View as Markdown

API reference: @salmonui/dropdowns/select

SelectItemRenderPropsinterface

import type { SelectItemRenderProps } from '@salmonui/dropdowns/select';
interface DropdownItemRenderProps<Item> {
    readonly item: Item;
    readonly label: string;
    readonly selected: boolean;
    readonly active: boolean;
    readonly disabled: boolean;
    readonly matches: readonly (readonly [
        number,
        number
    ])[];
}
SelectItemRenderProps members (6)
NameSignatureDescription
itemreadonly item: Item;
labelreadonly label: string;
selectedreadonly selected: boolean;
activereadonly active: boolean;
disabledreadonly disabled: boolean;
matchesreadonly matches: readonly (readonly [ number, number ])[];

[start, end) offsets of the matched text in label (with highlightMatches or a search).