import React from 'react';
import { Meta, Story } from '@storybook/react/types-6-0';
import { Switch, SwitchProps } from '.';
import { theme } from '../../styles/theme';

export default {
  title: 'Switch',
  component: Switch,
  argTypes: {
    onChange: { action: 'onChange' },
  },
} as Meta;

const Template: Story<SwitchProps> = (args) => <Switch {...args} />;

export const Default = Template.bind({});
Default.args = {
  onColor: theme.colors.success,
  offColor: theme.colors.gray[3],
};
