hosanna-ui-docs - v0.9.0
    Preparing search index...

    Interface representing the focus manager, responsible for managing focus transitions, handling key events, and providing debug utilities for focus management.

    interface IFocusManager {
        focusedView?: IFocusable;
        isAppLaunching: boolean;
        isLockedOnNativeRenderer: boolean;
        _setFocusLocked(newFocus: IFocusable): void;
        _setFocusUnlocked(): void;
        _tick(): void;
        _toggleDebugView(): void;
        addDebugView(): void;
        onKeyEvent(key: string, isPressed: boolean): void;
        resetFocus(): void;
        setFocus(newFocus: IFocusable, forced?: boolean): IOperationResult;
        setNativeFocus(renderer?: ISGNNode): void;
    }

    Implemented by

    Index

    Properties

    focusedView?: IFocusable

    The currently focused view.

    isAppLaunching: boolean
    isLockedOnNativeRenderer: boolean

    Indicates whether the focus is locked on the native renderer.

    Methods

    • Handles a key event and updates the focus state accordingly.

      Parameters

      • key: string

        The key that was pressed or released.

      • isPressed: boolean

        Whether the key is currently pressed.

      Returns void