UNPKG

1.41 kBTypeScriptView Raw
1import type { PageInstance } from '@tarojs/runtime';
2import type { PageConfig } from '@tarojs/taro';
3import type { History } from 'history';
4import type { MpaRouterConfig, Route } from '../../types/router';
5export default class MultiPageHandler {
6 history: History;
7 protected config: MpaRouterConfig;
8 constructor(config: MpaRouterConfig, history: History);
9 get appId(): string;
10 get router(): import("../../types/router").Router;
11 get routerMode(): "hash" | "browser" | "multi";
12 get customRoutes(): Record<string, string | string[]>;
13 get tabBarList(): import("@tarojs/taro").TabBarItem[];
14 get PullDownRefresh(): any;
15 set pathname(p: string);
16 get pathname(): string;
17 get basename(): string;
18 get pageConfig(): Route;
19 get isTabBar(): boolean;
20 get search(): string;
21 get usingWindowScroll(): boolean;
22 getQuery(search?: string, options?: Record<string, unknown>): {
23 [x: string]: unknown;
24 };
25 isDefaultNavigationStyle(): boolean;
26 mount(): void;
27 onReady(page: PageInstance, onLoad?: boolean): void;
28 load(page: PageInstance, pageConfig?: Route): void;
29 getPageContainer(page?: PageInstance | null): HTMLElement | null;
30 getScrollingElement(page?: PageInstance | null): (Window & typeof globalThis) | HTMLElement;
31 bindPageEvents(page: PageInstance, config?: Partial<PageConfig>): void;
32 triggerRouterChange(): void;
33}