@box/pdfjs-dist 0.0.0-stage → 6.4.299-box.2
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/CHANGELOG.md +16 -0
- package/CODE_OF_CONDUCT.md +15 -0
- package/LICENSE +177 -0
- package/README.md +23 -2
- package/build/pdf.min.mjs +28 -0
- package/build/pdf.mjs +28336 -0
- package/build/pdf.mjs.map +1 -0
- package/build/pdf.sandbox.min.mjs +28 -0
- package/build/pdf.sandbox.mjs +211 -0
- package/build/pdf.sandbox.mjs.map +1 -0
- package/build/pdf.worker.min.mjs +28 -0
- package/build/pdf.worker.mjs +64908 -0
- package/build/pdf.worker.mjs.map +1 -0
- package/cmaps/78-EUC-H.bcmap +0 -0
- package/cmaps/78-EUC-V.bcmap +0 -0
- package/cmaps/78-H.bcmap +0 -0
- package/cmaps/78-RKSJ-H.bcmap +0 -0
- package/cmaps/78-RKSJ-V.bcmap +0 -0
- package/cmaps/78-V.bcmap +0 -0
- package/cmaps/78ms-RKSJ-H.bcmap +0 -0
- package/cmaps/78ms-RKSJ-V.bcmap +0 -0
- package/cmaps/83pv-RKSJ-H.bcmap +0 -0
- package/cmaps/90ms-RKSJ-H.bcmap +0 -0
- package/cmaps/90ms-RKSJ-V.bcmap +0 -0
- package/cmaps/90msp-RKSJ-H.bcmap +0 -0
- package/cmaps/90msp-RKSJ-V.bcmap +0 -0
- package/cmaps/90pv-RKSJ-H.bcmap +0 -0
- package/cmaps/90pv-RKSJ-V.bcmap +0 -0
- package/cmaps/Add-H.bcmap +0 -0
- package/cmaps/Add-RKSJ-H.bcmap +0 -0
- package/cmaps/Add-RKSJ-V.bcmap +0 -0
- package/cmaps/Add-V.bcmap +0 -0
- package/cmaps/Adobe-CNS1-0.bcmap +0 -0
- package/cmaps/Adobe-CNS1-1.bcmap +0 -0
- package/cmaps/Adobe-CNS1-2.bcmap +0 -0
- package/cmaps/Adobe-CNS1-3.bcmap +0 -0
- package/cmaps/Adobe-CNS1-4.bcmap +0 -0
- package/cmaps/Adobe-CNS1-5.bcmap +0 -0
- package/cmaps/Adobe-CNS1-6.bcmap +0 -0
- package/cmaps/Adobe-CNS1-UCS2.bcmap +0 -0
- package/cmaps/Adobe-GB1-0.bcmap +0 -0
- package/cmaps/Adobe-GB1-1.bcmap +0 -0
- package/cmaps/Adobe-GB1-2.bcmap +0 -0
- package/cmaps/Adobe-GB1-3.bcmap +0 -0
- package/cmaps/Adobe-GB1-4.bcmap +0 -0
- package/cmaps/Adobe-GB1-5.bcmap +0 -0
- package/cmaps/Adobe-GB1-UCS2.bcmap +0 -0
- package/cmaps/Adobe-Japan1-0.bcmap +0 -0
- package/cmaps/Adobe-Japan1-1.bcmap +0 -0
- package/cmaps/Adobe-Japan1-2.bcmap +0 -0
- package/cmaps/Adobe-Japan1-3.bcmap +0 -0
- package/cmaps/Adobe-Japan1-4.bcmap +0 -0
- package/cmaps/Adobe-Japan1-5.bcmap +0 -0
- package/cmaps/Adobe-Japan1-6.bcmap +0 -0
- package/cmaps/Adobe-Japan1-UCS2.bcmap +0 -0
- package/cmaps/Adobe-Korea1-0.bcmap +0 -0
- package/cmaps/Adobe-Korea1-1.bcmap +0 -0
- package/cmaps/Adobe-Korea1-2.bcmap +0 -0
- package/cmaps/Adobe-Korea1-UCS2.bcmap +0 -0
- package/cmaps/B5-H.bcmap +0 -0
- package/cmaps/B5-V.bcmap +0 -0
- package/cmaps/B5pc-H.bcmap +0 -0
- package/cmaps/B5pc-V.bcmap +0 -0
- package/cmaps/CNS-EUC-H.bcmap +0 -0
- package/cmaps/CNS-EUC-V.bcmap +0 -0
- package/cmaps/CNS1-H.bcmap +0 -0
- package/cmaps/CNS1-V.bcmap +0 -0
- package/cmaps/CNS2-H.bcmap +0 -0
- package/cmaps/CNS2-V.bcmap +3 -0
- package/cmaps/ETHK-B5-H.bcmap +0 -0
- package/cmaps/ETHK-B5-V.bcmap +0 -0
- package/cmaps/ETen-B5-H.bcmap +0 -0
- package/cmaps/ETen-B5-V.bcmap +0 -0
- package/cmaps/ETenms-B5-H.bcmap +3 -0
- package/cmaps/ETenms-B5-V.bcmap +0 -0
- package/cmaps/EUC-H.bcmap +0 -0
- package/cmaps/EUC-V.bcmap +0 -0
- package/cmaps/Ext-H.bcmap +0 -0
- package/cmaps/Ext-RKSJ-H.bcmap +0 -0
- package/cmaps/Ext-RKSJ-V.bcmap +0 -0
- package/cmaps/Ext-V.bcmap +0 -0
- package/cmaps/GB-EUC-H.bcmap +0 -0
- package/cmaps/GB-EUC-V.bcmap +0 -0
- package/cmaps/GB-H.bcmap +4 -0
- package/cmaps/GB-V.bcmap +0 -0
- package/cmaps/GBK-EUC-H.bcmap +0 -0
- package/cmaps/GBK-EUC-V.bcmap +0 -0
- package/cmaps/GBK2K-H.bcmap +0 -0
- package/cmaps/GBK2K-V.bcmap +0 -0
- package/cmaps/GBKp-EUC-H.bcmap +0 -0
- package/cmaps/GBKp-EUC-V.bcmap +0 -0
- package/cmaps/GBT-EUC-H.bcmap +0 -0
- package/cmaps/GBT-EUC-V.bcmap +0 -0
- package/cmaps/GBT-H.bcmap +0 -0
- package/cmaps/GBT-V.bcmap +0 -0
- package/cmaps/GBTpc-EUC-H.bcmap +0 -0
- package/cmaps/GBTpc-EUC-V.bcmap +0 -0
- package/cmaps/GBpc-EUC-H.bcmap +0 -0
- package/cmaps/GBpc-EUC-V.bcmap +0 -0
- package/cmaps/H.bcmap +0 -0
- package/cmaps/HKdla-B5-H.bcmap +0 -0
- package/cmaps/HKdla-B5-V.bcmap +0 -0
- package/cmaps/HKdlb-B5-H.bcmap +0 -0
- package/cmaps/HKdlb-B5-V.bcmap +0 -0
- package/cmaps/HKgccs-B5-H.bcmap +0 -0
- package/cmaps/HKgccs-B5-V.bcmap +0 -0
- package/cmaps/HKm314-B5-H.bcmap +0 -0
- package/cmaps/HKm314-B5-V.bcmap +0 -0
- package/cmaps/HKm471-B5-H.bcmap +0 -0
- package/cmaps/HKm471-B5-V.bcmap +0 -0
- package/cmaps/HKscs-B5-H.bcmap +0 -0
- package/cmaps/HKscs-B5-V.bcmap +0 -0
- package/cmaps/Hankaku.bcmap +0 -0
- package/cmaps/Hiragana.bcmap +0 -0
- package/cmaps/KSC-EUC-H.bcmap +0 -0
- package/cmaps/KSC-EUC-V.bcmap +0 -0
- package/cmaps/KSC-H.bcmap +0 -0
- package/cmaps/KSC-Johab-H.bcmap +0 -0
- package/cmaps/KSC-Johab-V.bcmap +0 -0
- package/cmaps/KSC-V.bcmap +0 -0
- package/cmaps/KSCms-UHC-H.bcmap +0 -0
- package/cmaps/KSCms-UHC-HW-H.bcmap +0 -0
- package/cmaps/KSCms-UHC-HW-V.bcmap +0 -0
- package/cmaps/KSCms-UHC-V.bcmap +0 -0
- package/cmaps/KSCpc-EUC-H.bcmap +0 -0
- package/cmaps/KSCpc-EUC-V.bcmap +0 -0
- package/cmaps/Katakana.bcmap +0 -0
- package/cmaps/LICENSE +36 -0
- package/cmaps/NWP-H.bcmap +0 -0
- package/cmaps/NWP-V.bcmap +0 -0
- package/cmaps/RKSJ-H.bcmap +0 -0
- package/cmaps/RKSJ-V.bcmap +0 -0
- package/cmaps/Roman.bcmap +0 -0
- package/cmaps/UniCNS-UCS2-H.bcmap +0 -0
- package/cmaps/UniCNS-UCS2-V.bcmap +0 -0
- package/cmaps/UniCNS-UTF16-H.bcmap +0 -0
- package/cmaps/UniCNS-UTF16-V.bcmap +0 -0
- package/cmaps/UniCNS-UTF32-H.bcmap +0 -0
- package/cmaps/UniCNS-UTF32-V.bcmap +0 -0
- package/cmaps/UniCNS-UTF8-H.bcmap +0 -0
- package/cmaps/UniCNS-UTF8-V.bcmap +0 -0
- package/cmaps/UniGB-UCS2-H.bcmap +0 -0
- package/cmaps/UniGB-UCS2-V.bcmap +0 -0
- package/cmaps/UniGB-UTF16-H.bcmap +0 -0
- package/cmaps/UniGB-UTF16-V.bcmap +0 -0
- package/cmaps/UniGB-UTF32-H.bcmap +0 -0
- package/cmaps/UniGB-UTF32-V.bcmap +0 -0
- package/cmaps/UniGB-UTF8-H.bcmap +0 -0
- package/cmaps/UniGB-UTF8-V.bcmap +0 -0
- package/cmaps/UniJIS-UCS2-H.bcmap +0 -0
- package/cmaps/UniJIS-UCS2-HW-H.bcmap +0 -0
- package/cmaps/UniJIS-UCS2-HW-V.bcmap +0 -0
- package/cmaps/UniJIS-UCS2-V.bcmap +0 -0
- package/cmaps/UniJIS-UTF16-H.bcmap +0 -0
- package/cmaps/UniJIS-UTF16-V.bcmap +0 -0
- package/cmaps/UniJIS-UTF32-H.bcmap +0 -0
- package/cmaps/UniJIS-UTF32-V.bcmap +0 -0
- package/cmaps/UniJIS-UTF8-H.bcmap +0 -0
- package/cmaps/UniJIS-UTF8-V.bcmap +0 -0
- package/cmaps/UniJIS2004-UTF16-H.bcmap +0 -0
- package/cmaps/UniJIS2004-UTF16-V.bcmap +0 -0
- package/cmaps/UniJIS2004-UTF32-H.bcmap +0 -0
- package/cmaps/UniJIS2004-UTF32-V.bcmap +0 -0
- package/cmaps/UniJIS2004-UTF8-H.bcmap +0 -0
- package/cmaps/UniJIS2004-UTF8-V.bcmap +0 -0
- package/cmaps/UniJISPro-UCS2-HW-V.bcmap +0 -0
- package/cmaps/UniJISPro-UCS2-V.bcmap +0 -0
- package/cmaps/UniJISPro-UTF8-V.bcmap +0 -0
- package/cmaps/UniJISX0213-UTF32-H.bcmap +0 -0
- package/cmaps/UniJISX0213-UTF32-V.bcmap +0 -0
- package/cmaps/UniJISX02132004-UTF32-H.bcmap +0 -0
- package/cmaps/UniJISX02132004-UTF32-V.bcmap +0 -0
- package/cmaps/UniKS-UCS2-H.bcmap +0 -0
- package/cmaps/UniKS-UCS2-V.bcmap +0 -0
- package/cmaps/UniKS-UTF16-H.bcmap +0 -0
- package/cmaps/UniKS-UTF16-V.bcmap +0 -0
- package/cmaps/UniKS-UTF32-H.bcmap +0 -0
- package/cmaps/UniKS-UTF32-V.bcmap +0 -0
- package/cmaps/UniKS-UTF8-H.bcmap +0 -0
- package/cmaps/UniKS-UTF8-V.bcmap +0 -0
- package/cmaps/V.bcmap +0 -0
- package/cmaps/WP-Symbol.bcmap +0 -0
- package/iccs/CGATS001Compat-v2-micro.icc +0 -0
- package/iccs/LICENSE +116 -0
- package/image_decoders/pdf.image_decoders.min.mjs +28 -0
- package/image_decoders/pdf.image_decoders.mjs +5378 -0
- package/image_decoders/pdf.image_decoders.mjs.map +1 -0
- package/legacy/build/pdf.d.mts +1 -0
- package/legacy/build/pdf.min.mjs +27 -0
- package/legacy/build/pdf.mjs +34799 -0
- package/legacy/build/pdf.mjs.map +1 -0
- package/legacy/build/pdf.sandbox.min.mjs +27 -0
- package/legacy/build/pdf.sandbox.mjs +2502 -0
- package/legacy/build/pdf.sandbox.mjs.map +1 -0
- package/legacy/build/pdf.worker.min.mjs +27 -0
- package/legacy/build/pdf.worker.mjs +71124 -0
- package/legacy/build/pdf.worker.mjs.map +1 -0
- package/legacy/image_decoders/pdf.image_decoders.min.mjs +27 -0
- package/legacy/image_decoders/pdf.image_decoders.mjs +9845 -0
- package/legacy/image_decoders/pdf.image_decoders.mjs.map +1 -0
- package/legacy/web/images/altText_add.svg +3 -0
- package/legacy/web/images/altText_disclaimer.svg +3 -0
- package/legacy/web/images/altText_done.svg +3 -0
- package/legacy/web/images/altText_spinner.svg +30 -0
- package/legacy/web/images/altText_warning.svg +3 -0
- package/legacy/web/images/annotation-check.svg +11 -0
- package/legacy/web/images/annotation-comment.svg +16 -0
- package/legacy/web/images/annotation-help.svg +26 -0
- package/legacy/web/images/annotation-insert.svg +10 -0
- package/legacy/web/images/annotation-key.svg +11 -0
- package/legacy/web/images/annotation-newparagraph.svg +11 -0
- package/legacy/web/images/annotation-noicon.svg +7 -0
- package/legacy/web/images/annotation-note.svg +42 -0
- package/legacy/web/images/annotation-paperclip.svg +6 -0
- package/legacy/web/images/annotation-paragraph.svg +16 -0
- package/legacy/web/images/annotation-pushpin.svg +7 -0
- package/legacy/web/images/checkmark.svg +5 -0
- package/legacy/web/images/comment-actionsButton.svg +3 -0
- package/legacy/web/images/comment-closeButton.svg +3 -0
- package/legacy/web/images/comment-editButton.svg +8 -0
- package/legacy/web/images/comment-popup-editButton.svg +5 -0
- package/legacy/web/images/cursor-editorFreeHighlight.svg +6 -0
- package/legacy/web/images/cursor-editorFreeText.svg +3 -0
- package/legacy/web/images/cursor-editorInk.svg +4 -0
- package/legacy/web/images/cursor-editorTextHighlight.svg +8 -0
- package/legacy/web/images/editor-toolbar-delete.svg +5 -0
- package/legacy/web/images/editor-toolbar-edit.svg +3 -0
- package/legacy/web/images/findbarButton-next.svg +3 -0
- package/legacy/web/images/findbarButton-previous.svg +3 -0
- package/legacy/web/images/gv-toolbarButton-download.svg +3 -0
- package/legacy/web/images/loading-icon.gif +0 -0
- package/legacy/web/images/loading.svg +1 -0
- package/legacy/web/images/messageBar_closingButton.svg +3 -0
- package/legacy/web/images/messageBar_info.svg +3 -0
- package/legacy/web/images/messageBar_warning.svg +3 -0
- package/legacy/web/images/pages_closeButton.svg +3 -0
- package/legacy/web/images/pages_selected.svg +7 -0
- package/legacy/web/images/pages_viewArrow.svg +3 -0
- package/legacy/web/images/pages_viewButton.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-documentProperties.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-firstPage.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-handTool.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-lastPage.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-rotateCcw.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-rotateCw.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-scrollHorizontal.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-scrollPage.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-scrollVertical.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-scrollWrapped.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-selectTool.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-spreadEven.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-spreadNone.svg +3 -0
- package/legacy/web/images/secondaryToolbarButton-spreadOdd.svg +3 -0
- package/legacy/web/images/signature-properties-row-check.svg +4 -0
- package/legacy/web/images/toolbarButton-bookmark.svg +3 -0
- package/legacy/web/images/toolbarButton-currentOutlineItem.svg +3 -0
- package/legacy/web/images/toolbarButton-download.svg +4 -0
- package/legacy/web/images/toolbarButton-editorFreeText.svg +5 -0
- package/legacy/web/images/toolbarButton-editorHighlight.svg +6 -0
- package/legacy/web/images/toolbarButton-editorInk.svg +4 -0
- package/legacy/web/images/toolbarButton-editorSignature.svg +6 -0
- package/legacy/web/images/toolbarButton-editorStamp.svg +8 -0
- package/legacy/web/images/toolbarButton-menuArrow.svg +3 -0
- package/legacy/web/images/toolbarButton-menuArrowNova.svg +3 -0
- package/legacy/web/images/toolbarButton-openFile.svg +3 -0
- package/legacy/web/images/toolbarButton-pageDown.svg +3 -0
- package/legacy/web/images/toolbarButton-pageUp.svg +3 -0
- package/legacy/web/images/toolbarButton-presentationMode.svg +3 -0
- package/legacy/web/images/toolbarButton-print.svg +3 -0
- package/legacy/web/images/toolbarButton-search.svg +3 -0
- package/legacy/web/images/toolbarButton-secondaryToolbarToggle.svg +3 -0
- package/legacy/web/images/toolbarButton-signaturePropertiesError.svg +7 -0
- package/legacy/web/images/toolbarButton-signaturePropertiesVerified.svg +7 -0
- package/legacy/web/images/toolbarButton-viewAttachments.svg +3 -0
- package/legacy/web/images/toolbarButton-viewLayers.svg +3 -0
- package/legacy/web/images/toolbarButton-viewOutline.svg +3 -0
- package/legacy/web/images/toolbarButton-viewThumbnail.svg +3 -0
- package/legacy/web/images/toolbarButton-viewsManagerToggle.svg +3 -0
- package/legacy/web/images/toolbarButton-zoomIn.svg +3 -0
- package/legacy/web/images/toolbarButton-zoomOut.svg +3 -0
- package/legacy/web/images/treeitem-collapsed.svg +1 -0
- package/legacy/web/images/treeitem-expanded.svg +1 -0
- package/legacy/web/pdf_viewer.css +6463 -0
- package/legacy/web/pdf_viewer.d.mts +1 -0
- package/legacy/web/pdf_viewer.mjs +14798 -0
- package/legacy/web/pdf_viewer.mjs.map +1 -0
- package/legacy/webpack.mjs +26 -0
- package/package.json +33 -4
- package/standard_fonts/FoxitDingbats.pfb +0 -0
- package/standard_fonts/FoxitFixed.pfb +0 -0
- package/standard_fonts/FoxitFixedBold.pfb +0 -0
- package/standard_fonts/FoxitFixedBoldItalic.pfb +0 -0
- package/standard_fonts/FoxitFixedItalic.pfb +0 -0
- package/standard_fonts/FoxitSerif.pfb +0 -0
- package/standard_fonts/FoxitSerifBold.pfb +0 -0
- package/standard_fonts/FoxitSerifBoldItalic.pfb +0 -0
- package/standard_fonts/FoxitSerifItalic.pfb +0 -0
- package/standard_fonts/FoxitSymbol.pfb +0 -0
- package/standard_fonts/LICENSE_FOXIT +27 -0
- package/standard_fonts/LICENSE_LIBERATION +363 -0
- package/standard_fonts/LiberationSans-Bold.ttf +0 -0
- package/standard_fonts/LiberationSans-BoldItalic.ttf +0 -0
- package/standard_fonts/LiberationSans-Italic.ttf +0 -0
- package/standard_fonts/LiberationSans-Regular.ttf +0 -0
- package/types/external/brotli/decode.d.ts +5 -0
- package/types/external/jbig2/jbig2.d.ts +2 -0
- package/types/external/openjpeg/openjpeg.d.ts +2 -0
- package/types/external/qcms/qcms.d.ts +96 -0
- package/types/external/qcms/qcms_utils.d.ts +9 -0
- package/types/src/core/ascii_85_stream.d.ts +7 -0
- package/types/src/core/ascii_hex_stream.d.ts +7 -0
- package/types/src/core/base_stream.d.ts +52 -0
- package/types/src/core/brotli_stream.d.ts +9 -0
- package/types/src/core/calculate_md5.d.ts +1 -0
- package/types/src/core/calculate_sha256.d.ts +1 -0
- package/types/src/core/calculate_sha_other.d.ts +2 -0
- package/types/src/core/catalog.d.ts +169 -0
- package/types/src/core/ccitt_stream.d.ts +18 -0
- package/types/src/core/cleanup_helper.d.ts +1 -0
- package/types/src/core/colorspace.d.ts +168 -0
- package/types/src/core/colorspace_utils.d.ts +21 -0
- package/types/src/core/core_utils.d.ts +136 -0
- package/types/src/core/crypto.d.ts +135 -0
- package/types/src/core/decode_stream.d.ts +32 -0
- package/types/src/core/decrypt_stream.d.ts +9 -0
- package/types/src/core/file_spec.d.ts +67 -0
- package/types/src/core/flate_stream.d.ts +14 -0
- package/types/src/core/icc_colorspace.d.ts +21 -0
- package/types/src/core/image_resizer.d.ts +24 -0
- package/types/src/core/image_utils.d.ts +52 -0
- package/types/src/core/jbig2_ccittFax.d.ts +13 -0
- package/types/src/core/jbig2_stream.d.ts +17 -0
- package/types/src/core/jpeg_stream.d.ts +24 -0
- package/types/src/core/jpg.d.ts +58 -0
- package/types/src/core/jpx.d.ts +24 -0
- package/types/src/core/jpx_stream.d.ts +15 -0
- package/types/src/core/lzw_stream.d.ts +19 -0
- package/types/src/core/metadata_parser.d.ts +13 -0
- package/types/src/core/name_number_tree.d.ts +21 -0
- package/types/src/core/parser.d.ts +119 -0
- package/types/src/core/pattern.d.ts +61 -0
- package/types/src/core/predictor_stream.d.ts +14 -0
- package/types/src/core/primitives.d.ts +95 -0
- package/types/src/core/run_length_stream.d.ts +6 -0
- package/types/src/core/sasl_prep.d.ts +1 -0
- package/types/src/core/sound.d.ts +39 -0
- package/types/src/core/stream.d.ts +20 -0
- package/types/src/core/string_utils.d.ts +5 -0
- package/types/src/core/struct_tree.d.ts +93 -0
- package/types/src/core/unicode.d.ts +5 -0
- package/types/src/core/wasm_image.d.ts +21 -0
- package/types/src/core/xml_parser.d.ts +78 -0
- package/types/src/core/xref.d.ts +39 -0
- package/types/src/display/annotation_layer.d.ts +265 -0
- package/types/src/display/annotation_storage.d.ts +94 -0
- package/types/src/display/api.d.ts +1693 -0
- package/types/src/display/api_utils.d.ts +13 -0
- package/types/src/display/binary_data_factory.d.ts +22 -0
- package/types/src/display/canvas.d.ts +257 -0
- package/types/src/display/canvas_dependency_tracker.d.ts +221 -0
- package/types/src/display/canvas_factory.d.ts +29 -0
- package/types/src/display/content_disposition.d.ts +6 -0
- package/types/src/display/display_utils.d.ts +172 -0
- package/types/src/display/draw_layer.d.ts +143 -0
- package/types/src/display/editor/alt_text.d.ts +34 -0
- package/types/src/display/editor/annotation_editor_layer.d.ts +226 -0
- package/types/src/display/editor/color_picker.d.ts +40 -0
- package/types/src/display/editor/comment.d.ts +59 -0
- package/types/src/display/editor/draw.d.ts +175 -0
- package/types/src/display/editor/drawers/contour.d.ts +3 -0
- package/types/src/display/editor/drawers/freedraw.d.ts +34 -0
- package/types/src/display/editor/drawers/highlight.d.ts +120 -0
- package/types/src/display/editor/drawers/inkdraw.d.ts +134 -0
- package/types/src/display/editor/drawers/outline.d.ts +81 -0
- package/types/src/display/editor/drawers/signaturedraw.d.ts +79 -0
- package/types/src/display/editor/editor.d.ts +581 -0
- package/types/src/display/editor/freetext.d.ts +63 -0
- package/types/src/display/editor/highlight.d.ts +85 -0
- package/types/src/display/editor/ink.d.ts +49 -0
- package/types/src/display/editor/signature.d.ts +77 -0
- package/types/src/display/editor/stamp.d.ts +49 -0
- package/types/src/display/editor/toolbar.d.ts +26 -0
- package/types/src/display/editor/tools.d.ts +503 -0
- package/types/src/display/fetch_stream.d.ts +7 -0
- package/types/src/display/filter_factory.d.ts +53 -0
- package/types/src/display/font_loader.d.ts +52 -0
- package/types/src/display/metadata.d.ts +10 -0
- package/types/src/display/network.d.ts +20 -0
- package/types/src/display/network_stream.d.ts +2 -0
- package/types/src/display/network_utils.d.ts +16 -0
- package/types/src/display/node_stream.d.ts +4 -0
- package/types/src/display/node_utils.d.ts +18 -0
- package/types/src/display/obj_bin_transform_display.d.ts +50 -0
- package/types/src/display/optional_content_config.d.ts +28 -0
- package/types/src/display/page_viewport.d.ts +137 -0
- package/types/src/display/pages_mapper.d.ts +78 -0
- package/types/src/display/pattern_helper.d.ts +88 -0
- package/types/src/display/pdf_objects.d.ts +38 -0
- package/types/src/display/svg_factory.d.ts +14 -0
- package/types/src/display/text_layer.d.ts +93 -0
- package/types/src/display/text_layer_images.d.ts +10 -0
- package/types/src/display/touch_manager.d.ts +55 -0
- package/types/src/display/transport_stream.d.ts +11 -0
- package/types/src/display/webgpu.d.ts +11 -0
- package/types/src/display/worker_options.d.ts +25 -0
- package/types/src/display/xfa_layer.d.ts +49 -0
- package/types/src/display/xfa_text.d.ts +18 -0
- package/types/src/pdf.d.ts +69 -0
- package/types/src/shared/base_pdf_stream.d.ts +120 -0
- package/types/src/shared/css_utils.d.ts +8 -0
- package/types/src/shared/image_utils.d.ts +28 -0
- package/types/src/shared/internal_evt.d.ts +7 -0
- package/types/src/shared/math_clamp.d.ts +1 -0
- package/types/src/shared/message_handler.d.ts +39 -0
- package/types/src/shared/murmurhash3.d.ts +7 -0
- package/types/src/shared/obj_bin_transform_utils.d.ts +27 -0
- package/types/src/shared/scripting_utils.d.ts +18 -0
- package/types/src/shared/util.d.ts +433 -0
- package/types/web/annotation_editor_layer_builder.d.ts +66 -0
- package/types/web/annotation_layer_builder.d.ts +107 -0
- package/types/web/app_options.d.ts +16 -0
- package/types/web/autolinker.d.ts +29 -0
- package/types/web/base_download_manager.d.ts +24 -0
- package/types/web/base_pdf_page_view.d.ts +29 -0
- package/types/web/comment_manager.d.ts +20 -0
- package/types/web/download_manager.d.ts +4 -0
- package/types/web/draw_layer_builder.d.ts +64 -0
- package/types/web/event_utils.d.ts +68 -0
- package/types/web/generic_scripting.d.ts +8 -0
- package/types/web/genericl10n.d.ts +18 -0
- package/types/web/internal_evt.d.ts +7 -0
- package/types/web/l10n.d.ts +31 -0
- package/types/web/menu.d.ts +11 -0
- package/types/web/pdf_find_controller.d.ts +142 -0
- package/types/web/pdf_find_utils.d.ts +10 -0
- package/types/web/pdf_history.d.ts +116 -0
- package/types/web/pdf_link_service.d.ts +148 -0
- package/types/web/pdf_page_detail_view.d.ts +27 -0
- package/types/web/pdf_page_view.d.ts +256 -0
- package/types/web/pdf_rendering_queue.d.ts +49 -0
- package/types/web/pdf_scripting_manager.component.d.ts +5 -0
- package/types/web/pdf_scripting_manager.d.ts +57 -0
- package/types/web/pdf_single_page_viewer.d.ts +7 -0
- package/types/web/pdf_thumbnail_view.d.ts +108 -0
- package/types/web/pdf_thumbnail_viewer.d.ts +179 -0
- package/types/web/pdf_viewer.component.d.ts +23 -0
- package/types/web/pdf_viewer.d.ts +653 -0
- package/types/web/renderable_view.d.ts +33 -0
- package/types/web/sidebar.d.ts +65 -0
- package/types/web/struct_tree_layer_builder.d.ts +39 -0
- package/types/web/text_accessibility.d.ts +46 -0
- package/types/web/text_highlighter.d.ts +62 -0
- package/types/web/text_layer_builder.d.ts +70 -0
- package/types/web/ui_utils.d.ts +260 -0
- package/types/web/xfa_layer_builder.d.ts +50 -0
- package/wasm/LICENSE_JBIG2 +196 -0
- package/wasm/LICENSE_OPENJPEG +39 -0
- package/wasm/LICENSE_PDFJS_JBIG2 +13 -0
- package/wasm/LICENSE_PDFJS_OPENJPEG +22 -0
- package/wasm/LICENSE_PDFJS_QCMS +19 -0
- package/wasm/LICENSE_QCMS +21 -0
- package/wasm/jbig2.wasm +0 -0
- package/wasm/jbig2_nowasm_fallback.js +15 -0
- package/wasm/openjpeg.wasm +0 -0
- package/wasm/openjpeg_nowasm_fallback.js +17 -0
- package/wasm/qcms_bg.wasm +0 -0
- package/wasm/quickjs-eval.js +16 -0
- package/wasm/quickjs-eval.wasm +0 -0
- package/web/images/altText_add.svg +3 -0
- package/web/images/altText_disclaimer.svg +3 -0
- package/web/images/altText_done.svg +3 -0
- package/web/images/altText_spinner.svg +30 -0
- package/web/images/altText_warning.svg +3 -0
- package/web/images/annotation-check.svg +11 -0
- package/web/images/annotation-comment.svg +16 -0
- package/web/images/annotation-help.svg +26 -0
- package/web/images/annotation-insert.svg +10 -0
- package/web/images/annotation-key.svg +11 -0
- package/web/images/annotation-newparagraph.svg +11 -0
- package/web/images/annotation-noicon.svg +7 -0
- package/web/images/annotation-note.svg +42 -0
- package/web/images/annotation-paperclip.svg +6 -0
- package/web/images/annotation-paragraph.svg +16 -0
- package/web/images/annotation-pushpin.svg +7 -0
- package/web/images/checkmark.svg +5 -0
- package/web/images/comment-actionsButton.svg +3 -0
- package/web/images/comment-closeButton.svg +3 -0
- package/web/images/comment-editButton.svg +8 -0
- package/web/images/comment-popup-editButton.svg +5 -0
- package/web/images/cursor-editorFreeHighlight.svg +6 -0
- package/web/images/cursor-editorFreeText.svg +3 -0
- package/web/images/cursor-editorInk.svg +4 -0
- package/web/images/cursor-editorTextHighlight.svg +8 -0
- package/web/images/editor-toolbar-delete.svg +5 -0
- package/web/images/editor-toolbar-edit.svg +3 -0
- package/web/images/findbarButton-next.svg +3 -0
- package/web/images/findbarButton-previous.svg +3 -0
- package/web/images/gv-toolbarButton-download.svg +3 -0
- package/web/images/loading-icon.gif +0 -0
- package/web/images/loading.svg +1 -0
- package/web/images/messageBar_closingButton.svg +3 -0
- package/web/images/messageBar_info.svg +3 -0
- package/web/images/messageBar_warning.svg +3 -0
- package/web/images/pages_closeButton.svg +3 -0
- package/web/images/pages_selected.svg +7 -0
- package/web/images/pages_viewArrow.svg +3 -0
- package/web/images/pages_viewButton.svg +3 -0
- package/web/images/secondaryToolbarButton-documentProperties.svg +3 -0
- package/web/images/secondaryToolbarButton-firstPage.svg +3 -0
- package/web/images/secondaryToolbarButton-handTool.svg +3 -0
- package/web/images/secondaryToolbarButton-lastPage.svg +3 -0
- package/web/images/secondaryToolbarButton-rotateCcw.svg +3 -0
- package/web/images/secondaryToolbarButton-rotateCw.svg +3 -0
- package/web/images/secondaryToolbarButton-scrollHorizontal.svg +3 -0
- package/web/images/secondaryToolbarButton-scrollPage.svg +3 -0
- package/web/images/secondaryToolbarButton-scrollVertical.svg +3 -0
- package/web/images/secondaryToolbarButton-scrollWrapped.svg +3 -0
- package/web/images/secondaryToolbarButton-selectTool.svg +3 -0
- package/web/images/secondaryToolbarButton-spreadEven.svg +3 -0
- package/web/images/secondaryToolbarButton-spreadNone.svg +3 -0
- package/web/images/secondaryToolbarButton-spreadOdd.svg +3 -0
- package/web/images/signature-properties-row-check.svg +4 -0
- package/web/images/toolbarButton-bookmark.svg +3 -0
- package/web/images/toolbarButton-currentOutlineItem.svg +3 -0
- package/web/images/toolbarButton-download.svg +4 -0
- package/web/images/toolbarButton-editorFreeText.svg +5 -0
- package/web/images/toolbarButton-editorHighlight.svg +6 -0
- package/web/images/toolbarButton-editorInk.svg +4 -0
- package/web/images/toolbarButton-editorSignature.svg +6 -0
- package/web/images/toolbarButton-editorStamp.svg +8 -0
- package/web/images/toolbarButton-menuArrow.svg +3 -0
- package/web/images/toolbarButton-menuArrowNova.svg +3 -0
- package/web/images/toolbarButton-openFile.svg +3 -0
- package/web/images/toolbarButton-pageDown.svg +3 -0
- package/web/images/toolbarButton-pageUp.svg +3 -0
- package/web/images/toolbarButton-presentationMode.svg +3 -0
- package/web/images/toolbarButton-print.svg +3 -0
- package/web/images/toolbarButton-search.svg +3 -0
- package/web/images/toolbarButton-secondaryToolbarToggle.svg +3 -0
- package/web/images/toolbarButton-signaturePropertiesError.svg +7 -0
- package/web/images/toolbarButton-signaturePropertiesVerified.svg +7 -0
- package/web/images/toolbarButton-viewAttachments.svg +3 -0
- package/web/images/toolbarButton-viewLayers.svg +3 -0
- package/web/images/toolbarButton-viewOutline.svg +3 -0
- package/web/images/toolbarButton-viewThumbnail.svg +3 -0
- package/web/images/toolbarButton-viewsManagerToggle.svg +3 -0
- package/web/images/toolbarButton-zoomIn.svg +3 -0
- package/web/images/toolbarButton-zoomOut.svg +3 -0
- package/web/images/treeitem-collapsed.svg +1 -0
- package/web/images/treeitem-expanded.svg +1 -0
- package/web/pdf_viewer.css +6463 -0
- package/web/pdf_viewer.d.mts +1 -0
- package/web/pdf_viewer.mjs +9811 -0
- package/web/pdf_viewer.mjs.map +1 -0
- package/webpack.mjs +26 -0
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
export type CipherConstructors = typeof AES128Cipher | typeof AES256Cipher | typeof ARCFourCipher | typeof NullCipher;
|
|
2
|
+
/**
|
|
3
|
+
* Find the appropriate cipher class based on the filter name.
|
|
4
|
+
*/
|
|
5
|
+
export type ResolveCipher = (filterName?: Name | null | undefined) => CipherConstructors;
|
|
6
|
+
export class AES128Cipher extends AESBaseCipher {
|
|
7
|
+
constructor(key: any);
|
|
8
|
+
_rcon: Uint8Array<ArrayBuffer>;
|
|
9
|
+
_cyclesOfRepetition: number;
|
|
10
|
+
_keySize: number;
|
|
11
|
+
_key: Uint8Array<ArrayBuffer>;
|
|
12
|
+
_expandKey(cipherKey: any): Uint8Array<ArrayBuffer>;
|
|
13
|
+
}
|
|
14
|
+
export class AES256Cipher extends AESBaseCipher {
|
|
15
|
+
constructor(key: any);
|
|
16
|
+
_cyclesOfRepetition: number;
|
|
17
|
+
_keySize: number;
|
|
18
|
+
_key: Uint8Array<ArrayBuffer>;
|
|
19
|
+
_expandKey(cipherKey: any): Uint8Array<ArrayBuffer>;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* @typedef {typeof AES128Cipher | typeof AES256Cipher | typeof ARCFourCipher
|
|
23
|
+
* | typeof NullCipher} CipherConstructors
|
|
24
|
+
*/
|
|
25
|
+
/**
|
|
26
|
+
* @callback ResolveCipher
|
|
27
|
+
* Find the appropriate cipher class based on the filter name.
|
|
28
|
+
* @param {Name | null} [filterName]
|
|
29
|
+
* Name.
|
|
30
|
+
* @returns {CipherConstructors}
|
|
31
|
+
* Cipher constructor.
|
|
32
|
+
*/
|
|
33
|
+
export class ARCFourCipher {
|
|
34
|
+
constructor(key: any);
|
|
35
|
+
a: number;
|
|
36
|
+
b: number;
|
|
37
|
+
s: Uint8Array<ArrayBuffer>;
|
|
38
|
+
encryptBlock(data: any): Uint8Array<any>;
|
|
39
|
+
decryptBlock(data: any): Uint8Array<any>;
|
|
40
|
+
encrypt(data: any): Uint8Array<any>;
|
|
41
|
+
}
|
|
42
|
+
export class CipherTransform {
|
|
43
|
+
/**
|
|
44
|
+
* @param {ResolveCipher} resolveCipher
|
|
45
|
+
* Resolve a cipher constructor from a crypt filter name.
|
|
46
|
+
* @param {Name | null} [stringFilterName]
|
|
47
|
+
* Default crypt filter for strings.
|
|
48
|
+
* @param {Name | null} [streamFilterName]
|
|
49
|
+
* Default crypt filter for streams.
|
|
50
|
+
*/
|
|
51
|
+
constructor(resolveCipher: ResolveCipher, stringFilterName?: Name | null, streamFilterName?: Name | null);
|
|
52
|
+
/** @type {Name | null} */
|
|
53
|
+
embeddedFilterName: Name | null;
|
|
54
|
+
resolveCipher: ResolveCipher;
|
|
55
|
+
streamFilterName: Name | null;
|
|
56
|
+
stringFilterName: Name | null;
|
|
57
|
+
/**
|
|
58
|
+
* @param {BaseStream} stream
|
|
59
|
+
* @param {number | null} length
|
|
60
|
+
* @param {Name | null} [cryptFilterName]
|
|
61
|
+
* @returns {DecryptStream}
|
|
62
|
+
*/
|
|
63
|
+
createStream(stream: BaseStream, length: number | null, cryptFilterName?: Name | null): DecryptStream;
|
|
64
|
+
decryptString(s: any): string;
|
|
65
|
+
encryptString(s: any): string;
|
|
66
|
+
#private;
|
|
67
|
+
}
|
|
68
|
+
export class CipherTransformFactory {
|
|
69
|
+
static get _defaultPasswordBytes(): any;
|
|
70
|
+
constructor(dict: any, fileId: any, password: any);
|
|
71
|
+
filterName: any;
|
|
72
|
+
dict: any;
|
|
73
|
+
algorithm: any;
|
|
74
|
+
cf: any;
|
|
75
|
+
stmf: any;
|
|
76
|
+
strf: any;
|
|
77
|
+
eff: any;
|
|
78
|
+
encryptMetadata: boolean;
|
|
79
|
+
encryptionKey: any;
|
|
80
|
+
/**
|
|
81
|
+
* Set password.
|
|
82
|
+
* @param {string} password
|
|
83
|
+
* New password.
|
|
84
|
+
* @returns {undefined}
|
|
85
|
+
* Nothing.
|
|
86
|
+
*/
|
|
87
|
+
setPassword(password: string): undefined;
|
|
88
|
+
/**
|
|
89
|
+
* @param {number} num
|
|
90
|
+
* Object number.
|
|
91
|
+
* @param {number} gen
|
|
92
|
+
* Generation number.
|
|
93
|
+
* @returns {CipherTransform}
|
|
94
|
+
* Cipher transform.
|
|
95
|
+
*/
|
|
96
|
+
createCipherTransform(num: number, gen: number): CipherTransform;
|
|
97
|
+
#private;
|
|
98
|
+
}
|
|
99
|
+
export class PDF17 extends PDFBase {
|
|
100
|
+
_hash(password: any, input: any, userBytes: any): Uint8Array<ArrayBuffer>;
|
|
101
|
+
}
|
|
102
|
+
export class PDF20 extends PDFBase {
|
|
103
|
+
_hash(password: any, input: any, userBytes: any): Uint8Array<ArrayBuffer>;
|
|
104
|
+
}
|
|
105
|
+
declare class NullCipher {
|
|
106
|
+
decryptBlock(data: any): any;
|
|
107
|
+
encrypt(data: any): any;
|
|
108
|
+
}
|
|
109
|
+
import { Name } from "./primitives.js";
|
|
110
|
+
declare class AESBaseCipher {
|
|
111
|
+
_s: Uint8Array<ArrayBuffer>;
|
|
112
|
+
_inv_s: Uint8Array<ArrayBuffer>;
|
|
113
|
+
_mix: Uint32Array<ArrayBuffer>;
|
|
114
|
+
_mixCol: Uint8Array<ArrayBuffer>;
|
|
115
|
+
buffer: Uint8Array<ArrayBuffer>;
|
|
116
|
+
bufferPosition: number;
|
|
117
|
+
_expandKey(cipherKey: any): void;
|
|
118
|
+
_decrypt(input: any, key: any): Uint8Array<ArrayBuffer>;
|
|
119
|
+
_encrypt(input: any, key: any): Uint8Array<ArrayBuffer>;
|
|
120
|
+
_decryptBlock2(data: any, finalize: any): Uint8Array<ArrayBuffer>;
|
|
121
|
+
bufferLength: number | undefined;
|
|
122
|
+
iv: any;
|
|
123
|
+
decryptBlock(data: any, finalize: any, iv?: null): any;
|
|
124
|
+
encrypt(data: any, iv: any): Uint8Array<ArrayBuffer>;
|
|
125
|
+
}
|
|
126
|
+
import type { BaseStream } from "./base_stream.js";
|
|
127
|
+
import { DecryptStream } from "./decrypt_stream.js";
|
|
128
|
+
declare class PDFBase {
|
|
129
|
+
_hash(password: any, input: any, userBytes: any): void;
|
|
130
|
+
checkOwnerPassword(password: any, ownerValidationSalt: any, userBytes: any, ownerPassword: any): boolean;
|
|
131
|
+
checkUserPassword(password: any, userValidationSalt: any, userPassword: any): boolean;
|
|
132
|
+
getOwnerKey(password: any, ownerKeySalt: any, userBytes: any, ownerEncryption: any): any;
|
|
133
|
+
getUserKey(password: any, userKeySalt: any, userEncryption: any): any;
|
|
134
|
+
}
|
|
135
|
+
export {};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
export class DecodeStream extends BaseStream {
|
|
2
|
+
constructor(maybeMinBufferLength: any);
|
|
3
|
+
buffer: Uint8Array<ArrayBuffer>;
|
|
4
|
+
bufferLength: number;
|
|
5
|
+
eof: boolean;
|
|
6
|
+
minBufferLength: number;
|
|
7
|
+
pos: number;
|
|
8
|
+
_rawMinBufferLength: any;
|
|
9
|
+
readBlock(): void;
|
|
10
|
+
ensureBuffer(requested: any): Uint8Array<ArrayBuffer>;
|
|
11
|
+
getByte(): number;
|
|
12
|
+
getBytes(length: any, decoderOptions?: null): Uint8Array<ArrayBuffer>;
|
|
13
|
+
getImageData(length: any, decoderOptions: any): Promise<any>;
|
|
14
|
+
asyncGetBytesFromDecompressionStream(name: any): Promise<{
|
|
15
|
+
decompressed: Uint8Array<ArrayBuffer>;
|
|
16
|
+
compressed: any;
|
|
17
|
+
} | {
|
|
18
|
+
decompressed: null;
|
|
19
|
+
compressed: any;
|
|
20
|
+
}>;
|
|
21
|
+
makeSubStream(start: any, length: any, dict?: null): Stream;
|
|
22
|
+
clone(): Stream;
|
|
23
|
+
getBaseStreams(): any;
|
|
24
|
+
}
|
|
25
|
+
export class StreamsSequenceStream extends DecodeStream {
|
|
26
|
+
constructor(streams: any, onError?: null);
|
|
27
|
+
streams: any;
|
|
28
|
+
_onError: any;
|
|
29
|
+
getBaseStreams(): any[] | null;
|
|
30
|
+
}
|
|
31
|
+
import { BaseStream } from "./base_stream.js";
|
|
32
|
+
import { Stream } from "./stream.js";
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @import { CatalogAttachmentContent } from "./catalog.js";
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* "A PDF file can refer to the contents of another file by using a File
|
|
6
|
+
* Specification (PDF 1.1)", see the spec (7.11) for more details.
|
|
7
|
+
* NOTE: Only embedded files are supported (as part of the attachments support)
|
|
8
|
+
* TODO: support the 'URL' file system (with caching if !/V), portable
|
|
9
|
+
* collections attributes and related files (/RF)
|
|
10
|
+
*/
|
|
11
|
+
export class FileSpec {
|
|
12
|
+
/**
|
|
13
|
+
* Get a platform-specific item from a file-spec dictionary.
|
|
14
|
+
*
|
|
15
|
+
* Search order follows the PDF platform keys: `UF`, `F`, `Unix`, `Mac`,
|
|
16
|
+
* `DOS`.
|
|
17
|
+
* @param {Dict | null | undefined} dict
|
|
18
|
+
* Dictionary.
|
|
19
|
+
* @param {boolean} [raw]
|
|
20
|
+
* Return the raw (possibly indirect) value rather than the resolved one.
|
|
21
|
+
* @returns {unknown}
|
|
22
|
+
* Matching dictionary value or `null` when no key is found.
|
|
23
|
+
*/
|
|
24
|
+
static pickPlatformItem(dict: Dict | null | undefined, raw?: boolean): unknown;
|
|
25
|
+
/**
|
|
26
|
+
* Whether a file specification carries an embedded file we can read.
|
|
27
|
+
* @param {Dict} fileSpecDict
|
|
28
|
+
* @returns {boolean}
|
|
29
|
+
*/
|
|
30
|
+
static hasEmbeddedFile(fileSpecDict: Dict): boolean;
|
|
31
|
+
/**
|
|
32
|
+
* Read attachment bytes from a file-spec dictionary.
|
|
33
|
+
* @param {Dict | null | undefined} dict
|
|
34
|
+
* File-spec dictionary containing an `EF` entry.
|
|
35
|
+
* @returns {CatalogAttachmentContent}
|
|
36
|
+
* Attachment bytes when available; otherwise `null`.
|
|
37
|
+
* @throws {PasswordException}
|
|
38
|
+
* When attachment bytes are encrypted and no key is available.
|
|
39
|
+
*/
|
|
40
|
+
static readContent(dict: Dict | null | undefined): CatalogAttachmentContent;
|
|
41
|
+
/**
|
|
42
|
+
* Read the bytes of an embedded-file stream.
|
|
43
|
+
* @param {BaseStream} stream
|
|
44
|
+
* Embedded-file stream.
|
|
45
|
+
* @returns {CatalogAttachmentContent}
|
|
46
|
+
* Attachment bytes.
|
|
47
|
+
* @throws {PasswordException}
|
|
48
|
+
* When the bytes are encrypted and no key is available.
|
|
49
|
+
*/
|
|
50
|
+
static readStreamContent(stream: BaseStream): CatalogAttachmentContent;
|
|
51
|
+
/**
|
|
52
|
+
* @param {Dict | null | undefined} root
|
|
53
|
+
* File specification dictionary.
|
|
54
|
+
*/
|
|
55
|
+
constructor(root: Dict | null | undefined);
|
|
56
|
+
root: Dict | undefined;
|
|
57
|
+
get filename(): any;
|
|
58
|
+
get description(): any;
|
|
59
|
+
get serializable(): {
|
|
60
|
+
rawFilename: any;
|
|
61
|
+
filename: any;
|
|
62
|
+
description: any;
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
import { Dict } from "./primitives.js";
|
|
66
|
+
import type { CatalogAttachmentContent } from "./catalog.js";
|
|
67
|
+
import { BaseStream } from "./base_stream.js";
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export class FlateStream extends DecodeStream {
|
|
2
|
+
constructor(str: any, maybeLength: any);
|
|
3
|
+
stream: any;
|
|
4
|
+
dict: any;
|
|
5
|
+
codeSize: number;
|
|
6
|
+
codeBuf: number;
|
|
7
|
+
getImageData(length: any, _decoderOptions: any): Promise<Uint8Array<ArrayBuffer>>;
|
|
8
|
+
asyncGetBytes(): Promise<Uint8Array<ArrayBuffer> | null>;
|
|
9
|
+
getBits(bits: any): number;
|
|
10
|
+
getCode(table: any): number;
|
|
11
|
+
generateHuffmanTable(lengths: any): (number | Int32Array<ArrayBuffer>)[];
|
|
12
|
+
#private;
|
|
13
|
+
}
|
|
14
|
+
import { DecodeStream } from "./decode_stream.js";
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export class CmykICCBasedCS extends IccColorSpace {
|
|
2
|
+
static #iccUrl: any;
|
|
3
|
+
static setOptions({ iccUrl }: {
|
|
4
|
+
iccUrl: any;
|
|
5
|
+
}): void;
|
|
6
|
+
constructor();
|
|
7
|
+
}
|
|
8
|
+
export class IccColorSpace extends ColorSpace {
|
|
9
|
+
static #useWasm: boolean;
|
|
10
|
+
static #wasmUrl: null;
|
|
11
|
+
static #finalizer: null;
|
|
12
|
+
static setOptions({ useWasm, useWorkerFetch, wasmUrl }: {
|
|
13
|
+
useWasm: any;
|
|
14
|
+
useWorkerFetch: any;
|
|
15
|
+
wasmUrl: any;
|
|
16
|
+
}): void;
|
|
17
|
+
static get isUsable(): any;
|
|
18
|
+
constructor(iccProfile: any, name: any, numComps: any);
|
|
19
|
+
#private;
|
|
20
|
+
}
|
|
21
|
+
import { ColorSpace } from "./colorspace.js";
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export class ImageResizer {
|
|
2
|
+
static #goodSquareLength: number;
|
|
3
|
+
static #isImageDecoderSupported: any;
|
|
4
|
+
static get canUseImageDecoder(): any;
|
|
5
|
+
static needsToBeResized(width: any, height: any): boolean;
|
|
6
|
+
static set MAX_AREA(area: any);
|
|
7
|
+
static get MAX_AREA(): any;
|
|
8
|
+
static getReducePower(width: any, height: any, maxArea?: number): number;
|
|
9
|
+
static getReducePowerForJPX(width: any, height: any, componentsCount: any): number;
|
|
10
|
+
static get MAX_DIM(): any;
|
|
11
|
+
static setOptions({ canvasMaxAreaInBytes, isImageDecoderSupported, }: {
|
|
12
|
+
canvasMaxAreaInBytes?: number | undefined;
|
|
13
|
+
isImageDecoderSupported?: boolean | undefined;
|
|
14
|
+
}): void;
|
|
15
|
+
static _areGoodDims(width: any, height: any): boolean;
|
|
16
|
+
static _guessMax(start: any, end: any, tolerance: any, defaultHeight: any): any;
|
|
17
|
+
static createImage(imgData: any, isMask?: boolean): Promise<any>;
|
|
18
|
+
constructor(imgData: any, isMask: any);
|
|
19
|
+
_imgData: any;
|
|
20
|
+
_isMask: any;
|
|
21
|
+
_createImage(): Promise<any>;
|
|
22
|
+
_encodeBMP(): Uint8Array<any>;
|
|
23
|
+
#private;
|
|
24
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
export class GlobalColorSpaceCache extends BaseLocalCache {
|
|
2
|
+
set(name: null | undefined, ref: any, data: any): void;
|
|
3
|
+
clear(): void;
|
|
4
|
+
}
|
|
5
|
+
export class GlobalImageCache {
|
|
6
|
+
static NUM_PAGES_THRESHOLD: number;
|
|
7
|
+
static MIN_IMAGES_TO_CACHE: number;
|
|
8
|
+
static MAX_BYTE_SIZE: number;
|
|
9
|
+
_refCache: RefMap;
|
|
10
|
+
_imageCache: RefMap;
|
|
11
|
+
shouldCache(ref: any, pageIndex: any): boolean;
|
|
12
|
+
addDecodeFailed(ref: any): void;
|
|
13
|
+
hasDecodeFailed(ref: any): boolean;
|
|
14
|
+
/**
|
|
15
|
+
* PLEASE NOTE: Must be called *after* the `setData` method.
|
|
16
|
+
*/
|
|
17
|
+
addByteSize(ref: any, byteSize: any): void;
|
|
18
|
+
getData(ref: any, pageIndex: any): any;
|
|
19
|
+
setData(ref: any, data: any): void;
|
|
20
|
+
clear(onlyData?: boolean): void;
|
|
21
|
+
#private;
|
|
22
|
+
}
|
|
23
|
+
export class LocalColorSpaceCache extends BaseLocalCache {
|
|
24
|
+
set(name: null | undefined, ref: null | undefined, data: any): void;
|
|
25
|
+
}
|
|
26
|
+
export class LocalFunctionCache extends BaseLocalCache {
|
|
27
|
+
set(name: null | undefined, ref: any, data: any): void;
|
|
28
|
+
}
|
|
29
|
+
export class LocalGStateCache extends BaseLocalCache {
|
|
30
|
+
set(name: any, ref: null | undefined, data: any): void;
|
|
31
|
+
}
|
|
32
|
+
export class LocalImageCache extends BaseLocalCache {
|
|
33
|
+
set(name: any, ref: null | undefined, data: any): void;
|
|
34
|
+
}
|
|
35
|
+
export class LocalTilingPatternCache extends BaseLocalCache {
|
|
36
|
+
set(name: null | undefined, ref: any, data: any): void;
|
|
37
|
+
}
|
|
38
|
+
export class RegionalImageCache extends BaseLocalCache {
|
|
39
|
+
set(name: null | undefined, ref: any, data: any): void;
|
|
40
|
+
}
|
|
41
|
+
declare class BaseLocalCache {
|
|
42
|
+
constructor(options: any);
|
|
43
|
+
_onlyRefs: boolean;
|
|
44
|
+
_nameRefMap: Map<any, any> | undefined;
|
|
45
|
+
_imageMap: Map<any, any> | undefined;
|
|
46
|
+
_imageCache: RefMap;
|
|
47
|
+
getByName(name: any): any;
|
|
48
|
+
getByRef(ref: any): any;
|
|
49
|
+
set(name: any, ref: any, data: any): void;
|
|
50
|
+
}
|
|
51
|
+
import { RefMap } from "./primitives.js";
|
|
52
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export class JBig2CCITTFaxImage extends WasmImage {
|
|
2
|
+
static get instance(): any;
|
|
3
|
+
_filename: string;
|
|
4
|
+
_noWasmFilename: string;
|
|
5
|
+
decode(bytes: any, width: any, height: any, globals: any, CCITTOptions: any): Promise<never>;
|
|
6
|
+
}
|
|
7
|
+
declare const Jbig2Error_base: any;
|
|
8
|
+
export class Jbig2Error extends Jbig2Error_base {
|
|
9
|
+
[x: string]: any;
|
|
10
|
+
constructor(msg: any);
|
|
11
|
+
}
|
|
12
|
+
import { WasmImage } from "./wasm_image.js";
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* For JBIG2's we use a library to decode these images and
|
|
3
|
+
* the stream behaves like all the other DecodeStreams.
|
|
4
|
+
*/
|
|
5
|
+
export class Jbig2Stream extends DecodeStream {
|
|
6
|
+
static stripFileHeader(bytes: any): any;
|
|
7
|
+
constructor(stream: any, maybeLength: any, params: any);
|
|
8
|
+
stream: any;
|
|
9
|
+
dict: any;
|
|
10
|
+
maybeLength: any;
|
|
11
|
+
params: any;
|
|
12
|
+
get bytes(): any;
|
|
13
|
+
ensureBuffer(requested: any): void;
|
|
14
|
+
decodeImage(bytes: any, length: any, _decoderOptions: any): Promise<Uint8Array<ArrayBuffer>>;
|
|
15
|
+
get canAsyncDecodeImageFromBuffer(): any;
|
|
16
|
+
}
|
|
17
|
+
import { DecodeStream } from "./decode_stream.js";
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* For JPEG's we use a library to decode these images and the stream behaves
|
|
3
|
+
* like all the other DecodeStreams.
|
|
4
|
+
*/
|
|
5
|
+
export class JpegStream extends DecodeStream {
|
|
6
|
+
static #isImageDecoderSupported: any;
|
|
7
|
+
static get canUseImageDecoder(): any;
|
|
8
|
+
static setOptions({ isImageDecoderSupported }: {
|
|
9
|
+
isImageDecoderSupported?: boolean | undefined;
|
|
10
|
+
}): void;
|
|
11
|
+
constructor(stream: any, maybeLength: any, params: any);
|
|
12
|
+
stream: any;
|
|
13
|
+
dict: any;
|
|
14
|
+
maybeLength: any;
|
|
15
|
+
params: any;
|
|
16
|
+
get bytes(): any;
|
|
17
|
+
ensureBuffer(requested: any): void;
|
|
18
|
+
get jpegOptions(): any;
|
|
19
|
+
decodeImage(bytes: any): Uint8Array<ArrayBuffer>;
|
|
20
|
+
get canAsyncDecodeImageFromBuffer(): any;
|
|
21
|
+
getTransferableImage(width: any, height: any): Promise<VideoFrame | null>;
|
|
22
|
+
#private;
|
|
23
|
+
}
|
|
24
|
+
import { DecodeStream } from "./decode_stream.js";
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
declare const JpegError_base: any;
|
|
2
|
+
export class JpegError extends JpegError_base {
|
|
3
|
+
[x: string]: any;
|
|
4
|
+
constructor(msg: any);
|
|
5
|
+
}
|
|
6
|
+
export class JpegImage {
|
|
7
|
+
static canUseImageDecoder(data: any, colorTransform?: number): {
|
|
8
|
+
width: number;
|
|
9
|
+
height: number;
|
|
10
|
+
exifStart: number;
|
|
11
|
+
exifEnd: number;
|
|
12
|
+
} | null;
|
|
13
|
+
constructor(options: any);
|
|
14
|
+
_colorTransform: any;
|
|
15
|
+
_decodeTransform: any;
|
|
16
|
+
_isSourcePDF: boolean | undefined;
|
|
17
|
+
parse(data: any, { dnlScanLines }?: {
|
|
18
|
+
dnlScanLines?: null | undefined;
|
|
19
|
+
}): any;
|
|
20
|
+
width: any;
|
|
21
|
+
height: any;
|
|
22
|
+
jfif: {
|
|
23
|
+
version: {
|
|
24
|
+
major: any;
|
|
25
|
+
minor: any;
|
|
26
|
+
};
|
|
27
|
+
densityUnits: any;
|
|
28
|
+
xDensity: number;
|
|
29
|
+
yDensity: number;
|
|
30
|
+
thumbWidth: any;
|
|
31
|
+
thumbHeight: any;
|
|
32
|
+
thumbData: any;
|
|
33
|
+
} | null | undefined;
|
|
34
|
+
adobe: {
|
|
35
|
+
version: number;
|
|
36
|
+
flags0: number;
|
|
37
|
+
flags1: number;
|
|
38
|
+
transformCode: any;
|
|
39
|
+
} | null | undefined;
|
|
40
|
+
components: any[] | undefined;
|
|
41
|
+
numComponents: number | undefined;
|
|
42
|
+
get _isColorConversionNeeded(): boolean;
|
|
43
|
+
_convertYccToRgb(data: any): any;
|
|
44
|
+
_convertYccToRgba(data: any, out: any): any;
|
|
45
|
+
_convertYcckToRgb(data: any): any;
|
|
46
|
+
_convertYcckToRgba(data: any): any;
|
|
47
|
+
_convertYcckToCmyk(data: any): any;
|
|
48
|
+
_convertCmykToRgb(data: any): any;
|
|
49
|
+
_convertCmykToRgba(data: any): any;
|
|
50
|
+
getData({ width, height, forceRGBA, forceRGB }: {
|
|
51
|
+
width: any;
|
|
52
|
+
height: any;
|
|
53
|
+
forceRGBA?: boolean | undefined;
|
|
54
|
+
forceRGB?: boolean | undefined;
|
|
55
|
+
}, ...args: any[]): any;
|
|
56
|
+
#private;
|
|
57
|
+
}
|
|
58
|
+
export {};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
declare const JpxError_base: any;
|
|
2
|
+
export class JpxError extends JpxError_base {
|
|
3
|
+
[x: string]: any;
|
|
4
|
+
constructor(msg: any);
|
|
5
|
+
}
|
|
6
|
+
export class JpxImage extends WasmImage {
|
|
7
|
+
static get instance(): any;
|
|
8
|
+
static parseImageProperties(stream: any): {
|
|
9
|
+
width: number;
|
|
10
|
+
height: number;
|
|
11
|
+
bitsPerComponent: number;
|
|
12
|
+
componentsCount: any;
|
|
13
|
+
};
|
|
14
|
+
_filename: string;
|
|
15
|
+
_noWasmFilename: string;
|
|
16
|
+
decode(bytes: any, { numComponents, isIndexedColormap, smaskInData, reducePower, }?: {
|
|
17
|
+
numComponents?: number | undefined;
|
|
18
|
+
isIndexedColormap?: boolean | undefined;
|
|
19
|
+
smaskInData?: boolean | undefined;
|
|
20
|
+
reducePower?: number | undefined;
|
|
21
|
+
}): Promise<never>;
|
|
22
|
+
}
|
|
23
|
+
import { WasmImage } from "./wasm_image.js";
|
|
24
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* For JPEG 2000's we use a library to decode these images and
|
|
3
|
+
* the stream behaves like all the other DecodeStreams.
|
|
4
|
+
*/
|
|
5
|
+
export class JpxStream extends DecodeStream {
|
|
6
|
+
constructor(stream: any, maybeLength: any);
|
|
7
|
+
stream: any;
|
|
8
|
+
dict: any;
|
|
9
|
+
maybeLength: any;
|
|
10
|
+
get bytes(): any;
|
|
11
|
+
ensureBuffer(requested: any): void;
|
|
12
|
+
decodeImage(bytes: any, _length: any, decoderOptions: any): Promise<Uint8Array<ArrayBuffer>>;
|
|
13
|
+
get canAsyncDecodeImageFromBuffer(): any;
|
|
14
|
+
}
|
|
15
|
+
import { DecodeStream } from "./decode_stream.js";
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export class LZWStream extends DecodeStream {
|
|
2
|
+
constructor(str: any, maybeLength: any, earlyChange: any);
|
|
3
|
+
stream: any;
|
|
4
|
+
dict: any;
|
|
5
|
+
cachedData: number;
|
|
6
|
+
bitsCached: number;
|
|
7
|
+
lzwState: {
|
|
8
|
+
earlyChange: any;
|
|
9
|
+
codeLength: number;
|
|
10
|
+
nextCode: number;
|
|
11
|
+
dictionaryValues: Uint8Array<ArrayBuffer>;
|
|
12
|
+
dictionaryLengths: Uint16Array<ArrayBuffer>;
|
|
13
|
+
dictionaryPrevCodes: Uint16Array<ArrayBuffer>;
|
|
14
|
+
currentSequence: Uint8Array<ArrayBuffer>;
|
|
15
|
+
currentSequenceLength: number;
|
|
16
|
+
};
|
|
17
|
+
readBits(n: any): number | null;
|
|
18
|
+
}
|
|
19
|
+
import { DecodeStream } from "./decode_stream.js";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export class MetadataParser {
|
|
2
|
+
constructor(data: any);
|
|
3
|
+
_metadataMap: Map<any, any>;
|
|
4
|
+
_data: any;
|
|
5
|
+
_repair(data: any): any;
|
|
6
|
+
_getSequence(entry: any): any;
|
|
7
|
+
_parseArray(entry: any): void;
|
|
8
|
+
_parse(xmlDocument: any): void;
|
|
9
|
+
get serializable(): {
|
|
10
|
+
parsedData: Map<any, any>;
|
|
11
|
+
rawData: any;
|
|
12
|
+
};
|
|
13
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export class NameTree extends NameOrNumberTree {
|
|
2
|
+
constructor(root: any, xref: any);
|
|
3
|
+
}
|
|
4
|
+
export class NumberTree extends NameOrNumberTree {
|
|
5
|
+
constructor(root: any, xref: any);
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* A NameTree/NumberTree is like a Dict but has some advantageous properties,
|
|
9
|
+
* see the specification (7.9.6 and 7.9.7) for additional details.
|
|
10
|
+
* TODO: implement all the Dict functions and make this more efficient.
|
|
11
|
+
*/
|
|
12
|
+
declare class NameOrNumberTree {
|
|
13
|
+
constructor(root: any, xref: any, type: any);
|
|
14
|
+
root: any;
|
|
15
|
+
xref: any;
|
|
16
|
+
_type: any;
|
|
17
|
+
getAll(isRaw?: boolean): Map<any, any>;
|
|
18
|
+
getRaw(key: any): any;
|
|
19
|
+
get(key: any): any;
|
|
20
|
+
}
|
|
21
|
+
export {};
|