combobox

Combobox

Searchable single-choice list behind a trigger, with headed groups and an empty state; the list is as wide as its trigger, and the trigger joins a Field as its control.

States: Default, Focus, Disabled, Invalid

Parts

PartFileDoes
ComboboxCombobox.vueGroups all parts of the combobox, which lets the user search and pick an option.
ComboboxAnchorComboboxAnchor.vueMarks where the option list attaches, wrapping the input and trigger.
ComboboxEmptyComboboxEmpty.vueShows a message when no option matches the search.
ComboboxGroupComboboxGroup.vueGroups related options in the combobox list.
ComboboxInputComboboxInput.vueLets the user type to filter the combobox options.
ComboboxItemComboboxItem.vueHolds one option the user can pick from the combobox.
ComboboxItemIndicatorComboboxItemIndicator.vueMarks an option as selected in the combobox list.
ComboboxListComboboxList.vueHolds the options the combobox offers while it is open.
ComboboxSeparatorComboboxSeparator.vueSeparates groups of options in the combobox list; hidden while a search filters the list.
ComboboxTriggerComboboxTrigger.vueShows the chosen option and opens the combobox list when pressed.
ComboboxViewportComboboxViewport.vueScrolls the options when the combobox list is longer than the space available.

Anatomy

<Combobox>
  <ComboboxAnchor>
    <ComboboxTrigger />
  </ComboboxAnchor>
  <ComboboxList>
    <ComboboxInput />
    <ComboboxViewport>
      <ComboboxEmpty />
      <ComboboxSeparator />
      <ComboboxGroup>
        <ComboboxItem>
          <ComboboxItemIndicator />
        </ComboboxItem>
      </ComboboxGroup>
    </ComboboxViewport>
  </ComboboxList>
</Combobox>

Styling

PartRecipe
ComboboxAnchorcombobox-anchor
ComboboxEmptycombobox-empty
ComboboxGroupcombobox-label
ComboboxInputcombobox-input
ComboboxInputcombobox-search
ComboboxItemcombobox-item
ComboboxItemIndicatorcombobox-item-indicator
ComboboxListcombobox-content
ComboboxSeparatorcombobox-separator
ComboboxTriggercombobox-trigger
ComboboxTriggercombobox-chevron
ComboboxViewportcombobox-viewport

Install

Writes 13 files into components/ui/combobox/. For agents, npx @frontic/ui docs combobox prints this reference as markdown; the MCP server serves the same.

npm packages
@lucide/vue
@vueuse/core
reka-ui

API reference

Combobox Combobox.vue

Groups all parts of the combobox, which lets the user search and pick an option.

PropTypeDefault
openboolean—
defaultOpenbooleanfalse
resetSearchTermOnBlurbooleantrue
resetSearchTermOnSelectbooleantrue
openOnFocusbooleanfalse
openOnClickbooleanfalse
ignoreFilterbooleanfalse
resetModelValueOnClearbooleanfalse
unmountOnHidebooleantrue
multiplebooleanfalse
disabledbooleanfalse
dirDirection—
asChildbooleanfalse
asAsTag | Component—
modelValueAcceptableValue | AcceptableValue[]—
defaultValueAcceptableValue | AcceptableValue[]—
namestring—
requiredbooleanfalse
highlightOnHoverbooleantrue
loopbooleanfalse
bystring | ((a: AcceptableValue, b: AcceptableValue) => boolean)—
EventPayload
update:modelValuevalue: AcceptableValue
update:openvalue: boolean
highlightpayload: { ref: HTMLElement; value: AcceptableValue; } | undefined
SlotSlot props
default{ open: boolean; modelValue: AcceptableValue | AcceptableValue[]; }

ComboboxAnchor ComboboxAnchor.vue

ComboboxEmpty ComboboxEmpty.vue

ComboboxGroup ComboboxGroup.vue

ComboboxInput ComboboxInput.vue

ComboboxItem ComboboxItem.vue

ComboboxItemIndicator ComboboxItemIndicator.vue

ComboboxList ComboboxList.vue

ComboboxSeparator ComboboxSeparator.vue

ComboboxTrigger ComboboxTrigger.vue

ComboboxViewport ComboboxViewport.vue

Example
State