Live navigation API provided to View skins / shells.
Source src/ui/Navigator.ts:4124 lines
export interface Service {
readonly Service.root: RouteGroup(property) Service.root: {
key: string;
members: Record<string, unknown>;
}
root: type RouteGroup = {
readonly key: string;
readonly members: Record<string, unknown>;
}
A group-shaped node the router can walk (Group.Tag or { key, members }).
RouteGroup;
readonly Service.mode: "memory" | "history"mode: "memory" | "history";
/** Short-name path — `["Nwsl", "HttpApi"]`. */
readonly Service.path: readonly string[]Short-name path — ["Nwsl", "HttpApi"].
path: interface ReadonlyArray<T>ReadonlyArray<string>;
readonly Service.trail: readonly RouteGroup[]trail: interface ReadonlyArray<T>ReadonlyArray<type RouteGroup = {
readonly key: string;
readonly members: Record<string, unknown>;
}
A group-shaped node the router can walk (Group.Tag or { key, members }).
RouteGroup>;
/** Deepest group (grid to render). */
readonly Service.group: RouteGroup(property) Service.group: {
key: string;
members: Record<string, unknown>;
}
Deepest group (grid to render).
group: type RouteGroup = {
readonly key: string;
readonly members: Record<string, unknown>;
}
A group-shaped node the router can walk (Group.Tag or { key, members }).
RouteGroup;
readonly Service.selected: unknownselected: unknown | null;
/** Leaf sub-view (`"logs"` / `"schedule"`), if any. */
readonly Service.view: string | undefinedLeaf sub-view ("logs" / "schedule"), if any.
view: string | undefined;
readonly Service.open: (member: MemberTag) => voidopen: (member: MemberTagmember: type MemberTag =
| LeafTag
| {
readonly key: string
readonly members: Record<string, unknown>
}
Group or leaf a Navigator can open — what
Group.isGroup
narrows against.
MemberTag) => void;
/** Descend by short member name from the current group (or append leaf sub-view). */
readonly Service.openKey: (key: string) => voidDescend by short member name from the current group (or append leaf sub-view).
openKey: (key: stringkey: string) => void;
readonly Service.back: () => voidback: () => void;
readonly Service.toRoot: () => voidtoRoot: () => void;
/** Show the leaf’s `page`-sized content outlet as logs (path + `"logs"`). */
readonly Service.openLogs: (tag: LeafTag) => voidShow the leaf’s page-sized content outlet as logs (path + "logs").
openLogs: (tag: LeafTag(parameter) tag: {
key: string;
}
tag: LeafTag) => void;
/** Show schedule as page content (path + `"schedule"`). */
readonly Service.openSchedule: (tag: LeafTag) => voidShow schedule as page content (path + "schedule").
openSchedule: (tag: LeafTag(parameter) tag: {
key: string;
}
tag: LeafTag) => void;
readonly Service.subscribe: (listener: () => void) => () => voidsubscribe: (listener: () => voidlistener: () => void) => () => void;
/** History mode: re-read `location.pathname`. @internal */
readonly Service.syncFromLocation: () => voidHistory mode: re-read location.pathname.
syncFromLocation: () => void;
}
Referenced by 4 symbols