shadcn.io is not affiliated with official shadcn/ui
Field examples · Selects
Multiple Selects Field for React
Language and currency selects stacked in a field group, each with a default value.
Framework
UI library
Two related Selects for regional settings, Language and Currency, stacked in a FieldGroup. Each opens on a default, English and USD, so the form is valid before anyone touches it.
Preview
Installation
Sign in to get your install command
Free with an account. It carries your token, so the CLI installs everything in one go.
FAQ
What groups Language and Currency?
One FieldGroup stacks two Fields, capped with max-w-md. Each field is a FieldLabel and a Select, and neither field sets orientation.
Which values are selected at first?
Language opens on English, and Currency opens on USD. Neither has a placeholder.
Set defaultValue to en on Language and usd on Currency.
What is in each list?
Language items are English, Spanish, French, and German. Currency items are USD, EUR, GBP, and JPY. Each option is a SelectItem.
Related
- Simple Select FieldA country select with a label and a
- Select with Default Value FieldAn account status select that opens on
- Vertical Layout (Default) FieldTwo stacked fields, each with its label
- Grid Layout FieldPersonal details in a grid: two equal
- Date Picker with RangeA date range picker that shows two months
- Theme Selector Dropdown MenuA theme picker behind a palette button