A styled, accessible <select> — single or multi, text or badge display,
optionally searchable and creatable.
A real <select> carries the value (server-authoritative, so phx-change
works with zero extra wiring); the SkuaSelect hook layers a W3C APG
combobox/listbox on top with full keyboard support (arrows, Home/End,
typeahead, Enter/Escape) and aria-activedescendant.
<.select field={@form[:status]} label="Status"
options={[{"Open", "open"}, {"Done", "done"}]} />
<.select field={@form[:teams]} multiple display="badge" searchable creatable
placeholder="Add teams…" options={@team_options} />Options are {label, value} or {label, value, description} tuples.
Summary
Functions
Attributes
field(Phoenix.HTML.FormField) - Defaults tonil.id(:string) - Defaults tonil.name(:string) - Defaults tonil.value(:any) - Defaults tonil.options(:list) (required) - {label, value} or {label, value, desc} tuples.multiple(:boolean) - Defaults tofalse.display(:string) - Defaults to"text". Must be one of"text", or"badge".placeholder(:string) - Defaults to"Select…".prompt(:string) - empty leading option so a single select can be unselected (the placeholder shows). Defaults tonil.searchable(:boolean) - Defaults tofalse.creatable(:boolean) - Defaults tofalse.label(:string) - Defaults tonil.hint(:string) - Defaults tonil.errors(:list) - Defaults tonil.required(:boolean) - Defaults tofalse.- Global attributes are accepted.