import type { Meta, StoryObj } from '@storybook/react-vite'; import { Field, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSet, } from './field'; import { Input } from '../input/input'; import { Switch } from '../switch/switch'; const meta = { title: 'Components/Field', component: Field, parameters: { layout: 'centered', docs: { description: { component: 'Layout for a control and its supporting text, without a form library. Use the `form` subpath instead when you are on react-hook-form — that version also derives `aria-invalid` and `aria-describedby` from validation state. Here you own the wiring: give the control an `id` and point `FieldLabel` at it.', }, }, }, tags: ['autodocs'], decorators: [(Story) =>