@progress/kendo-angular-pdfviewer 13.0.0-develop.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/LICENSE.md +11 -0
  2. package/NOTICE.txt +654 -0
  3. package/README.md +32 -0
  4. package/esm2020/index.mjs +16 -0
  5. package/esm2020/loader/loader.component.mjs +53 -0
  6. package/esm2020/localization/custom-messages.component.mjs +38 -0
  7. package/esm2020/localization/localized-messages.directive.mjs +37 -0
  8. package/esm2020/localization/messages.mjs +71 -0
  9. package/esm2020/models/events.mjs +21 -0
  10. package/esm2020/models/loader-settings.mjs +5 -0
  11. package/esm2020/models/pdfviewer-context.mjs +5 -0
  12. package/esm2020/models/toolbar-tool.mjs +5 -0
  13. package/esm2020/models/zoom-level.mjs +5 -0
  14. package/esm2020/package-metadata.mjs +15 -0
  15. package/esm2020/pdfviewer.component.mjs +801 -0
  16. package/esm2020/pdfviewer.module.mjs +81 -0
  17. package/esm2020/progress-kendo-angular-pdfviewer.mjs +8 -0
  18. package/esm2020/toolbar/input-wrapper.component.mjs +63 -0
  19. package/esm2020/toolbar/search.component.mjs +171 -0
  20. package/esm2020/toolbar/toolbar-combobox.directive.mjs +43 -0
  21. package/esm2020/toolbar/toolbar-focusable.directive.mjs +63 -0
  22. package/esm2020/toolbar/toolbar-navigation.service.mjs +52 -0
  23. package/esm2020/toolbar/toolbar.component.mjs +460 -0
  24. package/esm2020/util.mjs +72 -0
  25. package/fesm2015/progress-kendo-angular-pdfviewer.mjs +1943 -0
  26. package/fesm2020/progress-kendo-angular-pdfviewer.mjs +1938 -0
  27. package/index.d.ts +16 -0
  28. package/loader/loader.component.d.ts +17 -0
  29. package/localization/custom-messages.component.d.ts +18 -0
  30. package/localization/localized-messages.directive.d.ts +16 -0
  31. package/localization/messages.d.ts +113 -0
  32. package/models/events.d.ts +81 -0
  33. package/models/loader-settings.d.ts +48 -0
  34. package/models/pdfviewer-context.d.ts +27 -0
  35. package/models/toolbar-tool.d.ts +8 -0
  36. package/models/zoom-level.d.ts +14 -0
  37. package/package-metadata.d.ts +9 -0
  38. package/package.json +65 -0
  39. package/pdfviewer.component.d.ts +228 -0
  40. package/pdfviewer.module.d.ts +30 -0
  41. package/progress-kendo-angular-pdfviewer.d.ts +9 -0
  42. package/schematics/collection.json +12 -0
  43. package/schematics/ngAdd/index.js +8 -0
  44. package/schematics/ngAdd/schema.json +24 -0
  45. package/toolbar/input-wrapper.component.d.ts +21 -0
  46. package/toolbar/search.component.d.ts +39 -0
  47. package/toolbar/toolbar-combobox.directive.d.ts +21 -0
  48. package/toolbar/toolbar-focusable.directive.d.ts +21 -0
  49. package/toolbar/toolbar-navigation.service.d.ts +23 -0
  50. package/toolbar/toolbar.component.d.ts +65 -0
  51. package/util.d.ts +32 -0
package/index.d.ts ADDED
@@ -0,0 +1,16 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ export { PDFViewerModule } from './pdfviewer.module';
6
+ export { PDFViewerComponent } from './pdfviewer.component';
7
+ export { ToolbarComponent } from './toolbar/toolbar.component';
8
+ export { LoaderComponent } from './loader/loader.component';
9
+ export { PDFViewerContext } from './models/pdfviewer-context';
10
+ export { PDFViewerSearchComponent } from './toolbar/search.component';
11
+ export { PDFViewerErrorEvent, PDFViewerLoadEvent, PDFViewerDownloadEvent, PDFViewerPageChangeEvent, PDFViewerZoomChangeEvent } from './models/events';
12
+ export { PDFViewerCustomMessagesComponent } from './localization/custom-messages.component';
13
+ export { LocalizedPDFViewerMessagesDirective } from './localization/localized-messages.directive';
14
+ export { ToolbarFocusableDirective } from './toolbar/toolbar-focusable.directive';
15
+ export { ToolbarInputWrapperComponent } from './toolbar/input-wrapper.component';
16
+ export { ToolbarComboBoxDirective } from './toolbar/toolbar-combobox.directive';
@@ -0,0 +1,17 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { LoaderSettings } from '../models/loader-settings';
6
+ import * as i0 from "@angular/core";
7
+ /**
8
+ * @hidden
9
+ */
10
+ export declare class LoaderComponent {
11
+ settings: LoaderSettings;
12
+ loaderContainerClass: boolean;
13
+ loaderContainerSizingClass: boolean;
14
+ loaderPositionClass: boolean;
15
+ static ɵfac: i0.ɵɵFactoryDeclaration<LoaderComponent, never>;
16
+ static ɵcmp: i0.ɵɵComponentDeclaration<LoaderComponent, "[loader]", never, { "settings": "settings"; }, {}, never, never>;
17
+ }
@@ -0,0 +1,18 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
6
+ import { Messages } from './messages';
7
+ import * as i0 from "@angular/core";
8
+ /**
9
+ * Custom component messages override default component messages
10
+ * ([see example]({% slug rtl_pdfviewer %}).
11
+ */
12
+ export declare class PDFViewerCustomMessagesComponent extends Messages {
13
+ protected service: LocalizationService;
14
+ constructor(service: LocalizationService);
15
+ protected get override(): boolean;
16
+ static ɵfac: i0.ɵɵFactoryDeclaration<PDFViewerCustomMessagesComponent, never>;
17
+ static ɵcmp: i0.ɵɵComponentDeclaration<PDFViewerCustomMessagesComponent, "kendo-pdfviewer-messages", never, {}, {}, never, never>;
18
+ }
@@ -0,0 +1,16 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
6
+ import { Messages } from './messages';
7
+ import * as i0 from "@angular/core";
8
+ /**
9
+ * @hidden
10
+ */
11
+ export declare class LocalizedPDFViewerMessagesDirective extends Messages {
12
+ protected service: LocalizationService;
13
+ constructor(service: LocalizationService);
14
+ static ɵfac: i0.ɵɵFactoryDeclaration<LocalizedPDFViewerMessagesDirective, never>;
15
+ static ɵdir: i0.ɵɵDirectiveDeclaration<LocalizedPDFViewerMessagesDirective, "[kendoPDFViewerLocalizedMessages]", never, {}, {}, never>;
16
+ }
@@ -0,0 +1,113 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { ComponentMessages } from '@progress/kendo-angular-l10n';
6
+ import * as i0 from "@angular/core";
7
+ /**
8
+ * @hidden
9
+ */
10
+ export declare class Messages extends ComponentMessages {
11
+ /**
12
+ * The ZoomIn tool title and label.
13
+ */
14
+ zoomInTitle: string;
15
+ /**
16
+ * The ZoomOut tool titla and label.
17
+ */
18
+ zoomOutTitle: string;
19
+ /**
20
+ * The Selection tool title and label.
21
+ */
22
+ selectionTitle: string;
23
+ /**
24
+ * The Panning tool title and label.
25
+ */
26
+ panningTitle: string;
27
+ /**
28
+ * The Search tool title and label.
29
+ */
30
+ searchTitle: string;
31
+ /**
32
+ * The Open tool title and label.
33
+ */
34
+ openTitle: string;
35
+ /**
36
+ * The Download tool title and label.
37
+ */
38
+ downloadTitle: string;
39
+ /**
40
+ * The Print tool title and label.
41
+ */
42
+ printTitle: string;
43
+ /**
44
+ * The `aria-label` attribute of the Pager input element.
45
+ */
46
+ pagerInputLabel: string;
47
+ /**
48
+ * The `title` attribute of the Pager input element.
49
+ */
50
+ pagerInputTitle: string;
51
+ /**
52
+ * The Pager **First page** button label.
53
+ */
54
+ pagerFirstPage: string;
55
+ /**
56
+ * The Pager **Previous page** button label.
57
+ */
58
+ pagerPreviousPage: string;
59
+ /**
60
+ * The Pager **Next page** button label.
61
+ */
62
+ pagerNextPage: string;
63
+ /**
64
+ * The Pager **Last page** button label.
65
+ */
66
+ pagerLastPage: string;
67
+ /**
68
+ * The text before the Pager total-page number.
69
+ */
70
+ pagerOf: string;
71
+ /**
72
+ * The text displayed before the Pager input.
73
+ */
74
+ pagerPage: string;
75
+ /**
76
+ * The text for the zoom level chooser Fit to page option.
77
+ */
78
+ fitToPage: string;
79
+ /**
80
+ * The text for the zoom level chooser Fit to width option.
81
+ */
82
+ fitToWidth: string;
83
+ /**
84
+ * The text for the search input placeholder.
85
+ */
86
+ searchInputPlaceholder: string;
87
+ /**
88
+ * The text before the total number of matches in the Search tool.
89
+ */
90
+ searchMatchesOf: string;
91
+ /**
92
+ * The title of the Search previous match button.
93
+ */
94
+ searchPreviousMatchTitle: string;
95
+ /**
96
+ * The title of the Search next match button.
97
+ */
98
+ searchNextMatchTitle: string;
99
+ /**
100
+ * The title of the Search close button.
101
+ */
102
+ searchCloseTitle: string;
103
+ /**
104
+ * The title of the Search match case button.
105
+ */
106
+ searchMatchCaseTitle: string;
107
+ /**
108
+ * The text for the zoom tool input placeholder.
109
+ */
110
+ zoomInputPlaceholder: string;
111
+ static ɵfac: i0.ɵɵFactoryDeclaration<Messages, never>;
112
+ static ɵdir: i0.ɵɵDirectiveDeclaration<Messages, "kendo-pdfviewer-messages-base", never, { "zoomInTitle": "zoomInTitle"; "zoomOutTitle": "zoomOutTitle"; "selectionTitle": "selectionTitle"; "panningTitle": "panningTitle"; "searchTitle": "searchTitle"; "openTitle": "openTitle"; "downloadTitle": "downloadTitle"; "printTitle": "printTitle"; "pagerInputLabel": "pagerInputLabel"; "pagerInputTitle": "pagerInputTitle"; "pagerFirstPage": "pagerFirstPage"; "pagerPreviousPage": "pagerPreviousPage"; "pagerNextPage": "pagerNextPage"; "pagerLastPage": "pagerLastPage"; "pagerOf": "pagerOf"; "pagerPage": "pagerPage"; "fitToPage": "fitToPage"; "fitToWidth": "fitToWidth"; "searchInputPlaceholder": "searchInputPlaceholder"; "searchMatchesOf": "searchMatchesOf"; "searchPreviousMatchTitle": "searchPreviousMatchTitle"; "searchNextMatchTitle": "searchNextMatchTitle"; "searchCloseTitle": "searchCloseTitle"; "searchMatchCaseTitle": "searchMatchCaseTitle"; "zoomInputPlaceholder": "zoomInputPlaceholder"; }, {}, never>;
113
+ }
@@ -0,0 +1,81 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { PreventableEvent } from "@progress/kendo-angular-common";
6
+ import { PDFViewerContext } from "./pdfviewer-context";
7
+ import { SaveOptions } from "@progress/kendo-file-saver";
8
+ /**
9
+ * Represents the event data object of the `LoadEvent`.
10
+ */
11
+ export interface PDFViewerLoadEvent {
12
+ /**
13
+ * Represents the currently loaded `PDF.js` document, its pages, and their DOM element wrapper.
14
+ */
15
+ context: PDFViewerContext;
16
+ }
17
+ /**
18
+ * Represents the event data object of the `ErrorEvent`.
19
+ */
20
+ export interface PDFViewerErrorEvent {
21
+ /**
22
+ * Represents the original Error object, related to the triggered event.
23
+ */
24
+ error: Error;
25
+ /**
26
+ * Represents the currently loaded `PDF.js` document, its pages, and their DOM element wrapper.
27
+ */
28
+ context: PDFViewerContext;
29
+ }
30
+ /**
31
+ * Arguments for the `download` event. The event fires when the end user clicks the Download tool.
32
+ * If you cancel the event, the downloading of the file is prevented.
33
+ */
34
+ export declare class PDFViewerDownloadEvent extends PreventableEvent {
35
+ /**
36
+ * The Blob object.
37
+ */
38
+ readonly blob: Blob;
39
+ /**
40
+ * The name which will be used for saving the file.
41
+ */
42
+ readonly fileName: string;
43
+ /**
44
+ * The options which will be used for saving the file.
45
+ */
46
+ readonly saveOptions: SaveOptions;
47
+ /**
48
+ * Represents the currently loaded `PDF.js` document, its pages, and their DOM element wrapper.
49
+ */
50
+ readonly context: PDFViewerContext;
51
+ /**
52
+ * @hidden
53
+ */
54
+ constructor(blob: Blob, fileName: string, saveOptions: SaveOptions, context: PDFViewerContext);
55
+ }
56
+ /**
57
+ * Represents the data object of the `PDFViewerPageChangeEvent`
58
+ */
59
+ export interface PDFViewerPageChangeEvent {
60
+ /**
61
+ * The active PDF page prior to triggering of the event.
62
+ */
63
+ previousPage: number;
64
+ /**
65
+ * The current active PDF page after triggering of the event.
66
+ */
67
+ currentPage: number;
68
+ }
69
+ /**
70
+ * Represents the data object of the `PDFViewerZoomChangeEvent`
71
+ */
72
+ export interface PDFViewerZoomChangeEvent {
73
+ /**
74
+ * The applied PDF zoom level before it was changed by the user.
75
+ */
76
+ previousZoomLevel: number;
77
+ /**
78
+ * The current applied PDF zoom level after it was changed by the user.
79
+ */
80
+ currentZoomLevel: number;
81
+ }
@@ -0,0 +1,48 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { LoaderSize, LoaderThemeColor, LoaderType } from "@progress/kendo-angular-indicators";
6
+ /**
7
+ * The configuration of the Loader component that is displayed while loading a PDF document.
8
+ */
9
+ export interface LoaderSettings {
10
+ /**
11
+ * Specifies the size of the Loader.
12
+ *
13
+ * The possible values are:
14
+ * * `small`
15
+ * * `medium` (Default)
16
+ * * `large`
17
+ *
18
+ */
19
+ size: LoaderSize;
20
+ /**
21
+ * Specifies the Loader animation type.
22
+ *
23
+ * The possible values are:
24
+ * - `pulsing` (default)
25
+ * - `infinite-spinner`
26
+ * - `converging-spinner`
27
+ *
28
+ */
29
+ type: LoaderType;
30
+ /**
31
+ * Specifies the theme color of the Loader.
32
+ * ([see example]({% slug appearance_loader %}#toc-theme-color)).
33
+ *
34
+ * The possible values are:
35
+ * * `primary` (Default)&mdash;Applies coloring based on primary theme color.
36
+ * * `secondary`&mdash;Applies coloring based on secondary theme color.
37
+ * * `tertiary`&mdash; Applies coloring based on tertiary theme color.
38
+ * * `info`&mdash;Applies coloring based on info theme color.
39
+ * * `success`&mdash; Applies coloring based on success theme color.
40
+ * * `warning`&mdash; Applies coloring based on warning theme color.
41
+ * * `error`&mdash; Applies coloring based on error theme color.
42
+ * * `dark`&mdash; Applies coloring based on dark theme color.
43
+ * * `light`&mdash; Applies coloring based on light theme color.
44
+ * * `inverse`&mdash; Applies coloring based on inverted theme color.
45
+ *
46
+ */
47
+ themeColor: LoaderThemeColor;
48
+ }
@@ -0,0 +1,27 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { PDFDocumentProxy } from "@progress/kendo-pdfviewer-common";
6
+ import { PDFPageProxy } from 'pdfjs-dist';
7
+ /**
8
+ * Represents the currently loaded `PDF.js` document, its pages, and their DOM element wrapper.
9
+ */
10
+ export interface PDFViewerContext {
11
+ /**
12
+ * The `PDF.js` document loaded in the PDFViewer component.
13
+ */
14
+ pdfDoc: PDFDocumentProxy;
15
+ /**
16
+ * The root DOM element wrapper of the PDF document.
17
+ */
18
+ element: HTMLDivElement;
19
+ /**
20
+ * The separate `PDF.js` pages loaded in the PDFViewer component.
21
+ */
22
+ pdfPages: PDFPageProxy[];
23
+ /**
24
+ * The current zoom level of the PDF document.
25
+ */
26
+ zoom: number;
27
+ }
@@ -0,0 +1,8 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ /**
6
+ * Represents the possible types of Toolbar tools.
7
+ */
8
+ export declare type PDFViewerTool = 'pager' | 'spacer' | 'zoomInOut' | 'zoom' | 'selection' | 'search' | 'open' | 'download' | 'print';
@@ -0,0 +1,14 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ /**
6
+ * @hidden
7
+ */
8
+ export interface ZoomLevel {
9
+ id?: number;
10
+ text?: string;
11
+ displayValue?: string;
12
+ type?: string;
13
+ value?: number;
14
+ }
@@ -0,0 +1,9 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { PackageMetadata } from '@progress/kendo-licensing';
6
+ /**
7
+ * @hidden
8
+ */
9
+ export declare const packageMetadata: PackageMetadata;
package/package.json ADDED
@@ -0,0 +1,65 @@
1
+ {
2
+ "name": "@progress/kendo-angular-pdfviewer",
3
+ "version": "13.0.0-develop.10",
4
+ "description": "Kendo UI PDFViewer for Angular",
5
+ "license": "SEE LICENSE IN LICENSE.md",
6
+ "author": "Progress",
7
+ "homepage": "https://www.telerik.com/kendo-angular-ui/components/",
8
+ "bugs": {
9
+ "url": "https://github.com/telerik/kendo-angular"
10
+ },
11
+ "keywords": [
12
+ "Angular",
13
+ "Kendo UI",
14
+ "Pdfviewer",
15
+ "Progress"
16
+ ],
17
+ "@progress": {
18
+ "friendlyName": "Pdfviewer"
19
+ },
20
+ "peerDependencies": {
21
+ "@angular/animations": "13 - 16",
22
+ "@angular/common": "13 - 16",
23
+ "@angular/core": "13 - 16",
24
+ "@angular/platform-browser": "13 - 16",
25
+ "@progress/kendo-licensing": "^1.0.2",
26
+ "@progress/kendo-angular-buttons": "13.0.0-develop.10",
27
+ "@progress/kendo-angular-common": "13.0.0-develop.10",
28
+ "@progress/kendo-angular-dropdowns": "13.0.0-develop.10",
29
+ "@progress/kendo-angular-inputs": "13.0.0-develop.10",
30
+ "@progress/kendo-angular-intl": "13.0.0-develop.10",
31
+ "@progress/kendo-angular-l10n": "13.0.0-develop.10",
32
+ "@progress/kendo-angular-icons": "13.0.0-develop.10",
33
+ "@progress/kendo-angular-indicators": "13.0.0-develop.10",
34
+ "@progress/kendo-angular-pager": "13.0.0-develop.10",
35
+ "@progress/kendo-angular-popup": "13.0.0-develop.10",
36
+ "@progress/kendo-angular-schematics": "13.0.0-develop.10",
37
+ "rxjs": "^6.5.3 || ^7.0.0"
38
+ },
39
+ "dependencies": {
40
+ "tslib": "^2.3.1",
41
+ "@progress/kendo-angular-schematics": "13.0.0-develop.10",
42
+ "@progress/kendo-pdfviewer-common": "0.1.1"
43
+ },
44
+ "schematics": "./schematics/collection.json",
45
+ "module": "fesm2015/progress-kendo-angular-pdfviewer.mjs",
46
+ "es2020": "fesm2020/progress-kendo-angular-pdfviewer.mjs",
47
+ "esm2020": "esm2020/progress-kendo-angular-pdfviewer.mjs",
48
+ "fesm2020": "fesm2020/progress-kendo-angular-pdfviewer.mjs",
49
+ "fesm2015": "fesm2015/progress-kendo-angular-pdfviewer.mjs",
50
+ "typings": "progress-kendo-angular-pdfviewer.d.ts",
51
+ "exports": {
52
+ "./package.json": {
53
+ "default": "./package.json"
54
+ },
55
+ ".": {
56
+ "types": "./progress-kendo-angular-pdfviewer.d.ts",
57
+ "esm2020": "./esm2020/progress-kendo-angular-pdfviewer.mjs",
58
+ "es2020": "./fesm2020/progress-kendo-angular-pdfviewer.mjs",
59
+ "es2015": "./fesm2015/progress-kendo-angular-pdfviewer.mjs",
60
+ "node": "./fesm2015/progress-kendo-angular-pdfviewer.mjs",
61
+ "default": "./fesm2020/progress-kendo-angular-pdfviewer.mjs"
62
+ }
63
+ },
64
+ "sideEffects": false
65
+ }
@@ -0,0 +1,228 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2023 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { AfterViewInit, EventEmitter, NgZone, OnDestroy, OnInit, Renderer2, SimpleChanges } from '@angular/core';
6
+ import { LoaderSettings } from './models/loader-settings';
7
+ import { TypedArray } from '@progress/kendo-pdfviewer-common';
8
+ import { PDFViewerContext } from './models/pdfviewer-context';
9
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
10
+ import { PDFViewerDownloadEvent, PDFViewerErrorEvent, PDFViewerLoadEvent, PDFViewerPageChangeEvent, PDFViewerZoomChangeEvent } from './models/events';
11
+ import { SaveOptions } from '@progress/kendo-file-saver';
12
+ import { PageChangeEvent } from '@progress/kendo-angular-pager';
13
+ import { ZoomLevel } from './models/zoom-level';
14
+ import { PDFViewerTool } from './models/toolbar-tool';
15
+ import { ToolbarComponent } from './toolbar/toolbar.component';
16
+ import 'pdfjs-dist/build/pdf.worker.entry';
17
+ import * as i0 from "@angular/core";
18
+ /**
19
+ * Represents the [Kendo UI PDFViewer component for Angular]({% slug overview_pdfviewer %}).
20
+ */
21
+ export declare class PDFViewerComponent implements OnInit, AfterViewInit, OnDestroy {
22
+ private ngZone;
23
+ private renderer;
24
+ private localizationService;
25
+ hostClass: boolean;
26
+ direction: string;
27
+ /**
28
+ * Represents the tools collection rendered in the toolbar.
29
+ * @default ['pager', 'spacer', 'zoomInOut', 'zoom', 'selection', 'spacer', 'search', 'open', 'download', 'print' ]
30
+ */
31
+ tools: PDFViewerTool[];
32
+ /**
33
+ * The configuration of the internal Loader component.
34
+ * @default { size: 'large', type: 'pulsing', themeColor: 'primary' }
35
+ */
36
+ loaderSettings: LoaderSettings;
37
+ /**
38
+ * The name of the file that will be saved when the end user clicks the Download tool.
39
+ * @default 'Download'
40
+ */
41
+ saveFileName: string;
42
+ /**
43
+ * Represents the options for saving the file when the end user clicks the Download tool.
44
+ * @default {}
45
+ */
46
+ saveOptions: SaveOptions;
47
+ /**
48
+ * Represents the url of the PDF file.
49
+ */
50
+ url: string | undefined;
51
+ /**
52
+ * Represents the data of the PDF file in [Base64 format](https://developer.mozilla.org/en-US/docs/Glossary/Base64).
53
+ */
54
+ data: string | undefined;
55
+ /**
56
+ * Represents the raw [binary data buffer](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer) of the PDF file.
57
+ */
58
+ arrayBuffer: ArrayBuffer | undefined;
59
+ /**
60
+ * Represents the data of the PDF file in [`TypedArray`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray) format.
61
+ */
62
+ typedArray: TypedArray | undefined;
63
+ /**
64
+ * The initial zoom level of the PDF document.
65
+ *
66
+ * @default 1.25
67
+ */
68
+ zoom: number;
69
+ /**
70
+ * Represents the step the zoom level will be changed with when using the ZoomIn and ZoomOut tools.
71
+ * @default 0.25
72
+ */
73
+ zoomRate: number;
74
+ /**
75
+ * Represents minimum allowed zoom value.
76
+ * @default 0.5
77
+ */
78
+ minZoom: number;
79
+ /**
80
+ * Represents maximum allowed zoom value.
81
+ * @default 4
82
+ */
83
+ maxZoom: number;
84
+ /**
85
+ * The event fired when a PDF document is successfully loaded in the `PDFViewer` component.
86
+ */
87
+ load: EventEmitter<PDFViewerLoadEvent>;
88
+ /**
89
+ * The event fired when an error occurs during the loading or downloading of the PDF document.
90
+ */
91
+ error: EventEmitter<PDFViewerErrorEvent>;
92
+ /**
93
+ * The event fired when an error occurs during the loading of the PDF document.
94
+ */
95
+ download: EventEmitter<PDFViewerDownloadEvent>;
96
+ /**
97
+ * The event fired when the end user changes the page of the loaded PDF document.
98
+ */
99
+ pageChange: EventEmitter<PDFViewerPageChangeEvent>;
100
+ /**
101
+ * The event fired when the end user changes the zoom level of the loaded PDF document.
102
+ */
103
+ zoomLevelChange: EventEmitter<PDFViewerZoomChangeEvent>;
104
+ private pagesContainer;
105
+ /**
106
+ * Returns the current page number of the loaded PDF document.
107
+ */
108
+ get currentPage(): number;
109
+ set pdfContext(doc: PDFViewerContext);
110
+ /**
111
+ * Exposes the currently loaded `PDF.js` document, its pages, and their DOM element wrapper.
112
+ */
113
+ get pdfContext(): PDFViewerContext;
114
+ /**
115
+ * @hidden
116
+ */
117
+ get activePageId(): string;
118
+ /**
119
+ * @hidden
120
+ */
121
+ get pagesContainerId(): string;
122
+ loading: boolean;
123
+ searchActive: boolean;
124
+ matchCase: boolean;
125
+ currentMatches: any[];
126
+ currentMatch: number;
127
+ /**
128
+ * @hidden
129
+ */
130
+ set enabledSelection(value: boolean);
131
+ /**
132
+ * @hidden
133
+ */
134
+ get enabledSelection(): boolean;
135
+ skip: number;
136
+ zoomOptionsData: ({
137
+ id: number;
138
+ text: string;
139
+ type: string;
140
+ displayValue: string;
141
+ value: number;
142
+ } | {
143
+ id: number;
144
+ text: string;
145
+ displayValue: string;
146
+ value: number;
147
+ type?: undefined;
148
+ })[];
149
+ zoomLevel: ZoomLevel;
150
+ private _pdfContext;
151
+ private _enabedSelection;
152
+ private pdfScroller;
153
+ private searchService;
154
+ private subs;
155
+ constructor(ngZone: NgZone, renderer: Renderer2, localizationService: LocalizationService);
156
+ ngOnInit(): void;
157
+ ngAfterViewInit(): void;
158
+ ngOnDestroy(): void;
159
+ ngOnChanges(changes: SimpleChanges): void;
160
+ /**
161
+ * Scrolls the PDFViewer document to the passed page number.
162
+ */
163
+ scrollToPage(page: number): void;
164
+ /**
165
+ * @hidden
166
+ */
167
+ onFileSelect(e: string | ArrayBuffer): void;
168
+ /**
169
+ * @hidden
170
+ */
171
+ onFileSelectError(e: any): void;
172
+ /**
173
+ * @hidden
174
+ */
175
+ onPageChange(e: PageChangeEvent): void;
176
+ /**
177
+ * @hidden
178
+ */
179
+ onDownload(): void;
180
+ /**
181
+ * @hidden
182
+ */
183
+ onZoomIn(): void;
184
+ /**
185
+ * @hidden
186
+ */
187
+ onZoomOut(): void;
188
+ /**
189
+ * @hidden
190
+ */
191
+ onZoomLevelChange(zoomLevel: ZoomLevel | string): void;
192
+ /**
193
+ * @hidden
194
+ */
195
+ onSearch(): void;
196
+ /**
197
+ * @hidden
198
+ */
199
+ onPrint(): void;
200
+ /**
201
+ * @hidden
202
+ */
203
+ onSearchChange(e: {
204
+ text: string;
205
+ matchCase: boolean;
206
+ }): void;
207
+ /**
208
+ * @hidden
209
+ */
210
+ closeSearch(toolbar: ToolbarComponent): void;
211
+ /**
212
+ * @hidden
213
+ */
214
+ onNextMatch(): void;
215
+ /**
216
+ * @hidden
217
+ */
218
+ onPreviousMatch(): void;
219
+ private loadPdf;
220
+ private reloadDocument;
221
+ private assignPageIds;
222
+ private setZoomLevel;
223
+ private verifySettings;
224
+ private isSet;
225
+ private scrollListener;
226
+ static ɵfac: i0.ɵɵFactoryDeclaration<PDFViewerComponent, never>;
227
+ static ɵcmp: i0.ɵɵComponentDeclaration<PDFViewerComponent, "kendo-pdfviewer", ["kendo-pdfviewer"], { "tools": "tools"; "loaderSettings": "loaderSettings"; "saveFileName": "saveFileName"; "saveOptions": "saveOptions"; "url": "url"; "data": "data"; "arrayBuffer": "arrayBuffer"; "typedArray": "typedArray"; "zoom": "zoom"; "zoomRate": "zoomRate"; "minZoom": "minZoom"; "maxZoom": "maxZoom"; }, { "load": "load"; "error": "error"; "download": "download"; "pageChange": "pageChange"; "zoomLevelChange": "zoomLevelChange"; }, never, never>;
228
+ }