Forms
Combobox
A searchable dropdown select with filtering, clear button, disabled options, and optional description text.
Quick Preview
Installation
// Copy Combobox.tsx to your components/forms/ folder// src/components/forms/Combobox.tsx
Usage
import { Combobox } from '@/components/forms/Combobox'const options = [{ value: 'next', label: 'Next.js' },{ value: 'remix', label: 'Remix' },{ value: 'astro', label: 'Astro', disabled: true },]const [framework, setFramework] = useState('')<Comboboxoptions={options}value={framework}onChange={setFramework}placeholder="Select a framework…"label="Framework"/>
Examples
Frameworks with disabled option
Prompt Preview
Copy a prompt that recreates this UI
Paste this into your AI coding assistant to generate code that closely matches the reference, including color, size, shape, typography, spacing, and polish.
Copy-ready AI prompt
Starts from the current visual reference and project constraints.
Tweak only product-specific copy or data after the first generation pass.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
options* | ComboboxOption[] | - | Array of selectable options |
value | string | - | Controlled selected value |
onChange | (value: string) => void | - | Called when selection changes |
placeholder | string | "Select an option…" | Trigger button placeholder |
searchPlaceholder | string | "Search…" | Search input placeholder |
disabled | boolean | false | Disables the entire combobox |
label | string | - | Label rendered above the trigger |
emptyMessage | string | "No options found." | Message when search has no results |