import type { Meta, StoryObj } from '@storybook/nextjs-vite' import { FieldWrapper } from '../components/ui/field-wrapper' import { Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectSeparator, SelectTrigger, SelectValue, } from '../components/ui/select' const meta = { title: 'UI/Select', component: Select, parameters: { layout: 'padded', }, tags: ['autodocs'], decorators: [ (Story) => (
), ], } satisfies Meta export default meta type Story = StoryObj /** * Default select with placeholder. */ export const Default: Story = { render: () => ( ), } /** * Select with a pre-selected value. */ export const WithValue: Story = { render: () => ( ), } /** * Disabled select. */ export const Disabled: Story = { render: () => ( ), } /** * Select with grouped items and labels. */ export const WithGroups: Story = { render: () => ( ), } /** * Select with a disabled item. */ export const WithDisabledItem: Story = { render: () => ( ), } /** * Select with many items to demonstrate scrolling. */ export const ManyItems: Story = { render: () => ( ), } /** * Select with invalid state. */ export const Invalid: Story = { render: () => ( ), } /** * Select with label using FieldWrapper. */ export const WithLabel: Story = { render: () => ( ), } /** * Select with label and error message. */ export const WithLabelAndError: Story = { render: () => ( ), } /** * Select with label and selected value. */ export const WithLabelAndValue: Story = { render: () => ( ), } /** * All select variants displayed together for comparison. */ export const AllVariants: Story = { render: () => (
), }