Skip to main content

UseTour

What useTour returns.

This is an interface exported by @mapcairn/map, checked against version 0.2.0.

Signature​

import type { UseTour } from "@mapcairn/map";

interface UseTour

Properties​

focusRequest​

readonly focusRequest: number;

Grows each time the card's heading should take focus.

state​

readonly state: TourState;

Where the tour is: off, welcome, running or ended.

step​

readonly step: TourStep | null;

The current step while running, else null.

steps​

readonly steps: readonly TourStep[];

The tour's steps, as the host gave them.

Methods​

close​

close(): void;

Closes the ending card.

next​

next(): void;

Goes to the next step, or to the ending after the last.

skip​

skip(): void;

Ends the tour from the welcome card or any step.

start​

start(): void;

Starts at the first step, from the welcome card or from Help.

See also​

Source: packages/map/src/tools/Tour/useTour.ts:49