Spatial Navigation for GeckoView - v3.2.0
    Preparing search index...

    Variable GroupPathConst

    GroupPath: {
        ancestors(id: string): string[];
        areSiblings(id1: string, id2: string): boolean;
        depth(id: string): number;
        isDescendant(childId: string, parentId: string): boolean;
        leaf(id: string): string;
        parent(id: string): string | null;
        root(id: string): string;
    } = ...

    Path utilities for hierarchical group IDs.

    Type Declaration

    • ancestors: function
      • Get all ancestor IDs for a group. e.g., "sidebar.menu.item1" -> ["sidebar.menu", "sidebar"]

        Parameters

        • id: string

        Returns string[]

    • areSiblings: function
      • Check if two IDs are siblings (same parent).

        Parameters

        • id1: string
        • id2: string

        Returns boolean

    • depth: function
      • Get the depth of a group ID. e.g., "sidebar" -> 1, "sidebar.menu" -> 2, "sidebar.menu.item1" -> 3

        Parameters

        • id: string

        Returns number

    • isDescendant: function
      • Check if childId is a descendant of parentId. e.g., isDescendant("sidebar.menu.item1", "sidebar") -> true

        Parameters

        • childId: string
        • parentId: string

        Returns boolean

    • leaf: function
      • Get the leaf name (last segment). e.g., "sidebar.menu.item1" -> "item1"

        Parameters

        • id: string

        Returns string

    • parent: function
      • Get the parent path of a group ID. e.g., "sidebar.menu.item1" -> "sidebar.menu"

        Parameters

        • id: string

        Returns string | null

    • root: function
      • Get the root ID (first segment). e.g., "sidebar.menu.item1" -> "sidebar"

        Parameters

        • id: string

        Returns string