/** Take the hash if it is going, and report whether this caller got it. */ export declare function claimHash(): boolean; /** Give the hash back, so a book that replaces this one can own it. */ export declare function releaseHash(): void; /** Read the 1-based page from a hash, as a 0-based index. Null when it carries no page. */ export declare function pageFromHash(hash: string): number | null; /** The hash that names `page` (0-based), leaving any other keys in `hash` untouched. */ export declare function hashWithPage(hash: string, page: number): string; export interface DeepLinkHandle { /** Write the current page into the address bar. */ push(page: number): void; stop(): void; } /** * Mirror the reader's page in the URL, and follow it when the URL changes (back/forward, or a * pasted link). `onNavigate` fires only for a page the book is not already on. */ export declare function bindDeepLink(win: Window, onNavigate: (page: number) => void): DeepLinkHandle;