import { IPathFragments, IRoute, IRouteMatch, IRouterSlot, PathFragment } from "./model"; /** * Slot for a node in the router tree. * @slot - Default content. * @event changestate - Dispatched when the router slot state changes. */ export declare class RouterSlot extends HTMLElement implements IRouterSlot { /** * Listeners on the router. */ private listeners; /** * The available routes. */ private _routes; routes: IRoute[]; /** * The parent router. * Is REQUIRED if this router is a child. * When set, the relevant listeners are added or teared down because they depend on the parent. */ _parent: IRouterSlot

| null | undefined; parent: IRouterSlot

| null | undefined; /** * The current route. */ readonly route: IRoute | null; /** * The current path fragment. */ readonly fragments: IPathFragments | null; /** * The current path routeMatch. */ private _routeMatch; readonly match: IRouteMatch | null; /** * Whether the router is a root router. */ readonly isRoot: boolean; /** * Hooks up the element. */ constructor(); /** * Query the parent router slot when the router slot is connected. */ connectedCallback(): void; /** * Tears down the element. */ disconnectedCallback(): void; /** * Queries the parent router. */ queryParentRouterSlot(): IRouterSlot

| null; /** * Returns an absolute path from this router slot. * @param path */ constructAbsolutePath(path: PathFragment): string; /** * Adds routes to the router. * @param routes * @param navigate */ add(routes: IRoute[], navigate?: boolean): void; /** * Removes all routes. */ clear(): void; /** * Each time the path changes, load the new path. */ load(): Promise; /** * Attaches listeners, either globally or on the parent router. */ protected attachListeners(): void; /** * Detaches the listeners. */ protected detachListeners(): void; /** * Loads a new path based on the routes. * Returns true if a navigation was made to a new page. */ protected loadPath(path: string | PathFragment): Promise; } declare global { interface HTMLElementTagNameMap { "router-slot": RouterSlot; } }