PageSourceSearch

https://supermocks.com/_next/static/chunks/pages/pdf-viewer-ddc2a8f16c765a0a.js

js supermocks.com collected 2026-09-24 14:56:27 UTC 5,815 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7947],{39383:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pdf-viewer",function(){return t(22131)}])},22131:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return _}});var r=t(47568),i=t(26042),a=t(97582),o=t(85893),u=t(67294),c=t(66764),s=t(29061),d=t(69495),l=function(e){return{x:e.width-75,y:e.height-20,size:10,color:(0,d.rgb)(0,0,0),opacity:.2,rotate:(0,d.degrees)(0)}};function f(e,n){return w.apply(this,arguments)}function w(){return w=(0,r.Z)((function(e,n){var t,r,i,o,u,c,s,f,w,h,v,p=arguments;return(0,a.__generator)(this,(function(a){switch(a.label){case 0:t=p.length>2&&void 0!==p[2]?p[2]:l,a.label=1;case 1:return a.trys.push([1,5,,6]),[4,d.PDFDocument.load(e)];case 2:if((r=a.sent()).isEncrypted)return[3,4];i=r.getPages(),o=!0,u=!1,c=void 0;try{for(s=i[Symbol.iterator]();!(o=(f=s.next()).done);o=!0)w=f.value,h=w.getSize(),v=t(h),w.drawText(n,v)}catch(b){u=!0,c=b}finally{try{o||null==s.return||s.return()}finally{if(u)throw c}}return[4,r.save()];case 3:return[2,a.sent()];case 4:return[2,e];case 5:return a.sent(),[2,e];case 6:return[2]}}
1))})),w.apply(this,arguments)}!function(){var e=(0,r.Z)((function(e){return(0,a.__generator)(this,(function(n){return[2,s.Z.get("https://appx-wsb-gcp.akamai.net.in/test_pdf/2023-03-17-0.10527749863330227.pdf",{responseType:"arraybuffer"}).then(function(){var n=(0,r.Z)((function(n){return(0,a.__generator)(this,(function(t){switch(t.label){case 0:return[4,f(n.data,e)];case 1:return[2,t.sent()]}}))}));return function(e){return n.apply(this,arguments)}}())]}))}))}();var h=function(){var e=(0,r.Z)((function(e,n){return(0,a.__generator)(this,(function(t){return[2,fetch(e).then((function(e){return e.arrayBuffer()})).then(function(){var e=(0,r.Z)((function(e){return(0,a.__generator)(this,(function(t){switch(t.label){case 0:return[4,f(e,n)];case 1:return[2,t.sent()]}}))}));return function(n){return e.apply(this,arguments)}}())]}))}));return function(n,t){return e.apply(this,arguments)}}(),v=(function(){var e=(0,r.Z)((function(e,n,t){var i;return(0,a.__generator)(this,(function(o){return(i=new URLSearchParams).append("token",n),[2,s.Z.post("".concat(e).concat("/fetch_pdf_url_from_token"),i,{responseType:"arraybuffer",responseEncoding:"binary"}).then(function(){var e=(0,r.Z)((function(e){return(0,a.__generator)(this,(function(n){switch(n.label){case 0:return[4,f(e.data,t)];case 1:return[2,n.sent()]}}))}));return function(n){return e.apply(this,arguments)}}()).catch((function(){return null}))]}))}))}(),t(89885)),p=t(4027),b=t(4298),y=t.n(b);function _(e){var n=e.url,t=e.saveFlag,r=e.phone,i=(0,u.useContext)(v.Z),a=i.currentUser,s=i.appConfig,d="af53e8c68a8d4d918e9a319b7e88a441",l={embedMode:"FULL_WINDOW",showAnnotationTools:!1,showDownloadPDF:"1"==t,showPrintPDF:!1,showLeftHandPanel:!0,defaultViewMode:"FIT_PAGE"};return(0,u.useEffect)((function(){var e=window.pdfConfig,t=(null===e||void 0===e?void 0:e.showWatermark)||(null===s||void 0===s?void 0:s.web_enablewatermarkpdfviewer)||!1,i=(0,p.h)(t),o=new c.Z(d);if(n)if(i){var u=(null===e||void 0===e?void 0:e.watermarkText)||(null===a||void 0===a?void 0:a.phone)||r;o.ready().then((function(){h(n,u).then((function(e){var n=URL.createObjectURL(new Blob([e]));o.previewFile("adobe-dc-view",n,l)}))}))}else o.ready().then((function(){o.previewFile("adobe-dc-view",n,l)}));window.onmessage=function(e){var n;if("object"==typeof e.data&&null!=(null===(n=e.data)||void 0===n?void 0:n.file)){var t=new c.Z(d),r=e.data.file,i=new FileReader;i.onloadend=function(e){var n=Promise.resolve(e.target.result);t.ready().then((function(){t.previewFileUsingFilePromise("adobe-dc-view",n,r.name,l)}))},i.readAsArrayBuffer(r)}}}),[]),(0,o.jsx)("div",{id:"adobe-dc-view",style:{height:"100vh"}})}_.getInitialProps=function(){var e=(0,r.Z)((function(e){return(0,a.__generator)(this,(function(n){return[2,(0,i.Z)({},e.query)]}))}));return function(n){return e.apply(this,arguments)}}(),_.layout=function(e){var n=e.children;return(0,o.jsxs)("div",{children:[(0,o.jsx)(y(),{src:"https://acrobatservices.adobe.com/view-sdk/viewer.js"}),n]})}},66764:function(e,n,t){"use strict";var r=t(51438),i=t(52951),a=t(14924),o=function(){function e(n){(0,r.Z)(this,e),(0,a.Z)(this,"clientId",void 0),this.clientId=window.location.host.startsWith("localhost")||window.location.host.includes("appx-website-staging.akamai.net.in")?"5604070f76d2454eb28a122c79a1cf5c":n,this.readyPromise=new Promise((function(e){window.AdobeDC?e():document.addEventListener("adobe_dc_view_sdk.ready",(function(){e()}))})),this.adobeDCView=void 0}return(0,i.Z)(e,[{key:"ready",value:function(){return this.readyPromise}},{key:"previewFile",value:function(e,n,t){t.dockPageControls=!0;var r={clientId:this.clientId};return e&&(r.divId=e),this.adobeDCView=new window.AdobeDC.View(r),this.adobeDCView.previewFile({content:{location:{url:n}},metaData:{fileName:n.split("/").pop()}},t)}},{key:"previewFileUsingFilePromise",value:function(e,n,t,r){this.adobeDCView=new window.AdobeDC.View({clientId:this.clientId,divId:e}),this.adobeDCView.previewFile({content:{promise:n},metaData:{fileName:t}},r)}},{key:"registerSaveApiHandler",value:function(){this.adobeDCView.registerCallback(window.AdobeDC.View.Enum.CallbackType.SAVE_API,(function(e,n,t){return new Promise((function(n){setTimeout((function(){var t={code:window.AdobeDC.View.Enum.ApiResponseCode.SUCCESS,data:{metaData:Object.assign(e,{updatedAt:(new Date).getTime()})}};n(t)}),2e3)}))}),{})}},{key:"registerEventsHandler",value:function(){this.adobeDCView.registerCallback(window.AdobeDC.View.Enum.CallbackType.EVENT_LISTENER,(function(e){console.log(e)}),{enablePDFAnalytics:!0})}}]),e}();n.Z=o}},function(e){e.O(0,[9495,9774,2888,179],(function(){return n=39383,e(e.s=n);var n}));var n=e.O();_N_E=n}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.