Combobox

Use Combobox when the user searches, highlights, and selects structured options. Use Popover only for generic floating panels.

Preview#

import {
  Combobox,
  ComboboxClear,
  ComboboxContent,
  ComboboxControl,
  ComboboxEmpty,
  ComboboxInput,
  ComboboxItem,
  ComboboxItemIndicator,
  ComboboxList,
  ComboboxTriggerIndicator,
  Field,
  FieldLabel,
} from "raft-ui";

<Combobox>
  <Field>
    <FieldLabel />
    <ComboboxControl>
      <ComboboxInput />
      <ComboboxClear />
      <ComboboxTriggerIndicator />
    </ComboboxControl>
  </Field>
  <ComboboxContent>
    <ComboboxList>
      <ComboboxItem value="option">
        <ComboboxItemIndicator />
      </ComboboxItem>
    </ComboboxList>
    <ComboboxEmpty />
  </ComboboxContent>
</Combobox>

Button trigger#

Load options#

Async select#

Custom trigger#

API#WIP

PropTypeDefaultDescription
...propsBase UI Combobox.Root.PropsOwns selected value, input value, filtering, highlighted item, Escape, and Enter selection.
PropTypeDefaultDescription
...propsBase UI Combobox.Label.PropsAccessible label for the combobox.
PropTypeDefaultDescription
...propsBase UI Combobox.InputGroup.PropsInput-first control surface. Use it when the visible combobox trigger should be searchable; plain SVG children get the component's default icon size.
PropTypeDefaultDescription
renderReactElement | (props, state) => ReactElementReplaces the trigger element entirely. When provided, the default Button and its recipe styles are skipped; pass event and aria props to your own element.
...propsBase UI Combobox.Trigger.PropsDefault trigger renders an outline md Button for picker-style filters where the search input lives inside the popup.
PropTypeDefaultDescription
...propsBase UI Combobox.Value.PropsDisplayed value slot inside the trigger.
PropTypeDefaultDescription
...propsStyledProps<ComponentPropsWithRef<"span">>Count badge shown next to the trigger value.
PropTypeDefaultDescription
...propsStyledProps<ComponentPropsWithRef<"span">>Chevron or custom indicator inside the trigger.
PropTypeDefaultDescription
...propsBase UI Combobox.Input.PropsSearch input. Supports password-manager suppression for compact filter panels.
PropTypeDefaultDescription
...propsBase UI Combobox.InputGroup.PropsLayout wrapper grouping the input with trigger actions.
PropTypeDefaultDescription
...propsBase UI Combobox.Clear.PropsClears the current input and selected value through the primitive.
PropTypeDefaultDescription
...propsBase UI Popup + Positioner propsPortaled popup shell. Defaults to side=bottom, align=start, sideOffset=4, and local collision props.
PropTypeDefaultDescription
containerHTMLElement | RefObject | nullCustom portal container for framed previews or contained overlays.
...propsBase UI Combobox.Portal.PropsPortals the popup to the body or a custom container.
PropTypeDefaultDescription
...propsdiv propsHeader row for picker titles and trailing actions.
PropTypeDefaultDescription
...propsdiv propsHorizontal divider between composed combobox regions.
PropTypeDefaultDescription
...propsdiv propsUnpositioned popup shell for advanced static rendering. Prefer ComboboxContent for trigger-anchored pickers.
PropTypeDefaultDescription
...propsBase UI Combobox.List.PropsRenders filtered items, usually through the list render function.
PropTypeDefaultDescription
...propsBase UI Combobox.Empty.PropsEmpty-state message shown when no options match.
PropTypeDefaultDescription
...propsBase UI Combobox.Group.PropsGroup container for related options.
PropTypeDefaultDescription
...propsBase UI Combobox.GroupLabel.PropsGroup heading inside ComboboxGroup.
PropTypeDefaultDescription
...propsBase UI Combobox.Row.PropsRow layout for composite options.
PropTypeDefaultDescription
...propsBase UI Combobox.Item.PropsSelectable option row. Selection/highlight state is exposed through data attributes.
PropTypeDefaultDescription
...propsBase UI Combobox.ItemIndicator.PropsSelected-state indicator for single and multiple selection.
PropTypeDefaultDescription
...propsBase UI Combobox.Collection.PropsCollects items for keyboard navigation and filtering.
PropTypeDefaultDescription
...propsBase UI Combobox.Chips.PropsWrap container for selected-value chips.
PropTypeDefaultDescription
...propsBase UI Combobox.Chip.PropsSingle selected-value chip.
PropTypeDefaultDescription
...propsBase UI Combobox.ChipRemove.PropsDismiss control inside a selected-value chip.