Use internally by Select and Dropdown for rendering searchable option lists.
customSearchcustom-searchIndicates a custom search is being implemented for the option list.
disabledDisables the option list.
labelDetermines the label that is applied to the option list for accessibility purposes.
multipleEnables the multi-select ability for the option list.
Only applicable when options are provided.
noSelectno-selectDisables the logic that handles selecting and focusing an option in the option list.
selectedOptionsselected-optionsA list of the selected options on the element.
showSelectedshow-selectedApplies focus to the selected option.
typeTranslates to the role of the option list
The q2-option-list element exposes events that can be used to send and receive data from the component based on user interaction.
Emitted when an option is selected or deselected.
When the multi-select is enabled, the value property will be undefined and the selectedOptions property
will contain the selected option values.
{ value: string; values: IOptionValue[]; }Emitted to indicate the intended state of the popover.
{ open: boolean; action: "select" | "open" | "close"; }Emitted when the component has finished rendering.
undefinedEmitted when an option is selected or deselected.
When the multi-select is enabled, the value property will be undefined and the selectedOptions property
will contain the selected option values.
{ value: string; values: IOptionValue[]; }The q2-option-list element exposes methods that can be used to perform various actions on the component.
getContents() => Promise<(HTMLQ2OptgroupElement | ValidOptionElements)[]>getOptions() => Promise<ValidOptionElements[]>handleExternalKeydown(event: KeyboardEvent) => Promise<void>setActiveElement(index: number) => Promise<void>setDefaultActiveElement() => Promise<void>This component uses other components in the Tecton library, including:
Other components in the Tecton library use this component, including:
q2-action-sheetq2-dropdownq2-pillq2-selectq2-tagThe following CSS variables are available to override the default theme styles of the q2-option-list component.