Welcome to mirror list, hosted at ThFree Co, Russian Federation.

files_pdfviewer-workersrc.js « js - github.com/nextcloud/files_pdfviewer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 2beeb5019e586a341fa40d0eb0ec29957b4fc153 (plain)
1
2
!function(e){var t={};function n(o){if(t[o])return t[o].exports;var r=t[o]={i:o,l:!1,exports:{}};return e[o].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=e,n.c=t,n.d=function(e,t,o){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(o,r,function(t){return e[t]}.bind(null,r));return o},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/js/",n(n.s=133)}({133:function(e,t){!function(){try{if(window.frameElement)return}catch(e){console.debug(e)}window.location.href="/"}(),document.addEventListener("webviewerloaded",(function(){PDFViewerApplicationOptions.set("disablePreferences",!0),PDFViewerApplicationOptions.set("externalLinkTarget",pdfjsLib.LinkTarget.BLANK),PDFViewerApplicationOptions.set("isEvalSupported",!1),PDFViewerApplicationOptions.set("workerSrc",document.getElementsByTagName("head")[0].getAttribute("data-workersrc")),PDFViewerApplicationOptions.set("cMapUrl",document.getElementsByTagName("head")[0].getAttribute("data-cmapurl")),PDFViewerApplication.download=function(){function e(e){let t=0;const n=e.length;for(;t<n&&""===e[t].trim();)t++;return"data:"===e.substr(t,5).toLowerCase()}const t=decodeURIComponent(window.location.search.substr(6));this.downloadManager.downloadUrl(t,function(t){const n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"document.pdf";if(e(t))return console.warn('getPDFFileNameFromURL: ignoring "data:" URL for performance reasons.'),n;const o=/^(?:(?:[^:]+:)?\/\/[^/]+)?([^?#]*)(\?[^#]*)?(#.*)?$/,r=/[^/?#=]+\.pdf\b(?!.*\.pdf\b)/i,i=o.exec(t);let a=r.exec(i[1])||r.exec(i[2])||r.exec(i[3]);if(a&&(a=a[0],-1!==a.indexOf("%")))try{a=r.exec(decodeURIComponent(a))[0]}catch(e){console.debug(e)}return a||n}(t))},"true"===window.parent.document.getElementById("hideDownload").value&&(PDFViewerApplication.download=function(){},delete PDFViewerApplication.supportsPrinting,PDFViewerApplication.supportsPrinting=!1,PDFViewerApplication.beforePrint=function(){})}),!0)}});
//# sourceMappingURL=files_pdfviewer-workersrc.js.map?v=01b289cf7664b1049bc8