@theredhead — Frontend Library - v1.0.0
    Preparing search index...

    Interface TreeKeyboardDelegate

    Delegate interface that the TreeKeyboardHandler uses to query and navigate the tree-view's state.

    All navigation and selection logic lives in the delegate (the component). The handler is just a thin key-to-intent mapper.

    Implement this on the host component (or any adapter) to wire up the handler without coupling it to a specific component class.

    interface TreeKeyboardDelegate {
        activateCursor(): void;
        clearSelection(): void;
        collapseCursor(): void;
        cursorHasChildren(): boolean;
        expandCursor(): void;
        hasCursor(): boolean;
        isCursorExpanded(): boolean;
        moveCursorDown(extend: boolean): void;
        moveCursorToFirst(extend: boolean): void;
        moveCursorToLast(extend: boolean): void;
        moveCursorToParent(): void;
        moveCursorUp(extend: boolean): void;
    }

    Implemented by

    Index

    Methods

    • Activate the cursor node (e.g. emit an activation event).

      Returns void

    • Clear all selection.

      Returns void

    • Collapse the cursor node.

      Returns void

    • Whether the cursor node has children (is expandable).

      Returns boolean

    • Expand the cursor node.

      Returns void

    • Whether any node currently has the keyboard cursor.

      Returns boolean

    • Whether the cursor node is currently expanded.

      Returns boolean

    • Move cursor to the next visible node.

      Parameters

      • extend: boolean

      Returns void

    • Move cursor to the first visible node.

      Parameters

      • extend: boolean

      Returns void

    • Move cursor to the last visible node.

      Parameters

      • extend: boolean

      Returns void

    • Move cursor to the parent of the current node.

      Returns void

    • Move cursor to the previous visible node.

      Parameters

      • extend: boolean

      Returns void