GitHub

Combobox

Searchable dropdown with type-ahead filtering and model binding.

<rhx-combobox>

Examples

Basic

Enum Binding

Filled

Child Options

Sizes

States

htmx Integration

Properties

Property Type Default Description
rhx-for ModelExpression - ASP.NET Core model expression for two-way binding
name string - The form field name
value string - The current value
rhx-label string - Label text displayed above the combobox
rhx-hint string - Hint text displayed below the combobox
rhx-size string medium Combobox size: small, medium, large
rhx-disabled bool false Whether the combobox is disabled
rhx-readonly bool false Whether the combobox is read-only
rhx-placeholder string - Placeholder text
rhx-items List<SelectListItem> - Server-side items to render as options
rhx-filled bool false Use filled appearance
rhx-server-filter bool false Filter options server-side via htmx instead of client-side JS
rhx-search-param string q Query parameter name for the search text when server filtering is enabled

Accessibility

  • Uses role="combobox" with aria-expanded and aria-autocomplete.
  • Listbox options use role="option" with aria-selected.
  • Keyboard navigation: arrow keys, Enter to select, Escape to close.
  • Active descendant tracked via aria-activedescendant.