Combo Box
A combo box combines a text input with a listbox, allowing users to filter a list of options to items matching a query.
Installation
CLI
Copy & Paste
npx @sly-cli/sly add draft-ui comboboxExamples
Default
This is the default ComboBox
Example
Code
With Button
Any React Aria Component Button placed inside ComboBox, will automatically toggle the appearance of ComboBoxContent when pressed.
Example
Code
Disabled Keys
To disable specific ComboBoxItem's, add an array of disabledKey's to ComboBox. Ensure the ComboBoxItem's have appropriate, corresponding id's.
Example
Code
Disabled
Use the isDisabled prop to disable the ComboxInput altogether.
Example
Code