@pdftools/four-heights-pdf-web-viewer 4.3.6
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.
- package/LICENSE.md +446 -0
- package/README.md +145 -0
- package/css/pdf-web-viewer.css +2407 -0
- package/doc/PdfWebViewer.pdf +0 -0
- package/es6/common/Checkbox.d.ts +9 -0
- package/es6/common/Checkbox.js +8 -0
- package/es6/common/Color.d.ts +23 -0
- package/es6/common/Color.js +118 -0
- package/es6/common/ColorPicker.d.ts +15 -0
- package/es6/common/ColorPicker.js +46 -0
- package/es6/common/Contextbar.d.ts +6 -0
- package/es6/common/Contextbar.js +19 -0
- package/es6/common/DragMoveHandler.d.ts +51 -0
- package/es6/common/DragMoveHandler.js +175 -0
- package/es6/common/Dropdown.d.ts +36 -0
- package/es6/common/Dropdown.js +76 -0
- package/es6/common/DropdownMenu.d.ts +9 -0
- package/es6/common/DropdownMenu.js +10 -0
- package/es6/common/DropdownSeparator.d.ts +3 -0
- package/es6/common/DropdownSeparator.js +6 -0
- package/es6/common/Icon.d.ts +13 -0
- package/es6/common/Icon.js +8 -0
- package/es6/common/Loader.d.ts +3 -0
- package/es6/common/Loader.js +6 -0
- package/es6/common/RangeSlider.d.ts +17 -0
- package/es6/common/RangeSlider.js +42 -0
- package/es6/common/StrokeStylePicker.d.ts +11 -0
- package/es6/common/StrokeStylePicker.js +20 -0
- package/es6/common/StrokeWidthPicker.d.ts +11 -0
- package/es6/common/StrokeWidthPicker.js +20 -0
- package/es6/common/Toolbar.d.ts +10 -0
- package/es6/common/Toolbar.js +6 -0
- package/es6/common/ToolbarButton.d.ts +14 -0
- package/es6/common/ToolbarButton.js +21 -0
- package/es6/common/ToolbarFileButton.d.ts +15 -0
- package/es6/common/ToolbarFileButton.js +27 -0
- package/es6/common/ToolbarItemGroup.d.ts +8 -0
- package/es6/common/ToolbarItemGroup.js +12 -0
- package/es6/common/ToolbarSeparator.d.ts +3 -0
- package/es6/common/ToolbarSeparator.js +6 -0
- package/es6/common/Tools.d.ts +10 -0
- package/es6/common/Tools.js +89 -0
- package/es6/common/TooltipManager.d.ts +12 -0
- package/es6/common/TooltipManager.js +54 -0
- package/es6/common/TranslationManager.d.ts +11 -0
- package/es6/common/TranslationManager.js +61 -0
- package/es6/common/classNames.d.ts +2 -0
- package/es6/common/classNames.js +18 -0
- package/es6/common/formatDate.d.ts +1 -0
- package/es6/common/formatDate.js +1 -0
- package/es6/common/icons.d.ts +13 -0
- package/es6/common/icons.js +412 -0
- package/es6/common/utils.d.ts +2 -0
- package/es6/common/utils.js +19 -0
- package/es6/custom/history.d.ts +2 -0
- package/es6/custom/history.js +59 -0
- package/es6/index.d.ts +5 -0
- package/es6/index.js +5 -0
- package/es6/lib/hyperapp/index.d.ts +108 -0
- package/es6/lib/hyperapp/index.js +327 -0
- package/es6/modules/CanvasLayer.d.ts +32 -0
- package/es6/modules/CanvasLayer.js +83 -0
- package/es6/modules/CanvasModule.d.ts +59 -0
- package/es6/modules/CanvasModule.js +98 -0
- package/es6/modules/eraser/EraserLayer.d.ts +13 -0
- package/es6/modules/eraser/EraserLayer.js +141 -0
- package/es6/modules/eraser/EraserModule.d.ts +19 -0
- package/es6/modules/eraser/EraserModule.js +34 -0
- package/es6/modules/eraser/EraserToolbar.d.ts +10 -0
- package/es6/modules/eraser/EraserToolbar.js +30 -0
- package/es6/modules/form-fields/CheckBoxWidget.d.ts +9 -0
- package/es6/modules/form-fields/CheckBoxWidget.js +45 -0
- package/es6/modules/form-fields/ComboBoxWidget.d.ts +22 -0
- package/es6/modules/form-fields/ComboBoxWidget.js +152 -0
- package/es6/modules/form-fields/EditFormFieldLayer.d.ts +17 -0
- package/es6/modules/form-fields/EditFormFieldLayer.js +238 -0
- package/es6/modules/form-fields/FormFieldModule.d.ts +15 -0
- package/es6/modules/form-fields/FormFieldModule.js +27 -0
- package/es6/modules/form-fields/ListBoxWidget.d.ts +9 -0
- package/es6/modules/form-fields/ListBoxWidget.js +73 -0
- package/es6/modules/form-fields/RadioButtonWidget.d.ts +9 -0
- package/es6/modules/form-fields/RadioButtonWidget.js +45 -0
- package/es6/modules/form-fields/SelectListWidget.d.ts +9 -0
- package/es6/modules/form-fields/SelectListWidget.js +45 -0
- package/es6/modules/form-fields/TextBoxWidget.d.ts +9 -0
- package/es6/modules/form-fields/TextBoxWidget.js +53 -0
- package/es6/modules/form-fields/WidgetBase.d.ts +23 -0
- package/es6/modules/form-fields/WidgetBase.js +29 -0
- package/es6/modules/freetext-annotation/AddFreetextAnnotationLayer.d.ts +19 -0
- package/es6/modules/freetext-annotation/AddFreetextAnnotationLayer.js +181 -0
- package/es6/modules/freetext-annotation/AddFreetextAnnotationToolbar.d.ts +21 -0
- package/es6/modules/freetext-annotation/AddFreetextAnnotationToolbar.js +37 -0
- package/es6/modules/freetext-annotation/EditFreetextAnnotationLayer.d.ts +20 -0
- package/es6/modules/freetext-annotation/EditFreetextAnnotationLayer.js +211 -0
- package/es6/modules/freetext-annotation/EditFreetextAnnotationToolbar.d.ts +50 -0
- package/es6/modules/freetext-annotation/EditFreetextAnnotationToolbar.js +118 -0
- package/es6/modules/freetext-annotation/FreetextAnnotationModule.d.ts +28 -0
- package/es6/modules/freetext-annotation/FreetextAnnotationModule.js +58 -0
- package/es6/modules/freetext-annotation/RichTextEditor.d.ts +31 -0
- package/es6/modules/freetext-annotation/RichTextEditor.js +223 -0
- package/es6/modules/highlight-annotation/AddHighlightAnnotationLayer.d.ts +31 -0
- package/es6/modules/highlight-annotation/AddHighlightAnnotationLayer.js +289 -0
- package/es6/modules/highlight-annotation/AddHighlightAnnotationToolbar.d.ts +20 -0
- package/es6/modules/highlight-annotation/AddHighlightAnnotationToolbar.js +52 -0
- package/es6/modules/highlight-annotation/EditHighlightAnnotationLayer.d.ts +15 -0
- package/es6/modules/highlight-annotation/EditHighlightAnnotationLayer.js +104 -0
- package/es6/modules/highlight-annotation/EditHighlightAnnotationToolbar.d.ts +15 -0
- package/es6/modules/highlight-annotation/EditHighlightAnnotationToolbar.js +28 -0
- package/es6/modules/highlight-annotation/HighlightAnnotationModule.d.ts +27 -0
- package/es6/modules/highlight-annotation/HighlightAnnotationModule.js +54 -0
- package/es6/modules/image-annotations/ImageAnnotationModule.d.ts +23 -0
- package/es6/modules/image-annotations/ImageAnnotationModule.js +169 -0
- package/es6/modules/index.d.ts +13 -0
- package/es6/modules/index.js +13 -0
- package/es6/modules/ink-annotation/AddInkAnnotationLayer.d.ts +40 -0
- package/es6/modules/ink-annotation/AddInkAnnotationLayer.js +503 -0
- package/es6/modules/ink-annotation/AddInkAnnotationToolbar.d.ts +30 -0
- package/es6/modules/ink-annotation/AddInkAnnotationToolbar.js +53 -0
- package/es6/modules/ink-annotation/EditInkAnnotationLayer.d.ts +20 -0
- package/es6/modules/ink-annotation/EditInkAnnotationLayer.js +137 -0
- package/es6/modules/ink-annotation/EditInkAnnotationToolbar.d.ts +25 -0
- package/es6/modules/ink-annotation/EditInkAnnotationToolbar.js +47 -0
- package/es6/modules/ink-annotation/InkAnnotationModule.d.ts +27 -0
- package/es6/modules/ink-annotation/InkAnnotationModule.js +50 -0
- package/es6/modules/popup/Popup.d.ts +64 -0
- package/es6/modules/popup/Popup.js +360 -0
- package/es6/modules/popup/PopupLayer.d.ts +31 -0
- package/es6/modules/popup/PopupLayer.js +509 -0
- package/es6/modules/popup/PopupModule.d.ts +16 -0
- package/es6/modules/popup/PopupModule.js +25 -0
- package/es6/modules/print-service/PrintServiceDialog.d.ts +30 -0
- package/es6/modules/print-service/PrintServiceDialog.js +134 -0
- package/es6/modules/print-service/PrintServiceLayer.d.ts +24 -0
- package/es6/modules/print-service/PrintServiceLayer.js +310 -0
- package/es6/modules/print-service/PrintServiceModule.d.ts +18 -0
- package/es6/modules/print-service/PrintServiceModule.js +30 -0
- package/es6/modules/shape-annotations/AddShapeAnnotationLayer.d.ts +24 -0
- package/es6/modules/shape-annotations/AddShapeAnnotationLayer.js +210 -0
- package/es6/modules/shape-annotations/AddShapeAnnotationToolbar.d.ts +26 -0
- package/es6/modules/shape-annotations/AddShapeAnnotationToolbar.js +69 -0
- package/es6/modules/shape-annotations/EditShapeAnnotationLayer.d.ts +19 -0
- package/es6/modules/shape-annotations/EditShapeAnnotationLayer.js +148 -0
- package/es6/modules/shape-annotations/EditShapeAnnotationToolbar.d.ts +24 -0
- package/es6/modules/shape-annotations/EditShapeAnnotationToolbar.js +57 -0
- package/es6/modules/shape-annotations/ShapeAnnotationModule.d.ts +28 -0
- package/es6/modules/shape-annotations/ShapeAnnotationModule.js +50 -0
- package/es6/modules/stamp-annotation/AddStampAnnotationLayer.d.ts +19 -0
- package/es6/modules/stamp-annotation/AddStampAnnotationLayer.js +257 -0
- package/es6/modules/stamp-annotation/AddStampAnnotationToolbar.d.ts +17 -0
- package/es6/modules/stamp-annotation/AddStampAnnotationToolbar.js +68 -0
- package/es6/modules/stamp-annotation/StampAnnotationModule.d.ts +20 -0
- package/es6/modules/stamp-annotation/StampAnnotationModule.js +35 -0
- package/es6/modules/text-annotation/AddTextAnnotationLayer.d.ts +14 -0
- package/es6/modules/text-annotation/AddTextAnnotationLayer.js +132 -0
- package/es6/modules/text-annotation/AddTextAnnotationToolbar.d.ts +15 -0
- package/es6/modules/text-annotation/AddTextAnnotationToolbar.js +27 -0
- package/es6/modules/text-annotation/TextAnnotationModule.d.ts +19 -0
- package/es6/modules/text-annotation/TextAnnotationModule.js +34 -0
- package/es6/pdf-viewer-api/ImageContainer.d.ts +10 -0
- package/es6/pdf-viewer-api/ImageContainer.js +43 -0
- package/es6/pdf-viewer-api/PdfViewerApi.d.ts +463 -0
- package/es6/pdf-viewer-api/PdfViewerApi.js +732 -0
- package/es6/pdf-viewer-api/PdfViewingWrapper.d.ts +178 -0
- package/es6/pdf-viewer-api/PdfViewingWrapper.js +2037 -0
- package/es6/pdf-viewer-api/annotationDefaultBehaviors.d.ts +3 -0
- package/es6/pdf-viewer-api/annotationDefaultBehaviors.js +30 -0
- package/es6/pdf-viewer-api/enums.d.ts +100 -0
- package/es6/pdf-viewer-api/enums.js +113 -0
- package/es6/pdf-viewer-api/index.d.ts +3 -0
- package/es6/pdf-viewer-api/index.js +3 -0
- package/es6/pdf-viewer-api/types.d.ts +284 -0
- package/es6/pdf-viewer-api/types.js +6 -0
- package/es6/pdf-viewer-canvas/CanvasEvents.d.ts +76 -0
- package/es6/pdf-viewer-canvas/CanvasEvents.js +345 -0
- package/es6/pdf-viewer-canvas/PdfViewerCanvas.d.ts +175 -0
- package/es6/pdf-viewer-canvas/PdfViewerCanvas.js +1226 -0
- package/es6/pdf-viewer-canvas/state/annotations.d.ts +36 -0
- package/es6/pdf-viewer-canvas/state/annotations.js +157 -0
- package/es6/pdf-viewer-canvas/state/appState.d.ts +10 -0
- package/es6/pdf-viewer-canvas/state/appState.js +60 -0
- package/es6/pdf-viewer-canvas/state/canvas.d.ts +31 -0
- package/es6/pdf-viewer-canvas/state/canvas.js +41 -0
- package/es6/pdf-viewer-canvas/state/document.d.ts +50 -0
- package/es6/pdf-viewer-canvas/state/document.js +99 -0
- package/es6/pdf-viewer-canvas/state/pointer.d.ts +31 -0
- package/es6/pdf-viewer-canvas/state/pointer.js +31 -0
- package/es6/pdf-viewer-canvas/state/scroll.d.ts +22 -0
- package/es6/pdf-viewer-canvas/state/scroll.js +25 -0
- package/es6/pdf-viewer-canvas/state/search.d.ts +36 -0
- package/es6/pdf-viewer-canvas/state/search.js +27 -0
- package/es6/pdf-viewer-canvas/state/store.d.ts +39 -0
- package/es6/pdf-viewer-canvas/state/store.js +52 -0
- package/es6/pdf-viewer-canvas/state/viewer.d.ts +91 -0
- package/es6/pdf-viewer-canvas/state/viewer.js +175 -0
- package/es6/pdf-viewer-canvas/view-layers/AnnotationSelectionLayer.d.ts +28 -0
- package/es6/pdf-viewer-canvas/view-layers/AnnotationSelectionLayer.js +452 -0
- package/es6/pdf-viewer-canvas/view-layers/BusyStateLayer.d.ts +9 -0
- package/es6/pdf-viewer-canvas/view-layers/BusyStateLayer.js +25 -0
- package/es6/pdf-viewer-canvas/view-layers/PdfDocumentLayer.d.ts +10 -0
- package/es6/pdf-viewer-canvas/view-layers/PdfDocumentLayer.js +149 -0
- package/es6/pdf-viewer-canvas/view-layers/ScrollLayer.d.ts +48 -0
- package/es6/pdf-viewer-canvas/view-layers/ScrollLayer.js +308 -0
- package/es6/pdf-viewer-canvas/view-layers/TextSelectionLayer.d.ts +19 -0
- package/es6/pdf-viewer-canvas/view-layers/TextSelectionLayer.js +289 -0
- package/es6/pdf-viewer-canvas/view-layers/ViewLayerBase.d.ts +31 -0
- package/es6/pdf-viewer-canvas/view-layers/ViewLayerBase.js +106 -0
- package/es6/pdf-viewer-canvas/view-layers/canvasShapes.d.ts +11 -0
- package/es6/pdf-viewer-canvas/view-layers/canvasShapes.js +149 -0
- package/es6/pdf-viewer-canvas/view-layers/canvasUtlis.d.ts +3 -0
- package/es6/pdf-viewer-canvas/view-layers/canvasUtlis.js +10 -0
- package/es6/pdf-viewer-canvas/view-layers/views/AnnotationBorder.d.ts +52 -0
- package/es6/pdf-viewer-canvas/view-layers/views/AnnotationBorder.js +377 -0
- package/es6/pdf-viewer-canvas/view-layers/views/AnnotationContextBar.d.ts +47 -0
- package/es6/pdf-viewer-canvas/view-layers/views/AnnotationContextBar.js +102 -0
- package/es6/pdf-viewer-canvas/view-layers/views/TextSelectionContextBar.d.ts +14 -0
- package/es6/pdf-viewer-canvas/view-layers/views/TextSelectionContextBar.js +36 -0
- package/es6/pdf-viewing/PdfViewing.d.ts +4865 -0
- package/es6/pdf-viewing/PdfViewing.js +9611 -0
- package/es6/pdf-web-viewer/PdfWebViewer.d.ts +372 -0
- package/es6/pdf-web-viewer/PdfWebViewer.js +1386 -0
- package/es6/pdf-web-viewer/UserSettings.d.ts +8 -0
- package/es6/pdf-web-viewer/UserSettings.js +40 -0
- package/es6/pdf-web-viewer/WebViewerOptions.d.ts +387 -0
- package/es6/pdf-web-viewer/WebViewerOptions.js +582 -0
- package/es6/pdf-web-viewer/state/index.d.ts +80 -0
- package/es6/pdf-web-viewer/state/index.js +98 -0
- package/es6/pdf-web-viewer/state/layout.d.ts +24 -0
- package/es6/pdf-web-viewer/state/layout.js +21 -0
- package/es6/pdf-web-viewer/state/mobile.d.ts +16 -0
- package/es6/pdf-web-viewer/state/mobile.js +11 -0
- package/es6/pdf-web-viewer/state/navigationPanel.d.ts +61 -0
- package/es6/pdf-web-viewer/state/navigationPanel.js +84 -0
- package/es6/pdf-web-viewer/state/passwordForm.d.ts +18 -0
- package/es6/pdf-web-viewer/state/passwordForm.js +21 -0
- package/es6/pdf-web-viewer/state/pdfDocument.d.ts +31 -0
- package/es6/pdf-web-viewer/state/pdfDocument.js +41 -0
- package/es6/pdf-web-viewer/state/search.d.ts +29 -0
- package/es6/pdf-web-viewer/state/search.js +23 -0
- package/es6/pdf-web-viewer/views/App.d.ts +4 -0
- package/es6/pdf-web-viewer/views/App.js +19 -0
- package/es6/pdf-web-viewer/views/CustomButtons.d.ts +9 -0
- package/es6/pdf-web-viewer/views/CustomButtons.js +18 -0
- package/es6/pdf-web-viewer/views/DropZone.d.ts +9 -0
- package/es6/pdf-web-viewer/views/DropZone.js +53 -0
- package/es6/pdf-web-viewer/views/Layout.d.ts +4 -0
- package/es6/pdf-web-viewer/views/Layout.js +22 -0
- package/es6/pdf-web-viewer/views/annotationbar/Annotationbar.d.ts +4 -0
- package/es6/pdf-web-viewer/views/annotationbar/Annotationbar.js +21 -0
- package/es6/pdf-web-viewer/views/appbar/AddonsToolbar.d.ts +4 -0
- package/es6/pdf-web-viewer/views/appbar/AddonsToolbar.js +35 -0
- package/es6/pdf-web-viewer/views/appbar/AnnotationsMenu.d.ts +4 -0
- package/es6/pdf-web-viewer/views/appbar/AnnotationsMenu.js +22 -0
- package/es6/pdf-web-viewer/views/appbar/AppBar.d.ts +4 -0
- package/es6/pdf-web-viewer/views/appbar/AppBar.js +26 -0
- package/es6/pdf-web-viewer/views/appbar/DocumentBar.d.ts +4 -0
- package/es6/pdf-web-viewer/views/appbar/DocumentBar.js +36 -0
- package/es6/pdf-web-viewer/views/appbar/Menu.d.ts +4 -0
- package/es6/pdf-web-viewer/views/appbar/Menu.js +80 -0
- package/es6/pdf-web-viewer/views/appbar/NavigationBar.d.ts +4 -0
- package/es6/pdf-web-viewer/views/appbar/NavigationBar.js +74 -0
- package/es6/pdf-web-viewer/views/appbar/SearchBar.d.ts +4 -0
- package/es6/pdf-web-viewer/views/appbar/SearchBar.js +83 -0
- package/es6/pdf-web-viewer/views/appbar/SearchOptions.d.ts +10 -0
- package/es6/pdf-web-viewer/views/appbar/SearchOptions.js +55 -0
- package/es6/pdf-web-viewer/views/appbar/ViewBar.d.ts +4 -0
- package/es6/pdf-web-viewer/views/appbar/ViewBar.js +52 -0
- package/es6/pdf-web-viewer/views/appbar/ZoomBar.d.ts +4 -0
- package/es6/pdf-web-viewer/views/appbar/ZoomBar.js +18 -0
- package/es6/pdf-web-viewer/views/modal/ApplicationError.d.ts +4 -0
- package/es6/pdf-web-viewer/views/modal/ApplicationError.js +25 -0
- package/es6/pdf-web-viewer/views/modal/LoadApplication.d.ts +3 -0
- package/es6/pdf-web-viewer/views/modal/LoadApplication.js +6 -0
- package/es6/pdf-web-viewer/views/modal/LoadFile.d.ts +3 -0
- package/es6/pdf-web-viewer/views/modal/LoadFile.js +10 -0
- package/es6/pdf-web-viewer/views/modal/Modal.d.ts +4 -0
- package/es6/pdf-web-viewer/views/modal/Modal.js +39 -0
- package/es6/pdf-web-viewer/views/modal/OpenFile.d.ts +4 -0
- package/es6/pdf-web-viewer/views/modal/OpenFile.js +30 -0
- package/es6/pdf-web-viewer/views/modal/OpenFileError.d.ts +4 -0
- package/es6/pdf-web-viewer/views/modal/OpenFileError.js +13 -0
- package/es6/pdf-web-viewer/views/modal/PasswordForm.d.ts +4 -0
- package/es6/pdf-web-viewer/views/modal/PasswordForm.js +54 -0
- package/es6/pdf-web-viewer/views/modal/SaveFile.d.ts +4 -0
- package/es6/pdf-web-viewer/views/modal/SaveFile.js +10 -0
- package/es6/pdf-web-viewer/views/modal/UnsavedChanges.d.ts +4 -0
- package/es6/pdf-web-viewer/views/modal/UnsavedChanges.js +32 -0
- package/es6/pdf-web-viewer/views/navigation/AnnotationList.d.ts +8 -0
- package/es6/pdf-web-viewer/views/navigation/AnnotationList.js +26 -0
- package/es6/pdf-web-viewer/views/navigation/AnnotationListItem.d.ts +8 -0
- package/es6/pdf-web-viewer/views/navigation/AnnotationListItem.js +158 -0
- package/es6/pdf-web-viewer/views/navigation/AnnotationNavigation.d.ts +4 -0
- package/es6/pdf-web-viewer/views/navigation/AnnotationNavigation.js +11 -0
- package/es6/pdf-web-viewer/views/navigation/NavigationPanel.d.ts +4 -0
- package/es6/pdf-web-viewer/views/navigation/NavigationPanel.js +50 -0
- package/es6/pdf-web-viewer/views/navigation/OutlineList.d.ts +12 -0
- package/es6/pdf-web-viewer/views/navigation/OutlineList.js +19 -0
- package/es6/pdf-web-viewer/views/navigation/OutlineNavigation.d.ts +4 -0
- package/es6/pdf-web-viewer/views/navigation/OutlineNavigation.js +10 -0
- package/es6/pdf-web-viewer/views/navigation/ThumbnailNavigation.d.ts +16 -0
- package/es6/pdf-web-viewer/views/navigation/ThumbnailNavigation.js +32 -0
- package/package.json +24 -0
- package/pdfwebviewer/PdfViewing.data +0 -0
- package/pdfwebviewer/PdfViewing_Main.js +1 -0
- package/pdfwebviewer/PdfViewing_Main.wasm +0 -0
- package/pdfwebviewer/PdfViewing_Worker.js +1 -0
- package/pdfwebviewer/PdfViewing_Worker.wasm +0 -0
- package/pdfwebviewer/pdf-web-viewer.css +2407 -0
- package/pdfwebviewer/pdf-web-viewer.development.js +25955 -0
- package/pdfwebviewer/pdf-web-viewer.min.js +1 -0
- package/pdfwebviewer/translations.de.json +151 -0
- package/pdfwebviewer/translations.en.json +151 -0
- package/pdfwebviewer/translations.fr.json +151 -0
- package/pdfwebviewer/translations.it.json +151 -0
- package/scss/common/_breakpoints.scss +44 -0
- package/scss/common/_buttons.scss +42 -0
- package/scss/common/_colorpicker.scss +89 -0
- package/scss/common/_common.scss +21 -0
- package/scss/common/_contextbar.scss +44 -0
- package/scss/common/_dropdown.scss +176 -0
- package/scss/common/_icon.scss +9 -0
- package/scss/common/_index.scss +19 -0
- package/scss/common/_loader.scss +30 -0
- package/scss/common/_rangeslider.scss +24 -0
- package/scss/common/_scrollbars.scss +64 -0
- package/scss/common/_stroke-style-picker.scss +64 -0
- package/scss/common/_stroke-width-picker.scss +23 -0
- package/scss/common/_toolbar.scss +117 -0
- package/scss/common/_tooltip.scss +39 -0
- package/scss/modules/_eraser.scss +28 -0
- package/scss/modules/_forms.scss +56 -0
- package/scss/modules/_highlightannotation.scss +12 -0
- package/scss/modules/_index.scss +5 -0
- package/scss/modules/_inkannotation.scss +41 -0
- package/scss/modules/_stampannotation.scss +19 -0
- package/scss/pdf-viewer-canvas/_annotationborder.scss +107 -0
- package/scss/pdf-viewer-canvas/_busy-loader.scss +53 -0
- package/scss/pdf-viewer-canvas/_freetexteditor.scss +28 -0
- package/scss/pdf-viewer-canvas/_index.scss +7 -0
- package/scss/pdf-viewer-canvas/_layout.scss +52 -0
- package/scss/pdf-viewer-canvas/_popup.scss +217 -0
- package/scss/pdf-viewer-canvas/_printservice.scss +171 -0
- package/scss/pdf-viewer-canvas/_textselection.scss +17 -0
- package/scss/pdf-web-viewer/_annotationbar.scss +47 -0
- package/scss/pdf-web-viewer/_index.scss +8 -0
- package/scss/pdf-web-viewer/_layout.scss +63 -0
- package/scss/pdf-web-viewer/_modal.scss +186 -0
- package/scss/pdf-web-viewer/_navigationpanel.scss +398 -0
- package/scss/pdf-web-viewer/_searchbar.scss +47 -0
- package/scss/pdf-web-viewer/_toolbar.scss +134 -0
- package/scss/pdf-web-viewer/_viewer.scss +54 -0
- package/scss/pdf-web-viewer.scss +1 -0
- package/scss/themes/default/_light.scss +32 -0
- package/scss/themes/default/_mixins.scss +129 -0
- package/scss/themes/default/_theme.scss +161 -0
- package/scss/themes/pdf-web-viewer.scss +1 -0
- package/umd/pdf-web-viewer.development.js +25955 -0
- package/umd/pdf-web-viewer.development.js.map +1 -0
- package/umd/pdf-web-viewer.min.js +1 -0
- package/wasm/PdfViewing.data +0 -0
- package/wasm/PdfViewing_Main.js +1 -0
- package/wasm/PdfViewing_Main.wasm +0 -0
- package/wasm/PdfViewing_Worker.js +1 -0
- package/wasm/PdfViewing_Worker.wasm +0 -0
- package/wasm/translations.de.json +151 -0
- package/wasm/translations.en.json +151 -0
- package/wasm/translations.fr.json +151 -0
- package/wasm/translations.it.json +151 -0
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { PdfViewerApi, Annotation } from '../../pdf-viewer-api';
|
|
2
|
+
import { PdfViewerCanvas, PdfViewerCanvasEventMap } from '../PdfViewerCanvas';
|
|
3
|
+
import { WebViewerOptions } from '../../pdf-web-viewer/WebViewerOptions';
|
|
4
|
+
import { ViewerCanvasState, ViewerCanvasStore } from '../state/store';
|
|
5
|
+
export interface ViewLayer {
|
|
6
|
+
resize(width: number, height: number, devicePixelRatio: number): void;
|
|
7
|
+
render(timestamp: number, viewerCanvasState: ViewerCanvasState): void;
|
|
8
|
+
}
|
|
9
|
+
export declare abstract class ViewLayerBase implements ViewLayer {
|
|
10
|
+
protected viewerCanvas: PdfViewerCanvas | undefined;
|
|
11
|
+
protected dispatchEvent: any;
|
|
12
|
+
protected containerElement: HTMLElement | undefined;
|
|
13
|
+
private canvasContexts;
|
|
14
|
+
private htmlLayers;
|
|
15
|
+
private pPdfViewerApi;
|
|
16
|
+
private pStore;
|
|
17
|
+
private pOptions;
|
|
18
|
+
constructor();
|
|
19
|
+
protected get pdfViewerApi(): PdfViewerApi;
|
|
20
|
+
protected get store(): ViewerCanvasStore;
|
|
21
|
+
protected get options(): WebViewerOptions;
|
|
22
|
+
resize(width: number, height: number, pixelRatio: number): void;
|
|
23
|
+
register(viewerCanvas: PdfViewerCanvas, dispatchEvent: <K extends keyof PdfViewerCanvasEventMap>(type: K, args: PdfViewerCanvasEventMap[K]) => void): void;
|
|
24
|
+
abstract create(): void;
|
|
25
|
+
abstract render(timestamp: number, state: ViewerCanvasState): void | boolean;
|
|
26
|
+
protected createHtmlLayer(): HTMLDivElement;
|
|
27
|
+
protected createCanvas(className?: string): CanvasRenderingContext2D;
|
|
28
|
+
protected removeHtmlElements(): void;
|
|
29
|
+
protected removeCanvasElements(): void;
|
|
30
|
+
protected addDeleteHistory(annotation: Annotation): void;
|
|
31
|
+
}
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { addHistoryEntry } from '../../custom/history';
|
|
2
|
+
export class ViewLayerBase {
|
|
3
|
+
constructor() {
|
|
4
|
+
this.canvasContexts = [];
|
|
5
|
+
this.htmlLayers = [];
|
|
6
|
+
}
|
|
7
|
+
get pdfViewerApi() {
|
|
8
|
+
if (!this.pPdfViewerApi) {
|
|
9
|
+
this.pPdfViewerApi = this.viewerCanvas.pdfViewerApi;
|
|
10
|
+
if (!this.pPdfViewerApi) {
|
|
11
|
+
throw new Error('pdfViewerApi in undefined');
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
return this.pPdfViewerApi;
|
|
15
|
+
}
|
|
16
|
+
get store() {
|
|
17
|
+
if (!this.pStore) {
|
|
18
|
+
this.pStore = this.viewerCanvas.store;
|
|
19
|
+
if (!this.pStore) {
|
|
20
|
+
throw new Error('pStore in undefined');
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
return this.pStore;
|
|
24
|
+
}
|
|
25
|
+
get options() {
|
|
26
|
+
if (!this.pOptions) {
|
|
27
|
+
this.pOptions = this.viewerCanvas.options;
|
|
28
|
+
if (!this.pOptions) {
|
|
29
|
+
throw new Error('options in undefined');
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
return this.pOptions;
|
|
33
|
+
}
|
|
34
|
+
resize(width, height, pixelRatio) {
|
|
35
|
+
try {
|
|
36
|
+
const tempCanvas = document.createElement('canvas');
|
|
37
|
+
tempCanvas.width = width * pixelRatio;
|
|
38
|
+
tempCanvas.height = height * pixelRatio;
|
|
39
|
+
const tempContext = tempCanvas.getContext('2d');
|
|
40
|
+
this.canvasContexts.forEach((ctx) => {
|
|
41
|
+
tempContext.drawImage(ctx.canvas, 0, 0);
|
|
42
|
+
ctx.canvas.style.width = width + 'px';
|
|
43
|
+
ctx.canvas.style.height = height + 'px';
|
|
44
|
+
ctx.canvas.width = width * pixelRatio;
|
|
45
|
+
ctx.canvas.height = height * pixelRatio;
|
|
46
|
+
ctx.drawImage(tempContext.canvas, 0, 0);
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
catch (err) {
|
|
50
|
+
console.warn(err);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
register(viewerCanvas, dispatchEvent) {
|
|
54
|
+
this.viewerCanvas = viewerCanvas;
|
|
55
|
+
this.dispatchEvent = dispatchEvent;
|
|
56
|
+
this.containerElement = this.viewerCanvas.viewLayersElement;
|
|
57
|
+
this.create();
|
|
58
|
+
}
|
|
59
|
+
createHtmlLayer() {
|
|
60
|
+
const element = document.createElement('div');
|
|
61
|
+
this.htmlLayers.push(element);
|
|
62
|
+
if (this.containerElement) {
|
|
63
|
+
this.containerElement.appendChild(element);
|
|
64
|
+
}
|
|
65
|
+
return element;
|
|
66
|
+
}
|
|
67
|
+
createCanvas(className) {
|
|
68
|
+
const element = document.createElement('canvas');
|
|
69
|
+
element.style.position = 'absolute';
|
|
70
|
+
element.style.top = '0';
|
|
71
|
+
element.style.left = '0';
|
|
72
|
+
element.style.right = '0';
|
|
73
|
+
element.style.bottom = '0';
|
|
74
|
+
if (className) {
|
|
75
|
+
element.classList.add(className);
|
|
76
|
+
}
|
|
77
|
+
const context = element.getContext('2d');
|
|
78
|
+
this.canvasContexts.push(context);
|
|
79
|
+
if (this.containerElement) {
|
|
80
|
+
this.containerElement.appendChild(element);
|
|
81
|
+
const rect = this.containerElement.getBoundingClientRect();
|
|
82
|
+
context.canvas.width = rect.width * devicePixelRatio;
|
|
83
|
+
context.canvas.height = rect.height * devicePixelRatio;
|
|
84
|
+
}
|
|
85
|
+
return context;
|
|
86
|
+
}
|
|
87
|
+
removeHtmlElements() {
|
|
88
|
+
if (this.containerElement) {
|
|
89
|
+
for (let i = 0; i < this.htmlLayers.length; i++) {
|
|
90
|
+
this.containerElement.removeChild(this.htmlLayers[i]);
|
|
91
|
+
}
|
|
92
|
+
this.htmlLayers = [];
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
removeCanvasElements() {
|
|
96
|
+
if (this.containerElement) {
|
|
97
|
+
for (let i = 0; i < this.canvasContexts.length; i++) {
|
|
98
|
+
this.containerElement.removeChild(this.canvasContexts[i].canvas);
|
|
99
|
+
}
|
|
100
|
+
this.canvasContexts = [];
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
addDeleteHistory(annotation) {
|
|
104
|
+
addHistoryEntry(annotation, 'delete', this.options.viewer.general.user);
|
|
105
|
+
}
|
|
106
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Rect, Point } from '../../pdf-viewer-api';
|
|
2
|
+
/** internal */
|
|
3
|
+
export declare const renderAnnotationSelection: (ctx: CanvasRenderingContext2D, scale: number, color: string, rect: Rect, resizable: boolean) => void;
|
|
4
|
+
/** internal */
|
|
5
|
+
export declare const renderTextMarker: (ctx: CanvasRenderingContext2D, scale: number, type: 'start' | 'end', color: string, rect: Rect) => void;
|
|
6
|
+
/** internal */
|
|
7
|
+
export declare const renderTextSelection: (ctx: CanvasRenderingContext2D, scale: number, color: string, selection: Point[][]) => void;
|
|
8
|
+
/** internal */
|
|
9
|
+
export declare const renderPopupMarker: (ctx: CanvasRenderingContext2D, scale: number, color: string, pos: Point) => void;
|
|
10
|
+
/** internal */
|
|
11
|
+
export declare const renderStickyNote: (ctx: CanvasRenderingContext2D, scale: number, rect: Rect, fillColor: string, strokeColor: string) => void;
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
/** internal */
|
|
2
|
+
/* tslint:disable-next-line */
|
|
3
|
+
export const renderAnnotationSelection = (ctx, scale, color, rect, resizable) => {
|
|
4
|
+
const handle = 10 * scale;
|
|
5
|
+
const handleOffset = handle / 2;
|
|
6
|
+
const padding = 4 * scale;
|
|
7
|
+
const x = rect.x - padding;
|
|
8
|
+
const y = rect.y - padding;
|
|
9
|
+
const w = rect.w + 2 * padding;
|
|
10
|
+
const h = rect.h + 2 * padding;
|
|
11
|
+
ctx.lineWidth = 2 * scale;
|
|
12
|
+
ctx.strokeStyle = color;
|
|
13
|
+
ctx.fillStyle = color;
|
|
14
|
+
if (resizable) {
|
|
15
|
+
const x1 = x - handleOffset;
|
|
16
|
+
const x2 = x1 + w;
|
|
17
|
+
const y1 = y - handleOffset;
|
|
18
|
+
const y2 = y1 + h;
|
|
19
|
+
ctx.fillRect(x1, y1, handle, handle);
|
|
20
|
+
ctx.fillRect(x1, y2, handle, handle);
|
|
21
|
+
ctx.fillRect(x2, y1, handle, handle);
|
|
22
|
+
ctx.fillRect(x2, y2, handle, handle);
|
|
23
|
+
}
|
|
24
|
+
ctx.strokeRect(x, y, w, h);
|
|
25
|
+
};
|
|
26
|
+
/** internal */
|
|
27
|
+
export const renderTextMarker = (ctx, scale, type, color, rect) => {
|
|
28
|
+
ctx.save();
|
|
29
|
+
const startType = type === 'start';
|
|
30
|
+
const lineWidth = 2 * scale;
|
|
31
|
+
const p = 3 * scale;
|
|
32
|
+
const x = startType ? rect.x - lineWidth / 2 : rect.x + rect.w + lineWidth / 2;
|
|
33
|
+
const y1 = startType ? rect.y - p : rect.y + rect.h + p;
|
|
34
|
+
const y2 = startType ? rect.y + rect.h : rect.y;
|
|
35
|
+
ctx.strokeStyle = color;
|
|
36
|
+
ctx.fillStyle = color;
|
|
37
|
+
ctx.lineWidth = lineWidth;
|
|
38
|
+
ctx.globalAlpha = 0.8;
|
|
39
|
+
ctx.beginPath();
|
|
40
|
+
ctx.moveTo(x, y1);
|
|
41
|
+
ctx.lineTo(x, y2);
|
|
42
|
+
ctx.closePath();
|
|
43
|
+
ctx.stroke();
|
|
44
|
+
ctx.restore();
|
|
45
|
+
};
|
|
46
|
+
/** internal */
|
|
47
|
+
export const renderTextSelection = (ctx, scale, color, selection) => {
|
|
48
|
+
ctx.save();
|
|
49
|
+
ctx.globalCompositeOperation = 'multiply';
|
|
50
|
+
ctx.globalAlpha = 0.3;
|
|
51
|
+
ctx.fillStyle = color;
|
|
52
|
+
if (selection.length) {
|
|
53
|
+
ctx.beginPath();
|
|
54
|
+
for (let i = 0; i < selection.length; i++) {
|
|
55
|
+
const path = selection[i];
|
|
56
|
+
for (let k = 0; k < path.length; k++) {
|
|
57
|
+
const point = path[k];
|
|
58
|
+
if (k === 0) {
|
|
59
|
+
ctx.moveTo(point.x, point.y);
|
|
60
|
+
}
|
|
61
|
+
else {
|
|
62
|
+
ctx.lineTo(point.x, point.y);
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
ctx.closePath();
|
|
67
|
+
ctx.fill();
|
|
68
|
+
}
|
|
69
|
+
ctx.restore();
|
|
70
|
+
};
|
|
71
|
+
/** internal */
|
|
72
|
+
export const renderPopupMarker = (ctx, scale, color, pos) => {
|
|
73
|
+
const posX = pos.x;
|
|
74
|
+
const posY = pos.y;
|
|
75
|
+
ctx.beginPath();
|
|
76
|
+
ctx.moveTo(posX - 5 * scale, posY - 5 * scale);
|
|
77
|
+
ctx.lineTo(posX + 6 * scale, posY - 5 * scale);
|
|
78
|
+
ctx.lineTo(posX + 6 * scale, posY + 3 * scale);
|
|
79
|
+
ctx.lineTo(posX + 3 * scale, posY + 3 * scale);
|
|
80
|
+
ctx.lineTo(posX, posY + 6 * scale);
|
|
81
|
+
ctx.lineTo(posX - 3 * scale, posY + 3 * scale);
|
|
82
|
+
ctx.lineTo(posX - 5 * scale, posY + 3 * scale);
|
|
83
|
+
ctx.closePath();
|
|
84
|
+
ctx.stroke();
|
|
85
|
+
ctx.globalAlpha = 0.5;
|
|
86
|
+
ctx.fillStyle = color;
|
|
87
|
+
ctx.fill();
|
|
88
|
+
ctx.globalAlpha = 1;
|
|
89
|
+
};
|
|
90
|
+
/** internal */
|
|
91
|
+
export const renderStickyNote = (ctx, scale, rect, fillColor, strokeColor) => {
|
|
92
|
+
const w = rect.w;
|
|
93
|
+
const h1 = rect.h * 0.8;
|
|
94
|
+
const h2 = rect.h;
|
|
95
|
+
const r = rect.w / 6;
|
|
96
|
+
const s = rect.w / 10;
|
|
97
|
+
const x1 = rect.x;
|
|
98
|
+
const y1 = rect.y;
|
|
99
|
+
const x1r = x1 + r;
|
|
100
|
+
const y1r = y1 + r;
|
|
101
|
+
const x2 = x1 + w;
|
|
102
|
+
const y2 = y1 + h1;
|
|
103
|
+
const x2r = x2 - r;
|
|
104
|
+
const y2r = y2 - r;
|
|
105
|
+
const xs1 = x1r + r;
|
|
106
|
+
const xs2 = xs1 + r;
|
|
107
|
+
const xs3 = x1r + s;
|
|
108
|
+
const ys3 = y1 + h2;
|
|
109
|
+
ctx.beginPath();
|
|
110
|
+
ctx.moveTo(x1r, y1);
|
|
111
|
+
ctx.lineTo(x2r, y1);
|
|
112
|
+
ctx.arcTo(x2, y1, x2, y1r, r);
|
|
113
|
+
ctx.lineTo(x2, y2r);
|
|
114
|
+
ctx.arcTo(x2, y2, x2r, y2, r);
|
|
115
|
+
ctx.lineTo(xs2, y2);
|
|
116
|
+
ctx.lineTo(xs3, ys3);
|
|
117
|
+
ctx.lineTo(xs1, y2);
|
|
118
|
+
ctx.lineTo(x1r, y2);
|
|
119
|
+
ctx.arcTo(x1, y2, x1, y2r, r);
|
|
120
|
+
ctx.lineTo(x1, y1r);
|
|
121
|
+
ctx.arcTo(x1, y1, x1r, y1, r);
|
|
122
|
+
ctx.closePath();
|
|
123
|
+
ctx.lineWidth = 0.75 * scale;
|
|
124
|
+
ctx.fillStyle = fillColor;
|
|
125
|
+
ctx.strokeStyle = strokeColor;
|
|
126
|
+
ctx.fill();
|
|
127
|
+
ctx.stroke();
|
|
128
|
+
const x1l = x1r + 1 * scale;
|
|
129
|
+
const x2l = x2r - 1 * scale;
|
|
130
|
+
const x3l = x2r - r;
|
|
131
|
+
const y1l = y1r + 1 * scale;
|
|
132
|
+
const y3l = y2r - 1 * scale;
|
|
133
|
+
const y2l = y1l + (y3l - y1l) / 2;
|
|
134
|
+
ctx.beginPath();
|
|
135
|
+
ctx.moveTo(x1l, y1l);
|
|
136
|
+
ctx.lineTo(x2l, y1l);
|
|
137
|
+
ctx.closePath();
|
|
138
|
+
ctx.stroke();
|
|
139
|
+
ctx.beginPath();
|
|
140
|
+
ctx.moveTo(x1l, y2l);
|
|
141
|
+
ctx.lineTo(x2l, y2l);
|
|
142
|
+
ctx.closePath();
|
|
143
|
+
ctx.stroke();
|
|
144
|
+
ctx.beginPath();
|
|
145
|
+
ctx.moveTo(x1l, y3l);
|
|
146
|
+
ctx.lineTo(x3l, y3l);
|
|
147
|
+
ctx.closePath();
|
|
148
|
+
ctx.stroke();
|
|
149
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** internal */
|
|
2
|
+
export const pointInRect = (p, rect, padding) => {
|
|
3
|
+
if (padding) {
|
|
4
|
+
rect.x -= padding;
|
|
5
|
+
rect.y -= padding;
|
|
6
|
+
rect.w += 2 * padding;
|
|
7
|
+
rect.h += 2 * padding;
|
|
8
|
+
}
|
|
9
|
+
return p.x >= rect.x && p.x <= rect.x + rect.w && p.y >= rect.y && p.y <= rect.y + rect.h;
|
|
10
|
+
};
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { Rect, Point, Annotation } from '../../../pdf-viewer-api';
|
|
2
|
+
import { WebViewerOptions } from '../../../pdf-web-viewer/WebViewerOptions';
|
|
3
|
+
import { ViewerCanvasStore } from 'pdf-viewer-canvas/state/store';
|
|
4
|
+
/** internal */
|
|
5
|
+
export declare const MIN_SIZE = 10;
|
|
6
|
+
/** internal */
|
|
7
|
+
export declare class AnnotationBorder {
|
|
8
|
+
private annotationId;
|
|
9
|
+
private movable;
|
|
10
|
+
private resizable;
|
|
11
|
+
private aspectRatio;
|
|
12
|
+
private pageRect;
|
|
13
|
+
private options;
|
|
14
|
+
private store;
|
|
15
|
+
private isViewOnly;
|
|
16
|
+
private element;
|
|
17
|
+
private border;
|
|
18
|
+
private dragElement;
|
|
19
|
+
private dragHandler;
|
|
20
|
+
private resizeElementNw;
|
|
21
|
+
private resizeElementNe;
|
|
22
|
+
private resizeElementSw;
|
|
23
|
+
private resizeElementSe;
|
|
24
|
+
private resizeHandlerNw;
|
|
25
|
+
private resizeHandlerNe;
|
|
26
|
+
private resizeHandlerSw;
|
|
27
|
+
private resizeHandlerSe;
|
|
28
|
+
private dragOffsetX;
|
|
29
|
+
private dragOffsetY;
|
|
30
|
+
private containerOffsetX;
|
|
31
|
+
private containerOffsetY;
|
|
32
|
+
private onMoved;
|
|
33
|
+
private onResized;
|
|
34
|
+
private onDblClick;
|
|
35
|
+
private resizeDir;
|
|
36
|
+
private minSize;
|
|
37
|
+
constructor(element: HTMLElement, onMoved: (id: number, newPosition: Point) => void, onResized: (id: number, newRect: Rect) => void, onDblClick: (id: number) => void, options: WebViewerOptions, store: ViewerCanvasStore, isViewOnly: boolean);
|
|
38
|
+
setAnnotation(annotation: Annotation, pageRect: Rect): void;
|
|
39
|
+
deselectAnnotation(): void;
|
|
40
|
+
updatePageRect(pageRect: Rect): void;
|
|
41
|
+
private click;
|
|
42
|
+
private dblClick;
|
|
43
|
+
private startResize;
|
|
44
|
+
private resizing;
|
|
45
|
+
private updateMinSize;
|
|
46
|
+
private resizeNoAspectRatio;
|
|
47
|
+
private resizeWithAspectRatio;
|
|
48
|
+
private endResize;
|
|
49
|
+
private startMove;
|
|
50
|
+
private moving;
|
|
51
|
+
private endMove;
|
|
52
|
+
}
|