48 lines
975 B
TypeScript
48 lines
975 B
TypeScript
|
|
import type { Meta, StoryObj } from '@storybook/react';
|
||
|
|
import { AuthButton } from './AuthButton';
|
||
|
|
|
||
|
|
const meta = {
|
||
|
|
title: 'Features/Auth/Components/AuthButton',
|
||
|
|
component: AuthButton,
|
||
|
|
tags: ['autodocs'],
|
||
|
|
argTypes: {
|
||
|
|
variant: {
|
||
|
|
control: 'radio',
|
||
|
|
options: ['primary', 'secondary'],
|
||
|
|
},
|
||
|
|
loading: { control: 'boolean' },
|
||
|
|
disabled: { control: 'boolean' },
|
||
|
|
},
|
||
|
|
} satisfies Meta<typeof AuthButton>;
|
||
|
|
|
||
|
|
export default meta;
|
||
|
|
type Story = StoryObj<typeof meta>;
|
||
|
|
|
||
|
|
export const Primary: Story = {
|
||
|
|
args: {
|
||
|
|
children: 'Sign In',
|
||
|
|
variant: 'primary',
|
||
|
|
},
|
||
|
|
};
|
||
|
|
|
||
|
|
export const Secondary: Story = {
|
||
|
|
args: {
|
||
|
|
children: 'Create Account',
|
||
|
|
variant: 'secondary',
|
||
|
|
},
|
||
|
|
};
|
||
|
|
|
||
|
|
export const Loading: Story = {
|
||
|
|
args: {
|
||
|
|
children: 'Sign In',
|
||
|
|
loading: true,
|
||
|
|
},
|
||
|
|
};
|
||
|
|
|
||
|
|
export const Disabled: Story = {
|
||
|
|
args: {
|
||
|
|
children: 'Sign In',
|
||
|
|
disabled: true,
|
||
|
|
},
|
||
|
|
};
|