@dxos/react-ui-menu
    Preparing search index...

    Type Alias SortMenuProps<T>

    type SortMenuProps<T extends string> = {
        directionLabels: Record<SortDirection, string>;
        fields: readonly ViewOption<T>[];
        label: string;
        onChange: (value: SortValue<T>) => void;
        testId?: string;
        unsorted?: T;
        value: SortValue<T>;
    }

    Type Parameters

    • T extends string
    Index

    Properties

    directionLabels: Record<SortDirection, string>
    fields: readonly ViewOption<T>[]
    label: string

    Trigger label while the list is in its own order, and the menu's heading.

    onChange: (value: SortValue<T>) => void
    testId?: string

    Prefix of the trigger's and items' test ids (<testId>.<field>, <testId>.<direction>).

    unsorted?: T

    A field that is the list's own order (e.g. a hand-arranged one), so it has no direction to pick.

    value: SortValue<T>