Select
Picks one value from a short list of options.
- Forms
- 1 file
- 2 npm packages
- Accessibility notes
pnpm dlx @dowel-ui/cli add selectnpm packages installed: class-variance-authority, radix-ui.
import { Select } from "@/components/ui/select";Default
Grouped
With Disabled Option
Long List
Invalid
Spring Stagger
<Select>
| Prop | Type | Default |
|---|---|---|
aria-describedby | string | — |
aria-invalid | AriaAttributes["aria-invalid"] | — |
aria-label | string | — |
aria-labelledby | string | — |
id | string | — |
Every prop of Radix UI’s Select.Root, plus className.
<SelectTrigger>
| Prop | Type | Default |
|---|---|---|
triggerSize | "sm" | "md" | "lg" | "md" |
Every prop of Radix UI’s Select.Trigger, plus className.
<SelectContent>
Every prop of Radix UI’s Select.Content, plus className.
<SelectItem>
| Prop | Type | Default |
|---|---|---|
labelWhat the trigger shows once this option is chosen. The primitive clones the item's text into the trigger, so a rich option — a name with a description under it — would otherwise drag all of that into a one-line trigger. Give the label here and the rest as children. | ReactNode | — |
Every prop of Radix UI’s Select.Item, plus className.
<SelectLabel>
Every prop of Radix UI’s Select.Label, plus className.
<SelectSeparator>
Every prop of Radix UI’s Select.Separator, plus className.
8/8
checks passed
- Tested — passes
- axe assertion — passes
- Keyboard tested — does not apply
- Storybook examples — passes
- Accessibility documented — passes
- Semantic tokens only — passes
- Motion from tokens — passes
- className merged — passes
- Visible focus — does not apply
- No fixed widths — passes