Binhlaig logoBinhlaig UI
Components/ComboBox
Binhlaig UI Component

ComboBox

A searchable input combined with a predefined list of selectable options.

Installation

Install Combobox in your project.

Terminal
npx binhlaig-ui@latest add combobox

For project setup, installer selection, dependencies, and advanced installation instructions, see the Installation Guide.

View Installation Guide →Update or Overwrite →

Import

Import the ComboBox primitives you need.

import {
  Combobox,
  ComboboxClear,
  ComboboxEmpty,
  ComboboxInput,
  ComboboxInputGroup,
  ComboboxItem,
  ComboboxItemIndicator,
  ComboboxList,
  ComboboxPopup,
  ComboboxPortal,
  ComboboxPositioner,
  ComboboxTrigger,
} from "@/components/ui/combobox"

Basic

Filter and select from a predefined list.

Controlled Value

Manage the selected option from React state.

Selected:Next.js

Grouped Options

Organize large option lists into readable groups.

Disabled

Disable the complete control when selection is unavailable.

API Reference

Main primitives available in Binhlaig UI ComboBox.

ComponentPurpose
ComboboxControls items, value and open state.
ComboboxInputFilters available options.
ComboboxTriggerOpens or closes the popup.
ComboboxClearClears the selected option.
ComboboxPopupFloating option container.
ComboboxListRenders available items.
ComboboxItemA selectable option.
ComboboxItemIndicatorMarks the selected option.
ComboboxEmptyShown when filtering has no results.
ComboboxGroupGroups related options.