import { Meta, Story } from '@storybook/react';
import React from 'react';
import { Button, ButtonTypes, IButtonProps } from '../../../components/Button';
import { RPGUIRoot } from '../../../components/RPGUI/RPGUIRoot';

const meta: Meta = {
  title: 'UI/Buttons & Inputs/Button',
  component: Button,
  argTypes: {
    children: {},
    buttonType: {
      control: {
        type: 'select',
        labels: {
          [ButtonTypes.RPGUIButton]: 'rpgui-button',
          [ButtonTypes.RPGUIGoldButton]: 'rpgui-button gold',
        },
      },
    },
  },
};

export default meta;

const Template: Story<IButtonProps> = args => (
  <RPGUIRoot>
    <Button {...args} />
  </RPGUIRoot>
);

export const Default = Template.bind({});

Default.args = {
  children: 'Teste',
  buttonType: ButtonTypes.RPGUIButton,
};
