device-navigation - v4.5.5
    Preparing search index...

    Type Alias NavigationResult<Action>

    NavigationResult: (
        | {
            coords: Coords;
            defaulted: boolean;
            newElement: HTMLElement;
            success: true;
            wrapped: boolean;
        }
        | { reason: string; success: false }
    ) & { direction: NavActionToDirectionType[Action]; navAction: Action }

    Data which describes the result of an attempted navigation action.

    Type Parameters

    Type declaration

    • {
          coords: Coords;
          defaulted: boolean;
          newElement: HTMLElement;
          success: true;
          wrapped: boolean;
      }
      • coords: Coords
      • defaulted: boolean

        When true, indicates that there was no valid starting point to start the navigation from, so a default behavior was taken. Most navigation actions do not support this behavior.

      • newElement: HTMLElement

        The element that the performed navigation focused.

      • success: true

        Indicates that the intended navigation succeeded or failed.

      • wrapped: boolean

        When true, indicates that the performed navigation resulted in a wrap.

    • { reason: string; success: false }
      • reason: string

        The reason why the intended navigation did not succeed.

      • success: false

        Indicates that the intended navigation succeeded or failed.