Trilium Frontend API
    Preparing search index...

    Interface GroupComponent

    interface GroupComponent {
        getElement: () => HTMLElement;
        getField: () => string;
        getKey: () => any;
        getParentGroup: () => false | GroupComponent;
        getRows: () => RowComponent[];
        getSubGroups: () => GroupComponent[];
        getTable: () => Tabulator;
        hide: () => void;
        isVisible: () => boolean;
        popup: (contents: string, position: PopupPosition) => void;
        scrollTo: (
            position?: "center" | "top" | "bottom" | "nearest",
            scrollIfVisible?: boolean,
        ) => Promise<void>;
        show: () => void;
        toggle: () => void;
    }
    Index

    Properties

    getElement: () => HTMLElement

    The getElement function returns the DOM node for the group header.

    getField: () => string

    Returns the string of the field that all rows in this group have been grouped by. (if a function is used to group the rows rather than a field, this function will return false)

    getKey: () => any

    The getKey function returns the unique key that is shared between all rows in this group.

    getParentGroup: () => false | GroupComponent

    The getParentGroup function returns the GroupComponent for the parent group of this group. if no parent exists, this function will return false.

    getRows: () => RowComponent[]

    The getRows function returns an array of RowComponent objects, one for each row in the group

    getSubGroups: () => GroupComponent[]

    The getSubGroups function returns an array of GroupComponent objects, one for each sub group of this group.

    getTable: () => Tabulator

    The getTable function returns the Tabulator object for the table containing the group

    hide: () => void

    The hide function hides the group if it is visible.

    isVisible: () => boolean

    The isVisible function returns a boolean to show if the group is visible, a value of true means it is visible.

    popup: (contents: string, position: PopupPosition) => void
    scrollTo: (
        position?: "center" | "top" | "bottom" | "nearest",
        scrollIfVisible?: boolean,
    ) => Promise<void>

    The scrollTo function will scroll the table to the group header if it passes the current filters.

    show: () => void

    The show function shows the group if it is hidden.

    toggle: () => void

    The toggle function toggles the visibility of the group, switching between hidden and visible.