import { ActionsType } from '../../lib/hyperapp'; import { OutlineItem, Annotation, PdfItemsOnPage, DeletedItem } from '../../pdf-viewer-api'; type NavigationType = 'thumbnail' | 'outline' | 'annotation'; /** internal */ export interface PageNavigationItem { thumbnail: string | null; pageNumber: number; loading?: boolean | null; } /** internal */ export interface OutlineNavigationItem extends OutlineItem { open: boolean; hasDescendants: boolean; descendants: OutlineNavigationItem[]; } export interface AnnotationItemState { [annotationId: number]: Annotation; } export interface AnnotationsState { [page: number]: AnnotationItemState; } export interface AnnotationSelection { page: number; annotationId: number; } /** internal */ export interface NavigationPanelState { showNavigation: boolean; selectedNavigation: NavigationType; outlineItemsLoaded: boolean; annotationsLoaded: boolean; pages: PageNavigationItem[]; outlines: OutlineNavigationItem[]; annotations: AnnotationsState; selectedAnnotation?: AnnotationSelection; } /** internal */ export declare const state: NavigationPanelState; /** internal */ export interface NavigationPanelActions { clear(): NavigationPanelState; setThumbnailPlaceholders(pageCount: number): NavigationPanelState; updateThumbnail(pageThumbnail: PageNavigationItem): NavigationPanelState; setOutlines(outline: OutlineNavigationItem[]): NavigationPanelState; selectNavigation(navigation: NavigationType): NavigationPanelState; toggleNavigationPanel(): NavigationPanelState; showNavigationPanel(): NavigationPanelState; hideNavigationPanel(): NavigationPanelState; toggleOutlineItem(path: string[]): NavigationPanelState; clearAnnotations(): NavigationPanelState; setAnnotationLoaded(): NavigationPanelState; initAnnotations(pageCount: number): NavigationPanelState; setPageAnnotations(itemsOnPage: PdfItemsOnPage): NavigationPanelState; updateAnnotation(annotation: Annotation): NavigationPanelState; deleteAnnotation(deletedItem: DeletedItem): NavigationPanelState; selectAnnotation(annotation: Annotation): NavigationPanelState; deselectAnnotation(): NavigationPanelState; } /** internal */ export declare const actions: ActionsType; export {};