UNPKG

ngx-extended-pdf-viewer

Version:

Embedding PDF files in your Angular application. Highly configurable viewer including the toolbar, sidebar, and all the features you're used to.

39 lines (38 loc) • 1.84 kB
import * as i0 from "@angular/core"; /** * Multiple viewers on one page: the live viewers, in the order they were created. * * Each <ngx-extended-pdf-viewer> has its own PDFNotificationService and * NgxExtendedPdfViewerService. The instances an application injects (root or module * level) follow the primary viewer - the oldest live one - so applications with a * single viewer work exactly as before. * * Internal - not part of the public API. */ export declare class PdfViewerRegistry { private readonly viewers; /** the oldest live viewer, or undefined if there's none */ readonly primary: import("@angular/core").Signal<object>; /** the number of live viewers */ readonly count: import("@angular/core").Signal<number>; private readonly lastUsed; /** the browser's window.print(), saved before the first viewer replaces it with `print` */ readonly nativePrint: (() => void) | undefined; /** * The viewer the user works with: the one clicked or focused last, else the primary viewer. * Keyboard shortcuts typed outside every viewer go to this one. */ readonly active: import("@angular/core").Signal<object>; /** * window.print() while ngx-extended-pdf-viewer prints with pdf.js (`replaceBrowserPrint`): prints the * active viewer. One function for all viewers, so it doesn't matter which viewer installed it last. */ readonly print: () => void; /** whether a live viewer prints with pdf.js (`replaceBrowserPrint`), so window.print() must stay `print` */ someViewerPrintsWithPdfJs(): boolean; activate(viewer: object): void; register(viewer: object): void; unregister(viewer: object): void; static ɵfac: i0.ɵɵFactoryDeclaration<PdfViewerRegistry, never>; static ɵprov: i0.ɵɵInjectableDeclaration<PdfViewerRegistry>; }