@box/pdfjs-dist 0.0.0-stage → 6.4.299-box.1

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 (554) hide show
  1. package/CODE_OF_CONDUCT.md +15 -0
  2. package/LICENSE +177 -0
  3. package/README.md +13 -2
  4. package/build/pdf.min.mjs +28 -0
  5. package/build/pdf.mjs +28211 -0
  6. package/build/pdf.mjs.map +1 -0
  7. package/build/pdf.sandbox.min.mjs +28 -0
  8. package/build/pdf.sandbox.mjs +211 -0
  9. package/build/pdf.sandbox.mjs.map +1 -0
  10. package/build/pdf.worker.min.mjs +28 -0
  11. package/build/pdf.worker.mjs +64908 -0
  12. package/build/pdf.worker.mjs.map +1 -0
  13. package/cmaps/78-EUC-H.bcmap +0 -0
  14. package/cmaps/78-EUC-V.bcmap +0 -0
  15. package/cmaps/78-H.bcmap +0 -0
  16. package/cmaps/78-RKSJ-H.bcmap +0 -0
  17. package/cmaps/78-RKSJ-V.bcmap +0 -0
  18. package/cmaps/78-V.bcmap +0 -0
  19. package/cmaps/78ms-RKSJ-H.bcmap +0 -0
  20. package/cmaps/78ms-RKSJ-V.bcmap +0 -0
  21. package/cmaps/83pv-RKSJ-H.bcmap +0 -0
  22. package/cmaps/90ms-RKSJ-H.bcmap +0 -0
  23. package/cmaps/90ms-RKSJ-V.bcmap +0 -0
  24. package/cmaps/90msp-RKSJ-H.bcmap +0 -0
  25. package/cmaps/90msp-RKSJ-V.bcmap +0 -0
  26. package/cmaps/90pv-RKSJ-H.bcmap +0 -0
  27. package/cmaps/90pv-RKSJ-V.bcmap +0 -0
  28. package/cmaps/Add-H.bcmap +0 -0
  29. package/cmaps/Add-RKSJ-H.bcmap +0 -0
  30. package/cmaps/Add-RKSJ-V.bcmap +0 -0
  31. package/cmaps/Add-V.bcmap +0 -0
  32. package/cmaps/Adobe-CNS1-0.bcmap +0 -0
  33. package/cmaps/Adobe-CNS1-1.bcmap +0 -0
  34. package/cmaps/Adobe-CNS1-2.bcmap +0 -0
  35. package/cmaps/Adobe-CNS1-3.bcmap +0 -0
  36. package/cmaps/Adobe-CNS1-4.bcmap +0 -0
  37. package/cmaps/Adobe-CNS1-5.bcmap +0 -0
  38. package/cmaps/Adobe-CNS1-6.bcmap +0 -0
  39. package/cmaps/Adobe-CNS1-UCS2.bcmap +0 -0
  40. package/cmaps/Adobe-GB1-0.bcmap +0 -0
  41. package/cmaps/Adobe-GB1-1.bcmap +0 -0
  42. package/cmaps/Adobe-GB1-2.bcmap +0 -0
  43. package/cmaps/Adobe-GB1-3.bcmap +0 -0
  44. package/cmaps/Adobe-GB1-4.bcmap +0 -0
  45. package/cmaps/Adobe-GB1-5.bcmap +0 -0
  46. package/cmaps/Adobe-GB1-UCS2.bcmap +0 -0
  47. package/cmaps/Adobe-Japan1-0.bcmap +0 -0
  48. package/cmaps/Adobe-Japan1-1.bcmap +0 -0
  49. package/cmaps/Adobe-Japan1-2.bcmap +0 -0
  50. package/cmaps/Adobe-Japan1-3.bcmap +0 -0
  51. package/cmaps/Adobe-Japan1-4.bcmap +0 -0
  52. package/cmaps/Adobe-Japan1-5.bcmap +0 -0
  53. package/cmaps/Adobe-Japan1-6.bcmap +0 -0
  54. package/cmaps/Adobe-Japan1-UCS2.bcmap +0 -0
  55. package/cmaps/Adobe-Korea1-0.bcmap +0 -0
  56. package/cmaps/Adobe-Korea1-1.bcmap +0 -0
  57. package/cmaps/Adobe-Korea1-2.bcmap +0 -0
  58. package/cmaps/Adobe-Korea1-UCS2.bcmap +0 -0
  59. package/cmaps/B5-H.bcmap +0 -0
  60. package/cmaps/B5-V.bcmap +0 -0
  61. package/cmaps/B5pc-H.bcmap +0 -0
  62. package/cmaps/B5pc-V.bcmap +0 -0
  63. package/cmaps/CNS-EUC-H.bcmap +0 -0
  64. package/cmaps/CNS-EUC-V.bcmap +0 -0
  65. package/cmaps/CNS1-H.bcmap +0 -0
  66. package/cmaps/CNS1-V.bcmap +0 -0
  67. package/cmaps/CNS2-H.bcmap +0 -0
  68. package/cmaps/CNS2-V.bcmap +3 -0
  69. package/cmaps/ETHK-B5-H.bcmap +0 -0
  70. package/cmaps/ETHK-B5-V.bcmap +0 -0
  71. package/cmaps/ETen-B5-H.bcmap +0 -0
  72. package/cmaps/ETen-B5-V.bcmap +0 -0
  73. package/cmaps/ETenms-B5-H.bcmap +3 -0
  74. package/cmaps/ETenms-B5-V.bcmap +0 -0
  75. package/cmaps/EUC-H.bcmap +0 -0
  76. package/cmaps/EUC-V.bcmap +0 -0
  77. package/cmaps/Ext-H.bcmap +0 -0
  78. package/cmaps/Ext-RKSJ-H.bcmap +0 -0
  79. package/cmaps/Ext-RKSJ-V.bcmap +0 -0
  80. package/cmaps/Ext-V.bcmap +0 -0
  81. package/cmaps/GB-EUC-H.bcmap +0 -0
  82. package/cmaps/GB-EUC-V.bcmap +0 -0
  83. package/cmaps/GB-H.bcmap +4 -0
  84. package/cmaps/GB-V.bcmap +0 -0
  85. package/cmaps/GBK-EUC-H.bcmap +0 -0
  86. package/cmaps/GBK-EUC-V.bcmap +0 -0
  87. package/cmaps/GBK2K-H.bcmap +0 -0
  88. package/cmaps/GBK2K-V.bcmap +0 -0
  89. package/cmaps/GBKp-EUC-H.bcmap +0 -0
  90. package/cmaps/GBKp-EUC-V.bcmap +0 -0
  91. package/cmaps/GBT-EUC-H.bcmap +0 -0
  92. package/cmaps/GBT-EUC-V.bcmap +0 -0
  93. package/cmaps/GBT-H.bcmap +0 -0
  94. package/cmaps/GBT-V.bcmap +0 -0
  95. package/cmaps/GBTpc-EUC-H.bcmap +0 -0
  96. package/cmaps/GBTpc-EUC-V.bcmap +0 -0
  97. package/cmaps/GBpc-EUC-H.bcmap +0 -0
  98. package/cmaps/GBpc-EUC-V.bcmap +0 -0
  99. package/cmaps/H.bcmap +0 -0
  100. package/cmaps/HKdla-B5-H.bcmap +0 -0
  101. package/cmaps/HKdla-B5-V.bcmap +0 -0
  102. package/cmaps/HKdlb-B5-H.bcmap +0 -0
  103. package/cmaps/HKdlb-B5-V.bcmap +0 -0
  104. package/cmaps/HKgccs-B5-H.bcmap +0 -0
  105. package/cmaps/HKgccs-B5-V.bcmap +0 -0
  106. package/cmaps/HKm314-B5-H.bcmap +0 -0
  107. package/cmaps/HKm314-B5-V.bcmap +0 -0
  108. package/cmaps/HKm471-B5-H.bcmap +0 -0
  109. package/cmaps/HKm471-B5-V.bcmap +0 -0
  110. package/cmaps/HKscs-B5-H.bcmap +0 -0
  111. package/cmaps/HKscs-B5-V.bcmap +0 -0
  112. package/cmaps/Hankaku.bcmap +0 -0
  113. package/cmaps/Hiragana.bcmap +0 -0
  114. package/cmaps/KSC-EUC-H.bcmap +0 -0
  115. package/cmaps/KSC-EUC-V.bcmap +0 -0
  116. package/cmaps/KSC-H.bcmap +0 -0
  117. package/cmaps/KSC-Johab-H.bcmap +0 -0
  118. package/cmaps/KSC-Johab-V.bcmap +0 -0
  119. package/cmaps/KSC-V.bcmap +0 -0
  120. package/cmaps/KSCms-UHC-H.bcmap +0 -0
  121. package/cmaps/KSCms-UHC-HW-H.bcmap +0 -0
  122. package/cmaps/KSCms-UHC-HW-V.bcmap +0 -0
  123. package/cmaps/KSCms-UHC-V.bcmap +0 -0
  124. package/cmaps/KSCpc-EUC-H.bcmap +0 -0
  125. package/cmaps/KSCpc-EUC-V.bcmap +0 -0
  126. package/cmaps/Katakana.bcmap +0 -0
  127. package/cmaps/LICENSE +36 -0
  128. package/cmaps/NWP-H.bcmap +0 -0
  129. package/cmaps/NWP-V.bcmap +0 -0
  130. package/cmaps/RKSJ-H.bcmap +0 -0
  131. package/cmaps/RKSJ-V.bcmap +0 -0
  132. package/cmaps/Roman.bcmap +0 -0
  133. package/cmaps/UniCNS-UCS2-H.bcmap +0 -0
  134. package/cmaps/UniCNS-UCS2-V.bcmap +0 -0
  135. package/cmaps/UniCNS-UTF16-H.bcmap +0 -0
  136. package/cmaps/UniCNS-UTF16-V.bcmap +0 -0
  137. package/cmaps/UniCNS-UTF32-H.bcmap +0 -0
  138. package/cmaps/UniCNS-UTF32-V.bcmap +0 -0
  139. package/cmaps/UniCNS-UTF8-H.bcmap +0 -0
  140. package/cmaps/UniCNS-UTF8-V.bcmap +0 -0
  141. package/cmaps/UniGB-UCS2-H.bcmap +0 -0
  142. package/cmaps/UniGB-UCS2-V.bcmap +0 -0
  143. package/cmaps/UniGB-UTF16-H.bcmap +0 -0
  144. package/cmaps/UniGB-UTF16-V.bcmap +0 -0
  145. package/cmaps/UniGB-UTF32-H.bcmap +0 -0
  146. package/cmaps/UniGB-UTF32-V.bcmap +0 -0
  147. package/cmaps/UniGB-UTF8-H.bcmap +0 -0
  148. package/cmaps/UniGB-UTF8-V.bcmap +0 -0
  149. package/cmaps/UniJIS-UCS2-H.bcmap +0 -0
  150. package/cmaps/UniJIS-UCS2-HW-H.bcmap +0 -0
  151. package/cmaps/UniJIS-UCS2-HW-V.bcmap +0 -0
  152. package/cmaps/UniJIS-UCS2-V.bcmap +0 -0
  153. package/cmaps/UniJIS-UTF16-H.bcmap +0 -0
  154. package/cmaps/UniJIS-UTF16-V.bcmap +0 -0
  155. package/cmaps/UniJIS-UTF32-H.bcmap +0 -0
  156. package/cmaps/UniJIS-UTF32-V.bcmap +0 -0
  157. package/cmaps/UniJIS-UTF8-H.bcmap +0 -0
  158. package/cmaps/UniJIS-UTF8-V.bcmap +0 -0
  159. package/cmaps/UniJIS2004-UTF16-H.bcmap +0 -0
  160. package/cmaps/UniJIS2004-UTF16-V.bcmap +0 -0
  161. package/cmaps/UniJIS2004-UTF32-H.bcmap +0 -0
  162. package/cmaps/UniJIS2004-UTF32-V.bcmap +0 -0
  163. package/cmaps/UniJIS2004-UTF8-H.bcmap +0 -0
  164. package/cmaps/UniJIS2004-UTF8-V.bcmap +0 -0
  165. package/cmaps/UniJISPro-UCS2-HW-V.bcmap +0 -0
  166. package/cmaps/UniJISPro-UCS2-V.bcmap +0 -0
  167. package/cmaps/UniJISPro-UTF8-V.bcmap +0 -0
  168. package/cmaps/UniJISX0213-UTF32-H.bcmap +0 -0
  169. package/cmaps/UniJISX0213-UTF32-V.bcmap +0 -0
  170. package/cmaps/UniJISX02132004-UTF32-H.bcmap +0 -0
  171. package/cmaps/UniJISX02132004-UTF32-V.bcmap +0 -0
  172. package/cmaps/UniKS-UCS2-H.bcmap +0 -0
  173. package/cmaps/UniKS-UCS2-V.bcmap +0 -0
  174. package/cmaps/UniKS-UTF16-H.bcmap +0 -0
  175. package/cmaps/UniKS-UTF16-V.bcmap +0 -0
  176. package/cmaps/UniKS-UTF32-H.bcmap +0 -0
  177. package/cmaps/UniKS-UTF32-V.bcmap +0 -0
  178. package/cmaps/UniKS-UTF8-H.bcmap +0 -0
  179. package/cmaps/UniKS-UTF8-V.bcmap +0 -0
  180. package/cmaps/V.bcmap +0 -0
  181. package/cmaps/WP-Symbol.bcmap +0 -0
  182. package/iccs/CGATS001Compat-v2-micro.icc +0 -0
  183. package/iccs/LICENSE +116 -0
  184. package/image_decoders/pdf.image_decoders.min.mjs +28 -0
  185. package/image_decoders/pdf.image_decoders.mjs +5378 -0
  186. package/image_decoders/pdf.image_decoders.mjs.map +1 -0
  187. package/legacy/build/pdf.d.mts +1 -0
  188. package/legacy/build/pdf.min.mjs +27 -0
  189. package/legacy/build/pdf.mjs +34672 -0
  190. package/legacy/build/pdf.mjs.map +1 -0
  191. package/legacy/build/pdf.sandbox.min.mjs +27 -0
  192. package/legacy/build/pdf.sandbox.mjs +2502 -0
  193. package/legacy/build/pdf.sandbox.mjs.map +1 -0
  194. package/legacy/build/pdf.worker.min.mjs +27 -0
  195. package/legacy/build/pdf.worker.mjs +71124 -0
  196. package/legacy/build/pdf.worker.mjs.map +1 -0
  197. package/legacy/image_decoders/pdf.image_decoders.min.mjs +27 -0
  198. package/legacy/image_decoders/pdf.image_decoders.mjs +9845 -0
  199. package/legacy/image_decoders/pdf.image_decoders.mjs.map +1 -0
  200. package/legacy/web/images/altText_add.svg +3 -0
  201. package/legacy/web/images/altText_disclaimer.svg +3 -0
  202. package/legacy/web/images/altText_done.svg +3 -0
  203. package/legacy/web/images/altText_spinner.svg +30 -0
  204. package/legacy/web/images/altText_warning.svg +3 -0
  205. package/legacy/web/images/annotation-check.svg +11 -0
  206. package/legacy/web/images/annotation-comment.svg +16 -0
  207. package/legacy/web/images/annotation-help.svg +26 -0
  208. package/legacy/web/images/annotation-insert.svg +10 -0
  209. package/legacy/web/images/annotation-key.svg +11 -0
  210. package/legacy/web/images/annotation-newparagraph.svg +11 -0
  211. package/legacy/web/images/annotation-noicon.svg +7 -0
  212. package/legacy/web/images/annotation-note.svg +42 -0
  213. package/legacy/web/images/annotation-paperclip.svg +6 -0
  214. package/legacy/web/images/annotation-paragraph.svg +16 -0
  215. package/legacy/web/images/annotation-pushpin.svg +7 -0
  216. package/legacy/web/images/checkmark.svg +5 -0
  217. package/legacy/web/images/comment-actionsButton.svg +3 -0
  218. package/legacy/web/images/comment-closeButton.svg +3 -0
  219. package/legacy/web/images/comment-editButton.svg +8 -0
  220. package/legacy/web/images/comment-popup-editButton.svg +5 -0
  221. package/legacy/web/images/cursor-editorFreeHighlight.svg +6 -0
  222. package/legacy/web/images/cursor-editorFreeText.svg +3 -0
  223. package/legacy/web/images/cursor-editorInk.svg +4 -0
  224. package/legacy/web/images/cursor-editorTextHighlight.svg +8 -0
  225. package/legacy/web/images/editor-toolbar-delete.svg +5 -0
  226. package/legacy/web/images/editor-toolbar-edit.svg +3 -0
  227. package/legacy/web/images/findbarButton-next.svg +3 -0
  228. package/legacy/web/images/findbarButton-previous.svg +3 -0
  229. package/legacy/web/images/gv-toolbarButton-download.svg +3 -0
  230. package/legacy/web/images/loading-icon.gif +0 -0
  231. package/legacy/web/images/loading.svg +1 -0
  232. package/legacy/web/images/messageBar_closingButton.svg +3 -0
  233. package/legacy/web/images/messageBar_info.svg +3 -0
  234. package/legacy/web/images/messageBar_warning.svg +3 -0
  235. package/legacy/web/images/pages_closeButton.svg +3 -0
  236. package/legacy/web/images/pages_selected.svg +7 -0
  237. package/legacy/web/images/pages_viewArrow.svg +3 -0
  238. package/legacy/web/images/pages_viewButton.svg +3 -0
  239. package/legacy/web/images/secondaryToolbarButton-documentProperties.svg +3 -0
  240. package/legacy/web/images/secondaryToolbarButton-firstPage.svg +3 -0
  241. package/legacy/web/images/secondaryToolbarButton-handTool.svg +3 -0
  242. package/legacy/web/images/secondaryToolbarButton-lastPage.svg +3 -0
  243. package/legacy/web/images/secondaryToolbarButton-rotateCcw.svg +3 -0
  244. package/legacy/web/images/secondaryToolbarButton-rotateCw.svg +3 -0
  245. package/legacy/web/images/secondaryToolbarButton-scrollHorizontal.svg +3 -0
  246. package/legacy/web/images/secondaryToolbarButton-scrollPage.svg +3 -0
  247. package/legacy/web/images/secondaryToolbarButton-scrollVertical.svg +3 -0
  248. package/legacy/web/images/secondaryToolbarButton-scrollWrapped.svg +3 -0
  249. package/legacy/web/images/secondaryToolbarButton-selectTool.svg +3 -0
  250. package/legacy/web/images/secondaryToolbarButton-spreadEven.svg +3 -0
  251. package/legacy/web/images/secondaryToolbarButton-spreadNone.svg +3 -0
  252. package/legacy/web/images/secondaryToolbarButton-spreadOdd.svg +3 -0
  253. package/legacy/web/images/signature-properties-row-check.svg +4 -0
  254. package/legacy/web/images/toolbarButton-bookmark.svg +3 -0
  255. package/legacy/web/images/toolbarButton-currentOutlineItem.svg +3 -0
  256. package/legacy/web/images/toolbarButton-download.svg +4 -0
  257. package/legacy/web/images/toolbarButton-editorFreeText.svg +5 -0
  258. package/legacy/web/images/toolbarButton-editorHighlight.svg +6 -0
  259. package/legacy/web/images/toolbarButton-editorInk.svg +4 -0
  260. package/legacy/web/images/toolbarButton-editorSignature.svg +6 -0
  261. package/legacy/web/images/toolbarButton-editorStamp.svg +8 -0
  262. package/legacy/web/images/toolbarButton-menuArrow.svg +3 -0
  263. package/legacy/web/images/toolbarButton-menuArrowNova.svg +3 -0
  264. package/legacy/web/images/toolbarButton-openFile.svg +3 -0
  265. package/legacy/web/images/toolbarButton-pageDown.svg +3 -0
  266. package/legacy/web/images/toolbarButton-pageUp.svg +3 -0
  267. package/legacy/web/images/toolbarButton-presentationMode.svg +3 -0
  268. package/legacy/web/images/toolbarButton-print.svg +3 -0
  269. package/legacy/web/images/toolbarButton-search.svg +3 -0
  270. package/legacy/web/images/toolbarButton-secondaryToolbarToggle.svg +3 -0
  271. package/legacy/web/images/toolbarButton-signaturePropertiesError.svg +7 -0
  272. package/legacy/web/images/toolbarButton-signaturePropertiesVerified.svg +7 -0
  273. package/legacy/web/images/toolbarButton-viewAttachments.svg +3 -0
  274. package/legacy/web/images/toolbarButton-viewLayers.svg +3 -0
  275. package/legacy/web/images/toolbarButton-viewOutline.svg +3 -0
  276. package/legacy/web/images/toolbarButton-viewThumbnail.svg +3 -0
  277. package/legacy/web/images/toolbarButton-viewsManagerToggle.svg +3 -0
  278. package/legacy/web/images/toolbarButton-zoomIn.svg +3 -0
  279. package/legacy/web/images/toolbarButton-zoomOut.svg +3 -0
  280. package/legacy/web/images/treeitem-collapsed.svg +1 -0
  281. package/legacy/web/images/treeitem-expanded.svg +1 -0
  282. package/legacy/web/pdf_viewer.css +6463 -0
  283. package/legacy/web/pdf_viewer.d.mts +1 -0
  284. package/legacy/web/pdf_viewer.mjs +14798 -0
  285. package/legacy/web/pdf_viewer.mjs.map +1 -0
  286. package/legacy/webpack.mjs +26 -0
  287. package/package.json +32 -4
  288. package/standard_fonts/FoxitDingbats.pfb +0 -0
  289. package/standard_fonts/FoxitFixed.pfb +0 -0
  290. package/standard_fonts/FoxitFixedBold.pfb +0 -0
  291. package/standard_fonts/FoxitFixedBoldItalic.pfb +0 -0
  292. package/standard_fonts/FoxitFixedItalic.pfb +0 -0
  293. package/standard_fonts/FoxitSerif.pfb +0 -0
  294. package/standard_fonts/FoxitSerifBold.pfb +0 -0
  295. package/standard_fonts/FoxitSerifBoldItalic.pfb +0 -0
  296. package/standard_fonts/FoxitSerifItalic.pfb +0 -0
  297. package/standard_fonts/FoxitSymbol.pfb +0 -0
  298. package/standard_fonts/LICENSE_FOXIT +27 -0
  299. package/standard_fonts/LICENSE_LIBERATION +363 -0
  300. package/standard_fonts/LiberationSans-Bold.ttf +0 -0
  301. package/standard_fonts/LiberationSans-BoldItalic.ttf +0 -0
  302. package/standard_fonts/LiberationSans-Italic.ttf +0 -0
  303. package/standard_fonts/LiberationSans-Regular.ttf +0 -0
  304. package/types/external/brotli/decode.d.ts +5 -0
  305. package/types/external/jbig2/jbig2.d.ts +2 -0
  306. package/types/external/openjpeg/openjpeg.d.ts +2 -0
  307. package/types/external/qcms/qcms.d.ts +96 -0
  308. package/types/external/qcms/qcms_utils.d.ts +9 -0
  309. package/types/src/core/ascii_85_stream.d.ts +7 -0
  310. package/types/src/core/ascii_hex_stream.d.ts +7 -0
  311. package/types/src/core/base_stream.d.ts +52 -0
  312. package/types/src/core/brotli_stream.d.ts +9 -0
  313. package/types/src/core/calculate_md5.d.ts +1 -0
  314. package/types/src/core/calculate_sha256.d.ts +1 -0
  315. package/types/src/core/calculate_sha_other.d.ts +2 -0
  316. package/types/src/core/catalog.d.ts +169 -0
  317. package/types/src/core/ccitt_stream.d.ts +18 -0
  318. package/types/src/core/cleanup_helper.d.ts +1 -0
  319. package/types/src/core/colorspace.d.ts +168 -0
  320. package/types/src/core/colorspace_utils.d.ts +21 -0
  321. package/types/src/core/core_utils.d.ts +136 -0
  322. package/types/src/core/crypto.d.ts +135 -0
  323. package/types/src/core/decode_stream.d.ts +32 -0
  324. package/types/src/core/decrypt_stream.d.ts +9 -0
  325. package/types/src/core/file_spec.d.ts +67 -0
  326. package/types/src/core/flate_stream.d.ts +14 -0
  327. package/types/src/core/icc_colorspace.d.ts +21 -0
  328. package/types/src/core/image_resizer.d.ts +24 -0
  329. package/types/src/core/image_utils.d.ts +52 -0
  330. package/types/src/core/jbig2_ccittFax.d.ts +13 -0
  331. package/types/src/core/jbig2_stream.d.ts +17 -0
  332. package/types/src/core/jpeg_stream.d.ts +24 -0
  333. package/types/src/core/jpg.d.ts +58 -0
  334. package/types/src/core/jpx.d.ts +24 -0
  335. package/types/src/core/jpx_stream.d.ts +15 -0
  336. package/types/src/core/lzw_stream.d.ts +19 -0
  337. package/types/src/core/metadata_parser.d.ts +13 -0
  338. package/types/src/core/name_number_tree.d.ts +21 -0
  339. package/types/src/core/parser.d.ts +119 -0
  340. package/types/src/core/pattern.d.ts +61 -0
  341. package/types/src/core/predictor_stream.d.ts +14 -0
  342. package/types/src/core/primitives.d.ts +95 -0
  343. package/types/src/core/run_length_stream.d.ts +6 -0
  344. package/types/src/core/sasl_prep.d.ts +1 -0
  345. package/types/src/core/sound.d.ts +39 -0
  346. package/types/src/core/stream.d.ts +20 -0
  347. package/types/src/core/string_utils.d.ts +5 -0
  348. package/types/src/core/struct_tree.d.ts +93 -0
  349. package/types/src/core/unicode.d.ts +5 -0
  350. package/types/src/core/wasm_image.d.ts +21 -0
  351. package/types/src/core/xml_parser.d.ts +78 -0
  352. package/types/src/core/xref.d.ts +39 -0
  353. package/types/src/display/annotation_layer.d.ts +265 -0
  354. package/types/src/display/annotation_storage.d.ts +94 -0
  355. package/types/src/display/api.d.ts +1693 -0
  356. package/types/src/display/api_utils.d.ts +13 -0
  357. package/types/src/display/binary_data_factory.d.ts +22 -0
  358. package/types/src/display/canvas.d.ts +257 -0
  359. package/types/src/display/canvas_dependency_tracker.d.ts +221 -0
  360. package/types/src/display/canvas_factory.d.ts +29 -0
  361. package/types/src/display/content_disposition.d.ts +6 -0
  362. package/types/src/display/display_utils.d.ts +129 -0
  363. package/types/src/display/draw_layer.d.ts +143 -0
  364. package/types/src/display/editor/alt_text.d.ts +34 -0
  365. package/types/src/display/editor/annotation_editor_layer.d.ts +226 -0
  366. package/types/src/display/editor/color_picker.d.ts +40 -0
  367. package/types/src/display/editor/comment.d.ts +59 -0
  368. package/types/src/display/editor/draw.d.ts +175 -0
  369. package/types/src/display/editor/drawers/contour.d.ts +3 -0
  370. package/types/src/display/editor/drawers/freedraw.d.ts +34 -0
  371. package/types/src/display/editor/drawers/highlight.d.ts +120 -0
  372. package/types/src/display/editor/drawers/inkdraw.d.ts +134 -0
  373. package/types/src/display/editor/drawers/outline.d.ts +81 -0
  374. package/types/src/display/editor/drawers/signaturedraw.d.ts +79 -0
  375. package/types/src/display/editor/editor.d.ts +581 -0
  376. package/types/src/display/editor/freetext.d.ts +63 -0
  377. package/types/src/display/editor/highlight.d.ts +85 -0
  378. package/types/src/display/editor/ink.d.ts +49 -0
  379. package/types/src/display/editor/signature.d.ts +77 -0
  380. package/types/src/display/editor/stamp.d.ts +49 -0
  381. package/types/src/display/editor/toolbar.d.ts +26 -0
  382. package/types/src/display/editor/tools.d.ts +503 -0
  383. package/types/src/display/fetch_stream.d.ts +7 -0
  384. package/types/src/display/filter_factory.d.ts +53 -0
  385. package/types/src/display/font_loader.d.ts +52 -0
  386. package/types/src/display/metadata.d.ts +10 -0
  387. package/types/src/display/network.d.ts +20 -0
  388. package/types/src/display/network_stream.d.ts +2 -0
  389. package/types/src/display/network_utils.d.ts +16 -0
  390. package/types/src/display/node_stream.d.ts +4 -0
  391. package/types/src/display/node_utils.d.ts +18 -0
  392. package/types/src/display/obj_bin_transform_display.d.ts +50 -0
  393. package/types/src/display/optional_content_config.d.ts +28 -0
  394. package/types/src/display/page_viewport.d.ts +137 -0
  395. package/types/src/display/pages_mapper.d.ts +78 -0
  396. package/types/src/display/pattern_helper.d.ts +88 -0
  397. package/types/src/display/pdf_objects.d.ts +38 -0
  398. package/types/src/display/svg_factory.d.ts +14 -0
  399. package/types/src/display/text_layer.d.ts +93 -0
  400. package/types/src/display/text_layer_images.d.ts +10 -0
  401. package/types/src/display/touch_manager.d.ts +55 -0
  402. package/types/src/display/transport_stream.d.ts +11 -0
  403. package/types/src/display/webgpu.d.ts +11 -0
  404. package/types/src/display/worker_options.d.ts +25 -0
  405. package/types/src/display/xfa_layer.d.ts +49 -0
  406. package/types/src/display/xfa_text.d.ts +18 -0
  407. package/types/src/pdf.d.ts +69 -0
  408. package/types/src/shared/base_pdf_stream.d.ts +120 -0
  409. package/types/src/shared/css_utils.d.ts +8 -0
  410. package/types/src/shared/image_utils.d.ts +28 -0
  411. package/types/src/shared/internal_evt.d.ts +7 -0
  412. package/types/src/shared/math_clamp.d.ts +1 -0
  413. package/types/src/shared/message_handler.d.ts +39 -0
  414. package/types/src/shared/murmurhash3.d.ts +7 -0
  415. package/types/src/shared/obj_bin_transform_utils.d.ts +27 -0
  416. package/types/src/shared/scripting_utils.d.ts +18 -0
  417. package/types/src/shared/util.d.ts +433 -0
  418. package/types/web/annotation_editor_layer_builder.d.ts +66 -0
  419. package/types/web/annotation_layer_builder.d.ts +107 -0
  420. package/types/web/app_options.d.ts +16 -0
  421. package/types/web/autolinker.d.ts +29 -0
  422. package/types/web/base_download_manager.d.ts +24 -0
  423. package/types/web/base_pdf_page_view.d.ts +29 -0
  424. package/types/web/comment_manager.d.ts +20 -0
  425. package/types/web/download_manager.d.ts +4 -0
  426. package/types/web/draw_layer_builder.d.ts +64 -0
  427. package/types/web/event_utils.d.ts +68 -0
  428. package/types/web/generic_scripting.d.ts +8 -0
  429. package/types/web/genericl10n.d.ts +18 -0
  430. package/types/web/internal_evt.d.ts +7 -0
  431. package/types/web/l10n.d.ts +31 -0
  432. package/types/web/menu.d.ts +11 -0
  433. package/types/web/pdf_find_controller.d.ts +142 -0
  434. package/types/web/pdf_find_utils.d.ts +10 -0
  435. package/types/web/pdf_history.d.ts +116 -0
  436. package/types/web/pdf_link_service.d.ts +148 -0
  437. package/types/web/pdf_page_detail_view.d.ts +27 -0
  438. package/types/web/pdf_page_view.d.ts +256 -0
  439. package/types/web/pdf_rendering_queue.d.ts +49 -0
  440. package/types/web/pdf_scripting_manager.component.d.ts +5 -0
  441. package/types/web/pdf_scripting_manager.d.ts +57 -0
  442. package/types/web/pdf_single_page_viewer.d.ts +7 -0
  443. package/types/web/pdf_thumbnail_view.d.ts +108 -0
  444. package/types/web/pdf_thumbnail_viewer.d.ts +179 -0
  445. package/types/web/pdf_viewer.component.d.ts +23 -0
  446. package/types/web/pdf_viewer.d.ts +653 -0
  447. package/types/web/renderable_view.d.ts +33 -0
  448. package/types/web/sidebar.d.ts +65 -0
  449. package/types/web/struct_tree_layer_builder.d.ts +39 -0
  450. package/types/web/text_accessibility.d.ts +46 -0
  451. package/types/web/text_highlighter.d.ts +62 -0
  452. package/types/web/text_layer_builder.d.ts +70 -0
  453. package/types/web/ui_utils.d.ts +260 -0
  454. package/types/web/xfa_layer_builder.d.ts +50 -0
  455. package/wasm/LICENSE_JBIG2 +196 -0
  456. package/wasm/LICENSE_OPENJPEG +39 -0
  457. package/wasm/LICENSE_PDFJS_JBIG2 +13 -0
  458. package/wasm/LICENSE_PDFJS_OPENJPEG +22 -0
  459. package/wasm/LICENSE_PDFJS_QCMS +19 -0
  460. package/wasm/LICENSE_QCMS +21 -0
  461. package/wasm/jbig2.wasm +0 -0
  462. package/wasm/jbig2_nowasm_fallback.js +15 -0
  463. package/wasm/openjpeg.wasm +0 -0
  464. package/wasm/openjpeg_nowasm_fallback.js +17 -0
  465. package/wasm/qcms_bg.wasm +0 -0
  466. package/wasm/quickjs-eval.js +16 -0
  467. package/wasm/quickjs-eval.wasm +0 -0
  468. package/web/images/altText_add.svg +3 -0
  469. package/web/images/altText_disclaimer.svg +3 -0
  470. package/web/images/altText_done.svg +3 -0
  471. package/web/images/altText_spinner.svg +30 -0
  472. package/web/images/altText_warning.svg +3 -0
  473. package/web/images/annotation-check.svg +11 -0
  474. package/web/images/annotation-comment.svg +16 -0
  475. package/web/images/annotation-help.svg +26 -0
  476. package/web/images/annotation-insert.svg +10 -0
  477. package/web/images/annotation-key.svg +11 -0
  478. package/web/images/annotation-newparagraph.svg +11 -0
  479. package/web/images/annotation-noicon.svg +7 -0
  480. package/web/images/annotation-note.svg +42 -0
  481. package/web/images/annotation-paperclip.svg +6 -0
  482. package/web/images/annotation-paragraph.svg +16 -0
  483. package/web/images/annotation-pushpin.svg +7 -0
  484. package/web/images/checkmark.svg +5 -0
  485. package/web/images/comment-actionsButton.svg +3 -0
  486. package/web/images/comment-closeButton.svg +3 -0
  487. package/web/images/comment-editButton.svg +8 -0
  488. package/web/images/comment-popup-editButton.svg +5 -0
  489. package/web/images/cursor-editorFreeHighlight.svg +6 -0
  490. package/web/images/cursor-editorFreeText.svg +3 -0
  491. package/web/images/cursor-editorInk.svg +4 -0
  492. package/web/images/cursor-editorTextHighlight.svg +8 -0
  493. package/web/images/editor-toolbar-delete.svg +5 -0
  494. package/web/images/editor-toolbar-edit.svg +3 -0
  495. package/web/images/findbarButton-next.svg +3 -0
  496. package/web/images/findbarButton-previous.svg +3 -0
  497. package/web/images/gv-toolbarButton-download.svg +3 -0
  498. package/web/images/loading-icon.gif +0 -0
  499. package/web/images/loading.svg +1 -0
  500. package/web/images/messageBar_closingButton.svg +3 -0
  501. package/web/images/messageBar_info.svg +3 -0
  502. package/web/images/messageBar_warning.svg +3 -0
  503. package/web/images/pages_closeButton.svg +3 -0
  504. package/web/images/pages_selected.svg +7 -0
  505. package/web/images/pages_viewArrow.svg +3 -0
  506. package/web/images/pages_viewButton.svg +3 -0
  507. package/web/images/secondaryToolbarButton-documentProperties.svg +3 -0
  508. package/web/images/secondaryToolbarButton-firstPage.svg +3 -0
  509. package/web/images/secondaryToolbarButton-handTool.svg +3 -0
  510. package/web/images/secondaryToolbarButton-lastPage.svg +3 -0
  511. package/web/images/secondaryToolbarButton-rotateCcw.svg +3 -0
  512. package/web/images/secondaryToolbarButton-rotateCw.svg +3 -0
  513. package/web/images/secondaryToolbarButton-scrollHorizontal.svg +3 -0
  514. package/web/images/secondaryToolbarButton-scrollPage.svg +3 -0
  515. package/web/images/secondaryToolbarButton-scrollVertical.svg +3 -0
  516. package/web/images/secondaryToolbarButton-scrollWrapped.svg +3 -0
  517. package/web/images/secondaryToolbarButton-selectTool.svg +3 -0
  518. package/web/images/secondaryToolbarButton-spreadEven.svg +3 -0
  519. package/web/images/secondaryToolbarButton-spreadNone.svg +3 -0
  520. package/web/images/secondaryToolbarButton-spreadOdd.svg +3 -0
  521. package/web/images/signature-properties-row-check.svg +4 -0
  522. package/web/images/toolbarButton-bookmark.svg +3 -0
  523. package/web/images/toolbarButton-currentOutlineItem.svg +3 -0
  524. package/web/images/toolbarButton-download.svg +4 -0
  525. package/web/images/toolbarButton-editorFreeText.svg +5 -0
  526. package/web/images/toolbarButton-editorHighlight.svg +6 -0
  527. package/web/images/toolbarButton-editorInk.svg +4 -0
  528. package/web/images/toolbarButton-editorSignature.svg +6 -0
  529. package/web/images/toolbarButton-editorStamp.svg +8 -0
  530. package/web/images/toolbarButton-menuArrow.svg +3 -0
  531. package/web/images/toolbarButton-menuArrowNova.svg +3 -0
  532. package/web/images/toolbarButton-openFile.svg +3 -0
  533. package/web/images/toolbarButton-pageDown.svg +3 -0
  534. package/web/images/toolbarButton-pageUp.svg +3 -0
  535. package/web/images/toolbarButton-presentationMode.svg +3 -0
  536. package/web/images/toolbarButton-print.svg +3 -0
  537. package/web/images/toolbarButton-search.svg +3 -0
  538. package/web/images/toolbarButton-secondaryToolbarToggle.svg +3 -0
  539. package/web/images/toolbarButton-signaturePropertiesError.svg +7 -0
  540. package/web/images/toolbarButton-signaturePropertiesVerified.svg +7 -0
  541. package/web/images/toolbarButton-viewAttachments.svg +3 -0
  542. package/web/images/toolbarButton-viewLayers.svg +3 -0
  543. package/web/images/toolbarButton-viewOutline.svg +3 -0
  544. package/web/images/toolbarButton-viewThumbnail.svg +3 -0
  545. package/web/images/toolbarButton-viewsManagerToggle.svg +3 -0
  546. package/web/images/toolbarButton-zoomIn.svg +3 -0
  547. package/web/images/toolbarButton-zoomOut.svg +3 -0
  548. package/web/images/treeitem-collapsed.svg +1 -0
  549. package/web/images/treeitem-expanded.svg +1 -0
  550. package/web/pdf_viewer.css +6463 -0
  551. package/web/pdf_viewer.d.mts +1 -0
  552. package/web/pdf_viewer.mjs +9811 -0
  553. package/web/pdf_viewer.mjs.map +1 -0
  554. package/webpack.mjs +26 -0
@@ -0,0 +1,13 @@
1
+ export function getDataProp(val: any): Uint8Array<any>;
2
+ export function getFactoryUrlProp(val: any): string | null;
3
+ export function getUrlProp(val: any): URL | null;
4
+ export function isNameProxy(v: any): boolean;
5
+ export function isRefProxy(v: any): boolean;
6
+ export const isValidExplicitDest: (dest?: any) => boolean;
7
+ export class LoopbackPort {
8
+ postMessage(obj: any, transfer: any): void;
9
+ addEventListener(name: any, listener: any, options?: null): void;
10
+ removeEventListener(name: any, listener: any): void;
11
+ terminate(): void;
12
+ #private;
13
+ }
@@ -0,0 +1,22 @@
1
+ export class BaseBinaryDataFactory {
2
+ constructor({ cMapUrl, standardFontDataUrl, wasmUrl }: {
3
+ cMapUrl?: null | undefined;
4
+ standardFontDataUrl?: null | undefined;
5
+ wasmUrl?: null | undefined;
6
+ });
7
+ cMapUrl: any;
8
+ standardFontDataUrl: any;
9
+ wasmUrl: any;
10
+ fetch({ kind, filename }: {
11
+ kind: any;
12
+ filename: any;
13
+ }): Promise<Uint8Array<ArrayBufferLike>>;
14
+ /**
15
+ * @ignore
16
+ * @returns {Promise<Uint8Array>}
17
+ */
18
+ _fetch(url: any, kind: any): Promise<Uint8Array>;
19
+ #private;
20
+ }
21
+ export class DOMBinaryDataFactory extends BaseBinaryDataFactory {
22
+ }
@@ -0,0 +1,257 @@
1
+ export class CanvasGraphics {
2
+ static #SCALE_MATRIX: null;
3
+ constructor(canvasCtx: any, commonObjs: any, objs: any, canvasFactory: any, filterFactory: any, { optionalContentConfig, markedContentStack }: {
4
+ optionalContentConfig: any;
5
+ markedContentStack?: null | undefined;
6
+ }, annotationCanvasMap: any, pageColors: any, dependencyTracker: any, imagesTracker: any);
7
+ ctx: any;
8
+ current: CanvasExtraState;
9
+ stateStack: any[];
10
+ pendingClip: {} | {} | null;
11
+ pendingEOFill: boolean;
12
+ commonObjs: any;
13
+ objs: any;
14
+ canvasFactory: any;
15
+ filterFactory: any;
16
+ groupStack: any[];
17
+ baseTransform: any;
18
+ baseTransformStack: any[];
19
+ groupLevel: number;
20
+ smaskStack: any[];
21
+ tempSMask: any;
22
+ smaskGroupCanvases: any[];
23
+ smaskPreparedEntry: any;
24
+ smaskPreparedFor: any;
25
+ smaskPreparedOffsetX: number;
26
+ smaskPreparedOffsetY: number;
27
+ smaskPreparedOOBAlpha: any;
28
+ suspendedCtx: any;
29
+ contentVisible: boolean;
30
+ markedContentStack: never[];
31
+ optionalContentConfig: any;
32
+ cachedPatterns: Map<any, any>;
33
+ annotationCanvasMap: any;
34
+ viewportScale: number;
35
+ outputScaleX: number;
36
+ outputScaleY: number;
37
+ pageColors: any;
38
+ _cachedScaleForStroking: number[];
39
+ _cachedBitmapsMap: Map<any, any>;
40
+ dependencyTracker: any;
41
+ imagesTracker: any;
42
+ getObject(opIdx: any, data: any, fallback?: null): any;
43
+ beginDrawing({ transform, viewport, transparency, background, }: {
44
+ transform: any;
45
+ viewport: any;
46
+ transparency?: boolean | undefined;
47
+ background?: null | undefined;
48
+ }): void;
49
+ transparentCanvasEntry: any;
50
+ compositeCtx: any;
51
+ executeOperatorList(operatorList: any, executionStartIdx: any, continueCallback: any, stepper: any, operationsFilter: any): any;
52
+ transparentCanvas: any;
53
+ endDrawing(): void;
54
+ _scaleImage(img: any, inverseTransform: any): {
55
+ img: any;
56
+ paintWidth: any;
57
+ paintHeight: any;
58
+ tmpCanvas: any;
59
+ };
60
+ _createMaskCanvas(opIdx: any, img: any): {
61
+ canvas: any;
62
+ offsetX: number;
63
+ offsetY: number;
64
+ canvasEntry?: undefined;
65
+ } | {
66
+ canvas: any;
67
+ canvasEntry: any;
68
+ offsetX: number;
69
+ offsetY: number;
70
+ };
71
+ setLineWidth(opIdx: any, width: any): void;
72
+ setLineCap(opIdx: any, style: any): void;
73
+ setLineJoin(opIdx: any, style: any): void;
74
+ setMiterLimit(opIdx: any, limit: any): void;
75
+ setDash(opIdx: any, dashArray: any, dashPhase: any): void;
76
+ setRenderingIntent(opIdx: any, intent: any): void;
77
+ setFlatness(opIdx: any, flatness: any): void;
78
+ setGState(opIdx: any, states: any): void;
79
+ get inSMaskMode(): boolean;
80
+ _clearPreparedSMask(): void;
81
+ _ensurePreparedSMask(smask: any): void;
82
+ checkSMaskState(opIdx: any): void;
83
+ _prepareSMaskCanvas(smask: any): void;
84
+ /**
85
+ * Bake the mask plus optional backdrop into a (w x h) canvas with the
86
+ * mask drawn at (drawX, drawY), then optionally pipe through the SVG
87
+ * filter described by `filterSpec`. Returns the prepared canvas-
88
+ * factory entry.
89
+ *
90
+ * The backdrop fill uses destination-atop so transparent / partial-
91
+ * alpha pixels inside the mask see the backdrop *before* filtering
92
+ * (per PDF spec). Filtering the raw mask would yield filter(0)
93
+ * instead of filter(backdrop) -- wrong for "keep" Luminosity and for
94
+ * Alpha masks whose transferMap[255] differs from transferMap[0].
95
+ *
96
+ * In the no-backdrop layer-size case the OOB region of srcEntry
97
+ * stays transparent and the filter outputs filter(transparent) =
98
+ * transferMap[0], matching the spec's transparent extension of the
99
+ * mask group. No-backdrop mask-size prebakes have no OOB region;
100
+ * destination-in handles OOB at compose time.
101
+ *
102
+ * Some browsers (e.g. older Safari) silently ignore SVG `url(#id)`
103
+ * filters on a 2D canvas: the assignment is accepted but
104
+ * `ctx.filter` reads back as "none" and `drawImage` produces an
105
+ * unfiltered copy. We detect that and fall back to a pixel-buffer
106
+ * loop that reproduces the SVG filter exactly (matrix luminance and
107
+ * `feFuncA` transferMap, both with sRGB color-interpolation, i.e.
108
+ * straight on gamma-encoded byte values).
109
+ */
110
+ _bakeSMaskCanvas(maskCanvas: any, drawX: any, drawY: any, w: any, h: any, backdrop: any, filterSpec: any): any;
111
+ /**
112
+ * Replaces the current drawing canvas with a temporary scratch canvas and
113
+ * suspends the main context. Drawing operations on the scratch canvas are
114
+ * composited back via `compose()`. The scratch canvas mirrors many operations
115
+ * onto the suspended canvas to keep their graphics-state stacks in sync, so
116
+ * that clipping paths and transformations remain correct when soft mask mode
117
+ * ends.
118
+ */
119
+ beginSMaskMode(opIdx: any): void;
120
+ smaskScratchCanvas: any;
121
+ endSMaskMode(): void;
122
+ compose(dirtyBox: any): void;
123
+ composeSMask(ctx: any, smask: any, layerCtx: any, layerBox: any): void;
124
+ /**
125
+ * Fade the dirty box's OOB region by a constant alpha. Called from
126
+ * composeSMask when smaskPreparedOOBAlpha is in (0, 255).
127
+ *
128
+ * destination-in clears every destination pixel outside the source's
129
+ * footprint, so four fillRects (one per strip) would each clear the
130
+ * others. Instead one fillRect covers the dirty box, restricted by
131
+ * an even-odd clip enclosing exactly (dirty_box XOR mask_region);
132
+ * within the clip the source covers everything so no "outside
133
+ * source" pixels exist.
134
+ */
135
+ _applySMaskOOBAlpha(layerCtx: any, layerOffsetX: any, layerOffsetY: any, layerWidth: any, layerHeight: any, maskX0: any, maskY0: any, maskX1: any, maskY1: any, alpha: any): void;
136
+ genericComposeSMask(smask: any, layerCtx: any, width: any, height: any, layerOffsetX: any, layerOffsetY: any): void;
137
+ save(opIdx: any): void;
138
+ restore(opIdx: any): void;
139
+ transform(opIdx: any, a: any, b: any, c: any, d: any, e: any, f: any): void;
140
+ constructPath(opIdx: any, op: any, data: any, minMax: any): void;
141
+ _pathStartIdx: any;
142
+ closePath(opIdx: any): void;
143
+ stroke(opIdx: any, path: any, consumePath?: boolean): void;
144
+ closeStroke(opIdx: any, path: any): void;
145
+ fill(opIdx: any, path: any, consumePath?: boolean): void;
146
+ eoFill(opIdx: any, path: any): void;
147
+ fillStroke(opIdx: any, path: any): void;
148
+ eoFillStroke(opIdx: any, path: any): void;
149
+ closeFillStroke(opIdx: any, path: any): void;
150
+ closeEOFillStroke(opIdx: any, path: any): void;
151
+ endPath(opIdx: any, path: any): void;
152
+ rawFillPath(opIdx: any, path: any): void;
153
+ clip(opIdx: any): void;
154
+ eoClip(opIdx: any): void;
155
+ beginText(opIdx: any): void;
156
+ endText(opIdx: any): void;
157
+ setCharSpacing(opIdx: any, spacing: any): void;
158
+ setWordSpacing(opIdx: any, spacing: any): void;
159
+ setHScale(opIdx: any, scale: any): void;
160
+ setLeading(opIdx: any, leading: any): void;
161
+ setFont(opIdx: any, fontRefName: any, size: any): void;
162
+ setTextRenderingMode(opIdx: any, mode: any): void;
163
+ setTextRise(opIdx: any, rise: any): void;
164
+ moveText(opIdx: any, x: any, y: any): void;
165
+ setLeadingMoveText(opIdx: any, x: any, y: any): void;
166
+ setTextMatrix(opIdx: any, matrix: any): void;
167
+ nextLine(opIdx: any): void;
168
+ paintChar(opIdx: any, character: any, x: any, y: any, patternFillTransform: any, patternStrokeTransform: any): void;
169
+ get isFontSubpixelAAEnabled(): any;
170
+ showText(opIdx: any, glyphs: any): void;
171
+ showType3Text(opIdx: any, glyphs: any): void;
172
+ setCharWidth(opIdx: any, xWidth: any, yWidth: any): void;
173
+ setCharWidthAndBounds(opIdx: any, xWidth: any, yWidth: any, llx: any, lly: any, urx: any, ury: any): void;
174
+ getColorN_Pattern(opIdx: any, IR: any): any;
175
+ setStrokeColorN(opIdx: any, ...args: any[]): void;
176
+ setFillColorN(opIdx: any, ...args: any[]): void;
177
+ setStrokeRGBColor(opIdx: any, color: any): void;
178
+ setStrokeTransparent(opIdx: any): void;
179
+ setFillRGBColor(opIdx: any, color: any): void;
180
+ setFillTransparent(opIdx: any): void;
181
+ _getPattern(opIdx: any, objId: any, matrix?: null): any;
182
+ shadingFill(opIdx: any, objId: any): void;
183
+ beginInlineImage(): void;
184
+ beginImageData(): void;
185
+ paintFormXObjectBegin(opIdx: any, matrix: any, bbox: any): void;
186
+ paintFormXObjectEnd(opIdx: any): void;
187
+ beginGroup(opIdx: any, group: any): void;
188
+ endGroup(opIdx: any, group: any): void;
189
+ beginAnnotation(opIdx: any, id: any, rect: any, transform: any, matrix: any, hasOwnCanvas: any, canvasName: any): void;
190
+ annotationCanvas: any;
191
+ endAnnotation(opIdx: any): void;
192
+ paintImageMaskXObject(opIdx: any, img: any): void;
193
+ paintImageMaskXObjectRepeat(opIdx: any, img: any, scaleX: any, skewX: number | undefined, skewY: number | undefined, scaleY: any, positions: any): void;
194
+ paintImageMaskXObjectGroup(opIdx: any, images: any): void;
195
+ paintImageXObject(opIdx: any, objId: any): void;
196
+ paintImageXObjectRepeat(opIdx: any, objId: any, scaleX: any, scaleY: any, positions: any): void;
197
+ applyTransferMapsToCanvas(ctx: any): any;
198
+ applyTransferMapsToBitmap(imgData: any): {
199
+ img: any;
200
+ canvasEntry: any;
201
+ };
202
+ paintInlineImageXObject(opIdx: any, imgData: any): void;
203
+ paintInlineImageXObjectGroup(opIdx: any, imgData: any, map: any): void;
204
+ paintSolidColorImageMask(opIdx: any): void;
205
+ markPoint(opIdx: any, tag: any): void;
206
+ markPointProps(opIdx: any, tag: any, properties: any): void;
207
+ beginMarkedContent(opIdx: any, tag: any): void;
208
+ beginMarkedContentProps(opIdx: any, tag: any, properties: any): void;
209
+ endMarkedContent(opIdx: any): void;
210
+ beginCompat(opIdx: any): void;
211
+ endCompat(opIdx: any): void;
212
+ consumePath(opIdx: any, path: any, clipBox: any): void;
213
+ getSinglePixelWidth(): number;
214
+ getScaleForStroking(): number[];
215
+ rescaleAndStroke(path: any, saveRestore: any): void;
216
+ isContentVisible(): boolean;
217
+ #private;
218
+ }
219
+ declare class CanvasExtraState {
220
+ constructor(width: any, height: any);
221
+ alphaIsShape: boolean;
222
+ fontSize: number;
223
+ fontSizeScale: number;
224
+ textMatrix: null;
225
+ textMatrixScale: number;
226
+ fontMatrix: number[];
227
+ leading: number;
228
+ x: number;
229
+ y: number;
230
+ lineX: number;
231
+ lineY: number;
232
+ charSpacing: number;
233
+ wordSpacing: number;
234
+ textHScale: number;
235
+ textRenderingMode: number;
236
+ textRise: number;
237
+ fillColor: string;
238
+ strokeColor: string;
239
+ tilingPatternDims: null;
240
+ patternFill: boolean;
241
+ patternStroke: boolean;
242
+ fillAlpha: number;
243
+ strokeAlpha: number;
244
+ lineWidth: number;
245
+ activeSMask: null;
246
+ transferMaps: string;
247
+ transferMapsFallback: null;
248
+ minMax: Float32Array<ArrayBuffer>;
249
+ clipBox: Float32Array<ArrayBuffer>;
250
+ clone(): any;
251
+ getPathBoundingBox(pathType?: string, transform?: null): Float32Array<ArrayBuffer>;
252
+ updateClipFromPath(): void;
253
+ isEmptyClip(): boolean;
254
+ startNewPathAndClipBox(box: any): void;
255
+ getClippedPathBoundingBox(pathType?: string, transform?: null): number[] | null;
256
+ }
257
+ export {};
@@ -0,0 +1,221 @@
1
+ export type SimpleDependency = "lineWidth" | "lineCap" | "lineJoin" | "miterLimit" | "dash" | "strokeAlpha" | "fillColor" | "fillAlpha" | "globalCompositeOperation" | "path" | "filter" | "font" | "fontObj";
2
+ export type IncrementalDependency = "transform" | "moveText" | "sameLineText";
3
+ export type InternalIncrementalDependency = IncrementalDependency | typeof FORCED_DEPENDENCY_LABEL;
4
+ export class CanvasBBoxTracker {
5
+ constructor(canvas: any, operationsCount: any);
6
+ _pendingBBoxIdx: number;
7
+ _savesStack: any[];
8
+ _markedContentStack: any[];
9
+ growOperationsCount(operationsCount: any): void;
10
+ get clipBox(): number[];
11
+ save(opIdx: any): this;
12
+ restore(opIdx: any, onSavePopped: any): this;
13
+ /**
14
+ * @param {number} idx
15
+ */
16
+ recordOpenMarker(idx: number): this;
17
+ getOpenMarker(): any;
18
+ recordCloseMarker(opIdx: any, onSavePopped: any): this;
19
+ beginMarkedContent(opIdx: any): this;
20
+ endMarkedContent(opIdx: any, onSavePopped: any): this;
21
+ pushBaseTransform(ctx: any): this;
22
+ popBaseTransform(): this;
23
+ resetBBox(idx: any): this;
24
+ recordClipBox(idx: any, ctx: any, minX: any, maxX: any, minY: any, maxY: any): this;
25
+ recordBBox(idx: any, ctx: any, minX: any, maxX: any, minY: any, maxY: any): this;
26
+ recordFullPageBBox(idx: any): this;
27
+ /**
28
+ * @param {number} idx
29
+ * @param {boolean} [preserve=false] - When false, the pending bounding box
30
+ * is cleared once recorded; pass true to keep it for subsequent
31
+ * operations.
32
+ * @param {Iterable<Iterable<number>>} [dependencyLists] - Groups of operation
33
+ * indices whose bounding boxes are also expanded to cover this operation.
34
+ */
35
+ recordOperation(idx: number, preserve?: boolean, dependencyLists?: Iterable<Iterable<number>>): this;
36
+ bboxToClipBoxDropOperation(idx: any): this;
37
+ take(): BBoxReader;
38
+ takeDebugMetadata(): void;
39
+ recordSimpleData(name: any, idx: any): this;
40
+ recordIncrementalData(name: any, idx: any): this;
41
+ resetIncrementalData(name: any, idx: any): this;
42
+ recordNamedData(name: any, idx: any): this;
43
+ recordSimpleDataFromNamed(name: any, depName: any, fallbackIdx: any): this;
44
+ recordFutureForcedDependency(name: any, idx: any): this;
45
+ inheritSimpleDataAsFutureForcedDependencies(names: any): this;
46
+ inheritPendingDependenciesAsFutureForcedDependencies(): this;
47
+ recordCharacterBBox(idx: any, ctx: any, font: any, scale: number | undefined, x: number | undefined, y: number | undefined, getMeasure: any): this;
48
+ getSimpleIndex(dependencyName: any): undefined;
49
+ recordDependencies(idx: any, dependencyNames: any): this;
50
+ recordNamedDependency(idx: any, name: any): this;
51
+ recordShowTextOperation(idx: any, preserve?: boolean): this;
52
+ #private;
53
+ }
54
+ /**
55
+ * @typedef {"lineWidth" | "lineCap" | "lineJoin" | "miterLimit" | "dash" |
56
+ * "strokeAlpha" | "fillColor" | "fillAlpha" | "globalCompositeOperation" |
57
+ * "path" | "filter" | "font" | "fontObj"} SimpleDependency
58
+ */
59
+ /**
60
+ * @typedef {"transform" | "moveText" | "sameLineText"} IncrementalDependency
61
+ */
62
+ /**
63
+ * @typedef {IncrementalDependency |
64
+ * typeof FORCED_DEPENDENCY_LABEL} InternalIncrementalDependency
65
+ */
66
+ export class CanvasDependencyTracker {
67
+ constructor(bboxTracker: any, recordDebugMetadata?: boolean);
68
+ get clipBox(): any;
69
+ growOperationsCount(operationsCount: any): void;
70
+ save(opIdx: any): this;
71
+ restore(opIdx: any): this;
72
+ recordOpenMarker(opIdx: any): this;
73
+ getOpenMarker(): any;
74
+ recordCloseMarker(opIdx: any): this;
75
+ /**
76
+ * @param {number} opIdx
77
+ */
78
+ beginMarkedContent(opIdx: number): this;
79
+ endMarkedContent(opIdx: any): this;
80
+ pushBaseTransform(ctx: any): this;
81
+ popBaseTransform(): this;
82
+ /**
83
+ * @param {SimpleDependency} name
84
+ * @param {number} idx
85
+ */
86
+ recordSimpleData(name: SimpleDependency, idx: number): this;
87
+ /**
88
+ * @param {IncrementalDependency} name
89
+ * @param {number} idx
90
+ */
91
+ recordIncrementalData(name: IncrementalDependency, idx: number): this;
92
+ /**
93
+ * @param {IncrementalDependency} name
94
+ * @param {number} idx
95
+ */
96
+ resetIncrementalData(name: IncrementalDependency, idx: number): this;
97
+ recordNamedData(name: any, idx: any): this;
98
+ /**
99
+ * @param {SimpleDependency} name
100
+ * @param {string} depName
101
+ * @param {number} fallbackIdx
102
+ */
103
+ recordSimpleDataFromNamed(name: SimpleDependency, depName: string, fallbackIdx: number): void;
104
+ recordFutureForcedDependency(name: any, idx: any): this;
105
+ inheritSimpleDataAsFutureForcedDependencies(names: any): this;
106
+ inheritPendingDependenciesAsFutureForcedDependencies(): this;
107
+ resetBBox(idx: any): this;
108
+ recordClipBox(idx: any, ctx: any, minX: any, maxX: any, minY: any, maxY: any): this;
109
+ recordBBox(idx: any, ctx: any, minX: any, maxX: any, minY: any, maxY: any): this;
110
+ recordCharacterBBox(idx: any, ctx: any, font: any, scale: number | undefined, x: number | undefined, y: number | undefined, getMeasure: any): this;
111
+ recordFullPageBBox(idx: any): this;
112
+ getSimpleIndex(dependencyName: any): any;
113
+ recordDependencies(idx: any, dependencyNames: any): this;
114
+ recordNamedDependency(idx: any, name: any): this;
115
+ /**
116
+ * @param {number} idx
117
+ * @param {boolean} [preserve=false] - When false, the pending dependencies
118
+ * are cleared once recorded; pass true to keep them for later operations.
119
+ */
120
+ recordOperation(idx: number, preserve?: boolean): this;
121
+ recordShowTextOperation(idx: any, preserve?: boolean): this;
122
+ bboxToClipBoxDropOperation(idx: any, preserve?: boolean): this;
123
+ take(): any;
124
+ takeDebugMetadata(): Map<any, any> | undefined;
125
+ #private;
126
+ }
127
+ /**
128
+ * Track the locations of images in the canvas. For each image it computes
129
+ * a bounding box as a potentially rotated rectangle, matching the rotation of
130
+ * the current canvas transform.
131
+ */
132
+ export class CanvasImagesTracker {
133
+ static #CoordsArray: any;
134
+ constructor(canvas: any);
135
+ record(ctx: any, width: any, height: any, clipBox: any): void;
136
+ take(): any;
137
+ #private;
138
+ }
139
+ /**
140
+ * Used to track dependencies of nested operations list, that
141
+ * should actually all map to the index of the operation that
142
+ * contains the nested list.
143
+ * @implements {CanvasDependencyTracker}
144
+ */
145
+ export class CanvasNestedDependencyTracker implements CanvasDependencyTracker {
146
+ constructor(dependencyTracker: any, opIdx: any, ignoreBBoxes: any);
147
+ get clipBox(): any;
148
+ growOperationsCount(): void;
149
+ save(opIdx: any): this;
150
+ restore(opIdx: any): this;
151
+ recordOpenMarker(idx: any): this;
152
+ getOpenMarker(): any;
153
+ recordCloseMarker(idx: any): this;
154
+ beginMarkedContent(opIdx: any): this;
155
+ endMarkedContent(opIdx: any): this;
156
+ pushBaseTransform(ctx: any): this;
157
+ popBaseTransform(): this;
158
+ /**
159
+ * @param {SimpleDependency} name
160
+ * @param {number} idx
161
+ */
162
+ recordSimpleData(name: SimpleDependency, idx: number): this;
163
+ /**
164
+ * @param {IncrementalDependency} name
165
+ * @param {number} idx
166
+ */
167
+ recordIncrementalData(name: IncrementalDependency, idx: number): this;
168
+ /**
169
+ * @param {IncrementalDependency} name
170
+ * @param {number} idx
171
+ */
172
+ resetIncrementalData(name: IncrementalDependency, idx: number): this;
173
+ recordNamedData(name: any, idx: any): this;
174
+ /**
175
+ * @param {SimpleDependency} name
176
+ * @param {string} depName
177
+ * @param {number} fallbackIdx
178
+ */
179
+ recordSimpleDataFromNamed(name: SimpleDependency, depName: string, fallbackIdx: number): this;
180
+ recordFutureForcedDependency(name: any, idx: any): this;
181
+ inheritSimpleDataAsFutureForcedDependencies(names: any): this;
182
+ inheritPendingDependenciesAsFutureForcedDependencies(): this;
183
+ resetBBox(idx: any): this;
184
+ recordClipBox(idx: any, ctx: any, minX: any, maxX: any, minY: any, maxY: any): this;
185
+ recordBBox(idx: any, ctx: any, minX: any, maxX: any, minY: any, maxY: any): this;
186
+ recordCharacterBBox(idx: any, ctx: any, font: any, scale: any, x: any, y: any, getMeasure: any): this;
187
+ recordFullPageBBox(idx: any): this;
188
+ getSimpleIndex(dependencyName: any): any;
189
+ recordDependencies(idx: any, dependencyNames: any): this;
190
+ recordNamedDependency(idx: any, name: any): this;
191
+ /**
192
+ * @param {number} idx
193
+ */
194
+ recordOperation(idx: number): this;
195
+ recordShowTextOperation(idx: any): this;
196
+ bboxToClipBoxDropOperation(idx: any): this;
197
+ take(): void;
198
+ takeDebugMetadata(): void;
199
+ #private;
200
+ }
201
+ export namespace Dependencies {
202
+ let stroke: string[];
203
+ let fill: string[];
204
+ let imageXObject: string[];
205
+ let rawFillPath: string[];
206
+ let showText: string[];
207
+ let transform: string[];
208
+ let transformAndFill: string[];
209
+ }
210
+ declare const FORCED_DEPENDENCY_LABEL: "__forcedDependency";
211
+ declare class BBoxReader {
212
+ constructor(bboxes: any, coords: any);
213
+ get length(): any;
214
+ isEmpty(i: any): boolean;
215
+ minX(i: any): number;
216
+ minY(i: any): number;
217
+ maxX(i: any): number;
218
+ maxY(i: any): number;
219
+ #private;
220
+ }
221
+ export {};
@@ -0,0 +1,29 @@
1
+ export class BaseCanvasFactory {
2
+ constructor({ enableHWA }: {
3
+ enableHWA?: boolean | undefined;
4
+ });
5
+ create(width: any, height: any): {
6
+ canvas: void;
7
+ context: any;
8
+ };
9
+ reset({ canvas }: {
10
+ canvas: any;
11
+ }, width: any, height: any): void;
12
+ destroy(canvasAndContext: any): void;
13
+ /**
14
+ * @ignore
15
+ */
16
+ _createCanvas(width: any, height: any): void;
17
+ #private;
18
+ }
19
+ export class DOMCanvasFactory extends BaseCanvasFactory {
20
+ constructor({ ownerDocument, enableHWA }: {
21
+ ownerDocument?: Document | undefined;
22
+ enableHWA?: boolean | undefined;
23
+ });
24
+ _document: Document;
25
+ /**
26
+ * @ignore
27
+ */
28
+ _createCanvas(width: any, height: any): HTMLCanvasElement;
29
+ }
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Extract file name from the Content-Disposition HTTP response header.
3
+ * @param {string} contentDisposition
4
+ * @returns {string} Filename, if found in the Content-Disposition header.
5
+ */
6
+ export function getFilenameFromContentDispositionHeader(contentDisposition: string): string;
@@ -0,0 +1,129 @@
1
+ export function applyOpacity(color: any, opacity: any): any;
2
+ export class ColorScheme {
3
+ static get isDarkMode(): any;
4
+ }
5
+ export function computeLuminance(x: any): number;
6
+ export class CSSConstants {
7
+ static get commentForegroundColor(): any;
8
+ }
9
+ export function deprecated(details: any): void;
10
+ export function fetchData(url: any, type?: string): Promise<any>;
11
+ /**
12
+ * Find a color that has sufficient contrast against a fixed color.
13
+ * The luminance (in HSL color space) of the base color is adjusted
14
+ * until the contrast ratio between the base color and the fixed color
15
+ * is at least the minimum contrast ratio required by WCAG 2.1.
16
+ * @param {Array<number>} baseColor
17
+ * @param {Array<number>} fixedColor
18
+ * @returns {string}
19
+ */
20
+ export function findContrastColor(baseColor: Array<number>, fixedColor: Array<number>): string;
21
+ export function getColorValues(colors: any): void;
22
+ export function getCurrentTransform(ctx: any): any[];
23
+ export function getCurrentTransformInverse(ctx: any): any[];
24
+ /**
25
+ * Gets the filename from a given URL.
26
+ * @param {string} url
27
+ * @returns {string}
28
+ */
29
+ export function getFilenameFromUrl(url: string): string;
30
+ /**
31
+ * Returns the filename or guessed filename from the url (see issue 3455).
32
+ * @param {string} url - The original PDF location.
33
+ * @param {string} defaultFilename - The value returned if the filename is
34
+ * unknown, or the protocol is unsupported.
35
+ * @returns {string} Guessed PDF filename.
36
+ */
37
+ export function getPdfFilenameFromUrl(url: string, defaultFilename?: string): string;
38
+ export function getRGB(color: any): any[];
39
+ export function getRGBA(color: any): any[] | null;
40
+ export function isDataScheme(url: any): boolean;
41
+ export function isPdfFile(filename: any): boolean;
42
+ export function isValidFetchUrl(url: any, baseUrl: any): boolean;
43
+ export function makePathFromDrawOPS(data: any): Path2D;
44
+ /**
45
+ * Event handler to suppress context menu.
46
+ */
47
+ export function noContextMenu(e: any): void;
48
+ /**
49
+ * Scale factors for the canvas, necessary with HiDPI displays.
50
+ */
51
+ export class OutputScale {
52
+ static get pixelRatio(): number;
53
+ static capPixels(maxPixels: any, capAreaFactor: any): any;
54
+ /**
55
+ * @type {number} Horizontal scale.
56
+ */
57
+ sx: number;
58
+ /**
59
+ * @type {number} Vertical scale.
60
+ */
61
+ sy: number;
62
+ /**
63
+ * @type {boolean} Returns `true` when scaling is required, `false` otherwise.
64
+ */
65
+ get scaled(): boolean;
66
+ /**
67
+ * @type {boolean} Returns `true` when scaling is symmetric,
68
+ * `false` otherwise.
69
+ */
70
+ get symmetric(): boolean;
71
+ /**
72
+ * @returns {boolean} Returns `true` if scaling was limited,
73
+ * `false` otherwise.
74
+ */
75
+ limitCanvas(width: any, height: any, maxPixels: any, maxDim: any, capAreaFactor?: number): boolean;
76
+ }
77
+ export class PDFDateString {
78
+ static #regex: any;
79
+ /**
80
+ * Convert a PDF date string to a JavaScript `Date` object.
81
+ *
82
+ * The PDF date string format is described in section 7.9.4 of the official
83
+ * PDF 32000-1:2008 specification. However, in the PDF 1.7 reference (sixth
84
+ * edition) Adobe describes the same format including a trailing apostrophe.
85
+ * This syntax in incorrect, but Adobe Acrobat creates PDF files that contain
86
+ * them. We ignore all apostrophes as they are not necessary for date parsing.
87
+ *
88
+ * Moreover, Adobe Acrobat doesn't handle changing the date to universal time
89
+ * and doesn't use the user's time zone (effectively ignoring the HH' and mm'
90
+ * parts of the date string).
91
+ * @param {string} input
92
+ * @returns {Date|null}
93
+ */
94
+ static toDateObject(input: string): Date | null;
95
+ }
96
+ export class PixelsPerInch {
97
+ static CSS: number;
98
+ static PDF: number;
99
+ static PDF_TO_CSS_UNITS: number;
100
+ }
101
+ declare const RenderingCancelledException_base: any;
102
+ export class RenderingCancelledException extends RenderingCancelledException_base {
103
+ [x: string]: any;
104
+ constructor(msg: any, extraDelay?: number);
105
+ extraDelay: number;
106
+ }
107
+ export function renderRichText({ html, dir, className }: {
108
+ html: any;
109
+ dir: any;
110
+ className: any;
111
+ }, container: any): void;
112
+ /**
113
+ * @param {HTMLDivElement} div
114
+ * @param {PageViewport} viewport
115
+ * @param {boolean} mustFlip
116
+ * @param {boolean} mustRotate
117
+ */
118
+ export function setLayerDimensions(div: HTMLDivElement, viewport: PageViewport, mustFlip?: boolean, mustRotate?: boolean): void;
119
+ export class StatTimer {
120
+ times: any[];
121
+ time(name: any): void;
122
+ timeEnd(name: any): void;
123
+ toString(): string;
124
+ #private;
125
+ }
126
+ export function stopEvent(e: any): void;
127
+ export const SupportedImageMimeTypes: Set<string>;
128
+ import { PageViewport } from "./page_viewport.js";
129
+ export {};