From b0d7b0ffc628a236601cdace8859b064cc01f2dd Mon Sep 17 00:00:00 2001 From: rakeshkumar1019 Date: Wed, 11 Sep 2024 10:04:03 +0530 Subject: [PATCH] ELEMENTS-1756: update PDF.js to 4.2.67, hide toobar icons & change .mjs to .js --- ui/viewers/pdfjs/build/{pdf.mjs => pdf.js} | 4 ++-- .../build/{pdf.sandbox.mjs => pdf.sandbox.js} | 2 +- .../build/{pdf.worker.mjs => pdf.worker.js} | 2 +- .../pdfjs/web/{debugger.mjs => debugger.js} | 2 +- ui/viewers/pdfjs/web/viewer.html | 4 ++-- ui/viewers/pdfjs/web/{viewer.mjs => viewer.js} | 16 ++++++++-------- 6 files changed, 15 insertions(+), 15 deletions(-) rename ui/viewers/pdfjs/build/{pdf.mjs => pdf.js} (99%) rename ui/viewers/pdfjs/build/{pdf.sandbox.mjs => pdf.sandbox.js} (99%) rename ui/viewers/pdfjs/build/{pdf.worker.mjs => pdf.worker.js} (99%) rename ui/viewers/pdfjs/web/{debugger.mjs => debugger.js} (99%) rename ui/viewers/pdfjs/web/{viewer.mjs => viewer.js} (99%) diff --git a/ui/viewers/pdfjs/build/pdf.mjs b/ui/viewers/pdfjs/build/pdf.js similarity index 99% rename from ui/viewers/pdfjs/build/pdf.mjs rename to ui/viewers/pdfjs/build/pdf.js index 03dfd5f4c7..6fc52c95a4 100644 --- a/ui/viewers/pdfjs/build/pdf.mjs +++ b/ui/viewers/pdfjs/build/pdf.js @@ -8370,7 +8370,7 @@ const PDFWorkerUtil = { { if (_shared_util_js__WEBPACK_IMPORTED_MODULE_20__.isNodeJS) { PDFWorkerUtil.isWorkerDisabled = true; - _worker_options_js__WEBPACK_IMPORTED_MODULE_35__.GlobalWorkerOptions.workerSrc ||= "./pdf.worker.mjs"; + _worker_options_js__WEBPACK_IMPORTED_MODULE_35__.GlobalWorkerOptions.workerSrc ||= "./pdf.worker.js"; } PDFWorkerUtil.isSameOrigin = function (baseUrl, otherUrl) { let base; @@ -24826,4 +24826,4 @@ const FontRenderOps = { /******/ export { __webpack_exports__AbortException as AbortException, __webpack_exports__AnnotationEditorLayer as AnnotationEditorLayer, __webpack_exports__AnnotationEditorParamsType as AnnotationEditorParamsType, __webpack_exports__AnnotationEditorType as AnnotationEditorType, __webpack_exports__AnnotationEditorUIManager as AnnotationEditorUIManager, __webpack_exports__AnnotationLayer as AnnotationLayer, __webpack_exports__AnnotationMode as AnnotationMode, __webpack_exports__CMapCompressionType as CMapCompressionType, __webpack_exports__ColorPicker as ColorPicker, __webpack_exports__DOMSVGFactory as DOMSVGFactory, __webpack_exports__DrawLayer as DrawLayer, __webpack_exports__FeatureTest as FeatureTest, __webpack_exports__GlobalWorkerOptions as GlobalWorkerOptions, __webpack_exports__ImageKind as ImageKind, __webpack_exports__InvalidPDFException as InvalidPDFException, __webpack_exports__MissingPDFException as MissingPDFException, __webpack_exports__OPS as OPS, __webpack_exports__Outliner as Outliner, __webpack_exports__PDFDataRangeTransport as PDFDataRangeTransport, __webpack_exports__PDFDateString as PDFDateString, __webpack_exports__PDFWorker as PDFWorker, __webpack_exports__PasswordResponses as PasswordResponses, __webpack_exports__PermissionFlag as PermissionFlag, __webpack_exports__PixelsPerInch as PixelsPerInch, __webpack_exports__RenderingCancelledException as RenderingCancelledException, __webpack_exports__UnexpectedResponseException as UnexpectedResponseException, __webpack_exports__Util as Util, __webpack_exports__VerbosityLevel as VerbosityLevel, __webpack_exports__XfaLayer as XfaLayer, __webpack_exports__build as build, __webpack_exports__createValidAbsoluteUrl as createValidAbsoluteUrl, __webpack_exports__fetchData as fetchData, __webpack_exports__getDocument as getDocument, __webpack_exports__getFilenameFromUrl as getFilenameFromUrl, __webpack_exports__getPdfFilenameFromUrl as getPdfFilenameFromUrl, __webpack_exports__getXfaPageViewport as getXfaPageViewport, __webpack_exports__isDataScheme as isDataScheme, __webpack_exports__isPdfFile as isPdfFile, __webpack_exports__noContextMenu as noContextMenu, __webpack_exports__normalizeUnicode as normalizeUnicode, __webpack_exports__renderTextLayer as renderTextLayer, __webpack_exports__setLayerDimensions as setLayerDimensions, __webpack_exports__shadow as shadow, __webpack_exports__updateTextLayer as updateTextLayer, __webpack_exports__version as version }; /******/ -//# sourceMappingURL=pdf.mjs.map \ No newline at end of file +//# sourceMappingURL=pdf.js.map \ No newline at end of file diff --git a/ui/viewers/pdfjs/build/pdf.sandbox.mjs b/ui/viewers/pdfjs/build/pdf.sandbox.js similarity index 99% rename from ui/viewers/pdfjs/build/pdf.sandbox.mjs rename to ui/viewers/pdfjs/build/pdf.sandbox.js index f8eaea9bb1..1e5b0f3bc5 100644 --- a/ui/viewers/pdfjs/build/pdf.sandbox.mjs +++ b/ui/viewers/pdfjs/build/pdf.sandbox.js @@ -3793,4 +3793,4 @@ function QuickJSSandbox() { var __webpack_exports__QuickJSSandbox = __webpack_exports__.QuickJSSandbox; export { __webpack_exports__QuickJSSandbox as QuickJSSandbox }; -//# sourceMappingURL=pdf.sandbox.mjs.map \ No newline at end of file +//# sourceMappingURL=pdf.sandbox.js.map \ No newline at end of file diff --git a/ui/viewers/pdfjs/build/pdf.worker.mjs b/ui/viewers/pdfjs/build/pdf.worker.js similarity index 99% rename from ui/viewers/pdfjs/build/pdf.worker.mjs rename to ui/viewers/pdfjs/build/pdf.worker.js index 9932c14e13..eae1ec9024 100644 --- a/ui/viewers/pdfjs/build/pdf.worker.mjs +++ b/ui/viewers/pdfjs/build/pdf.worker.js @@ -61123,4 +61123,4 @@ const pdfjsBuild = "49b388101"; var __webpack_exports__WorkerMessageHandler = __webpack_exports__.WorkerMessageHandler; export { __webpack_exports__WorkerMessageHandler as WorkerMessageHandler }; -//# sourceMappingURL=pdf.worker.mjs.map \ No newline at end of file +//# sourceMappingURL=pdf.worker.js.map \ No newline at end of file diff --git a/ui/viewers/pdfjs/web/debugger.mjs b/ui/viewers/pdfjs/web/debugger.js similarity index 99% rename from ui/viewers/pdfjs/web/debugger.mjs rename to ui/viewers/pdfjs/web/debugger.js index 59c1871b3e..8c431dad4d 100644 --- a/ui/viewers/pdfjs/web/debugger.mjs +++ b/ui/viewers/pdfjs/web/debugger.js @@ -586,7 +586,7 @@ class PDFBug { const link = document.createElement("link"); link.rel = "stylesheet"; - link.href = url.replace(/\.mjs$/, ".css"); + link.href = url.replace(/\.js$/, ".css"); document.head.append(link); } diff --git a/ui/viewers/pdfjs/web/viewer.html b/ui/viewers/pdfjs/web/viewer.html index e571ee2690..bd158898b5 100644 --- a/ui/viewers/pdfjs/web/viewer.html +++ b/ui/viewers/pdfjs/web/viewer.html @@ -29,11 +29,11 @@ - + - + diff --git a/ui/viewers/pdfjs/web/viewer.mjs b/ui/viewers/pdfjs/web/viewer.js similarity index 99% rename from ui/viewers/pdfjs/web/viewer.mjs rename to ui/viewers/pdfjs/web/viewer.js index 0da95dcea6..371753b12e 100644 --- a/ui/viewers/pdfjs/web/viewer.mjs +++ b/ui/viewers/pdfjs/web/viewer.js @@ -4917,7 +4917,7 @@ var esnext_iterator_constructor = __webpack_require__(8992); var esnext_iterator_filter = __webpack_require__(4520); // EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.iterator.for-each.js var esnext_iterator_for_each = __webpack_require__(3949); -;// CONCATENATED MODULE: ./node_modules/cached-iterable/src/cached_iterable.mjs +;// CONCATENATED MODULE: ./node_modules/cached-iterable/src/cached_iterable.js class CachedIterable extends Array { static from(iterable) { if (iterable instanceof this) { @@ -4926,7 +4926,7 @@ class CachedIterable extends Array { return new this(iterable); } } -;// CONCATENATED MODULE: ./node_modules/cached-iterable/src/cached_sync_iterable.mjs +;// CONCATENATED MODULE: ./node_modules/cached-iterable/src/cached_sync_iterable.js class CachedSyncIterable extends CachedIterable { @@ -4962,7 +4962,7 @@ class CachedSyncIterable extends CachedIterable { return this[this.length - 1]; } } -;// CONCATENATED MODULE: ./node_modules/cached-iterable/src/cached_async_iterable.mjs +;// CONCATENATED MODULE: ./node_modules/cached-iterable/src/cached_async_iterable.js class CachedAsyncIterable extends CachedIterable { @@ -5000,7 +5000,7 @@ class CachedAsyncIterable extends CachedIterable { return this[this.length - 1]; } } -;// CONCATENATED MODULE: ./node_modules/cached-iterable/src/index.mjs +;// CONCATENATED MODULE: ./node_modules/cached-iterable/src/index.js ;// CONCATENATED MODULE: ./node_modules/@fluent/dom/esm/localization.js @@ -8385,7 +8385,7 @@ const defaultOptions = { kind: OptionKind.VIEWER + OptionKind.PREFERENCE }, debuggerSrc: { - value: "./debugger.mjs", + value: "./debugger.js", kind: OptionKind.VIEWER }, defaultZoomDelay: { @@ -8565,7 +8565,7 @@ const defaultOptions = { kind: OptionKind.WORKER }, workerSrc: { - value: "../build/pdf.worker.mjs", + value: "../build/pdf.worker.js", kind: OptionKind.WORKER } }; @@ -8575,7 +8575,7 @@ const defaultOptions = { kind: OptionKind.VIEWER }; defaultOptions.sandboxBundleSrc = { - value: "../build/pdf.sandbox.mjs", + value: "../build/pdf.sandbox.js", kind: OptionKind.VIEWER }; defaultOptions.viewerCssTheme = { @@ -19493,4 +19493,4 @@ __webpack_async_result__(); /******/ export { __webpack_exports__PDFViewerApplication as PDFViewerApplication, __webpack_exports__PDFViewerApplicationConstants as PDFViewerApplicationConstants, __webpack_exports__PDFViewerApplicationOptions as PDFViewerApplicationOptions }; /******/ -//# sourceMappingURL=viewer.mjs.map \ No newline at end of file +//# sourceMappingURL=viewer.js.map \ No newline at end of file