Skip to content

Listbox ​

Single / multi select list, role=listbox

A choice where the options should stay visible — a short list in a sidebar, a filter panel, a settings pane. When space is tight use Select; for a handful of single choices RadioGroup is simpler; to type and filter, Combobox.

Basic
加藤恵
澤村・スペンサー・英梨々
霞ヶ丘詩羽
氷堂美智留
波島出海
megumi
加藤恵
澤村・スペンサー・英梨々
霞ヶ丘詩羽
氷堂美智留
波島出海
[ "eriri", "utaha" ] · 3 rows then scroll · type to jump
  • One tab stop. Arrows move, Home/End jump, Space or Enter picks, and typing letters jumps to a matching label. Focus starts on the selected option.
  • multiple toggles each option; rows caps the height and scrolls.
  • Inside a Field the field's label names it. name submits one value per selected option.

Usage ​

ts
import { BlessListbox } from "blessing-ui";

API ​

Props

NameTypeDefaultDescription
idstring—
namestring—submitted with the form, one value per selected option
options*BlessOption<T>[]—
multipleboolean—
disabledboolean—
labelstring—
rowsnumber0visible rows before scrolling; 0 = no limit
modelValueT | T[]—

Events

NamePayloadDescription
update:modelValue[value: T | T[] | undefined]

Slots

NameScopeDescription
default{ option: BlessOption<T>; selected: boolean; }

Released under the MIT License. Character names and artwork belong to their owners.