Orca Note Plugin API Documentation
    Preparing search index...

    Interface SelectProps

    Props for the Select dropdown component

    interface SelectProps {
        alignment?: "left" | "center" | "right";
        buttonClassName?: string;
        disabled?: boolean;
        filter?: boolean;
        filterFunction?: (
            keyword: string,
            options?: SelectOption[],
        ) => SelectOption[] | Promise<SelectOption[]>;
        filterPlaceholder?: string;
        filterPost?: ReactElement;
        formatter?: (value: string) => string;
        menuAttrs?: Record<string, any>;
        menuClassName?: string;
        menuContainer?: RefObject<HTMLElement>;
        multiSelection?: boolean;
        onChange?: (
            selected: string[],
            filterKeyword?: string,
        ) => void | Promise<void>;
        options: SelectOption[];
        placeholder?: string;
        pre?: ReactElement;
        readOnly?: boolean;
        selected: string[];
        width?: string | number;
        withClear?: boolean;
    }
    Index

    Properties

    alignment?: "left" | "center" | "right"

    Popup alignment relative to the button

    buttonClassName?: string

    Class name for the trigger button

    disabled?: boolean

    Disable the select

    filter?: boolean

    Show a search input to filter options

    filterFunction?: (
        keyword: string,
        options?: SelectOption[],
    ) => SelectOption[] | Promise<SelectOption[]>

    Custom filter function. Receives the keyword and the full option list, returns filtered options. When omitted, a default label/pinyin substring match is used.

    filterPlaceholder?: string

    Placeholder for the filter input

    filterPost?: ReactElement

    Element appended after the filter input

    formatter?: (value: string) => string

    Formats a selected value into a display string when the value has no matching option

    menuAttrs?: Record<string, any>

    Additional attributes forwarded to the Menu component

    menuClassName?: string

    Class name for the dropdown menu

    menuContainer?: RefObject<HTMLElement>

    Scrolling container ref for the popup

    multiSelection?: boolean

    Allow selecting multiple values

    onChange?: (selected: string[], filterKeyword?: string) => void | Promise<void>

    Called when selection changes; second argument is the current filter keyword if filtering is active

    options: SelectOption[]

    Available options

    placeholder?: string

    Placeholder text when nothing is selected

    pre?: ReactElement

    Element prepended inside the select button

    readOnly?: boolean

    Show the select in read-only mode (button click does nothing)

    selected: string[]

    Currently selected values

    width?: string | number

    Minimum width of the select button and dropdown

    withClear?: boolean

    Show a "Clear selection(s)" action at the bottom of the dropdown