Skip to content

Latest commit

 

History

History
29 lines (23 loc) · 597 Bytes

storybook.md

File metadata and controls

29 lines (23 loc) · 597 Bytes

Storybook code example

import type { Meta, StoryObj } from '@storybook/react';
import { Theme } from '@/shared/consts/theme';
import { WithThemeDecorator } from '@/shared/config/storybook';
import { Input } from './Input';

const meta: Meta<typeof Input> = {
  title: 'Shared/Input',
  component: Input,
  tags: ['autodocs'],
  decorators: [WithThemeDecorator(Theme.DARK)],
};

export default meta;
type Story = StoryObj<typeof Input>;

export const Clear: Story = {
  args: {},
};

export const WithPlaceholder: Story = {
  args: {
    placeholder: 'Some text',
  },
};