import type { Meta, StoryObj } from '@storybook/react-vite'; import { Button } from '../../src/ui/Button/Button'; const meta: Meta = { title: 'UI/Button', component: Button, parameters: { layout: 'centered' }, tags: ['autodocs'], argTypes: { variant: { control: 'select', options: ['primary', 'secondary', 'ghost', 'danger'] }, size: { control: 'select', options: ['sm', 'md', 'lg'] }, loading: { control: 'boolean' }, disabled: { control: 'boolean' }, }, }; export default meta; type Story = StoryObj; export const Primary: Story = { args: { children: 'Button', variant: 'primary' } }; export const Secondary: Story = { args: { children: 'Button', variant: 'secondary' } }; export const Ghost: Story = { args: { children: 'Button', variant: 'ghost' } }; export const Danger: Story = { args: { children: 'Delete', variant: 'danger' } }; export const Small: Story = { args: { children: 'Small', size: 'sm' } }; export const Large: Story = { args: { children: 'Large', size: 'lg' } }; export const Loading: Story = { args: { children: 'Saving…', loading: true } }; export const Disabled: Story = { args: { children: 'Button', disabled: true } };