PageSourceSearch

https://garder-pro.web.app/5925.0d57d67fb39df29b.js

js garder-pro.web.app collected 2026-10-03 12:25:28 UTC 387,987 bytes, 1 lines download raw bytes

1var xt=Object.defineProperty,Et=(ue,L,ne)=>L in ue?xt(ue,L,{enumerable:!0,configurable:!0,writable:!0,value:ne}):ue[L]=ne,ze=(ue,L,ne)=>(Et(ue,"symbol"!=typeof L?L+"":L,ne),ne),Ke=(ue,L,ne)=>{if(!L.has(ue))throw TypeError("Cannot "+ne)},Ae=(ue,L,ne)=>(Ke(ue,L,"read from private field"),ne?ne.call(ue):L.get(ue)),ve=(ue,L,ne)=>{if(L.has(ue))throw TypeError("Cannot add the same private member more than once");L instanceof WeakSet?L.add(ue):L.set(ue,ne)},Te=(ue,L,ne,y)=>(Ke(ue,L,"write to private field"),y?y.call(ue,ne):L.set(ue,ne),ne),lt=(ue,L,ne,y)=>({set _(oe){Te(ue,L,oe,ne)},get _(){return Ae(ue,L,y)}}),ye=(ue,L,ne)=>(Ke(ue,L,"access private method"),ne);(self.webpackChunkapp=self.webpackChunkapp||[]).push([[5925],{6036:function(module,__unused_webpack_exports,__webpack_require__){var _asyncToGenerator=__webpack_require__(9344).default,ne;ne=()=>(()=>{"use strict";var __webpack_modules__=[,(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.VerbosityLevel=L.Util=L.UnknownErrorException=L.UnexpectedResponseException=L.UNSUPPORTED_FEATURES=L.TextRenderingMode=L.StreamType=L.RenderingIntentFlag=L.PermissionFlag=L.PasswordResponses=L.PasswordException=L.PageActionEventType=L.OPS=L.MissingPDFException=L.InvalidPDFException=L.ImageKind=L.IDENTITY_MATRIX=L.FormatError=L.FontType=L.FeatureTest=L.FONT_IDENTITY_MATRIX=L.DocumentActionEventType=L.CMapCompressionType=L.BaseException=L.AnnotationType=L.AnnotationStateModelType=L.AnnotationReviewState=L.AnnotationReplyType=L.AnnotationMode=L.AnnotationMarkedState=L.AnnotationFlag=L.AnnotationFieldFlag=L.AnnotationBorderStyleType=L.AnnotationActionEventType=L.AbortException=void 0,L.arrayByteLength=U,L.arraysToBytes=function V(Z){const R=Z.length;if(1===R&&Z[0]instanceof Uint8Array)return Z[0];let F=0;for(let fe=0;fe<R;fe++)F+=U(Z[fe]);let ae=0;const le=new Uint8Array(F);for(let fe=0;fe<R;fe++){let ge=Z[fe];ge instanceof Uint8Array||(ge="string"==typeof ge?B(ge):new Uint8Array(ge));const Pe=ge.byteLength;le.set(ge,ae),ae+=Pe}return le},L.assert=function $(Z,R){Z||N(R)},L.bytesToString=function E(Z){("object"!=typeof Z||null===Z||void 0===Z.length)&&N("Invalid argument for bytesToString");const R=Z.length,F=8192;if(R<F)return String.fromCharCode.apply(null,Z);const ae=[];for(let le=0;le<R;le+=F){const fe=Math.min(le+F,R),ge=Z.subarray(le,fe);ae.push(String.fromCharCode.apply(null,ge))}
vendor: 48,703 bytes, line 1
1return ae.join("")},L.createPromiseCapability=function Ee(){const Z=Object.create(null);let R=!1;return Object.defineProperty(Z,"settled",{get:()=>R}),Z.promise=new Promise(function(F,ae){Z.resolve=function(le){R=!0,F(le)},Z.reject=function(le){R=!0,ae(le)}}),Z},L.createValidAbsoluteUrl=function te(Z,R=null,F=null){if(!Z)return null;try{if(F&&"string"==typeof Z){if(F.addDefaultProtocol&&Z.startsWith("www.")){const le=Z.match(/\./g);le&&le.length>=2&&(Z=`http://${Z}`)}if(F.tryConvertEncoding)try{Z=he(Z)}catch{}}const ae=R?new URL(Z,R):new URL(Z);if(function K(Z){if(!Z)return!1;switch(Z.protocol){case"http:":case"https:":case"ftp:":case"mailto:":case"tel:":return!0;default:return!1}}(ae))return ae}catch{}return null},L.escapeString=function q(Z){return Z.replace(/([()\\\n\r])/g,R=>"\n"===R?"\\n":"\r"===R?"\\r":`\\${R}`)},L.getModificationDate=function Ce(Z=new Date){return[Z.getUTCFullYear().toString(),(Z.getUTCMonth()+1).toString().padStart(2,"0"),Z.getUTCDate().toString().padStart(2,"0"),Z.getUTCHours().toString().padStart(2,"0"),Z.getUTCMinutes().toString().padStart(2,"0"),Z.getUTCSeconds().toString().padStart(2,"0")].join("")},L.getVerbosityLevel=function j(){return k},L.info=function X(Z){k>=A.INFOS&&console.log(`Info: ${Z}`)},L.isArrayBuffer=function _e(Z){return"object"==typeof Z&&null!==Z&&void 0!==Z.byteLength},L.isArrayEqual=function Se(Z,R){if(Z.length!==R.length)return!1;for(let F=0,ae=Z.length;F<ae;F++)if(Z[F]!==R[F])return!1;return!0},L.isAscii=function pe(Z){return/^[\x00-\x7F]*$/.test(Z)},L.objectFromMap=function ee(Z){const R=Object.create(null);for(const[F,ae]of Z)R[F]=ae;return R},L.objectSize=function Y(Z){return Object.keys(Z).length},L.setVerbosityLevel=function I(Z){Number.isInteger(Z)&&(k=Z)},L.shadow=se,L.string32=function z(Z){return String.fromCharCode(Z>>24&255,Z>>16&255,Z>>8&255,255&Z)},L.stringToBytes=B,L.stringToPDFString=function D(Z){if(Z[0]>="\xef"){let F;if("\xfe"===Z[0]&&"\xff"===Z[1]?F="utf-16be":"\xff"===Z[0]&&"\xfe"===Z[1]?F="utf-16le":"\xef"===Z[0]&&"\xbb"===Z[1]&&"\xbf"===Z[2]&&(F="utf-8"),F)try{const ae=new TextDecoder(F,{fatal:!0}),le=B(Z);return ae.decode(le)}catch(ae){J(`stringToPDFString: "${ae}".`)}}const R=[];for(let F=0,ae=Z.length;F<ae;F++){const le=P[Z.charCodeAt(F)];R.push(le?String.fromCharCode(le):Z.charAt(F))}return R.join("")},L.stringToUTF16BEString=function de(Z){const R=["\xfe\xff"];for(let F=0,ae=Z.length;F<ae;F++){const le=Z.charCodeAt(F);R.push(String.fromCharCode(le>>8&255),String.fromCharCode(255&le))}return R.join("")},L.stringToUTF8String=he,L.unreachable=N,L.utf8StringToString=function me(Z){return unescape(encodeURIComponent(Z))},L.warn=J,ne(2),L.IDENTITY_MATRIX=[1,0,0,1,0,0],L.FONT_IDENTITY_MATRIX=[.001,0,0,.001,0,0],L.RenderingIntentFlag={ANY:1,DISPLAY:2,PRINT:4,ANNOTATIONS_FORMS:16,ANNOTATIONS_STORAGE:32,ANNOTATIONS_DISABLE:64,OPLIST:256},L.AnnotationMode={DISABLE:0,ENABLE:1,ENABLE_FORMS:2,ENABLE_STORAGE:3},L.PermissionFlag={PRINT:4,MODIFY_CONTENTS:8,COPY:16,MODIFY_ANNOTATIONS:32,FILL_INTERACTIVE_FORMS:256,COPY_FOR_ACCESSIBILITY:512,ASSEMBLE:1024,PRINT_HIGH_QUALITY:2048},L.TextRenderingMode={FILL:0,STROKE:1,FILL_STROKE:2,INVISIBLE:3,FILL_ADD_TO_PATH:4,STROKE_ADD_TO_PATH:5,FILL_STROKE_ADD_TO_PATH:6,ADD_TO_PATH:7,FILL_STROKE_MASK:3,ADD_TO_PATH_FLAG:4},L.ImageKind={GRAYSCALE_1BPP:1,RGB_24BPP:2,RGBA_32BPP:3},L.AnnotationType={TEXT:1,LINK:2,FREETEXT:3,LINE:4,SQUARE:5,CIRCLE:6,POLYGON:7,POLYLINE:8,HIGHLIGHT:9,UNDERLINE:10,SQUIGGLY:11,STRIKEOUT:12,STAMP:13,CARET:14,INK:15,POPUP:16,FILEATTACHMENT:17,SOUND:18,MOVIE:19,WIDGET:20,SCREEN:21,PRINTERMARK:22,TRAPNET:23,WATERMARK:24,THREED:25,REDACT:26},L.AnnotationStateModelType={MARKED:"Marked",REVIEW:"Review"},L.AnnotationMarkedState={MARKED:"Marked",UNMARKED:"Unmarked"},L.AnnotationReviewState={ACCEPTED:"Accepted",REJECTED:"Rejected",CANCELLED:"Cancelled",COMPLETED:"Completed",NONE:"None"},L.AnnotationReplyType={GROUP:"Group",REPLY:"R"},L.AnnotationFlag={INVISIBLE:1,HIDDEN:2,PRINT:4,NOZOOM:8,NOROTATE:16,NOVIEW:32,READONLY:64,LOCKED:128,TOGGLENOVIEW:256,LOCKEDCONTENTS:512},L.AnnotationFieldFlag={READONLY:1,REQUIRED:2,NOEXPORT:4,MULTILINE:4096,PASSWORD:8192,NOTOGGLETOOFF:16384,RADIO:32768,PUSHBUTTON:65536,COMBO:131072,EDIT:262144,SORT:524288,FILESELECT:1048576,MULTISELECT:2097152,DONOTSPELLCHECK:4194304,DONOTSCROLL:8388608,COMB:16777216,RICHTEXT:33554432,RADIOSINUNISON:33554432,COMMITONSELCHANGE:67108864},L.AnnotationBorderStyleType={SOLID:1,DASHED:2,BEVELED:3,INSET:4,UNDERLINE:5},L.AnnotationActionEventType={E:"Mouse Enter",X:"Mouse Exit",D:"Mouse Down",U:"Mouse Up",Fo:"Focus",Bl:"Blur",PO:"PageOpen",PC:"PageClose",PV:"PageVisible",PI:"PageInvisible",K:"Keystroke",F:"Format",V:"Validate",C:"Calculate"},L.DocumentActionEventType={WC:"WillClose",WS:"WillSave",DS:"DidSave",WP:"WillPrint",DP:"DidPrint"},L.PageActionEventType={O:"PageOpen",C:"PageClose"},L.StreamType={UNKNOWN:"UNKNOWN",FLATE:"FLATE",LZW:"LZW",DCT:"DCT",JPX:"JPX",JBIG:"JBIG",A85:"A85",AHX:"AHX",CCF:"CCF",RLX:"RLX"},L.FontType={UNKNOWN:"UNKNOWN",TYPE1:"TYPE1",TYPE1STANDARD:"TYPE1STANDARD",TYPE1C:"TYPE1C",CIDFONTTYPE0:"CIDFONTTYPE0",CIDFONTTYPE0C:"CIDFONTTYPE0C",TRUETYPE:"TRUETYPE",CIDFONTTYPE2:"CIDFONTTYPE2",TYPE3:"TYPE3",OPENTYPE:"OPENTYPE",TYPE0:"TYPE0",MMTYPE1:"MMTYPE1"};const A={ERRORS:0,WARNINGS:1,INFOS:5};L.VerbosityLevel=A,L.CMapCompressionType={NONE:0,BINARY:1,STREAM:2},L.OPS={dependency:1,setLineWidth:2,setLineCap:3,setLineJoin:4,setMiterLimit:5,setDash:6,setRenderingIntent:7,setFlatness:8,setGState:9,save:10,restore:11,transform:12,moveTo:13,lineTo:14,curveTo:15,curveTo2:16,curveTo3:17,closePath:18,rectangle:19,stroke:20,closeStroke:21,fill:22,eoFill:23,fillStroke:24,eoFillStroke:25,closeFillStroke:26,closeEOFillStroke:27,endPath:28,clip:29,eoClip:30,beginText:31,endText:32,setCharSpacing:33,setWordSpacing:34,setHScale:35,setLeading:36,setFont:37,setTextRenderingMode:38,setTextRise:39,moveText:40,setLeadingMoveText:41,setTextMatrix:42,nextLine:43,showText:44,showSpacedText:45,nextLineShowText:46,nextLineSetSpacingShowText:47,setCharWidth:48,setCharWidthAndBounds:49,setStrokeColorSpace:50,setFillColorSpace:51,setStrokeColor:52,setStrokeColorN:53,setFillColor:54,setFillColorN:55,setStrokeGray:56,setFillGray:57,setStrokeRGBColor:58,setFillRGBColor:59,setStrokeCMYKColor:60,setFillCMYKColor:61,shadingFill:62,beginInlineImage:63,beginImageData:64,endInlineImage:65,paintXObject:66,markPoint:67,markPointProps:68,beginMarkedContent:69,beginMarkedContentProps:70,endMarkedContent:71,beginCompat:72,endCompat:73,paintFormXObjectBegin:74,paintFormXObjectEnd:75,beginGroup:76,endGroup:77,beginAnnotations:78,endAnnotations:79,beginAnnotation:80,endAnnotation:81,paintJpegXObject:82,paintImageMaskXObject:83,paintImageMaskXObjectGroup:84,paintImageXObject:85,paintInlineImageXObject:86,paintInlineImageXObjectGroup:87,paintImageXObjectRepeat:88,paintImageMaskXObjectRepeat:89,paintSolidColorImageMask:90,constructPath:91},L.UNSUPPORTED_FEATURES={unknown:"unknown",forms:"forms",javaScript:"javaScript",signatures:"signatures",smask:"smask",shadingPattern:"shadingPattern",font:"font",errorTilingPattern:"errorTilingPattern",errorExtGState:"errorExtGState",errorXObject:"errorXObject",errorFontLoadType3:"errorFontLoadType3",errorFontState:"errorFontState",errorFontMissing:"errorFontMissing",errorFontTranslate:"errorFontTranslate",errorColorSpace:"errorColorSpace",errorOperatorList:"errorOperatorList",errorFontToUnicode:"errorFontToUnicode",errorFontLoadNative:"errorFontLoadNative",errorFontBuildPath:"errorFontBuildPath",errorFontGetPath:"errorFontGetPath",errorMarkedContent:"errorMarkedContent",errorContentSubStream:"errorContentSubStream"},L.PasswordResponses={NEED_PASSWORD:1,INCORRECT_PASSWORD:2};let k=A.WARNINGS;function J(Z){k>=A.WARNINGS&&console.log(`Warning: ${Z}`)}function N(Z){throw new Error(Z)}function se(Z,R,F){return Object.defineProperty(Z,R,{value:F,enumerable:!0,configurable:!0,writable:!1}),F}const T=function(){function R(F,ae){this.constructor===R&&N("Cannot initialize BaseException."),this.message=F,this.name=ae}return R.prototype=new Error,R.constructor=R,R}();function B(Z){"string"!=typeof Z&&N("Invalid argument for stringToBytes");const R=Z.length,F=new Uint8Array(R);for(let ae=0;ae<R;++ae)F[ae]=255&Z.charCodeAt(ae);return F}function U(Z){return void 0!==Z.length?Z.length:void 0!==Z.byteLength?Z.byteLength:void N("Invalid argument for arrayByteLength")}L.BaseException=T,L.PasswordException=class o extends T{constructor(R,F){super(R,"PasswordException"),this.code=F}},L.UnknownErrorException=class h extends T{constructor(R,F){super(R,"UnknownErrorException"),this.details=F}},L.InvalidPDFException=class e extends T{constructor(R){super(R,"InvalidPDFException")}},L.MissingPDFException=class c extends T{constructor(R){super(R,"MissingPDFException")}},L.UnexpectedResponseException=class b extends T{constructor(R,F){super(R,"UnexpectedResponseException"),this.status=F}},L.FormatError=class w extends T{constructor(R){super(R,"FormatError")}},L.AbortException=class C extends T{constructor(R){super(R,"AbortException")}},L.FeatureTest=class Q{static get isLittleEndian(){return se(this,"isLittleEndian",function ce(){const Z=new Uint8Array(4);return Z[0]=1,1===new Uint32Array(Z.buffer,0,1)[0]}())}static get isEvalSupported(){return se(this,"isEvalSupported",function be(){try{return new Function(""),!0}catch{return!1}}())}static get isOffscreenCanvasSupported(){return se(this,"isOffscreenCanvasSupported",typeof OffscreenCanvas<"u")}};const re=[...Array(256).keys()].map(Z=>Z.toString(16).padStart(2,"0"));class ie{static makeHexColor(R,F,ae){return`#${re[R]}${re[F]}${re[ae]}`}static scaleMinMax(R,F){let ae;R[0]?(R[0]<0&&(ae=F[0],F[0]=F[1],F[1]=ae),F[0]*=R[0],F[1]*=R[0],R[3]<0&&(ae=F[2],F[2]=F[3],F[3]=ae),F[2]*=R[3],F[3]*=R[3]):(ae=F[0],F[0]=F[2],F[2]=ae,ae=F[1],F[1]=F[3],F[3]=ae,R[1]<0&&(ae=F[2],F[2]=F[3],F[3]=ae),F[2]*=R[1],F[3]*=R[1],R[2]<0&&(ae=F[0],F[0]=F[1],F[1]=ae),F[0]*=R[2],F[1]*=R[2]),F[0]+=R[4],F[1]+=R[4],F[2]+=R[5],F[3]+=R[5]}static transform(R,F){return[R[0]*F[0]+R[2]*F[1],R[1]*F[0]+R[3]*F[1],R[0]*F[2]+R[2]*F[3],R[1]*F[2]+R[3]*F[3],R[0]*F[4]+R[2]*F[5]+R[4],R[1]*F[4]+R[3]*F[5]+R[5]]}static applyTransform(R,F){return[R[0]*F[0]+R[1]*F[2]+F[4],R[0]*F[1]+R[1]*F[3]+F[5]]}static applyInverseTransform(R,F){const ae=F[0]*F[3]-F[1]*F[2];return[(R[0]*F[3]-R[1]*F[2]+F[2]*F[5]-F[4]*F[3])/ae,(-R[0]*F[1]+R[1]*F[0]+F[4]*F[1]-F[5]*F[0])/ae]}static getAxialAlignedBoundingBox(R,F){const ae=ie.applyTransform(R,F),le=ie.applyTransform(R.slice(2,4),F),fe=ie.applyTransform([R[0],R[3]],F),ge=ie.applyTransform([R[2],R[1]],F);return[Math.min(ae[0],le[0],fe[0],ge[0]),Math.min(ae[1],le[1],fe[1],ge[1]),Math.max(ae[0],le[0],fe[0],ge[0]),Math.max(ae[1],le[1],fe[1],ge[1])]}static inverseTransform(R){const F=R[0]*R[3]-R[1]*R[2];return[R[3]/F,-R[1]/F,-R[2]/F,R[0]/F,(R[2]*R[5]-R[4]*R[3])/F,(R[4]*R[1]-R[5]*R[0])/F]}static apply3dTransform(R,F){return[R[0]*F[0]+R[1]*F[1]+R[2]*F[2],R[3]*F[0]+R[4]*F[1]+R[5]*F[2],R[6]*F[0]+R[7]*F[1]+R[8]*F[2]]}static singularValueDecompose2dScale(R){const F=[R[0],R[2],R[1],R[3]],ae=R[0]*F[0]+R[1]*F[2],ge=R[2]*F[1]+R[3]*F[3],Pe=(ae+ge)/2,we=Math.sqrt((ae+ge)**2-4*(ae*ge-(R[2]*F[0]+R[3]*F[2])*(R[0]*F[1]+R[1]*F[3])))/2,xe=Pe-we||1;return[Math.sqrt(Pe+we||1),Math.sqrt(xe)]}static normalizeRect(R){const F=R.slice(0);return R[0]>R[2]&&(F[0]=R[2],F[2]=R[0]),R[1]>R[3]&&(F[1]=R[3],F[3]=R[1]),F}static intersect(R,F){const ae=Math.max(Math.min(R[0],R[2]),Math.min(F[0],F[2])),le=Math.min(Math.max(R[0],R[2]),Math.max(F[0],F[2]));if(ae>le)return null;const fe=Math.max(Math.min(R[1],R[3]),Math.min(F[1],F[3])),ge=Math.min(Math.max(R[1],R[3]),Math.max(F[1],F[3]));return fe>ge?null:[ae,fe,le,ge]}static bezierBoundingBox(R,F,ae,le,fe,ge,Pe,we){const Me=[],xe=[[],[]];let Re,ke,Be,Le,Fe,Oe,Ne,De;for(let Ye=0;Ye<2;++Ye)if(0===Ye?(ke=6*R-12*ae+6*fe,Re=-3*R+9*ae-9*fe+3*Pe,Be=3*ae-3*R):(ke=6*F-12*le+6*ge,Re=-3*F+9*le-9*ge+3*we,Be=3*le-3*F),Math.abs(Re)<1e-12){if(Math.abs(ke)<1e-12)continue;Le=-Be/ke,0<Le&&Le<1&&Me.push(Le)}else Ne=ke*ke-4*Be*Re,De=Math.sqrt(Ne),!(Ne<0)&&(Fe=(-ke+De)/(2*Re),0<Fe&&Fe<1&&Me.push(Fe),Oe=(-ke-De)/(2*Re),0<Oe&&Oe<1&&Me.push(Oe));let Ie,Ve=Me.length;const je=Ve;for(;Ve--;)Le=Me[Ve],Ie=1-Le,xe[0][Ve]=Ie*Ie*Ie*R+3*Ie*Ie*Le*ae+3*Ie*Le*Le*fe+Le*Le*Le*Pe,xe[1][Ve]=Ie*Ie*Ie*F+3*Ie*Ie*Le*le+3*Ie*Le*Le*ge+Le*Le*Le*we;return xe[0][je]=R,xe[1][je]=F,xe[0][je+1]=Pe,xe[1][je+1]=we,xe[0].length=xe[1].length=je+2,[Math.min(...xe[0]),Math.min(...xe[1]),Math.max(...xe[0]),Math.max(...xe[1])]}}L.Util=ie;const P=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,728,711,710,729,733,731,730,732,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8226,8224,8225,8230,8212,8211,402,8260,8249,8250,8722,8240,8222,8220,8221,8216,8217,8218,8482,64257,64258,321,338,352,376,381,305,322,339,353,382,0,8364];function he(Z){return decodeURIComponent(escape(Z))}},(ue,L,ne)=>{ne(3)},(ue,L)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.isNodeJS=void 0;const ne=!("object"!=typeof process||process+""!="[object process]"||process.versions.nw||process.versions.electron&&process.type&&"browser"!==process.type);L.isNodeJS=ne},(__unused_webpack_module,exports,__w_pdfjs_require__)=>{var ue,ne,y,oe,G,H,W,O,Qe,v;Object.defineProperty(exports,"__esModule",{value:!0}),exports.build=exports.RenderTask=exports.PDFWorkerUtil=exports.PDFWorker=exports.PDFPageProxy=exports.PDFDocumentProxy=exports.PDFDocumentLoadingTask=exports.PDFDataRangeTransport=exports.LoopbackPort=exports.DefaultStandardFontDataFactory=exports.DefaultCanvasFactory=exports.DefaultCMapReaderFactory=void 0,exports.getDocument=getDocument,exports.setPDFNetworkStreamFactory=setPDFNetworkStreamFactory,exports.version=void 0;var _util=__w_pdfjs_require__(1),_display_utils=__w_pdfjs_require__(5),_font_loader=__w_pdfjs_require__(7),_annotation_storage=__w_pdfjs_require__(8),_canvas=__w_pdfjs_require__(10),_worker_options=__w_pdfjs_require__(13),_is_node=__w_pdfjs_require__(3),_message_handler=__w_pdfjs_require__(14),_metadata=__w_pdfjs_require__(15),_optional_content_config=__w_pdfjs_require__(16),_transport_stream=__w_pdfjs_require__(17),_xfa_text=__w_pdfjs_require__(18);const DEFAULT_RANGE_CHUNK_SIZE=65536,RENDERING_CANCELLED_TIMEOUT=100;let DefaultCanvasFactory=_display_utils.DOMCanvasFactory;exports.DefaultCanvasFactory=DefaultCanvasFactory;let DefaultCMapReaderFactory=_display_utils.DOMCMapReaderFactory;exports.DefaultCMapReaderFactory=DefaultCMapReaderFactory;let DefaultStandardFontDataFactory=_display_utils.DOMStandardFontDataFactory,createPDFNetworkStream;if(exports.DefaultStandardFontDataFactory=DefaultStandardFontDataFactory,_is_node.isNodeJS){const{NodeCanvasFactory:f,NodeCMapReaderFactory:r,NodeStandardFontDataFactory:p}=__w_pdfjs_require__(19);exports.DefaultCanvasFactory=DefaultCanvasFactory=f,exports.DefaultCMapReaderFactory=DefaultCMapReaderFactory=r,exports.DefaultStandardFontDataFactory=DefaultStandardFontDataFactory=p}function setPDFNetworkStreamFactory(f){createPDFNetworkStream=f}function getDocument(f){const r=new PDFDocumentLoadingTask;let p;if("string"==typeof f||f instanceof URL)p={url:f};else if((0,_util.isArrayBuffer)(f))p={data:f};else if(f instanceof PDFDataRangeTransport)p={range:f};else{if("object"!=typeof f)throw new Error("Invalid parameter in getDocument, need either string, URL, Uint8Array, or parameter object.");if(!f.url&&!f.data&&!f.range)throw new Error("Invalid parameter object: need either .data, .range or .url");p=f}const n=Object.create(null);let s=null,u=null;for(const d in p){const _=p[d];switch(d){case"url":if(typeof window<"u")try{n[d]=new URL(_,window.location).href;continue}catch(t){(0,_util.warn)(`Cannot create valid URL: "${t}".`)}else if("string"==typeof _||_ instanceof URL){n[d]=_.toString();continue}throw new Error("Invalid PDF url data: either string or URL-object is expected in the url property.");case"range":s=_;continue;case"worker":u=_;continue;case"data":if(_is_node.isNodeJS&&typeof Buffer<"u"&&_ instanceof Buffer)n[d]=new Uint8Array(_);else{if(_ instanceof Uint8Array)break;if("string"==typeof _)n[d]=(0,_util.stringToBytes)(_);else if("object"!=typeof _||null===_||isNaN(_.length)){if(!(0,_util.isArrayBuffer)(_))throw new Error("Invalid PDF binary data: either typed array, string, or array-like object is expected in the data property.");n[d]=new Uint8Array(_)}else n[d]=new Uint8Array(_)}continue}n[d]=_}if(n.CMapReaderFactory=n.CMapReaderFactory||DefaultCMapReaderFactory,n.StandardFontDataFactory=n.StandardFontDataFactory||DefaultStandardFontDataFactory,n.ignoreErrors=!0!==n.stopAtErrors,n.fontExtraProperties=!0===n.fontExtraProperties,n.pdfBug=!0===n.pdfBug,n.enableXfa=!0===n.enableXfa,(!Number.isInteger(n.rangeChunkSize)||n.rangeChunkSize<1)&&(n.rangeChunkSize=DEFAULT_RANGE_CHUNK_SIZE),("string"!=typeof n.docBaseUrl||(0,_display_utils.isDataScheme)(n.docBaseUrl))&&(n.docBaseUrl=null),(!Number.isInteger(n.maxImageSize)||n.maxImageSize<-1)&&(n.maxImageSize=-1),"string"!=typeof n.cMapUrl&&(n.cMapUrl=null),"string"!=typeof n.standardFontDataUrl&&(n.standardFontDataUrl=null),"boolean"!=typeof n.useWorkerFetch&&(n.useWorkerFetch=n.CMapReaderFactory===_display_utils.DOMCMapReaderFactory&&n.StandardFontDataFactory===_display_utils.DOMStandardFontDataFactory),"boolean"!=typeof n.isEvalSupported&&(n.isEvalSupported=!0),"boolean"!=typeof n.disableFontFace&&(n.disableFontFace=_is_node.isNodeJS),"boolean"!=typeof n.useSystemFonts&&(n.useSystemFonts=!_is_node.isNodeJS&&!n.disableFontFace),("object"!=typeof n.ownerDocument||null===n.ownerDocument)&&(n.ownerDocument=globalThis.document),"boolean"!=typeof n.disableRange&&(n.disableRange=!1),"boolean"!=typeof n.disableStream&&(n.disableStream=!1),"boolean"!=typeof n.disableAutoFetch&&(n.disableAutoFetch=!1),(0,_util.setVerbosityLevel)(n.verbosity),!u){const d={verbosity:n.verbosity,port:_worker_options.GlobalWorkerOptions.workerPort};u=d.port?PDFWorker.fromPort(d):new PDFWorker(d),r._worker=u}const S=r.docId;return u.promise.then(function(){if(r.destroyed)throw new Error("Loading aborted");const d=_fetchDocument(u,n,s,S),_=new Promise(function(t){let i;s?i=new _transport_stream.PDFDataTransportStream({length:n.length,initialData:n.initialData,progressiveDone:n.progressiveDone,contentDispositionFilename:n.contentDispositionFilename,disableRange:n.disableRange,disableStream:n.disableStream},s):n.data||(i=createPDFNetworkStream({url:n.url,length:n.length,httpHeaders:n.httpHeaders,withCredentials:n.withCredentials,rangeChunkSize:n.rangeChunkSize,disableRange:n.disableRange,disableStream:n.disableStream})),t(i)});return Promise.all([d,_]).then(function([t,i]){if(r.destroyed)throw new Error("Loading aborted");const A=new _message_handler.MessageHandler(S,t,u.port),l=new WorkerTransport(A,r,i,n);r._transport=l,A.send("Ready",null)})}).catch(r._capability.reject),r}function _fetchDocument(f,r,p,n){return _fetchDocument2.apply(this,arguments)}function _fetchDocument2(){return(_fetchDocument2=_asyncToGenerator(function*(f,r,p,n){if(f.destroyed)throw new Error("Worker was destroyed");p&&(r.length=p.length,r.initialData=p.initialData,r.progressiveDone=p.progressiveDone,r.contentDispositionFilename=p.contentDispositionFilename);const s=yield f.messageHandler.sendWithPromise("GetDocRequest",{docId:n,apiVersion:"2.14.305",source:{data:r.data,url:r.url,password:r.password,disableAutoFetch:r.disableAutoFetch,rangeChunkSize:r.rangeChunkSize,length:r.length},maxImageSize:r.maxImageSize,disableFontFace:r.disableFontFace,docBaseUrl:r.docBaseUrl,ignoreErrors:r.ignoreErrors,isEvalSupported:r.isEvalSupported,fontExtraProperties:r.fontExtraProperties,enableXfa:r.enableXfa,useSystemFonts:r.useSystemFonts,cMapUrl:r.useWorkerFetch?r.cMapUrl:null,standardFontDataUrl:r.useWorkerFetch?r.standardFontDataUrl:null});if(f.destroyed)throw new Error("Worker was destroyed");return s})).apply(this,arguments)}const L=class{constructor(){this._capability=(0,_util.createPromiseCapability)(),this._transport=null,this._worker=null,this.docId="d"+lt(L,ue)._++,this.destroyed=!1,this.onPassword=null,this.onProgress=null,this.onUnsupportedFeature=null}get promise(){return this._capability.promise}destroy(){var r=this;return _asyncToGenerator(function*(){r.destroyed=!0,yield r._transport?.destroy(),r._transport=null,r._worker&&(r._worker.destroy(),r._worker=null)})()}};let PDFDocumentLoadingTask=L;ue=new WeakMap,ve(PDFDocumentLoadingTask,ue,0),exports.PDFDocumentLoadingTask=PDFDocumentLoadingTask;class PDFDataRangeTransport{constructor(r,p,n=!1,s=null){this.length=r,this.initialData=p,this.progressiveDone=n,this.contentDispositionFilename=s,this._rangeListeners=[],this._progressListeners=[],this._progressiveReadListeners=[],this._progressiveDoneListeners=[],this._readyCapability=(0,_util.createPromiseCapability)()}addRangeListener(r){this._rangeListeners.push(r)}addProgressListener(r){this._progressListeners.push(r)}addProgressiveReadListener(r){this._progressiveReadListeners.push(r)}addProgressiveDoneListener(r){this._progressiveDoneListeners.push(r)}onDataRange(r,p){for(const n of this._rangeListeners)n(r,p)}onDataProgress(r,p){this._readyCapability.promise.then(()=>{for(const n of this._progressListeners)n(r,p)})}onDataProgressiveRead(r){this._readyCapability.promise.then(()=>{for(const p of this._progressiveReadListeners)p(r)})}onDataProgressiveDone(){this._readyCapability.promise.then(()=>{for(const r of this._progressiveDoneListeners)r()})}transportReady(){this._readyCapability.resolve()}requestDataRange(r,p){(0,_util.unreachable)("Abstract method PDFDataRangeTransport.requestDataRange")}abort(){}}exports.PDFDataRangeTransport=PDFDataRangeTransport;class PDFDocumentProxy{constructor(r,p){var s,n=this;this._pdfInfo=r,this._transport=p,Object.defineProperty(this,"fingerprint",{get(){return(0,_display_utils.deprecated)("`PDFDocumentProxy.fingerprint`, please use `PDFDocumentProxy.fingerprints` instead."),this.fingerprints[0]}}),Object.defineProperty(this,"getStats",{value:(s=_asyncToGenerator(function*(){return(0,_display_utils.deprecated)("`PDFDocumentProxy.getStats`, please use the `PDFDocumentProxy.stats`-getter instead."),n.stats||{streamTypes:{},fontTypes:{}}}),function(){return s.apply(this,arguments)})})}get annotationStorage(){return this._transport.annotationStorage}get numPages(){return this._pdfInfo.numPages}get fingerprints(){return this._pdfInfo.fingerprints}get stats(){return this._transport.stats}get isPureXfa(){return!!this._transport._htmlForXfa}get allXfaHtml(){return this._transport._htmlForXfa}getPage(r){return this._transport.getPage(r)}getPageIndex(r){return this._transport.getPageIndex(r)}getDestinations(){return this._transport.getDestinations()}getDestination(r){return this._transport.getDestination(r)}getPageLabels(){return this._transport.getPageLabels()}getPageLayout(){return this._transport.getPageLayout()}getPageMode(){return this._transport.getPageMode()}getViewerPreferences(){return this._transport.getViewerPreferences()}getOpenAction(){return this._transport.getOpenAction()}getAttachments(){return this._transport.getAttachments()}getJavaScript(){return this._transport.getJavaScript()}getJSActions(){return this._transport.getDocJSActions()}getOutline(){return this._transport.getOutline()}getOptionalContentConfig(){return this._transport.getOptionalContentConfig()}getPermissions(){return this._transport.getPermissions()}getMetadata(){return this._transport.getMetadata()}getMarkInfo(){return this._transport.getMarkInfo()}getData(){return this._transport.getData()}getDownloadInfo(){return this._transport.downloadInfoCapability.promise}cleanup(r=!1){return this._transport.startCleanup(r||this.isPureXfa)}destroy(){return this.loadingTask.destroy()}get loadingParams(){return this._transport.loadingParams}get loadingTask(){return this._transport.loadingTask}saveDocument(){return this._transport.annotationStorage.size<=0&&(0,_display_utils.deprecated)("saveDocument called while `annotationStorage` is empty, please use the getData-method instead."),this._transport.saveDocument()}getFieldObjects(){return this._transport.getFieldObjects()}hasJSActions(){return this._transport.hasJSActions()}getCalculationOrderIds(){return this._transport.getCalculationOrderIds()}}exports.PDFDocumentProxy=PDFDocumentProxy;class PDFPageProxy{constructor(r,p,n,s,u=!1){this._pageIndex=r,this._pageInfo=p,this._ownerDocument=s,this._transport=n,this._stats=u?new _display_utils.StatTimer:null,this._pdfBug=u,this.commonObjs=n.commonObjs,this.objs=new PDFObjects,this._bitmaps=new Set,this.cleanupAfterRender=!1,this.pendingCleanup=!1,this._intentStates=new Map,this._annotationPromises=new Map,this.destroyed=!1}get pageNumber(){return this._pageIndex+1}get rotate(){return this._pageInfo.rotate}get ref(){return this._pageInfo.ref}get userUnit(){return this._pageInfo.userUnit}get view(){return this._pageInfo.view}getViewport({scale:r,rotation:p=this.rotate,offsetX:n=0,offsetY:s=0,dontFlip:u=!1}={}){return new _display_utils.PageViewport({viewBox:this.view,scale:r,rotation:p,offsetX:n,offsetY:s,dontFlip:u})}getAnnotations({intent:r="display"}={}){const p=this._transport.getRenderingIntent(r);let n=this._annotationPromises.get(p.cacheKey);return n||(n=this._transport.getAnnotations(this._pageIndex,p.renderingIntent),this._annotationPromises.set(p.cacheKey,n),n=n.then(s=>{for(const u of s)void 0!==u.titleObj&&Object.defineProperty(u,"title",{get:()=>((0,_display_utils.deprecated)("`title`-property on annotation, please use `titleObj` instead."),u.titleObj.str)}),void 0!==u.contentsObj&&Object.defineProperty(u,"contents",{get:()=>((0,_display_utils.deprecated)("`contents`-property on annotation, please use `contentsObj` instead."),u.contentsObj.str)});return s})),n}getJSActions(){return this._jsActionsPromise||(this._jsActionsPromise=this._transport.getPageJSActions(this._pageIndex))}getXfa(){var r=this;return _asyncToGenerator(function*(){return r._transport._htmlForXfa?.children[r._pageIndex]||null})()}render({canvasContext:r,viewport:p,intent:n="display",annotationMode:s=_util.AnnotationMode.ENABLE,transform:u=null,imageLayer:S=null,canvasFactory:d=null,background:_=null,optionalContentConfigPromise:t=null,annotationCanvasMap:i=null,pageColors:A=null}){void 0!==arguments[0]?.renderInteractiveForms&&((0,_display_utils.deprecated)("render no longer accepts the `renderInteractiveForms`-option, please use the `annotationMode`-option instead."),!0===arguments[0].renderInteractiveForms&&s===_util.AnnotationMode.ENABLE&&(s=_util.AnnotationMode.ENABLE_FORMS)),void 0!==arguments[0]?.includeAnnotationStorage&&((0,_display_utils.deprecated)("render no longer accepts the `includeAnnotationStorage`-option, please use the `annotationMode`-option instead."),!0===arguments[0].includeAnnotationStorage&&s===_util.AnnotationMode.ENABLE&&(s=_util.AnnotationMode.ENABLE_STORAGE)),this._stats&&this._stats.time("Overall");const l=this._transport.getRenderingIntent(n,s);this.pendingCleanup=!1,t||(t=this._transport.getOptionalContentConfig());let m=this._intentStates.get(l.cacheKey);m||(m=Object.create(null),this._intentStates.set(l.cacheKey,m)),m.streamReaderCancelTimeout&&(clearTimeout(m.streamReaderCancelTimeout),m.streamReaderCancelTimeout=null);const x=d||new DefaultCanvasFactory({ownerDocument:this._ownerDocument}),M=!!(l.renderingIntent&_util.RenderingIntentFlag.PRINT);m.displayReadyCapability||(m.displayReadyCapability=(0,_util.createPromiseCapability)(),m.operatorList={fnArray:[],argsArray:[],lastChunk:!1},this._stats&&this._stats.time("Page Request"),this._pumpOperatorList(l));const k=X=>{m.renderTasks.delete(I),(this.cleanupAfterRender||M)&&(this.pendingCleanup=!0),this._tryCleanup(),X?(I.capability.reject(X),this._abortOperatorList({intentState:m,reason:X instanceof Error?X:new Error(X)})):I.capability.resolve(),this._stats&&(this._stats.timeEnd("Rendering"),this._stats.timeEnd("Overall"))},I=new InternalRenderTask({callback:k,params:{canvasContext:r,viewport:p,transform:u,imageLayer:S,background:_},objs:this.objs,commonObjs:this.commonObjs,annotationCanvasMap:i,operatorList:m.operatorList,pageIndex:this._pageIndex,canvasFactory:x,useRequestAnimationFrame:!M,pdfBug:this._pdfBug,pageColors:A});(m.renderTasks||(m.renderTasks=new Set)).add(I);const j=I.task;return Promise.all([m.displayReadyCapability.promise,t]).then(([X,J])=>{this.pendingCleanup?k():(this._stats&&this._stats.time("Rendering"),I.initializeGraphics({transparency:X,optionalContentConfig:J}),I.operatorListChanged())}).catch(k),j}getOperatorList({intent:r="display",annotationMode:p=_util.AnnotationMode.ENABLE}={}){const s=this._transport.getRenderingIntent(r,p,!0);let S,u=this._intentStates.get(s.cacheKey);return u||(u=Object.create(null),this._intentStates.set(s.cacheKey,u)),u.opListReadCapability||(S=Object.create(null),S.operatorListChanged=function n(){u.operatorList.lastChunk&&(u.opListReadCapability.resolve(u.operatorList),u.renderTasks.delete(S))},u.opListReadCapability=(0,_util.createPromiseCapability)(),(u.renderTasks||(u.renderTasks=new Set)).add(S),u.operatorList={fnArray:[],argsArray:[],lastChunk:!1},this._stats&&this._stats.time("Page Request"),this._pumpOperatorList(s)),u.opListReadCapability.promise}streamTextContent({disableCombineTextItems:r=!1,includeMarkedContent:p=!1}={}){return this._transport.messageHandler.sendWithStream("GetTextContent",{pageIndex:this._pageIndex,combineTextItems:!0!==r,includeMarkedContent:!0===p},{highWaterMark:100,size:s=>s.items.length})}getTextContent(r={}){if(this._transport._htmlForXfa)return this.getXfa().then(n=>_xfa_text.XfaText.textContent(n));const p=this.streamTextContent(r);return new Promise(function(n,s){const S=p.getReader(),d={items:[],styles:Object.create(null)};!function u(){S.read().then(function({value:_,done:t}){t?n(d):(Object.assign(d.styles,_.styles),d.items.push(..._.items),u())},s)}()})}getStructTree(){return this._structTreePromise||(this._structTreePromise=this._transport.getStructTree(this._pageIndex))}_destroy(){this.destroyed=!0;const r=[];for(const p of this._intentStates.values())if(this._abortOperatorList({intentState:p,reason:new Error("Page was destroyed."),force:!0}),!p.opListReadCapability)for(const n of p.renderTasks)r.push(n.completed),n.cancel();this.objs.clear();for(const p of this._bitmaps)p.close();return this._bitmaps.clear(),this._annotationPromises.clear(),this._jsActionsPromise=null,this._structTreePromise=null,this.pendingCleanup=!1,Promise.all(r)}cleanup(r=!1){return this.pendingCleanup=!0,this._tryCleanup(r)}_tryCleanup(r=!1){if(!this.pendingCleanup)return!1;for(const{renderTasks:p,operatorList:n}of this._intentStates.values())if(p.size>0||!n.lastChunk)return!1;this._intentStates.clear(),this.objs.clear(),this._annotationPromises.clear(),this._jsActionsPromise=null,this._structTreePromise=null,r&&this._stats&&(this._stats=new _display_utils.StatTimer);for(const p of this._bitmaps)p.close();return this._bitmaps.clear(),this.pendingCleanup=!1,!0}_startRenderPage(r,p){const n=this._intentStates.get(p);!n||(this._stats&&this._stats.timeEnd("Page Request"),n.displayReadyCapability&&n.displayReadyCapability.resolve(r))}_renderPageChunk(r,p){for(let n=0,s=r.length;n<s;n++)p.operatorList.fnArray.push(r.fnArray[n]),p.operatorList.argsArray.push(r.argsArray[n]);p.operatorList.lastChunk=r.lastChunk;for(const n of p.renderTasks)n.operatorListChanged();r.lastChunk&&this._tryCleanup()}_pumpOperatorList({renderingIntent:r,cacheKey:p}){const s=this._transport.messageHandler.sendWithStream("GetOperatorList",{pageIndex:this._pageIndex,intent:r,cacheKey:p,annotationStorage:r&_util.RenderingIntentFlag.ANNOTATIONS_STORAGE?this._transport.annotationStorage.serializable:null}).getReader(),u=this._intentStates.get(p);u.streamReader=s;const S=()=>{s.read().then(({value:d,done:_})=>{_?u.streamReader=null:this._transport.destroyed||(this._renderPageChunk(d,u),S())},d=>{if(u.streamReader=null,!this._transport.destroyed){if(u.operatorList){u.operatorList.lastChunk=!0;for(const _ of u.renderTasks)_.operatorListChanged();this._tryCleanup()}if(u.displayReadyCapability)u.displayReadyCapability.reject(d);else{if(!u.opListReadCapability)throw d;u.opListReadCapability.reject(d)}}})};S()}_abortOperatorList({intentState:r,reason:p,force:n=!1}){if(r.streamReader){if(!n){if(r.renderTasks.size>0)return;if(p instanceof _display_utils.RenderingCancelledException)return void(r.streamReaderCancelTimeout=setTimeout(()=>{this._abortOperatorList({intentState:r,reason:p,force:!0}),r.streamReaderCancelTimeout=null},RENDERING_CANCELLED_TIMEOUT))}if(r.streamReader.cancel(new _util.AbortException(p.message)).catch(()=>{}),r.streamReader=null,!this._transport.destroyed){for(const[s,u]of this._intentStates)if(u===r){this._intentStates.delete(s);break}this.cleanup()}}}get stats(){return this._stats}}exports.PDFPageProxy=PDFPageProxy;class LoopbackPort{constructor(){this._listeners=[],this._deferred=Promise.resolve()}postMessage(r,p){const n={data:structuredClone(r,p)};this._deferred.then(()=>{for(const s of this._listeners)s.call(this,n)})}addEventListener(r,p){this._listeners.push(p)}removeEventListener(r,p){const n=this._listeners.indexOf(p);this._listeners.splice(n,1)}terminate(){this._listeners.length=0}}exports.LoopbackPort=LoopbackPort;const PDFWorkerUtil={isWorkerDisabled:!1,fallbackWorkerSrc:null,fakeWorkerId:0};if(exports.PDFWorkerUtil=PDFWorkerUtil,_is_node.isNodeJS)PDFWorkerUtil.isWorkerDisabled=!0,PDFWorkerUtil.fallbackWorkerSrc="./pdf.worker.js";else if("object"==typeof document){const f=document?.currentScript?.src;f&&(PDFWorkerUtil.fallbackWorkerSrc=f.replace(/(\.(?:min\.)?js)(\?.*)?$/i,".worker$1$2"))}PDFWorkerUtil.isSameOrigin=function(f,r){let p;try{if(p=new URL(f),!p.origin||"null"===p.origin)return!1}catch{return!1}const n=new URL(r,p);return p.origin===n.origin},PDFWorkerUtil.createCDNWrapper=function(f){return URL.createObjectURL(new Blob([`importScripts("${f}");`]))};const _PDFWorker=class{constructor({name:f=null,port:r=null,verbosity:p=(0,_util.getVerbosityLevel)()}={}){if(r&&Ae(_PDFWorker,ne).has(r))throw new Error("Cannot use more than one PDFWorker per port.");if(this.name=f,this.destroyed=!1,this.verbosity=p,this._readyCapability=(0,_util.createPromiseCapability)(),this._port=null,this._webWorker=null,this._messageHandler=null,r)return Ae(_PDFWorker,ne).set(r,this),void this._initializeFromPort(r);this._initialize()}get promise(){return this._readyCapability.promise}get port(){return this._port}get messageHandler(){return this._messageHandler}_initializeFromPort(f){this._port=f,this._messageHandler=new _message_handler.MessageHandler("main","worker",f),this._messageHandler.on("ready",function(){}),this._readyCapability.resolve()}_initialize(){if(typeof Worker<"u"&&!PDFWorkerUtil.isWorkerDisabled&&!_PDFWorker._mainThreadWorkerMessageHandler){let f=_PDFWorker.workerSrc;try{PDFWorkerUtil.isSameOrigin(window.location.href,f)||(f=PDFWorkerUtil.createCDNWrapper(new URL(f,window.location).href));const r=new Worker(f),p=new _message_handler.MessageHandler("main","worker",r),n=()=>{r.removeEventListener("error",s),p.destroy(),r.terminate(),this.destroyed?this._readyCapability.reject(new Error("Worker was destroyed")):this._setupFakeWorker()},s=()=>{this._webWorker||n()};r.addEventListener("error",s),p.on("test",S=>{r.removeEventListener("error",s),this.destroyed?n():S?(this._messageHandler=p,this._port=r,this._webWorker=r,this._readyCapability.resolve(),p.send("configure",{verbosity:this.verbosity})):(this._setupFakeWorker(),p.destroy(),r.terminate())}),p.on("ready",S=>{if(r.removeEventListener("error",s),this.destroyed)n();else try{u()}catch{this._setupFakeWorker()}});const u=()=>{const S=new Uint8Array;p.send("test",S,[S.buffer])};return void u()}catch{(0,_util.info)("The worker has been disabled.")}}this._setupFakeWorker()}_setupFakeWorker(){PDFWorkerUtil.isWorkerDisabled||((0,_util.warn)("Setting up fake worker."),PDFWorkerUtil.isWorkerDisabled=!0),_PDFWorker._setupFakeWorkerGlobal.then(f=>{if(this.destroyed)return void this._readyCapability.reject(new Error("Worker was destroyed"));const r=new LoopbackPort;this._port=r;const p="fake"+PDFWorkerUtil.fakeWorkerId++,n=new _message_handler.MessageHandler(p+"_worker",p,r);f.setup(n,r);const s=new _message_handler.MessageHandler(p,p+"_worker",r);this._messageHandler=s,this._readyCapability.resolve(),s.send("configure",{verbosity:this.verbosity})}).catch(f=>{this._readyCapability.reject(new Error(`Setting up fake worker failed: "${f.message}".`))})}destroy(){this.destroyed=!0,this._webWorker&&(this._webWorker.terminate(),this._webWorker=null),Ae(_PDFWorker,ne).delete(this._port),this._port=null,this._messageHandler&&(this._messageHandler.destroy(),this._messageHandler=null)}static fromPort(f){if(!f?.port)throw new Error("PDFWorker.fromPort - invalid method signature.");return Ae(this,ne).has(f.port)?Ae(this,ne).get(f.port):new _PDFWorker(f)}static get workerSrc(){if(_worker_options.GlobalWorkerOptions.workerSrc)return _worker_options.GlobalWorkerOptions.workerSrc;if(null!==PDFWorkerUtil.fallbackWorkerSrc)return _is_node.isNodeJS||(0,_display_utils.deprecated)('No "GlobalWorkerOptions.workerSrc" specified.'),PDFWorkerUtil.fallbackWorkerSrc;throw new Error('No "GlobalWorkerOptions.workerSrc" specified.')}static get _mainThreadWorkerMessageHandler(){try{return globalThis.pdfjsWorker?.WorkerMessageHandler||null}catch{return null}}static get _setupFakeWorkerGlobal(){var _this4=this;const loader=function(){var _ref2=_asyncToGenerator(function*(){const mainWorkerMessageHandler=_this4._mainThreadWorkerMessageHandler;if(mainWorkerMessageHandler)return mainWorkerMessageHandler;if(_is_node.isNodeJS){const worker=eval("require")(_this4.workerSrc);return worker.WorkerMessageHandler}return yield(0,_display_utils.loadScript)(_this4.workerSrc),window.pdfjsWorker.WorkerMessageHandler});return function f(){return _ref2.apply(this,arguments)}}();return(0,_util.shadow)(this,"_setupFakeWorkerGlobal",loader())}};let PDFWorker=_PDFWorker;ne=new WeakMap,ve(PDFWorker,ne,new WeakMap),exports.PDFWorker=PDFWorker,PDFWorker.getWorkerSrc=function(){return(0,_display_utils.deprecated)("`PDFWorker.getWorkerSrc()`, please use `PDFWorker.workerSrc` instead."),this.workerSrc};class WorkerTransport{constructor(r,p,n,s){ve(this,y,null),ve(this,oe,new Map),ve(this,G,new Map),ve(this,H,null),this.messageHandler=r,this.loadingTask=p,this.commonObjs=new PDFObjects,this.fontLoader=new _font_loader.FontLoader({docId:p.docId,onUnsupportedFeature:this._onUnsupportedFeature.bind(this),ownerDocument:s.ownerDocument,styleElement:s.styleElement}),this._params=s,s.useWorkerFetch||(this.CMapReaderFactory=new s.CMapReaderFactory({baseUrl:s.cMapUrl,isCompressed:s.cMapPacked}),this.StandardFontDataFactory=new s.StandardFontDataFactory({baseUrl:s.standardFontDataUrl})),this.destroyed=!1,this.destroyCapability=null,this._passwordCapability=null,this._networkStream=n,this._fullReader=null,this._lastProgress=null,this.downloadInfoCapability=(0,_util.createPromiseCapability)(),this.setupMessageHandler()}get annotationStorage(){return(0,_util.shadow)(this,"annotationStorage",new _annotation_storage.AnnotationStorage)}get stats(){return Ae(this,y)}getRenderingIntent(r,p=_util.AnnotationMode.ENABLE,n=!1){let s=_util.RenderingIntentFlag.DISPLAY,u="";switch(r){case"any":s=_util.RenderingIntentFlag.ANY;break;case"display":break;case"print":s=_util.RenderingIntentFlag.PRINT;break;default:(0,_util.warn)(`getRenderingIntent - invalid intent: ${r}`)}switch(p){case _util.AnnotationMode.DISABLE:s+=_util.RenderingIntentFlag.ANNOTATIONS_DISABLE;break;case _util.AnnotationMode.ENABLE:break;case _util.AnnotationMode.ENABLE_FORMS:s+=_util.RenderingIntentFlag.ANNOTATIONS_FORMS;break;case _util.AnnotationMode.ENABLE_STORAGE:s+=_util.RenderingIntentFlag.ANNOTATIONS_STORAGE,u=this.annotationStorage.hash;break;default:(0,_util.warn)(`getRenderingIntent - invalid annotationMode: ${p}`)}return n&&(s+=_util.RenderingIntentFlag.OPLIST),{renderingIntent:s,cacheKey:`${s}_${u}`}}destroy(){if(this.destroyCapability)return this.destroyCapability.promise;this.destroyed=!0,this.destroyCapability=(0,_util.createPromiseCapability)(),this._passwordCapability&&this._passwordCapability.reject(new Error("Worker was destroyed during onPassword callback"));const r=[];for(const n of Ae(this,oe).values())r.push(n._destroy());Ae(this,oe).clear(),Ae(this,G).clear(),this.hasOwnProperty("annotationStorage")&&this.annotationStorage.resetModified();const p=this.messageHandler.sendWithPromise("Terminate",null);return r.push(p),Promise.all(r).then(()=>{this.commonObjs.clear(),this.fontLoader.clear(),Te(this,H,null),this._getFieldObjectsPromise=null,this._hasJSActionsPromise=null,this._networkStream&&this._networkStream.cancelAllRequests(new _util.AbortException("Worker was terminated.")),this.messageHandler&&(this.messageHandler.destroy(),this.messageHandler=null),this.destroyCapability.resolve()},this.destroyCapability.reject),this.destroyCapability.promise}setupMessageHandler(){const{messageHandler:r,loadingTask:p}=this;r.on("GetReader",(n,s)=>{(0,_util.assert)(this._networkStream,"GetReader - no `IPDFStream` instance available."),this._fullReader=this._networkStream.getFullReader(),this._fullReader.onProgress=u=>{this._lastProgress={loaded:u.loaded,total:u.total}},s.onPull=()=>{this._fullReader.read().then(function({value:u,done:S}){S?s.close():((0,_util.assert)((0,_util.isArrayBuffer)(u),"GetReader - expected an ArrayBuffer."),s.enqueue(new Uint8Array(u),1,[u]))}).catch(u=>{s.error(u)})},s.onCancel=u=>{this._fullReader.cancel(u),s.ready.catch(S=>{if(!this.destroyed)throw S})}}),r.on("ReaderHeadersReady",n=>{const s=(0,_util.createPromiseCapability)(),u=this._fullReader;return u.headersReady.then(()=>{(!u.isStreamingSupported||!u.isRangeSupported)&&(this._lastProgress&&p.onProgress?.(this._lastProgress),u.onProgress=S=>{p.onProgress?.({loaded:S.loaded,total:S.total})}),s.resolve({isStreamingSupported:u.isStreamingSupported,isRangeSupported:u.isRangeSupported,contentLength:u.contentLength})},s.reject),s.promise}),r.on("GetRangeReader",(n,s)=>{(0,_util.assert)(this._networkStream,"GetRangeReader - no `IPDFStream` instance available.");const u=this._networkStream.getRangeReader(n.begin,n.end);u?(s.onPull=()=>{u.read().then(function({value:S,done:d}){d?s.close():((0,_util.assert)((0,_util.isArrayBuffer)(S),"GetRangeReader - expected an ArrayBuffer."),s.enqueue(new Uint8Array(S),1,[S]))}).catch(S=>{s.error(S)})},s.onCancel=S=>{u.cancel(S),s.ready.catch(d=>{if(!this.destroyed)throw d})}):s.close()}),r.on("GetDoc",({pdfInfo:n})=>{this._numPages=n.numPages,this._htmlForXfa=n.htmlForXfa,delete n.htmlForXfa,p._capability.resolve(new PDFDocumentProxy(n,this))}),r.on("DocException",function(n){let s;switch(n.name){case"PasswordException":s=new _util.PasswordException(n.message,n.code);break;case"InvalidPDFException":s=new _util.InvalidPDFException(n.message);break;case"MissingPDFException":s=new _util.MissingPDFException(n.message);break;case"UnexpectedResponseException":s=new _util.UnexpectedResponseException(n.message,n.status);break;case"UnknownErrorException":s=new _util.UnknownErrorException(n.message,n.details);break;default:(0,_util.unreachable)("DocException - expected a valid Error.")}p._capability.reject(s)}),r.on("PasswordRequest",n=>{if(this._passwordCapability=(0,_util.createPromiseCapability)(),p.onPassword){const s=u=>{u instanceof Error?this._passwordCapability.reject(u):this._passwordCapability.resolve({password:u})};try{p.onPassword(s,n.code)}catch(u){this._passwordCapability.reject(u)}}else this._passwordCapability.reject(new _util.PasswordException(n.message,n.code));return this._passwordCapability.promise}),r.on("DataLoaded",n=>{p.onProgress?.({loaded:n.length,total:n.length}),this.downloadInfoCapability.resolve(n)}),r.on("StartRenderPage",n=>{this.destroyed||Ae(this,oe).get(n.pageIndex)._startRenderPage(n.transparency,n.cacheKey)}),r.on("commonobj",([n,s,u])=>{if(!this.destroyed&&!this.commonObjs.has(n))switch(s){case"Font":const S=this._params;if("error"in u){const t=u.error;(0,_util.warn)(`Error during font loading: ${t}`),this.commonObjs.resolve(n,t);break}let d=null;S.pdfBug&&globalThis.FontInspector?.enabled&&(d={registerFont(t,i){globalThis.FontInspector.fontAdded(t,i)}});const _=new _font_loader.FontFaceObject(u,{isEvalSupported:S.isEvalSupported,disableFontFace:S.disableFontFace,ignoreErrors:S.ignoreErrors,onUnsupportedFeature:this._onUnsupportedFeature.bind(this),fontRegistry:d});this.fontLoader.bind(_).catch(t=>r.sendWithPromise("FontFallback",{id:n})).finally(()=>{!S.fontExtraProperties&&_.data&&(_.data=null),this.commonObjs.resolve(n,_)});break;case"FontPath":case"Image":this.commonObjs.resolve(n,u);break;default:throw new Error(`Got unknown common object type ${s}`)}}),r.on("obj",([n,s,u,S])=>{if(this.destroyed)return;const d=Ae(this,oe).get(s);if(!d.objs.has(n))switch(u){case"Image":d.objs.resolve(n,S);const _=8e6;if(S){let t;if(S.bitmap){const{bitmap:i,width:A,height:l}=S;t=A*l*4,d._bitmaps.add(i)}else t=S.data?.length||0;t>_&&(d.cleanupAfterRender=!0)}break;case"Pattern":d.objs.resolve(n,S);break;default:throw new Error(`Got unknown object type ${u}`)}}),r.on("DocProgress",n=>{this.destroyed||p.onProgress?.({loaded:n.loaded,total:n.total})}),r.on("DocStats",n=>{this.destroyed||Te(this,y,Object.freeze({streamTypes:Object.freeze(n.streamTypes),fontTypes:Object.freeze(n.fontTypes)}))}),r.on("UnsupportedFeature",this._onUnsupportedFeature.bind(this)),r.on("FetchBuiltInCMap",n=>this.destroyed?Promise.reject(new Error("Worker was destroyed.")):this.CMapReaderFactory?this.CMapReaderFactory.fetch(n):Promise.reject(new Error("CMapReaderFactory not initialized, see the `useWorkerFetch` parameter."))),r.on("FetchStandardFontData",n=>this.destroyed?Promise.reject(new Error("Worker was destroyed.")):this.StandardFontDataFactory?this.StandardFontDataFactory.fetch(n):Promise.reject(new Error("StandardFontDataFactory not initialized, see the `useWorkerFetch` parameter.")))}_onUnsupportedFeature({featureId:r}){this.destroyed||this.loadingTask.onUnsupportedFeature?.(r)}getData(){return this.messageHandler.sendWithPromise("GetData",null)}getPage(r){if(!Number.isInteger(r)||r<=0||r>this._numPages)return Promise.reject(new Error("Invalid page request."));const p=r-1,n=Ae(this,G).get(p);if(n)return n;const s=this.messageHandler.sendWithPromise("GetPage",{pageIndex:p}).then(u=>{if(this.destroyed)throw new Error("Transport destroyed");const S=new PDFPageProxy(p,u,this,this._params.ownerDocument,this._params.pdfBug);return Ae(this,oe).set(p,S),S});return Ae(this,G).set(p,s),s}getPageIndex(r){return"object"!=typeof r||null===r||!Number.isInteger(r.num)||r.num<0||!Number.isInteger(r.gen)||r.gen<0?Promise.reject(new Error("Invalid pageIndex request.")):this.messageHandler.sendWithPromise("GetPageIndex",{num:r.num,gen:r.gen})}getAnnotations(r,p){return this.messageHandler.sendWithPromise("GetAnnotations",{pageIndex:r,intent:p})}saveDocument(){return this.messageHandler.sendWithPromise("SaveDocument",{isPureXfa:!!this._htmlForXfa,numPages:this._numPages,annotationStorage:this.annotationStorage.serializable,filename:this._fullReader?.filename??null}).finally(()=>{this.annotationStorage.resetModified()})}getFieldObjects(){return this._getFieldObjectsPromise||(this._getFieldObjectsPromise=this.messageHandler.sendWithPromise("GetFieldObjects",null))}hasJSActions(){return this._hasJSActionsPromise||(this._hasJSActionsPromise=this.messageHandler.sendWithPromise("HasJSActions",null))}getCalculationOrderIds(){return this.messageHandler.sendWithPromise("GetCalculationOrderIds",null)}getDestinations(){return this.messageHandler.sendWithPromise("GetDestinations",null)}getDestination(r){return"string"!=typeof r?Promise.reject(new Error("Invalid destination request.")):this.messageHandler.sendWithPromise("GetDestination",{id:r})}getPageLabels(){return this.messageHandler.sendWithPromise("GetPageLabels",null)}getPageLayout(){return this.messageHandler.sendWithPromise("GetPageLayout",null)}getPageMode(){return this.messageHandler.sendWithPromise("GetPageMode",null)}getViewerPreferences(){return this.messageHandler.sendWithPromise("GetViewerPreferences",null)}getOpenAction(){return this.messageHandler.sendWithPromise("GetOpenAction",null)}getAttachments(){return this.messageHandler.sendWithPromise("GetAttachments",null)}getJavaScript(){return this.messageHandler.sendWithPromise("GetJavaScript",null)}getDocJSActions(){return this.messageHandler.sendWithPromise("GetDocJSActions",null)}getPageJSActions(r){return this.messageHandler.sendWithPromise("GetPageJSActions",{pageIndex:r})}
1getStructTree(r){return this.messageHandler.sendWithPromise("GetStructTree",{pageIndex:r})}getOutline(){return this.messageHandler.sendWithPromise("GetOutline",null)}getOptionalContentConfig(){return this.messageHandler.sendWithPromise("GetOptionalContentConfig",null).then(r=>new _optional_content_config.OptionalContentConfig(r))}getPermissions(){return this.messageHandler.sendWithPromise("GetPermissions",null)}getMetadata(){return Ae(this,H)||Te(this,H,this.messageHandler.sendWithPromise("GetMetadata",null).then(r=>({info:r[0],metadata:r[1]?new _metadata.Metadata(r[1]):null,contentDispositionFilename:this._fullReader?.filename??null,contentLength:this._fullReader?.contentLength??null})))}getMarkInfo(){return this.messageHandler.sendWithPromise("GetMarkInfo",null)}startCleanup(r=!1){var p=this;return _asyncToGenerator(function*(){if(yield p.messageHandler.sendWithPromise("Cleanup",null),!p.destroyed){for(const n of Ae(p,oe).values())if(!n.cleanup())throw new Error(`startCleanup: Page ${n.pageNumber} is currently rendering.`);p.commonObjs.clear(),r||p.fontLoader.clear(),Te(p,H,null),p._getFieldObjectsPromise=null,p._hasJSActionsPromise=null}})()}get loadingParams(){const r=this._params;return(0,_util.shadow)(this,"loadingParams",{disableAutoFetch:r.disableAutoFetch,enableXfa:r.enableXfa})}}y=new WeakMap,oe=new WeakMap,G=new WeakMap,H=new WeakMap;class PDFObjects{constructor(){ve(this,O),ve(this,W,Object.create(null))}get(r,p=null){if(p){const s=ye(this,O,Qe).call(this,r);return s.capability.promise.then(()=>p(s.data)),null}const n=Ae(this,W)[r];if(!n?.capability.settled)throw new Error(`Requesting object that isn't resolved yet ${r}.`);return n.data}has(r){return Ae(this,W)[r]?.capability.settled||!1}resolve(r,p=null){const n=ye(this,O,Qe).call(this,r);
1n.data=p,n.capability.resolve()}clear(){Te(this,W,Object.create(null))}}W=new WeakMap,O=new WeakSet,Qe=function(r){return Ae(this,W)[r]||(Ae(this,W)[r]={capability:(0,_util.createPromiseCapability)(),data:null})};class RenderTask{constructor(r){this._internalRenderTask=r,this.onContinue=null}get promise(){return this._internalRenderTask.capability.promise}cancel(){this._internalRenderTask.cancel()}}exports.RenderTask=RenderTask;const g=class{constructor({callback:r,params:p,objs:n,commonObjs:s,annotationCanvasMap:u,operatorList:S,pageIndex:d,canvasFactory:_,useRequestAnimationFrame:t=!1,pdfBug:i=!1,pageColors:A=null}){this.callback=r,this.params=p,this.objs=n,this.commonObjs=s,this.annotationCanvasMap=u,this.operatorListIdx=null,this.operatorList=S,this._pageIndex=d,this.canvasFactory=_,this._pdfBug=i,this.pageColors=A,this.running=!1,this.graphicsReadyCallback=null,this.graphicsReady=!1,this._useRequestAnimationFrame=!0===t&&typeof window<"u",this.cancelled=!1,this.capability=(0,_util.createPromiseCapability)(),this.task=new RenderTask(this),this._cancelBound=this.cancel.bind(this),this._continueBound=this._continue.bind(this),this._scheduleNextBound=this._scheduleNext.bind(this),this._nextBound=this._next.bind(this),this._canvas=p.canvasContext.canvas}get completed(){return this.capability.promise.catch(function(){})}initializeGraphics({transparency:r=!1,optionalContentConfig:p}){if(this.cancelled)return;if(this._canvas){if(Ae(g,v).has(this._canvas))throw new Error("Cannot use the same canvas during multiple render() operations. Use different canvas or ensure previous operations were cancelled or completed.");Ae(g,v).add(this._canvas)}this._pdfBug&&globalThis.StepperManager?.enabled&&(this.stepper=globalThis.StepperManager.create(this._pageIndex),this.stepper.init(this.operatorList),this.stepper.nextBreakPoint=this.stepper.getNextBreakPoint());const{canvasContext:n,viewport:s,transform:u,imageLayer:S,background:d}=this.params;this.gfx=new _canvas.CanvasGraphics(n,this.commonObjs,this.objs,this.canvasFactory,S,p,this.annotationCanvasMap,this.pageColors),this.gfx.beginDrawing({transform:u,viewport:s,transparency:r,background:d}),this.operatorListIdx=0,this.graphicsReady=!0,this.graphicsReadyCallback&&this.graphicsReadyCallback()}cancel(r=null){this.running=!1,this.cancelled=!0,this.gfx&&this.gfx.endDrawing(),this._canvas&&Ae(g,v).delete(this._canvas),this.callback(r||new _display_utils.RenderingCancelledException(`Rendering cancelled, page ${this._pageIndex+1}`,"canvas"))}operatorListChanged(){this.graphicsReady?(this.stepper&&this.stepper.updateOperatorList(this.operatorList),!this.running&&this._continue()):this.graphicsReadyCallback||(this.graphicsReadyCallback=this._continueBound)}_continue(){this.running=!0,!this.cancelled&&(this.task.onContinue?this.task.onContinue(this._scheduleNextBound):this._scheduleNext())}_scheduleNext(){this._useRequestAnimationFrame?window.requestAnimationFrame(()=>{this._nextBound().catch(this._cancelBound)}):Promise.resolve().then(this._nextBound).catch(this._cancelBound)}_next(){var r=this;return _asyncToGenerator(function*(){r.cancelled||(r.operatorListIdx=r.gfx.executeOperatorList(r.operatorList,r.operatorListIdx,r._continueBound,r.stepper),r.operatorListIdx===r.operatorList.argsArray.length&&(r.running=!1,r.operatorList.lastChunk&&(r.gfx.endDrawing(),r._canvas&&Ae(g,v).delete(r._canvas),r.callback())))})()}};let InternalRenderTask=g;v=new WeakMap,ve(InternalRenderTask,v,new WeakSet);const version="2.14.305";exports.version=version;const build="eaaa8b4ad";exports.build=build},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.StatTimer=L.RenderingCancelledException=L.PixelsPerInch=L.PageViewport=L.PDFDateString=L.DOMStandardFontDataFactory=L.DOMSVGFactory=L.DOMCanvasFactory=L.DOMCMapReaderFactory=void 0,L.deprecated=function i(M){console.log("Deprecated API usage: "+M)},L.getFilenameFromUrl=function u(M){const k=M.indexOf("#"),I=M.indexOf("?"),j=Math.min(k>0?k:M.length,I>0?I:M.length);return M.substring(M.lastIndexOf("/",j)+1,j)},L.getPdfFilenameFromUrl=function S(M,k="document.pdf"){if("string"!=typeof M)return k;
vendor: 16,617 bytes, line 1
1if(n(M))return(0,oe.warn)('getPdfFilenameFromUrl: ignore "data:"-URL for performance reasons.'),k;const j=/[^/?#=]+\.pdf\b(?!.*\.pdf\b)/i,X=/^(?:(?:[^:]+:)?\/\/[^/]+)?([^?#]*)(\?[^#]*)?(#.*)?$/.exec(M);let J=j.exec(X[1])||j.exec(X[2])||j.exec(X[3]);if(J&&(J=J[0],J.includes("%")))try{J=j.exec(decodeURIComponent(J))[0]}catch{}return J||k},L.getXfaPageViewport=function m(M,{scale:k=1,rotation:I=0}){const{width:j,height:X}=M.attributes.style,J=[0,0,parseInt(j),parseInt(X)];return new r({viewBox:J,scale:k,rotation:I})},L.isDataScheme=n,L.isPdfFile=function s(M){return"string"==typeof M&&/\.pdf$/i.test(M)},L.isValidFetchUrl=_,L.loadScript=function t(M,k=!1){return new Promise((I,j)=>{const X=document.createElement("script");X.src=M,X.onload=function(J){k&&X.remove(),I(J)},X.onerror=function(){j(new Error(`Cannot load script at: ${X.src}`))},(document.head||document.documentElement).appendChild(X)})};var y=ne(6),oe=ne(1);const x=class{};let A,H=x;function O(M){return a.apply(this,arguments)}function a(){return(a=_asyncToGenerator(function*(M,k=!1){if(_(M,document.baseURI)){const I=yield fetch(M);if(!I.ok)throw new Error(I.statusText);return k?new Uint8Array(yield I.arrayBuffer()):(0,oe.stringToBytes)(yield I.text())}return new Promise((I,j)=>{const X=new XMLHttpRequest;X.open("GET",M,!0),k&&(X.responseType="arraybuffer"),X.onreadystatechange=()=>{if(X.readyState===XMLHttpRequest.DONE){if(200===X.status||0===X.status){let J;if(k&&X.response?J=new Uint8Array(X.response):!k&&X.responseText&&(J=(0,oe.stringToBytes)(X.responseText)),J)return void I(J)}j(new Error(X.statusText))}},X.send(null)})})).apply(this,arguments)}ze(H,"CSS",96),ze(H,"PDF",72),ze(H,"PDF_TO_CSS_UNITS",x.CSS/x.PDF),L.PixelsPerInch=H,L.DOMCanvasFactory=class W extends y.BaseCanvasFactory{constructor({ownerDocument:k=globalThis.document}={}){super(),this._document=k}_createCanvas(k,I){const j=this._document.createElement("canvas");return j.width=k,j.height=I,j}},L.DOMCMapReaderFactory=class v extends y.BaseCMapReaderFactory{_fetchData(k,I){return O(k,this.isCompressed).then(j=>({cMapData:j,compressionType:I}))}},L.DOMStandardFontDataFactory=class g extends y.BaseStandardFontDataFactory{_fetchData(k){return O(k,!0)}},L.DOMSVGFactory=class f extends y.BaseSVGFactory{_createSVG(k){return document.createElementNS("http://www.w3.org/2000/svg",k)}};class r{constructor({viewBox:k,scale:I,rotation:j,offsetX:X=0,offsetY:J=0,dontFlip:N=!1}){this.viewBox=k,this.scale=I,this.rotation=j,this.offsetX=X,this.offsetY=J;const $=(k[2]+k[0])/2,K=(k[3]+k[1])/2;let te,se,T,o,h,e,c,b;switch((j%=360)<0&&(j+=360),j){case 180:te=-1,se=0,T=0,o=1;break;case 90:te=0,se=1,T=1,o=0;break;case 270:te=0,se=-1,T=-1,o=0;break;case 0:te=1,se=0,T=0,o=-1;break;default:throw new Error("PageViewport: Invalid rotation, must be a multiple of 90 degrees.")}N&&(T=-T,o=-o),0===te?(h=Math.abs(K-k[1])*I+X,e=Math.abs($-k[0])*I+J,c=Math.abs(k[3]-k[1])*I,b=Math.abs(k[2]-k[0])*I):(h=Math.abs($-k[0])*I+X,e=Math.abs(K-k[1])*I+J,c=Math.abs(k[2]-k[0])*I,b=Math.abs(k[3]-k[1])*I),this.transform=[te*I,se*I,T*I,o*I,h-te*I*$-T*I*K,e-se*I*$-o*I*K],this.width=c,this.height=b}clone({scale:k=this.scale,rotation:I=this.rotation,offsetX:j=this.offsetX,offsetY:X=this.offsetY,dontFlip:J=!1}={}){return new r({viewBox:this.viewBox.slice(),scale:k,rotation:I,offsetX:j,offsetY:X,dontFlip:J})}convertToViewportPoint(k,I){return oe.Util.applyTransform([k,I],this.transform)}convertToViewportRectangle(k){const I=oe.Util.applyTransform([k[0],k[1]],this.transform),j=oe.Util.applyTransform([k[2],k[3]],this.transform);return[I[0],I[1],j[0],j[1]]}convertToPdfPoint(k,I){return oe.Util.applyInverseTransform([k,I],this.transform)}}function n(M){const k=M.length;let I=0;for(;I<k&&""===M[I].trim();)I++;return"data:"===M.substring(I,I+5).toLowerCase()}function _(M,k){try{const{protocol:I}=k?new URL(M,k):new URL(M);return"http:"===I||"https:"===I}catch{return!1}}L.PageViewport=r,L.RenderingCancelledException=class p extends oe.BaseException{constructor(k,I){super(k,"RenderingCancelledException"),this.type=I}},L.StatTimer=class d{constructor(){this.started=Object.create(null),this.times=[]}time(k){k in this.started&&(0,oe.warn)(`Timer is already running for ${k}`),this.started[k]=Date.now()}timeEnd(k){k in this.started||(0,oe.warn)(`Timer has not been started for ${k}`),this.times.push({name:k,start:this.started[k],end:Date.now()}),delete this.started[k]}toString(){const k=[];let I=0;for(const j of this.times){const X=j.name;X.length>I&&(I=X.length)}for(const j of this.times){const X=j.end-j.start;k.push(`${j.name.padEnd(I)} ${X}ms\n`)}return k.join("")}},L.PDFDateString=class l{static toDateObject(k){if(!k||"string"!=typeof k)return null;A||(A=new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?"));const I=A.exec(k);if(!I)return null;const j=parseInt(I[1],10);let X=parseInt(I[2],10);X=X>=1&&X<=12?X-1:0;let J=parseInt(I[3],10);J=J>=1&&J<=31?J:1;let N=parseInt(I[4],10);N=N>=0&&N<=23?N:0;let $=parseInt(I[5],10);$=$>=0&&$<=59?$:0;let K=parseInt(I[6],10);K=K>=0&&K<=59?K:0;const te=I[7]||"Z";let se=parseInt(I[8],10);se=se>=0&&se<=23?se:0;let T=parseInt(I[9],10)||0;return T=T>=0&&T<=59?T:0,"-"===te?(N+=se,$+=T):"+"===te&&(N-=se,$-=T),new Date(Date.UTC(j,X,J,N,$,K))}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.BaseStandardFontDataFactory=L.BaseSVGFactory=L.BaseCanvasFactory=L.BaseCMapReaderFactory=void 0;var y=ne(1);class oe{constructor(){this.constructor===oe&&(0,y.unreachable)("Cannot initialize BaseCanvasFactory.")}create(a,v){if(a<=0||v<=0)throw new Error("Invalid canvas size");const g=this._createCanvas(a,v);return{canvas:g,context:g.getContext("2d")}}reset(a,v,g){if(!a.canvas)throw new Error("Canvas is not specified");if(v<=0||g<=0)throw new Error("Invalid canvas size");a.canvas.width=v,a.canvas.height=g}destroy(a){if(!a.canvas)throw new Error("Canvas is not specified");a.canvas.width=0,a.canvas.height=0,a.canvas=null,a.context=null}_createCanvas(a,v){(0,y.unreachable)("Abstract method `_createCanvas` called.")}}L.BaseCanvasFactory=oe;class G{constructor({baseUrl:a=null,isCompressed:v=!1}){this.constructor===G&&(0,y.unreachable)("Cannot initialize BaseCMapReaderFactory."),this.baseUrl=a,this.isCompressed=v}fetch({name:a}){var v=this;return _asyncToGenerator(function*(){if(!v.baseUrl)throw new Error('The CMap "baseUrl" parameter must be specified, ensure that the "cMapUrl" and "cMapPacked" API parameters are provided.');if(!a)throw new Error("CMap name must be specified.");const g=v.baseUrl+a+(v.isCompressed?".bcmap":"");return v._fetchData(g,v.isCompressed?y.CMapCompressionType.BINARY:y.CMapCompressionType.NONE).catch(r=>{throw new Error(`Unable to load ${v.isCompressed?"binary ":""}CMap at: ${g}`)})})()}_fetchData(a,v){(0,y.unreachable)("Abstract method `_fetchData` called.")}}L.BaseCMapReaderFactory=G;class H{constructor({baseUrl:a=null}){this.constructor===H&&(0,y.unreachable)("Cannot initialize BaseStandardFontDataFactory."),this.baseUrl=a}fetch({filename:a}){var v=this;return _asyncToGenerator(function*(){if(!v.baseUrl)throw new Error('The standard font "baseUrl" parameter must be specified, ensure that the "standardFontDataUrl" API parameter is provided.');if(!a)throw new Error("Font filename must be specified.");const g=`${v.baseUrl}${a}`;return v._fetchData(g).catch(f=>{throw new Error(`Unable to load font data at: ${g}`)})})()}_fetchData(a){(0,y.unreachable)("Abstract method `_fetchData` called.")}}L.BaseStandardFontDataFactory=H;class W{constructor(){this.constructor===W&&(0,y.unreachable)("Cannot initialize BaseSVGFactory.")}create(a,v){if(a<=0||v<=0)throw new Error("Invalid SVG dimensions");const g=this._createSVG("svg:svg");return g.setAttribute("version","1.1"),g.setAttribute("width",`${a}px`),g.setAttribute("height",`${v}px`),g.setAttribute("preserveAspectRatio","none"),g.setAttribute("viewBox",`0 0 ${a} ${v}`),g}createElement(a){if("string"!=typeof a)throw new Error("Invalid SVG element type");return this._createSVG(a)}_createSVG(a){(0,y.unreachable)("Abstract method `_createSVG` called.")}}L.BaseSVGFactory=W},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.FontLoader=L.FontFaceObject=void 0;var y=ne(1);class oe{constructor({docId:O,onUnsupportedFeature:a,ownerDocument:v=globalThis.document,styleElement:g=null}){this.constructor===oe&&(0,y.unreachable)("Cannot initialize BaseFontLoader."),this.docId=O,this._onUnsupportedFeature=a,this._document=v,this.nativeFontFaces=[],this.styleElement=null}addNativeFontFace(O){this.nativeFontFaces.push(O),this._document.fonts.add(O)}insertRule(O){let a=this.styleElement;a||(a=this.styleElement=this._document.createElement("style"),a.id=`PDFJS_FONT_STYLE_TAG_${this.docId}`,this._document.documentElement.getElementsByTagName("head")[0].appendChild(a));const v=a.sheet;v.insertRule(O,v.cssRules.length)}clear(){for(const O of this.nativeFontFaces)this._document.fonts.delete(O);this.nativeFontFaces.length=0,this.styleElement&&(this.styleElement.remove(),this.styleElement=null)}bind(O){var a=this;return _asyncToGenerator(function*(){if(O.attached||O.missingFile)return;if(O.attached=!0,a.isFontLoadingAPISupported){const g=O.createNativeFontFace();if(g){a.addNativeFontFace(g);try{yield g.loaded}catch(f){throw a._onUnsupportedFeature({featureId:y.UNSUPPORTED_FEATURES.errorFontLoadNative}),(0,y.warn)(`Failed to load font '${g.family}': '${f}'.`),O.disableFontFace=!0,f}}return}const v=O.createFontFaceRule();if(v){if(a.insertRule(v),a.isSyncFontLoadingSupported)return;yield new Promise(g=>{const f=a._queueLoadingCallback(g);a._prepareFontLoadEvent([v],[O],f)})}})()}_queueLoadingCallback(O){(0,y.unreachable)("Abstract method `_queueLoadingCallback`.")}get isFontLoadingAPISupported(){return(0,y.shadow)(this,"isFontLoadingAPISupported",!!this._document?.fonts)}get isSyncFontLoadingSupported(){(0,y.unreachable)("Abstract method `isSyncFontLoadingSupported`.")}get _loadTestFont(){(0,y.unreachable)("Abstract method `_loadTestFont`.")}_prepareFontLoadEvent(O,a,v){(0,y.unreachable)("Abstract method `_prepareFontLoadEvent`.")}}let G;L.FontLoader=G,L.FontLoader=G=class extends oe{constructor(O){super(O),this.loadingContext={requests:[],nextRequestId:0},this.loadTestFontId=0}get isSyncFontLoadingSupported(){let O=!1;return(typeof navigator>"u"||/Mozilla\/5.0.*?rv:(\d+).*? Gecko/.exec(navigator.userAgent)?.[1]>=14)&&(O=!0),(0,y.shadow)(this,"isSyncFontLoadingSupported",O)}_queueLoadingCallback(O){const v=this.loadingContext,g={id:"pdfjs-font-loading-"+v.nextRequestId++,done:!1,complete:function a(){for((0,y.assert)(!g.done,"completeRequest() cannot be called twice."),g.done=!0;v.requests.length>0&&v.requests[0].done;){const f=v.requests.shift();setTimeout(f.callback,0)}},callback:O};return v.requests.push(g),g}get _loadTestFont(){return(0,y.shadow)(this,"_loadTestFont",atob("T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQAFQAABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABDQLUAAACNAAAAUJoZWFk/xVFDQAAALwAAAA2aGhlYQdkA+oAAAD0AAAAJGhtdHgD6AAAAAAEWAAAAAZtYXhwAAJQAAAAARgAAAAGbmFtZVjmdH4AAAGAAAAAsXBvc3T/hgAzAAADeAAAACAAAQAAAAEAALZRFsRfDzz1AAsD6AAAAADOBOTLAAAAAM4KHDwAAAAAA+gDIQAAAAgAAgAAAAAAAAABAAADIQAAAFoD6AAAAAAD6AABAAAAAAAAAAAAAAAAAAAAAQAAUAAAAgAAAAQD6AH0AAUAAAKKArwAAACMAooCvAAAAeAAMQECAAACAAYJAAAAAAAAAAAAAQAAAAAAAAAAAAAAAFBmRWQAwAAuAC4DIP84AFoDIQAAAAAAAQAAAAAAAAAAACAAIAABAAAADgCuAAEAAAAAAAAAAQAAAAEAAAAAAAEAAQAAAAEAAAAAAAIAAQAAAAEAAAAAAAMAAQAAAAEAAAAAAAQAAQAAAAEAAAAAAAUAAQAAAAEAAAAAAAYAAQAAAAMAAQQJAAAAAgABAAMAAQQJAAEAAgABAAMAAQQJAAIAAgABAAMAAQQJAAMAAgABAAMAAQQJAAQAAgABAAMAAQQJAAUAAgABAAMAAQQJAAYAAgABWABYAAAAAAAAAwAAAAMAAAAcAAEAAAAAADwAAwABAAAAHAAEACAAAAAEAAQAAQAAAC7//wAAAC7////TAAEAAAAAAAABBgAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAAAAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgcA/gXBIwMAYuL+nz5tQXkD5j3CBLnEQACAQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYAAABAQAADwACAQEEE/t3Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQAAAAAAAABAAAAAMmJbzEAAAAAzgTjFQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA=="))}_prepareFontLoadEvent(O,a,v){function g(I,j){return I.charCodeAt(j)<<24|I.charCodeAt(j+1)<<16|I.charCodeAt(j+2)<<8|255&I.charCodeAt(j+3)}function f(I,j,X,J){return I.substring(0,j)+J+I.substring(j+X)}let r,p;const n=this._document.createElement("canvas");n.width=1,n.height=1;const s=n.getContext("2d");let u=0;const d=`lt${Date.now()}${this.loadTestFontId++}`;let _=this._loadTestFont;_=f(_,976,d.length,d);const A=1482184792;let l=g(_,16);for(r=0,p=d.length-3;r<p;r+=4)l=l-A+g(d,r)|0;r<d.length&&(l=l-A+g(d+"XXX",r)|0),_=f(_,16,4,(0,y.string32)(l));const m=`url(data:font/opentype;base64,${btoa(_)});`;this.insertRule(`@font-face {font-family:"${d}";src:${m}}`);const M=[];for(const I of a)M.push(I.loadedName);M.push(d);const k=this._document.createElement("div");k.style.visibility="hidden",k.style.width=k.style.height="10px",k.style.position="absolute",k.style.top=k.style.left="0px";for(const I of M){const j=this._document.createElement("span");j.textContent="Hi",j.style.fontFamily=I,k.appendChild(j)}this._document.body.appendChild(k),function S(I,j){if(u++,u>30)return(0,y.warn)("Load test font never loaded."),void j();s.font="30px "+I,s.fillText(".",0,20),s.getImageData(0,0,1,1).data[3]>0?j():setTimeout(S.bind(null,I,j))}(d,()=>{k.remove(),v.complete()})}},L.FontFaceObject=class H{constructor(O,{isEvalSupported:a=!0,disableFontFace:v=!1,ignoreErrors:g=!1,onUnsupportedFeature:f,fontRegistry:r=null}){this.compiledGlyphs=Object.create(null);for(const p in O)this[p]=O[p];this.isEvalSupported=!1!==a,this.disableFontFace=!0===v,this.ignoreErrors=!0===g,this._onUnsupportedFeature=f,this.fontRegistry=r}createNativeFontFace(){if(!this.data||this.disableFontFace)return null;let O;if(this.cssFontInfo){const a={weight:this.cssFontInfo.fontWeight};this.cssFontInfo.italicAngle&&(a.style=`oblique ${this.cssFontInfo.italicAngle}deg`),O=new FontFace(this.cssFontInfo.fontFamily,this.data,a)}else O=new FontFace(this.loadedName,this.data,{});return this.fontRegistry&&this.fontRegistry.registerFont(this),O}createFontFaceRule(){if(!this.data||this.disableFontFace)return null;const O=(0,y.bytesToString)(this.data),a=`url(data:${this.mimetype};base64,${btoa(O)});`;let v;if(this.cssFontInfo){let g=`font-weight: ${this.cssFontInfo.fontWeight};`;this.cssFontInfo.italicAngle&&(g+=`font-style: oblique ${this.cssFontInfo.italicAngle}deg;`),v=`@font-face {font-family:"${this.cssFontInfo.fontFamily}";${g}src:${a}}`}else v=`@font-face {font-family:"${this.loadedName}";src:${a}}`;return this.fontRegistry&&this.fontRegistry.registerFont(this,a),v}getPathGenerator(O,a){if(void 0!==this.compiledGlyphs[a])return this.compiledGlyphs[a];let v;try{v=O.get(this.loadedName+"_path_"+a)}catch(g){if(!this.ignoreErrors)throw g;return this._onUnsupportedFeature({featureId:y.UNSUPPORTED_FEATURES.errorFontGetPath}),(0,y.warn)(`getPathGenerator - ignoring character: "${g}".`),this.compiledGlyphs[a]=function(f,r){}}if(this.isEvalSupported&&y.FeatureTest.isEvalSupported){const g=[];for(const f of v){const r=void 0!==f.args?f.args.join(","):"";g.push("c.",f.cmd,"(",r,");\n")}return this.compiledGlyphs[a]=new Function("c","size",g.join(""))}return this.compiledGlyphs[a]=function(g,f){for(const r of v)"scale"===r.cmd&&(r.args=[f,-f]),g[r.cmd].apply(g,r.args)}}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.AnnotationStorage=void 0;var y=ne(9),oe=ne(1);L.AnnotationStorage=class G{constructor(){this._storage=new Map,this._modified=!1,this.onSetModified=null,this.onResetModified=null}getValue(W,O){const a=this._storage.get(W);return void 0===a?O:Object.assign(O,a)}getRawValue(W){return this._storage.get(W)}setValue(W,O){const a=this._storage.get(W);let v=!1;if(void 0!==a)for(const[g,f]of Object.entries(O))a[g]!==f&&(v=!0,a[g]=f);else v=!0,this._storage.set(W,O);v&&this._setModified()}getAll(){return this._storage.size>0?(0,oe.objectFromMap)(this._storage):null}get size(){return this._storage.size}_setModified(){this._modified||(this._modified=!0,"function"==typeof this.onSetModified&&this.onSetModified())}resetModified(){this._modified&&(this._modified=!1,"function"==typeof this.onResetModified&&this.onResetModified())}get serializable(){return this._storage.size>0?this._storage:null}get hash(){const W=new y.MurmurHash3_64;
1for(const[O,a]of this._storage)W.update(`${O}:${JSON.stringify(a)}`);return W.hexdigest()}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.MurmurHash3_64=void 0;var y=ne(1);const oe=3285377520,G=4294901760,H=65535;L.MurmurHash3_64=class W{constructor(a){this.h1=a?4294967295&a:oe,this.h2=a?4294967295&a:oe}update(a){let v,g;if("string"==typeof a){v=new Uint8Array(2*a.length),g=0;for(let A=0,l=a.length;A<l;A++){const m=a.charCodeAt(A);m<=255?v[g++]=m:(v[g++]=m>>>8,v[g++]=255&m)}}else{if(!(0,y.isArrayBuffer)(a))throw new Error("Wrong data format in MurmurHash3_64_update. Input must be a string or array.");v=a.slice(),g=v.byteLength}const f=g>>2,r=g-4*f,p=new Uint32Array(v.buffer,0,f);let n=0,s=0,u=this.h1,S=this.h2;const d=3432918353,_=461845907,t=d&H,i=_&H;for(let A=0;A<f;A++)1&A?(n=p[A],n=n*d&G|n*t&H,n=n<<15|n>>>17,n=n*_&G|n*i&H,u^=n,u=u<<13|u>>>19,u=5*u+3864292196):(s=p[A],s=s*d&G|s*t&H,s=s<<15|s>>>17,s=s*_&G|s*i&H,S^=s,S=S<<13|S>>>19,S=5*S+3864292196);switch(n=0,r){case 3:n^=v[4*f+2]<<16;case 2:n^=v[4*f+1]<<8;case 1:n^=v[4*f],n=n*d&G|n*t&H,n=n<<15|n>>>17,n=n*_&G|n*i&H,1&f?u^=n:S^=n}this.h1=u,this.h2=S}hexdigest(){let a=this.h1,v=this.h2;a^=v>>>1,a=3981806797*a&G|36045*a&H,v=4283543511*v&G|(2950163797*(v<<16|a>>>16)&G)>>>16,a^=v>>>1,a=444984403*a&G|60499*a&H,v=3301882366*v&G|(3120437893*(v<<16|a>>>16)&G)>>>16,a^=v>>>1;const g=(a>>>0).toString(16),f=(v>>>0).toString(16);return g.padStart(8,"0")+f.padStart(8,"0")}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.CanvasGraphics=void 0;var y=ne(1),oe=ne(11),G=ne(12),H=ne(3),W=ne(5);const v=4096,n=16;function S(T){if(T._transformStack&&(T._transformStack=[]),!T.mozCurrentTransform){T._originalSave=T.save,T._originalRestore=T.restore,T._originalRotate=T.rotate,T._originalScale=T.scale,T._originalTranslate=T.translate,T._originalTransform=T.transform,T._originalSetTransform=T.setTransform,T._originalResetTransform=T.resetTransform,T._transformMatrix=T._transformMatrix||[1,0,0,1,0,0],T._transformStack=[];try{const o=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(T),"lineWidth");T._setLineWidth=o.set,T._getLineWidth=o.get,Object.defineProperty(T,"lineWidth",{set:function(e){this._setLineWidth(1.000001*e)},get:function(){return this._getLineWidth()}})}catch{}Object.defineProperty(T,"mozCurrentTransform",{get:function(){return this._transformMatrix}}),Object.defineProperty(T,"mozCurrentTransformInverse",{get:function(){const[h,e,c,b,w,C]=this._transformMatrix,E=h*b-e*c,B=e*c-h*b;return[b/E,e/B,c/B,h/E,(b*w-c*C)/B,(e*w-h*C)/E]}}),T.save=function(){const h=this._transformMatrix;this._transformStack.push(h),this._transformMatrix=h.slice(0,6),this._originalSave()},T.restore=function(){0===this._transformStack.length&&(0,y.warn)("Tried to restore a ctx when the stack was already empty.");const h=this._transformStack.pop();h&&(this._transformMatrix=h,this._originalRestore())},T.translate=function(h,e){const c=this._transformMatrix;c[4]=c[0]*h+c[2]*e+c[4],c[5]=c[1]*h+c[3]*e+c[5],this._originalTranslate(h,e)},T.scale=function(h,e){const c=this._transformMatrix;c[0]*=h,c[1]*=h,c[2]*=e,c[3]*=e,this._originalScale(h,e)},T.transform=function(h,e,c,b,w,C){const E=this._transformMatrix;this._transformMatrix=[E[0]*h+E[2]*e,E[1]*h+E[3]*e,E[0]*c+E[2]*b,E[1]*c+E[3]*b,E[0]*w+E[2]*C+E[4],E[1]*w+E[3]*C+E[5]],T._originalTransform(h,e,c,b,w,C)},T.setTransform=function(h,e,c,b,w,C){this._transformMatrix=[h,e,c,b,w,C],T._originalSetTransform(h,e,c,b,w,C)},T.resetTransform=function(){this._transformMatrix=[1,0,0,1,0,0],T._originalResetTransform()},T.rotate=function(h){const e=Math.cos(h),c=Math.sin(h),b=this._transformMatrix;this._transformMatrix=[b[0]*e+b[2]*c,b[1]*e+b[3]*c,b[0]*-c+b[2]*e,b[1]*-c+b[3]*e,b[4],b[5]],this._originalRotate(h)}}}class d{constructor(o){this.canvasFactory=o,this.cache=Object.create(null)}getCanvas(o,h,e,c){let b;return void 0!==this.cache[o]?(b=this.cache[o],this.canvasFactory.reset(b,h,e),b.context.setTransform(1,0,0,1,0,0)):(b=this.canvasFactory.create(h,e),this.cache[o]=b),c&&S(b.context),b}delete(o){delete this.cache[o]}clear(){for(const o in this.cache)this.canvasFactory.destroy(this.cache[o]),delete this.cache[o]}}
vendor: 27,139 bytes, line 1
1function _(T,o,h,e,c,b,w,C,E,B){const[U,V,z,Y,ee,ce]=T.mozCurrentTransform;if(0===V&&0===z){const ie=Math.round(w*U+ee),D=Math.round(C*Y+ce),pe=Math.abs(Math.round((w+E)*U+ee)-ie)||1,he=Math.abs(Math.round((C+B)*Y+ce)-D)||1;return T.setTransform(Math.sign(U),0,0,Math.sign(Y),ie,D),T.drawImage(o,h,e,c,b,0,0,pe,he),T.setTransform(U,V,z,Y,ee,ce),[pe,he]}if(0===U&&0===Y){const ie=Math.round(C*z+ee),D=Math.round(w*V+ce),pe=Math.abs(Math.round((C+B)*z+ee)-ie)||1,he=Math.abs(Math.round((w+E)*V+ce)-D)||1;return T.setTransform(0,Math.sign(V),Math.sign(z),0,ie,D),T.drawImage(o,h,e,c,b,0,0,he,pe),T.setTransform(U,V,z,Y,ee,ce),[he,pe]}return T.drawImage(o,h,e,c,b,w,C,E,B),[Math.hypot(U,V)*E,Math.hypot(z,Y)*B]}class i{constructor(o,h){this.alphaIsShape=!1,this.fontSize=0,this.fontSizeScale=1,this.textMatrix=y.IDENTITY_MATRIX,this.textMatrixScale=1,this.fontMatrix=y.FONT_IDENTITY_MATRIX,this.leading=0,this.x=0,this.y=0,this.lineX=0,this.lineY=0,this.charSpacing=0,this.wordSpacing=0,this.textHScale=1,this.textRenderingMode=y.TextRenderingMode.FILL,this.textRise=0,this.fillColor="#000000",this.strokeColor="#000000",this.patternFill=!1,this.fillAlpha=1,this.strokeAlpha=1,this.lineWidth=1,this.activeSMask=null,this.transferMaps=null,this.startNewPathAndClipBox([0,0,o,h])}clone(){const o=Object.create(this);return o.clipBox=this.clipBox.slice(),o}setCurrentPoint(o,h){this.x=o,this.y=h}updatePathMinMax(o,h,e){[h,e]=y.Util.applyTransform([h,e],o),this.minX=Math.min(this.minX,h),this.minY=Math.min(this.minY,e),this.maxX=Math.max(this.maxX,h),this.maxY=Math.max(this.maxY,e)}updateRectMinMax(o,h){const e=y.Util.applyTransform(h,o),c=y.Util.applyTransform(h.slice(2),o);this.minX=Math.min(this.minX,e[0],c[0]),this.minY=Math.min(this.minY,e[1],c[1]),this.maxX=Math.max(this.maxX,e[0],c[0]),this.maxY=Math.max(this.maxY,e[1],c[1])}updateScalingPathMinMax(o,h){y.Util.scaleMinMax(o,h),this.minX=Math.min(this.minX,h[0]),this.maxX=Math.max(this.maxX,h[1]),this.minY=Math.min(this.minY,h[2]),this.maxY=Math.max(this.maxY,h[3])}updateCurvePathMinMax(o,h,e,c,b,w,C,E,B,U){const V=y.Util.bezierBoundingBox(h,e,c,b,w,C,E,B);if(U)return U[0]=Math.min(U[0],V[0],V[2]),U[1]=Math.max(U[1],V[0],V[2]),U[2]=Math.min(U[2],V[1],V[3]),void(U[3]=Math.max(U[3],V[1],V[3]));this.updateRectMinMax(o,V)}getPathBoundingBox(o=oe.PathType.FILL,h=null){const e=[this.minX,this.minY,this.maxX,this.maxY];if(o===oe.PathType.STROKE){h||(0,y.unreachable)("Stroke bounding box must include transform.");const c=y.Util.singularValueDecompose2dScale(h),b=c[0]*this.lineWidth/2,w=c[1]*this.lineWidth/2;e[0]-=b,e[1]-=w,e[2]+=b,e[3]+=w}return e}updateClipFromPath(){const o=y.Util.intersect(this.clipBox,this.getPathBoundingBox());this.startNewPathAndClipBox(o||[0,0,0,0])}isEmptyClip(){return this.minX===1/0}startNewPathAndClipBox(o){this.clipBox=o,this.minX=1/0,this.minY=1/0,this.maxX=0,this.maxY=0}getClippedPathBoundingBox(o=oe.PathType.FILL,h=null){return y.Util.intersect(this.clipBox,this.getPathBoundingBox(o,h))}}function A(T,o,h=null){if(typeof ImageData<"u"&&o instanceof ImageData)return void T.putImageData(o,0,0);const e=o.height,c=o.width,b=e%n,w=(e-b)/n,C=0===b?w:w+1,E=T.createImageData(c,n);let U,B=0;const V=o.data,z=E.data;let Y,ee,ce,be,Q,re,ie,P;if(h)switch(h.length){case 1:Q=h[0],re=h[0],ie=h[0],P=h[0];break;case 4:Q=h[0],re=h[1],ie=h[2],P=h[3]}if(o.kind===y.ImageKind.GRAYSCALE_1BPP){const D=V.byteLength,q=new Uint32Array(z.buffer,0,z.byteLength>>2),pe=q.length,de=c+7>>3;let he=4294967295,me=y.FeatureTest.isLittleEndian?4278190080:255;for(P&&255===P[0]&&0===P[255]&&([he,me]=[me,he]),Y=0;Y<C;Y++){for(ce=Y<w?n:b,U=0,ee=0;ee<ce;ee++){const _e=D-B;let Se=0;const Ce=_e>de?c:8*_e-7,Ee=-8&Ce;let Z=0,R=0;for(;Se<Ee;Se+=8)R=V[B++],q[U++]=128&R?he:me,q[U++]=64&R?he:me,q[U++]=32&R?he:me,q[U++]=16&R?he:me,q[U++]=8&R?he:me,q[U++]=4&R?he:me,q[U++]=2&R?he:me,q[U++]=1&R?he:me;for(;Se<Ce;Se++)0===Z&&(R=V[B++],Z=128),q[U++]=R&Z?he:me,Z>>=1}for(;U<pe;)q[U++]=0;T.putImageData(E,0,Y*n)}}else if(o.kind===y.ImageKind.RGBA_32BPP){const D=!!(Q||re||ie);for(ee=0,be=c*n*4,Y=0;Y<w;Y++){if(z.set(V.subarray(B,B+be)),B+=be,D)for(let q=0;q<be;q+=4)Q&&(z[q+0]=Q[z[q+0]]),re&&(z[q+1]=re[z[q+1]]),ie&&(z[q+2]=ie[z[q+2]]);T.putImageData(E,0,ee),ee+=n}if(Y<C){if(be=c*b*4,z.set(V.subarray(B,B+be)),D)for(let q=0;q<be;q+=4)Q&&(z[q+0]=Q[z[q+0]]),re&&(z[q+1]=re[z[q+1]]),ie&&(z[q+2]=ie[z[q+2]]);T.putImageData(E,0,ee)}}else{if(o.kind!==y.ImageKind.RGB_24BPP)throw new Error(`bad image kind: ${o.kind}`);{const D=!!(Q||re||ie);for(ce=n,be=c*ce,Y=0;Y<C;Y++){for(Y>=w&&(ce=b,be=c*ce),U=0,ee=be;ee--;)z[U++]=V[B++],z[U++]=V[B++],z[U++]=V[B++],z[U++]=255;if(D)for(let q=0;q<U;q+=4)Q&&(z[q+0]=Q[z[q+0]]),re&&(z[q+1]=re[z[q+1]]),ie&&(z[q+2]=ie[z[q+2]]);T.putImageData(E,0,Y*n)}}}}function l(T,o){if(o.bitmap)return void T.drawImage(o.bitmap,0,0);const h=o.height,e=o.width,c=h%n,b=(h-c)/n,w=0===c?b:b+1,C=T.createImageData(e,n);let E=0;const B=o.data,U=C.data;for(let V=0;V<w;V++){const z=V<b?n:c;({srcPos:E}=(0,G.applyMaskImageData)({src:B,srcPos:E,dest:U,width:e,height:z})),T.putImageData(C,0,V*n)}}function m(T,o){const h=["strokeStyle","fillStyle","fillRule","globalAlpha","lineWidth","lineCap","lineJoin","miterLimit","globalCompositeOperation","font"];for(let e=0,c=h.length;e<c;e++){const b=h[e];void 0!==T[b]&&(o[b]=T[b])}void 0!==T.setLineDash&&(o.setLineDash(T.getLineDash()),o.lineDashOffset=T.lineDashOffset)}function x(T,o){T.strokeStyle=T.fillStyle=o||"#000000",T.fillRule="nonzero",T.globalAlpha=1,T.lineWidth=1,T.lineCap="butt",T.lineJoin="miter",T.miterLimit=10,T.globalCompositeOperation="source-over",T.font="10px sans-serif",void 0!==T.setLineDash&&(T.setLineDash([]),T.lineDashOffset=0)}function M(T,o,h,e){const c=T.length;for(let b=3;b<c;b+=4){const w=T[b];if(0===w)T[b-3]=o,T[b-2]=h,T[b-1]=e;else if(w<255){const C=255-w;T[b-3]=T[b-3]*w+o*C>>8,T[b-2]=T[b-2]*w+h*C>>8,T[b-1]=T[b-1]*w+e*C>>8}}}function k(T,o,h){const e=T.length;for(let b=3;b<e;b+=4)o[b]=o[b]*(h?h[T[b]]:T[b])*.00392156862745098|0}function I(T,o,h){const e=T.length;for(let c=3;c<e;c+=4){const b=77*T[c-3]+152*T[c-2]+28*T[c-1];o[c]=h?o[c]*h[b>>8]>>8:o[c]*b>>16}}function J(T,o){const h=y.Util.singularValueDecompose2dScale(T);h[0]=Math.fround(h[0]),h[1]=Math.fround(h[1]);const e=Math.fround((globalThis.devicePixelRatio||1)*W.PixelsPerInch.PDF_TO_CSS_UNITS);return void 0!==o?o:h[0]<=e||h[1]<=e}const N=["butt","round","square"],$=["miter","round","bevel"],K={},te={};class se{constructor(o,h,e,c,b,w,C,E){this.ctx=o,this.current=new i(this.ctx.canvas.width,this.ctx.canvas.height),this.stateStack=[],this.pendingClip=null,this.pendingEOFill=!1,this.res=null,this.xobjs=null,this.commonObjs=h,this.objs=e,this.canvasFactory=c,this.imageLayer=b,this.groupStack=[],this.processingType3=null,this.baseTransform=null,this.baseTransformStack=[],this.groupLevel=0,this.smaskStack=[],this.smaskCounter=0,this.tempSMask=null,this.suspendedCtx=null,this.contentVisible=!0,this.markedContentStack=[],this.optionalContentConfig=w,this.cachedCanvases=new d(this.canvasFactory),this.cachedPatterns=new Map,this.annotationCanvasMap=C,this.viewportScale=1,this.outputScaleX=1,this.outputScaleY=1,this.backgroundColor=E?.background||null,this.foregroundColor=E?.foreground||null,o&&S(o),this._cachedScaleForStroking=null,this._cachedGetSinglePixelWidth=null,this._cachedBitmapsMap=new Map}getObject(o,h=null){return"string"==typeof o?o.startsWith("g_")?this.commonObjs.get(o):this.objs.get(o):h}beginDrawing({transform:o,viewport:h,transparency:e=!1,background:c=null}){const b=this.ctx.canvas.width,w=this.ctx.canvas.height,C=c||"#ffffff";if(this.ctx.save(),this.foregroundColor&&this.backgroundColor){this.ctx.fillStyle=this.foregroundColor;const E=this.foregroundColor=this.ctx.fillStyle;this.ctx.fillStyle=this.backgroundColor;const B=this.backgroundColor=this.ctx.fillStyle;let U=!0,V=C;if(this.ctx.fillStyle=C,V=this.ctx.fillStyle,U="string"==typeof V&&/^#[0-9A-Fa-f]{6}$/.test(V),"#000000"===E&&"#ffffff"===B||E===B||!U)this.foregroundColor=this.backgroundColor=null;else{const z=parseInt(V.slice(1),16),ee=(z&&65280)>>8,ce=z&&255,be=re=>(re/=255)<=.03928?re/12.92:((re+.055)/1.055)**2.4,Q=Math.round(.2126*be((z&&16711680)>>16)+.7152*be(ee)+.0722*be(ce));this.selectColor=(re,ie,P)=>{const D=.2126*be(re)+.7152*be(ie)+.0722*be(P);return Math.round(D)===Q?B:E}}}if(this.ctx.fillStyle=this.backgroundColor||C,this.ctx.fillRect(0,0,b,w),this.ctx.restore(),e){const E=this.cachedCanvases.getCanvas("transparent",b,w,!0);this.compositeCtx=this.ctx,this.transparentCanvas=E.canvas,this.ctx=E.context,this.ctx.save(),this.ctx.transform.apply(this.ctx,this.compositeCtx.mozCurrentTransform)}this.ctx.save(),x(this.ctx,this.foregroundColor),o&&(this.ctx.transform.apply(this.ctx,o),this.outputScaleX=o[0],this.outputScaleY=o[0]),this.ctx.transform.apply(this.ctx,h.transform),this.viewportScale=h.scale,this.baseTransform=this.ctx.mozCurrentTransform.slice(),this.imageLayer&&this.imageLayer.beginLayout()}executeOperatorList(o,h,e,c){const b=o.argsArray,w=o.fnArray;let C=h||0;const E=b.length;if(E===C)return C;const B=E-C>10&&"function"==typeof e,U=B?Date.now()+15:0;let V=0;const z=this.commonObjs,Y=this.objs;let ee;for(;;){if(void 0!==c&&C===c.nextBreakPoint)return c.breakIt(C,e),C;if(ee=w[C],ee!==y.OPS.dependency)this[ee].apply(this,b[C]);else for(const ce of b[C]){const be=ce.startsWith("g_")?z:Y;if(!be.has(ce))return be.get(ce,e),C}if(C++,C===E)return C;if(B&&++V>10){if(Date.now()>U)return e(),C;V=0}}}endDrawing(){for(;this.stateStack.length||this.inSMaskMode;)this.restore();this.ctx.restore(),this.transparentCanvas&&(this.ctx=this.compositeCtx,this.ctx.save(),this.ctx.setTransform(1,0,0,1,0,0),this.ctx.drawImage(this.transparentCanvas,0,0),this.ctx.restore(),this.transparentCanvas=null),this.cachedCanvases.clear(),this.cachedPatterns.clear();for(const o of this._cachedBitmapsMap.values()){for(const h of o.values())typeof HTMLCanvasElement<"u"&&h instanceof HTMLCanvasElement&&(h.width=h.height=0);o.clear()}this._cachedBitmapsMap.clear(),this.imageLayer&&this.imageLayer.endLayout()}_scaleImage(o,h){const e=o.width,c=o.height;let U,V,b=Math.max(Math.hypot(h[0],h[1]),1),w=Math.max(Math.hypot(h[2],h[3]),1),C=e,E=c,B="prescale1";for(;b>2&&C>1||w>2&&E>1;){let z=C,Y=E;b>2&&C>1&&(z=Math.ceil(C/2),b/=C/z),w>2&&E>1&&(Y=Math.ceil(E/2),w/=E/Y),U=this.cachedCanvases.getCanvas(B,z,Y,!1),V=U.context,V.clearRect(0,0,z,Y),V.drawImage(o,0,0,C,E,0,0,z,Y),o=U.canvas,C=z,E=Y,B="prescale1"===B?"prescale2":"prescale1"}return{img:o,paintWidth:C,paintHeight:E}}_createMaskCanvas(o){const h=this.ctx,{width:e,height:c}=o,b=this.current.fillColor,w=this.current.patternFill,C=h.mozCurrentTransform;let E,B,U,V;if((o.bitmap||o.data)&&o.count>1){const pe=o.bitmap||o.data.buffer,de=C.slice(0,4);B=JSON.stringify(w?de:[de,b]),E=this._cachedBitmapsMap.get(pe),E||(E=new Map,this._cachedBitmapsMap.set(pe,E));const he=E.get(B);if(he&&!w)return{canvas:he,offsetX:Math.round(Math.min(C[0],C[2])+C[4]),offsetY:Math.round(Math.min(C[1],C[3])+C[5])};U=he}U||(V=this.cachedCanvases.getCanvas("maskCanvas",e,c,!1),l(V.context,o));let z=y.Util.transform(C,[1/e,0,0,-1/c,0,0]);z=y.Util.transform(z,[1,0,0,1,0,-c]);const Y=y.Util.applyTransform([0,0],z),ee=y.Util.applyTransform([e,c],z),ce=y.Util.normalizeRect([Y[0],Y[1],ee[0],ee[1]]),be=Math.round(ce[2]-ce[0])||1,Q=Math.round(ce[3]-ce[1])||1,re=this.cachedCanvases.getCanvas("fillCanvas",be,Q,!0),ie=re.context,P=Math.min(Y[0],ee[0]),D=Math.min(Y[1],ee[1]);ie.translate(-P,-D),ie.transform.apply(ie,z),U||(U=this._scaleImage(V.canvas,ie.mozCurrentTransformInverse),U=U.img,E&&w&&E.set(B,U)),ie.imageSmoothingEnabled=J(ie.mozCurrentTransform,o.interpolate),_(ie,U,0,0,U.width,U.height,0,0,e,c),ie.globalCompositeOperation="source-in";const q=y.Util.transform(ie.mozCurrentTransformInverse,[1,0,0,1,-P,-D]);return ie.fillStyle=w?b.getPattern(h,this,q,oe.PathType.FILL):b,ie.fillRect(0,0,e,c),E&&!w&&(this.cachedCanvases.delete("fillCanvas"),E.set(B,re.canvas)),{canvas:re.canvas,offsetX:Math.round(P),offsetY:Math.round(D)}}setLineWidth(o){o!==this.current.lineWidth&&(this._cachedScaleForStroking=null),this.current.lineWidth=o,this.ctx.lineWidth=o}setLineCap(o){this.ctx.lineCap=N[o]}setLineJoin(o){this.ctx.lineJoin=$[o]}setMiterLimit(o){this.ctx.miterLimit=o}setDash(o,h){const e=this.ctx;void 0!==e.setLineDash&&(e.setLineDash(o),e.lineDashOffset=h)}setRenderingIntent(o){}setFlatness(o){}setGState(o){for(let h=0,e=o.length;h<e;h++){const c=o[h],w=c[1];switch(c[0]){case"LW":this.setLineWidth(w);break;case"LC":this.setLineCap(w);break;case"LJ":this.setLineJoin(w);break;case"ML":this.setMiterLimit(w);break;case"D":this.setDash(w[0],w[1]);break;case"RI":this.setRenderingIntent(w);break;case"FL":this.setFlatness(w);break;case"Font":this.setFont(w[0],w[1]);break;case"CA":this.current.strokeAlpha=c[1];break;case"ca":this.current.fillAlpha=c[1],this.ctx.globalAlpha=c[1];break;case"BM":this.ctx.globalCompositeOperation=w;break;case"SMask":this.current.activeSMask=w?this.tempSMask:null,this.tempSMask=null,this.checkSMaskState();break;case"TR":this.current.transferMaps=w}}}get inSMaskMode(){return!!this.suspendedCtx}checkSMaskState(){const o=this.inSMaskMode;this.current.activeSMask&&!o?this.beginSMaskMode():!this.current.activeSMask&&o&&this.endSMaskMode()}beginSMaskMode(){if(this.inSMaskMode)throw new Error("beginSMaskMode called while already in smask mode");const c=this.cachedCanvases.getCanvas("smaskGroupAt"+this.groupLevel,this.ctx.canvas.width,this.ctx.canvas.height,!0);this.suspendedCtx=this.ctx,this.ctx=c.context;const b=this.ctx;b.setTransform.apply(b,this.suspendedCtx.mozCurrentTransform),m(this.suspendedCtx,b),function u(T,o){if(T._removeMirroring)throw new Error("Context is already forwarding operations.");T.__originalSave=T.save,T.__originalRestore=T.restore,T.__originalRotate=T.rotate,T.__originalScale=T.scale,T.__originalTranslate=T.translate,T.__originalTransform=T.transform,T.__originalSetTransform=T.setTransform,T.__originalResetTransform=T.resetTransform,T.__originalClip=T.clip,T.__originalMoveTo=T.moveTo,T.__originalLineTo=T.lineTo,T.__originalBezierCurveTo=T.bezierCurveTo,T.__originalRect=T.rect,T.__originalClosePath=T.closePath,T.__originalBeginPath=T.beginPath,T._removeMirroring=()=>{T.save=T.__originalSave,T.restore=T.__originalRestore,T.rotate=T.__originalRotate,T.scale=T.__originalScale,T.translate=T.__originalTranslate,T.transform=T.__originalTransform,T.setTransform=T.__originalSetTransform,T.resetTransform=T.__originalResetTransform,T.clip=T.__originalClip,T.moveTo=T.__originalMoveTo,T.lineTo=T.__originalLineTo,T.bezierCurveTo=T.__originalBezierCurveTo,T.rect=T.__originalRect,T.closePath=T.__originalClosePath,T.beginPath=T.__originalBeginPath,delete T._removeMirroring},T.save=function(){o.save(),this.__originalSave()},T.restore=function(){o.restore(),this.__originalRestore()},T.translate=function(e,c){o.translate(e,c),this.__originalTranslate(e,c)},T.scale=function(e,c){o.scale(e,c),this.__originalScale(e,c)},T.transform=function(e,c,b,w,C,E){o.transform(e,c,b,w,C,E),this.__originalTransform(e,c,b,w,C,E)},T.setTransform=function(e,c,b,w,C,E){o.setTransform(e,c,b,w,C,E),this.__originalSetTransform(e,c,b,w,C,E)},T.resetTransform=function(){o.resetTransform(),this.__originalResetTransform()},T.rotate=function(e){o.rotate(e),this.__originalRotate(e)},T.clip=function(e){o.clip(e),this.__originalClip(e)},T.moveTo=function(h,e){o.moveTo(h,e),this.__originalMoveTo(h,e)},T.lineTo=function(h,e){o.lineTo(h,e),this.__originalLineTo(h,e)},T.bezierCurveTo=function(h,e,c,b,w,C){o.bezierCurveTo(h,e,c,b,w,C),this.__originalBezierCurveTo(h,e,c,b,w,C)},T.rect=function(h,e,c,b){o.rect(h,e,c,b),this.__originalRect(h,e,c,b)},T.closePath=function(){o.closePath(),this.__originalClosePath()},T.beginPath=function(){o.beginPath(),this.__originalBeginPath()}}(b,this.suspendedCtx),this.setGState([["BM","source-over"],["ca",1],["CA",1]])}endSMaskMode(){if(!this.inSMaskMode)throw new Error("endSMaskMode called while not in smask mode");this.ctx._removeMirroring(),m(this.ctx,this.suspendedCtx),this.ctx=this.suspendedCtx,this.suspendedCtx=null}compose(o){this.current.activeSMask&&(o?(o[0]=Math.floor(o[0]),o[1]=Math.floor(o[1]),o[2]=Math.ceil(o[2]),o[3]=Math.ceil(o[3])):o=[0,0,this.ctx.canvas.width,this.ctx.canvas.height],function X(T,o,h,e){const c=e[0],b=e[1],w=e[2]-c,C=e[3]-b;0===w||0===C||(function j(T,o,h,e,c,b,w,C,E,B,U){const V=!!b,z=V?b[0]:0,Y=V?b[1]:0,ee=V?b[2]:0;let ce;ce="Luminosity"===c?I:k;const Q=Math.min(e,Math.ceil(1048576/h));for(let re=0;re<e;re+=Q){const ie=Math.min(Q,e-re),P=T.getImageData(C-B,re+(E-U),h,ie),D=o.getImageData(C,re+E,h,ie);V&&M(P.data,z,Y,ee),ce(P.data,D.data,w),o.putImageData(D,C,re+E)}}(o.context,h,w,C,o.subtype,o.backdrop,o.transferMap,c,b,o.offsetX,o.offsetY),T.save(),T.globalAlpha=1,T.globalCompositeOperation="source-over",T.setTransform(1,0,0,1,0,0),T.drawImage(h.canvas,0,0),T.restore())}(this.suspendedCtx,this.current.activeSMask,this.ctx,o),this.ctx.save(),this.ctx.setTransform(1,0,0,1,0,0),this.ctx.clearRect(0,0,this.ctx.canvas.width,this.ctx.canvas.height),this.ctx.restore())}save(){this.inSMaskMode?(m(this.ctx,this.suspendedCtx),this.suspendedCtx.save()):this.ctx.save();const o=this.current;this.stateStack.push(o),this.current=o.clone()}restore(){0===this.stateStack.length&&this.inSMaskMode&&this.endSMaskMode(),0!==this.stateStack.length&&(this.current=this.stateStack.pop(),this.inSMaskMode?(this.suspendedCtx.restore(),m(this.suspendedCtx,this.ctx)):this.ctx.restore(),this.checkSMaskState(),this.pendingClip=null,this._cachedScaleForStroking=null,this._cachedGetSinglePixelWidth=null)}transform(o,h,e,c,b,w){this.ctx.transform(o,h,e,c,b,w),this._cachedScaleForStroking=null,this._cachedGetSinglePixelWidth=null}constructPath(o,h,e){const c=this.ctx,b=this.current;let E,B,w=b.x,C=b.y;const U=c.mozCurrentTransform,V=0===U[0]&&0===U[3]||0===U[1]&&0===U[2],z=V?e.slice(0):null;for(let Y=0,ee=0,ce=o.length;Y<ce;Y++)switch(0|o[Y]){case y.OPS.rectangle:w=h[ee++],C=h[ee++];const be=h[ee++],Q=h[ee++],re=w+be,ie=C+Q;c.moveTo(w,C),0===be||0===Q?c.lineTo(re,ie):(c.lineTo(re,C),c.lineTo(re,ie),c.lineTo(w,ie)),V||b.updateRectMinMax(U,[w,C,re,ie]),c.closePath();break;case y.OPS.moveTo:w=h[ee++],C=h[ee++],c.moveTo(w,C),V||b.updatePathMinMax(U,w,C);break;case y.OPS.lineTo:w=h[ee++],C=h[ee++],c.lineTo(w,C),V||b.updatePathMinMax(U,w,C);break;case y.OPS.curveTo:E=w,B=C,w=h[ee+4],C=h[ee+5],c.bezierCurveTo(h[ee],h[ee+1],h[ee+2],h[ee+3],w,C),b.updateCurvePathMinMax(U,E,B,h[ee],h[ee+1],h[ee+2],h[ee+3],w,C,z),ee+=6;break;case y.OPS.curveTo2:E=w,B=C,c.bezierCurveTo(w,C,h[ee],h[ee+1],h[ee+2],h[ee+3]),b.updateCurvePathMinMax(U,E,B,w,C,h[ee],h[ee+1],h[ee+2],h[ee+3],z),w=h[ee+2],C=h[ee+3],ee+=4;break;case y.OPS.curveTo3:E=w,B=C,w=h[ee+2],C=h[ee+3],c.bezierCurveTo(h[ee],h[ee+1],w,C,w,C),b.updateCurvePathMinMax(U,E,B,h[ee],h[ee+1],w,C,w,C,z),ee+=4;break;case y.OPS.closePath:c.closePath()}V&&b.updateScalingPathMinMax(U,z),b.setCurrentPoint(w,C)}closePath(){this.ctx.closePath()}stroke(o){o=!(typeof o<"u")||o;const h=this.ctx,e=this.current.strokeColor;h.globalAlpha=this.current.strokeAlpha,this.contentVisible&&("object"==typeof e&&e?.getPattern?(h.save(),h.strokeStyle=e.getPattern(h,this,h.mozCurrentTransformInverse,oe.PathType.STROKE),this.rescaleAndStroke(!1),h.restore()):this.rescaleAndStroke(!0)),o&&this.consumePath(this.current.getClippedPathBoundingBox()),h.globalAlpha=this.current.fillAlpha}closeStroke(){this.closePath(),this.stroke()}fill(o){o=!(typeof o<"u")||o;const h=this.ctx,e=this.current.fillColor;let b=!1;this.current.patternFill&&(h.save(),h.fillStyle=e.getPattern(h,this,h.mozCurrentTransformInverse,oe.PathType.FILL),b=!0);const w=this.current.getClippedPathBoundingBox();this.contentVisible&&null!==w&&(this.pendingEOFill?(h.fill("evenodd"),this.pendingEOFill=!1):h.fill()),b&&h.restore(),o&&this.consumePath(w)}eoFill(){this.pendingEOFill=!0,this.fill()}fillStroke(){this.fill(!1),this.stroke(!1),this.consumePath()}eoFillStroke(){this.pendingEOFill=!0,this.fillStroke()}closeFillStroke(){this.closePath(),this.fillStroke()}closeEOFillStroke(){this.pendingEOFill=!0,this.closePath(),this.fillStroke()}endPath(){this.consumePath()}clip(){this.pendingClip=K}eoClip(){this.pendingClip=te}beginText(){this.current.textMatrix=y.IDENTITY_MATRIX,this.current.textMatrixScale=1,this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0}endText(){const o=this.pendingTextPaths,h=this.ctx;if(void 0!==o){h.save(),h.beginPath();for(let e=0;e<o.length;e++){const c=o[e];h.setTransform.apply(h,c.transform),h.translate(c.x,c.y),c.addToPath(h,c.fontSize)}h.restore(),h.clip(),h.beginPath(),delete this.pendingTextPaths}else h.beginPath()}setCharSpacing(o){this.current.charSpacing=o}setWordSpacing(o){this.current.wordSpacing=o}setHScale(o){this.current.textHScale=o/100}setLeading(o){this.current.leading=-o}setFont(o,h){const e=this.commonObjs.get(o),c=this.current;if(!e)throw new Error(`Can't find font for ${o}`);if(c.fontMatrix=e.fontMatrix||y.FONT_IDENTITY_MATRIX,(0===c.fontMatrix[0]||0===c.fontMatrix[3])&&(0,y.warn)("Invalid font matrix for font "+o),h<0?(h=-h,c.fontDirection=-1):c.fontDirection=1,this.current.font=e,this.current.fontSize=h,e.isType3Font)return;let w="normal";e.black?w="900":e.bold&&(w="bold");const C=e.italic?"italic":"normal",E=`"${e.loadedName||"sans-serif"}", ${e.fallbackName}`;let B=h;h<16?B=16:h>100&&(B=100),this.current.fontSizeScale=h/B,this.ctx.font=`${C} ${w} ${B}px ${E}`}setTextRenderingMode(o){this.current.textRenderingMode=o}setTextRise(o){this.current.textRise=o}moveText(o,h){this.current.x=this.current.lineX+=o,this.current.y=this.current.lineY+=h}setLeadingMoveText(o,h){this.setLeading(-h),this.moveText(o,h)}setTextMatrix(o,h,e,c,b,w){this.current.textMatrix=[o,h,e,c,b,w],this.current.textMatrixScale=Math.hypot(o,h),this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0}nextLine(){this.moveText(0,this.current.leading)}paintChar(o,h,e,c){const b=this.ctx,w=this.current,C=w.font,E=w.textRenderingMode,B=w.fontSize/w.fontSizeScale,U=E&y.TextRenderingMode.FILL_STROKE_MASK,V=!!(E&y.TextRenderingMode.ADD_TO_PATH_FLAG),z=w.patternFill&&!C.missingFile;let Y;(C.disableFontFace||V||z)&&(Y=C.getPathGenerator(this.commonObjs,o)),C.disableFontFace||z?(b.save(),b.translate(h,e),b.beginPath(),Y(b,B),c&&b.setTransform.apply(b,c),(U===y.TextRenderingMode.FILL||U===y.TextRenderingMode.FILL_STROKE)&&b.fill(),(U===y.TextRenderingMode.STROKE||U===y.TextRenderingMode.FILL_STROKE)&&b.stroke(),b.restore()):((U===y.TextRenderingMode.FILL||U===y.TextRenderingMode.FILL_STROKE)&&b.fillText(o,h,e),(U===y.TextRenderingMode.STROKE||U===y.TextRenderingMode.FILL_STROKE)&&b.strokeText(o,h,e)),V&&(this.pendingTextPaths||(this.pendingTextPaths=[])).push({transform:b.mozCurrentTransform,x:h,y:e,fontSize:B,addToPath:Y})}get isFontSubpixelAAEnabled(){const{context:o}=this.cachedCanvases.getCanvas("isFontSubpixelAAEnabled",10,10,!1);o.scale(1.5,1),o.fillText("I",0,10);const h=o.getImageData(0,0,10,10).data;let e=!1;for(let c=3;c<h.length;c+=4)if(h[c]>0&&h[c]<255){e=!0;break}return(0,y.shadow)(this,"isFontSubpixelAAEnabled",e)}showText(o){const h=this.current,e=h.font;if(e.isType3Font)return this.showType3Text(o);const c=h.fontSize;if(0===c)return;const b=this.ctx,w=h.fontSizeScale,C=h.charSpacing,E=h.wordSpacing,B=h.fontDirection,U=h.textHScale*B,V=o.length,z=e.vertical,Y=z?1:-1,ee=e.defaultVMetrics,ce=c*h.fontMatrix[0],be=h.textRenderingMode===y.TextRenderingMode.FILL&&!e.disableFontFace&&!h.patternFill;let Q;if(b.save(),b.transform.apply(b,h.textMatrix),b.translate(h.x,h.y+h.textRise),b.scale(U,B>0?-1:1),h.patternFill){b.save();const q=h.fillColor.getPattern(b,this,b.mozCurrentTransformInverse,oe.PathType.FILL);Q=b.mozCurrentTransform,b.restore(),b.fillStyle=q}let re=h.lineWidth;const ie=h.textMatrixScale;if(0===ie||0===re){const q=h.textRenderingMode&y.TextRenderingMode.FILL_STROKE_MASK;(q===y.TextRenderingMode.STROKE||q===y.TextRenderingMode.FILL_STROKE)&&(re=this.getSinglePixelWidth())}else re/=ie;1!==w&&(b.scale(w,w),re/=w),b.lineWidth=re;let D,P=0;for(D=0;D<V;++D){const q=o[D];if("number"==typeof q){P+=Y*q*c/1e3;continue}let pe=!1;const de=(q.isSpace?E:0)+C,he=q.fontChar,me=q.accent;let _e,Se,Ee,Ce=q.width;if(z){const Z=q.vmetric||ee,R=-(q.vmetric?Z[1]:.5*Ce)*ce;Ce=Z?-Z[0]:Ce,_e=R/w,Se=(P+Z[2]*ce)/w}else _e=P/w,Se=0;if(e.remeasure&&Ce>0){const Z=1e3*b.measureText(he).width/c*w;if(Ce<Z&&this.isFontSubpixelAAEnabled){const R=Ce/Z;pe=!0,b.save(),b.scale(R,1),_e/=R}else Ce!==Z&&(_e+=(Ce-Z)/2e3*c/w)}this.contentVisible&&(q.isInFont||e.missingFile)&&(be&&!me?b.fillText(he,_e,Se):(this.paintChar(he,_e,Se,Q),me&&this.paintChar(me.fontChar,_e+c*me.offset.x/w,Se-c*me.offset.y/w,Q))),Ee=z?Ce*ce-de*B:Ce*ce+de*B,P+=Ee,pe&&b.restore()}z?h.y-=P:h.x+=P*U,b.restore(),this.compose()}showType3Text(o){const h=this.ctx,e=this.current,c=e.font,b=e.fontSize,w=e.fontDirection,C=c.vertical?1:-1,E=e.charSpacing,B=e.wordSpacing,U=e.textHScale*w,V=e.fontMatrix||y.FONT_IDENTITY_MATRIX,z=o.length;let ee,ce,be,Q;if(e.textRenderingMode!==y.TextRenderingMode.INVISIBLE&&0!==b){for(this._cachedScaleForStroking=null,this._cachedGetSinglePixelWidth=null,h.save(),h.transform.apply(h,e.textMatrix),h.translate(e.x,e.y),h.scale(U,w),ee=0;ee<z;++ee){if(ce=o[ee],"number"==typeof ce){Q=C*ce*b/1e3,this.ctx.translate(Q,0),e.x+=Q*U;continue}const re=(ce.isSpace?B:0)+E,ie=c.charProcOperatorList[ce.operatorListId];ie?(this.contentVisible&&(this.processingType3=ce,this.save(),h.scale(b,b),h.transform.apply(h,V),this.executeOperatorList(ie),this.restore()),be=y.Util.applyTransform([ce.width,0],V)[0]*b+re,h.translate(be,0),e.x+=be*U):(0,y.warn)(`Type3 character "${ce.operatorListId}" is not available.`)}h.restore(),this.processingType3=null}}setCharWidth(o,h){}setCharWidthAndBounds(o,h,e,c,b,w){this.ctx.rect(e,c,b-e,w-c),this.ctx.clip(),this.endPath()}getColorN_Pattern(o){let h;if("TilingPattern"===o[0]){const e=o[1],c=this.baseTransform||this.ctx.mozCurrentTransform.slice();h=new oe.TilingPattern(o,e,this.ctx,{createCanvasGraphics:w=>new se(w,this.commonObjs,this.objs,this.canvasFactory)},c)}else h=this._getPattern(o[1],o[2]);return h}setStrokeColorN(){this.current.strokeColor=this.getColorN_Pattern(arguments)}setFillColorN(){this.current.fillColor=this.getColorN_Pattern(arguments),this.current.patternFill=!0}setStrokeRGBColor(o,h,e){const c=this.selectColor?.(o,h,e)||y.Util.makeHexColor(o,h,e);this.ctx.strokeStyle=c,this.current.strokeColor=c}setFillRGBColor(o,h,e){const c=this.selectColor?.(o,h,e)||y.Util.makeHexColor(o,h,e);this.ctx.fillStyle=c,this.current.fillColor=c,this.current.patternFill=!1}_getPattern(o,h=null){let e;return this.cachedPatterns.has(o)?e=this.cachedPatterns.get(o):(e=(0,oe.getShadingPattern)(this.objs.get(o)),this.cachedPatterns.set(o,e)),h&&(e.matrix=h),e}shadingFill(o){if(!this.contentVisible)return;const h=this.ctx;this.save();const e=this._getPattern(o);h.fillStyle=e.getPattern(h,this,h.mozCurrentTransformInverse,oe.PathType.SHADING);const c=h.mozCurrentTransformInverse;if(c){const b=h.canvas,w=b.width,C=b.height,E=y.Util.applyTransform([0,0],c),B=y.Util.applyTransform([0,C],c
1),U=y.Util.applyTransform([w,0],c),V=y.Util.applyTransform([w,C],c),z=Math.min(E[0],B[0],U[0],V[0]),Y=Math.min(E[1],B[1],U[1],V[1]),ee=Math.max(E[0],B[0],U[0],V[0]),ce=Math.max(E[1],B[1],U[1],V[1]);this.ctx.fillRect(z,Y,ee-z,ce-Y)}else this.ctx.fillRect(-1e10,-1e10,2e10,2e10);this.compose(this.current.getClippedPathBoundingBox()),this.restore()}beginInlineImage(){(0,y.unreachable)("Should not call beginInlineImage")}beginImageData(){(0,y.unreachable)("Should not call beginImageData")}paintFormXObjectBegin(o,h){this.contentVisible&&(this.save(),this.baseTransformStack.push(this.baseTransform),Array.isArray(o)&&6===o.length&&this.transform.apply(this,o),this.baseTransform=this.ctx.mozCurrentTransform,h)&&(this.ctx.rect(h[0],h[1],h[2]-h[0],h[3]-h[1]),this.current.updateRectMinMax(this.ctx.mozCurrentTransform,h),this.clip(),this.endPath())}paintFormXObjectEnd(){!this.contentVisible||(this.restore(),this.baseTransform=this.baseTransformStack.pop())}beginGroup(o){if(!this.contentVisible)return;this.save(),this.inSMaskMode&&(this.endSMaskMode(),this.current.activeSMask=null);const h=this.ctx;o.isolated||(0,y.info)("TODO: Support non-isolated groups."),o.knockout&&(0,y.warn)("Knockout groups not supported.");const e=h.mozCurrentTransform;
vendor: 4,152 bytes, line 1
1if(o.matrix&&h.transform.apply(h,o.matrix),!o.bbox)throw new Error("Bounding box is required.");let c=y.Util.getAxialAlignedBoundingBox(o.bbox,h.mozCurrentTransform);c=y.Util.intersect(c,[0,0,h.canvas.width,h.canvas.height])||[0,0,0,0];const w=Math.floor(c[0]),C=Math.floor(c[1]);let E=Math.max(Math.ceil(c[2])-w,1),B=Math.max(Math.ceil(c[3])-C,1),U=1,V=1;E>v&&(U=E/v,E=v),B>v&&(V=B/v,B=v),this.current.startNewPathAndClipBox([0,0,E,B]);let z="groupAt"+this.groupLevel;o.smask&&(z+="_smask_"+this.smaskCounter++%2);const Y=this.cachedCanvases.getCanvas(z,E,B,!0),ee=Y.context;ee.scale(1/U,1/V),ee.translate(-w,-C),ee.transform.apply(ee,e),o.smask?this.smaskStack.push({canvas:Y.canvas,context:ee,offsetX:w,offsetY:C,scaleX:U,scaleY:V,subtype:o.smask.subtype,backdrop:o.smask.backdrop,transferMap:o.smask.transferMap||null,startTransformInverse:null}):(h.setTransform(1,0,0,1,0,0),h.translate(w,C),h.scale(U,V),h.save()),m(h,ee),this.ctx=ee,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(h),this.groupLevel++}endGroup(o){if(!this.contentVisible)return;this.groupLevel--;const h=this.ctx,e=this.groupStack.pop();if(this.ctx=e,this.ctx.imageSmoothingEnabled=!1,o.smask)this.tempSMask=this.smaskStack.pop(),this.restore();else{this.ctx.restore();const c=this.ctx.mozCurrentTransform;this.restore(),this.ctx.save(),this.ctx.setTransform.apply(this.ctx,c);const b=y.Util.getAxialAlignedBoundingBox([0,0,h.canvas.width,h.canvas.height],c);this.ctx.drawImage(h.canvas,0,0),this.ctx.restore(),this.compose(b)}}beginAnnotations(){this.save(),this.baseTransform&&this.ctx.setTransform.apply(this.ctx,this.baseTransform)}endAnnotations(){this.restore()}beginAnnotation(o,h,e,c,b){if(this.save(),Array.isArray(h)&&4===h.length){const w=h[2]-h[0],C=h[3]-h[1];if(b&&this.annotationCanvasMap){(e=e.slice())[4]-=h[0],e[5]-=h[1],(h=h.slice())[0]=h[1]=0,h[2]=w,h[3]=C;const[E,B]=y.Util.singularValueDecompose2dScale(this.ctx.mozCurrentTransform),{viewportScale:U}=this,V=Math.ceil(w*this.outputScaleX*U),z=Math.ceil(C*this.outputScaleY*U);this.annotationCanvas=this.canvasFactory.create(V,z);const{canvas:Y,context:ee}=this.annotationCanvas,ce=`var(--zoom-factor) * ${W.PixelsPerInch.PDF_TO_CSS_UNITS}`;Y.style.width=`calc(${w}px * ${ce})`,Y.style.height=`calc(${C}px * ${ce})`,this.annotationCanvasMap.set(o,Y),this.annotationCanvas.savedCtx=this.ctx,this.ctx=ee,this.ctx.setTransform(E,0,0,-B,0,C*B),S(this.ctx),x(this.ctx,this.foregroundColor)}else x(this.ctx,this.foregroundColor),this.ctx.rect(h[0],h[1],w,C),this.ctx.clip(),this.endPath()}this.current=new i(this.ctx.canvas.width,this.ctx.canvas.height),this.transform.apply(this,e),this.transform.apply(this,c)}endAnnotation(){this.annotationCanvas&&(this.ctx=this.annotationCanvas.savedCtx,delete this.annotationCanvas.savedCtx,delete this.annotationCanvas),this.restore()}paintImageMaskXObject(o){if(!this.contentVisible)return;const h=o.count;(o=this.getObject(o.data,o)).count=h;const e=this.ctx,c=this.processingType3;if(c&&(void 0===c.compiled&&(c.compiled=function t(T){const{width:o,height:h}=T;if(o>1e3||h>1e3)return null;const c=new Uint8Array([0,2,4,0,1,0,5,4,8,10,0,8,0,2,1,0]),b=o+1;let C,E,B,w=new Uint8Array(b*(h+1));const U=o+7&-8;let V=new Uint8Array(U*h),z=0;for(const ie of T.data){let P=128;for(;P>0;)V[z++]=ie&P?0:255,P>>=1}let Y=0;for(z=0,0!==V[z]&&(w[0]=1,++Y),E=1;E<o;E++)V[z]!==V[z+1]&&(w[E]=V[z]?2:1,++Y),z++;for(0!==V[z]&&(w[E]=2,++Y),C=1;C<h;C++){z=C*U,B=C*b,V[z-U]!==V[z]&&(w[B]=V[z]?1:8,++Y);let ie=(V[z]?4:0)+(V[z-U]?8:0);for(E=1;E<o;E++)ie=(ie>>2)+(V[z+1]?4:0)+(V[z-U+1]?8:0),c[ie]&&(w[B+E]=c[ie],++Y),z++;if(V[z-U]!==V[z]&&(w[B+E]=V[z]?2:4,++Y),Y>1e3)return null}for(z=U*(h-1),B=C*b,0!==V[z]&&(w[B]=8,++Y),E=1;E<o;E++)V[z]!==V[z+1]&&(w[B+E]=V[z]?4:8,++Y),z++;if(0!==V[z]&&(w[B+E]=4,++Y),Y>1e3)return null;const ee=new Int32Array([0,b,-1,0,-b,0,0,0,1]);let ce,be,Q;for(H.isNodeJS?be=[]:ce=new Path2D,C=0;Y&&C<=h;C++){let ie=C*b;const P=ie+o;for(;ie<P&&!w[ie];)ie++;if(ie===P)continue;ce?ce.moveTo(ie%b,C):Q=[ie%b,C];const D=ie;let q=w[ie];do{const pe=ee[q];do{ie+=pe}while(!w[ie]);const de=w[ie];5!==de&&10!==de?(q=de,w[ie]=0):(q=de&51*q>>4,w[ie]&=q>>
12|q<<2),ce?ce.lineTo(ie%b,ie/b|0):Q.push(ie%b,ie/b|0),w[ie]||--Y}while(D!==ie);ce||be.push(Q),--C}return V=null,w=null,function(ie){if(ie.save(),ie.scale(1/o,-1/h),ie.translate(0,-h),ce)ie.fill(ce);else{ie.beginPath();for(const P of be){ie.moveTo(P[0],P[1]);for(let D=2,q=P.length;D<q;D+=2)ie.lineTo(P[D],P[D+1])}ie.fill()}ie.beginPath(),ie.restore()}}(o)),c.compiled))return void c.compiled(e);const b=this._createMaskCanvas(o),w=b.canvas;e.save(),e.setTransform(1,0,0,1,0,0),e.drawImage(w,b.offsetX,b.offsetY),e.restore(),this.compose()}paintImageMaskXObjectRepeat(o,h,e=0,c=0,b,w){if(!this.contentVisible)return;o=this.getObject(o.data,o);const C=this.ctx;C.save();const E=C.mozCurrentTransform;C.transform(h,e,c,b,0,0);const B=this._createMaskCanvas(o);C.setTransform(1,0,0,1,0,0);for(let U=0,V=w.length;U<V;U+=2){const z=y.Util.transform(E,[h,e,c,b,w[U],w[U+1]]),[Y,ee]=y.Util.applyTransform([0,0],z);C.drawImage(B.canvas,Y,ee)}C.restore(),this.compose()}paintImageMaskXObjectGroup(o){if(!this.contentVisible)return;const h=this.ctx,e=this.current.fillColor,c=this.current.patternFill;for(let b=0,w=o.length;b<w;b++){const C=o[b],E=C.width,B=C.height,U=this.cachedCanvases.getCanvas("maskCanvas",E,B,!1),V=U.context;V.save(),l(V,C),V.globalCompositeOperation="source-in",V.fillStyle=c?e.getPattern(V,this,h.mozCurrentTransformInverse,oe.PathType.FILL):e,V.fillRect(0,0,E,B),V.restore(),h.save(),h.transform.apply(h,C.transform),h.scale(1,-1),_(h,U.canvas,0,0,E,B,0,-1,1,1),h.restore()}this.compose()}paintImageXObject(o){if(!this.contentVisible)return;const h=this.getObject(o);h?this.paintInlineImageXObject(h):(0,y.warn)("Dependent image isn't ready yet")}paintImageXObjectRepeat(o,h,e,c){if(!this.contentVisible)return;const b=this.getObject(o);if(!b)return void(0,y.warn)("Dependent image isn't ready yet");const w=b.width,C=b.height,E=[];for(let B=0,U=c.length;B<U;B+=2)E.push({transform:[h,0,0,e,c[B],c[B+1]],x:0,y:0,w,h:C});this.paintInlineImageXObjectGroup(b,E)}paintInlineImageXObject(o){if(!this.contentVisible)return;const h=o.width,e=o.height,c=this.ctx;let b;if(this.save(),c.scale(1/h,-1/e),"function"==typeof HTMLElement&&o instanceof HTMLElement||!o.data)b=o;else{const B=this.cachedCanvases.getCanvas("inlineImage",h,e,!1);A(B.context,o,this.current.transferMaps),b=B.canvas}const w=this._scaleImage(b,c.mozCurrentTransformInverse);c.imageSmoothingEnabled=J(c.mozCurrentTransform,o.interpolate);const[C,E]=_(c,w.img,0,0,w.paintWidth,w.paintHeight,0,-e,h,e);if(this.imageLayer){const B=this.getCanvasPosition(0,-e);this.imageLayer.appendImage({imgData:o,left:B[0],top:B[1],width:C,height:E})}this.compose(),this.restore()}
vendor: 16,869 bytes, line 1
1paintInlineImageXObjectGroup(o,h){if(!this.contentVisible)return;const e=this.ctx,c=o.width,b=o.height,w=this.cachedCanvases.getCanvas("inlineImage",c,b,!1);A(w.context,o,this.current.transferMaps);for(let E=0,B=h.length;E<B;E++){const U=h[E];if(e.save(),e.transform.apply(e,U.transform),e.scale(1,-1),_(e,w.canvas,U.x,U.y,U.w,U.h,0,-1,1,1),this.imageLayer){const V=this.getCanvasPosition(U.x,U.y);this.imageLayer.appendImage({imgData:o,left:V[0],top:V[1],width:c,height:b})}e.restore()}this.compose()}paintSolidColorImageMask(){!this.contentVisible||(this.ctx.fillRect(0,0,1,1),this.compose())}markPoint(o){}markPointProps(o,h){}beginMarkedContent(o){this.markedContentStack.push({visible:!0})}beginMarkedContentProps(o,h){this.markedContentStack.push("OC"===o?{visible:this.optionalContentConfig.isVisible(h)}:{visible:!0}),this.contentVisible=this.isContentVisible()}endMarkedContent(){this.markedContentStack.pop(),this.contentVisible=this.isContentVisible()}beginCompat(){}endCompat(){}consumePath(o){const h=this.current.isEmptyClip();this.pendingClip&&this.current.updateClipFromPath(),this.pendingClip||this.compose(o);const e=this.ctx;this.pendingClip&&(h||(this.pendingClip===te?e.clip("evenodd"):e.clip()),this.pendingClip=null),this.current.startNewPathAndClipBox(this.current.clipBox),e.beginPath()}getSinglePixelWidth(){if(!this._cachedGetSinglePixelWidth){const o=this.ctx.mozCurrentTransform;if(0===o[1]&&0===o[2])this._cachedGetSinglePixelWidth=1/Math.min(Math.abs(o[0]),Math.abs(o[3]));else{const h=Math.abs(o[0]*o[3]-o[2]*o[1]),e=Math.hypot(o[0],o[2]),c=Math.hypot(o[1],o[3]);this._cachedGetSinglePixelWidth=Math.max(e,c)/h}}return this._cachedGetSinglePixelWidth}getScaleForStroking(){if(!this._cachedScaleForStroking){const{lineWidth:o}=this.current,h=this.ctx.mozCurrentTransform;let e,c;if(0===h[1]&&0===h[2]){const b=Math.abs(h[0]),w=Math.abs(h[3]);if(0===o)e=1/b,c=1/w;else{const C=b*o,E=w*o;e=C<1?1/C:1,c=E<1?1/E:1}}else{const b=Math.abs(h[0]*h[3]-h[2]*h[1]),w=Math.hypot(h[0],h[1]),C=Math.hypot(h[2],h[3]);if(0===o)e=C/b,c=w/b;else{const E=o*b;e=C>E?C/E:1,c=w>E?w/E:1}}this._cachedScaleForStroking=[e,c]}return this._cachedScaleForStroking}rescaleAndStroke(o){const{ctx:h}=this,{lineWidth:e}=this.current,[c,b]=this.getScaleForStroking();if(h.lineWidth=e||1,1===c&&1===b)return void h.stroke();let w,C,E;o&&(w=h.mozCurrentTransform.slice(),C=h.getLineDash().slice(),E=h.lineDashOffset),h.scale(c,b);const B=Math.max(c,b);h.setLineDash(h.getLineDash().map(U=>U/B)),h.lineDashOffset/=B,h.stroke(),o&&(h.setTransform(...w),h.setLineDash(C),h.lineDashOffset=E)}getCanvasPosition(o,h){const e=this.ctx.mozCurrentTransform;return[e[0]*o+e[2]*h+e[4],e[1]*o+e[3]*h+e[5]]}isContentVisible(){for(let o=this.markedContentStack.length-1;o>=0;o--)if(!this.markedContentStack[o].visible)return!1;return!0}}L.CanvasGraphics=se;for(const T in y.OPS)void 0!==se.prototype[T]&&(se.prototype[y.OPS[T]]=se.prototype[T])},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.TilingPattern=L.PathType=void 0,L.getShadingPattern=function r(s){switch(s[0]){case"RadialAxial":return new O(s);case"Mesh":return new g(s);case"Dummy":return new f}throw new Error(`Unknown IR type: ${s[0]}`)};var y=ne(1),oe=ne(3);const G={FILL:"Fill",STROKE:"Stroke",SHADING:"Shading"};function H(s,u){if(!u||oe.isNodeJS)return;const S=u[2]-u[0],d=u[3]-u[1],_=new Path2D;_.rect(u[0],u[1],S,d),s.clip(_)}L.PathType=G;class W{constructor(){this.constructor===W&&(0,y.unreachable)("Cannot initialize BaseShadingPattern.")}getPattern(){(0,y.unreachable)("Abstract method `getPattern` called.")}}class O extends W{constructor(u){super(),this._type=u[1],this._bbox=u[2],this._colorStops=u[3],this._p0=u[4],this._p1=u[5],this._r0=u[6],this._r1=u[7],this.matrix=null}_createGradient(u){let S;"axial"===this._type?S=u.createLinearGradient(this._p0[0],this._p0[1],this._p1[0],this._p1[1]):"radial"===this._type&&(S=u.createRadialGradient(this._p0[0],this._p0[1],this._r0,this._p1[0],this._p1[1],this._r1));for(const d of this._colorStops)S.addColorStop(d[0],d[1]);return S}getPattern(u,S,d,_){let t;if(_===G.STROKE||_===G.FILL){const i=S.current.getClippedPathBoundingBox(_,u.mozCurrentTransform)||[0,0,0,0],A=Math.ceil(i[2]-i[0])||1,l=Math.ceil(i[3]-i[1])||1,m=S.cachedCanvases.getCanvas("pattern",A,l,!0),x=m.context;x.clearRect(0,0,x.canvas.width,x.canvas.height),x.beginPath(),x.rect(0,0,x.canvas.width,x.canvas.height),x.translate(-i[0],-i[1]),d=y.Util.transform(d,[1,0,0,1,i[0],i[1]]),x.transform.apply(x,S.baseTransform),this.matrix&&x.transform.apply(x,this.matrix),H(x,this._bbox),x.fillStyle=this._createGradient(x),x.fill(),t=u.createPattern(m.canvas,"no-repeat");const M=new DOMMatrix(d);try{t.setTransform(M)}catch(k){(0,y.warn)(`RadialAxialShadingPattern.getPattern: "${k?.message}".`)}}else H(u,this._bbox),t=this._createGradient(u);return t}}function a(s,u,S,d,_,t,i,A){const l=u.coords,m=u.colors,x=s.data,M=4*s.width;let k;l[S+1]>l[d+1]&&(k=S,S=d,d=k,k=t,t=i,i=k),l[d+1]>l[_+1]&&(k=d,d=_,_=k,k=i,i=A,A=k),l[S+1]>l[d+1]&&(k=S,S=d,d=k,k=t,t=i,i=k);const I=(l[S]+u.offsetX)*u.scaleX,j=(l[S+1]+u.offsetY)*u.scaleY,X=(l[d]+u.offsetX)*u.scaleX,J=(l[d+1]+u.offsetY)*u.scaleY,N=(l[_]+u.offsetX)*u.scaleX,$=(l[_+1]+u.offsetY)*u.scaleY;if(j>=$)return;const K=m[t],te=m[t+1],se=m[t+2],T=m[i],o=m[i+1],h=m[i+2],e=m[A],c=m[A+1],b=m[A+2],w=Math.round(j),C=Math.round($);let E,B,U,V,z,Y,ee,ce;for(let be=w;be<=C;be++){if(be<J){let D;D=be<j?0:(j-be)/(j-J),E=I-(I-X)*D,B=K-(K-T)*D,U=te-(te-o)*D,V=se-(se-h)*D}else{let D;D=be>$?1:J===$?0:(J-be)/(J-$),E=X-(X-N)*D,B=T-(T-e)*D,U=o-(o-c)*D,V=h-(h-b)*D}let Q;Q=be<j?0:be>$?1:(j-be)/(j-$),z=I-(I-N)*Q,Y=K-(K-e)*Q,ee=te-(te-c)*Q,ce=se-(se-b)*Q;const re=Math.round(Math.min(E,z)),ie=Math.round(Math.max(E,z));let P=M*be+4*re;for(let D=re;D<=ie;D++)Q=(E-D)/(E-z),Q<0?Q=0:Q>1&&(Q=1),x[P++]=B-(B-Y)*Q|0,x[P++]=U-(U-ee)*Q|0,x[P++]=V-(V-ce)*Q|0,x[P++]=255}}function v(s,u,S){const d=u.coords,_=u.colors;let t,i;switch(u.type){case"lattice":const A=u.verticesPerRow,l=Math.floor(d.length/A)-1,m=A-1;for(t=0;t<l;t++){let x=t*A;for(let M=0;M<m;M++,x++)a(s,S,d[x],d[x+1],d[x+A],_[x],_[x+1],_[x+A]),a(s,S,d[x+A+1],d[x+1],d[x+A],_[x+A+1],_[x+1],_[x+A])}break;case"triangles":for(t=0,i=d.length;t<i;t+=3)a(s,S,d[t],d[t+1],d[t+2],_[t],_[t+1],_[t+2]);break;default:throw new Error("illegal figure")}}class g extends W{constructor(u){super(),this._coords=u[2],this._colors=u[3],this._figures=u[4],this._bounds=u[5],this._bbox=u[7],this._background=u[8],this.matrix=null}_createMeshCanvas(u,S,d){const A=Math.floor(this._bounds[0]),l=Math.floor(this._bounds[1]),m=Math.ceil(this._bounds[2])-A,x=Math.ceil(this._bounds[3])-l,M=Math.min(Math.ceil(Math.abs(m*u[0]*1.1)),3e3),k=Math.min(Math.ceil(Math.abs(x*u[1]*1.1)),3e3),I=m/M,j=x/k,X={coords:this._coords,colors:this._colors,offsetX:-A,offsetY:-l,scaleX:1/I,scaleY:1/j},$=d.getCanvas("mesh",M+4,k+4,!1),K=$.context,te=K.createImageData(M,k);if(S){const T=te.data;for(let o=0,h=T.length;o<h;o+=4)T[o]=S[0],T[o+1]=S[1],T[o+2]=S[2],T[o+3]=255}for(const T of this._figures)v(te,T,X);return K.putImageData(te,2,2),{canvas:$.canvas,offsetX:A-2*I,offsetY:l-2*j,scaleX:I,scaleY:j}}getPattern(u,S,d,_){let t;if(H(u,this._bbox),_===G.SHADING)t=y.Util.singularValueDecompose2dScale(u.mozCurrentTransform);else if(t=y.Util.singularValueDecompose2dScale(S.baseTransform),this.matrix){const A=y.Util.singularValueDecompose2dScale(this.matrix);t=[t[0]*A[0],t[1]*A[1]]}const i=this._createMeshCanvas(t,_===G.SHADING?null:this._background,S.cachedCanvases);return _!==G.SHADING&&(u.setTransform.apply(u,S.baseTransform),this.matrix&&u.transform.apply(u,this.matrix)),u.translate(i.offsetX,i.offsetY),u.scale(i.scaleX,i.scaleY),u.createPattern(i.canvas,"no-repeat")}}class f extends W{getPattern(){return"hotpink"}}class n{static get MAX_PATTERN_SIZE(){return(0,y.shadow)(this,"MAX_PATTERN_SIZE",3e3)}constructor(u,S,d,_,t){this.operatorList=u[2],this.matrix=u[3]||[1,0,0,1,0,0],this.bbox=u[4],this.xstep=u[5],this.ystep=u[6],this.paintType=u[7],this.tilingType=u[8],this.color=S,this.ctx=d,this.canvasGraphicsFactory=_,this.baseTransform=t}createPatternCanvas(u){const S=this.operatorList,d=this.bbox,_=this.xstep,t=this.ystep,i=this.paintType,l=this.color,m=this.canvasGraphicsFactory;(0,y.info)("TilingType: "+this.tilingType);const x=d[0],M=d[1],k=d[2],I=d[3],j=y.Util.singularValueDecompose2dScale(this.matrix),X=y.Util.singularValueDecompose2dScale(this.baseTransform),J=[j[0]*X[0],j[1]*X[1]],N=this.getSizeAndScale(_,this.ctx.canvas.width,J[0]),$=this.getSizeAndScale(t,this.ctx.canvas.height,J[1]),K=u.cachedCanvases.getCanvas("pattern",N.size,$.size,!0),te=K.context,se=m.createCanvasGraphics(te);se.groupLevel=u.groupLevel,this.setFillAndStrokeStyleToContext(se,i,l);let T=x,o=M,h=k,e=I;return x<0&&(T=0,h+=Math.abs(x)),M<0&&(o=0,e+=Math.abs(M)),te.translate(-N.scale*T,-$.scale*o),se.transform(N.scale,0,0,$.scale,0,0),te.save(),this.clipBbox(se,T,o,h,e),se.baseTransform=se.ctx.mozCurrentTransform.slice(),se.executeOperatorList(S),se.endDrawing(),{canvas:K.canvas,scaleX:N.scale,scaleY:$.scale,offsetX:T,offsetY:o}}getSizeAndScale(u,S,d){u=Math.abs(u);const _=Math.max(n.MAX_PATTERN_SIZE,S);let t=Math.ceil(u*d);return t>=_?t=_:d=t/u,{scale:d,size:t}}clipBbox(u,S,d,_,t){u.ctx.rect(S,d,_-S,t-d),u.current.updateRectMinMax(u.ctx.mozCurrentTransform,[S,d,_,t]),u.clip(),u.endPath()}setFillAndStrokeStyleToContext(u,S,d){const _=u.ctx,t=u.current;switch(S){case 1:const i=this.ctx;_.fillStyle=i.fillStyle,_.strokeStyle=i.strokeStyle,t.fillColor=i.fillStyle,t.strokeColor=i.strokeStyle;break;case 2:const A=y.Util.makeHexColor(d[0],d[1],d[2]);_.fillStyle=A,_.strokeStyle=A,t.fillColor=A,t.strokeColor=A;break;default:throw new y.FormatError(`Unsupported paint type: ${S}`)}}getPattern(u,S,d,_){let t=d;_!==G.SHADING&&(t=y.Util.transform(t,S.baseTransform),this.matrix&&(t=y.Util.transform(t,this.matrix)));const i=this.createPatternCanvas(S);let A=new DOMMatrix(t);A=A.translate(i.offsetX,i.offsetY),A=A.scale(1/i.scaleX,1/i.scaleY);const l=u.createPattern(i.canvas,"repeat");try{l.setTransform(A)}catch(m){(0,y.warn)(`TilingPattern.getPattern: "${m?.message}".`)}return l}}L.TilingPattern=n},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.applyMaskImageData=function oe({src:G,srcPos:H=0,dest:W,destPos:O=0,width:a,height:v,inverseDecode:g=!1}){const f=y.FeatureTest.isLittleEndian?4278190080:255,[r,p]=g?[0,f]:[f,0],n=a>>3,s=7&a,u=G.length;W=new Uint32Array(W.buffer);for(let S=0;S<v;S++){for(const _=H+n;H<_;H++){const t=H<u?G[H]:255;W[O++]=128&t?p:r,W[O++]=64&t?p:r,W[O++]=32&t?p:r,W[O++]=16&t?p:r,W[O++]=8&t?p:r,W[O++]=4&t?p:r,W[O++]=2&t?p:r,W[O++]=1&t?p:r}if(0===s)continue;const d=H<u?G[H++]:255;for(let _=0;_<s;_++)W[O++]=d&1<<7-_?p:r}return{srcPos:H,destPos:O}};var y=ne(1)},(ue,L)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.GlobalWorkerOptions=void 0;const ne=Object.create(null);L.GlobalWorkerOptions=ne,ne.workerPort=void 0===ne.workerPort?null:ne.workerPort,ne.workerSrc=void 0===ne.workerSrc?"":ne.workerSrc},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.MessageHandler=void 0;var y=ne(1);function H(O){switch(O instanceof Error||"object"==typeof O&&null!==O||(0,y.unreachable)('wrapReason: Expected "reason" to be a (possibly cloned) Error.'),O.name){case"AbortException":return new y.AbortException(O.message);case"MissingPDFException":return new y.MissingPDFException(O.message);case"PasswordException":return new y.PasswordException(O.message,O.code);case"UnexpectedResponseException":return new y.UnexpectedResponseException(O.message,O.status);case"UnknownErrorException":return new y.UnknownErrorException(O.message,O.details);default:return new y.UnknownErrorException(O.message,O.toString())}}L.MessageHandler=class W{constructor(a,v,g){this.sourceName=a,this.targetName=v,this.comObj=g,this.callbackId=1,this.streamId=1,this.streamSinks=Object.create(null),this.streamControllers=Object.create(null),this.callbackCapabilities=Object.create(null),this.actionHandler=Object.create(null),this._onComObjOnMessage=f=>{const r=f.data;if(r.targetName!==this.sourceName)return;if(r.stream)return void this._processStreamMessage(r);if(r.callback){const n=r.callbackId,s=this.callbackCapabilities[n];if(!s)throw new Error(`Cannot resolve callback ${n}`);if(delete this.callbackCapabilities[n],1===r.callback)s.resolve(r.data);else{if(2!==r.callback)throw new Error("Unexpected callback case");s.reject(H(r.reason))}return}const p=this.actionHandler[r.action];if(!p)throw new Error(`Unknown action from worker: ${r.action}`);if(r.callbackId){const n=this.sourceName,s=r.sourceName;new Promise(function(u){u(p(r.data))}).then(function(u){g.postMessage({sourceName:n,targetName:s,callback:1,callbackId:r.callbackId,data:u})},function(u){g.postMessage({sourceName:n,targetName:s,callback:2,callbackId:r.callbackId,reason:H(u)})})}else r.streamId?this._createStreamSink(r):p(r.data)},g.addEventListener("message",this._onComObjOnMessage)}on(a,v){const g=this.actionHandler;if(g[a])throw new Error(`There is already an actionName called "${a}"`);g[a]=v}send(a,v,g){this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:a,data:v},g)}sendWithPromise(a,v,g){const f=this.callbackId++,r=(0,y.createPromiseCapability)();this.callbackCapabilities[f]=r;try{this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:a,callbackId:f,data:v},g)}catch(p){r.reject(p)}return r.promise}sendWithStream(a,v,g,f){const r=this.streamId++,p=this.sourceName,n=this.targetName,s=this.comObj;return new ReadableStream({start:u=>{const S=(0,y.createPromiseCapability)();return this.streamControllers[r]={controller:u,startCall:S,pullCall:null,cancelCall:null,isClosed:!1},s.postMessage({sourceName:p,targetName:n,action:a,streamId:r,data:v,desiredSize:u.desiredSize},f),S.promise},pull:u=>{const S=(0,y.createPromiseCapability)();return this.streamControllers[r].pullCall=S,s.postMessage({sourceName:p,targetName:n,stream:6,streamId:r,desiredSize:u.desiredSize}),S.promise},cancel:u=>{(0,y.assert)(u instanceof Error,"cancel must have a valid reason");const S=(0,y.createPromiseCapability)();return this.streamControllers[r].cancelCall=S,this.streamControllers[r].isClosed=!0,s.postMessage({sourceName:p,targetName:n,stream:1,streamId:r,reason:H(u)}),S.promise}},g)}_createStreamSink(a){const v=a.streamId,g=this.sourceName,f=a.sourceName,r=this.comObj,p=this,n=this.actionHandler[a.action],s={enqueue(u,S=1,d){if(this.isCancelled)return;const _=this.desiredSize;this.desiredSize-=S,_>0&&this.desiredSize<=0&&(this.sinkCapability=(0,y.createPromiseCapability)(),this.ready=this.sinkCapability.promise),r.postMessage({sourceName:g,targetName:f,stream:4,streamId:v,chunk:u},d)},close(){this.isCancelled||(this.isCancelled=!0,r.postMessage({sourceName:g,targetName:f,stream:3,streamId:v}),delete p.streamSinks[v])},error(u){(0,y.assert)(u instanceof Error,"error must have a valid reason"),!this.isCancelled&&(this.isCancelled=!0,r.postMessage({sourceName:g,targetName:f,stream:5,streamId:v,reason:H(u)}))},sinkCapability:(0,y.createPromiseCapability)(),onPull:null,onCancel:null,isCancelled:!1,desiredSize:a.desiredSize,ready:null};s.sinkCapability.resolve(),s.ready=s.sinkCapability.promise,this.streamSinks[v]=s,new Promise(function(u){u(n(a.data,s))}).then(function(){r.postMessage({sourceName:g,targetName:f,stream:8,streamId:v,success:!0})},function(u){r.postMessage({sourceName:g,targetName:f,stream:8,streamId:v,reason:H(u)})})}_processStreamMessage(a){const v=a.streamId,g=this.sourceName,f=a.sourceName,r=this.comObj,p=this.streamControllers[v],n=this.streamSinks[v];switch(a.stream){case 8:a.success?p.startCall.resolve():p.startCall.reject(H(a.reason));break;case 7:a.success?p.pullCall.resolve():p.pullCall.reject(H(a.reason));break;case 6:if(!n){r.postMessage({sourceName:g,targetName:f,stream:7,streamId:v,success:!0});break}n.desiredSize<=0&&a.desiredSize>0&&n.sinkCapability.resolve(),n.desiredSize=a.desiredSize,new Promise(function(s){s(n.onPull&&n.onPull())}).then(function(){r.postMessage({sourceName:g,targetName:f,stream:7,streamId:v,success:!0})},function(s){r.postMessage({sourceName:g,targetName:f,stream:7,streamId:v,reason:H(s)})});break;case 4:if((0,y.assert)(p,"enqueue should have stream controller"),p.isClosed)break;p.controller.enqueue(a.chunk);break;case 3:if((0,y.assert)(p,"close should have stream controller"),p.isClosed)break;p.isClosed=!0,p.controller.close(),this._deleteStreamController(p,v);break;case 5:(0,y.assert)(p,"error should have stream controller"),p.controller.error(H(a.reason)),this._deleteStreamController(p,v);break;case 2:a.success?p.cancelCall.resolve():p.cancelCall.reject(H(a.reason)),this._deleteStreamController(p,v);break;case 1:if(!n)break;new Promise(function(s){s(n.onCancel&&n.onCancel(H(a.reason)))}).then(function(){r.postMessage({sourceName:g,targetName:f,stream
1:2,streamId:v,success:!0})},function(s){r.postMessage({sourceName:g,targetName:f,stream:2,streamId:v,reason:H(s)})}),n.sinkCapability.reject(H(a.reason)),n.isCancelled=!0,delete this.streamSinks[v];break;default:throw new Error("Unexpected stream case")}}_deleteStreamController(a,v){var g=this;return _asyncToGenerator(function*(){yield Promise.allSettled([a.startCall&&a.startCall.promise,a.pullCall&&a.pullCall.promise,a.cancelCall&&a.cancelCall.promise]),delete g.streamControllers[v]})()}destroy(){this.comObj.removeEventListener("message",this._onComObjOnMessage)}}},(ue,L,ne)=>{var G,H;Object.defineProperty(L,"__esModule",{value:!0}),L.Metadata=void 0;var y=ne(1);G=new WeakMap,H=new WeakMap,L.Metadata=class oe{constructor({parsedData:O,rawData:a}){ve(this,G,void 0),ve(this,H,void 0),Te(this,G,O),Te(this,H,a)}getRaw(){return Ae(this,H)}get(O){return Ae(this,G).get(O)??null}getAll(){return(0,y.objectFromMap)(Ae(this,G))}has(O){return Ae(this,G).has(O)}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.OptionalContentConfig=void 0;var y=ne(1);class oe{constructor(W,O){this.visible=!0,this.name=W,this.intent=O}}L.OptionalContentConfig=class G{constructor(W){if(this.name=null,this.creator=null,this._order=null,this._groups=new Map,null!==W){this.name=W.name,this.creator=W.creator,this._order=W.order;for(const O of W.groups)this._groups.set(O.id,new oe(O.name,O.intent));if("OFF"===W.baseState)for(const O of this._groups)O.visible=!1;for(const O of W.on)this._groups.get(O).visible=!0;for(const O of W.off)this._groups.get(O).visible=!1}}_evaluateVisibilityExpression(W){const O=W.length;if(O<2)return!0;const a=W[0];for(let v=1;v<O;v++){const g=W[v];let f;if(Array.isArray(g))f=this._evaluateVisibilityExpression(g);else{if(!this._groups.has(g))return(0,y.warn)(`Optional content group not found: ${g}`),!0;f=this._groups.get(g).visible}switch(a){case"And":if(!f)return!1;break;case"Or":if(f)return!0;break;case"Not":return!f;default:return!0}}return"And"===a}isVisible(W){if(0===this._groups.size)return!0;if(!W)return(0,y.warn)("Optional content group not defined."),!0;if("OCG"===W.type)return this._groups.has(W.id)?this._groups.get(W.id).visible:((0,y.warn)(`Optional content group not found: ${W.id}`),!0);if("OCMD"===W.type){if(W.expression)return this._evaluateVisibilityExpression(W.expression);if(!W.policy||"AnyOn"===W.policy){for(const O of W.ids){if(!this._groups.has(O))return(0,y.warn)(`Optional content group not found: ${O}`),!0;if(this._groups.get(O).visible)return!0}return!1}if("AllOn"===W.policy){for(const O of W.ids){if(!this._groups.has(O))return(0,y.warn)(`Optional content group not found: ${O}`),!0;if(!this._groups.get(O).visible)return!1}return!0}if("AnyOff"===W.policy){for(const O of W.ids){if(!this._groups.has(O))return(0,y.warn)(`Optional content group not found: ${O}`),!0;if(!this._groups.get(O).visible)return!0}return!1}if("AllOff"===W.policy){for(const O of W.ids){if(!this._groups.has(O))return(0,y.warn)(`Optional content group not found: ${O}`),!0;if(this._groups.get(O).visible)return!1}return!0}return(0,y.warn)(`Unknown optional content policy ${W.policy}.`),!0}return(0,y.warn)(`Unknown group type ${W.type}.`),!0}setVisibility(W,O=!0){this._groups.has(W)?this._groups.get(W).visible=!!O:(0,y.warn)(`Optional content group not found: ${W}`)}getOrder(){return this._groups.size?this._order?this._order.slice():Array.from(this._groups.keys()):null}getGroups(){return this._groups.size>0?(0,y.objectFromMap)(this._groups):null}getGroup(W){return this._groups.get(W)||null}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.PDFDataTransportStream=void 0;var y=ne(1),oe=ne(5);L.PDFDataTransportStream=class G{constructor(a,v){(0,y.assert)(v,'PDFDataTransportStream - missing required "pdfDataRangeTransport" argument.'),this._queuedChunks=[],this._progressiveDone=a.progressiveDone||!1,this._contentDispositionFilename=a.contentDispositionFilename||null;const g=a.initialData;if(g?.length>0){const f=new Uint8Array(g).buffer;this._queuedChunks.push(f)}this._pdfDataRangeTransport=v,this._isStreamingSupported=!a.disableStream,this._isRangeSupported=!a.disableRange,this._contentLength=a.length,this._fullRequestReader=null,this._rangeReaders=[],this._pdfDataRangeTransport.addRangeListener((f,r)=>{this._onReceiveData({begin:f,chunk:r})}),this._pdfDataRangeTransport.addProgressListener((f,r)=>{this._onProgress({loaded:f,total:r})}),this._pdfDataRangeTransport.addProgressiveReadListener(f=>{this._onReceiveData({chunk:f})}),this._pdfDataRangeTransport.addProgressiveDoneListener(()=>{this._onProgressiveDone()}),this._pdfDataRangeTransport.transportReady()}_onReceiveData(a){const v=new Uint8Array(a.chunk).buffer;if(void 0===a.begin)this._fullRequestReader?this._fullRequestReader._enqueue(v):this._queuedChunks.push(v);else{const g=this._rangeReaders.some(function(f){return f._begin===a.begin&&(f._enqueue(v),!0)});(0,y.assert)(g,"_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found.")}}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}
vendor: 5,253 bytes, line 1
1_onProgress(a){if(void 0===a.total){const v=this._rangeReaders[0];v?.onProgress&&v.onProgress({loaded:a.loaded})}else{const v=this._fullRequestReader;v?.onProgress&&v.onProgress({loaded:a.loaded,total:a.total})}}_onProgressiveDone(){this._fullRequestReader&&this._fullRequestReader.progressiveDone(),this._progressiveDone=!0}_removeRangeReader(a){const v=this._rangeReaders.indexOf(a);v>=0&&this._rangeReaders.splice(v,1)}getFullReader(){(0,y.assert)(!this._fullRequestReader,"PDFDataTransportStream.getFullReader can only be called once.");const a=this._queuedChunks;return this._queuedChunks=null,new H(this,a,this._progressiveDone,this._contentDispositionFilename)}getRangeReader(a,v){if(v<=this._progressiveDataLength)return null;const g=new W(this,a,v);return this._pdfDataRangeTransport.requestDataRange(a,v),this._rangeReaders.push(g),g}cancelAllRequests(a){this._fullRequestReader&&this._fullRequestReader.cancel(a);for(const v of this._rangeReaders.slice(0))v.cancel(a);this._pdfDataRangeTransport.abort()}};class H{constructor(a,v,g=!1,f=null){this._stream=a,this._done=g||!1,this._filename=(0,oe.isPdfFile)(f)?f:null,this._queuedChunks=v||[],this._loaded=0;for(const r of this._queuedChunks)this._loaded+=r.byteLength;this._requests=[],this._headersReady=Promise.resolve(),a._fullRequestReader=this,this.onProgress=null}_enqueue(a){this._done||(this._requests.length>0?this._requests.shift().resolve({value:a,done:!1}):this._queuedChunks.push(a),this._loaded+=a.byteLength)}get headersReady(){return this._headersReady}get filename(){return this._filename}get isRangeSupported(){return this._stream._isRangeSupported}get isStreamingSupported(){return this._stream._isStreamingSupported}get contentLength(){return this._stream._contentLength}read(){var a=this;return _asyncToGenerator(function*(){if(a._queuedChunks.length>0)return{value:a._queuedChunks.shift(),done:!1};if(a._done)return{value:void 0,done:!0};const v=(0,y.createPromiseCapability)();return a._requests.push(v),v.promise})()}cancel(a){this._done=!0;for(const v of this._requests)v.resolve({value:void 0,done:!0});this._requests.length=0}progressiveDone(){this._done||(this._done=!0)}}class W{constructor(a,v,g){this._stream=a,this._begin=v,this._end=g,this._queuedChunk=null,this._requests=[],this._done=!1,this.onProgress=null}_enqueue(a){if(!this._done){if(0===this._requests.length)this._queuedChunk=a;else{this._requests.shift().resolve({value:a,done:!1});for(const g of this._requests)g.resolve({value:void 0,done:!0});this._requests.length=0}this._done=!0,this._stream._removeRangeReader(this)}}get isStreamingSupported(){return!1}read(){var a=this;return _asyncToGenerator(function*(){if(a._queuedChunk){const g=a._queuedChunk;return a._queuedChunk=null,{value:g,done:!1}}if(a._done)return{value:void 0,done:!0};const v=(0,y.createPromiseCapability)();return a._requests.push(v),v.promise})()}cancel(a){this._done=!0;for(const v of this._requests)v.resolve({value:void 0,done:!0});this._requests.length=0,this._stream._removeRangeReader(this)}}},(ue,L)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.XfaText=void 0;class ne{static textContent(oe){const G=[],H={items:G,styles:Object.create(null)};return function W(O){if(!O)return;let a=null;const v=O.name;if("#text"===v)a=O.value;else{if(!ne.shouldBuildText(v))return;O?.attributes?.textContent?a=O.attributes.textContent:O.value&&(a=O.value)}if(null!==a&&G.push({str:a}),O.children)for(const g of O.children)W(g)}(oe),H}static shouldBuildText(oe){return!("textarea"===oe||"input"===oe||"option"===oe||"select"===oe)}}L.XfaText=ne},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.NodeStandardFontDataFactory=L.NodeCanvasFactory=L.NodeCMapReaderFactory=void 0;var y=ne(6);const oe=function(O){return new Promise((a,v)=>{__webpack_require__(172).readFile(O,(f,r)=>{!f&&r?a(new Uint8Array(r)):v(new Error(f))})})};L.NodeCanvasFactory=class G extends y.BaseCanvasFactory{_createCanvas(a,v){return __webpack_require__(3414).createCanvas(a,v)}},L.NodeCMapReaderFactory=class H extends y.BaseCMapReaderFactory{_fetchData(a,v){return oe(a).then(g=>({cMapData:g,compressionType:v}))}},L.NodeStandardFontDataFactory=class W extends y.BaseStandardFontDataFactory{_fetchData(a){return oe(a)}}},(ue,L,ne)=>{var T,Je;Object.defineProperty(L,"__esModule",{value:!0}),L.AnnotationLayer=void 0;var y=ne(1),oe=ne(5),G=ne(8),H=ne(21),W=ne(22);const O=1e3,a=new WeakSet;function v(h){return{width:h[2]-h[0],height:h[3]-h[1]}}class g{static create(e){switch(e.data.annotationType){case y.AnnotationType.LINK:return new r(e);case y.AnnotationType.TEXT:return new p(e);case y.AnnotationType.WIDGET:switch(e.data.fieldType){case"Tx":return new s(e);case"Btn":return e.data.radioButton?new S(e):e.data.checkBox?new u(e):new d(e);case"Ch":return new _(e)}return new n(e);case y.AnnotationType.POPUP:return new t(e);case y.AnnotationType.FREETEXT:return new A(e);case y.AnnotationType.LINE:return new l(e);case y.AnnotationType.SQUARE:return new m(e);case y.AnnotationType.CIRCLE:return new x(e);case y.AnnotationType.POLYLINE:return new M(e);case y.AnnotationType.CARET:return new I(e);case y.AnnotationType.INK:return new j(e);case y.AnnotationType.POLYGON:return new k(e);case y.AnnotationType.HIGHLIGHT:return new X(e);
1case y.AnnotationType.UNDERLINE:return new J(e);case y.AnnotationType.SQUIGGLY:return new N(e);case y.AnnotationType.STRIKEOUT:return new $(e);case y.AnnotationType.STAMP:return new K(e);case y.AnnotationType.FILEATTACHMENT:return new te(e);default:return new f(e)}}}class f{constructor(e,{isRenderable:c=!1,ignoreBorder:b=!1,createQuadrilaterals:w=!1}={}){this.isRenderable=c,this.data=e.data,this.layer=e.layer,this.page=e.page,this.viewport=e.viewport,this.linkService=e.linkService,this.downloadManager=e.downloadManager,this.imageResourcesPath=e.imageResourcesPath,this.renderForms=e.renderForms,this.svgFactory=e.svgFactory,this.annotationStorage=e.annotationStorage,this.enableScripting=e.enableScripting,this.hasJSActions=e.hasJSActions,this._fieldObjects=e.fieldObjects,this._mouseState=e.mouseState,c&&(this.container=this._createContainer(b)),w&&(this.quadrilaterals=this._createQuadrilaterals(b))}_createContainer(e=!1){const c=this.data,b=this.page,w=this.viewport,C=document.createElement("section");let{width:E,height:B}=v(c.rect);C.setAttribute("data-annotation-id",c.id);const U=y.Util.normalizeRect([c.rect[0],b.view[3]-c.rect[1]+b.view[1],c.rect[2],b.view[3]-c.rect[3]+b.view[1]]);if(c.hasOwnCanvas){const V=w.transform.slice(),[z,Y]=y.Util.singularValueDecompose2dScale(V);E=Math.ceil(E*z),B=Math.ceil(B*Y),U[0]*=z,U[1]*=Y;for(let ee=0;ee<4;ee++)V[ee]=Math.sign(V[ee]);C.style.transform=`matrix(${V.join(",")})`}else C.style.transform=`matrix(${w.transform.join(",")})`;if(C.style.transformOrigin=`${-U[0]}px ${-U[1]}px`,!e&&c.borderStyle.width>0){C.style.borderWidth=`${c.borderStyle.width}px`,c.borderStyle.style!==y.AnnotationBorderStyleType.UNDERLINE&&(E-=2*c.borderStyle.width,B-=2*c.borderStyle.width);const V=c.borderStyle.horizontalCornerRadius,z=c.borderStyle.verticalCornerRadius;switch((V>0||z>0)&&(C.style.borderRadius=`${V}px / ${z}px`),c.borderStyle.style){case y.AnnotationBorderStyleType.SOLID:C.style.borderStyle="solid";break;case y.AnnotationBorderStyleType.DASHED:C.style.borderStyle="dashed";break;case y.AnnotationBorderStyleType.BEVELED:(0,y.warn)("Unimplemented border style: beveled");break;case y.AnnotationBorderStyleType.INSET:(0,y.warn)("Unimplemented border style: inset");break;case y.AnnotationBorderStyleType.UNDERLINE:C.style.borderBottomStyle="solid"}c.borderColor||c.color?C.style.borderColor=y.Util.makeHexColor(0|c.color[0],0|c.color[1],0|c.color[2]):C.style.borderWidth=0}return C.style.left=`${U[0]}px`,C.style.top=`${U[1]}px`,c.hasOwnCanvas?C.style.width=C.style.height="auto":(C.style.width=`${E}px`,C.style.height=`${B}px`),C}get _commonActions(){const e=(c,b,w)=>{const C=w.detail[c];w.target.style[b]=H.ColorConverters[`${C[0]}_HTML`](C.slice(1))};return(0,y.shadow)(this,"_commonActions",{display:c=>{const b=c.detail.display%2==1;c.target.style.visibility=b?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{hidden:b,print:0===c.detail.display||3===c.detail.display})},print:c=>{this.annotationStorage.setValue(this.data.id,{print:c.detail.print})},hidden:c=>{c.target.style.visibility=c.detail.hidden?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{hidden:c.detail.hidden})},focus:c=>{setTimeout(()=>c.target.focus({preventScroll:!1}),0)},userName:c=>{c.target.title=c.detail.userName},readonly:c=>{c.detail.readonly?c.target.setAttribute("readonly",""):c.target.removeAttribute("readonly")},required:c=>{c.detail.required?c.target.setAttribute("required",""):c.target.removeAttribute("required")},bgColor:c=>{e("bgColor","backgroundColor",c)},fillColor:c=>{e("fillColor","backgroundColor",c)},fgColor:c=>{e("fgColor","color",c)},textColor:c=>{e("textColor","color",c)},borderColor:c=>{e("borderColor","borderColor",c)},strokeColor:c=>{e("strokeColor","borderColor",c)}})}_dispatchEventFromSandbox(e,c){const b=this._commonActions;for(const w of Object.keys(c.detail)){const C=e[w]||b[w];C&&C(c)}}_setDefaultPropertiesFromJS(e){if(!this.enableScripting)return;const c=this.annotationStorage.getRawValue(this.data.id);if(!c)return;const b=this._commonActions;for(const[w,C]of Object.entries(c)){const E=b[w];E&&(E({detail:C,target:e}),delete c[w])}}
1_createQuadrilaterals(e=!1){if(!this.data.quadPoints)return null;const c=[],b=this.data.rect;for(const w of this.data.quadPoints)this.data.rect=[w[2].x,w[2].y,w[1].x,w[1].y],c.push(this._createContainer(e));return this.data.rect=b,c}_createPopup(e,c){let b=this.container;this.quadrilaterals&&(e=e||this.quadrilaterals,b=this.quadrilaterals[0]),e||((e=document.createElement("div")).style.height=b.style.height,e.style.width=b.style.width,b.appendChild(e));const C=new i({container:b,trigger:e,color:c.color,titleObj:c.titleObj,modificationDate:c.modificationDate,contentsObj:c.contentsObj,richText:c.richText,hideWrapper:!0}).render();C.style.left=b.style.width,b.appendChild(C)}_renderQuadrilaterals(e){for(const c of this.quadrilaterals)c.className=e;return this.quadrilaterals}render(){(0,y.unreachable)("Abstract method `AnnotationElement.render` called")}_getElementsByName(e,c=null){const b=[];if(this._fieldObjects){const w=this._fieldObjects[e];if(w)for(const{page:C,id:E,exportValues:B}of w){if(-1===C||E===c)continue;const U="string"==typeof B?B:null,V=document.getElementById(E);!V||a.has(V)?b.push({id:E,exportValue:U,domElement:V}):(0,y.warn)(`_getElementsByName - element not allowed: ${E}`)}return b}for(const w of document.getElementsByName(e)){const{id:C,exportValue:E}=w;C!==c&&(!a.has(w)||b.push({id:C,exportValue:E,domElement:w}))}return b}static get platform(){const e=typeof navigator<"u"?navigator.platform:"";return(0,y.shadow)(this,"platform",{isWin:e.includes("Win"),isMac:e.includes("Mac")})}}class r extends f{constructor(e,c=null){super(e,{isRenderable:!!(e.data.url||e.data.dest||e.data.action||e.data.isTooltipOnly||e.data.resetForm||e.data.actions&&(e.data.actions.Action||e.data.actions["Mouse Up"]||e.data.actions["Mouse Down"])),ignoreBorder:!!c?.ignoreBorder,createQuadrilaterals:!0})}render(){const{data:e,linkService:c}=this,b=document.createElement("a");if(e.url)c.addLinkAttributes(b,e.url,e.newWindow);else if(e.action)this._bindNamedAction(b,e.action);else if(e.dest)this._bindLink(b,e.dest);else{let w=!1;e.actions&&(e.actions.Action||e.actions["Mouse Up"]||e.actions["Mouse Down"])&&this.enableScripting&&this.hasJSActions&&(w=!0,this._bindJSAction(b,e)),e.resetForm?this._bindResetFormAction(b,e.resetForm):w||this._bindLink(b,"")}return this.quadrilaterals?this._renderQuadrilaterals("linkAnnotation").map((w,C)=>{const E=0===C?b:b.cloneNode();return w.appendChild(E),w}):(this.container.className="linkAnnotation",this.container.appendChild(b),this.container)}_bindLink(e,c){e.href=this.linkService.getDestinationHash(c),e.onclick=()=>(c&&this.linkService.goToDestination(c),!1),(c||""===c)&&(e.className="internalLink")}_bindNamedAction(e,c){e.href=this.linkService.getAnchorUrl(""),e.onclick=()=>(this.linkService.executeNamedAction(c),!1),e.className="internalLink"}_bindJSAction(e,c){e.href=this.linkService.getAnchorUrl("");const b=new Map([["Action","onclick"],["Mouse Up","onmouseup"],["Mouse Down","onmousedown"]]);for(const w of Object.keys(c.actions)){const C=b.get(w);!C||(e[C]=()=>(this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:c.id,name:w}}),!1))}e.onclick||(e.onclick=()=>!1),e.className="internalLink"}_bindResetFormAction(e,c){const b=e.onclick;if(b||(e.href=this.linkService.getAnchorUrl("")),e.className="internalLink",!this._fieldObjects)return(0,y.warn)('_bindResetFormAction - "resetForm" action not supported, ensure that the `fieldObjects` parameter is provided.'),void(b||(e.onclick=()=>!1));e.onclick=()=>{b&&b();const{fields:w,refs:C,include:E}=c,B=[];if(0!==w.length||0!==C.length){const z=new Set(C);for(const Y of w){const ee=this._fieldObjects[Y]||[];for(const{id:ce}of ee)z.add(ce)}for(const Y of Object.values(this._fieldObjects))for(const ee of Y)z.has(ee.id)===E&&B.push(ee)}else for(const z of Object.values(this._fieldObjects))B.push(...z);const U=this.annotationStorage,V=[];for(const z of B){const{id:Y}=z;switch(V.push(Y),z.type){case"text":case"combobox":case"listbox":U.setValue(Y,{value:z.defaultValue||""});break;case"checkbox":case"radiobutton":U.setValue(Y,{value:z.defaultValue===z.exportValues});break;default:continue}const ee=document.getElementById(Y);!ee||!a.has(ee)||ee.dispatchEvent(new Event("resetform"))}return this.enableScripting&&this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:"app",ids:V,name:"ResetForm"}}),!1}}}class p extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.r
vendor: 21,087 bytes, line 1
1ichText?.str)})}render(){this.container.className="textAnnotation";const e=document.createElement("img");return e.style.height=this.container.style.height,e.style.width=this.container.style.width,e.src=this.imageResourcesPath+"annotation-"+this.data.name.toLowerCase()+".svg",e.alt="[{{type}} Annotation]",e.dataset.l10nId="text_annotation_type",e.dataset.l10nArgs=JSON.stringify({type:this.data.name}),this.data.hasPopup||this._createPopup(e,this.data),this.container.appendChild(e),this.container}}class n extends f{render(){return this.data.alternativeText&&(this.container.title=this.data.alternativeText),this.container}_getKeyModifier(e){const{isWin:c,isMac:b}=f.platform;return c&&e.ctrlKey||b&&e.metaKey}_setEventListener(e,c,b,w){c.includes("mouse")?e.addEventListener(c,C=>{this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:b,value:w(C),shift:C.shiftKey,modifier:this._getKeyModifier(C)}})}):e.addEventListener(c,C=>{this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:b,value:w(C)}})})}_setEventListeners(e,c,b){for(const[w,C]of c)("Action"===C||this.data.actions?.[C])&&this._setEventListener(e,w,C,b)}_setBackgroundColor(e){const c=this.data.backgroundColor||null;e.style.backgroundColor=null===c?"transparent":y.Util.makeHexColor(c[0],c[1],c[2])}}class s extends n{constructor(e){super(e,{isRenderable:e.renderForms||!e.data.hasAppearance&&!!e.data.fieldValue})}setPropertyOnSiblings(e,c,b,w){const C=this.annotationStorage;for(const E of this._getElementsByName(e.name,e.id))E.domElement&&(E.domElement[c]=b),C.setValue(E.id,{[w]:b})}render(){const e=this.annotationStorage,c=this.data.id;this.container.className="textWidgetAnnotation";let b=null;if(this.renderForms){const w=e.getValue(c,{value:this.data.fieldValue}),C=w.formattedValue||w.value||"",E={userValue:null,formattedValue:null,valueOnFocus:""};this.data.multiLine?(b=document.createElement("textarea"),b.textContent=C):(b=document.createElement("input"),b.type="text",b.setAttribute("value",C)),a.add(b),b.disabled=this.data.readOnly,b.name=this.data.fieldName,b.tabIndex=O,E.userValue=C,b.setAttribute("id",c),b.addEventListener("input",U=>{e.setValue(c,{value:U.target.value}),this.setPropertyOnSiblings(b,"value",U.target.value,"value")}),b.addEventListener("resetform",U=>{b.value=E.userValue=this.data.defaultFieldValue??"",E.formattedValue=null});let B=U=>{const{formattedValue:V}=E;null!=V&&(U.target.value=V),U.target.scrollLeft=0};if(this.enableScripting&&this.hasJSActions){b.addEventListener("focus",V=>{E.userValue&&(V.target.value=E.userValue),E.valueOnFocus=V.target.value}),b.addEventListener("updatefromsandbox",V=>{this._dispatchEventFromSandbox({value(Y){E.userValue=Y.detail.value??"",e.setValue(c,{value:E.userValue.toString()}),Y.target.value=E.userValue},formattedValue(Y){const{formattedValue:ee}=Y.detail;E.formattedValue=ee,null!=ee&&Y.target!==document.activeElement&&(Y.target.value=ee),e.setValue(c,{formattedValue:ee})},selRange(Y){Y.target.setSelectionRange(...Y.detail.selRange)}},V)}),b.addEventListener("keydown",V=>{let z=-1;if("Escape"===V.key?z=0:"Enter"===V.key?z=2:"Tab"===V.key&&(z=3),-1===z)return;const{value:Y}=V.target;E.valueOnFocus!==Y&&(E.userValue=Y,this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:c,name:"Keystroke",value:Y,willCommit:!0,commitKey:z,selStart:V.target.selectionStart,selEnd:V.target.selectionEnd}}))});const U=B;B=null,b.addEventListener("blur",V=>{const{value:z}=V.target;E.userValue=z,this._mouseState.isDown&&E.valueOnFocus!==z&&this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:c,name:"Keystroke",value:z,willCommit:!0,commitKey:1,selStart:V.target.selectionStart,selEnd:V.target.selectionEnd}}),U(V)}),this.data.actions?.Keystroke&&b.addEventListener("beforeinput",V=>{const{data:z,target:Y}=V,{value:ee,selectionStart:ce,selectionEnd:be}=Y;let Q=ce,re=be;switch(V.inputType){case"deleteWordBackward":{const ie=ee.substring(0,ce).match(/\w*[^\w]*$/);ie&&(Q-=ie[0].length);break}case"deleteWordForward":{const ie=ee.substring(ce).match(/^[^\w]*\w*/);ie&&(re+=ie[0].length);break}case"deleteContentBackward":ce===be&&(Q-=1);break;case"deleteContentForward":ce===be&&(re+=1)}V.preventDefault(),this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:c,name:"Keystroke",value:ee,change:z||"",willCommit:!1,selStart:Q,selEnd:re}})}),this._setEventListeners(b,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],V=>V.target.value)}if(B&&b.addEventListener("blur",B),null!==this.data.maxLen&&(b.maxLength=this.data.maxLen),this.data.comb){const V=(this.data.rect[2]-this.data.rect[0])/this.data.maxLen;b.classList.add("comb"),b.style.letterSpacing=`calc(${V}px - 1ch)`}}else b=document.createElement("div"),b.textContent=this.data.fieldValue,b.style.verticalAlign="middle",b.style.display="table-cell";return this._setTextStyle(b),this._setBackgroundColor(b),this._setDefaultPropertiesFromJS(b),this.container.appendChild(b),this.container}_setTextStyle(e){const{fontSize:b,fontColor:w}=this.data.defaultAppearanceData,C=e.style;b&&(C.fontSize=`${b}px`),C.color=y.Util.makeHexColor(w[0],w[1],w[2]),null!==this.data.textAlignment&&(C.textAlign=["left","center","right"][this.data.textAlignment])}}class u extends n{constructor(e){super(e,{isRenderable:e.renderForms})}render(){const e=this.annotationStorage,c=this.data,b=c.id;let w=e.getValue(b,{value:c.exportValue===c.fieldValue}).value;"string"==typeof w&&(w="Off"!==w,e.setValue(b,{value:w})),this.container.className="buttonWidgetAnnotation checkBox";const C=document.createElement("input");return a.add(C),C.disabled=c.readOnly,C.type="checkbox",C.name=c.fieldName,w&&C.setAttribute("checked",!0),C.setAttribute("id",b),C.setAttribute("exportValue",c.exportValue),C.tabIndex=O,C.addEventListener("change",E=>{const{name:B,checked:U}=E.target;for(const V of this._getElementsByName(B,b)){const z=U&&V.exportValue===c.exportValue;V.domElement&&(V.domElement.checked=z),e.setValue(V.id,{value:z})}e.setValue(b,{value:U})}),C.addEventListener("resetform",E=>{E.target.checked=(c.defaultFieldValue||"Off")===c.exportValue}),this.enableScripting&&this.hasJSActions&&(C.addEventListener("updatefromsandbox",E=>{this._dispatchEventFromSandbox({value(U){U.target.checked="Off"!==U.detail.value,e.setValue(b,{value:U.target.checked})}},E)}),this._setEventListeners(C,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],E=>E.target.checked)),this._setBackgroundColor(C),this._setDefaultPropertiesFromJS(C),this.container.appendChild(C),this.container}}class S extends n{constructor(e){super(e,{isRenderable:e.renderForms})}render(){this.container.className="buttonWidgetAnnotation radioButton";const e=this.annotationStorage,c=this.data,b=c.id;let w=e.getValue(b,{value:c.fieldValue===c.buttonValue}).value;"string"==typeof w&&(w=w!==c.buttonValue,e.setValue(b,{value:w}));const C=document.createElement("input");if(a.add(C),C.disabled=c.readOnly,C.type="radio",C.name=c.fieldName,w&&C.setAttribute("checked",!0),C.setAttribute("id",b),C.tabIndex=O,C.addEventListener("change",E=>{const{name:B,checked:U}=E.target;for(const V of this._getElementsByName(B,b))e.setValue(V.id,{value:!1});e.setValue(b,{value:U})}),C.addEventListener("resetform",E=>{const B=c.defaultFieldValue;E.target.checked=null!=B&&B===c.buttonValue}),this.enableScripting&&this.hasJSActions){const E=c.buttonValue;C.addEventListener("updatefromsandbox",B=>{this._dispatchEventFromSandbox({value:V=>{const z=E===V.detail.value;for(const Y of this._getElementsByName(V.target.name)){const ee=z&&Y.id===b;Y.domElement&&(Y.domElement.checked=ee),e.setValue(Y.id,{value:ee})}}},B)}),this._setEventListeners(C,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],B=>B.target.checked)}return this._setBackgroundColor(C),this._setDefaultPropertiesFromJS(C),this.container.appendChild(C),this.container}}class d extends r{constructor(e){super(e,{ignoreBorder:e.data.hasAppearance})}render(){const e=super.render();return e.className="buttonWidgetAnnotation pushButton",this.data.alternativeText&&(e.title=this.data.alternativeText),this._setDefaultPropertiesFromJS(e),e}}class _ extends n{constructor(e){super(e,{isRenderable:e.renderForms})}render(){this.container.className="choiceWidgetAnnotation";const e=this.annotationStorage,c=this.data.id,b=e.getValue(c,{value:this.data.fieldValue});let{fontSize:w}=this.data.defaultAppearanceData;w||(w=9);const C=`calc(${w}px * var(--zoom-factor))`,E=document.createElement("select");a.add(E),E.disabled=this.data.readOnly,E.name=this.data.fieldName,E.setAttribute("id",c),E.tabIndex=O,E.style.fontSize=`${w}px`,this.data.combo||(E.size=this.data.options.length,this.data.multiSelect&&(E.multiple=!0)),E.addEventListener("resetform",V=>{const z=this.data.defaultFieldValue;for(const Y of E.options)Y.selected=Y.value===z});for(const V of this.data.options){const z=document.createElement("option");z.textContent=V.displayValue,z.value=V.exportValue,this.data.combo&&(z.style.fontSize=C),b.value.includes(V.exportValue)&&z.setAttribute("selected",!0),E.appendChild(z)}const B=(V,z)=>{const Y=z?"value":"textContent",ee=V.target.options;return V.target.multiple?Array.prototype.filter.call(ee,ce=>ce.selected).map(ce=>ce[Y]):-1===ee.selectedIndex?null:ee[ee.selectedIndex][Y]},U=V=>Array.prototype.map.call(V.target.options,Y=>({displayValue:Y.textContent,exportValue:Y.value}));return this.enableScripting&&this.hasJSActions?(E.addEventListener("updatefromsandbox",V=>{this._dispatchEventFromSandbox({value(Y){const ee=Y.detail.value,ce=new Set(Array.isArray(ee)?ee:[ee]);for(const be of E.options)be.selected=ce.has(be.value);e.setValue(c,{value:B(Y,!0)})},multipleSelection(Y){E.multiple=!0},remove(Y){const ee=E.options,ce=Y.detail.remove;ee[ce].selected=!1,E.remove(ce),ee.length>0&&-1===Array.prototype.findIndex.call(ee,Q=>Q.selected)&&(ee[0].selected=!0),e.setValue(c,{value:B(Y,!0),items:U(Y)})},clear(Y){for(;0!==E.length;)E.remove(0);e.setValue(c,{value:null,items:[]})},insert(Y){const{index:ee,displayValue:ce,exportValue:be}=Y.detail.insert,Q=document.createElement("option");Q.textContent=ce,Q.value=be,E.insertBefore(Q,E.children[ee]),e.setValue(c,{value:B(Y,!0),items:U(Y)})},items(Y){const{items:ee}=Y.detail;for(;0!==E.length;)E.remove(0);for(const ce of ee){const{displayValue:be,exportValue:Q}=ce,re=document.createElement("option");re.textContent=be,re.value=Q,E.appendChild(re)}E.options.length>0&&(E.options[0].selected=!0),e.setValue(c,{value:B(Y,!0),items:U(Y)})},indices(Y){const ee=new Set(Y.detail.indices);for(const ce of Y.target.options)ce.selected=ee.has(ce.index);e.setValue(c,{value:B(Y,!0)})},editable(Y){Y.target.disabled=!Y.detail.editable}},V)}),E.addEventListener("input",V=>{const z=B(V,!0),Y=B(V,!1);e.setValue(c,{value:z}),this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:c,name:"Keystroke",value:Y,changeEx:z,willCommit:!0,commitKey:1,keyDown:!1}})}),this._setEventListeners(E,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"],["input","Action"]],V=>V.target.checked)):E.addEventListener("input",function(V){e.setValue(c,{value:B(V,!0)})}),this._setBackgroundColor(E),this._setDefaultPropertiesFromJS(E),this.container.appendChild(E),this.container}}class t extends f{constructor(e){super(e,{isRenderable:!!(e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str)})}render(){if(this.container.className="popupAnnotation",["Line","Square","Circle","PolyLine","Polygon","Ink"].includes(this.data.parentType))return this.container;const b=this.layer.querySelectorAll(`[data-annotation-id="${this.data.parentId}"]`);if(0===b.length)return this.container;const w=new i({container:this.container,trigger:Array.from(b),color:this.data.color,titleObj:this.data.titleObj,modificationDate:this.data.modificationDate,contentsObj:this.data.contentsObj,richText:this.data.richText}),C=this.page,E=y.Util.normalizeRect([this.data.parentRect[0],C.view[3]-this.data.parentRect[1]+C.view[1],this.data.parentRect[2],C.view[3]-this.data.parentRect[3]+C.view[1]]),B=E[0]+this.data.parentRect[2]-this.data.parentRect[0],U=E[1];return this.container.style.transformOrigin=`${-B}px ${-U}px`,this.container.style.left=`${B}px`,this.container.style.top=`${U}px`,this.container.appendChild(w.render()),this.container}}class i{constructor(e){this.container=e.container,this.trigger=e.trigger,this.color=e.color,this.titleObj=e.titleObj,this.modificationDate=e.modificationDate,this.contentsObj=e.contentsObj,this.richText=e.richText,this.hideWrapper=e.hideWrapper||!1,this.pinned=!1}render(){const c=document.createElement("div");c.className="popupWrapper",this.hideElement=this.hideWrapper?c:this.container,this.hideElement.hidden=!0;const b=document.createElement("div");b.className="popup";const w=this.color;w&&(b.style.backgroundColor=y.Util.makeHexColor(0|.7*(255-w[0])+w[0],0|.7*(255-w[1])+w[1],0|.7*(255-w[2])+w[2]));const C=document.createElement("h1");C.dir=this.titleObj.dir,C.textContent=this.titleObj.str,b.appendChild(C);const E=oe.PDFDateString.toDateObject(this.modificationDate);if(E){const B=document.createElement("span");B.className="popupDate",B.textContent="{{date}}, {{time}}",B.dataset.l10nId="annotation_date_string",B.dataset.l10nArgs=JSON.stringify({date:E.toLocaleDateString(),time:E.toLocaleTimeString()}),b.appendChild(B)}if(!this.richText?.str||this.contentsObj?.str&&this.contentsObj.str!==this.richText.str){const B=this._formatContents(this.contentsObj);b.appendChild(B)}else W.XfaLayer.render({xfaHtml:this.richText.html,intent:"richText",div:b}),b.lastChild.className="richText popupContent";Array.isArray(this.trigger)||(this.trigger=[this.trigger]);for(const B of this.trigger)B.addEventListener("click",this._toggle.bind(this)),B.addEventListener("mouseover",this._show.bind(this,!1)),B.addEventListener("mouseout",this._hide.bind(this,!1));return b.addEventListener("click",this._hide.bind(this,!0)),c.appendChild(b),c}_formatContents({str:e,dir:c}){const b=document.createElement("p");b.className="popupContent",b.dir=c;const w=e.split(/(?:\r\n?|\n)/);for(let C=0,E=w.length;C<E;++C)b.appendChild(document.createTextNode(w[C])),C<E-1&&b.appendChild(document.createElement("br"));return b}_toggle(){this.pinned?this._hide(!0):this._show(!0)}_show(e=!1){e&&(this.pinned=!0),this.hideElement.hidden&&(this.hideElement.hidden=!1,this.container.style.zIndex+=1)}_hide(e=!0){e&&(this.pinned=!1),!this.hideElement.hidden&&!this.pinned&&(this.hideElement.hidden=!0,this.container.style.zIndex-=1)}}class A extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0})}render(){return this.container.className="freeTextAnnotation",this.data.hasPopup||this._createPopup(null,this.data),this.container}}class l extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0})}render(){this.container.className="lineAnnotation";const e=this.data,{width:c,height:b}=v(e.rect),w=this.svgFactory.create(c,b),C=this.svgFactory.createElement("svg:line");return C.setAttribute("x1",e.rect[2]-e.lineCoordinates[0]),C.setAttribute("y1",e.rect[3]-e.lineCoordinates[1]),C.setAttribute("x2",e.rect[2]-e.lineCoordinates[2]),C.setAttribute("y2",e.rect[3]-e.lineCoordinates[3]),C.setAttribute("stroke-width",e.borderStyle.width||1),C.setAttribute("stroke","transparent"),C.setAttribute("fill","transparent"),w.appendChild(C),this.container.append(w),this._createPopup(C,e),this.container}}class m extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0})}render(){this.container.className="squareAnnotation";const e=this.data,{width:c,height:b}=v(e.rect),w=this.svgFactory.create(c,b),C=e.borderStyle.width,E=this.svgFactory.createElement("svg:rect");return E.setAttribute("x",C/2),E.setAttribute("y",C/2),E.setAttribute("width",c-C),E.setAttribute("height",b-C),E.setAttribute("stroke-width",C||1),E.setAttribute("stroke","transparent"),E.setAttribute("fill","transparent"),w.appendChild(E),this.container.append(w),this._createPopup(E,e),this.container}}class x extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0})}render(){this.container.className="circleAnnotation";const e=this.data,{width:c,height:b}=v(e.rect),w=this.svgFactory.create(c,b),C=e.borderStyle.width,E=this.svgFactory.createElement("svg:ellipse");return E.setAttribute("cx",c/2),E.setAttribute("cy",b/2),E.setAttribute("rx",c/2-C/2),E.setAttribute("ry",b/2-C/2),E.setAttribute("stroke-width",C||1),E.setAttribute("stroke","transparent"),E.setAttribute("fill","transparent"),w.appendChild(E),this.container.append(w),this._createPopup(E,e),this.container}}class M extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0}),this.containerClassName="polylineAnnotation",this.svgElementName="svg:polyline"}render(){this.container.className=this.containerClassName;const e=this.data,{width:c,height:b}=v(e.rect),w=this.svgFactory.create(c,b);let C=[];for(const B of e.vertices)C.push(B.x-e.rect[0]+","+(e.rect[3]-B.y));C=C.join(" ");const E=this.svgFactory.createElement(this.svgElementName);return E.setAttribute("points",C),E.setAttribute("stroke-width",e.borderStyle.width||1),E.setAttribute("stroke","transparent"),E.setAttribute("fill","transparent"),w.appendChild(E),this.container.append(w),this._createPopup(E,e),this.container}}class k extends M{constructor(e){super(e),this.containerClassName="polygonAnnotation",this.svgElementName="svg:polygon"}}class I extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0})}render(){return this.container.className="caretAnnotation",this.data.hasPopup||this._createPopup(null,this.data),this.container}}class j extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0}),this.containerClassName="inkAnnotation",this.svgElementName="svg:polyline"}render(){this.container.className=this.containerClassName;const e=this.data,{width:c,height:b}=v(e.rect),w=this.svgFactory.create(c,b);for(const C of e.inkLists){let E=[];for(const U of C)E.push(`${U.x-e.rect[0]},${e.rect[3]-U.y}`);E=E.join(" ");const B=this.svgFactory.createElement(this.svgElementName);B.setAttribute("points",E),B.setAttribute("stroke-width",e.borderStyle.width||1),B.setAttribute("stroke","transparent"),B.setAttribute("fill","transparent"),this._createPopup(B,e),w.appendChild(B)}return this.container.append(w),this.container}}class X extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0,createQuadrilaterals:!0})}render(){return this.data.hasPopup||this._createPopup(null,this.data),this.quadrilaterals?this._renderQuadrilaterals("highlightAnnotation"):(this.container.className="highlightAnnotation",this.container)}}class J extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0,createQuadrilaterals:!0})}render(){return this.data.hasPopup||this._createPopup(null,this.data),this.quadrilaterals?this._renderQuadrilaterals("underlineAnnotation"):(this.container.className="underlineAnnotation",this.container)}}class N extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0,createQuadrilaterals:!0})}render(){return this.data.hasPopup||this._createPopup(null,this.data),this.quadrilaterals?this._renderQuadrilaterals("squigglyAnnotation"):(this.container.className="squigglyAnnotation",this.container)}}class $ extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.richText?.str),ignoreBorder:!0,createQuadrilaterals:!0})}render(){return this.data.hasPopup||this._createPopup(null,this.data),this.quadrilaterals?this._renderQuadrilaterals("strikeoutAnnotation"):(this.container.className="strikeoutAnnotation",this.container)}}class K extends f{constructor(e){super(e,{isRenderable:!!(e.data.hasPopup||e.data.titleObj?.str||e.data.contentsObj?.str||e.data.r
1ichText?.str),ignoreBorder:!0})}render(){return this.container.className="stampAnnotation",this.data.hasPopup||this._createPopup(null,this.data),this.container}}class te extends f{constructor(e){super(e,{isRenderable:!0});const{filename:c,content:b}=this.data.file;this.filename=(0,oe.getFilenameFromUrl)(c),this.content=b,this.linkService.eventBus?.dispatch("fileattachmentannotation",{source:this,filename:c,content:b})}render(){this.container.className="fileAttachmentAnnotation";const e=document.createElement("div");return e.style.height=this.container.style.height,e.style.width=this.container.style.width,e.addEventListener("dblclick",this._download.bind(this)),!this.data.hasPopup&&(this.data.titleObj?.str||this.data.contentsObj?.str||this.data.richText)&&this._createPopup(e,this.data),this.container.appendChild(e),this.container}_download(){this.downloadManager?.openOrDownloadData(this.container,this.content,this.filename)}}class se{static render(e){const c=[],b=[];for(const C of e.annotations){if(!C)continue;const{width:E,height:B}=v(C.rect);if(!(E<=0||B<=0)){if(C.annotationType===y.AnnotationType.POPUP){b.push(C);continue}c.push(C)}}b.length&&c.push(...b);const w=e.div;for(const C of c){const E=g.create({data:C,layer:w,page:e.page,viewport:e.viewport,linkService:e.linkService,downloadManager:e.downloadManager,imageResourcesPath:e.imageResourcesPath||"",renderForms:!1!==e.renderForms,svgFactory:new oe.DOMSVGFactory,annotationStorage:e.annotationStorage||new G.AnnotationStorage,enableScripting:e.enableScripting,hasJSActions:e.hasJSActions,fieldObjects:e.fieldObjects,mouseState:e.mouseState||{isDown:!1}});if(E.isRenderable){const B=E.render();if(C.hidden&&(B.style.visibility="hidden"),Array.isArray(B))for(const U of B)w.appendChild(U);else E instanceof t?w.prepend(B):w.appendChild(B)}}ye(this,T,Je).call(this,w,e.annotationCanvasMap)}static update(e){const{page:c,viewport:b,annotations:w,annotationCanvasMap:C,div:E}=e,B=b.transform,U=`matrix(${B.join(",")})`;let V,z;for(const Y of w){const ee=E.querySelectorAll(`[data-annotation-id="${Y.id}"]`);if(ee)for(const ce of ee)if(Y.hasOwnCanvas){const be=y.Util.normalizeRect([Y.rect[0],c.view[3]-Y.rect[1]+c.view[1],Y.rect[2],c.view[3]-Y.rect[3]+c.view[1]]);if(!z){V=Math.abs(B[0]||B[1]);const ie=B.slice();for(let P=0;P<4;P++)ie[P]=Math.sign(ie[P]);z=`matrix(${ie.join(",")})`}const Q=be[0]*V,re=be[1]*V;ce.style.left=`${Q}px`,ce.style.top=`${re}px`,ce.style.transformOrigin=`${-Q}px ${-re}px`,ce.style.transform=z}else ce.style.transform=U}ye(this,T,Je).call(this,E,C),E.hidden=!1}}T=new WeakSet,Je=function(e,c){if(c){for(const[b,w]of c){const C=e.querySelector(`[data-annotation-id="${b}"]`);if(!C)continue;const{firstChild:E}=C;"CANVAS"===E.nodeName?C.replaceChild(w,E):C.insertBefore(w,E)}c.clear()}},ve(se,T),L.AnnotationLayer=se},(ue,L)=>{function ne(oe){return Math.floor(255*Math.max(0,Math.min(1,oe))).toString(16).padStart(2,"0")}Object.defineProperty(L,"__esModule",{value:!0}),L.ColorConverters=void 0,L.ColorConverters=class y{static CMYK_G([G,H,W,O]){return["G",1-Math.min(1,.3*G+.59*W+.11*H+O)]}static G_CMYK([G]){return["CMYK",0,0,0,1-G]}static G_RGB([G]){return["RGB",G,G,G]}static G_HTML([G]){const H=ne(G);return`#${H}${H}${H}`}static RGB_G([G,H,W]){return["G",.3*G+.59*H+.11*W]}static RGB_HTML([G,H,W]){return`#${ne(G)}${ne(H)}${ne(W)}`}static T_HTML(){return"#00000000"}static CMYK_RGB([G,H,W,O]){return["RGB",1-Math.min(1,G+O),1-Math.min(1,W+O),1-Math.min(1,H+O)]}static CMYK_HTML(G){return this.RGB_HTML(this.CMYK_RGB(G))}static RGB_CMYK([G,H,W]){const O=1-G,a=1-H,v=1-W;return["CMYK",O,a,v,Math.min(O,a,v)]}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.XfaLayer=void 0;var y=ne(18);L.XfaLayer=class oe{static setupStorage(H,W,O,a,v){const g=a.getValue(W,{value:null});switch(O.name){case"textarea":if(null!==g.value&&(H.textContent=g.value),"print"===v)break;H.addEventListener("input",f=>{a.setValue(W,{value:f.target.value})});break;case"input":if("radio"===O.attributes.type||"checkbox"===O.attributes.type){if(g.value===O.attributes.xfaOn?H.setAttribute("checked",!0):g.value===O.attributes.xfaOff&&H.removeAttribute("checked"),"print"===v)break;H.addEventListener("change",f=>{a.setValue(W,{value:f.target.getAttribute(f.target.checked?"xfaOn":"xfaOff")})})}else{if(null!==g.value&&H.setAttribute("value",g.value),"print"===v)break;H.addEventListener("input",f=>{a.setValue(W,{value:f.target.value})})}break;case"select":if(null!==g.value)for(const f of O.children)f.attributes.value===g.value&&(f.attributes.selected=!0);H.addEventListener("input",f=>{const r=f.target.options;a.setValue(W,{value:-1===r.selectedIndex?"":r[r.selectedIndex].value})})}}static setAttributes({html:H,element:W,storage:O=null,intent:a,linkService:v}){const{attributes:g}=W,f=H instanceof HTMLAnchorElement;"radio"===g.type&&(g.name=`${g.name}-${a}`);for(const[r,p]of Object.entries(g))if(null!=p&&"dataId"!==r)if("style"!==r)if("textContent"===r)H.textContent=p;else if("class"===r)p.length&&H.setAttribute(r,p.join(" "));else{if(f&&("href"===r||"newWindow"===r))continue;H.setAttribute(r,p)}else Object.assign(H.style,p);f&&v.addLinkAttributes(H,g.href,g.newWindow),O&&g.dataId&&this.setupStorage(H,g.dataId,W,O)}static render(H){const W=H.annotationStorage,O=H.linkService,a=H.xfaHtml,v=H.intent||"display",g=document.createElement(a.name);a.attributes&&this.setAttributes({html:g,element:a,intent:v,linkService:O});const f=[[a,-1,g]],r=H.div;if(r.appendChild(g),H.viewport){const n=`matrix(${H.viewport.transform.join(",")})`;r.style.transform=n}"richText"!==v&&r.setAttribute("class","xfaLayer xfaFont");const p=[];for(;f.length>0;){const[n,s,u]=f[f.length-1];if(s+1===n.children.length){f.pop();continue}const S=n.children[++f[f.length-1][1]];if(null===S)continue;const{name:d}=S;if("#text"===d){const t=document.createTextNode(S.value);p.push(t),u.appendChild(t);continue}let _;if(_=S?.attributes?.xmlns?document.createElementNS(S.attributes.xmlns,d):document.createElement(d),u.appendChild(_),S.attributes&&this.setAttributes({html:_,element:S,storage:W,intent:v,linkService:O}),S.children&&S.children.length>0)f.push([S,-1,_]);else if(S.value){const t=document.createTextNode(S.value);y.XfaText.shouldBuildText(d)&&p.push(t),_.appendChild(t)}}for(const n of r.querySelectorAll(".xfaNonInteractive input, .xfaNonInteractive textarea"))n.setAttribute("readOnly",!0);return{textDivs:p}}static update(H){const W=`matrix(${H.viewport.transform.join(",")})`;H.div.style.transform=W,H.div.hidden=!1}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.renderTextLayer=function u(S){const d=new s({textContent:S.textContent,textContentStream:S.textContentStream,container:S.container,viewport:S.viewport,textDivs:S.textDivs,textContentItemsStr:S.textContentItemsStr,enhanceTextSelection:S.enhanceTextSelection});return d._render(S.timeout),d};var y=ne(1);const G=30,W=new Map,O=/^\s+$/g;function v(S,d,_,t){const i=document.createElement("span"),A=S._enhanceTextSelection?{angle:0,canvasWidth:0,hasText:""!==d.str,hasEOL:d.hasEOL,originalTransform:null,paddingBottom:0,paddingLeft:0,paddingRight:0,paddingTop:0,scale:1}:{angle:0,canvasWidth:0,hasText:""!==d.str,hasEOL:d.hasEOL};S._textDivs.push(i);const l=y.Util.transform(S._viewport.transform,d.transform);let m=Math.atan2(l[1],l[0]);const x=_[d.fontName];x.vertical&&(m+=Math.PI/2);const M=Math.hypot(l[2],l[3]),k=M*function a(S,d){const _=W.get(S);if(_)return _;d.save(),d.font=`30px ${S}`;const t=d.measureText("");let i=t.fontBoundingBoxAscent,A=Math.abs(t.fontBoundingBoxDescent);
vendor: 53,456 bytes, line 1
1if(i){d.restore();const m=i/(i+A);return W.set(S,m),m}d.strokeStyle="red",d.clearRect(0,0,G,G),d.strokeText("g",0,0);let l=d.getImageData(0,0,G,G).data;A=0;for(let m=l.length-1-3;m>=0;m-=4)if(l[m]>0){A=Math.ceil(m/4/G);break}d.clearRect(0,0,G,G),d.strokeText("A",0,G),l=d.getImageData(0,0,G,G).data,i=0;for(let m=0,x=l.length;m<x;m+=4)if(l[m]>0){i=G-Math.floor(m/4/G);break}if(d.restore(),i){const m=i/(i+A);return W.set(S,m),m}return W.set(S,.8),.8}(x.fontFamily,t);let I,j;0===m?(I=l[4],j=l[5]-k):(I=l[4]+k*Math.sin(m),j=l[5]-k*Math.cos(m)),i.style.left=`${I}px`,i.style.top=`${j}px`,i.style.fontSize=`${M}px`,i.style.fontFamily=x.fontFamily,i.setAttribute("role","presentation"),i.textContent=d.str,i.dir=d.dir,S._fontInspectorEnabled&&(i.dataset.fontName=d.fontName),0!==m&&(A.angle=m*(180/Math.PI));let X=!1;if(d.str.length>1||S._enhanceTextSelection&&O.test(d.str))X=!0;else if(" "!==d.str&&d.transform[0]!==d.transform[3]){const J=Math.abs(d.transform[0]),N=Math.abs(d.transform[3]);J!==N&&Math.max(J,N)/Math.min(J,N)>1.5&&(X=!0)}if(X&&(A.canvasWidth=x.vertical?d.height*S._viewport.scale:d.width*S._viewport.scale),S._textDivProperties.set(i,A),S._textContentStream&&S._layoutText(i),S._enhanceTextSelection&&A.hasText){let J=1,N=0;0!==m&&(J=Math.cos(m),N=Math.sin(m));const $=(x.vertical?d.height:d.width)*S._viewport.scale,K=M;let te,se;0!==m?(te=[J,N,-N,J,I,j],se=y.Util.getAxialAlignedBoundingBox([0,0,$,K],te)):se=[I,j,I+$,j+K],S._bounds.push({left:se[0],top:se[1],right:se[2],bottom:se[3],div:i,size:[$,K],m:te})}}function g(S){if(S._canceled)return;const d=S._textDivs,_=S._capability,t=d.length;if(t>1e5)return S._renderingDone=!0,void _.resolve();if(!S._textContentStream)for(let i=0;i<t;i++)S._layoutText(d[i]);S._renderingDone=!0,_.resolve()}function f(S,d,_){let t=0;for(let i=0;i<_;i++){const A=S[d++];A>0&&(t=t?Math.min(A,t):A)}return t}function n(S,d){d.sort(function(i,A){return i.x1-A.x1||i.index-A.index});const t=[{start:-1/0,end:1/0,boundary:{x1:-1/0,y1:-1/0,x2:0,y2:1/0,index:-1,x1New:0,x2New:0}}];for(const i of d){let A=0;for(;A<t.length&&t[A].end<=i.y1;)A++;let l=t.length-1;for(;l>=0&&t[l].start>=i.y2;)l--;let m,x,M,k,I=-1/0;for(M=A;M<=l;M++){let J;m=t[M],x=m.boundary,J=x.x2>i.x1?x.index>i.index?x.x1New:i.x1:void 0===x.x2New?(x.x2+i.x1)/2:x.x2New,J>I&&(I=J)}for(i.x1New=I,M=A;M<=l;M++)m=t[M],x=m.boundary,void 0===x.x2New?x.x2>i.x1?x.index>i.index&&(x.x2New=x.x2):x.x2New=I:x.x2New>I&&(x.x2New=Math.max(I,x.x2));const j=[];let X=null;for(M=A;M<=l;M++){m=t[M],x=m.boundary;const J=x.x2>i.x2?x:i;X===J?j[j.length-1].end=m.end:(j.push({start:m.start,end:m.end,boundary:J}),X=J)}for(t[A].start<i.y1&&(j[0].start=i.y1,j.unshift({start:t[A].start,end:i.y1,boundary:t[A].boundary})),i.y2<t[l].end&&(j[j.length-1].end=i.y2,j.push({start:i.y2,end:t[l].end,boundary:t[l].boundary})),M=A;M<=l;M++){if(m=t[M],x=m.boundary,void 0!==x.x2New)continue;let J=!1;for(k=A-1;!J&&k>=0&&t[k].start>=x.y1;k--)J=t[k].boundary===x;for(k=l+1;!J&&k<t.length&&t[k].end<=x.y2;k++)J=t[k].boundary===x;for(k=0;!J&&k<j.length;k++)J=j[k].boundary===x;J||(x.x2New=I)}Array.prototype.splice.apply(t,[A,l-A+1].concat(j))}for(const i of t){const A=i.boundary;void 0===A.x2New&&(A.x2New=Math.max(S,A.x2))}}class s{constructor({textContent:d,textContentStream:_,container:t,viewport:i,textDivs:A,textContentItemsStr:l,enhanceTextSelection:m}){this._textContent=d,this._textContentStream=_,this._container=t,this._document=t.ownerDocument,this._viewport=i,this._textDivs=A||[],this._textContentItemsStr=l||[],this._enhanceTextSelection=!!m,this._fontInspectorEnabled=!!globalThis.FontInspector?.enabled,this._reader=null,this._layoutTextLastFontSize=null,this._layoutTextLastFontFamily=null,this._layoutTextCtx=null,this._textDivProperties=new WeakMap,this._renderingDone=!1,this._canceled=!1,this._capability=(0,y.createPromiseCapability)(),this._renderTimer=null,this._bounds=[],this._capability.promise.finally(()=>{this._enhanceTextSelection||(this._textDivProperties=null),this._layoutTextCtx&&(this._layoutTextCtx.canvas.width=0,this._layoutTextCtx.canvas.height=0,this._layoutTextCtx=null)}).catch(()=>{})}get promise(){return this._capability.promise}cancel(){this._canceled=!0,this._reader&&(this._reader.cancel(new y.AbortException("TextLayer task cancelled.")).catch(()=>{}),this._reader=null),null!==this._renderTimer&&(clearTimeout(this._renderTimer),this._renderTimer=null),this._capability.reject(new Error("TextLayer task cancelled."))}_processItems(d,_){for(let t=0,i=d.length;t<i;t++)if(void 0!==d[t].str)this._textContentItemsStr.push(d[t].str),v(this,d[t],_,this._layoutTextCtx);else if("beginMarkedContentProps"===d[t].type||"beginMarkedContent"===d[t].type){const A=this._container;this._container=document.createElement("span"),this._container.classList.add("markedContent"),null!==d[t].id&&this._container.setAttribute("id",`${d[t].id}`),A.appendChild(this._container)}else"endMarkedContent"===d[t].type&&(this._container=this._container.parentNode)}_layoutText(d){const _=this._textDivProperties.get(d);let t="";if(0!==_.canvasWidth&&_.hasText){const{fontSize:i,fontFamily:A}=d.style;(i!==this._layoutTextLastFontSize||A!==this._layoutTextLastFontFamily)&&(this._layoutTextCtx.font=`${i} ${A}`,this._layoutTextLastFontSize=i,this._layoutTextLastFontFamily=A);const{width:l}=this._layoutTextCtx.measureText(d.textContent);if(l>0){const m=_.canvasWidth/l;this._enhanceTextSelection&&(_.scale=m),t=`scaleX(${m})`}}if(0!==_.angle&&(t=`rotate(${_.angle}deg) ${t}`),t.length>0&&(this._enhanceTextSelection&&(_.originalTransform=t),d.style.transform=t),_.hasText&&this._container.appendChild(d),_.hasEOL){const i=document.createElement("br");i.setAttribute("role","presentation"),this._container.appendChild(i)}}_render(d=0){const _=(0,y.createPromiseCapability)();let t=Object.create(null);const i=this._document.createElement("canvas");if(i.height=i.width=G,this._layoutTextCtx=i.getContext("2d",{alpha:!1}),this._textContent)this._processItems(this._textContent.items,this._textContent.styles),_.resolve();else{if(!this._textContentStream)throw new Error('Neither "textContent" nor "textContentStream" parameters specified.');{const A=()=>{this._reader.read().then(({value:l,done:m})=>{m?_.resolve():(Object.assign(t,l.styles),this._processItems(l.items,t),A())},_.reject)};this._reader=this._textContentStream.getReader(),A()}}_.promise.then(()=>{t=null,d?this._renderTimer=setTimeout(()=>{g(this),this._renderTimer=null},d):g(this)},this._capability.reject)}expandTextDivs(d=!1){if(!this._enhanceTextSelection||!this._renderingDone)return;null!==this._bounds&&(function r(S){const d=S._bounds,_=S._viewport,t=function p(S,d,_){const t=_.map(function(A,l){return{x1:A.left,y1:A.top,x2:A.right,y2:A.bottom,index:l,x1New:void 0,x2New:void 0}});n(S,t);const i=new Array(_.length);for(const A of t)i[A.index]={left:A.x1New,top:0,right:A.x2New,bottom:0};_.map(function(A,l){const m=i[l],x=t[l];x.x1=A.top,x.y1=S-m.right,x.x2=A.bottom,x.y2=S-m.left,x.index=l,x.x1New=void 0,x.x2New=void 0}),n(d,t);for(const A of t){const l=A.index;i[l].top=A.x1New,i[l].bottom=A.x2New}return i}(_.width,_.height,d);for(let i=0;i<t.length;i++){const A=d[i].div,l=S._textDivProperties.get(A);if(0===l.angle){l.paddingLeft=d[i].left-t[i].left,l.paddingTop=d[i].top-t[i].top,l.paddingRight=t[i].right-d[i].right,l.paddingBottom=t[i].bottom-d[i].bottom,S._textDivProperties.set(A,l);continue}const m=t[i],x=d[i],M=x.m,k=M[0],I=M[1],j=[[0,0],[0,x.size[1]],[x.size[0],0],x.size],X=new Float64Array(64);for(let N=0,$=j.length;N<$;N++){const K=y.Util.applyTransform(j[N],M);X[N+0]=k&&(m.left-K[0])/k,X[N+4]=I&&(m.top-K[1])/I,X[N+8]=k&&(m.right-K[0])/k,X[N+12]=I&&(m.bottom-K[1])/I,X[N+16]=I&&(m.left-K[0])/-I,X[N+20]=k&&(m.top-K[1])/k,X[N+24]=I&&(m.right-K[0])/-I,X[N+28]=k&&(m.bottom-K[1])/k,X[N+32]=k&&(m.left-K[0])/-k,X[N+36]=I&&(m.top-K[1])/-I,X[N+40]=k&&(m.right-K[0])/-k,X[N+44]=I&&(m.bottom-K[1])/-I,X[N+48]=I&&(m.left-K[0])/I,X[N+52]=k&&(m.top-K[1])/-k,X[N+56]=I&&(m.right-K[0])/I,X[N+60]=k&&(m.bottom-K[1])/-k}const J=1+Math.min(Math.abs(k),Math.abs(I));l.paddingLeft=f(X,32,16)/J,l.paddingTop=f(X,48,16)/J,l.paddingRight=f(X,0,16)/J,l.paddingBottom=f(X,16,16)/J,S._textDivProperties.set(A,l)}}(this),this._bounds=null);const _=[],t=[];for(let i=0,A=this._textDivs.length;i<A;i++){const l=this._textDivs[i],m=this._textDivProperties.get(l);!m.hasText||(d?(_.length=0,t.length=0,m.originalTransform&&_.push(m.originalTransform),m.paddingTop>0?(t.push(`${m.paddingTop}px`),_.push(`translateY(${-m.paddingTop}px)`)):t.push(0),t.push(m.paddingRight>0?m.paddingRight/m.scale+"px":0),t.push(m.paddingBottom>0?`${m.paddingBottom}px`:0),m.paddingLeft>0?(t.push(m.paddingLeft/m.scale+"px"),_.push(`translateX(${-m.paddingLeft/m.scale}px)`)):t.push(0),l.style.padding=t.join(" "),_.length&&(l.style.transform=_.join(" "))):(l.style.padding=null,l.style.transform=m.originalTransform))}}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.SVGGraphics=void 0;var y=ne(1),oe=ne(5),G=ne(3);let H=class{constructor(){(0,y.unreachable)("Not implemented: SVGGraphics")}};L.SVGGraphics=H;{let n=function(t){let i=[];const A=[];for(const l of t)"save"!==l.fn?"restore"===l.fn?i=A.pop():i.push(l):(i.push({fnId:92,fn:"group",items:[]}),A.push(i),i=i[i.length-1].items);return i},s=function(t){if(Number.isInteger(t))return t.toString();const i=t.toFixed(10);let A=i.length-1;if("0"!==i[A])return i;do{A--}while("0"===i[A]);return i.substring(0,"."===i[A]?A:A+1)},u=function(t){if(0===t[4]&&0===t[5]){if(0===t[1]&&0===t[2])return 1===t[0]&&1===t[3]?"":`scale(${s(t[0])} ${s(t[3])})`;if(t[0]===t[3]&&t[1]===-t[2]){const i=180*Math.acos(t[0])/Math.PI;return`rotate(${s(i)})`}}else if(1===t[0]&&0===t[1]&&0===t[2]&&1===t[3])return`translate(${s(t[4])} ${s(t[5])})`;return`matrix(${s(t[0])} ${s(t[1])} ${s(t[2])} ${s(t[3])} ${s(t[4])} ${s(t[5])})`};const W={fontStyle:"normal",fontWeight:"normal",fillColor:"#000000"},O="http://www.w3.org/XML/1998/namespace",a="http://www.w3.org/1999/xlink",v=["butt","round","square"],g=["miter","round","bevel"],f=function(t,i="",A=!1){if(URL.createObjectURL&&typeof Blob<"u"&&!A)return URL.createObjectURL(new Blob([t],{type:i}));const l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";let m=`data:${i};base64,`;for(let x=0,M=t.length;x<M;x+=3){const k=255&t[x],I=255&t[x+1],j=255&t[x+2];m+=l[k>>2]+l[(3&k)<<4|I>>4]+l[x+1<M?(15&I)<<2|j>>6:64]+l[x+2<M?63&j:64]}return m},r=function(){const t=new Uint8Array([137,80,78,71,13,10,26,10]),A=new Int32Array(256);for(let j=0;j<256;j++){let X=j;for(let J=0;J<8;J++)X=1&X?3988292384^X>>1&2147483647:X>>1&2147483647;A[j]=X}function m(j,X,J,N){let $=N;const K=X.length;J[$]=K>>24&255,J[$+1]=K>>16&255,J[$+2]=K>>8&255,J[$+3]=255&K,$+=4,J[$]=255&j.charCodeAt(0),J[$+1]=255&j.charCodeAt(1),J[$+2]=255&j.charCodeAt(2),J[$+3]=255&j.charCodeAt(3),$+=4,J.set(X,$),$+=X.length;const te=function l(j,X,J){let N=-1;for(let $=X;$<J;$++)N=N>>>8^A[255&(N^j[$])];return-1^N}(J,N+4,$);J[$]=te>>24&255,J[$+1]=te>>16&255,J[$+2]=te>>8&255,J[$+3]=255&te}function k(j){let X=j.length;const J=65535,N=Math.ceil(X/J),$=new Uint8Array(2+X+5*N+4);let K=0;$[K++]=120,$[K++]=156;let te=0;for(;X>J;)$[K++]=0,$[K++]=255,$[K++]=255,$[K++]=0,$[K++]=0,$.set(j.subarray(te,te+J),K),K+=J,te+=J,X-=J;$[K++]=1,$[K++]=255&X,$[K++]=X>>8&255,$[K++]=255&~X,$[K++]=(65535&~X)>>8&255,$.set(j.subarray(te),K),K+=j.length-te;const se=function x(j,X,J){let N=1,$=0;for(let K=X;K<J;++K)N=(N+(255&j[K]))%65521,$=($+N)%65521;return $<<16|N}(j,0,j.length);return $[K++]=se>>24&255,$[K++]=se>>16&255,$[K++]=se>>8&255,$[K++]=255&se,$}return function(X,J,N){return function I(j,X,J,N){const $=j.width,K=j.height;let te,se,T;const o=j.data;switch(X){case y.ImageKind.GRAYSCALE_1BPP:se=0,te=1,T=$+7>>3;break;case y.ImageKind.RGB_24BPP:se=2,te=8,T=3*$;break;case y.ImageKind.RGBA_32BPP:se=6,te=8,T=4*$;break;default:throw new Error("invalid format")}const h=new Uint8Array((1+T)*K);let e=0,c=0;for(let U=0;U<K;++U)h[e++]=0,h.set(o.subarray(c,c+T),e),c+=T,e+=T;if(X===y.ImageKind.GRAYSCALE_1BPP&&N){e=0;for(let U=0;U<K;U++){e++;for(let V=0;V<T;V++)h[e++]^=255}}const b=new Uint8Array([$>>24&255,$>>16&255,$>>8&255,255&$,K>>24&255,K>>16&255,K>>8&255,255&K,te,se,0,0,0]),w=function M(j){if(!G.isNodeJS)return k(j);try{let X;X=parseInt(process.versions.node)>=8?j:Buffer.from(j);const J=__webpack_require__(2258).deflateSync(X,{level:9});return J instanceof Uint8Array?J:new Uint8Array(J)}catch(X){(0,y.warn)("Not compressing PNG because zlib.deflateSync is unavailable: "+X)}return k(j)}(h),E=new Uint8Array(t.length+36+b.length+w.length);let B=0;return E.set(t,B),B+=t.length,m("IHDR",b,E,B),B+=12+b.length,m("IDATA",w,E,B),B+=12+w.length,m("IEND",new Uint8Array(0),E,B),f(E,"image/png",J)}(X,void 0===X.kind?y.ImageKind.GRAYSCALE_1BPP:X.kind,J,N)}}();class p{constructor(){this.fontSizeScale=1,this.fontWeight=W.fontWeight,this.fontSize=0,this.textMatrix=y.IDENTITY_MATRIX,this.fontMatrix=y.FONT_IDENTITY_MATRIX,this.leading=0,this.textRenderingMode=y.TextRenderingMode.FILL,this.textMatrixScale=1,this.x=0,this.y=0,this.lineX=0,this.lineY=0,this.charSpacing=0,this.wordSpacing=0,this.textHScale=1,this.textRise=0,this.fillColor=W.fillColor,this.strokeColor="#000000",this.fillAlpha=1,this.strokeAlpha=1,this.lineWidth=1,this.lineJoin="",this.lineCap="",this.miterLimit=0,this.dashArray=[],this.dashPhase=0,this.dependencies=[],this.activeClipUrl=null,this.clipGroup=null,this.maskId=""}clone(){return Object.create(this)}setCurrentPoint(i,A){this.x=i,this.y=A}}let S=0,d=0,_=0;L.SVGGraphics=H=class{constructor(t,i,A=!1){this.svgFactory=new oe.DOMSVGFactory,this.current=new p,this.transformMatrix=y.IDENTITY_MATRIX,this.transformStack=[],this.extraStack=[],this.commonObjs=t,this.objs=i,this.pendingClip=null,this.pendingEOFill=!1,this.embedFonts=!1,this.embeddedFonts=Object.create(null),this.cssStyle=null,this.forceDataSchema=!!A,this._operatorIdMapping=[];for(const l in y.OPS)this._operatorIdMapping[y.OPS[l]]=l}save(){this.transformStack.push(this.transformMatrix);const t=this.current;this.extraStack.push(t),this.current=t.clone()}restore(){this.transformMatrix=this.transformStack.pop(),this.current=this.extraStack.pop(),this.pendingClip=null,this.tgrp=null}group(t){this.save(),this.executeOpTree(t),this.restore()}loadDependencies(t){const i=t.fnArray,A=t.argsArray;for(let l=0,m=i.length;l<m;l++)if(i[l]===y.OPS.dependency)for(const x of A[l]){const M=x.startsWith("g_")?this.commonObjs:this.objs,k=new Promise(I=>{M.get(x,I)});this.current.dependencies.push(k)}return Promise.all(this.current.dependencies)}transform(t,i,A,l,m,x){this.transformMatrix=y.Util.transform(this.transformMatrix,[t,i,A,l,m,x]),this.tgrp=null}getSVG(t,i){this.viewport=i;const A=this._initialize(i);return this.loadDependencies(t).then(()=>(this.transformMatrix=y.IDENTITY_MATRIX,this.executeOpTree(this.convertOpList(t)),A))}convertOpList(t){const i=this._operatorIdMapping,A=t.argsArray,l=t.fnArray,m=[];for(let x=0,M=l.length;x<M;x++){const k=l[x];m.push({fnId:k,fn:i[k],args:A[x]})}return n(m)}executeOpTree(t){for(const i of t){const A=i.fn,m=i.args;switch(0|i.fnId){case y.OPS.beginText:this.beginText();break;case y.OPS.dependency:break;case y.OPS.setLeading:this.setLeading(m);break;case y.OPS.setLeadingMoveText:this.setLeadingMoveText(m[0],m[1]);break;case y.OPS.setFont:this.setFont(m);break;case y.OPS.showText:case y.OPS.showSpacedText:this.showText(m[0]);break;case y.OPS.endText:this.endText();break;case y.OPS.moveText:this.moveText(m[0],m[1]);break;case y.OPS.setCharSpacing:this.setCharSpacing(m[0]);break;case y.OPS.setWordSpacing:this.setWordSpacing(m[0]);break;case y.OPS.setHScale:this.setHScale(m[0]);break;case y.OPS.setTextMatrix:this.setTextMatrix(m[0],m[1],m[2],m[3],m[4],m[5]);break;case y.OPS.setTextRise:this.setTextRise(m[0]);break;case y.OPS.setTextRenderingMode:this.setTextRenderingMode(m[0]);break;case y.OPS.setLineWidth:this.setLineWidth(m[0]);break;case y.OPS.setLineJoin:this.setLineJoin(m[0]);break;case y.OPS.setLineCap:this.setLineCap(m[0]);break;case y.OPS.setMiterLimit:this.setMiterLimit(m[0]);break;case y.OPS.setFillRGBColor:this.setFillRGBColor(m[0],m[1],m[2]);break;case y.OPS.setStrokeRGBColor:this.setStrokeRGBColor(m[0],m[1],m[2]);break;case y.OPS.setStrokeColorN:this.setStrokeColorN(m);break;case y.OPS.setFillColorN:this.setFillColorN(m);break;case y.OPS.shadingFill:this.shadingFill(m[0]);break;case y.OPS.setDash:this.setDash(m[0],m[1]);break;case y.OPS.setRenderingIntent:this.setRenderingIntent(m[0]);break;case y.OPS.setFlatness:this.setFlatness(m[0]);break;case y.OPS.setGState:this.setGState(m[0]);break;case y.OPS.fill:this.fill();break;case y.OPS.eoFill:this.eoFill();break;case y.OPS.stroke:this.stroke();break;case y.OPS.fillStroke:this.fillStroke();break;case y.OPS.eoFillStroke:this.eoFillStroke();break;case y.OPS.clip:this.clip("nonzero");break;case y.OPS.eoClip:this.clip("evenodd");break;case y.OPS.paintSolidColorImageMask:this.paintSolidColorImageMask();break;case y.OPS.paintImageXObject:this.paintImageXObject(m[0]);break;case y.OPS.paintInlineImageXObject:this.paintInlineImageXObject(m[0]);break;case y.OPS.paintImageMaskXObject:this.paintImageMaskXObject(m[0]);break;case y.OPS.paintFormXObjectBegin:this.paintFormXObjectBegin(m[0],m[1]);break;case y.OPS.paintFormXObjectEnd:this.paintFormXObjectEnd();break;case y.OPS.closePath:this.closePath();break;case y.OPS.closeStroke:this.closeStroke();break;case y.OPS.closeFillStroke:this.closeFillStroke();break;case y.OPS.closeEOFillStroke:this.closeEOFillStroke();break;case y.OPS.nextLine:this.nextLine();break;case y.OPS.transform:this.transform(m[0],m[1],m[2],m[3],m[4],m[5]);break;case y.OPS.constructPath:this.constructPath(m[0],m[1]);break;case y.OPS.endPath:this.endPath();break;case 92:this.group(i.items);break;default:(0,y.warn)(`Unimplemented operator ${A}`)}}}setWordSpacing(t){this.current.wordSpacing=t}setCharSpacing(t){this.current.charSpacing=t}nextLine(){this.moveText(0,this.current.leading)}setTextMatrix(t,i,A,l,m,x){const M=this.current;M.textMatrix=M.lineMatrix=[t,i,A,l,m,x],M.textMatrixScale=Math.hypot(t,i),M.x=M.lineX=0,M.y=M.lineY=0,M.xcoords=[],M.ycoords=[],M.tspan=this.svgFactory.createElement("svg:tspan"),M.tspan.setAttributeNS(null,"font-family",M.fontFamily),M.tspan.setAttributeNS(null,"font-size",`${s(M.fontSize)}px`),M.tspan.setAttributeNS(null,"y",s(-M.y)),M.txtElement=this.svgFactory.createElement("svg:text"),M.txtElement.appendChild(M.tspan)}beginText(){const t=this.current;t.x=t.lineX=0,t.y=t.lineY=0,t.textMatrix=y.IDENTITY_MATRIX,t.lineMatrix=y.IDENTITY_MATRIX,t.textMatrixScale=1,t.tspan=this.svgFactory.createElement("svg:tspan"),t.txtElement=this.svgFactory.createElement("svg:text"),t.txtgrp=this.svgFactory.createElement("svg:g"),t.xcoords=[],t.ycoords=[]}moveText(t,i){const A=this.current;A.x=A.lineX+=t,A.y=A.lineY+=i,A.xcoords=[],A.ycoords=[],A.tspan=this.svgFactory.createElement("svg:tspan"),A.tspan.setAttributeNS(null,"font-family",A.fontFamily),A.tspan.setAttributeNS(null,"font-size",`${s(A.fontSize)}px`),A.tspan.setAttributeNS(null,"y",s(-A.y))}showText(t){const i=this.current,A=i.font,l=i.fontSize;if(0===l)return;const m=i.fontSizeScale,x=i.charSpacing,M=i.wordSpacing,k=i.fontDirection,I=i.textHScale*k,j=A.vertical,X=j?1:-1,J=A.defaultVMetrics,N=l*i.fontMatrix[0];let $=0;for(const se of t){if(null===se){$+=k*M;continue}if("number"==typeof se){$+=X*se*l/1e3;continue}const T=(se.isSpace?M:0)+x,o=se.fontChar;let h,e,b,c=se.width;if(j){let w;const C=se.vmetric||J;w=se.vmetric?C[1]:.5*c,w=-w*N,c=C?-C[0]:c,h=w/m,e=($+C[2]*N)/m}else h=$/m,e=0;(se.isInFont||A.missingFile)&&(i.xcoords.push(i.x+h),j&&i.ycoords.push(-i.y+e),i.tspan.textContent+=o),b=j?c*N-T*k:c*N+T*k,$+=b}i.tspan.setAttributeNS(null,"x",i.xcoords.map(s).join(" ")),i.tspan.setAttributeNS(null,"y",j?i.ycoords.map(s).join(" "):s(-i.y)),j?i.y-=$:i.x+=$*I,i.tspan.setAttributeNS(null,"font-family",i.fontFamily),i.tspan.setAttributeNS(null,"font-size",`${s(i.fontSize)}px`),i.fontStyle!==W.fontStyle&&i.tspan.setAttributeNS(null,"font-style",i.fontStyle),i.fontWeight!==W.fontWeight&&i.tspan.setAttributeNS(null,"font-weight",i.fontWeight);const K=i.textRenderingMode&y.TextRenderingMode.FILL_STROKE_MASK;K===y.TextRenderingMode.FILL||K===y.TextRenderingMode.FILL_STROKE?(i.fillColor!==W.fillColor&&i.tspan.setAttributeNS(null,"fill",i.fillColor),i.fillAlpha<1&&i.tspan.setAttributeNS(null,"fill-opacity",i.fillAlpha)):i.tspan.setAttributeNS(null,"fill",i.textRenderingMode===y.TextRenderingMode.ADD_TO_PATH?"transparent":"none"),(K===y.TextRenderingMode.STROKE||K===y.TextRenderingMode.FILL_STROKE)&&this._setStrokeAttributes(i.tspan,1/(i.textMatrixScale||1));let te=i.textMatrix;0!==i.textRise&&(te=te.slice(),te[5]+=i.textRise),i.txtElement.setAttributeNS(null,"transform",`${u(te)} scale(${s(I)}, -1)`),i.txtElement.setAttributeNS(O,"xml:space","preserve"),i.txtElement.appendChild(i.tspan),i.txtgrp.appendChild(i.txtElement),this._ensureTransformGroup().appendChild(i.txtElement)}setLeadingMoveText(t,i){this.setLeading(-i),this.moveText(t,i)}addFontStyle(t){if(!t.data)throw new Error('addFontStyle: No font data available, ensure that the "fontExtraProperties" API parameter is set.');this.cssStyle||(this.cssStyle=this.svgFactory.createElement("svg:style"),this.cssStyle.setAttributeNS(null,"type","text/css"),this.defs.appendChild(this.cssStyle));const i=f(t.data,t.mimetype,this.forceDataSchema);this.cssStyle.textContent+=`@font-face { font-family: "${t.loadedName}"; src: url(${i}); }\n`}setFont(t){const i=this.current,A=this.commonObjs.get(t[0]);let l=t[1];i.font=A,this.embedFonts&&!A.missingFile&&!this.embeddedFonts[A.loadedName]&&(this.addFontStyle(A),this.embeddedFonts[A.loadedName]=A),i.fontMatrix=A.fontMatrix||y.FONT_IDENTITY_MATRIX;let m="normal";A.black?m="900":A.bold&&(m="bold");const x=A.italic?"italic":"normal";l<0?(l=-l,i.fontDirection=-1):i.fontDirection=1,i.fontSize=l,i.fontFamily=A.loadedName,i.fontWeight=m,i.fontStyle=x,i.tspan=this.svgFactory.createElement("svg:tspan"),i.tspan.setAttributeNS(null,"y",s(-i.y)),i.xcoords=[],i.ycoords=[]}endText(){const t=this.current;t.textRenderingMode&y.TextRenderingMode.ADD_TO_PATH_FLAG&&t.txtElement?.hasChildNodes()&&(t.element=t.txtElement,this.clip("nonzero"),this.endPath())}setLineWidth(t){t>0&&(this.current.lineWidth=t)}setLineCap(t){this.current.lineCap=v[t]}setLineJoin(t){this.current.lineJoin=g[t]}setMiterLimit(t){this.current.miterLimit=t}setStrokeAlpha(t){this.current.strokeAlpha=t}setStrokeRGBColor(t,i,A){this.current.strokeColor=y.Util.makeHexColor(t,i,A)}setFillAlpha(t){this.current.fillAlpha=t}setFillRGBColor(t,i,A){this.current.fillColor=y.Util.makeHexColor(t,i,A),this.current.tspan=this.svgFactory.createElement("svg:tspan"),this.current.xcoords=[],this.current.ycoords=[]}setStrokeColorN(t){this.current.strokeColor=this._makeColorN_Pattern(t)}setFillColorN(t){this.current.fillColor=this._makeColorN_Pattern(t)}shadingFill(t){const i=this.viewport.width,A=this.viewport.height,l=y.Util.inverseTransform(this.transformMatrix),m=y.Util.applyTransform([0,0],l),x=y.Util.applyTransform([0,A],l),M=y.Util.applyTransform([i,0],l),k=y.Util.applyTransform([i,A],l),I=Math.min(m[0],x[0],M[0],k[0]),j=Math.min(m[1],x[1],M[1],k[1]),X=Math.max(m[0],x[0],M[0],k[0]),J=Math.max(m[1],x[1],M[1],k[1]),N=this.svgFactory.createElement("svg:rect");N.setAttributeNS(null,"x",I),N.setAttributeNS(null,"y",j),N.setAttributeNS(null,"width",X-I),N.setAttributeNS(null,"height",J-j),N.setAttributeNS(null,"fill",this._makeShadingPattern(t)),this.current.fillAlpha<1&&N.setAttributeNS(null,"fill-opacity",this.current.fillAlpha),this._ensureTransformGroup().appendChild(N)}_makeColorN_Pattern(t){return"TilingPattern"===t[0]?this._makeTilingPattern(t):this._makeShadingPattern(t)}_makeTilingPattern(t){const i=t[1],A=t[2],l=t[3]||y.IDENTITY_MATRIX,[m,x,M,k]=t[4],I=t[5],j=t[6],X=t[7],J="shading"+_++,[N,$,K,te]=y.Util.normalizeRect([...y.Util.applyTransform([m,x],l),...y.Util.applyTransform([M,k],l)]),[se,T]=y.Util.singularValueDecompose2dScale(l),o=I*se,h=j*T,e=this.svgFactory.createElement("svg:pattern");e.setAttributeNS(null,"id",J),e.setAttributeNS(null,"patternUnits","userSpaceOnUse"),e.setAttributeNS(null,"width",o),e.setAttributeNS(null,"height",h),e.setAttributeNS(null,"x",`${N}`),e.setAttributeNS(null,"y",`${$}`);const c=this.svg,b=this.transformMatrix,w=this.current.fillColor,C=this.current.strokeColor,E=this.svgFactory.create(K-N,te-$);if(this.svg=E,this.transformMatrix=l,2===X){const B=y.Util.makeHexColor(...i);this.current.fillColor=B,this.current.strokeColor=B}return this.executeOpTree(this.convertOpList(A)),this.svg=c,this.transformMatrix=b,this.current.fillColor=w,this.current.strokeColor=C,e.appendChild(E.childNodes[0]),this.defs.appendChild(e),`url(#${J})`}_makeShadingPattern(t){switch("string"==typeof t&&(t=this.objs.get(t)),t[0]){case"RadialAxial":const i="shading"+_++,A=t[3];let l;switch(t[1]){case"axial":const m=t[4],x=t[5];l=this.svgFactory.createElement("svg:linearGradient"),l.setAttributeNS(null,"id",i),l.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),l.setAttributeNS(null,"x1",m[0]),l.setAttributeNS(null,"y1",m[1]),l.setAttributeNS(null,"x2",x[0]),l.setAttributeNS(null,"y2",x[1]);break;case"radial":const M=t[4],k=t[5],I=t[6],j=t[7];l=this.svgFactory.createElement("svg:radialGradient"),l.setAttributeNS(null,"id",i),l.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),l.setAttributeNS(null,"cx",k[0]),l.setAttributeNS(null,"cy",k[1]),l.setAttributeNS(null,"r",j),l.setAttributeNS(null,"fx",M[0]),l.setAttributeNS(null,"fy",M[1]),l.setAttributeNS(null,"fr",I);break;default:throw new Error(`Unknown RadialAxial type: ${t[1]}`)}for(const m of A){const x=this.svgFactory.createElement("svg:stop");x.setAttributeNS(null,"offset",m[0]),x.setAttributeNS(null,"stop-color",m[1]),l.appendChild(x)}return this.defs.appendChild(l),`url(#${i})`;case"Mesh":return(0,y.warn)("Unimplemented pattern Mesh"),null;case"Dummy":return"hotpink";default:throw new Error(`Unknown IR type: ${t[0]}`)}}setDash(t,i){this.current.dashArray=t,this.current.dashPhase=i}constructPath(t,i){const A=this.current;let l=A.x,m=A.y,x=[],M=0;for(const k of t)switch(0|k){case y.OPS.rectangle:l=i[M++],m=i[M++];const X=l+i[M++],J=m+i[M++];x.push("M",s(l),s(m),"L",s(X),s(m),"L",s(X),s(J),"L",s(l),s(J),"Z");break;case y.OPS.moveTo:l=i[M++],m=i[M++],x.push("M",s(l),s(m));break;case y.OPS.lineTo:l=i[M++],m=i[M++],x.push("L",s(l),s(m));break;case y.OPS.curveTo:l=i[M+4],m=i[M+5],x.push("C",s(i[M]),s(i[M+1]),s(i[M+2]),s(i[M+3]),s(l),s(m)),M+=6;break;case y.OPS.curveTo2:x.push("C",s(l),s(m),s(i[M]),s(i[M+1]),s(i[M+2]),s(i[M+3])),l=i[M+2],m=i[M+3],M+=4;break;case y.OPS.curveTo3:l=i[M+2],m=i[M+3],x.push("C",s(i[M]),s(i[M+1]),s(l),s(m),s(l),s(m)),M+=4;break;case y.OPS.closePath:x.push("Z")}x=x.join(" "),A.path&&t.length>0&&t[0]!==y.OPS.rectangle&&t[0]!==y.OPS.moveTo?x=A.path.getAttributeNS(null,"d")+x:(A.path=this.svgFactory.createElement("svg:path"),this._ensureTransformGroup().appendChild(A.path)),A.path.setAttributeNS(null,"d",x),A.path.setAttributeNS(null,"fill","none"),A.element=A.path,A.setCurrentPoint(l,m)}endPath(){const t=this.current;if(t.path=null,!this.pendingClip)return;if(!t.element)return void(this.pendingClip=null);const i="clippath"+S++,A=this.svgFactory.createElement("svg:clipPath");A.setAttributeNS(null,"id",i),A.setAttributeNS(null,"transform",u(this.transformMatrix));const l=t.element.cloneNode(!0);if(l.setAttributeNS(null,"clip-rule","evenodd"===this.pendingClip?"evenodd":"nonzero"),this.pendingClip=null,A.appendChild(l),this.defs.appendChild(A),t.activeClipUrl){t.clipGroup=null;for(const m of this.extraStack)m.clipGroup=null;A.setAttributeNS(null,"clip-path",t.activeClipUrl)}t.activeClipUrl=`url(#${i})`,this.tgrp=null}clip(t){this.pendingClip=t}closePath(){const t=this.current;if(t.path){const i=`${t.path.getAttributeNS(null,"d")}Z`;t.path.setAttributeNS(null,"d",i)}}setLeading(t){this.current.leading=-t}setTextRise(t){this.current.textRise=t}setTextRenderingMode(t){this.current.textRenderingMode=t}setHScale(t){this.current.textHScale=t/100}setRenderingIntent(t){}setFlatness(t){}setGState(t){for(const[i,A]of t)switch(i){case"LW":this.setLineWidth(A);break;case"LC":this.setLineCap(A);break;case"LJ":this.setLineJoin(A);break;case"ML":this.setMiterLimit(A);break;case"D":this.setDash(A[0],A[1]);break;case"RI":this.setRenderingIntent(A);break;case"FL":this.setFlatness(A);break;case"Font":this.setFont(A);break;case"CA":this.setStrokeAlpha(A);break;case"ca":this.setFillAlpha(A);break;default:(0,y.warn)(`Unimplemented graphic state operator ${i}`)}}fill(){const t=this.current;t.element&&(t.element.setAttributeNS(null,"fill",t.fillColor),t.element.setAttributeNS(null,"fill-opacity",t.fillAlpha),this.endPath())}stroke(){const t=this.current;t.element&&(this._setStrokeAttributes(t.element),t.element.setAttributeNS(null,"fill","none"),this.endPath())}_setStrokeAttributes(t,i=1){const A=this.current;let l=A.dashArray;1!==i&&l.length>0&&(l=l.map(function(m){return i*m})),t.setAttributeNS(null,"stroke",A.strokeColor),t.setAttributeNS(null,"stroke-opacity",A.strokeAlpha),t.setAttributeNS(null,"stroke-miterlimit",s(A.miterLimit)),t.setAttributeNS(null,"stroke-linecap",A.lineCap),t.setAttributeNS(null,"stroke-linejoin",A.lineJoin),t.setAttributeNS(null,"stroke-width",s(i*A.lineWidth)+"px"),t.setAttributeNS(null,"stroke-dasharray",l.map(s).join(" ")),t.setAttributeNS(null,"stroke-dashoffset",s(i*A.dashPhase)+"px")}eoFill(){this.current.element&&this.current.element.setAttributeNS(null,"fill-rule","evenodd"),this.fill()}fillStroke(){this.stroke(),this.fill()}eoFillStroke(){this.current.element&&this.current.element.setAttributeNS(null,"fill-rule","evenodd"),this.fillStroke()}closeStroke(){this.closePath(),this.stroke()}closeFillStroke(){this.closePath(),this.fillStroke()}closeEOFillStroke(){this.closePath(),this.eoFillStroke()}paintSolidColorImageMask(){const t=this.svgFactory.createElement("svg:rect");t.setAttributeNS(null,"x","0"),t.setAttributeNS(null,"y","0"),t.setAttributeNS(null,"width","1px"),t.setAttributeNS(null,"height","1px"),t.setAttributeNS(null,"fill",this.current.fillColor),this._ensureTransformGroup().appendChild(t)}paintImageXObject(t){const i=t.startsWith("g_")?this.commonObjs.get(t):this.objs.get(t);i?this.paintInlineImageXObject(i):(0,y.warn)(`Dependent image with object ID ${t} is not ready yet`)}paintInlineImageXObject(t,i){const A=t.width,l=t.height,m=r(t,this.forceDataSchema,!!i),x=this.svgFactory.createElement("svg:rect");x.setAttributeNS(null,"x","0"),x.setAttributeNS(null,"y","0"),x.setAttributeNS(null,"width",s(A)),x.setAttributeNS(null,"height",s(l)),this.current.element=x,this.clip("nonzero");const M=this.svgFactory.createElement("svg:image");M.setAttributeNS(a,"xlink:href",m),M.setAttributeNS(null,"x","0"),M.setAttributeNS(null,"y",s(-l)),M.setAttributeNS(null,"width",s(A)+"px"),M.setAttributeNS(null,"height",s(l)+"px"),M.setAttributeNS(null,"transform",`scale(${s(1/A)} ${s(-1/l)})`),i?i.appendChild(M):this._ensureTransformGroup().appendChild(M)}paintImageMaskXObject(t){const i=this.current,A=t.width,l=t.height,m=i.fillColor;i.maskId="mask"+d++;const x=this.svgFactory.createElement("svg:mask");x.setAttributeNS(null,"id",i.maskId);const M=this.svgFactory.createElement("svg:rect");M.setAttributeNS(null,"x","0"),M.setAttributeNS(null,"y","0"),M.setAttributeNS(null,"width",s(A)),M.setAttributeNS(null,"height",s(l)),M.setAttributeNS(null,"fill",m),M.setAttributeNS(null,"mask",`url(#${i.maskId})`),this.defs.appendChild(x),this._ensureTransformGroup().appendChild(M),this.paintInlineImageXObject(t,x)}paintFormXObjectBegin(t,i){if(Array.isArray(t)&&6===t.length&&this.transform(t[0],t[1],t[2],t[3],t[4],t[5]),i){const A=i[2]-i[0],l=i[3]-i[1],m=this.svgFactory.createElement("svg:rect");m.setAttributeNS(null,"x",i[0]),m.setAttributeNS(null,"y",i[1]),m.setAttributeNS(null,"width",s(A)),m.setAttributeNS(null,"height",s(l)),this.current.element=m,this.clip("nonzero"),this.endPath()}}paintFormXObjectEnd(){}_initialize(t){const i=this.svgFactory.create(t.width,t.height),A=this.svgFactory.createElement("svg:defs");i.appendChild(A),this.defs=A;const l=this.svgFactory.createElement("svg:g");return l.setAttributeNS(null,"transform",u(t.transform)),i.appendChild(l),this.svg=l,i}_ensureClipGroup(){if(!this.current.clipGroup){const t=this.svgFactory.createElement("svg:g");t.setAttributeNS(null,"clip-path",this.current.activeClipUrl),this.svg.appendChild(t),this.current.clipGroup=t}return this.current.clipGroup}_ensureTransformGroup(){return this.tgrp||(this.tgrp=this.svgFactory.createElement("svg:g"),this.tgrp.setAttributeNS(null,"transform",u(this.transformMatrix)),this.current.activeClipUrl?this._ensureClipGroup().appendChild(this.tgrp):this.svg.appendChild(this.tgrp)),this.tgrp}}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.PDFNodeStream=void 0;var y=ne(1),oe=ne(26);const G=__webpack_require__(172),H=__webpack_require__(2001),W=__webpack_require__(3779),O=__webpack_require__(6558),a=/^file:\/\/\/[a-zA-Z]:\//;L.PDFNodeStream=class g{constructor(_){this.source=_,this.url=function v(d){const _=O.parse(d);return"file:"===_.protocol||_.host?_:/^[a-z]:[/\\]/i.test(d)?O.parse(`file:///${d}`):(_.host||(_.protocol="file:"),_)}(_.url),this.isHttp="http:"===this.url.protocol||"https:"===this.url.protocol,this.isFsUrl="file:"===this.url.protocol,this.httpHeaders=this.isHttp&&_.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}getFullReader(){return(0,y.assert)(!this._fullRequestReader,"PDFNodeStream.getFullReader can only be called once."),this._fullRequestReader=this.isFsUrl?new u(this):new n(this),this._fullRequestReader}getRangeReader(_,t){if(t<=this._progressiveDataLength)return null;const i=this.isFsUrl?new S(this,_,t):new s(this,_,t);return this._rangeRequestReaders.push(i),i}cancelAllRequests(_){this._fullRequestReader&&this._fullRequestReader.cancel(_);for(const t of this._rangeRequestReaders.slice(0))t.cancel(_)}};class f{constructor(_){this._url=_.url,this._done=!1,this._storedError=null,this.onProgress=null;const t=_.source;this._contentLength=t.length,this._loaded=0,this._filename=null,this._disableRange=t.disableRange||!1,this._rangeChunkSize=t.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._isStreamingSupported=!t.disableStream,this._isRangeSupported=!t.disableRange,this._readableStream=null,this._readCapability=(0,y.createPromiseCapability)(),this._headersCapability=(0,y.createPromiseCapability)()}get headersReady(){return this._headersCapability.promise}get filename(){return this._filename}get contentLength(){return this._contentLength}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}read(){var _=this;return _asyncToGenerator(function*(){if(yield _._readCapability.promise,_._done)return{value:void 0,done:!0};if(_._storedError)throw _._storedError;const t=_._readableStream.read();return null===t?(_._readCapability=(0,y.createPromiseCapability)(),_.read()):(_._loaded+=t.length,_.onProgress&&_.onProgress({loaded:_._loaded,total:_._contentLength}),{value:new Uint8Array(t).buffer,done:!1})})()}cancel(_){this._readableStream?this._readableStream.destroy(_):this._error(_)}_error(_){this._storedError=_,this._readCapability.resolve()}_setReadableStream(_){this._readableStream=_,_.on("readable",()=>{this._readCapability.resolve()}),_.on("end",()=>{_.destroy(),this._done=!0,this._readCapability.resolve()}),_.on("error",t=>{this._error(t)}),!this._isStreamingSupported&&this._isRangeSupported&&this._error(new y.AbortException("streaming is disabled")),this._storedError&&this._readableStream.destroy(this._storedError)}}class r{constructor(_){this._url=_.url,this._done=!1,this._storedError=null,this.onProgress=null,this._loaded=0,this._readableStream=null,this._readCapability=(0,y.createPromiseCapability)(),this._isStreamingSupported=!_.source.disableStream}get isStreamingSupported(){return this._isStreamingSupported}read(){var _=this;return _asyncToGenerator(function*(){if(yield _._readCapability.promise,_._done)return{value:void 0,done:!0};if(_._storedError)throw _._storedError;const t=_._readableStream.read();return null===t?(_._readCapability=(0,y.createPromiseCapability)(),_.read()):(_._loaded+=t.length,_.onProgress&&_.onProgress({loaded:_._loaded}),{value:new Uint8Array(t).buffer,done:!1})})()}cancel(_){this._readableStream?this._readableStream.destroy(_):this._error(_)}_error(_){this._storedError=_,this._readCapability.resolve()}_setReadableStream(_){this._readableStream=_,_.on("readable",()=>{this._readCapability.resolve()}),_.on("end",()=>{_.destroy(),this._done=!0,this._readCapability.resolve()}),_.on("error",t=>{this._error(t)}),this._storedError&&this._readableStream.destroy(this._storedError)}}function p(d,_){return{protocol:d.protocol,auth:d.auth,host:d.hostname,port:d.port,path:d.path,method:"GET",headers:_}}class n extends f{constructor(_){super(_);const t=i=>{if(404===i.statusCode){const x=new y.MissingPDFException(`Missing PDF "${this._url}".`);return this._storedError=x,void this._headersCapability.reject(x)}this._headersCapability.resolve(),this._setReadableStream(i);const A=x=>this._readableStream.headers[x.toLowerCase()],{allowRangeRequests:l,suggestedLength:m}=(0,oe.validateRangeRequestCapabilities)({getResponseHeader:A,isHttp:_.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=l,this._contentLength=m||this._contentLength,this._filename=(0,oe.extractFilenameFromHeader)(A)};this._request=null,this._request="http:"===this._url.protocol?H.request(p(this._url,_.httpHeaders),t):W.request(p(this._url,_.httpHeaders),t),this._request.on("error",i=>{this._storedError=i,this._headersCapability.reject(i)}),this._request.end()}}class s extends r{constructor(_,t,i){super(_),this._httpHeaders={};for(const l in _.httpHeaders){const m=_.httpHeaders[l];typeof m>"u"||(this._httpHeaders[l]=m)}this._httpHeaders.Range=`bytes=${t}-${i-1}`;const A=l=>{if(404!==l.statusCode)this._setReadableStream(l);else{const m=new y.MissingPDFException(`Missing PDF "${this._url}".`);this._storedError=m}};this._request=null,this._request="http:"===this._url.protocol?H.request(p(this._url,this._httpHeaders),A):W.request(p(this._url,this._httpHeaders),A),this._request.on("error",l=>{this._storedError=l}),this._request.end()}}class u extends f{constructor(_){super(_);let t=decodeURIComponent(this._url.path);a.test(this._url.href)&&(t=t.replace(/^\//,"")),G.lstat(t,(i,A)=>{if(i)return"ENOENT"===i.code&&(i=new y.MissingPDFException(`Missing PDF "${t}".`)),this._storedError=i,void this._headersCapability.reject(i);this._contentLength=A.size,this._setReadableStream(G.createReadStream(t)),this._headersCapability.resolve()})}}class S extends r{constructor(_,t,i){super(_);let A=decodeURIComponent(this._url.path);a.test(this._url.href)&&(A=A.replace(/^\//,"")),this._setReadableStream(G.createReadStream(A,{start:t,end:i-1}))}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.createResponseStatusError=function O(v,g){return 404===v||0===v&&g.startsWith("file:")?new y.MissingPDFException('Missing PDF "'+g+'".'):new y.UnexpectedResponseException(`Unexpected server response (${v}) while retrieving PDF "${g}".`,v)},L.extractFilenameFromHeader=function W(v){const g=v("Content-Disposition");if(g){let f=(0,oe.getFilenameFromContentDispositionHeader)(g);if(f.includes("%"))try{f=decodeURIComponent(f)}catch{}if((0,G.isPdfFile)(f))return f}return null},L.validateRangeRequestCapabilities=function H({getResponseHeader:v,isHttp:g,rangeChunkSize:f,disableRange:r}){const p={allowRangeRequests:!1,suggestedLength:void 0},n=parseInt(v("Content-Length"),10);return!Number.isInteger(n)||(p.suggestedLength=n,n<=2*f)||r||!g||"bytes"!==v("Accept-Ranges")||"identity"!==(v("Content-Encoding")||"identity")||(p.allowRangeRequests=!0),p},L.validateResponseStatus=function a(v){return 200===v||206===v};var y=ne(1),oe=ne(27),G=ne(5)},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.getFilenameFromContentDispositionHeader=function oe(G){let H=!0,W=O("filename\\*","i").exec(G);if(W){W=W[1];let n=f(W);return n=unescape(n),n=r(n),n=p(n),v(n)}if(W=function g(n){const s=[];let u;const S=O("filename\\*((?!0\\d)\\d+)(\\*?)","ig");for(;null!==(u=S.exec(n));){let[,_,t,i]=u;if(_=parseInt(_,10),_ in s){if(0===_)break}else s[_]=[t,i]}const d=[];for(let _=0;_<s.length&&_ in s;++_){let[t,i]=s[_];i=f(i),t&&(i=unescape(i),0===_&&(i=r(i))),d.push(i)}return d.join("")}(G),W)return v(p(W));if(W=O("filename","i").exec(G),W){W=W[1];let n=f(W);return n=p(n),v(n)}function O(n,s){return new RegExp("(?:^|;)\\s*"+n+'\\s*=\\s*([^";\\s][^;\\s]*|"(?:[^"\\\\]|\\\\"?)+"?)',s)}function a(n,s){if(n){if(!/^[\x00-\xFF]+$/.test(s))return s;try{const u=new TextDecoder(n,{fatal:!0}),S=(0,y.stringToBytes)(s);s=u.decode(S),H=!1}catch{}}return s}function v(n){return H&&/[\x80-\xff]/.test(n)&&(n=a("utf-8",n),H&&(n=a("iso-8859-1",n))),n}function f(n){if(n.startsWith('"')){const s=n.slice(1).split('\\"');for(let u=0;u<s.length;++u){const S=s[u].indexOf('"');-1!==S&&(s[u]=s[u].slice(0,S),s.length=u+1),s[u]=s[u].replace(/\\(.)/g,"$1")}n=s.join('"')}return n}function r(n){const s=n.indexOf("'");return-1===s?n:a(n.slice(0,s),n.slice(s+1).replace(/^[^']*'/,""))}function p(n){return!n.startsWith("=?")||/[\x00-\x19\x80-\xff]/.test(n)?n:n.replace(/=\?([\w-]*)\?([QqBb])\?((?:[^?]|\?(?!=))*)\?=/g,function(s,u,S,d){if("q"===S||"Q"===S)return a(u,d=(d=d.replace(/_/g," ")).replace(/=([0-9a-fA-F]{2})/g,function(_,t){return String.fromCharCode(parseInt(t,16))}));try{d=atob(d)}catch{}return a(u,d)})}return""};var y=ne(1)},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.PDFNetworkStream=void 0;var y=ne(1),oe=ne(26);class O{constructor(r,p={}){this.url=r,this.isHttp=/^https?:/i.test(r),this.httpHeaders=this.isHttp&&p.httpHeaders||Object.create(null),this.withCredentials=p.withCredentials||!1,this.getXhr=p.getXhr||function(){return new XMLHttpRequest},this.currXhrId=0,this.pendingRequests=Object.create(null)}requestRange(r,p,n){const s={begin:r,end:p};for(const u in n)s[u]=n[u];return this.request(s)}requestFull(r){return this.request(r)}request(r){const p=this.getXhr(),n=this.currXhrId++,s=this.pendingRequests[n]={xhr:p};p.open("GET",this.url),p.withCredentials=this.withCredentials;for(const u in this.httpHeaders){const S=this.httpHeaders[u];typeof S>"u"||p.setRequestHeader(u,S)}return this.isHttp&&"begin"in r&&"end"in r?(p.setRequestHeader("Range",`bytes=${r.begin}-${r.end-1}`),s.expectedStatus=206):s.expectedStatus=200,p.responseType="arraybuffer",r.onError&&(p.onerror=function(u){r.onError(p.status)}),p.onreadystatechange=this.onStateChange.bind(this,n),p.onprogress=this.onProgress.bind(this,n),s.onHeadersReceived=r.onHeadersReceived,s.onDone=r.onDone,s.onError=r.onError,s.onProgress=r.onProgress,p.send(null),n}onProgress(r,p){const n=this.pendingRequests[r];!n||n.onProgress?.(p)}onStateChange(r,p){const n=this.pendingRequests[r];if(!n)return;const s=n.xhr;if(s.readyState>=2&&n.onHeadersReceived&&(n.onHeadersReceived(),delete n.onHeadersReceived),4!==s.readyState||!(r in this.pendingRequests))return;if(delete this.pendingRequests[r],0===s.status&&this.isHttp)return void n.onError?.(s.status);const u=s.status||200;if((200!==u||206!==n.expectedStatus)&&u!==n.expectedStatus)return void n.onError?.(s.status);const d=function W(f){const r=f.response;return"string"!=typeof r?r:(0,y.stringToBytes)(r).buffer}(s);if(206===u){const _=s.getResponseHeader("Content-Range"),t=/bytes (\d+)-(\d+)\/(\d+)/.exec(_);n.onDone({begin:parseInt(t[1],10),chunk:d})}else d?n.onDone({begin:0,chunk:d}):n.onError?.(s.status)}getRequestXhr(r){return this.pendingRequests[r].xhr}isPendingRequest(r){return r in this.pendingRequests}abortRequest(r){const p=this.pendingRequests[r].xhr;delete this.pendingRequests[r],p.abort()}}L.PDFNetworkStream=class a{constructor(r){this._source=r,this._manager=new O(r.url,{httpHeaders:r.httpHeaders,withCredentials:r.withCredentials}),this._rangeChunkSize=r.rangeChunkSize,this._fullRequestReader=null,this._rangeRequestReaders=[]}_onRangeRequestReaderClosed(r){const p=this._rangeRequestReaders.indexOf(r);p>=0&&this._rangeRequestReaders.splice(p,1)}getFullReader(){return(0,y.assert)(!this._fullRequestReader,"PDFNetworkStream.getFullReader can only be called once."),this._fullRequestReader=new v(this._manager,this._source),this._fullRequestReader}getRangeReader(r,p){const n=new g(this._manager,r,p);return n.onClosed=this._onRangeRequestReaderClosed.bind(this),this._rangeRequestReaders.push(n),n}cancelAllRequests(r){this._fullRequestReader?.cancel(r);for(const p of this._rangeRequestReaders.slice(0))p.cancel(r)}};class v{constructor(r,p){this._manager=r;const n={onHeadersReceived:this._onHeadersReceived.bind(this),onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=p.url,this._fullRequestId=r.requestFull(n),this._headersReceivedCapability=(0,y.createPromiseCapability)(),this._disableRange=p.disableRange||!1,this._contentLength=p.length,this._rangeChunkSize=p.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._isStreamingSupported=!1,this._isRangeSupported=!1,this._cachedChunks=[],this._requests=[],this._done=!1,this._storedError=void 0,this._filename=null,this.onProgress=null}_onHeadersReceived(){const r=this._fullRequestId,p=this._manager.getRequestXhr(r),n=S=>p.getResponseHeader(S),{allowRangeRequests:s,suggestedLength:u}=(0,oe.validateRangeRequestCapabilities)({getResponseHeader:n,isHttp:this._manager.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});s&&(this._isRangeSupported=!0),this._contentLength=u||this._contentLength,this._filename=(0,oe.extractFilenameFromHeader)(n),this._isRangeSupported&&this._manager.abortRequest(r),this._headersReceivedCapability.resolve()}_onDone(r){if(r&&(this._requests.length>0?this._requests.shift().resolve({value:r.chunk,done:!1}):this._cachedChunks.push(r.chunk)),this._done=!0,!(this._cachedChunks.length>0)){for(const p of this._requests)p.resolve({value:void 0,done:!0});this._requests.length=0}}_onError(r){this._storedError=(0,oe.createResponseStatusError)(r,this._url),this._headersReceivedCapability.reject(this._storedError);for(const p of this._requests)p.reject(this._storedError);this._requests.length=0,this._cachedChunks.length=0}_onProgress(r){this.onProgress?.({loaded:r.loaded,total:r.lengthComputable?r.total:this._contentLength})}get filename(){return this._filename}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}get contentLength(){return this._contentLength}get headersReady(){return this._headersReceivedCapability.promise}read(){var r=this;return _asyncToGenerator(function*(){if(r._storedError)throw r._storedError;if(r._cachedChunks.length>0)return{value:r._cachedChunks.shift(),done:!1};if(r._done)return{value:void 0,done:!0};const p=(0,y.createPromiseCapability)();return r._requests.push(p),p.promise})()}cancel(r){this._done=!0,this._headersReceivedCapability.reject(r);for(const p of this._requests)p.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._fullRequestId)&&this._manager.abortRequest(this._fullRequestId),this._fullRequestReader=null}}class g{constructor(r,p,n){this._manager=r;const s={onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=r.url,this._requestId=r.requestRange(p,n,s),this._requests=[],this._queuedChunk=null,this._done=!1,this._storedError=void 0,this.onProgress=null,this.onClosed=null}_close(){this.onClosed?.(this)}_onDone(r){const p=r.chunk;this._requests.length>0?this._requests.shift().resolve({value:p,done:!1}):this._queuedChunk=p,this._done=!0;for(const n of this._requests)n.resolve({value:void 0,done:!0});this._requests.length=0,this._close()}_onError(r){this._storedError=(0,oe.createResponseStatusError)(r,this._url);for(const p of this._requests)p.reject(this._storedError);this._requests.length=0,this._queuedChunk=null}_onProgress(r){this.isStreamingSupported||this.onProgress?.({loaded:r.loaded})}get isStreamingSupported(){return!1}read(){var r=this;return _asyncToGenerator(function*(){if(r._storedError)throw r._storedError;if(null!==r._queuedChunk){const n=r._queuedChunk;return r._queuedChunk=null,{value:n,done:!1}}if(r._done)return{value:void 0,done:!0};const p=(0,y.createPromiseCapability)();return r._requests.push(p),p.promise})()}cancel(r){this._done=!0;for(const p of this._requests)p.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._requestId)&&this._manager.abortRequest(this._requestId),this._close()}}},(ue,L,ne)=>{Object.defineProperty(L,"__esModule",{value:!0}),L.PDFFetchStream=void 0;var y=ne(1),oe=ne(26);function G(v,g,f){return{method:"GET",headers:v,signal:f?.signal,mode:"cors",credentials:g?"include":"same-origin",redirect:"follow"}}function H(v){const g=new Headers;for(const f in v){const r=v[f];typeof r>"u"||g.append(f,r)}return g}L.PDFFetchStream=class W{constructor(g){this.source=g,this.isHttp=/^https?:/i.test(g.url),this.httpHeaders=this.isHttp&&g.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}getFullReader(){return(0,y.assert)(!this._fullRequestReader,"PDFFetchStream.getFullReader can only be called once."),this._fullRequestReader=new O(this),this._fullRequestReader}getRangeReader(g,f){if(f<=this._progressiveDataLength)return null;const r=new a(this,g,f);return this._rangeRequestReaders.push(r),r}cancelAllRequests(g){this._fullRequestReader&&this._fullRequestReader.cancel(g);for(const f of this._rangeRequestReaders.slice(0))f.cancel(g)}};class O{constructor(g){this._stream=g,this._reader=null,this._loaded=0,this._filename=null;const f=g.source;this._withCredentials=f.withCredentials||!1,this._contentLength=f.length,this._headersCapability=(0,y.createPromiseCapability)(),this._disableRange=f.disableRange||!1,this._rangeChunkSize=f.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),typeof AbortController<"u"&&(this._abortController=new AbortController),this._isStreamingSupported=!f.disableStream,this._isRangeSupported=!f.disableRange,this._headers=H(this._stream.httpHeaders);const r=f.url;fetch(r,G(this._headers,this._withCredentials,this._abortController)).then(p=>{if(!(0,oe.validateResponseStatus)(p.status))throw(0,oe.createResponseStatusError)(p.status,r);this._reader=p.body.getReader(),this._headersCapability.resolve();const n=S=>p.headers.get(S),{allowRangeRequests:s,suggestedLength:u}=(0,oe.validateRangeRequestCapabilities)({getResponseHeader:n,isHttp:this._stream.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=s,this._contentLength=u||this._contentLength,this._filename=(0,oe.extractFilenameFromHeader)(n),!this._isStreamingSupported&&this._isRangeSupported&&this.cancel(new y.AbortException("Streaming is disabled."))}).catch(this._headersCapability.reject),this.onProgress=null}get headersReady(){return this._headersCapability.promise}get filename(){return this._filename}get contentLength(){return this._contentLength}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}read(){var g=this;return _asyncToGenerator(function*(){yield g._headersCapability.promise;const{value:f,done:r}=yield g._reader.read();return r?{value:f,done:r}:(g._loaded+=f.byteLength,g.onProgress&&g.onProgress({loaded:g._loaded,total:g._contentLength}),{value:new Uint8Array(f).buffer,done:!1})})()}cancel(g){this._reader&&this._reader.cancel(g),this._abortController&&this._abortController.abort()}}class a{constructor(g,f,r){this._stream=g,this._reader=null,this._loaded=0;const p=g.source;this._withCredentials=p.withCredentials||!1,this._readCapability=(0,y.createPromiseCapability)(),this._isStreamingSupported=!p.disableStream,typeof AbortController<"u"&&(this._abortController=new AbortController),this._headers=H(this._stream.httpHeaders),this._headers.append("Range",`bytes=${f}-${r-1}`);const n=p.url;fetch(n,G(this._headers,this._withCredentials,this._abortController)).then(s=>{if(!(0,oe.validateResponseStatus)(s.status))throw(0,oe.createResponseStatusError)(s.status,n);this._readCapability.resolve(),this._reader=s.body.getReader()}).catch(this._readCapability.reject),this.onProgress=null}get isStreamingSupported(){return this._isStreamingSupported}read(){var g=this;return _asyncToGenerator(function*(){yield g._readCapability.promise;const{value:f,done:r}=yield g._reader.read();return r?{value:f,done:r}:(g._loaded+=f.byteLength,g.onProgress&&g.onProgress({loaded:g._loaded}),{value:new Uint8Array(f).buffer,done:!1})})()}cancel(g){this._reader&&this._reader.cancel(g),this._abortController&&this._abortController.abort()}}}],__webpack_module_cache__={};function __w_pdfjs_require__(ue){var L=__webpack_module_cache__[ue];if(void 0!==L)return L.exports;var ne=__webpack_module_cache__[ue]={exports:{}};return __webpack_modules__[ue](ne,ne.exports,__w_pdfjs_require__),ne.exports}var __webpack_exports__={};return(()=>{var ue=__webpack_exports__;
1Object.defineProperty(ue,"__esModule",{value:!0}),Object.defineProperty(ue,"AnnotationLayer",{enumerable:!0,get:function(){return oe.AnnotationLayer}}),Object.defineProperty(ue,"AnnotationMode",{enumerable:!0,get:function(){return L.AnnotationMode}}),Object.defineProperty(ue,"CMapCompressionType",{enumerable:!0,get:function(){return L.CMapCompressionType}}),Object.defineProperty(ue,"GlobalWorkerOptions",{enumerable:!0,get:function(){return G.GlobalWorkerOptions}}),Object.defineProperty(ue,"InvalidPDFException",{enumerable:!0,get:function(){return L.InvalidPDFException}}),Object.defineProperty(ue,"LoopbackPort",{enumerable:!0,get:function(){return ne.LoopbackPort}}),Object.defineProperty(ue,"MissingPDFException",{enumerable:!0,get:function(){return L.MissingPDFException}}),Object.defineProperty(ue,"OPS",{enumerable:!0,get:function(){return L.OPS}}),Object.defineProperty(ue,"PDFDataRangeTransport",{enumerable:!0,get:function(){return ne.PDFDataRangeTransport}}),Object.defineProperty(ue,"PDFDateString",{enumerable:!0,get:function(){return y.PDFDateString}}),Object.defineProperty(ue,"PDFWorker",{enumerable:!0,get:function(){return ne.PDFWorker}}),Object.defineProperty(ue,"PasswordResponses",{enumerable:!0,get:function(){return L.PasswordResponses}}),Object.defineProperty(ue,"PermissionFlag",{enumerable:!0,get:function(){return L.PermissionFlag}}),Object.defineProperty(ue,"PixelsPerInch",{enumerable:!0,get:function(){return y.PixelsPerInch}}),Object.defineProperty(ue,"RenderingCancelledException",{enumerable:!0,get:function(){return y.RenderingCancelledException}}),Object.defineProperty(ue,"SVGGraphics",{enumerable:!0,get:function(){return O.SVGGraphics}}),Object.defineProperty(ue,"UNSUPPORTED_FEATURES",{enumerable:!0,get:function(){return L.UNSUPPORTED_FEATURES}}),Object.defineProperty(ue,"UnexpectedResponseException",{enumerable:!0,get:function(){return L.UnexpectedResponseException}}),Object.defineProperty(ue,"Util",{enumerable:!0,get:function(){return L.Util}}),Object.defineProperty(ue,"VerbosityLevel",{enumerable:!0,get:function(){return L.VerbosityLevel}}),Object.defineProperty(ue,"XfaLayer",{enumerable:!0,get:function(){return a.XfaLayer}}),Object.defineProperty(ue,"build",{enumerable:!0,get:function(){return ne.build}}),Object.defineProperty(ue,"createPromiseCapability",{enumerable:!0,get:function(){return L.createPromiseCapability}}),Object.defineProperty(ue,"createValidAbsoluteUrl",{enumerable:!0,get:function(){return L.createValidAbsoluteUrl}}),Object.defineProperty(ue,"getDocument",{enumerable:!0,get:function(){return ne.getDocument}}),Object.defineProperty(ue,"getFilenameFromUrl",{enumerable:!0,get:function(){return y.getFilenameFromUrl}}),Object.defineProperty(ue,"getPdfFilenameFromUrl",{enumerable:!0,get:function(){return y.getPdfFilenameFromUrl}}),Object.defineProperty(ue,"getXfaPageViewport",{enumerable:!0,get:function(){return y.getXfaPageViewport}}),Object.defineProperty(ue,"isPdfFile",{enumerable:!0,get:function(){return y.isPdfFile}}),Object.defineProperty(ue,"loadScript",{enumerable:!0,get:function(){return y.loadScript}}),Object.defineProperty(ue,"renderTextLayer",{enumerable:!0,get:function(){return W.renderTextLayer}}),Object.defineProperty(ue,"shadow",{enumerable:!0,get:function(){return L.shadow}}),Object.defineProperty(ue,"version",{enumerable:!0,get:function(){return ne.version}});var L=__w_pdfjs_require__(1),ne=__w_pdfjs_require__(4),y=__w_pdfjs_require__(5),oe=__w_pdfjs_require__(20),G=__w_pdfjs_require__(13),H=__w_pdfjs_require__(3),W=__w_pdfjs_require__(23),O=__w_pdfjs_require__(24),a=__w_pdfjs_require__(22);if(H.isNodeJS){const{PDFNodeStream:f}=__w_pdfjs_require__(25);(0,ne.setPDFNetworkStreamFactory)(r=>new f(r))}else{const{PDFNetworkStream:f}=__w_pdfjs_require__(28),{PDFFetchStream:r}=__w_pdfjs_require__(29);(0,ne.setPDFNetworkStreamFactory)(p=>(0,y.isValidFetchUrl)(p.url)?new r(p):new f(p))}})(),__webpack_exports__})(),module.exports=ne()},2813:function(ue,L,ne){var H,y=ne(9344).default;H=()=>(()=>{"use strict";var oe=[,(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.DefaultXfaLayerFactory=a.DefaultTextLayerFactory=a.DefaultStructTreeLayerFactory=a.DefaultAnnotationLayerFactory=void 0;var g=v(2),f=v(4),r=v(5),p=v(7),n=v(8),s=v(9);a.DefaultAnnotationLayerFactory=class u{createAnnotationLayerBuilder(i,A,l=null,m="",x=!0,M=f.NullL10n,k=!1,I=null,j=null,X=null,J=null){return new g.AnnotationLayerBuilder({pageDiv:i,pdfPage:A,imageResourcesPath:m,renderForms:x,linkService:new r.SimpleLinkService,l10n:M,annotationStorage:l,enableScripting:k,hasJSActionsProm
1ise:I,fieldObjectsPromise:X,mouseState:j,annotationCanvasMap:J})}},a.DefaultStructTreeLayerFactory=class S{createStructTreeLayerBuilder(i){return new p.StructTreeLayerBuilder({pdfPage:i})}},a.DefaultTextLayerFactory=class d{createTextLayerBuilder(i,A,l,m=!1,x,M){return new n.TextLayerBuilder({textLayerDiv:i,pageIndex:A,viewport:l,enhanceTextSelection:m,eventBus:x,highlighter:M})}},a.DefaultXfaLayerFactory=class _{createXfaLayerBuilder(i,A,l=null,m=null){return new s.XfaLayerBuilder({pageDiv:i,pdfPage:A,annotationStorage:l,linkService:new r.SimpleLinkService,xfaHtml:m})}}},(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.AnnotationLayerBuilder=void 0;var g=v(3),f=v(4);a.AnnotationLayerBuilder=class r{constructor({pageDiv:n,pdfPage:s,linkService:u,downloadManager:S,annotationStorage:d=null,imageResourcesPath:_="",renderForms:t=!0,l10n:i=f.NullL10n,enableScripting:A=!1,hasJSActionsPromise:l=null,fieldObjectsPromise:m=null,mouseState:x=null,annotationCanvasMap:M=null}){this.pageDiv=n,this.pdfPage=s,this.linkService=u,this.downloadManager=S,this.imageResourcesPath=_,this.renderForms=t,this.l10n=i,this.annotationStorage=d,this.enableScripting=A,this._hasJSActionsPromise=l,this._fieldObjectsPromise=m,this._mouseState=x,this._annotationCanvasMap=M,this.div=null,this._cancelled=!1}render(n,s="display"){var u=this;return y(function*(){const[S,d=!1,_=null]=yield Promise.all([u.pdfPage.getAnnotations({intent:s}),u._hasJSActionsPromise,u._fieldObjectsPromise]);if(u._cancelled||0===S.length)return;const t={viewport:n.clone({dontFlip:!0}),div:u.div,annotations:S,page:u.pdfPage,imageResourcesPath:u.imageResourcesPath,renderForms:u.renderForms,linkService:u.linkService,downloadManager:u.downloadManager,annotationStorage:u.annotationStorage,enableScripting:u.enableScripting,hasJSActions:d,fieldObjects:_,mouseState:u._mouseState,annotationCanvasMap:u._annotationCanvasMap};u.div?g.AnnotationLayer.update(t):(u.div=document.createElement("div"),u.div.className="annotationLayer",u.pageDiv.appendChild(u.div),t.div=u.div,g.AnnotationLayer.render(t),u.l10n.translate(u.div))})()}cancel(){this._cancelled=!0}hide(){!this.div||(this.div.hidden=!0)}}},O=>{let a;a=typeof window<"u"&&window["pdfjs-dist/build/pdf"]?window["pdfjs-dist/build/pdf"]:ne(6036),O.exports=a},(O,a)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.NullL10n=void 0,a.fixupLangCode=function r(s){return f[s?.toLowerCase()]||s},a.getL10nFallback=g;const v={of_pages:"of {{pagesCount}}",page_of_pages:"({{pageNumber}} of {{pagesCount}})",document_properties_kb:"{{size_kb}} KB ({{size_b}} bytes)",document_properties_mb:"{{size_mb}} MB ({{size_b}} bytes)",document_properties_date_string:"{{date}}, {{time}}",document_properties_page_size_unit_inches:"in",document_properties_page_size_unit_millimeters:"mm",document_properties_page_size_orientation_portrait:"portrait",document_properties_page_size_orientation_landscape:"landscape",document_properties_page_size_name_a3:"A3",document_properties_page_size_name_a4:"A4",document_properties_page_size_name_letter:"Letter",document_properties_page_size_name_legal:"Legal",document_properties_page_size_dimension_string:"{{width}} \xd7 {{height}} {{unit}} ({{orientation}})",document_properties_page_size_dimension_name_string:"{{width}} \xd7 {{height}} {{unit}} ({{name}}, {{orientation}})",document_properties_linearized_yes:"Yes",document_properties_linearized_no:"No",print_progress_percent:"{{progress}}%","toggle_sidebar.title":"Toggle Sidebar","toggle_sidebar_notification2.title":"Toggle Sidebar (document contains outline/attachments/layers)",additional_layers:"Additional Layers",page_landmark:"Page {{page}}",thumb_page_title:"Page {{page}}",thumb_page_canvas:"Thumbnail of Page {{page}}",find_reached_top:"Reached top of document, continued from bottom",find_reached_bottom:"Reached end of document, continued from top","find_match_count[one]":"{{current}} of {{total}} match","find_match_count[other]":"{{current}} of {{total}} matches","find_match_count_limit[one]":"More than {{limit}} match","find_match_count_limit[other]":"More than {{limit}} matches",find_not_found:"Phrase not found",error_version_info:"PDF.js v{{version}} (build: {{build}})",error_message:"Message: {{message}}",error_stack:"Stack: {{stack}}",error_file:"File: {{file}}",error_line:"Line: {{line}}",rendering_error:"An error occurred while rendering the page.",page_scale_width:"Page Width",page_scale_fit:"Page Fit",page_scale_auto:"Automatic Zoom",page_scale_actual:"Actual Size",page_scale_percent:"{{scale}}%",loading:"Loading\u2026",loading_error:"An error occurred while loading the PDF.",invalid_file_error:"Invalid or corrupted PDF file.",missing_file_error:"Missing PDF file.",unexpected_response_error:"Unexpected server response.",printing_not_supported:"Warning: Printing is not fully supported by this browser.",printing_not_ready:"Warning: The PDF is not fully loaded for printing.",web_fonts_disabled:"Web fonts are disabled: unable to use embedded PDF fonts."};function g(s,u){switch(s){case"find_match_count":s=`find_match_count[${1===u.total?"one":"other"}]`;break;case"find_match_count_limit":s=`find_match_count_limit[${1===u.limit?"one"
1:"other"}]`}return v[s]||""}const f={en:"en-US",es:"es-ES",fy:"fy-NL",ga:"ga-IE",gu:"gu-IN",hi:"hi-IN",hy:"hy-AM",nb:"nb-NO",ne:"ne-NP",nn:"nn-NO",pa:"pa-IN",pt:"pt-PT",sv:"sv-SE",zh:"zh-CN"};a.NullL10n={getLanguage:()=>y(function*(){return"en-us"})(),getDirection:()=>y(function*(){return"ltr"})(),get:(s,u=null,S=g(s,u))=>y(function*(){return function p(s,u){return u?s.replace(/\{\{\s*(\w+)\s*\}\}/g,(S,d)=>d in u?u[d]:"{{"+d+"}}"):s}(S,u)})(),translate:s=>y(function*(){})()}},(O,a,v)=>{var u,S,Ze,_,ct;Object.defineProperty(a,"__esModule",{value:!0}),a.SimpleLinkService=a.PDFLinkService=a.LinkTarget=void 0;var g=v(6);const r={NONE:0,SELF:1,BLANK:2,PARENT:3,TOP:4};function p(A,{url:l,target:m,rel:x,enabled:M=!0}={}){if(!l||"string"!=typeof l)throw new Error('A valid "url" parameter must provided.');const k=(0,g.removeNullCharacters)(l);M?A.href=A.title=k:(A.href="",A.title=`Disabled: ${k}`,A.onclick=()=>!1);let I="";switch(m){case r.NONE:break;case r.SELF:I="_self";break;case r.BLANK:I="_blank";break;case r.PARENT:I="_parent";break;case r.TOP:I="_top"}A.target=I,A.rel="string"==typeof x?x:"noopener noreferrer nofollow"}a.LinkTarget=r;const i=class{constructor({eventBus:l,externalLinkTarget:m=null,externalLinkRel:x=null,ignoreDestinationZoom:M=!1}={}){ve(this,S),ve(this,u,new Map),this.eventBus=l,this.externalLinkTarget=m,this.externalLinkRel=x,this.externalLinkEnabled=!0,this._ignoreDestinationZoom=M,this.baseUrl=null,this.pdfDocument=null,this.pdfViewer=null,this.pdfHistory=null}setDocument(l,m=null){this.baseUrl=m,this.pdfDocument=l,Ae(this,u).clear()}setViewer(l){this.pdfViewer=l}setHistory(l){this.pdfHistory=l}get pagesCount(){return this.pdfDocument?this.pdfDocument.numPages:0}get page(){return this.pdfViewer.currentPageNumber}set page(l){this.pdfViewer.currentPageNumber=l}get rotation(){return this.pdfViewer.pagesRotation}set rotation(l){this.pdfViewer.pagesRotation=l}goToDestination(l){var m=this;return y(function*(){var k;if(!m.pdfDocument)return;let x,M;"string"==typeof l?(x=l,M=yield m.pdfDocument.getDestination(l)):(x=null,M=yield l),Array.isArray(M)?ye(k=m,S,Ze).call(k,l,x,M):console.error(`PDFLinkService.goToDestination: "${M}" is not a valid destination array, for dest="${l}".`)})()}goToPage(l){if(!this.pdfDocument)return;const m="string"==typeof l&&this.pdfViewer.pageLabelToPageNumber(l)||0|l;Number.isInteger(m)&&m>0&&m<=this.pagesCount?(this.pdfHistory&&(this.pdfHistory.pushCurrentPosition(),this.pdfHistory.pushPage(m)),this.pdfViewer.scrollPageIntoView({pageNumber:m})):console.error(`PDFLinkService.goToPage: "${l}" is not a valid page.`)}addLinkAttributes(l,m,x=!1){p(l,{url:m,target:x?r.BLANK:this.externalLinkTarget,rel:this.externalLinkRel,enabled:this.externalLinkEnabled})}getDestinationHash(l){if("string"==typeof l){if(l.length>0)return this.getAnchorUrl("#"+escape(l))}else if(Array.isArray(l)){const m=JSON.stringify(l);if(m.length>0)return this.getAnchorUrl("#"+escape(m))}return this.getAnchorUrl("")}getAnchorUrl(l){return(this.baseUrl||"")+l}setHash(l){var M;if(!this.pdfDocument)return;let m,x;if(l.includes("=")){const k=(0,g.parseQueryString)(l);if(k.has("search")&&this.eventBus.dispatch("findfromurlhash",{source:this,query:k.get("search").replace(/"/g,""),phraseSearch:"true"===k.get("phrase")}),k.has("page")&&(m=0|k.get("page")||1),k.has("zoom")){const I=k.get("zoom").split(","),j=I[0],X=parseFloat(j);j.includes("Fit")?"Fit"===j||"FitB"===j?x=[null,{name:j}]:"FitH"===j||"FitBH"===j||"FitV"===j||"FitBV"===j?x=[null,{name:j},I.length>1?0|I[1]:null]:"FitR"===j?5!==I.length?console.error('PDFLinkService.setHash: Not enough parameters for "FitR".'):x=[null,{name:j},0|I[1],0|I[2],0|I[3],0|I[4]]:console.error(`PDFLinkService.setHash: "${j}" is not a valid zoom value.`):x=[null,{name:"XYZ"},I.length>1?0|I[1]:null,I.length>2?0|I[2]:null,X?X/100:j]}x?this.pdfViewer.scrollPageIntoView({pageNumber:m||this.page,destArray:x,allowNegativeOffset:!0}):m&&(this.page=m),k.has("pagemode")&&this.eventBus.dispatch("pagemode",{source:this,mode:k.get("pagemode")}),k.has("nameddest")&&this.goToDestination(k.get("nameddest"))}else{x=unescape(l);try{x=JSON.parse(x),Array.isArray(x)||(x=x.toString())}catch{}if("string"==typeof x||ye(M=i,_,ct).call(M,x))return void this.goToDestination(x);console.error(`PDFLinkService.setHash: "${unescape(l)}" is not a valid destination.`)}}executeNamedAction(l){switch(l){case"GoBack":this.pdfHistory?.back();break;case"GoForward":this.pdfHistory?.forward();break;case"NextPage":this.pdfViewer.nextPage();break;case"PrevPage":this.pdfViewer.previousPage();break;case"LastPage":this.page=this.pagesCount;break;case"FirstPage":this.page=1}this.eventBus.dispatch("namedaction",{source:this,action:l})}cachePageRef(l,m){if(!m)return;const x=0===m.gen?`${m.num}R`:`${m.num}R${m.gen}`;Ae(this,u).set(x,l)}
vendor: 14,091 bytes, line 1
1_cachedPageNumber(l){if(!l)return null;const m=0===l.gen?`${l.num}R`:`${l.num}R${l.gen}`;return Ae(this,u).get(m)||null}isPageVisible(l){return this.pdfViewer.isPageVisible(l)}isPageCached(l){return this.pdfViewer.isPageCached(l)}};let n=i;u=new WeakMap,S=new WeakSet,Ze=function(l,m=null,x){const M=x[0];let k;if("object"==typeof M&&null!==M){if(k=this._cachedPageNumber(M),!k)return void this.pdfDocument.getPageIndex(M).then(I=>{this.cachePageRef(I+1,M),ye(this,S,Ze).call(this,l,m,x)}).catch(()=>{console.error(`PDFLinkService.#goToDestinationHelper: "${M}" is not a valid page reference, for dest="${l}".`)})}else{if(!Number.isInteger(M))return void console.error(`PDFLinkService.#goToDestinationHelper: "${M}" is not a valid destination reference, for dest="${l}".`);k=M+1}!k||k<1||k>this.pagesCount?console.error(`PDFLinkService.#goToDestinationHelper: "${k}" is not a valid page number, for dest="${l}".`):(this.pdfHistory&&(this.pdfHistory.pushCurrentPosition(),this.pdfHistory.push({namedDest:m,explicitDest:x,pageNumber:k})),this.pdfViewer.scrollPageIntoView({pageNumber:k,destArray:x,ignoreDestinationZoom:this._ignoreDestinationZoom}))},_=new WeakSet,ct=function(l){if(!Array.isArray(l))return!1;const m=l.length;if(m<2)return!1;const x=l[0];if(!("object"==typeof x&&Number.isInteger(x.num)&&Number.isInteger(x.gen)||Number.isInteger(x)&&x>=0))return!1;const M=l[1];if("object"!=typeof M||"string"!=typeof M.name)return!1;let k=!0;switch(M.name){case"XYZ":if(5!==m)return!1;break;case"Fit":case"FitB":return 2===m;case"FitH":case"FitBH":case"FitV":case"FitBV":if(3!==m)return!1;break;case"FitR":if(6!==m)return!1;k=!1;break;default:return!1}for(let I=2;I<m;I++){const j=l[I];if(!("number"==typeof j||k&&null===j))return!1}return!0},ve(n,_),a.PDFLinkService=n,a.SimpleLinkService=class s{constructor(){this.externalLinkEnabled=!0}get pagesCount(){return 0}get page(){return 0}set page(l){}get rotation(){return 0}set rotation(l){}goToDestination(l){return y(function*(){})()}goToPage(l){}addLinkAttributes(l,m,x=!1){p(l,{url:m,enabled:this.externalLinkEnabled})}getDestinationHash(l){return"#"}getAnchorUrl(l){return"#"}setHash(l){}executeNamedAction(l){}cachePageRef(l,m){}isPageVisible(l){return!0}isPageCached(l){return!0}}},(O,a)=>{var ce,ht;Object.defineProperty(a,"__esModule",{value:!0}),a.animationStarted=a.VERTICAL_PADDING=a.UNKNOWN_SCALE=a.TextLayerMode=a.SpreadMode=a.SidebarView=a.ScrollMode=a.SCROLLBAR_PADDING=a.RenderingStates=a.RendererType=a.ProgressBar=a.PresentationModeState=a.OutputScale=a.MIN_SCALE=a.MAX_SCALE=a.MAX_AUTO_SCALE=a.DEFAULT_SCALE_VALUE=a.DEFAULT_SCALE_DELTA=a.DEFAULT_SCALE=a.AutoPrintRegExp=void 0,a.apiPageLayoutToViewerModes=function Y(Q){let re=l.VERTICAL,ie=m.NONE;switch(Q){case"SinglePage":re=l.PAGE;break;case"OneColumn":break;case"TwoPageLeft":re=l.PAGE;case"TwoColumnLeft":ie=m.ODD;break;case"TwoPageRight":re=l.PAGE;case"TwoColumnRight":ie=m.EVEN}return{scrollMode:re,spreadMode:ie}},a.apiPageModeToSidebarView=function ee(Q){switch(Q){case"UseNone":return t.NONE;case"UseThumbs":return t.THUMBS;case"UseOutlines":return t.OUTLINE;case"UseAttachments":return t.ATTACHMENTS;case"UseOC":return t.LAYERS}return t.NONE},a.approximateFraction=function K(Q){if(Math.floor(Q)===Q)return[Q,1];const re=1/Q;if(re>8)return[1,8];if(Math.floor(re)===re)return[1,re];const P=Q>1?re:Q;let he,D=0,q=1,pe=1,de=1;for(;;){const me=D+pe,_e=q+de;if(_e>8)break;P<=me/_e?(pe=me,de=_e):(D=me,q=_e)}return he=P-D/q<pe/de-P?P===Q?[D,q]:[q,D]:P===Q?[pe,de]:[de,pe],he},a.backtrackBeforeAllVisibleElements=T,a.binarySearchFirstItem=$,a.getActiveOrFocusedElement=function z(){let Q=document,re=Q.activeElement||Q.querySelector(":focus");for(;re?.shadowRoot;)Q=re.shadowRoot,re=Q.activeElement||Q.querySelector(":focus");return re},a.getPageSizeInches=function se({view:Q,userUnit:re,rotate:ie}){const[P,D,q,pe]=Q,de=ie%180!=0,he=(q-P)/72*re,me=(pe-D)/72*re;return{width:de?me:he,height:de?he:me}},a.getVisibleElements=function o({scrollEl:Q,views:re,sortByVisibility:ie=!1,horizontal:P=!1,rtl:D=!1}){const q=Q.scrollTop,pe=q+Q.clientHeight,de=Q.scrollLeft,he=de+Q.clientWidth,Se=[],Ce=new Set,Ee=re.length;let Z=$(re,P?function _e(le){const fe=le.div,ge=fe.offsetLeft+fe.clientLeft;return D?ge<he:ge+fe.clientWidth>de}:function me(le){const fe=le.div;return fe.offsetTop+fe.clientTop+fe.clientHeight>q});Z>0&&Z<Ee&&!P&&(Z=T(Z,re,q));let R=P?he:-1;for(let le=Z;le<Ee;le++){const fe=re[le],ge=fe.div,Pe=ge.offsetLeft+ge.clientLeft,we=ge.offsetTop+ge.clientTop,Me=ge.clientWidth,xe=ge.clientHeight,Re=Pe+Me,ke=we+xe;if(-1===R)ke>=pe&&(R=ke);else if((P?Pe:we)>R)break;if(ke<=q||we>=pe||Re<=de||Pe>=he)continue;const Be=Math.max(0,q-we)+Math.max(0,ke-pe),Oe=(Me-(Math.max(0,de-Pe)+Math.max(0,Re-he)))/Me;Se.push({id:fe.id,x:Pe,y:we,view:fe,percent:(xe-Be)/xe*Oe*100|0,widthPercent:100*Oe|0}),Ce.add(fe.id)}const F=Se[0],ae=Se[Se.length-1];return ie&&Se.sort(function(le,fe){const ge=le.percent-fe.percent;return Math.abs(ge)>.001?-ge:le.id-fe.id}),{first:F,last:ae,views:Se,ids:Ce}},a.isPortraitOrientation=function E(Q){return Q.width<=Q.height},a.isValidRotation=function b(Q){return Number.isInteger(Q)&&Q%90==0},a.isValidScrollMode=function w(Q){return Number.isInteger(Q)&&Object.values(l).includes(Q)&&Q!==l.UNKNOWN},a.isValidSpreadMode=function C(Q){return Number.isInteger(Q)&&Object.values(m).includes(Q)&&Q!==m.UNKNOWN},a.noContextMenuHandler=function h(Q){Q.preventDefault()},a.normalizeWheelEventDelta=function c(Q){let re=e(Q);return 0===Q.deltaMode?re/=900:1===Q.deltaMode&&(re/=30),re},a.normalizeWheelEventDirection=e,a.parseQueryString=function j(Q){const re=new Map;for(const[ie,P]of new URLSearchParams(Q))re.set(ie.toLowerCase(),P);return re},a.removeNullCharacters=function N(Q,re=!1){return"string"!=typeof Q?(console.error("The argument must be a string."),Q):(re&&(Q=Q.replace(J," ")),Q.replace(X,""))},a.roundToDivide=function te(Q,re){const ie=Q%re;return 0===ie?Q:Math.round(Q-ie+re)},a.scrollIntoView=function k(Q,re,ie=!1){let P=Q.offsetParent;if(!P)return void console.error("offsetParent is not set -- cannot scroll");let D=Q.offsetTop+Q.clientTop,q=Q.offsetLeft+Q.clientLeft;for(;P.clientHeight===P.scrollHeight&&P.clientWidth===P.scrollWidth||ie&&(P.classList.contains("markedContent")||"hidden"===getComputedStyle(P).overflow);)if(D+=P.offsetTop,q+=P.offsetLeft,P=P.offsetParent,!P)return;re&&(void 0!==re.top&&(D+=re.top),void 0!==re.left&&(q+=re.left,P.scrollLeft=q)),P.scrollTop=D},a.watchScroll=function I(Q,re){const ie=function(q){D||(D=window.requestAnimationFrame(function(){D=null;const de=Q.scrollLeft,he=P.lastX;de!==he&&(P.right=de>he),P.lastX=de;const me=Q.scrollTop,_e=P.lastY;me!==_e&&(P.down=me>_e),P.lastY=me,re(P)}))},P={right:!0,down:!0,lastX:Q.scrollLeft,lastY:Q.scrollTop,_eventHandler:ie};let D=null;return Q.addEventListener("scroll",ie,!0),P},a.DEFAULT_SCALE_VALUE="auto",a.DEFAULT_SCALE=1,a.DEFAULT_SCALE_DELTA=1.1,a.MIN_SCALE=.1,a.MAX_SCALE=10,a.UNKNOWN_SCALE=0,a.MAX_AUTO_SCALE=1.25,a.SCROLLBAR_PADDING=40,a.VERTICAL_PADDING=5,a.RenderingStates={INITIAL:0,RUNNING:1,PAUSED:2,FINISHED:3},a.PresentationModeState={UNKNOWN:0,NORMAL:1,CHANGING:2,FULLSCREEN:3};const t={UNKNOWN:-1,NONE:0,THUMBS:1,OUTLINE:2,ATTACHMENTS:3,LAYERS:4};a.SidebarView=t,a.RendererType={CANVAS:"canvas",SVG:"svg"},a.TextLayerMode={DISABLE:0,ENABLE:1,ENABLE_ENHANCE:2};const l={UNKNOWN:-1,VERTICAL:0,HORIZONTAL:1,WRAPPED:2,PAGE:3};a.ScrollMode=l;const m={UNKNOWN:-1,NONE:0,ODD:1,EVEN:2};a.SpreadMode=m,a.AutoPrintRegExp=/\bprint\s*\(/,a.OutputScale=class M{constructor(){const re=window.devicePixelRatio||1;this.sx=re,this.sy=re}get scaled(){return 1!==this.sx||1!==this.sy}};const X=/\x00/g,J=/[\x01-\x1F]/g;function $(Q,re,ie=0){let P=ie,D=Q.length-1;if(D<0||!re(Q[D]))return Q.length;if(re(Q[P]))return P;for(;P<D;){const q=P+D>>1;re(Q[q])?D=q:P=q+1}return P}function T(Q,re,ie){if(Q<2)return Q;let P=re[Q].div,D=P.offsetTop+P.clientTop;D>=ie&&(P=re[Q-1].div,D=P.offsetTop+P.clientTop);for(let q=Q-2;q>=0&&(P=re[q].div,!(P.offsetTop+P.clientTop+P.clientHeight<=D));--q)Q=q;return Q}function e(Q){let re=Math.hypot(Q.deltaX,Q.deltaY);const ie=Math.atan2(Q.deltaY,Q.deltaX);return-.25*Math.PI<ie&&ie<.75*Math.PI&&(re=-re),re}const B=new Promise(function(Q){window.requestAnimationFrame(Q)});a.animationStarted=B,ce=new WeakSet,ht=function(){this._indeterminate?this.div.classList.add("indeterminate"):(this.div.classList.remove("indeterminate"),document.documentElement.style.setProperty("--progressBar-percent",`${this._percent}%`))},a.ProgressBar=class V{constructor(re){if(ve(this,ce),arguments.length>1)throw new Error("ProgressBar no longer accepts any additional options, please use CSS rules to modify its appearance instead.");this.visible=!0,this.div=document.querySelector(re+" .progress"),this.bar=this.div.parentNode,this.percent=0}get percent(){return this._percent}set percent(re){this._indeterminate=isNaN(re),this._percent=function U(Q,re,ie){return Math.min(Math.max(Q,re),ie)}(re,0,100),ye(this,ce,ht).call(this)}setWidth(re){if(!re)return;const P=re.parentNode.offsetWidth-re.offsetWidth;P>0&&document.documentElement.style.setProperty("--progressBar-end-offset",`${P}px`)}hide(){!this.visible||(this.visible=!1,this.bar.classList.add("hidden"))}show(){this.visible||(this.visible=!0,this.bar.classList.remove("hidden"))}}},(O,a)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.StructTreeLayerBuilder=void 0;const v={Document:null,DocumentFragment:null,Part:"group",Sect:"group",Div:"group",Aside:"note",NonStruct:"none",P:null,H:"heading",Title:null,FENote:"note",Sub:"group",Lbl:null,Span:null,Em:null,Strong:null,Link:"link",Annot:"note",Form:"form",Ruby:null,RB:null,RT:null,RP:null,Warichu:null,WT:null,WP:null,L:"list",LI:"listitem",LBody:null,Table:"table",TR:"row",TH:"columnheader",TD:"cell",THead:"columnheader",TBody:null,TFoot:null,Caption:null,Figure:"figure",Formula:null,Artifact:null},g=/^H(\d+)$/;a.StructTreeLayerBuilder=class f{constructor({pdfPage:p}){this.pdfPage=p}render(p){return this._walk(p)}_setAttributes(p,n){void 0!==p.alt&&n.setAttribute("aria-label",p.alt),void 0!==p.id&&n.setAttribute("aria-owns",p.id),void 0!==p.lang&&n.setAttribute("lang",p.lang)}_walk(p){if(!p)return null;const n=document.createElement("span");if("role"in p){const{role:s}=p,u=s.match(g);u?(n.setAttribute("role","heading"),n.setAttribute("aria-level",u[1])):v[s]&&n.setAttribute("role",v[s])}if(this._setAttributes(p,n),p.children)if(1===p.children.length&&"id"in p.children[0])this._setAttributes(p.children[0],n);else for(const s of p.children)n.appendChild(this._walk(s));return n}}},(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.TextLayerBuilder=void 0;var g=v(3);a.TextLayerBuilder=class r{constructor({textLayerDiv:n,eventBus:s,pageIndex:u,viewport:S,highlighter:d=null,enhanceTextSelection:_=!1}){this.textLayerDiv=n,this.eventBus=s,this.textContent=null,this.textContentItemsStr=[],this.textContentStream=null,this.renderingDone=!1,this.pageNumber=u+1,this.viewport=S,this.textDivs=[],this.textLayerRenderTask=null,this.highlighter=d,this.enhanceTextSelection=_,this._bindMouse()}_finishRendering(){if(this.renderingDone=!0,!this.enhanceTextSelection){const n=document.createElement("div");n.className="endOfContent",this.textLayerDiv.appendChild(n)}this.eventBus.dispatch("textlayerrendered",{source:this,pageNumber:this.pageNumber,numTextDivs:this.textDivs.length})}render(n=0){if(!this.textContent&&!this.textContentStream||this.renderingDone)return;this.cancel(),this.textDivs.length=0,this.highlighter?.setTextMapping(this.textDivs,this.textContentItemsStr);const s=document.createDocumentFragment();this.textLayerRenderTask=(0,g.renderTextLayer)({textContent:this.textContent,textContentStream:this.textContentStream,container:s,viewport:this.viewport,textDivs:this.textDivs,textContentItemsStr:this.textContentItemsStr,timeout:n,enhanceTextSelection:this.enhanceTextSelection}),this.textLayerRenderTask.promise.then(()=>{this.textLayerDiv.appendChild(s),this._finishRendering(),this.highlighter?.enable()},function(u){})}cancel(){this.textLayerRenderTask&&(this.textLayerRenderTask.cancel(),this.textLayerRenderTask=null),this.highlighter?.disable()}setTextContentStream(n){this.cancel(),this.textContentStream=n}setTextContent(n){this.cancel(),this.textContent=n}_bindMouse(){const n=this.textLayerDiv;let s=null;n.addEventListener("mousedown",u=>{if(this.enhanceTextSelection&&this.textLayerRenderTask)return this.textLayerRenderTask.expandTextDivs(!0),void(s&&(clearTimeout(s),s=null));const S=n.querySelector(".endOfContent");if(!S)return;let d=u.target!==n;if(d=d&&"none"!==window.getComputedStyle(S).getPropertyValue("-moz-user-select"),d){const _=n.getBoundingClientRect(),t=Math.max(0,(u.pageY-_.top)/_.height);S.style.top=(100*t).toFixed(2)+"%"}S.classList.add("active")}),n.addEventListener("mouseup",()=>{if(this.enhanceTextSelection&&this.textLayerRenderTask)return void(s=setTimeout(()=>{this.textLayerRenderTask&&this.textLayerRenderTask.expandTextDivs(!1),s=null},300));const u=n.querySelector(".endOfContent");!u||(u.style.top="",u.classList.remove("active"))})}}},(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.XfaLayerBuilder=void 0;var g=v(3);a.XfaLayerBuilder=class f{constructor({pageDiv:p,pdfPage:n,annotationStorage:s=null,linkService:u,xfaHtml:S=null}){this.pageDiv=p,this.pdfPage=n,this.annotationStorage=s,this.linkService=u,this.xfaHtml=S,this.div=null,this._cancelled=!1}render(p,n="display"){if("print"===n){const s={viewport:p.clone({dontFlip:!0}),div:this.div,xfaHtml:this.xfaHtml,annotationStorage:this.annotationStorage,linkService:this.linkService,intent:n},u=document.createElement("div");this.pageDiv.appendChild(u),s.div=u;const S=g.XfaLayer.render(s);return Promise.resolve(S)}return this.pdfPage.getXfa().then(s=>{if(this._cancelled||!s)return{textDivs:[]};const u={viewport:p.clone({dontFlip:!0}),div:this.div,xfaHtml:s,annotationStorage:this.annotationStorage,linkService:this.linkService,intent:n};return this.div?g.XfaLayer.update(u):(this.div=document.createElement("div"),this.pageDiv.appendChild(this.div),u.div
1=this.div,g.XfaLayer.render(u))}).catch(s=>{console.error(s)})}cancel(){this._cancelled=!0}hide(){!this.div||(this.div.hidden=!0)}}},(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.PDFViewer=a.PDFSinglePageViewer=void 0;var g=v(6),f=v(11);a.PDFViewer=class r extends f.BaseViewer{},a.PDFSinglePageViewer=class p extends f.BaseViewer{_resetView(){super._resetView(),this._scrollMode=g.ScrollMode.PAGE,this._spreadMode=g.SpreadMode.NONE}set scrollMode(s){}_updateScrollMode(){}set spreadMode(s){}_updateSpreadMode(){}}},(O,a,v)=>{var M,k,I,et,X,J,N,$,K,te,se,T,ut,h,dt,c,We,w,qe,E,ft,U,tt,z,pt,ee,gt,be,_t;Object.defineProperty(a,"__esModule",{value:!0}),a.PagesCountLimit=a.PDFPageViewBuffer=a.BaseViewer=void 0;var g=v(3),f=v(6),r=v(2),p=v(4),n=v(12),s=v(14),u=v(5),S=v(7),d=v(15),_=v(8),t=v(9);const A="enablePermissions",l={FORCE_SCROLL_MODE_PAGE:15e3,FORCE_LAZY_PAGE_INIT:7500,PAUSE_EAGER_PAGE_INIT:250};a.PagesCountLimit=l;class m{constructor(P){ve(this,I),ve(this,M,new Set),ve(this,k,0),Te(this,k,P)}push(P){const D=Ae(this,M);D.has(P)&&D.delete(P),D.add(P),D.size>Ae(this,k)&&ye(this,I,et).call(this)}resize(P,D=null){Te(this,k,P);const q=Ae(this,M);if(D){const pe=q.size;let de=1;for(const he of q)if(D.has(he.id)&&(q.delete(he),q.add(he)),++de>pe)break}for(;q.size>Ae(this,k);)ye(this,I,et).call(this)}has(P){return Ae(this,M).has(P)}[Symbol.iterator](){return Ae(this,M).keys()}}M=new WeakMap,k=new WeakMap,I=new WeakSet,et=function(){const P=Ae(this,M).keys().next().value;P?.destroy(),Ae(this,M).delete(P)},a.PDFPageViewBuffer=m;const re=class{constructor(P){if(ve(this,T),ve(this,h),ve(this,c),ve(this,w),ve(this,E),ve(this,U),ve(this,z),ve(this,ee),ve(this,be),ve(this,X,null),ve(this,J,g.AnnotationMode.ENABLE_FORMS),ve(this,N,null),ve(this,$,!1),ve(this,K,0),ve(this,te,null),ve(this,se,null),this.constructor===re)throw new Error("Cannot initialize BaseViewer.");const D="2.14.305";if(g.version!==D)throw new Error(`The API version "${g.version}" does not match the Viewer version "${D}".`);if(this.container=P.container,this.viewer=P.viewer||P.container.firstElementChild,"DIV"!==this.container?.tagName.toUpperCase()||"DIV"!==this.viewer?.tagName.toUpperCase())throw new Error("Invalid `container` and/or `viewer` option.");if(this.container.offsetParent&&"absolute"!==getComputedStyle(this.container).position)throw new Error("The `container` must be absolutely positioned.");this.eventBus=P.eventBus,this.linkService=P.linkService||new u.SimpleLinkService,this.downloadManager=P.downloadManager||null,this.findController=P.findController||null,this._scriptingManager=P.scriptingManager||null,this.removePageBorders=P.removePageBorders||!1,this.textLayerMode=P.textLayerMode??f.TextLayerMode.ENABLE,Te(this,J,P.annotationMode??g.AnnotationMode.ENABLE_FORMS),this.imageResourcesPath=P.imageResourcesPath||"",this.enablePrintAutoRotate=P.enablePrintAutoRotate||!1,this.renderer=P.renderer||f.RendererType.CANVAS,this.useOnlyCssZoom=P.useOnlyCssZoom||!1,this.maxCanvasPixels=P.maxCanvasPixels,this.l10n=P.l10n||p.NullL10n,Te(this,$,P.enablePermissions||!1),this.pageColors=P.pageColors||null,P.pageColors&&(!CSS.supports("color",P.pageColors.background)||!CSS.supports("color",P.pageColors.foreground))&&((P.pageColors.background||P.pageColors.foreground)&&console.warn("Ignoring `pageColors`-option, since the browser doesn't support the values used."),this.pageColors=null),this.defaultRenderingQueue=!P.renderingQueue,this.defaultRenderingQueue?(this.renderingQueue=new s.PDFRenderingQueue,this.renderingQueue.setViewer(this)):this.renderingQueue=P.renderingQueue,this._doc=document.documentElement,this.scroll=(0,f.watchScroll)(this.container,this._scrollUpdate.bind(this)),this.presentationModeState=f.PresentationModeState.UNKNOWN,this._onBeforeDraw=this._onAfterDraw=null,this._resetView(),this.removePageBorders&&this.viewer.classList.add("removePageBorders"),this.updateContainerHeightCss(),Promise.resolve().then(()=>{this.eventBus.dispatch("baseviewerinit",{source:this})})}get pagesCount(){return this._pages.length}getPageView(P){return this._pages[P]}get pageViewsReady(){return!!this._pagesCapability.settled&&this._pages.every(function(P){return P?.pdfPage})}get renderForms(){return Ae(this,J)===g.AnnotationMode.ENABLE_FORMS}get enableScripting(){return!!this._scriptingManager}get currentPageNumber(){return this._currentPageNumber}set currentPageNumber(P){if(!Number.isInteger(P))throw new Error("Invalid page number.");!this.pdfDocument||this._setCurrentPageNumber(P,!0)||console.error(`currentPageNumber: "${P}" is not a valid page.`)}_setCurrentPageNumber(P,D=!1){if(this._currentPageNumber===P)return D&&ye(this,U,tt).call(this),!0;if(!(0<P&&P<=this.pagesCount))return!1;const q=this._currentPageNumber;return this._currentPageNumber=P,this.eventBus.dispatch("pagechanging",{source:this,pageNumber:P,pageLabel:this._pageLabels?.[P-1]??null,previous:q}),D&&ye(this,U,tt).call(this),!0}get currentPageLabel(){return this._pageLabels?.[this._currentPageNumber-1]??null}set currentPageLabel(P){if(!this.pdfDocument)return;let D=0|P;if(this._pageLabels){const q=this._pageLabels.indexOf(P);q>=0&&(D=q+1)}this._setCurrentPageNumber(D,!0)||console.error(`currentPageLabel: "${P}" is not a valid page.`)}get currentScale(){return this._currentScale!==f.UNKNOWN_SCALE?this._currentScale:f.DEFAULT_SCALE}set currentScale(P){if(isNaN(P))throw new Error("Invalid numeric scale.");!this.pdfDocument||this._setScale(P,!1)}get currentScaleValue(){return this._currentScaleValue}set currentScaleValue(P){!this.pdfDocument||this._setScale(P,!1)}get pagesRotation(){return this._pagesRotation}set pagesRotation(P){if(!(0,f.isValidRotation)(P))throw new Error("Invalid pages rotation angle.");if(!this.pdfDocument||((P%=360)<0&&(P+=360),this._pagesRotation===P))return;this._pagesRotation=P;const D=this._currentPageNumber,q={rotation:P};for(const pe of this._pages)pe.update(q);this._currentScaleValue&&this._setScale(this._currentScaleValue,!0),this.eventBus.dispatch("rotationchanging",{source:this,pagesRotation:P,pageNumber:D}),this.defaultRenderingQueue&&this.update()}get firstPagePromise(){return this.pdfDocument?this._firstPageCapability.promise:null}get onePageRendered(){return this.pdfDocument?this._onePageRenderedCapability.promise:null}get pagesPromise(){return this.pdfDocument?this._pagesCapability.promise:null}setDocument(P){var D=this;if(this.pdfDocument&&(this.eventBus.dispatch("pagesdestroy",{source:this}),this._cancelRendering(),this._resetView(),this.findController&&this.findController.setDocument(null),this._scriptingManager&&this._scriptingManager.setDocument(null)),this.pdfDocument=P,!P)return;const q=P.isPureXfa,pe=P.numPages,de=P.getPage(1),he=P.getOptionalContentConfig(),me=Ae(this,$)?P.getPermissions():Promise.resolve();if(pe>l.FORCE_SCROLL_MODE_PAGE){console.warn("Forcing PAGE-scrolling for performance reasons, given the length of the document.");const _e=this._scrollMode=f.ScrollMode.PAGE;this.eventBus.dispatch("scrollmodechanged",{source:this,mode:_e})}this._pagesCapability.promise.then(()=>{this.eventBus.dispatch("pagesloaded",{source:this,pagesCount:pe})},()=>{}),this._onBeforeDraw=_e=>{const Se=this._pages[_e.pageNumber-1];!Se||Ae(this,X).push(Se)},this.eventBus._on("pagerender",this._onBeforeDraw),this._onAfterDraw=_e=>{_e.cssTransform||this._onePageRenderedCapability.settled||(this._onePageRenderedCapability.resolve({timestamp:_e.timestamp}),this.eventBus._off("pagerendered",this._onAfterDraw),this._onAfterDraw=null,Ae(this,se)&&(document.removeEventListener("visibilitychange",Ae(this,se)),Te(this,se,null)))},this.eventBus._on("pagerendered",this._onAfterDraw),Promise.all([de,me]).then(([_e,Se])=>
1{if(P!==this.pdfDocument)return;this._firstPageCapability.resolve(_e),this._optionalContentConfigPromise=he,ye(this,T,ut).call(this,Se);const Ce=this._scrollMode===f.ScrollMode.PAGE?null:this.viewer,Ee=this.currentScale,Z=_e.getViewport({scale:Ee*g.PixelsPerInch.PDF_TO_CSS_UNITS}),R=this.textLayerMode===f.TextLayerMode.DISABLE||q?null:this,F=Ae(this,J)!==g.AnnotationMode.DISABLE?this:null,ae=q?this:null;for(let fe=1;fe<=pe;++fe){const ge=new n.PDFPageView({container:Ce,eventBus:this.eventBus,id:fe,scale:Ee,defaultViewport:Z.clone(),optionalContentConfigPromise:he,renderingQueue:this.renderingQueue,textLayerFactory:R,textLayerMode:this.textLayerMode,annotationLayerFactory:F,annotationMode:Ae(this,J),xfaLayerFactory:ae,textHighlighterFactory:this,structTreeLayerFactory:this,imageResourcesPath:this.imageResourcesPath,renderer:this.renderer,useOnlyCssZoom:this.useOnlyCssZoom,maxCanvasPixels:this.maxCanvasPixels,pageColors:this.pageColors,l10n:this.l10n});this._pages.push(ge)}const le=this._pages[0];le&&(le.setPdfPage(_e),this.linkService.cachePageRef(1,_e.ref)),this._scrollMode===f.ScrollMode.PAGE?ye(this,c,We).call(this):this._spreadMode!==f.SpreadMode.NONE&&this._updateSpreadMode(),ye(this,h,dt).call(this).then(y(function*(){if(D.findController&&D.findController.setDocument(P),D._scriptingManager&&D._scriptingManager.setDocument(P),P.loadingParams.disableAutoFetch||pe>l.FORCE_LAZY_PAGE_INIT)return void D._pagesCapability.resolve();let fe=pe-1;if(fe<=0)D._pagesCapability.resolve();else for(let ge=2;ge<=pe;++ge){const Pe=P.getPage(ge).then(we=>{const Me=D._pages[ge-1];Me.pdfPage||Me.setPdfPage(we),D.linkService.cachePageRef(ge,we.ref),0==--fe&&D._pagesCapability.resolve()},we=>{console.error(`Unable to get page ${ge} to initialize viewer`,we),0==--fe&&D._pagesCapability.resolve()});ge%l.PAUSE_EAGER_PAGE_INIT==0&&(yield Pe)}})),this.eventBus.dispatch("pagesinit",{source:this}),P.getMetadata().then(({info:fe})=>{P===this.pdfDocument&&fe.Language&&(this.viewer.lang=fe.Language)}),this.defaultRenderingQueue&&this.update()}).catch(_e=>{console.error("Unable to initialize viewer",_e),this._pagesCapability.reject(_e)})}setPageLabels(P){if(this.pdfDocument){P?Array.isArray(P)&&this.pdfDocument.numPages===P.length?this._pageLabels=P:(this._pageLabels=null,console.error("setPageLabels: Invalid page labels.")):this._pageLabels=null;for(let D=0,q=this._pages.length;D<q;D++)this._pages[D].setPageLabel(this._pageLabels?.[D]??null)}}_resetView(){this._pages=[],this._currentPageNumber=1,this._currentScale=f.UNKNOWN_SCALE,this._currentScaleValue=null,this._pageLabels=null,Te(this,X,new m(10)),this._location=null,this._pagesRotation=0,this._optionalContentConfigPromise=null,this._firstPageCapability=(0,g.createPromiseCapability)(),this._onePageRenderedCapability=(0,g.createPromiseCapability)(),this._pagesCapability=(0,g.createPromiseCapability)(),this._scrollMode=f.ScrollMode.VERTICAL,this._previousScrollMode=f.ScrollMode.UNKNOWN,this._spreadMode=f.SpreadMode.NONE,Te(this,te,{previousPageNumber:1,scrollDown:!0,pages:[]}),this._onBeforeDraw&&(this.eventBus._off("pagerender",this._onBeforeDraw),this._onBeforeDraw=null),this._onAfterDraw&&(this.eventBus._off("pagerendered",this._onAfterDraw),this._onAfterDraw=null),Ae(this,se)&&(document.removeEventListener("visibilitychange",Ae(this,se)),Te(this,se,null)),this.viewer.textContent="",this._updateScrollMode(),this.viewer.removeAttribute("lang"),this.viewer.classList.remove(A),null!==Ae(this,N)&&(Te(this,J,Ae(this,N)),Te(this,N,null))}_scrollUpdate(){0!==this.pagesCount&&this.update()}_setScaleUpdatePages(P,D,q=!1,pe=!1){if(this._currentScaleValue=D.toString(),ye(this,E,ft).call(this,P))return void(pe&&this.eventBus.dispatch("scalechanging",{source:this,scale:P,presetValue:D}));this._doc.style.setProperty("--zoom-factor",P);const de={scale:P};for(const he of this._pages)he.update(de);if(this._currentScale=P,!q){let me,he=this._currentPageNumber;this._location&&!(this.isInPresentationMode||this.isChangingPresentationMode)&&(he=this._location.pageNumber,me=[null,{name:"XYZ"},this._location.left,this._location.top,null]),this.scrollPageIntoView({pageNumber:he,destArray:me,allowNegativeOffset:!0})}this.eventBus.dispatch("scalechanging",{source:this,scale:P,presetValue:pe?D:void 0}),this.defaultRenderingQueue&&this.update(),this.updateContainerHeight
vendor: 5,758 bytes, line 1
1Css()}get _pageWidthScaleFactor(){return this._spreadMode!==f.SpreadMode.NONE&&this._scrollMode!==f.ScrollMode.HORIZONTAL?2:1}_setScale(P,D=!1){let q=parseFloat(P);if(q>0)this._setScaleUpdatePages(q,P,D,!1);else{const pe=this._pages[this._currentPageNumber-1];if(!pe)return;let de=f.SCROLLBAR_PADDING,he=f.VERTICAL_PADDING;this.isInPresentationMode?de=he=4:this.removePageBorders?de=he=0:this._scrollMode===f.ScrollMode.HORIZONTAL&&([de,he]=[he,de]);const me=(this.container.clientWidth-de)/pe.width*pe.scale/this._pageWidthScaleFactor,_e=(this.container.clientHeight-he)/pe.height*pe.scale;switch(P){case"page-actual":q=1;break;case"page-width":q=me;break;case"page-height":q=_e;break;case"page-fit":q=Math.min(me,_e);break;case"auto":const Se=(0,f.isPortraitOrientation)(pe)?me:Math.min(_e,me);q=Math.min(f.MAX_AUTO_SCALE,Se);break;default:return void console.error(`_setScale: "${P}" is an unknown zoom value.`)}this._setScaleUpdatePages(q,P,D,!0)}}pageLabelToPageNumber(P){if(!this._pageLabels)return null;const D=this._pageLabels.indexOf(P);return D<0?null:D+1}scrollPageIntoView({pageNumber:P,destArray:D=null,allowNegativeOffset:q=!1,ignoreDestinationZoom:pe=!1}){if(!this.pdfDocument)return;const de=Number.isInteger(P)&&this._pages[P-1];if(!de)return void console.error(`scrollPageIntoView: "${P}" is not a valid pageNumber parameter.`);if(this.isInPresentationMode||!D)return void this._setCurrentPageNumber(P,!0);let Ce,Ee,he=0,me=0,_e=0,Se=0;const Z=de.rotation%180!=0,R=(Z?de.height:de.width)/de.scale/g.PixelsPerInch.PDF_TO_CSS_UNITS,F=(Z?de.width:de.height)/de.scale/g.PixelsPerInch.PDF_TO_CSS_UNITS;let ae=0;switch(D[1].name){case"XYZ":he=D[2],me=D[3],ae=D[4],he=null!==he?he:0,me=null!==me?me:F;break;case"Fit":case"FitB":ae="page-fit";break;case"FitH":case"FitBH":me=D[2],ae="page-width",null===me&&this._location?(he=this._location.left,me=this._location.top):("number"!=typeof me||me<0)&&(me=F);break;case"FitV":case"FitBV":he=D[2],_e=R,Se=F,ae="page-height";break;case"FitR":he=D[2],me=D[3],_e=D[4]-he,Se=D[5]-me,Ce=(this.container.clientWidth-(this.removePageBorders?0:f.SCROLLBAR_PADDING))/_e/g.PixelsPerInch.PDF_TO_CSS_UNITS,Ee=(this.container.clientHeight-(this.removePageBorders?0:f.VERTICAL_PADDING))/Se/g.PixelsPerInch.PDF_TO_CSS_UNITS,ae=Math.min(Math.abs(Ce),Math.abs(Ee));break;default:return void console.error(`scrollPageIntoView: "${D[1].name}" is not a valid destination type.`)}if(pe||(ae&&ae!==this._currentScale?this.currentScaleValue=ae:this._currentScale===f.UNKNOWN_SCALE&&(this.currentScaleValue=f.DEFAULT_SCALE_VALUE)),"page-fit"===ae&&!D[4])return void ye(this,w,qe).call(this,de);const le=[de.viewport.convertToViewportPoint(he,me),de.viewport.convertToViewportPoint(he+_e,me+Se)];let fe=Math.min(le[0][0],le[1][0]),ge=Math.min(le[0][1],le[1][1]);q||(fe=Math.max(fe,0),ge=Math.max(ge,0)),ye(this,w,qe).call(this,de,{left:fe,top:ge})}_updateLocation(P){const D=this._currentScale,q=this._currentScaleValue,pe=parseFloat(q)===D?Math.round(1e4*D)/100:q,de=P.id,me=this.container,_e=this._pages[de-1].getPagePoint(me.scrollLeft-P.x,me.scrollTop-P.y),Se=Math.round(_e[0]),Ce=Math.round(_e[1]);let Ee=`#page=${de}`;this.isInPresentationMode||(Ee+=`&zoom=${pe},${Se},${Ce}`),this._location={pageNumber:de,scale:pe,top:Ce,left:Se,rotation:this._pagesRotation,pdfOpenParams:Ee}}update(){const P=this._getVisiblePages(),D=P.views,q=D.length;if(0===q)return;const pe=Math.max(10,2*q+1);Ae(this,X).resize(pe,P.ids),this.renderingQueue.renderHighestPriority(P);const de=this._spreadMode===f.SpreadMode.NONE&&(this._scrollMode===f.ScrollMode.PAGE||this._scrollMode===f.ScrollMode.VERTICAL),he=this._currentPageNumber;let me=!1;for(const _e of D){if(_e.percent<100)break;if(_e.id===he&&de){me=!0;break}}this._setCurrentPageNumber(me?he:D[0].id),this._updateLocation(P.first),this.eventBus.dispatch("updateviewarea",{source:this,location:this._location})}containsElement(P){return this.container.contains(P)}focus(){this.container.focus()}get _isContainerRtl(){return"rtl"===getComputedStyle(this.container).direction}get isInPresentationMode(){return this.presentationModeState===f.PresentationModeState.FULLSCREEN}get isChangingPresentationMode(){return this.presentationModeState===f.PresentationModeState.CHANGING}get isHorizontalScrollbarEnabled(){return!this.isInPresentationMode&&this.container.scrollWidth>this.container.clientWidth}get isVerticalScrollbarEnabled(){return!this.isInPresentationMode&&this.container.scrollHeight>this.container.clientHeight}_getVisiblePages(){const P=this._scrollMode===f.ScrollMode.PAGE?Ae(this,te).pages:this._pages,D=this._scrollMode===f.ScrollMode.HORIZONTAL;return(0,f.getVisibleElements)({scrollEl:this.container,views:P,sortByVisibility:!0,horizontal:D,rtl:D&&this._isContainerRtl})}isPageVisible(P){return!!this.pdfDocument&&(Number.isInteger(P)&&P>0&&P<=this.pagesCount?this._getVisiblePages().ids.has(P):(console.error(`isPageVisible: "${P}" is not a valid page.`),!1))}isPageCached(P){if(!this.pdfDocument)return!1;if(!(Number.isInteger(P)&&P>0&&P<=this.pagesCount))return console.error(`isPageCached: "${P}" is not a valid page.`),!1;const D=this._pages[P-1];return Ae(this,X).has(D)}cleanup(){for(const P of this._pages)P.renderingState!==f.RenderingStates.FINISHED&&P.reset()}_cancelRendering(){for(const P of this._pages)P.cancelRendering()}forceRendering(P){const D=P||this._getVisiblePages(),q=ye(this,ee,gt).call(this,D),de=this.renderingQueue.getHighestPriority(D,this._pages,q,this._spreadMode!==f.SpreadMode.NONE&&this._scrollMode!==f.ScrollMode.HORIZONTAL);return ye(this,be,_t).call(this,D.ids),!!de&&(ye(this,z,pt).call(this,de).then(()=>{this.renderingQueue.renderView(de)}),!0)}createTextLayerBuilder(P,D,q,pe=!1,de,he){return new _.TextLayerBuilder({textLayerDiv
1:P,eventBus:de,pageIndex:D,viewport:q,enhanceTextSelection:!this.isInPresentationMode&&pe,highlighter:he})}createTextHighlighter(P,D){return new d.TextHighlighter({eventBus:D,pageIndex:P,findController:this.isInPresentationMode?null:this.findController})}createAnnotationLayerBuilder(P,D,q=null,pe="",de=!0,he=p.NullL10n,me=null,_e=null,Se=null,Ce=null,Ee=null){return new r.AnnotationLayerBuilder({pageDiv:P,pdfPage:D,annotationStorage:q||this.pdfDocument?.annotationStorage,imageResourcesPath:pe,renderForms:de,linkService:this.linkService,downloadManager:this.downloadManager,l10n:he,enableScripting:me??this.enableScripting,hasJSActionsPromise:_e||this.pdfDocument?.hasJSActions(),fieldObjectsPromise:Ce||this.pdfDocument?.getFieldObjects(),mouseState:Se||this._scriptingManager?.mouseState,annotationCanvasMap:Ee})}createXfaLayerBuilder(P,D,q=null){return new t.XfaLayerBuilder({pageDiv:P,pdfPage:D,annotationStorage:q||this.pdfDocument?.annotationStorage,linkService:this.linkService})}createStructTreeLayerBuilder(P){return new S.StructTreeLayerBuilder({pdfPage:P})}get hasEqualPageSizes(){const P=this._pages[0];for(let D=1,q=this._pages.length;D<q;++D){const pe=this._pages[D];if(pe.width!==P.width||pe.height!==P.height)return!1}return!0}getPagesOverview(){return this._pages.map(P=>{const D=P.pdfPage.getViewport({scale:1});return!this.enablePrintAutoRotate||(0,f.isPortraitOrientation)(D)?{width:D.width,height:D.height,rotation:D.rotation}:{width:D.height,height:D.width,rotation:(D.rotation-90)%360}})}get optionalContentConfigPromise(){return this.pdfDocument?this._optionalContentConfigPromise?this._optionalContentConfigPromise:this.pdfDocument.getOptionalContentConfig():Promise.resolve(null)}set optionalContentConfigPromise(P){if(!(P instanceof Promise))throw new Error(`Invalid optionalContentConfigPromise: ${P}`);if(!this.pdfDocument||!this._optionalContentConfigPromise)return;this._optionalContentConfigPromise=P;const D={optionalContentConfigPromise:P};for(const q of this._pages)q.update(D);this.update(),this.eventBus.dispatch("optionalcontentconfigchanged",{source:this,promise:P})}get scrollMode(){return this._scrollMode}set scrollMode(P){if(this._scrollMode!==P){if(!(0,f.isValidScrollMode)(P))throw new Error(`Invalid scroll mode: ${P}`);this.pagesCount>l.FORCE_SCROLL_MODE_PAGE||(this._previousScrollMode=this._scrollMode,this._scrollMode=P,this.eventBus.dispatch("scrollmodechanged",{source:this,mode:P}),this._updateScrollMode(this._currentPageNumber))}}_updateScrollMode(P=null){const D=this._scrollMode,q=this.viewer;q.classList.toggle("scrollHorizontal",D===f.ScrollMode.HORIZONTAL),q.classList.toggle("scrollWrapped",D===f.ScrollMode.WRAPPED),this.pdfDocument&&P&&(D===f.ScrollMode.PAGE?ye(this,c,We).call(this):this._previousScrollMode===f.ScrollMode.PAGE&&this._updateSpreadMode(),this._currentScaleValue&&isNaN(this._currentScaleValue)&&this._setScale(this._currentScaleValue,!0),this._setCurrentPageNumber(P,!0),this.update())}get spreadMode(){return this._spreadMode}set spreadMode(P){if(this._spreadMode!==P){if(!(0,f.isValidSpreadMode)(P))throw new Error(`Invalid spread mode: ${P}`);this._spreadMode=P,this.eventBus.dispatch("spreadmodechanged",{source:this,mode:P}),this._updateSpreadMode(this._currentPageNumber)}}_updateSpreadMode(P=null){if(!this.pdfDocument)return;const D=this.viewer,q=this._pages;if(this._scrollMode===f.ScrollMode.PAGE)ye(this,c,We).call(this);else if(D.textContent="",this._spreadMode===f.SpreadMode.NONE)for(const pe of this._pages)D.appendChild(pe.div);else{const pe=this._spreadMode-1;let de=null;for(let he=0,me=q.length;he<me;++he)null===de?(de=document.createElement("div"),de.className="spread",D.appendChild(de)):he%2===pe&&(de=de.cloneNode(!1),D.appendChild(de)),de.appendChild(q[he].div)}!P||(this._currentScaleValue&&isNaN(this._currentScaleValue)&&this._setScale(this._currentScaleValue,!0),this._setCurrentPageNumber(P,!0),this.update())}_getPageAdvance(P,D=!1){switch(this._scrollMode){case f.ScrollMode.WRAPPED:{const{views:q}=this._getVisiblePages(),pe=new Map;for(const{id:de,y:he,percent:me,widthPercent:_e}of q){if(0===me||_e<100)continue;let Se=pe.get(he);Se||pe.set(he,Se||(Se=[])),Se.push(de)}for(const de of pe.values()){const he=de.indexOf(P);if(-1===he)continue;const me=de.length;if(1===me)break;
1if(D)for(let _e=he-1,Se=0;_e>=Se;_e--){const Ee=de[_e+1]-1;if(de[_e]<Ee)return P-Ee}else for(let _e=he+1,Se=me;_e<Se;_e++){const Ee=de[_e-1]+1;if(de[_e]>Ee)return Ee-P}if(D){const _e=de[0];if(_e<P)return P-_e+1}else{const _e=de[me-1];if(_e>P)return _e-P+1}break}break}case f.ScrollMode.HORIZONTAL:break;case f.ScrollMode.PAGE:case f.ScrollMode.VERTICAL:{if(this._spreadMode===f.SpreadMode.NONE)break;const q=this._spreadMode-1;if(D&&P%2!==q)break;if(!D&&P%2===q)break;const{views:pe}=this._getVisiblePages(),de=D?P-1:P+1;for(const{id:he,percent:me,widthPercent:_e}of pe)if(he===de){if(me>0&&100===_e)return 2;break}break}}return 1}nextPage(){const P=this._currentPageNumber,D=this.pagesCount;if(P>=D)return!1;const q=this._getPageAdvance(P,!1)||1;return this.currentPageNumber=Math.min(P+q,D),!0}previousPage(){const P=this._currentPageNumber;if(P<=1)return!1;const D=this._getPageAdvance(P,!0)||1;return this.currentPageNumber=Math.max(P-D,1),!0}increaseScale(P=1){let D=this._currentScale;do{D=(D*f.DEFAULT_SCALE_DELTA).toFixed(2),D=Math.ceil(10*D)/10,D=Math.min(f.MAX_SCALE,D)}while(--P>0&&D<f.MAX_SCALE);this.currentScaleValue=D}decreaseScale(P=1){let D=this._currentScale;do{D=(D/f.DEFAULT_SCALE_DELTA).toFixed(2),D=Math.floor(10*D)/10,D=Math.max(f.MIN_SCALE,D)}while(--P>0&&D>f.MIN_SCALE);this.currentScaleValue=D}updateContainerHeightCss(){const P=this.container.clientHeight;P!==Ae(this,K)&&(Te(this,K,P),this._doc.style.setProperty("--viewer-container-height",`${P}px`))}};let x=re;X=new WeakMap,J=new WeakMap,N=new WeakMap,$=new WeakMap,K=new WeakMap,te=new WeakMap,se=new WeakMap,T=new WeakSet,ut=function(P){!P||(P.includes(g.PermissionFlag.COPY)||this.viewer.classList.add(A),!P.includes(g.PermissionFlag.MODIFY_ANNOTATIONS)&&!P.includes(g.PermissionFlag.FILL_INTERACTIVE_FORMS)&&Ae(this,J)===g.AnnotationMode.ENABLE_FORMS&&(Te(this,N,Ae(this,J)),Te(this,J,g.AnnotationMode.ENABLE)))},h=new WeakSet,dt=function(){if("hidden"===document.visibilityState||!this.container.offsetParent||0===this._getVisiblePages().views.length)return Promise.resolve();const P=new Promise(D=>{Te(this,se,()=>{"hidden"===document.visibilityState&&(D(),document.removeEventListener("visibilitychange",Ae(this,se)),Te(this,se,null))}),document.addEventListener("visibilitychange",Ae(this,se))});return Promise.race([this._onePageRenderedCapability.promise,P])},c=new WeakSet,We=function(){if(this._scrollMode!==f.ScrollMode.PAGE)throw new Error("#ensurePageViewVisible: Invalid scrollMode value.");const P=this._currentPageNumber,D=Ae(this,te),q=this.viewer;if(q.textContent="",D.pages.length=0,this._spreadMode!==f.SpreadMode.NONE||this.isInPresentationMode){const pe=new Set,de=this._spreadMode-1;-1===de?pe.add(P-1):P%2!==de?(pe.add(P-1),pe.add(P)):(pe.add(P-2),pe.add(P-1));const he=document.createElement("div");if(he.className="spread",this.isInPresentationMode){const me=document.createElement("div");me.className="dummyPage",he.appendChild(me)}for(const me of pe){const _e=this._pages[me];!_e||(he.appendChild(_e.div),D.pages.push(_e))}q.appendChild(he)}else{const pe=this._pages[P-1];q.appendChild(pe.div),D.pages.push(pe)}D.scrollDown=P>=D.previousPageNumber,D.previousPageNumber=P},w=new WeakSet,qe=function(P,D=null){const{div:q,id:pe}=P;if(this._scrollMode===f.ScrollMode.PAGE&&(this._setCurrentPageNumber(pe),ye(this,c,We).call(this),this.update()),!D&&!this.isInPresentationMode){const de=q.offsetLeft+q.clientLeft,he=de+q.clientWidth,{scrollLeft:me,clientWidth:_e}=this.container;(this._scrollMode===f.ScrollMode.HORIZONTAL||de<me||he>me+_e)&&(D={left:0,top:0})}(0,f.scrollIntoView)(q,D)},E=new WeakSet,ft=function(P){return P===this._currentScale||Math.abs(P-this._currentScale)<1e-15},U=new WeakSet,tt=function(){const P=this._pages[this._currentPageNumber-1];this.isInPresentationMode&&this._setScale(this._currentScaleValue,!0),ye(this,w,qe).call(this,P)},z=new WeakSet,pt=function(P){var D=this;return y(function*(){if(P.pdfPage)return P.pdfPage;try{const q=yield D.pdfDocument.getPage(P.id);return P.pdfPage||P.setPdfPage(q),D.linkService._cachedPageNumber?.(q.ref)||D.linkService.cachePageRef(P.id,q.ref),q}catch(q){return console.error("Unable to get page for page view",q),null}})()},ee=new WeakSet,gt=function(P){if(1===P.first?.id)return!0;
1if(P.last?.id===this.pagesCount)return!1;switch(this._scrollMode){case f.ScrollMode.PAGE:return Ae(this,te).scrollDown;case f.ScrollMode.HORIZONTAL:return this.scroll.right}return this.scroll.down},be=new WeakSet,_t=function(P){for(const D of P)this._pages[D-1]?.toggleLoadingIconSpinner(!0);for(const D of Ae(this,X))P.has(D.id)||D.toggleLoadingIconSpinner(!1)},a.BaseViewer=x},(O,a,v)=>{var u;Object.defineProperty(a,"__esModule",{value:!0}),a.PDFPageView=void 0;var g=v(3),f=v(6),r=v(13),p=v(4);const n=r.compatibilityParams.maxCanvasPixels||16777216;u=new WeakMap,a.PDFPageView=class s{constructor(d){ve(this,u,g.AnnotationMode.ENABLE_FORMS);const _=d.container,t=d.defaultViewport;this.id=d.id,this.renderingId="page"+this.id,this.pdfPage=null,this.pageLabel=null,this.rotation=0,this.scale=d.scale||f.DEFAULT_SCALE,this.viewport=t,this.pdfPageRotate=t.rotation,this._optionalContentConfigPromise=d.optionalContentConfigPromise||null,this.hasRestrictedScaling=!1,this.textLayerMode=d.textLayerMode??f.TextLayerMode.ENABLE,Te(this,u,d.annotationMode??g.AnnotationMode.ENABLE_FORMS),this.imageResourcesPath=d.imageResourcesPath||"",this.useOnlyCssZoom=d.useOnlyCssZoom||!1,this.maxCanvasPixels=d.maxCanvasPixels||n,this.pageColors=d.pageColors||null,this.eventBus=d.eventBus,this.renderingQueue=d.renderingQueue,this.textLayerFactory=d.textLayerFactory,this.annotationLayerFactory=d.annotationLayerFactory,this.xfaLayerFactory=d.xfaLayerFactory,this.textHighlighter=d.textHighlighterFactory?.createTextHighlighter(this.id-1,this.eventBus),this.structTreeLayerFactory=d.structTreeLayerFactory,this.renderer=d.renderer||f.RendererType.CANVAS,this.l10n=d.l10n||p.NullL10n,this.paintTask=null,this.paintedViewportMap=new WeakMap,this.renderingState=f.RenderingStates.INITIAL,this.resume=null,this._renderError=null,this._isStandalone=!this.renderingQueue?.hasViewer(),this._annotationCanvasMap=null,this.annotationLayer=null,this.textLayer=null,this.zoomLayer=null,this.xfaLayer=null,this.structTreeLayer=null;const i=document.createElement("div");i.className="page",i.style.width=Math.floor(this.viewport.width)+"px",i.style.height=Math.floor(this.viewport.height)+"px",i.setAttribute("data-page-number",this.id),i.setAttribute("role","region"),this.l10n.get("page_landmark",{page:this.id}).then(A=>{i.setAttribute("aria-label",A)}),this.div=i,_?.appendChild(i)}setPdfPage(d){this.pdfPage=d,this.pdfPageRotate=d.rotate,this.viewport=d.getViewport({scale:this.scale*g.PixelsPerInch.PDF_TO_CSS_UNITS,rotation:(this.rotation+this.pdfPageRotate)%360}),this.reset()}destroy(){this.reset(),this.pdfPage&&this.pdfPage.cleanup()}_renderAnnotationLayer(){var d=this;return y(function*(){let _=null;try{yield d.annotationLayer.render(d.viewport,"display")}catch(t){_=t}finally{d.eventBus.dispatch("annotationlayerrendered",{source:d,pageNumber:d.id,error:_})}})()}_renderXfaLayer(){var d=this;return y(function*(){let _=null;try{const t=yield d.xfaLayer.render(d.viewport,"display");d.textHighlighter&&d._buildXfaTextContentItems(t.textDivs)}catch(t){_=t}finally{d.eventBus.dispatch("xfalayerrendered",{source:d,pageNumber:d.id,error:_})}})()}_buildXfaTextContentItems(d){var _=this;return y(function*(){const t=yield _.pdfPage.getTextContent(),i=[];for(const A of t.items)i.push(A.str);_.textHighlighter.setTextMapping(d,i),_.textHighlighter.enable()})()}_resetZoomLayer(d=!1){if(!this.zoomLayer)return;const _=this.zoomLayer.firstChild;this.paintedViewportMap.delete(_),_.width=0,_.height=0,d&&this.zoomL
vendor: 11,268 bytes, line 1
1ayer.remove(),this.zoomLayer=null}reset({keepZoomLayer:d=!1,keepAnnotationLayer:_=!1,keepXfaLayer:t=!1}={}){this.cancelRendering({keepAnnotationLayer:_,keepXfaLayer:t}),this.renderingState=f.RenderingStates.INITIAL;const i=this.div;i.style.width=Math.floor(this.viewport.width)+"px",i.style.height=Math.floor(this.viewport.height)+"px";const A=i.childNodes,l=d&&this.zoomLayer||null,m=_&&this.annotationLayer?.div||null,x=t&&this.xfaLayer?.div||null;for(let M=A.length-1;M>=0;M--){const k=A[M];switch(k){case l:case m:case x:continue}k.remove()}i.removeAttribute("data-loaded"),m&&this.annotationLayer.hide(),x&&this.xfaLayer.hide(),l||(this.canvas&&(this.paintedViewportMap.delete(this.canvas),this.canvas.width=0,this.canvas.height=0,delete this.canvas),this._resetZoomLayer()),this.svg&&(this.paintedViewportMap.delete(this.svg),delete this.svg),this.loadingIconDiv=document.createElement("div"),this.loadingIconDiv.className="loadingIcon notVisible",this._isStandalone&&this.toggleLoadingIconSpinner(!0),this.loadingIconDiv.setAttribute("role","img"),this.l10n.get("loading").then(M=>{this.loadingIconDiv?.setAttribute("aria-label",M)}),i.appendChild(this.loadingIconDiv)}update({scale:d=0,rotation:_=null,optionalContentConfigPromise:t=null}){if(this.scale=d||this.scale,"number"==typeof _&&(this.rotation=_),t instanceof Promise&&(this._optionalContentConfigPromise=t),this.viewport=this.viewport.clone({scale:this.scale*g.PixelsPerInch.PDF_TO_CSS_UNITS,rotation:(this.rotation+this.pdfPageRotate)%360}),this._isStandalone){const{style:l}=document.documentElement;l.setProperty("--zoom-factor",this.scale)}if(this.svg)return this.cssTransform({target:this.svg,redrawAnnotationLayer:!0,redrawXfaLayer:!0}),void this.eventBus.dispatch("pagerendered",{source:this,pageNumber:this.id,cssTransform:!0,timestamp:performance.now(),error:this._renderError});let A=!1;if(this.canvas&&this.maxCanvasPixels>0){const l=this.outputScale;(Math.floor(this.viewport.width)*l.sx|0)*(Math.floor(this.viewport.height)*l.sy|0)>this.maxCanvasPixels&&(A=!0)}if(this.canvas){if(this.useOnlyCssZoom||this.hasRestrictedScaling&&A)return this.cssTransform({target:this.canvas,redrawAnnotationLayer:!0,redrawXfaLayer:!0}),void this.eventBus.dispatch("pagerendered",{source:this,pageNumber:this.id,cssTransform:!0,timestamp:performance.now(),error:this._renderError});!this.zoomLayer&&!this.canvas.hidden&&(this.zoomLayer=this.canvas.parentNode,this.zoomLayer.style.position="absolute")}this.zoomLayer&&this.cssTransform({target:this.zoomLayer.firstChild}),this.reset({keepZoomLayer:!0,keepAnnotationLayer:!0,keepXfaLayer:!0})}cancelRendering({keepAnnotationLayer:d=!1,keepXfaLayer:_=!1}={}){this.paintTask&&(this.paintTask.cancel(),this.paintTask=null),this.resume=null,this.textLayer&&(this.textLayer.cancel(),this.textLayer=null),this.annotationLayer&&(!d||!this.annotationLayer.div)&&(this.annotationLayer.cancel(),this.annotationLayer=null,this._annotationCanvasMap=null),this.xfaLayer&&(!_||!this.xfaLayer.div)&&(this.xfaLayer.cancel(),this.xfaLayer=null,this.textHighlighter?.disable()),this._onTextLayerRendered&&(this.eventBus._off("textlayerrendered",this._onTextLayerRendered),this._onTextLayerRendered=null)}cssTransform({target:d,redrawAnnotationLayer:_=!1,redrawXfaLayer:t=!1}){const i=this.viewport.width,A=this.viewport.height,l=this.div;d.style.width=d.parentNode.style.width=l.style.width=Math.floor(i)+"px",d.style.height=d.parentNode.style.height=l.style.height=Math.floor(A)+"px";const m=this.viewport.rotation-this.paintedViewportMap.get(d).rotation,x=Math.abs(m);let M=1,k=1;if((90===x||270===x)&&(M=A/i,k=i/A),d.style.transform=`rotate(${m}deg) scale(${M}, ${k})`,this.textLayer){const I=this.textLayer.viewport,X=Math.abs(this.viewport.rotation-I.rotation);let J=i/I.width;(90===X||270===X)&&(J=i/I.height);const N=this.textLayer.textLayerDiv;let $,K;switch(X){case 0:$=K=0;break;case 90:$=0,K="-"+N.style.height;break;case 180:$="-"+N.style.width,K="-"+N.style.height;break;case 270:$="-"+N.style.width,K=0;break;default:console.error("Bad rotation value.")}N.style.transform=`rotate(${X}deg) scale(${J}) translate(${$}, ${K})`,N.style.transformOrigin="0% 0%"}_&&this.annotationLayer&&this._renderAnnotationLayer(),t&&this.xfaLayer&&this._renderXfaLayer()}get width(){return this.viewport.width}get height(){return this.viewport.height}getPagePoint(d,_){return this.viewport.convertToPdfPoint(d,_)}toggleLoadingIconSpinner(d=!1){this.loadingIconDiv?.classList.toggle("notVisible",!d)}draw(){var d=this;this.renderingState!==f.RenderingStates.INITIAL&&(console.error("Must be in new state before drawing"),this.reset());const{div:_,pdfPage:t}=this;if(!t)return this.renderingState=f.RenderingStates.FINISHED,this.loadingIconDiv&&(this.loadingIconDiv.remove(),delete this.loadingIconDiv),Promise.reject(new Error("pdfPage is not loaded"));this.renderingState=f.RenderingStates.RUNNING;const i=document.createElement("div");i.style.width=_.style.width,i.style.height=_.style.height,i.classList.add("canvasWrapper"),this.annotationLayer?.div?_.insertBefore(i,this.annotationLayer.div):_.appendChild(i);let A=null;if(this.textLayerMode!==f.TextLayerMode.DISABLE&&this.textLayerFactory){const k=document.createElement("div");k.className="textLayer",k.style.width=i.style.width,k.style.height=i.style.height,this.annotationLayer?.div?_.insertBefore(k,this.annotationLayer.div):_.appendChild(k),A=this.textLayerFactory.createTextLayerBuilder(k,this.id-1,this.viewport,this.textLayerMode===f.TextLayerMode.ENABLE_ENHANCE,this.eventBus,this.textHighlighter)}this.textLayer=A,Ae(this,u)!==g.AnnotationMode.DISABLE&&this.annotationLayerFactory&&(this._annotationCanvasMap||(this._annotationCanvasMap=new Map),this.annotationLayer||(this.annotationLayer=this.annotationLayerFactory.createAnnotationLayerBuilder(_,t,null,this.imageResourcesPath,Ae(this,u)===g.AnnotationMode.ENABLE_FORMS,this.l10n,null,null,null,null,this._annotationCanvasMap))),this.xfaLayer?.div&&_.appendChild(this.xfaLayer.div);let l=null;this.renderingQueue&&(l=k=>{if(!this.renderingQueue.isHighestPriority(this))return this.renderingState=f.RenderingStates.PAUSED,void(this.resume=()=>{this.renderingState=f.RenderingStates.RUNNING,k()});k()});const m=function(){var k=y(function*(I=null){if(x===d.paintTask&&(d.paintTask=null),I instanceof g.RenderingCancelledException)d._renderError=null;else if(d._renderError=I,d.renderingState=f.RenderingStates.FINISHED,d.loadingIconDiv&&(d.loadingIconDiv.remove(),delete d.loadingIconDiv),d._resetZoomLayer(!0),d.eventBus.dispatch("pagerendered",{source:d,pageNumber:d.id,cssTransform:!1,timestamp:performance.now(),error:d._renderError}),I)throw I});return function(){return k.apply(this,arguments)}}(),x=this.renderer===f.RendererType.SVG?this.paintOnSvg(i):this.paintOnCanvas(i);x.onRenderContinue=l,this.paintTask=x;const M=x.promise.then(()=>m(null).then(()=>{if(A){const k=t.streamTextContent({includeMarkedContent:!0});A.setTextContentStream(k),A.render()}this.annotationLayer&&this._renderAnnotationLayer()}),function(k){return m(k)});return this.xfaLayerFactory&&(this.xfaLayer||(this.xfaLayer=this.xfaLayerFactory.createXfaLayerBuilder(_,t,null)),this._renderXfaLayer()),this.structTreeLayerFactory&&this.textLayer&&this.canvas&&(this._onTextLayerRendered=k=>{k.pageNumber===this.id&&(this.eventBus._off("textlayerrendered",this._onTextLayerRendered),this._onTextLayerRendered=null,this.canvas&&this.pdfPage.getStructTree().then(I=>{if(!I||!this.canvas)return;const j=this.structTreeLayer.render(I);j.classList.add("structTree"),this.canvas.appendChild(j)}))},this.eventBus._on("textlayerrendered",this._onTextLayerRendered),this.structTreeLayer=this.structTreeLayerFactory.createStructTreeLayerBuilder(t)),_.setAttribute("data-loaded",!0),this.eventBus.dispatch("pagerender",{source:this,pageNumber:this.id}),M}paintOnCanvas(d){const _=(0,g.createPromiseCapability)(),t={promise:_.promise,onRenderContinue(N){N()},cancel(){J.cancel()}},i=this.viewport,A=document.createElement("canvas");A.hidden=!0;let l=!0;const m=function(){l&&(A.hidden=!1,l=!1)};d.appendChild(A),this.canvas=A;const x=A.getContext("2d",{alpha:!1}),M=this.outputScale=new f.OutputScale;if(this.useOnlyCssZoom){const N=i.clone({scale:g.PixelsPerInch.PDF_TO_CSS_UNITS});M.sx*=N.width/i.width,M.sy*=N.height/i.height}if(this.maxCanvasPixels>0){const $=Math.sqrt(this.maxCanvasPixels/(i.width*i.height));M.sx>$||M.sy>$?(M.sx=$,M.sy=$,this.hasRestrictedScaling=!0):this.hasRestrictedScaling=!1}const k=(0,f.approximateFraction)(M.sx),I=(0,f.approximateFraction)(M.sy);A.width=(0,f.roundToDivide)(i.width*M.sx,k[0]),A.height=(0,f.roundToDivide)(i.height*M.sy,I[0]),A.style.width=(0,f.roundToDivide)(i.width,k[1])+"px",A.style.height=(0,f.roundToDivide)(i.height,I[1])+"px",this.paintedViewportMap.set(A,i);const X={canvasContext:x,transform:M.scaled?[M.sx,0,0,M.sy,0,0]:null,viewport:this.viewport,annotationMode:Ae(this,u),optionalContentConfigPromise:this._optionalContentConfigPromise,annotationCanvasMap:this._annotationCanvasMap,pageColors:this.pageColors},J=this.pdfPage.render(X);return J.onContinue=function(N){m(),t.onRenderContinue?t.onRenderContinue(N):N()},J.promise.then(function(){m(),_.resolve()},function(N){m(),_.reject(N)}),t}paintOnSvg(d){let _=!1;const t=()=>{if(_)throw new g.RenderingCancelledException(`Rendering cancelled, page ${this.id}`,"svg")},i=this.pdfPage,A=this.viewport.clone({scale:g.PixelsPerInch.PDF_TO_CSS_UNITS});return{promise:i.getOperatorList({annotationMode:Ae(this,u)}).then(m=>(t(),new g.SVGGraphics(i.commonObjs,i.objs).getSVG(m,A).then(M=>{t(),this.svg=M,this.paintedViewportMap.set(M,A),M.style.width=d.style.width,M.style.height=d.style.height,this.renderingState=f.RenderingStates.FINISHED,d.appendChild(M)}))),onRenderContinue(m){m()},cancel(){_=!0}}}setPageLabel(d){this.pageLabel="string"==typeof d?d:null,null!==this.pageLabel?this.div.setAttribute("data-page-label",this.pageLabel):this.div.removeAttribute("data-page-label")}}},(O,a)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.compatibilityParams=a.OptionKind=a.AppOptions=void 0;const v=Object.create(null);a.compatibilityParams=v;{const n=navigator.userAgent||"",s=navigator.platform||"",u=navigator.maxTouchPoints||1,S=/Android/.test(n);(/\b(iPad|iPhone|iPod)(?=;)/.test(n)||"MacIntel"===s&&u>1||S)&&(v.maxCanvasPixels=5242880)}const g={VIEWER:2,API:4,WORKER:8,PREFERENCE:128};a.OptionKind=g;const f={annotationMode:{value:2,kind:g.VIEWER+g.PREFERENCE},cursorToolOnLoad:{value:0,kind:g.VIEWER+g.PREFERENCE},defaultUrl:{value:"compressed.tracemonkey-pldi-09.pdf",kind:g.VIEWER},defaultZoomValue:{value:"",kind:g.VIEWER+g.PREFERENCE},disableHistory:{value:!1,kind:g.VIEWER},disablePageLabels:{value:!1,kind:g.VIEWER+g.PREFERENCE},enablePermissions:{value:!1,kind:g.VIEWER+g.PREFERENCE},enablePrintAutoRotate:{value:!0,kind:g.VIEWER+g.PREFERENCE},enableScripting:{value:!0,kind:g.VIEWER+g.PREFERENCE},externalLinkRel:{value:"noopener noreferrer nofollow",kind:g.VIEWER},externalLinkTarget:{value:0,kind:g.VIEWER+g.PREFERENCE},historyUpdateUrl:{value:!1,kind:g.VIEWER+g.PREFERENCE},ignoreDestinationZoom:{value:!1,kind:g.VIEWER+g.PREFERENCE},imageResourcesPath:{value:"./images/",kind:g.VIEWER},maxCanvasPixels:{value:16777216,compatibility:v.maxCanvasPixels,kind:g.VIEWER}
1,pageColorsBackground:{value:"Canvas",kind:g.VIEWER+g.PREFERENCE},pageColorsForeground:{value:"CanvasText",kind:g.VIEWER+g.PREFERENCE},pdfBugEnabled:{value:!1,kind:g.VIEWER+g.PREFERENCE},printResolution:{value:150,kind:g.VIEWER},renderer:{value:"canvas",kind:g.VIEWER},sidebarViewOnLoad:{value:-1,kind:g.VIEWER+g.PREFERENCE},scrollModeOnLoad:{value:-1,kind:g.VIEWER+g.PREFERENCE},spreadModeOnLoad:{value:-1,kind:g.VIEWER+g.PREFERENCE},textLayerMode:{value:1,kind:g.VIEWER+g.PREFERENCE},useOnlyCssZoom:{value:!1,kind:g.VIEWER+g.PREFERENCE},viewerCssTheme:{value:0,kind:g.VIEWER+g.PREFERENCE},viewOnLoad:{value:0,kind:g.VIEWER+g.PREFERENCE},cMapPacked:{value:!0,kind:g.API},cMapUrl:{value:"../web/cmaps/",kind:g.API},disableAutoFetch:{value:!1,kind:g.API+g.PREFERENCE},disableFontFace:{value:!1,kind:g.API+g.PREFERENCE},disableRange:{value:!1,kind:g.API+g.PREFERENCE},disableStream:{value:!1,kind:g.API+g.PREFERENCE},docBaseUrl:{value:"",kind:g.API},enableXfa:{value:!0,kind:g.API+g.PREFERENCE},fontExtraProperties:{value:!1,kind:g.API},isEvalSupported:{value:!0,kind:g.API},maxImageSize:{value:-1,kind:g.API},pdfBug:{value:!1,kind:g.API},standardFontDataUrl:{value:"../web/standard_fonts/",kind:g.API},verbosity:{value:1,kind:g.API},workerPort:{value:null,kind:g.WORKER},workerSrc:{value:"../build/pdf.worker.js",kind:g.WORKER}};f.disablePreferences={value:!1,kind:g.VIEWER},f.locale={value:navigator.language||"en-US",kind:g.VIEWER},f.sandboxBundleSrc={value:"../build/pdf.sandbox.js",kind:g.VIEWER},f.renderer.kind+=g.PREFERENCE;const r=Object.create(null);a.AppOptions=class p{constructor(){throw new Error("Cannot initialize AppOptions.")}static get(s){const u=r[s];if(void 0!==u)return u;const S=f[s];return void 0!==S?S.compatibility??S.value:void 0}static getAll(s=null){const u=Object.create(null);for(const S in f){const d=f[S];if(s){if(0==(s&d.kind))continue;if(s===g.PREFERENCE){const t=d.value,i=typeof t;if("boolean"===i||"string"===i||"number"===i&&Number.isInteger(t)){u[S]=t;continue}throw new Error(`Invalid type for preference: ${S}`)}}const _=r[S];u[S]=void 0!==_?_:d.compatibility??d.value}return u}static set(s,u){r[s]=u}static setAll(s){for(const u in s)r[u]=s[u]}static remove(s){delete r[s]}static _hasUserOptions(){return Object.keys(r).length>0}}},(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.PDFRenderingQueue=void 0;var g=v(3),f=v(6);a.PDFRenderingQueue=class p{constructor(){this.pdfViewer=null,this.pdfThumbnailViewer=null,this.onIdle=null,this.highestPriorityPage=null,this.idleTimeout=null,this.printing=!1,this.isThumbnailViewEnabled=!1}setViewer(s){this.pdfViewer=s}setThumbnailViewer(s){this.pdfThumbnailViewer=s}isHighestPriority(s){return this.highestPriorityPage===s.renderingId}hasViewer(){return!!this.pdfViewer}renderHighestPriority(s){this.idleTimeout&&(clearTimeout(this.idleTimeout),this.idleTimeout=null),!this.pdfViewer.forceRendering(s)&&(this.isThumbnailViewEnabled&&this.pdfThumbnailViewer?.forceRendering()||this.printing||this.onIdle&&(this.idleTimeout=setTimeout(this.onIdle.bind(this),3e4)))}getHighestPriority(s,u,S,d=!1){const _=s.views,t=_.length;if(0===t)return null;for(let x=0;x<t;
vendor: 16,759 bytes, line 1
1x++){const M=_[x].view;if(!this.isViewFinished(M))return M}const i=s.first.id,A=s.last.id;if(A-i+1>t){const x=s.ids;for(let M=1,k=A-i;M<k;M++){const I=S?i+M:A-M;if(x.has(I))continue;const j=u[I-1];if(!this.isViewFinished(j))return j}}let l=S?A:i-2,m=u[l];return m&&!this.isViewFinished(m)||d&&(l+=S?1:-1,m=u[l],m&&!this.isViewFinished(m))?m:null}isViewFinished(s){return s.renderingState===f.RenderingStates.FINISHED}renderView(s){switch(s.renderingState){case f.RenderingStates.FINISHED:return!1;case f.RenderingStates.PAUSED:this.highestPriorityPage=s.renderingId,s.resume();break;case f.RenderingStates.RUNNING:this.highestPriorityPage=s.renderingId;break;case f.RenderingStates.INITIAL:this.highestPriorityPage=s.renderingId,s.draw().finally(()=>{this.renderHighestPriority()}).catch(u=>{u instanceof g.RenderingCancelledException||console.error(`renderView: "${u}"`)})}return!0}}},(O,a)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.TextHighlighter=void 0,a.TextHighlighter=class v{constructor({findController:f,eventBus:r,pageIndex:p}){this.findController=f,this.matches=[],this.eventBus=r,this.pageIdx=p,this._onUpdateTextLayerMatches=null,this.textDivs=null,this.textContentItemsStr=null,this.enabled=!1}setTextMapping(f,r){this.textDivs=f,this.textContentItemsStr=r}enable(){if(!this.textDivs||!this.textContentItemsStr)throw new Error("Text divs and strings have not been set.");if(this.enabled)throw new Error("TextHighlighter is already enabled.");this.enabled=!0,this._onUpdateTextLayerMatches||(this._onUpdateTextLayerMatches=f=>{(f.pageIndex===this.pageIdx||-1===f.pageIndex)&&this._updateMatches()},this.eventBus._on("updatetextlayermatches",this._onUpdateTextLayerMatches)),this._updateMatches()}disable(){!this.enabled||(this.enabled=!1,this._onUpdateTextLayerMatches&&(this.eventBus._off("updatetextlayermatches",this._onUpdateTextLayerMatches),this._onUpdateTextLayerMatches=null))}_convertMatches(f,r){if(!f)return[];const{textContentItemsStr:p}=this;let n=0,s=0;const u=p.length-1,S=[];for(let d=0,_=f.length;d<_;d++){let t=f[d];for(;n!==u&&t>=s+p[n].length;)s+=p[n].length,n++;n===p.length&&console.error("Could not find a matching mapping");const i={begin:{divIdx:n,offset:t-s}};for(t+=r[d];n!==u&&t>s+p[n].length;)s+=p[n].length,n++;i.end={divIdx:n,offset:t-s},S.push(i)}return S}_renderMatches(f){if(0===f.length)return;const{findController:r,pageIdx:p}=this,{textContentItemsStr:n,textDivs:s}=this,u=p===r.selected.pageIdx,S=r.selected.matchIdx;let _=null;function i(x,M){const k=x.divIdx;return s[k].textContent="",A(k,0,x.offset,M)}function A(x,M,k,I){let j=s[x];if(j.nodeType===Node.TEXT_NODE){const N=document.createElement("span");j.parentNode.insertBefore(N,j),N.appendChild(j),s[x]=N,j=N}const X=n[x].substring(M,k),J=document.createTextNode(X);if(I){const N=document.createElement("span");return N.className=`${I} appended`,N.appendChild(J),j.appendChild(N),I.includes("selected")?N.offsetLeft:0}return j.appendChild(J),0}let l=S,m=l+1;if(r.state.highlightAll)l=0,m=f.length;else if(!u)return;for(let x=l;x<m;x++){const M=f[x],k=M.begin,I=M.end,j=u&&x===S,X=j?" selected":"";let J=0;if(_&&k.divIdx===_.divIdx?A(_.divIdx,_.offset,k.offset):(null!==_&&A(_.divIdx,_.offset,undefined),i(k)),k.divIdx===I.divIdx)J=A(k.divIdx,k.offset,I.offset,"highlight"+X);else{J=A(k.divIdx,k.offset,undefined,"highlight begin"+X);for(let N=k.divIdx+1,$=I.divIdx;N<$;N++)s[N].className="highlight middle"+X;i(I,"highlight end"+X)}_=I,j&&r.scrollMatchIntoView({element:s[k.divIdx],selectedLeft:J,pageIndex:p,matchIndex:S})}_&&A(_.divIdx,_.offset,undefined)}_updateMatches(){if(!this.enabled)return;const{findController:f,matches:r,pageIdx:p}=this,{textContentItemsStr:n,textDivs:s}=this;let u=-1;for(let _=0,t=r.length;_<t;_++){const i=r[_];for(let l=Math.max(u,i.begin.divIdx),m=i.end.divIdx;l<=m;l++){const x=s[l];x.textContent=n[l],x.className=""}u=i.end.divIdx+1}f?.highlightMatches&&(this.matches=this._convertMatches(f.pageMatches[p]||null,f.pageMatchesLength[p]||null),this._renderMatches(this.matches))}}},(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.DownloadManager=void 0;var g=v(3);function f(p,n){const s=document.createElement("a");if(!s.click)throw new Error('DownloadManager: "a.click()" is not supported.');s.href=p,s.target="_parent","download"in s&&(s.download=n),(document.body||document.documentElement).appendChild(s),s.click(),s.remove()}a.DownloadManager=class r{constructor(){this._openBlobUrls=new WeakMap}downloadUrl(n,s){(0,g.createValidAbsoluteUrl)(n,"http://example.com")?f(n+"#pdfjs.action=download",s):console.error(`downloadUrl - not a valid URL: ${n}`)}downloadData(n,s,u){f(URL.createObjectURL(new Blob([n],{type:u})),s)}openOrDownloadData(n,s,u){const S=(0,g.isPdfFile)(u),d=S?"application/pdf":"";if(S){let t,_=this._openBlobUrls.get(n);_||(_=URL.createObjectURL(new Blob([s],{type:d})),this._openBlobUrls.set(n,_)),t="?file="+encodeURIComponent(_+"#"+u);try{return window.open(t),!0}catch(i){console.error(`openOrDownloadData: ${i}`),URL.revokeObjectURL(_),this._openBlobUrls.delete(n)}}return this.downloadData(s,u,d),!1}download(n,s,u,S="download"){f(URL.createObjectURL(n),u)}}},(O,a)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.WaitOnType=a.EventBus=a.AutomationEventBus=void 0,a.waitOnEventOrTimeout=function g({target:p,name:n,delay:s=0}){return new Promise(function(u,S){if("object"!=typeof p||!n||"string"!=typeof n||!(Number.isInteger(s)&&s>=0))throw new Error("waitOnEventOrTimeout - invalid parameters.");function d(A){p instanceof f?p._off(n,_):p.removeEventListener(n,_),i&&clearTimeout(i),u(A)}const _=d.bind(null,v.EVENT);p instanceof f?p._on(n,_):p.addEventListener(n,_);const t=d.bind(null,v.TIMEOUT),i=setTimeout(t,s)})};const v={EVENT:"event",TIMEOUT:"timeout"};a.WaitOnType=v;class f{constructor(){this._listeners=Object.create(null)}on(n,s,u=null){this._on(n,s,{external:!0,once:u?.once})}off(n,s,u=null){this._off(n,s,{external:!0,once:u?.once})}dispatch(n,s){const u=this._listeners[n];if(!u||0===u.length)return;let S;for(const{listener:d,external:_,once:t}of u.slice(0))t&&this._off(n,d),_?(S||(S=[])).push(d):d(s);if(S){for(const d of S)d(s);S=null}}_on(n,s,u=null){var d;((d=this._listeners)[n]||(d[n]=[])).push({listener:s,external:!0===u?.external,once:!0===u?.once})}_off(n,s,u=null){const S=this._listeners[n];if(S)for(let d=0,_=S.length;d<_;d++)if(S[d].listener===s)return void S.splice(d,1)}}a.EventBus=f,a.AutomationEventBus=class r extends f{dispatch(n,s){throw new Error("Not implemented: AutomationEventBus.dispatch")}}},(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.GenericL10n=void 0,v(19);var g=v(4);const f=document.webL10n;a.GenericL10n=class r{constructor(n){this._lang=n,this._ready=new Promise((s,u)=>{f.setLanguage((0,g.fixupLangCode)(n),()=>{s(f)})})}getLanguage(){var n=this;return y(function*(){return(yield n._ready).getLanguage()})()}getDirection(){var n=this;return y(function*(){return(yield n._ready).getDirection()})()}get(n,s=null,u=(0,g.getL10nFallback)(n,s)){var S=this;return y(function*(){return(yield S._ready).get(n,s,u)})()}translate(n){var s=this;return y(function*(){return(yield s._ready).translate(n)})()}}},()=>{document.webL10n=function(O,a,v){var g={},f="",r="textContent",p="",n={},s="loading";function i(N,$,K){$=$||function(T){},K=K||function(){};var te=new XMLHttpRequest;te.open("GET",N,!0),te.overrideMimeType&&te.overrideMimeType("text/plain; charset=utf-8"),te.onreadystatechange=function(){4==te.readyState&&(200==te.status||0===te.status?$(te.responseText):K())},te.onerror=K,te.ontimeout=K;try{te.send(null)}catch{K()}}function l(N,$){N&&(N=N.toLowerCase()),$=$||function(){},function m(){g={},f="",p=""}(),p=N;var K=function S(){return a.querySelectorAll('link[type="application/l10n"]')}(),te=K.length;if(0!==te){var h,e=0;h=function(){++e>=te&&($(),s="complete")};for(var b=0;b<te;b++)new c(K[b]).load(N,h)}else{var se=function d(){var N=a.querySelector('script[type="application/l10n"]');return N?JSON.parse(N.innerHTML):null}();if(se&&se.locales&&se.default_locale){if(console.log("using the embedded JSON directory, early way out"),!(g=se.locales[N])){var T=se.default_locale.toLowerCase();for(var o in se.locales){if((o=o.toLowerCase())===N){g=se.locales[N];break}o===T&&(g=se.locales[T])}}$()}else console.log("no resource to load, early way out");s="complete"}function c(C){var E=C.href;this.load=function(B,U){!function A(N,$,K,te){var se=N.replace(/[^\/]*$/,"")||"./";function T(h){return h.lastIndexOf("\\")<0?h:h.replace(/\\\\/g,"\\").replace(/\\n/g,"\n").replace(/\\r/g,"\r").replace(/\\t/g,"\t").replace(/\\b/g,"\b").replace(/\\f/g,"\f").replace(/\\{/g,"{").replace(/\\}/g,"}").replace(/\\"/g,'"').replace(/\\'/g,"'")}i(N,function(h){f+=h,function o(h,e){var c={},b=/^\s*|\s*$/,w=/^\s*#|^\s*$/,C=/^\s*\[(.*)\]\s*$/,E=/^\s*@import\s+url\((.*)\)\s*$/i,B=/^([^=\s]*)\s*=\s*(.+)$/;function U(z,Y,ee){var ce=z.replace(b,"").split(/[\r\n]+/),be="*",Q=$.split("-",1)[0],re=!1,ie="";!function P(){for(;;){if(!ce.length)return void ee();var D=ce.shift();if(!w.test(D)){if(Y){if(ie=C.exec(D)){be=ie[1].toLowerCase(),re="*"!==be&&be!==$&&be!==Q;continue}if(re)continue;if(ie=E.exec(D))return void V(se+ie[1],P)}var q=D.match(B);q&&3==q.length&&(c[q[1]]=T(q[2]))}}}()}function V(z,Y){i(z,function(ee){U(ee,!1,Y)},function(){console.warn(z+" not found."),Y()})}U(h,!0,function(){e(c)})}(h,function(e){for(var c in e){var b,w,C=c.lastIndexOf(".");C>0?(b=c.substring(0,C),w=c.substring(C+1)):(b=c,w=r),g[b]||(g[b]={}),g[b][w]=e[c]}K&&K()})},te)}(E,B,U,function(){console.warn(E+" not found."),console.warn('"'+B+'" resource not found'),p="",U()})}}}function M(N,$,K){var te=g[N];if(!te){if(console.warn("#"+N+" is undefined."),!K)return null;te=K}var se={};for(var T in te){var o=te[T];o=I(o=k(o,$,N,T),$,N),se[T]=o}return se}function k(N,$,K,te){var T=/\{\[\s*([a-zA-Z]+)\(([a-zA-Z]+)\)\s*\]\}/.exec(N);if(!T||!T.length)return N;var e,o=T[1],h=T[2];return $&&h in $?e=$[h]:h in g&&(e=g[h]),o in n&&(N=(0,n[o])(N,e,K,te)),N}function I(N,$,K){return N.replace(/\{\{\s*(.+?)\s*\}\}/g,function(se,T){return $&&T in $?$[T]:T in g?g[T]:(console.log("argument {{"+T+"}} for #"+K+" is undefined."),se)})}function j(N){var $=function t(N){if(!N)return{};var $=N.getAttribute("data-l10n-id"),K=N.getAttribute("data-l10n-args"),te={};if(K)try{te=JSON.parse(K)}catch{console.warn("could not parse arguments for #"+$)}return{id:$,args:te}}(N);if($.id){var K=M($.id,$.args);if(!K)return void console.warn("#"+$.id+" is undefined.");if(K[r]){if(0===function X(N){if(N.children)return N.children.length;if(typeof N.childElementCount<"u")return N.childElementCount;for(var $=0,K=0;K<N.childNodes.length;K++)$+=1===N.nodeType?1:0;return $}(N))N[r]=K[r];else{for(var te=N.childNodes,se=!1,T=0,o=te.length;T<o;T++)3===te[T].nodeType&&/\S/.test(te[T].nodeValue)&&(se?te[T].nodeValue="":(te[T].nodeValue=K[r],se=!0));if(!se){var h=a.createTextNode(K[r]);N.insertBefore(h,N.firstChild)}}delete K[r]}for(var e in K)N[e]=K[e]}}return n.plural=function(N,$,K,te){var se=parseFloat($);if(isNaN(se)||te!=r)return N;n._pluralRules||(n._pluralRules=function x(N){function K(o,h){return-1!==h.indexOf(o)}function te(o,h,e){return h<=o&&o<=e}var se={0:function(o){return"other"},1:function(o){return te(o%100,3,10)?"few":0===o?"zero":te(o%100,11,99)?"many":2==o?"two":1==o?"one":"other"},2:function(o){return 0!==o&&o%10==0?"many":2==o?"two":1==o?"one":"other"},3:function(o){return 1==o?"one":"other"},4:function(o){return te(o,0,1)?"one":"other"},5:function(o){return te(o,0,2)&&2!=o?"one":"other"},6:function(o){return 0===o?"zero":o%10==1&&o%100!=11?"one":"other"},7:function(o){return 2==o?"two":1==o?"one":"other"},8:function(o){return te(o,3,6)?"few":te(o,7,10)?"many":2==o?"two":1==o?"one":"other"},9:function(o){return 0===o||1!=o&&te(o%100,1,19)?"few":1==o?"one":"other"},10:function(o){return te(o%10,2,9)&&!te(o%100,11,19)?"few":o%10!=1||te(o%100,11,19)?"other":"one"},11:function(o){return te(o%10,2,4)&&!te(o%100,12,14)?"few":o%10==0||te(o%10,5,9)||te(o%100,11,14)?"many":o%10==1&&o%100!=11?"one":"other"},12:function(o){return te(o,2,4)?"few":1==o?"one":"other"},13:function(o){return te(o%10,2,4)&&!te(o%100,12,14)?"few":1!=o&&te(o%10,0,1)||te(o%10,5,9)||te(o%100,12,14)?"many":1==o?"one":"other"},14:function(o){return te(o%100,3,4)?"few":o%100==2?"two":o%100==1?"one":"other"},15:function(o){return 0===o||te(o%100,2,10)?"few":te(o%100,11,19)?"many":1==o?"one":"other"},16:function(o){return o%10==1&&11!=o?"one":"other"},17:function(o){return 3==o?"few":0===o?"zero":6==o?"many":2==o?"two":1==o?"one":"other"},18:function(o){return 0===o?"zero":te(o,0,2)&&0!==o&&2!=o?"one":"other"},19:function(o){return te(o,2,10)?"few":te(o,0,1)?"one":"other"},20:function(o){return!te(o%10,3,4)&&o%10!=9||te(o%100,10,19)||te(o%100,70,79)||te(o%100,90,99)?o%1e6==0&&0!==o?"many":o%10!=2||K(o%100,[12,72,92])?o%10!=1||K(o%100,[11,71,91])?"other":"one":"two":"few"},21:function(o){return 0===o?"zero":1==o?"one":"other"},22:function(o){return te(o,0,1)||te(o,11,99)?"one":"other"},23:function(o){return te(o%10,1,2)||o%20==0?"one":"other"},24:function(o){return te(o,3,10)||te(o,13,19)?"few":K(o,[2,12])?"two":K(o,[1,11])?"one":"other"}},T={af:3,ak:4,am:4,ar:1,asa:3,az:0,be:11,bem:3,bez:3,bg:3,bh:4,bm:0,bn:3,bo:0,br:20,brx:3,bs:11,ca:3,cgg:3,chr:3,cs:12,cy:17,da:3,de:3,dv:3,dz:0,ee:3,el:3,en:3,eo:3,es:3,et:3,eu:3,fa:0,ff:5,fi:3,fil:4,fo:3,fr:5,fur:3,fy:3,ga:8,gd:24,gl:3,gsw:3,gu:3,guw:4,gv:23,ha:3,haw:3,he:2,hi:4,hr:11,hu:0,id:0,ig:0,ii:0,is:3,it:3,iu:7,ja:0,jmc:3,jv:0,ka:0,kab:5,kaj:3,kcg:3,kde:0,kea:0,kk:3,kl:3,km:0,kn:0,ko:0,ksb:3,ksh:21,ku:3,kw:7,lag:18,lb:3,lg:3,ln:4,lo:0,lt:10,lv:6,mas:3,mg:4,mk:16,ml:3,mn:3,mo:9,mr:3,ms:0,mt:15,my:0,nah:3,naq:7,nb:3,nd:3,ne:3,nl:3,nn:3,no:3,nr:3,nso:4,ny:3,nyn:3,om:3,or:3,pa:3,pap:3,pl:13,ps:3,pt:3,rm:3,ro:9,rof:3,ru:11,rwk:3,sah:0,saq:3,se:7,seh:3,ses:0,sg:0,sh:11,shi:19,sk:12,sl:14,sma:7,smi:7,smj:7,smn:7,sms:7,sn:3,so:3,sq:3,sr:11,ss:3,ssy:3,st:3,sv:3,sw:3,syr:3,ta:3,te:3,teo:3,th:0,ti:4,tig:3,tk:3,tl:4,tn:3,to:0,tr:0,ts:3,tzm:22,uk:11,ur:3,ve:3,vi:0,vun:3,wa:4,wae:3,wo:0,xh:3,xog:3,yo:0,zh:0,zu:3}[N.replace(/-.*$/,"")];return T in se?se[T]:(console.warn("plural form unknown for ["+N+"]"),function(){return"other"})}(p));var T="["+n._pluralRules(se)+"]";return 0===se&&K+"[zero]"in g?N=g[K+"[zero]"][te]:1==se&&K+"[one]"in g?N=g[K+"[one]"][te]:2==se&&K+"[two]"in g?N=g[K+"[two]"][te]:K+T in g?N=g[K+T][te]:K+"[other]"in g&&(N=g[K+"[other]"][te]),N},{get:function(N,$,K){var T,te=N.lastIndexOf("."),se=r;te>0&&(se=N.substring(te+1),N=N.substring(0,te)),K&&((T={})[se]=K);var o=M(N,$,T);return o&&se in o?o[se]:"{{"+N+"}}"},getData:function(){return g},getText:function(){return f},getLanguage:function(){return p},setLanguage:function(N,$){l(N,function(){$&&$()})},getDirection:function(){var $=p.split("-",1)[0];return["ar","he","fa","ps","ur"].indexOf($)>=0?"rtl":"ltr"},translate:function J(N){for(var $=function _(N){return N?N.querySelectorAll("*[data-l10n-id]"):[]}(N=N||a.documentElement),K=$.length,te=0;te<K;te++)j($[te]);j(N)},getReadyState:function(){return s},ready:function(N){N&&("complete"==s||"interactive"==s?O.setTimeout(function(){N()}):a.addEventListener&&a.addEventListener("localized",function $(){a.removeEventListener("localized",$),N()}))}}}(window,document)},(O,a,v)=>{var I,mt,X,nt,N,it,K,bt,se,At,o,yt,e,rt,b,vt,C,St,B,Xe,V,He,Y,Ue,ce,Pt,Q,st,ie,at,D,$e,pe,Ct,he,ot,_e,wt,Ce,Ge;Object.defineProperty(a,"__esModule",{value:!0}),a.PDFFindController=a.FindState=void 0;var g=v(6),f=v(3),r=v(21);const p={FOUND:0,NOT_FOUND:1,WRAPPED:2,PENDING:3};a.FindState=p;const S={"\u2010":"-","\u2018":"'","\u2019":"'","\u201a":"'","\u201b":"'","\u201c":'"',"\u201d":'"',"\u201e":'"',"\u201f":'"',"\xbc":"1/4","\xbd":"1/2","\xbe":"3/4"},d=new Set([12441,12442,2381,2509,2637,2765,2893,3021,3149,3277,3387,3388,3405,3530,3642,3770,3972,4153,4154,5908,5940,6098,6752,6980,7082,7083,7154,7155,11647,43014,43052,43204,43347,43456,43766,44013,3158,3953,3954,3962,3963,3964,3965,3968,3956]),_=[...d.values()].map(Z=>String.fromCharCode(Z)).join(""),t=/\p{M}+/gu,i=/([.*+?^${}()|[\]\\])|(\p{P})|(\s+)|(\p{M})|(\p{L})/gu,A=/([^\p{M}])\p{M}*$/u,l=/^\p{M}*([^\p{M}])/u;let m=null;function x(Z){if(!m){const xe=Object.keys(S).join("");m=new RegExp(`([${xe}])|(\\p{M}+(?:-\\n)?)|(\\S-\\n)|(\\n)`,"gum")}const R=[];let F;for(;null!==(F=t.exec(Z));)R.push([F[0].length,F.index]);let ae=Z.normalize("NFD");const le=[[0,0]];let fe=0,ge=0,Pe=0,we=0,Me=!1;return ae=ae.replace(m,(xe,Re,ke,Be,Le,Fe)=>{if(Fe-=Pe,Re){const Oe=S[xe],Ne=Oe.length;for(let De=1;De<Ne;De++)le.push([Fe-ge+De,ge-De]);return ge-=Ne-1,Oe}if(ke){const Oe=ke.endsWith("\n"),Ne=Oe?ke.length-2:ke.length;Me=!0;let De=Ne;Fe+we===R[fe]?.[1]&&(De-=R[fe][0],++fe);for(let Ve=1;Ve<De+1;
1Ve++)le.push([Fe-1-ge+Ve,ge-Ve]);return ge-=De,Pe+=De,Oe?(le.push([(Fe+=Ne-1)-ge+1,1+ge]),ge+=1,Pe+=1,we+=1,ke.slice(0,Ne)):ke}return Be?(le.push([Fe-ge+1,1+ge]),ge+=1,Pe+=1,we+=1,Be.charAt(0)):(le.push([Fe-ge+1,ge-1]),ge-=1,Pe+=1,we+=1," ")}),le.push([ae.length,ge]),[ae,le,Me]}function M(Z,R,F){if(!Z)return[R,F];const ae=R,le=R+F;let fe=(0,g.binarySearchFirstItem)(Z,Pe=>Pe[0]>=ae);Z[fe][0]>ae&&--fe;let ge=(0,g.binarySearchFirstItem)(Z,Pe=>Pe[0]>=le,fe);return Z[ge][0]>le&&--ge,[ae+Z[fe][1],F+Z[ge][1]-Z[fe][1]]}I=new WeakSet,mt=function(R){if(!R)return;const F=this._pdfDocument,{type:ae}=R;(null===this._state||ye(this,K,bt).call(this,R))&&(this._dirtyMatch=!0),this._state=R,"highlightallchange"!==ae&&ye(this,Ce,Ge).call(this,p.PENDING),this._firstPageCapability.promise.then(()=>{if(!this._pdfDocument||F&&this._pdfDocument!==F)return;ye(this,C,St).call(this);const le=!this._highlightMatches,fe=!!this._findTimeout;this._findTimeout&&(clearTimeout(this._findTimeout),this._findTimeout=null),ae?this._dirtyMatch?ye(this,Y,Ue).call(this):"again"===ae?(ye(this,Y,Ue).call(this),le&&this._state.highlightAll&&ye(this,V,He).call(this)):"highlightallchange"===ae?(fe?ye(this,Y,Ue).call(this):this._highlightMatches=!0,ye(this,V,He).call(this)):ye(this,Y,Ue).call(this):this._findTimeout=setTimeout(()=>{ye(this,Y,Ue).call(this),this._findTimeout=null},250)})},X=new WeakSet,nt=function(){this._highlightMatches=!1,this._scrollMatches=!1,this._pdfDocument=null,this._pageMatches=[],this._pageMatchesLength=[],this._state=null,this._selected={pageIdx:-1,matchIdx:-1},this._offset={pageIdx:null,matchIdx:null,wrapped:!1},this._extractTextPromises=[],this._pageContents=[],this._pageDiffs=[],this._hasDiacritics=[],this._matchesCountTotal=0,this._pagesToSearch=null,this._pendingFindMatches=new Set,this._resumePageIdx=null,this._dirtyMatch=!1,clearTimeout(this._findTimeout),this._findTimeout=null,this._firstPageCapability=(0,f.createPromiseCapability)()},N=new WeakSet,it=function(){return this._state.query!==this._rawQuery&&(this._rawQuery=this._state.query,[this._normalizedQuery]=x(this._state.query)),this._normalizedQuery},K=new WeakSet,bt=function(R){if(R.query!==this._state.query)return!0;switch(R.type){case"again":const F=this._selected.pageIdx+1,ae=this._linkService;return F>=1&&F<=ae.pagesCount&&F!==ae.page&&!ae.isPageVisible(F);case"highlightallchange":return!1}return!0},se=new WeakSet,At=function(R,F,ae){let le=R.slice(0,F).match(A);if(le){const fe=R.charCodeAt(F),ge=le[1].charCodeAt(0);if((0,r.getCharacterType)(fe)===(0,r.getCharacterType)(ge))return!1}if(le=R.slice(F+ae).match(l),le){const fe=R.charCodeAt(F+ae-1),ge=le[1].charCodeAt(0);if((0,r.getCharacterType)(fe)===(0,r.getCharacterType)(ge))return!1}return!0},o=new WeakSet,yt=function(R,F,ae,le){const fe=[],ge=[],Pe=this._pageDiffs[ae];let we;for(;null!==(we=R.exec(le));){if(F&&!ye(this,se,At).call(this,le,we.index,we[0].length))continue;const[Me,xe]=M(Pe,we.index,we[0].length);xe&&(fe.push(Me),ge.push(xe))}this._pageMatches[ae]=fe,this._pageMatchesLength[ae]=ge},e=new WeakSet,rt=function(R,F){const{matchDiacritics:ae}=this._state;let le=!1;return(R=R.replace(i,(ge,Pe,we,Me,xe,Re)=>Pe?`[ ]*\\${Pe}[ ]*`:we?`[ ]*${we}[ ]*`:Me?"[ ]+":ae?xe||Re:xe?d.has(xe.charCodeAt(0))?xe:"":F?(le=!0,`${Re}\\p{M}*`):Re)).endsWith("[ ]*")&&(R=R.slice(0,R.length-"[ ]*".length)),ae&&F&&(le=!0,R=`${R}(?=[${_}]|[^\\p{M}]|$)`),[le,R]},b=new WeakSet,vt=function(R){let F=Ae(this,N,it);if(0===F.length)return;const{caseSensitive:ae,entireWord:le,phraseSearch:fe}=this._state,ge=this._pageContents[R],Pe=this._hasDiacritics[R];let we=!1;if(fe)[we,F]=ye(this,e,rt).call(this,F,Pe);else{const Re=F.match(/\S+/g);Re&&(F=Re.sort().reverse().map(ke=>{const[Be,Le]=ye(this,e,rt).call(this,ke,Pe);return we||(we=Be),`(${Le})`}).join("|"))}F=new RegExp(F,`g${we?"u":""}${ae?"":"i"}`),ye(this,o,yt).call(this,F,le,R,ge),this._state.highlightAll&&ye(this,B,Xe).call(this,R),this._resumePageIdx===R&&(this._resumePageIdx=null,ye(this,Q,st).call(this));const xe=this._pageMatches[R].length;xe>0&&(this._matchesCountTotal+=xe,ye(this,_e,wt).call(this))},C=new WeakSet,St=function(){if(this._extractTextPromises.length>0)return;
1let R=Promise.resolve();for(let F=0,ae=this._linkService.pagesCount;F<ae;F++){const le=(0,f.createPromiseCapability)();this._extractTextPromises[F]=le.promise,R=R.then(()=>this._pdfDocument.getPage(F+1).then(fe=>fe.getTextContent()).then(fe=>{const ge=[];for(const Pe of fe.items)ge.push(Pe.str),Pe.hasEOL&&ge.push("\n");[this._pageContents[F],this._pageDiffs[F],this._hasDiacritics[F]]=x(ge.join("")),le.resolve()},fe=>{console.error(`Unable to get text content for page ${F+1}`,fe),this._pageContents[F]="",this._pageDiffs[F]=null,this._hasDiacritics[F]=!1,le.resolve()}))}},B=new WeakSet,Xe=function(R){this._scrollMatches&&this._selected.pageIdx===R&&(this._linkService.page=R+1),this._eventBus.dispatch("updatetextlayermatches",{source:this,pageIndex:R})},V=new WeakSet,He=function(){this._eventBus.dispatch("updatetextlayermatches",{source:this,pageIndex:-1})},Y=new WeakSet,Ue=function(){const R=this._state.findPrevious,F=this._linkService.page-1,ae=this._linkService.pagesCount;if(this._highlightMatches=!0,this._dirtyMatch){this._dirtyMatch=!1,this._selected.pageIdx=this._selected.matchIdx=-1,this._offset.pageIdx=F,this._offset.matchIdx=null,this._offset.wrapped=!1,this._resumePageIdx=null,this._pageMatches.length=0,this._pageMatchesLength.length=0,this._matchesCountTotal=0,ye(this,V,He).call(this);for(let fe=0;fe<ae;
1fe++)this._pendingFindMatches.has(fe)||(this._pendingFindMatches.add(fe),this._extractTextPromises[fe].then(()=>{this._pendingFindMatches.delete(fe),ye(this,b,vt).call(this,fe)}))}if(""===Ae(this,N,it))return void ye(this,Ce,Ge).call(this,p.FOUND);if(this._resumePageIdx)return;const le=this._offset;if(this._pagesToSearch=ae,null!==le.matchIdx){const fe=this._pageMatches[le.pageIdx].length;if(!R&&le.matchIdx+1<fe||R&&le.matchIdx>0)return le.matchIdx=R?le.matchIdx-1:le.matchIdx+1,void ye(this,D,$e).call(this,!0);ye(this,ie,at).call(this,R)}ye(this,Q,st).call(this)},ce=new WeakSet,Pt=function(R){const F=this._offset,ae=R.length,le=this._state.findPrevious;return ae?(F.matchIdx=le?ae-1:0,ye(this,D,$e).call(this,!0),!0):(ye(this,ie,at).call(this,le),!!(F.wrapped&&(F.matchIdx=null,this._pagesToSearch<0))&&(ye(this,D,$e).call(this,!1),!0))},Q=new WeakSet,st=function(){null!==this._resumePageIdx&&console.error("There can only be one pending page.");let R=null;do{const F=this._offset.pageIdx;if(R=this._pageMatches[F],!R){this._resumePageIdx=F;break}}while(!ye(this,ce,Pt).call(this,R))},ie=new WeakSet,at=function(R){const F=this._offset,ae=this._linkService.pagesCount;F.pageIdx=R?F.pageIdx-1:F.pageIdx+1,F.matchIdx=null,this._pagesToSearch--,(F.pageIdx>=ae||F.pageIdx<0)&&(F.pageIdx=R?ae-1:0,F.wrapped=!0)},D=new WeakSet,$e=function(R=!1){let F=p.NOT_FOUND;const ae=this._offset.wrapped;if(this._offset.wrapped=!1,R){const le=this._selected.pageIdx;this._selected.pageIdx=this._offset.pageIdx,this._selected.matchIdx=this._offset.matchIdx,F=ae?p.WRAPPED:p.FOUND,-1!==le&&le!==this._selected.pageIdx&&ye(this,B,Xe).call(this,le)}ye(this,Ce,Ge).call(this,F,this._state.findPrevious),-1!==this._selected.pageIdx&&(this._scrollMatches=!0,ye(this,B,Xe).call(this,this._selected.pageIdx))},pe=new WeakSet,Ct=function(R){const F=this._pdfDocument;this._firstPageCapability.promise.then(()=>{!this._pdfDocument||F&&this._pdfDocument!==F||(this._findTimeout&&(clearTimeout(this._findTimeout),this._findTimeout=null),this._resumePageIdx&&(this._resumePageIdx=null,this._dirtyMatch=!0),ye(this,Ce,Ge).call(this,p.FOUND),this._highlightMatches=!1,ye(this,V,He).call(this))})},he=new WeakSet,ot=function(){const{pageIdx:R,matchIdx:F}=this._selected;let ae=0,le=this._matchesCountTotal;if(-1!==F){for(let fe=0;fe<R;fe++)ae+=this._pageMatches[fe]?.length||0;ae+=F+1}return(ae<1||ae>le)&&(ae=le=0),{current:ae,total:le}},_e=new WeakSet,wt=function(){this._eventBus.dispatch("updatefindmatchescount",{source:this,matchesCount:ye(this,he,ot).call(this)})},Ce=new WeakSet,Ge=function(R,F=!1){this._eventBus.dispatch("updatefindcontrolstate",{source:this,state:R,previous:F,matchesCount:ye(this,he,ot).call(this),rawQuery:this._state?.query??null})},a.PDFFindController=class k{constructor({linkService:R,eventBus:F}){ve(this,I),ve(this,X),ve(this,N),ve(this,K),ve(this,se),ve(this,o),ve(this,e),ve(this,b),ve(this,C),ve(this,B),ve(this,V),ve(this,Y),ve(this,ce),ve(this,Q),ve(this,ie),ve(this,D),ve(this,pe),ve(this,he),ve(this,_e),ve(this,Ce),this._linkService=R,this._eventBus=F,ye(this,X,nt).call(this),F._on("find",ye(this,I,mt).bind(this)),F._on("findbarclose",ye(this,pe,Ct).bind(this))}get highlightMatches(){return this._highlightMatches}get pageMatches(){return this._pageMatches}get pageMatchesLength(){return this._pageMatchesLength}get selected(){return this._selected}get state(){return this._state}setDocument(R){this._pdfDocument&&ye(this,X,nt).call(this),R&&(this._pdfDocument=R,this._firstPageCapability.resolve())}scrollMatchIntoView({element:R=null,selectedLeft:F=0,pageIndex:ae=-1,matchIndex:le=-1}){this._scrollMatches&&R&&-1!==le&&le===this._selected.matchIdx&&-1!==ae&&ae===this._selected.pageIdx&&(this._scrollMatches=!1,(0,g.scrollIntoView)(R,{top:-50,left:F+-400},!0))}}},(O,a)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.CharacterType=void 0,a.getCharacterType=function t(i){return function g(i){return i<11904}(i)?function f(i){return 0==(65408&i)}(i)?function n(i){return 32===i||9===i||13===i||10===i}(i)?v.SPACE:function r(i){return i>=97&&i<=122||i>=65&&i<=90}(i)||function p(i){return i>=48&&i<=57}(i)||95===i?v.ALPHA_LETTER:v.PUNCT:function _(i){return 3584==(65408&i)}(i)?v.THAI_LETTER:160===i?v.SPACE:v.ALPHA_LETTER:function s(i){return i>=13312&&i<=40959||i>=63744&&i<=64255}(i)?v.HAN_LETTER:function u(i){return i>=12448&&i<=12543}(i)?v.KATAKANA_LETTER:function S(i){return i>=12352&&i<=12447}(i)?v.HIRAGANA_LETTER:function d(i){return i>=65376&&i<=65439}(i)?v.HALFWIDTH_KATAKANA_LETTER:v.ALPHA_LETTER};const v={SPACE:0,ALPHA_LETTER:1,PUNCT:2,HAN_LETTER:3,KATAKANA_LETTER:4,HIRAGANA_LETTER:5,HALFWIDTH_KATAKANA_LETTER:6,THAI_LETTER:7};a.CharacterType=v},(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.PDFHistory=void 0,a.isDestArraysEqual=d,a.isDestHashesEqual=S;var g=v(6),f=v(17);function s(){return document.location.hash}function S(_,t){return"string"==typeof _&&"string"==typeof t&&(_===t||(0,g.parseQueryString)(_).get("nameddest")===t)}function d(_,t){function i(A,l){if(typeof A!=typeof l||Array.isArray(A)||Array.isArray(l))return!1;if(null!==A&&"object"==typeof A&&null!==l){if(Object.keys(A).length!==Object.keys(l).length)return!1;for(const m in A)if(!i(A[m],l[m]))return!1;return!0}return A===l||Number.isNaN(A)&&Number.isNaN(l)}if(!Array.isArray(_)||!Array.isArray(t)||_.length!==t.length)return!1;for(let A=0,l=_.length;A<l;A++)if(!i(_[A],t[A]))return!1;return!0}a.PDFHistory=class u{constructor({linkService:t,eventBus:i}
vendor: 14,943 bytes, line 1
1){this.linkService=t,this.eventBus=i,this._initialized=!1,this._fingerprint="",this.reset(),this._boundEvents=null,this.eventBus._on("pagesinit",()=>{this._isPagesLoaded=!1,this.eventBus._on("pagesloaded",A=>{this._isPagesLoaded=!!A.pagesCount},{once:!0})})}initialize({fingerprint:t,resetHistory:i=!1,updateUrl:A=!1}){if(!t||"string"!=typeof t)return void console.error('PDFHistory.initialize: The "fingerprint" must be a non-empty string.');this._initialized&&this.reset();const l=""!==this._fingerprint&&this._fingerprint!==t;this._fingerprint=t,this._updateUrl=!0===A,this._initialized=!0,this._bindEvents();const m=window.history.state;if(this._popStateInProgress=!1,this._blockHashChange=0,this._currentHash=s(),this._numPositionUpdates=0,this._uid=this._maxUid=0,this._destination=null,this._position=null,!this._isValidState(m,!0)||i){const{hash:M,page:k,rotation:I}=this._parseCurrentHash(!0);return!M||l||i?void this._pushOrReplaceState(null,!0):void this._pushOrReplaceState({hash:M,page:k,rotation:I},!0)}const x=m.destination;this._updateInternalState(x,m.uid,!0),void 0!==x.rotation&&(this._initialRotation=x.rotation),x.dest?(this._initialBookmark=JSON.stringify(x.dest),this._destination.page=null):x.hash?this._initialBookmark=x.hash:x.page&&(this._initialBookmark=`page=${x.page}`)}reset(){this._initialized&&(this._pageHide(),this._initialized=!1,this._unbindEvents()),this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),this._initialBookmark=null,this._initialRotation=null}push({namedDest:t=null,explicitDest:i,pageNumber:A}){if(!this._initialized)return;if(t&&"string"!=typeof t)return void console.error(`PDFHistory.push: "${t}" is not a valid namedDest parameter.`);if(!Array.isArray(i))return void console.error(`PDFHistory.push: "${i}" is not a valid explicitDest parameter.`);if(!this._isValidPage(A)&&(null!==A||this._destination))return void console.error(`PDFHistory.push: "${A}" is not a valid pageNumber parameter.`);const l=t||JSON.stringify(i);if(!l)return;let m=!1;if(this._destination&&(S(this._destination.hash,l)||d(this._destination.dest,i))){if(this._destination.page)return;m=!0}this._popStateInProgress&&!m||(this._pushOrReplaceState({dest:i,hash:l,page:A,rotation:this.linkService.rotation},m),this._popStateInProgress||(this._popStateInProgress=!0,Promise.resolve().then(()=>{this._popStateInProgress=!1})))}pushPage(t){if(this._initialized){if(!this._isValidPage(t))return void console.error(`PDFHistory.pushPage: "${t}" is not a valid page number.`);this._destination?.page!==t&&(this._popStateInProgress||(this._pushOrReplaceState({dest:null,hash:`page=${t}`,page:t,rotation:this.linkService.rotation}),this._popStateInProgress||(this._popStateInProgress=!0,Promise.resolve().then(()=>{this._popStateInProgress=!1}))))}}pushCurrentPosition(){!this._initialized||this._popStateInProgress||this._tryPushCurrentPosition()}back(){if(!this._initialized||this._popStateInProgress)return;const t=window.history.state;this._isValidState(t)&&t.uid>0&&window.history.back()}forward(){if(!this._initialized||this._popStateInProgress)return;const t=window.history.state;this._isValidState(t)&&t.uid<this._maxUid&&window.history.forward()}get popStateInProgress(){return this._initialized&&(this._popStateInProgress||this._blockHashChange>0)}get initialBookmark(){return this._initialized?this._initialBookmark:null}get initialRotation(){return this._initialized?this._initialRotation:null}_pushOrReplaceState(t,i=!1){const A=i||!this._destination,l={fingerprint:this._fingerprint,uid:A?this._uid:this._uid+1,destination:t};let m;if(this._updateInternalState(t,l.uid),this._updateUrl&&t?.hash){const x=document.location.href.split("#")[0];x.startsWith("file://")||(m=`${x}#${t.hash}`)}A?window.history.replaceState(l,"",m):window.history.pushState(l,"",m)}_tryPushCurrentPosition(t=!1){if(!this._position)return;let i=this._position;if(t&&(i=Object.assign(Object.create(null),this._position),i.temporary=!0),!this._destination)return void this._pushOrReplaceState(i);if(this._destination.temporary)return void this._pushOrReplaceState(i,!0);if(this._destination.hash===i.hash||!this._destination.page&&this._numPositionUpdates<=50)return;let A=!1;if(this._destination.page>=i.first&&this._destination.page<=i.page){if(void 0!==this._destination.dest||!this._destination.first)return;A=!0}this._pushOrReplaceState(i,A)}_isValidPage(t){return Number.isInteger(t)&&t>0&&t<=this.linkService.pagesCount}_isValidState(t,i=!1){if(!t)return!1;if(t.fingerprint!==this._fingerprint){if(!i)return!1;{if("string"!=typeof t.fingerprint||t.fingerprint.length!==this._fingerprint.length)return!1;const[A]=performance.getEntriesByType("navigation");if("reload"!==A?.type)return!1}}return!(!Number.isInteger(t.uid)||t.uid<0||null===t.destination||"object"!=typeof t.destination)}_updateInternalState(t,i,A=!1){this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),A&&t?.temporary&&delete t.temporary,this._destination=t,this._uid=i,this._maxUid=Math.max(this._maxUid,i),this._numPositionUpdates=0}_parseCurrentHash(t=!1){const i=unescape(s()).substring(1),A=(0,g.parseQueryString)(i),l=A.get("nameddest")||"";let m=0|A.get("page");return(!this._isValidPage(m)||t&&l.length>0)&&(m=null),{hash:i,page:m,rotation:this.linkService.rotation}}_updateViewarea({location:t}){this._updateViewareaTimeout&&(clearTimeout(this._updateViewareaTimeout),this._updateViewareaTimeout=null),this._position={hash:t.pdfOpenParams.substring(1),page:this.linkService.page,first:t.pageNumber,rotation:t.rotation},!this._popStateInProgress&&(this._isPagesLoaded&&this._destination&&!this._destination.page&&this._numPositionUpdates++,this._updateViewareaTimeout=setTimeout(()=>{this._popStateInProgress||this._tryPushCurrentPosition(!0),this._updateViewareaTimeout=null},1e3))}_popState({state:t}){const i=s(),A=this._currentHash!==i;if(this._currentHash=i,!t){this._uid++;const{hash:m,page:x,rotation:M}=this._parseCurrentHash();return void this._pushOrReplaceState({hash:m,page:x,rotation:M},!0)}if(!this._isValidState(t))return;this._popStateInProgress=!0,A&&(this._blockHashChange++,(0,f.waitOnEventOrTimeout)({target:window,name:"hashchange",delay:1e3}).then(()=>{this._blockHashChange--}));const l=t.destination;this._updateInternalState(l,t.uid,!0),(0,g.isValidRotation)(l.rotation)&&(this.linkService.rotation=l.rotation),l.dest?this.linkService.goToDestination(l.dest):l.hash?this.linkService.setHash(l.hash):l.page&&(this.linkService.page=l.page),Promise.resolve().then(()=>{this._popStateInProgress=!1})}_pageHide(){(!this._destination||this._destination.temporary)&&this._tryPushCurrentPosition()}_bindEvents(){this._boundEvents||(this._boundEvents={updateViewarea:this._updateViewarea.bind(this),popState:this._popState.bind(this),pageHide:this._pageHide.bind(this)},this.eventBus._on("updateviewarea",this._boundEvents.updateViewarea),window.addEventListener("popstate",this._boundEvents.popState),window.addEventListener("pagehide",this._boundEvents.pageHide))}_unbindEvents(){!this._boundEvents||(this.eventBus._off("updateviewarea",this._boundEvents.updateViewarea),window.removeEventListener("popstate",this._boundEvents.popState),window.removeEventListener("pagehide",this._boundEvents.pageHide),this._boundEvents=null)}}},(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.PDFScriptingManager=void 0;var g=v(6),f=v(3);a.PDFScriptingManager=class r{constructor({eventBus:n,sandboxBundleSrc:s=null,scriptingFactory:u=null,docPropertiesLookup:S=null}){this._pdfDocument=null,this._pdfViewer=null,this._closeCapability=null,this._destroyCapability=null,this._scripting=null,this._mouseState=Object.create(null),this._ready=!1,this._eventBus=n,this._sandboxBundleSrc=s,this._scriptingFactory=u,this._docPropertiesLookup=S,this._scriptingFactory||window.addEventListener("updatefromsandbox",d=>{this._eventBus.dispatch("updatefromsandbox",{source:window,detail:d.detail})})}setViewer(n){this._pdfViewer=n}setDocument(n){var s=this;return y(function*(){if(s._pdfDocument&&(yield s._destroyScripting()),s._pdfDocument=n,!n)return;const[u,S,d]=yield Promise.all([n.getFieldObjects(),n.getCalculationOrderIds(),n.getJSActions()]);if(u||d){if(n===s._pdfDocument){try{s._scripting=s._createScripting()}catch(_){return console.error(`PDFScriptingManager.setDocument: "${_?.message}".`),void(yield s._destroyScripting())}s._internalEvents.set("updatefromsandbox",_=>{_?.source===window&&s._updateFromSandbox(_.detail)}),s._internalEvents.set("dispatcheventinsandbox",_=>{s._scripting?.dispatchEventInSandbox(_.detail)}),s._internalEvents.set("pagechanging",({pageNumber:_,previous:t})=>{_!==t&&(s._dispatchPageClose(t),s._dispatchPageOpen(_))}),s._internalEvents.set("pagerendered",({pageNumber:_})=>{!s._pageOpenPending.has(_)||_===s._pdfViewer.currentPageNumber&&s._dispatchPageOpen(_)}),s._internalEvents.set("pagesdestroy",function(){var _=y(function*(t){yield s._dispatchPageClose(s._pdfViewer.currentPageNumber),yield s._scripting?.dispatchEventInSandbox({id:"doc",name:"WillClose"}),s._closeCapability?.resolve()});return function(t){return _.apply(this,arguments)}}()),s._domEvents.set("mousedown",_=>{s._mouseState.isDown=!0}),s._domEvents.set("mouseup",_=>{s._mouseState.isDown=!1});for(const[_,t]of s._internalEvents)s._eventBus._on(_,t);for(const[_,t]of s._domEvents)window.addEventListener(_,t,!0);try{const _=yield s._getDocProperties();if(n!==s._pdfDocument)return;yield s._scripting.createSandbox({objects:u,calculationOrder:S,appInfo:{platform:navigator.platform,language:navigator.language},docInfo:{..._,actions:d}}),s._eventBus.dispatch("sandboxcreated",{source:s})}catch(_){return console.error(`PDFScriptingManager.setDocument: "${_?.message}".`),void(yield s._destroyScripting())}yield s._scripting?.dispatchEventInSandbox({id:"doc",name:"Open"}),yield s._dispatchPageOpen(s._pdfViewer.currentPageNumber,!0),Promise.resolve().then(()=>{n===s._pdfDocument&&(s._ready=!0)})}}else yield s._destroyScripting()})()}dispatchWillSave(n){var s=this;return y(function*(){return s._scripting?.dispatchEventInSandbox({id:"doc",name:"WillSave"})})()}dispatchDidSave(n){var s=this;return y(function*(){return s._scripting?.dispatchEventInSandbox({id:"doc",name:"DidSave"})})()}dispatchWillPrint(n){var s=this;return y(function*(){return s._scripting?.dispatchEventInSandbox({id:"doc",name:"WillPrint"})})()}dispatchDidPrint(n){var s=this;return y(function*(){return s._scripting?.dispatchEventInSandbox({id:"doc",name:"DidPrint"})})()}get mouseState(){return this._mouseState}get destroyPromise(){return this._destroyCapability?.promise||null}get ready(){return this._ready}get _internalEvents(){return(0,f.shadow)(this,"_internalEvents",new Map)}get _domEvents(){return(0,f.shadow)(this,"_domEvents",new Map)}get _pageOpenPending(){return(0,f.shadow)(this,"_pageOpenPending",new Set)}get _visitedPages(){return(0,f.shadow)(this,"_visitedPages",new Map)}_updateFromSandbox(n){var s=this;return y(function*(){const u=s._pdfViewer.isInPresentationMode||s._pdfViewer.isChangingPresentationMode,{id:S,siblings:d,command:_,value:t}=n;if(!S){switch(_){case"clear":console.clear();break;case"error":console.error(t);break;case"layout":if(u)return;const A=(0,g.apiPageLayoutToViewerModes)(t);s._pdfViewer.spreadMode=A.spreadMode;break;case"page-num":s._pdfViewer.currentPageNumber=t+1;break;case"print":yield s._pdfViewer.pagesPromise,s._eventBus.dispatch("print",{source:s});break;case"println":console.log(t);break;case"zoom":if(u)return;s._pdfViewer.currentScaleValue=t;break;case"SaveAs":s._eventBus.dispatch("save",{source:s});break;case"FirstPage":s._pdfViewer.currentPageNumber=1;break;case"LastPage":s._pdfViewer.currentPageNumber=s._pdfViewer.pagesCount;break;case"NextPage":s._pdfViewer.nextPage();break;case"PrevPage":s._pdfViewer.previousPage();break;case"ZoomViewIn":if(u)return;s._pdfViewer.increaseScale();break;case"ZoomViewOut":if(u)return;s._pdfViewer.decreaseScale()}return}if(u&&n.focus)return;delete n.id,delete n.siblings;const i=d?[S,...d]:[S];for(const A of i){const l=document.getElementById(A);l?l.dispatchEvent(new CustomEvent("updatefromsandbox",{detail:n})):s._pdfDocument?.annotationStorage.setValue(A,n)}})()}_dispatchPageOpen(n,s=!1){var u=this;return y(function*(){const S=u._pdfDocument,d=u._visitedPages;if(s&&(u._closeCapability=(0,f.createPromiseCapability)()),!u._closeCapability)return;const _=u._pdfViewer.getPageView(n-1);if(_?.renderingState!==g.RenderingStates.FINISHED)return void u._pageOpenPending.add(n);u._pageOpenPending.delete(n);const t=y(function*(){const i=yield d.has(n)?null:_.pdfPage?.getJSActions();S===u._pdfDocument&&(yield u._scripting?.dispatchEventInSandbox({id:"page",name:"PageOpen",pageNumber:n,actions:i}))})();d.set(n,t)})()}_dispatchPageClose(n){var s=this;return y(function*(){const u=s._pdfDocument,S=s._visitedPages;if(!s._closeCapability||s._pageOpenPending.has(n))return;const d=S.get(n);!d||(S.set(n,null),yield d,u===s._pdfDocument&&(yield s._scripting?.dispatchEventInSandbox({id:"page",name:"PageClose",pageNumber:n})))})()}_getDocProperties(){var n=this;return y(function*(){if(n._docPropertiesLookup)return n._docPropertiesLookup(n._pdfDocument);const{docPropertiesLookup:s}=v(24);return s(n._pdfDocument)})()}_createScripting(){if(this._destroyCapability=(0,f.createPromiseCapability)(),this._scripting)throw new Error("_createScripting: Scripting already exists.");if(this._scriptingFactory)return this._scriptingFactory.createScripting({sandboxBundleSrc:this._sandboxBundleSrc});const{GenericScripting:n}=v(24);return new n(this._sandboxBundleSrc)}_destroyScripting(){var n=this;return y(function*(){if(!n._scripting)return n._pdfDocument=null,void n._destroyCapability?.resolve();n._closeCapability&&(yield Promise.race([n._closeCapability.promise,new Promise(s=>{setTimeout(s,1e3)})]).catch(s=>{}),n._closeCapability=null),n._pdfDocument=null;try{yield n._scripting.destroySandbox()}catch{}for(const[s,u]of n._internalEvents)n._eventBus._off(s,u);n._internalEvents.clear();for(const[s,u]of n._domEvents)window.removeEventListener(s,u,!0);n._domEvents.clear(),n._pageOpenPending.clear(),n._visitedPages.clear(),n._scripting=null,delete n._mouseState.isDown,n._ready=!1,n._destroyCapability?.resolve()})()}}},(O,a,v)=>{Object.defineProperty(a,"__esModule",{value:!0}),a.GenericScripting=void 0,a.docPropertiesLookup=function f(n){return r.apply(this,arguments)};var g=v(3);function r(){return(r=y(function*(n){const u="".split("#")[0];let{info:S,metadata:d,contentDispositionFilename:_,contentLength:t}=yield n.getMetadata();if(!t){const{length:i}=yield n.getDownloadInfo();t=i}return{...S,baseURL:u,filesize:t,filename:_||(0,g.getPdfFilenameFromUrl)(""),metadata:d?.getRaw(),authors:d?.get("dc:creator"),numPages:n.numPages,URL:""}})).apply(this,arguments)}a.GenericScripting=class p{constructor(s){this._ready=(0,g.loadScript)(s,!0).then(()=>
1window.pdfjsSandbox.QuickJSSandbox())}createSandbox(s){var u=this;return y(function*(){(yield u._ready).create(s)})()}dispatchEventInSandbox(s){var u=this;return y(function*(){const S=yield u._ready;setTimeout(()=>S.dispatchEvent(s),0)})()}destroySandbox(){var s=this;return y(function*(){(yield s._ready).nukeSandbox()})()}}}],G={};function H(O){var a=G[O];if(void 0!==a)return a.exports;var v=G[O]={exports:{}};return oe[O](v,v.exports,H),v.exports}var W={};return(()=>{var O=W;Object.defineProperty(O,"__esModule",{value:!0}),Object.defineProperty(O,"AnnotationLayerBuilder",{enumerable:!0,get:function(){return r.AnnotationLayerBuilder}}),Object.defineProperty(O,"DefaultAnnotationLayerFactory",{enumerable:!0,get:function(){return a.DefaultAnnotationLayerFactory}}),Object.defineProperty(O,"DefaultStructTreeLayerFactory",{enumerable:!0,get:function(){return a.DefaultStructTreeLayerFactory}}),Object.defineProperty(O,"DefaultTextLayerFactory",{enumerable:!0,get:function(){return a.DefaultTextLayerFactory}}),Object.defineProperty(O,"DefaultXfaLayerFactory",{enumerable:!0,get:function(){return a.DefaultXfaLayerFactory}}),Object.defineProperty(O,"DownloadManager",{enumerable:!0,get:function(){return p.DownloadManager}}),Object.defineProperty(O,"EventBus",{enumerable:!0,get:function(){return n.EventBus}}),Object.defineProperty(O,"GenericL10n",{enumerable:!0,get:function(){return s.GenericL10n}}),Object.defineProperty(O,"LinkTarget",{enumerable:!0,get:function(){return v.LinkTarget}}),Object.defineProperty(O,"NullL10n",{enumerable:!0,get:function(){return u.NullL10n}}),Object.defineProperty(O,"PDFFindController",{enumerable:!0,get:function(){return S.PDFFindController}}),Object.defineProperty(O,"PDFHistory",{enumerable:!0,get:function(){return d.PDFHistory}}),Object.defineProperty(O,"PDFLinkService",{enumerable:!0,get:function(){return v.PDFLinkService}}),Object.defineProperty(O,"PDFPageView",{enumerable:!0,get:function(){return _.PDFPageView}}),Object.defineProperty(O,"PDFScriptingManager",{enumerable:!0,get:function(){return t.PDFScriptingManager}}),Object.defineProperty(O,"PDFSinglePageViewer",{enumerable:!0,get:function(){return f.PDFSinglePageViewer}}),Object.defineProperty(O,"PDFViewer",{enumerable:!0,get:function(){return f.PDFViewer}}),Object.defineProperty(O,"ProgressBar",{enumerable:!0,get:function(){return g.ProgressBar}}),Object.defineProperty(O,"SimpleLinkService",{enumerable:!0,get:function(){return v.SimpleLinkService}}),Object.defineProperty(O,"StructTreeLayerBuilder",{enumerable:!0,get:function(){return i.StructTreeLayerBuilder}}),Object.defineProperty(O,"TextLayerBuilder",{enumerable:!0,get:function(){return A.TextLayerBuilder}}),Object.defineProperty(O,"XfaLayerBuilder",{enumerable:!0,get:function(){return l.XfaLayerBuilder}}),Object.defineProperty(O,"parseQueryString",{enumerable:!0,get:function(){return g.parseQueryString}});var a=H(1),v=H(5),g=H(6),f=H(10),r=H(2),p=H(16),n=H(17),s=H(18),u=H(4),S=H(20),d=H(22),_=H(12),t=H(23),i=H(7),A=H(8),l=H(9)})(),W})(),ue.exports=H()},3414:()=>{},172:()=>{},2001:()=>{},3779:()=>{},6558:()=>{},2258:()=>{},9344:ue=>{function L(y,oe,G,H,W,O,a){try{var v=y[O](a),g=v.value}catch(f){return void G(f)}v.done?oe(g):Promise.resolve(g).then(H,W)}ue.exports=function ne(y){return function(){var oe=this,G=arguments;return new Promise(function(H,W){var O=y.apply(oe,G);function a(g){L(O,H,W,a,v,"next",g)}function v(g){L(O,H,W,a,v,"throw",g)}a(void 0)})}},ue.exports.__esModule=!0,ue.exports.default=ue.exports},9380:(ue,L,ne)=>{"use strict";var y,oe;ne.d(L,{rQ:()=>_,xC:()=>t});var G=ne(4650),H=ne(4968),W=ne(7579),O=ne(2076),a=ne(2722),v=ne(8372),g=ne(9300),f=ne(6036),r=ne(2813);const p=["pdfViewerContainer"];function u(i,A,l){i[A]=l}function S(){return typeof window>"u"}S()||u(y||(y=ne.t(f,2)),"verbosity",f.VerbosityLevel.INFOS);var d=(()=>{return(i=d||(d={}))[i.DISABLED=0]="DISABLED",i[i.ENABLED=1]="ENABLED",i[i.ENHANCED=2]="ENHANCED",d;var i})();let _=(()=>{class i{constructor(l,m){if(this.element=l,this.ngZone=m,this.isVisible=!1,this._cMapsUrl=typeof(y||(y=ne.t(f,2)))<"u"?`https://unpkg.com/pdfjs-dist@${f.version}/cmaps/`:null,this._imageResourcesPath=typeof(y||(y=ne.t(f,2)))<"u"?`https://unpkg.com/pdfjs-dist@${f.version}/web/images/`:null,this._renderText=!0,this._renderTextMode=d.ENABLED,this._stickToPage=!1,this._originalSize=!0,this._page=1,this._zoom=1,this._zoomScale="page-width",this._rotation=0,this._showAll=!0,this._canAutoResize=!0,this._fitToPage=!1,this._externalLinkTarget="blank",this._showBorders=!1,this.resizeTimeout=null,this.pageScrollTimeout=null,this.isInitialized=!1,this.destroy$=new W.x,this.afterLoadComplete=new G.vpe,this.pageRendered=new G.vpe,this.pageInitialized=new G.vpe,this.textLayerRendered=new G.vpe,this.onError=ne
1w G.vpe,this.onProgress=new G.vpe,this.pageChange=new G.vpe(!0),S())return;let x;const M=f.version;x=window[`pdfWorkerSrc${M}`]||(window.hasOwnProperty("pdfWorkerSrc")&&"string"==typeof window.pdfWorkerSrc&&window.pdfWorkerSrc?window.pdfWorkerSrc:`https://cdn.jsdelivr.net/npm/pdfjs-dist@${M}/legacy/build/pdf.worker.min.js`),u(f.GlobalWorkerOptions,"workerSrc",x)}set cMapsUrl(l){this._cMapsUrl=l}set page(l){const m=l=parseInt(l,10)||1;this._pdf&&(l=this.getValidPageNumber(l)),this._page=l,m!==l&&this.pageChange.emit(l)}set renderText(l){this._renderText=l}set renderTextMode(l){this._renderTextMode=l}set originalSize(l){this._originalSize=l}set showAll(l){this._showAll=l}set stickToPage(l){this._stickToPage=l}set zoom(l){l<=0||(this._zoom=l)}get zoom(){return this._zoom}set zoomScale(l){this._zoomScale=l}get zoomScale(){return this._zoomScale}set rotation(l){"number"==typeof l&&l%90==0?this._rotation=l:console.warn("Invalid pages rotation angle.")}set externalLinkTarget(l){this._externalLinkTarget=l}set autoresize(l){this._canAutoResize=Boolean(l)}set fitToPage(l){this._fitToPage=Boolean(l)}set showBorders(l){this._showBorders=Boolean(l)}static getLinkTarget(l){switch(l){case"blank":return r.LinkTarget.BLANK;case"none":return r.LinkTarget.NONE;case"self":return r.LinkTarget.SELF;case"parent":return r.LinkTarget.PARENT;case"top":return r.LinkTarget.TOP}return null}ngAfterViewChecked(){if(this.isInitialized)return;const l=this.pdfViewerContainer.nativeElement.offsetParent;!0!==this.isVisible||null!=l?!1===this.isVisible&&null!=l&&(this.isVisible=!0,setTimeout(()=>{this.initialize(),this.ngOnChanges({src:this.src})})):this.isVisible=!1}ngOnInit(){this.initialize(),this.setupResizeListener()}ngOnDestroy(){this.clear(),this.destroy$.next(),this.loadingTask=null}ngOnChanges(l){if(!S()&&this.isVisible)if("src"in l)this.loadPDF();else if(this._pdf){if("renderText"in l?(this.pdfViewer.textLayerMode=this._renderText?this._renderTextMode:d.DISABLED,this.resetPdfDocument()):"showAll"in l&&(this.setupViewer(),this.resetPdfDocument()),"page"in l){const{page:m}=l;if(m.currentValue===this._latestScrolledPage)return;this.pdfViewer.scrollPageIntoView({pageNumber:this._page})}this.update()}}updateSize(){(0,O.D)(this._pdf.getPage(this.pdfViewer.currentPageNumber)).pipe((0,a.R)(this.destroy$)).subscribe({next:l=>{const m=this._rotation+l.rotate,x=l.getViewport({scale:this._zoom,rotation:m}).width*i.CSS_UNITS;let M=this._zoom,k=!0;if(!this._originalSize||this._fitToPage&&x>this.pdfViewerContainer.nativeElement.clientWidth){const I=l.getViewport({scale:1,rotation:m});M=this.getScale(I.width,I.height),k=!this._stickToPage}this.pdfViewer._setScale(M,k)}})}clear(){this.loadingTask&&!this.loadingTask.destroyed&&this.loadingTask.destroy(),this._pdf&&(this._latestScrolledPage=0,this._pdf.destroy(),this._pdf=null,this.pdfViewer.setDocument(null),this.pdfLinkService.setDocument(null,null),this.pdfFindController.setDocument(null))}getPDFLinkServiceConfig(){const l=i.getLinkTarget(this._externalLinkTarget);return l?{externalLinkTarget:l}:{}}initEventBus(){this.eventBus=function n(i,A){const l=new i.EventBus;return function s(i,A){(0,H.R)(i,"documentload").pipe((0,a.R)(A)).subscribe(()=>{const l=document.createEvent("CustomEvent");l.initCustomEvent("documentload",!0,!0,{}),window.dispatchEvent(l)}),(0,H.R)(i,"pagerendered").pipe((0,a.R)(A)).subscribe(({pageNumber:l,cssTransform:m,source:x})=>{const M=document.createEvent("CustomEvent");M.initCustomEvent("pagerendered",!0,!0,{pageNumber:l,cssTransform:m}),x.div.dispatchEvent(M)}),(0,H.R)(i,"textlayerrendered").pipe((0,a.R)(A)).subscribe(({pageNumber:l,source:m})=>{const x=document.createEvent("CustomEvent");x.initCustomEvent("textlayerrendered",!0,!0,{pageNumber:l}),m.textLayerDiv.dispatchEvent(x)}),(0,H.R)(i,"pagechanging").pipe((0,a.R)(A)).subscribe(({pageNumber:l,source:m})=>{const x=document.createEvent("UIEvents");x.initEvent("pagechanging",!0,!0),x.pageNumber=l,m.container.dispatchEvent(x)}),(0,H.R)(i,"pagesinit").pipe((0,a.R)(A)).subscribe(({source:l})=>{const m=document.createEvent("CustomEvent");
1m.initCustomEvent("pagesinit",!0,!0,null),l.container.dispatchEvent(m)}),(0,H.R)(i,"pagesloaded").pipe((0,a.R)(A)).subscribe(({pagesCount:l,source:m})=>{const x=document.createEvent("CustomEvent");x.initCustomEvent("pagesloaded",!0,!0,{pagesCount:l}),m.container.dispatchEvent(x)}),(0,H.R)(i,"scalechange").pipe((0,a.R)(A)).subscribe(({scale:l,presetValue:m,source:x})=>{const M=document.createEvent("UIEvents");M.initEvent("scalechange",!0,!0),M.scale=l,M.presetValue=m,x.container.dispatchEvent(M)}),(0,H.R)(i,"updateviewarea").pipe((0,a.R)(A)).subscribe(({location:l,source:m})=>{const x=document.createEvent("UIEvents");x.initEvent("updateviewarea",!0,!0),x.location=l,m.container.dispatchEvent(x)}),(0,H.R)(i,"find").pipe((0,a.R)(A)).subscribe(({source:l,type:m,query:x,phraseSearch:M,caseSensitive:k,highlightAll:I,findPrevious:j})=>{if(l===window)return;const X=document.createEvent("CustomEvent");X.initCustomEvent("find"+m,!0,!0,{query:x,phraseSearch:M,caseSensitive:k,highlightAll:I,findPrevious:j}),window.dispatchEvent(X)}),(0,H.R)(i,"attachmentsloaded").pipe((0,a.R)(A)).subscribe(({attachmentsCount:l,source:m})=>{const x=document.createEvent("CustomEvent");x.initCustomEvent("attachmentsloaded",!0,!0,{attachmentsCount:l}),m.container.dispatchEvent(x)}),(0,H.R)(i,"sidebarviewchanged").pipe((0,a.R)(A)).subscribe(({view:l,source:m})=>{const x=document.createEvent("CustomEvent");x.initCustomEvent("sidebarviewchanged",!0,!0,{view:l}),m.outerContainer.dispatchEvent(x)}),(0,H.R)(i,"pagemode").pipe((0,a.R)(A)).subscribe(({mode:l,source:m})=>{const x=document.createEvent("CustomEvent");x.initCustomEvent("pagemode",!0,!0,{mode:l}),m.pdfViewer.container.dispatchEvent(x)}),(0,H.R)(i,"namedaction").pipe((0,a.R)(A)).subscribe(({action:l,source:m})=>{const x=document.createEvent("CustomEvent");x.initCustomEvent("namedaction",!0,!0,{action:l}),m.pdfViewer.container.dispatchEvent(x)}),(0,H.R)(i,"presentationmodechanged").pipe((0,a.R)(A)).subscribe(({active:l,switchInProgress:m})=>{const x=document.createEvent("CustomEvent");x.initCustomEvent("presentationmodechanged",!0,!0,{active:l,switchInProgress:m}),window.dispatchEvent(x)}),(0,H.R)(i,"outlineloaded").pipe((0,a.R)(A)).subscribe(({outlineCount:l,source:m})=>{const x=document.createEvent("CustomEvent");x.initCustomEvent("outlineloaded",!0,!0,{outlineCount:l}),m.container.dispatchEvent(x)})}(l,A),l}(oe||(oe=ne.t(r,2)),this.destroy$),(0,H.R)(this.eventBus,"pagerendered").pipe((0,a.R)(this.destroy$)).subscribe(l=>{this.pageRendered.emit(l)}),(0,H.R)(this.eventBus,"pagesinit").pipe((0,a.R)(this.destroy$)).subscribe(l=>{this.pageInitialized.emit(l)}),(0,H.R)(this.eventBus,"pagechanging").pipe((0,a.R)(this.destroy$)).subscribe(({pageNumber:l})=>{this.pageScrollTimeout&&clearTimeout(this.pageScrollTimeout),this.pageScrollTimeout=window.setTimeout(()=>{this._latestScrolledPage=l,this.pageChange.emit(l)},100)}),(0,H.R)(this.eventBus,"textlayerrendered").pipe((0,a.R)(this.destroy$)).subscribe(l=>{this.textLayerRendered.emit(l)})}initPDFServices(){this.pdfLinkService=new r.PDFLinkService({eventBus:this.eventBus,...this.getPDFLinkServiceConfig()}),this.pdfFindController=new r.PDFFindController({eventBus:this.eventBus,linkService:this.pdfLinkService})}getPDFOptions(){return{eventBus:this.eventBus,container:this.element.nativeElement.querySelector("div"),removePageBorders:!this._showBorders,linkService:this.pdfLinkService,textLayerMode:this._renderText?this._renderTextMode:d.DISABLED,findController:this.pdfFindController,renderer:"canvas",l10n:void 0,imageResourcesPath:this._imageResourcesPath}}setupViewer(){u(y||(y=ne.t(f,2)),"disableTextLayer",!this._renderText),this.initPDFServices(),this.pdfViewer=this._showAll?new r.PDFViewer(this.getPDFOptions()):new r.PDFSinglePageViewer(this.getPDFOptions()),this.pdfLinkService.setViewer(this.pdfViewer),this.pdfViewer._currentPageNumber=this._page}getValidPageNumber(l){return l<1?1:l>this._pdf.numPages?this._pdf.numPages:l}getDocumentParams(){const l=typeof this.src;if(!this._cMapsUrl)return this.src;const m={cMapUrl:this._cMapsUrl,cMapPacked:!0,enableXfa:!0};return"string"===l?m.url=this.src:"object"===l&&(void 0!==this.src.byteLength?m.data=this.src:Object.assign(m,this.src
1)),m}loadPDF(){if(!this.src)return;if(this.lastLoaded===this.src)return void this.update();this.clear(),this.setupViewer(),this.loadingTask=f.getDocument(this.getDocumentParams()),this.loadingTask.onProgress=m=>{this.onProgress.emit(m)};const l=this.src;(0,O.D)(this.loadingTask.promise).pipe((0,a.R)(this.destroy$)).subscribe({next:m=>{this._pdf=m,this.lastLoaded=l,this.afterLoadComplete.emit(m),this.resetPdfDocument(),this.update()},error:m=>{this.lastLoaded=null,this.onError.emit(m)}})}update(){this.page=this._page,this.render()}render(){this._page=this.getValidPageNumber(this._page),(0!==this._rotation||this.pdfViewer.pagesRotation!==this._rotation)&&setTimeout(()=>{this.pdfViewer.pagesRotation=this._rotation}),this._stickToPage&&setTimeout(()=>{this.pdfViewer.currentPageNumber=this._page}),this.updateSize()}getScale(l,m){const x=this._showBorders?2*i.BORDER_WIDTH:0,M=this.pdfViewerContainer.nativeElement.clientWidth-x,k=this.pdfViewerContainer.nativeElement.clientHeight-x;if(0===k||0===m||0===M||0===l)return 1;let I=1;switch(this._zoomScale){case"page-fit":I=Math.min(k/m,M/l);break;case"page-height":I=k/m;break;default:I=M/l}return this._zoom*I/i.CSS_UNITS}resetPdfDocument(){this.pdfLinkService.setDocument(this._pdf,null),this.pdfFindController.setDocument(this._pdf),this.pdfViewer.setDocument(this._pdf)}initialize(){S()||!this.isVisible||(this.isInitialized=!0,this.initEventBus(),this.setupViewer())}setupResizeListener(){S()||this.ngZone.runOutsideAngular(()=>{(0,H.R)(window,"resize").pipe((0,v.b)(100),(0,g.h)(()=>this._canAutoResize&&!!this._pdf),(0,a.R)(this.destroy$)).subscribe(()=>{this.updateSize()})})}}return i.CSS_UNITS=96/72,i.BORDER_WIDTH=9,i.\u0275fac=function(l){return new(l||i)(G.Y36(G.SBq),G.Y36(G.R0b))},i.\u0275cmp=G.Xpm({type:i,selectors:[["pdf-viewer"]],viewQuery:function(l,m){if(1&l&&G.Gf(p,5),2&l){let x;G.iGM(x=G.CRH())&&(m.pdfViewerContainer=x.first)}},inputs:{src:"src",cMapsUrl:["c-maps-url","cMapsUrl"],page:"page",renderText:["render-text","renderText"],renderTextMode:["render-text-mode","renderTextMode"],originalSize:["original-size","originalSize"],showAll:["show-all","showAll"],stickToPage:["stick-to-page","stickToPage"],zoom:"zoom",zoomScale:["zoom-scale","zoomScale"],rotation:"rotation",externalLinkTarget:["external-link-target","externalLinkTarget"],autoresize:"autoresize",fitToPage:["fit-to-page","fitToPage"],showBorders:["show-borders","showBorders"]},outputs:{afterLoadComplete:"after-load-complete",pageRendered:"page-rendered",pageInitialized:"pages-initialized",textLayerRendered:"text-layer-rendered",onError:"error",onProgress:"on-progress",pageChange:"pageChange"},features:[G.TTD],decls:3,vars:0,consts:[[1,"ng2-pdf-viewer-container"],["pdfViewerContainer",""],[1,"pdfViewer"]],template:function(l,m){1&l&&(G.TgZ(0,"div",0,1),G._UZ(2,"div",2),G.qZA())},styles:[".ng2-pdf-viewer-container[_ngcontent-%COMP%]{overflow-x:auto;position:absolute;height:100%;width:100%;-webkit-overflow-scrolling:touch}[_nghost-%COMP%]{display:block;position:relative}[_nghost-%COMP%]    {--pdfViewer-padding-bottom: 0;--page-margin: 1px auto -8px;--page-border: 9px solid transparent;--spreadHorizontalWrapped-margin-LR: -3.5px;--zoom-factor: 1;--viewport-scale-factor: 1;--shadow: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAYAAAByUDbMAAAA1ElEQVQ4jbWUWw6EIAxFy2NFs/8NzR4UJhpqLsdi5mOmSSMUOfYWqv3S0gMr4XlYH/64gZa/gN3ANYA7KAXALt4ktoQ5MI9YxqaG8bWmsIysMuT6piSQCa4whZThCu8CM4zP9YJaKci9jicPq3NcBWYoPMGUlhG7ivtkB+gVyFY75wXghOvh8t5mto1Mdim6e+MBqH6XsY+YAwjpq3vGF7weTWQptLEDVCZvPTMl5JZZsdh47FHW6qFMyvLYqjcnmdFfY9Xk/KDOlzCusX2mi/ofM7MPkzBcSp4Q1/wAAAAASUVORK5CYII=);--viewer-container-height: 0;--annotation-unfocused-field-background: url(\"data:image/svg+xml;charset=UTF-8,<svg width='1px' height='1px' xmlns='http://www.w3.org/2000/svg'><rect width='100%' height='100%' style='fill:rgba(0, 54, 255, 0.13);'/></svg>\");--xfa-unfocused-field-background: url(\"data:image/svg+xml;charset=UTF-8,<svg width='1px' height='1px' xmlns='http://www.w3.org/2000/svg'><rect width='100%' height='100%' style='fill:rgba(0, 54, 255, 0.13);'/></svg>\")}@media screen and (forced-colors: active){[_nghost-%COMP%]    {--pdfViewer-padding-bottom: 9px;--page-margin: 9px auto 0;--page-border: none;--spreadHorizontalWrapped-margin-LR: 4.5px}}[_nghost-%COMP%]     .textLayer{position:absolute;text-align:initial;left:0;top:0;right:0;bottom:0;overflow:hidden;opacity:.2;line-height:1;-webkit-text-size-adjust:none;text-size-adjust:none;forced-color-adjust:none}[_nghost-%COMP%]     .textLayer span, [_nghost-%COMP%]     .textLayer br{color:transparent;position:absolute;white-space:pre;cursor:text;transform-origin:0% 0%}[_nghost-%COMP%]     .textLayer span.markedContent{top:0;height:0}[_nghost-%COMP%]     .textLayer .highlight{margin:-1px;padding:1px;background-color:#b400aa;border-radius:4px}[_nghost-%COMP%]     .textLayer .highlight.appended{position:initial}[_nghost-%COMP%]     .textLayer .highlight.begin{border-radius:4px 0 0 4px}[_nghost-%COMP%]     .textLayer .highlight.end{border-radius:0 4px 4px 0}[_nghost-%COMP%]     .textLayer .highlight.middle{border-radius:0}[_nghost-%COMP%]     .textLayer .highlight.selected{background-color:#006400}[_nghost-%COMP%]     .textLayer ::selection{background:blue}[_nghost-%COMP%]     .textLayer br::selection{background:transparent}[_nghost-%COMP%]     .textLayer .endOfContent{display:block;position:absolute;
1left:0;top:100%;right:0;bottom:0;z-index:-1;cursor:default;-webkit-user-select:none;user-select:none}[_nghost-%COMP%]     .textLayer .endOfContent.active{top:0}[_nghost-%COMP%]     .annotationLayer section{position:absolute;text-align:initial}[_nghost-%COMP%]     .annotationLayer .linkAnnotation>a, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.pushButton>a{position:absolute;font-size:1em;top:0;left:0;width:100%;height:100%}[_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.pushButton>canvas{position:relative;top:0;left:0;z-index:-1}[_nghost-%COMP%]     .annotationLayer .linkAnnotation>a:hover, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.pushButton>a:hover{opacity:.2;background:yellow;box-shadow:0 2px 10px #ff0}[_nghost-%COMP%]     .annotationLayer .textAnnotation img{position:absolute;cursor:pointer}[_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation input, [_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation textarea, [_nghost-%COMP%]     .annotationLayer .choiceWidgetAnnotation select, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox input, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.radioButton input{background-image:var(--annotation-unfocused-field-background);border:1px solid transparent;box-sizing:border-box;font-size:9px;height:100%;margin:0;padding:0 3px;vertical-align:top;width:100%}[_nghost-%COMP%]     .annotationLayer .choiceWidgetAnnotation select option{padding:0}[_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.radioButton input{border-radius:50%}[_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation textarea{font:message-box;font-size:9px;resize:none}[_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation input[disabled], [_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation textarea[disabled], [_nghost-%COMP%]     .annotationLayer .choiceWidgetAnnotation select[disabled], [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox input[disabled], [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.radioButton input[disabled]{background:none;border:1px solid transparent;cursor:not-allowed}[_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation input:hover, [_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation textarea:hover, [_nghost-%COMP%]     .annotationLayer .choiceWidgetAnnotation select:hover, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox input:hover, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.radioButton input:hover{border:1px solid black}[_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation input:focus, [_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation textarea:focus, [_nghost-%COMP%]     .annotationLayer .choiceWidgetAnnotation select:focus{background:none;border:1px solid transparent}[_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation input :focus, [_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation textarea :focus, [_nghost-%COMP%]     .annotationLayer .choiceWidgetAnnotation select :focus, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox :focus, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.radioButton :focus{background-image:none;background-color:transparent;outline:auto}[_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:before, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:after, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.radioButton input:checked:before{background-color:#000;content:\"\";display:block;position:absolute}[_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:before, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:after{height:80%;left:45%;width:1px}[_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:before{transform:rotate(45deg)}[_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox input:checked:after{transform:rotate(-45deg)}[_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.radioButton input:checked:before{border-radius:50%;height:50%;left:30%;top:20%;width:50%}[_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation input.comb{font-family:monospace;padding-left:2px;padding-right:0}[_nghost-%COMP%]     .annotationLayer .textWidgetAnnotation input.comb:focus{width:103%}[_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.checkBox input, [_nghost-%COMP%]     .annotationLayer .buttonWidgetAnnotation.radioButton input{-webkit-appearance:none;-moz-appearance:none;appearance:none;padding:0}[_nghost-%COMP%]     .annotationLayer .popupWrapper{position:absolute;width:20em}[_nghost-%COMP%]     .annotationLayer .popup{position:absolute;z-index:200;max-width:20em;background-color:#ff9;box-shadow:0 2px 5px #888;border-radius:2px;padding:6px;margin-left:5px;cursor:pointer;font:message-box;font-size:9px;white-space:normal;word-wrap:break-word}[_nghost-%COMP%]     .annotationLayer .popup>*{font-size:9px}
1[_nghost-%COMP%]     .annotationLayer .popup h1{display:inline-block}[_nghost-%COMP%]     .annotationLayer .popupDate{display:inline-block;margin-left:5px}[_nghost-%COMP%]     .annotationLayer .popupContent{border-top:1px solid #333333;margin-top:2px;padding-top:2px}[_nghost-%COMP%]     .annotationLayer .richText>*{white-space:pre-wrap}[_nghost-%COMP%]     .annotationLayer .highlightAnnotation, [_nghost-%COMP%]     .annotationLayer .underlineAnnotation, [_nghost-%COMP%]     .annotationLayer .squigglyAnnotation, [_nghost-%COMP%]     .annotationLayer .strikeoutAnnotation, [_nghost-%COMP%]     .annotationLayer .freeTextAnnotation, [_nghost-%COMP%]     .annotationLayer .lineAnnotation svg line, [_nghost-%COMP%]     .annotationLayer .squareAnnotation svg rect, [_nghost-%COMP%]     .annotationLayer .circleAnnotation svg ellipse, [_nghost-%COMP%]     .annotationLayer .polylineAnnotation svg polyline, [_nghost-%COMP%]     .annotationLayer .polygonAnnotation svg polygon, [_nghost-%COMP%]     .annotationLayer .caretAnnotation, [_nghost-%COMP%]     .annotationLayer .inkAnnotation svg polyline, [_nghost-%COMP%]     .annotationLayer .stampAnnotation, [_nghost-%COMP%]     .annotationLayer .fileAttachmentAnnotation{cursor:pointer}[_nghost-%COMP%]     .xfaLayer .highlight{margin:-1px;padding:1px;background-color:#efcbed;border-radius:4px}[_nghost-%COMP%]     .xfaLayer .highlight.appended{position:initial}[_nghost-%COMP%]     .xfaLayer .highlight.begin{border-radius:4px 0 0 4px}[_nghost-%COMP%]     .xfaLayer .highlight.end{border-radius:0 4px 4px 0}[_nghost-%COMP%]     .xfaLayer .highlight.middle{border-radius:0}[_nghost-%COMP%]     .xfaLayer .highlight.selected{background-color:#cbdfcb}[_nghost-%COMP%]     .xfaLayer ::selection{background:blue}[_nghost-%COMP%]     .xfaPage{overflow:hidden;position:relative}[_nghost-%COMP%]     .xfaContentarea{position:absolute}[_nghost-%COMP%]     .xfaPrintOnly{display:none}[_nghost-%COMP%]     .xfaLayer{position:absolute;text-align:initial;top:0;left:0;transform-origin:0 0;line-height:1.2}[_nghost-%COMP%]     .xfaLayer *{color:inherit;font:inherit;font-style:inherit;font-weight:inherit;font-feature-settings:inherit;font-kerning:inherit;letter-spacing:-.01px;text-align:inherit;text-decoration:inherit;box-sizing:border-box;background-color:transparent;padding:0;margin:0;pointer-events:auto;line-height:inherit}[_nghost-%COMP%]     .xfaLayer div{pointer-events:none}[_nghost-%COMP%]     .xfaLayer svg{pointer-events:none}[_nghost-%COMP%]     .xfaLayer svg *{pointer-events:none}[_nghost-%COMP%]     .xfaLayer a{color:#00f}[_nghost-%COMP%]     .xfaRich li{margin-left:3em}[_nghost-%COMP%]     .xfaFont{color:#000;font-weight:400;font-feature-settings:\"kern\" off;font-kerning:none;font-size:10px;font-style:normal;letter-spacing:0;text-decoration:none;vertical-align:0}[_nghost-%COMP%]     .xfaCaption{overflow:hidden;flex:0 0 auto}[_nghost-%COMP%]     .xfaCaptionForCheckButton{overflow:hidden;flex:1 1 auto}[_nghost-%COMP%]     .xfaLabel{height:100%;width:100%}[_nghost-%COMP%]     .xfaLeft{display:flex;flex-direction:row;align-items:center}[_nghost-%COMP%]     .xfaRight{display:flex;flex-direction:row-reverse;align-items:center}[_nghost-%COMP%]     .xfaLeft>.xfaCaption, [_nghost-%COMP%]     .xfaLeft>.xfaCaptionForCheckButton, [_nghost-%COMP%]     .xfaRight>.xfaCaption, [_nghost-%COMP%]     .xfaRight>.xfaCaptionForCheckButton{max-height:100%}[_nghost-%COMP%]     .xfaTop{display:flex;flex-direction:column;align-items:flex-start}[_nghost-%COMP%]     .xfaBottom{display:flex;flex-direction:column-reverse;align-items:flex-start}[_nghost-%COMP%]     .xfaTop>.xfaCaption, [_nghost-%COMP%]     .xfaTop>.xfaCaptionForCheckButton, [_nghost-%COMP%]     .xfaBottom>.xfaCaption, [_nghost-%COMP%]     .xfaBottom>.xfaCaptionForCheckButton{width:100%}[_nghost-%COMP%]     .xfaBorder{background-color:transparent;position:absolute;pointer-events:none}[_nghost-%COMP%]     .xfaWrapped{width:100%;height:100%}[_nghost-%COMP%]     .xfaTextfield:focus, [_nghost-%COMP%]     .xfaSelect:focus{background-image:none;background-color:transparent;outline:auto;outline-offset:-1px}[_nghost-%COMP%]     .xfaCheckbox:focus, [_nghost-%COMP%]     .xfaRadio:focus{outline:auto}[_nghost-%COMP%]     .xfaTextfield, [_nghost-%COMP%]     .xfaSelect{height:100%;width:100%;flex:1 1 auto;border:none;resize:none;background-image:var(--xfa-unfocused-field-background)}[_nghost-%COMP%]     .xfaTop>.xfaTextfield, [_nghost-%COMP%]     .xfaTop>.xfaSelect, [_nghost-%COMP%]     .xfaBottom>.xfaTextfield, [_nghost-%COMP%]     .xfaBottom>.xfaSelect{flex:0 1 auto}
1[_nghost-%COMP%]     .xfaButton{cursor:pointer;width:100%;height:100%;border:none;text-align:center}[_nghost-%COMP%]     .xfaLink{width:100%;height:100%;position:absolute;top:0;left:0}[_nghost-%COMP%]     .xfaCheckbox, [_nghost-%COMP%]     .xfaRadio{width:100%;height:100%;flex:0 0 auto;border:none}[_nghost-%COMP%]     .xfaRich{white-space:pre-wrap;width:100%;height:100%}[_nghost-%COMP%]     .xfaImage{object-position:left top;object-fit:contain;width:100%;height:100%}[_nghost-%COMP%]     .xfaLrTb, [_nghost-%COMP%]     .xfaRlTb, [_nghost-%COMP%]     .xfaTb{display:flex;flex-direction:column;align-items:stretch}[_nghost-%COMP%]     .xfaLr{display:flex;flex-direction:row;align-items:stretch}[_nghost-%COMP%]     .xfaRl{display:flex;flex-direction:row-reverse;align-items:stretch}[_nghost-%COMP%]     .xfaTb>div{justify-content:left}[_nghost-%COMP%]     .xfaPosition{position:relative}[_nghost-%COMP%]     .xfaArea{position:relative}[_nghost-%COMP%]     .xfaValignMiddle{display:flex;align-items:center}[_nghost-%COMP%]     .xfaTable{display:flex;flex-direction:column;align-items:stretch}[_nghost-%COMP%]     .xfaTable .xfaRow{display:flex;flex-direction:row;align-items:stretch}[_nghost-%COMP%]     .xfaTable .xfaRlRow{display:flex;flex-direction:row-reverse;align-items:stretch;flex:1}[_nghost-%COMP%]     .xfaTable .xfaRlRow>div{flex:1}[_nghost-%COMP%]     .xfaNonInteractive input, [_nghost-%COMP%]     .xfaNonInteractive textarea, [_nghost-%COMP%]     .xfaDisabled input, [_nghost-%COMP%]     .xfaDisabled textarea, [_nghost-%COMP%]     .xfaReadOnly input, [_nghost-%COMP%]     .xfaReadOnly textarea{background:initial}@media print{[_nghost-%COMP%]     .xfaTextfield, [_nghost-%COMP%]     .xfaSelect{background:transparent}[_nghost-%COMP%]     .xfaSelect{-webkit-appearance:none;-moz-appearance:none;appearance:none;text-indent:1px;text-overflow:\"\"}}[_nghost-%COMP%]     .pdfViewer{padding-bottom:var(--pdfViewer-padding-bottom)}[_nghost-%COMP%]     .pdfViewer .canvasWrapper{overflow:hidden}[_nghost-%COMP%]     .pdfViewer .page{direction:ltr;width:816px;height:1056px;margin:var(--page-margin);position:relative;overflow:visible;border:var(--page-border);background-clip:content-box;border-image:var(--shadow) 9 9 repeat;background-color:#fff}[_nghost-%COMP%]     .pdfViewer .dummyPage{position:relative;width:0;height:var(--viewer-container-height)}[_nghost-%COMP%]     .pdfViewer.removePageBorders .page{margin:0 auto 10px;border:none}[_nghost-%COMP%]     .pdfViewer.singlePageView{display:inline-block}[_nghost-%COMP%]     .pdfViewer.singlePageView .page{margin:0;border:none}[_nghost-%COMP%]     .pdfViewer.scrollHorizontal, [_nghost-%COMP%]     .pdfViewer.scrollWrapped, [_nghost-%COMP%]     .spread{margin-left:3.5px;margin-right:3.5px;text-align:center}[_nghost-%COMP%]     .pdfViewer.scrollHorizontal, [_nghost-%COMP%]     .spread{white-space:nowrap}[_nghost-%COMP%]     .pdfViewer.removePageBorders, [_nghost-%COMP%]     .pdfViewer.scrollHorizontal .spread, [_nghost-%COMP%]     .pdfViewer.scrollWrapped .spread{margin-left:0;margin-right:0}[_nghost-%COMP%]     .spread .page, [_nghost-%COMP%]     .spread .dummyPage, [_nghost-%COMP%]     .pdfViewer.scrollHorizontal .page, [_nghost-%COMP%]     .pdfViewer.scrollWrapped .page, [_nghost-%COMP%]     .pdfViewer.scrollHorizontal .spread, [_nghost-%COMP%]     .pdfViewer.scrollWrapped .spread{display:inline-block;vertical-align:middle}[_nghost-%COMP%]     .spread .page, [_nghost-%COMP%]     .pdfViewer.scrollHorizontal .page, [_nghost-%COMP%]     .pdfViewer.scrollWrapped .page{margin-left:var(--spreadHorizontalWrapped-margin-LR);margin-right:var(--spreadHorizontalWrapped-margin-LR)}[_nghost-%COMP%]     .pdfViewer.removePageBorders .spread .page, [_nghost-%COMP%]     .pdfViewer.removePageBorders.scrollHorizontal .page, [_nghost-%COMP%]     .pdfViewer.removePageBorders.scrollWrapped .page{margin-left:5px;margin-right:5px}[_nghost-%COMP%]     .pdfViewer .page canvas{margin:0;display:block}[_nghost-%COMP%]     .pdfViewer .page canvas[hidden]{display:none}[_nghost-%COMP%]     .pdfViewer .page .loadingIcon{position:absolute;display:block;left:0;top:0;right:0;bottom:0;background:url(data:image/gif;base64,R0lGODlhGAAYAPQQAM7Ozvr6+uDg4LCwsOjo6I6OjsjIyJycnNjY2KioqMDAwPLy8nZ2doaGhri4uGhoaP///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh/ilPcHRpbWl6ZWQgd2l0aCBodHRwczovL2V6Z2lmLmNvbS9vcHRpbWl6ZQAh+QQJBwAQACwAAAAAGAAYAAAFmiAkjiTkOGVaBgjZNGSgkgKjjM8zLoI8iy+BKCdiCX8iBeMAhEEIPRXLxViYUE9CbCQoFAzFhHY3zkaT3oPvBz1zE4UBsr1eWZH4vAowOBwGAHk8AoQLfH6Agm0Ed3qOAXWOIgQKiWyFJQgDgJEpdG+WEACNEFNFmKVlVzJQk6qdkwqBoi1mebJ3ALNGeIZHtGSwNDS1RZKueCEAIfkECQcAEAAsAAAAABgAGAAABZcgJI4kpChlWgYCWRQkEKgjURgjw4zOg9CjVwuiEyEeO6CxkBC9nA+HiuUqLEyoBZI0Mx4SAF
1FgQCDZuguBoGv6Dtg0gvpqdhxQQDkBzuUr/4A1JwMKP39pc2mDhYCIc4GQYn6QCwCMeY91l0p6dBAEJ0OfcFRimZ91Mwt0alxxAIZyRmuAsKxDLKKvZbM1tJxmvGKRpn8hACH5BAkHABAALAAAAAAYABgAAAWhICSOJGQYZVoGAnkcJBKoI3EAY1GMCtPSosSBINKJBIwGkHdwBGGQA0OhYpEGQxNqkYzNIITBACEKKBaxxNfBeOCO4vMy0Hg8nDHFeCktkKtfNAtoS4UqAicKBj9zBAKPC4iKi4aRkISGmWWBmjUIAIyHkCUEAKCVo2WmREecVqoCgZhgP4NHrGWCj7e3szSpuxAsoVWxnp6cVV4kyZW+KSEAIfkECQcAEAAsAAAAABgAGAAABZkgJI4kBABlWgYEOQykEKgjMSDjcYxG0dKi108nEhQKQN4rCIMkCgbawjWYnSCLY2yGVSgEooBhWqsGGwxc0RtNBgoMhmJ1QgETjANYFeBKyUmBKQQIdT9JDmgPDQ6EhoKJD4sOgpWWgiwChyqEBH5hmptSoSOZgJ4kLKWkYTF7C2SaqaM/hEWygay4mYG8t6uffFuzl1iANCEAIfkECQcAEAAsAAAAABgAGAAABZ0gJI4khCBlmhKkopBCoI6LIozDMAIHO4uuBVBnOiR+I4FrCDwAZsKdQnaCLIwwmRUA8JmioprWUCjcwlwUMnAoG0qL03k2KCS8cC0UjOzDCQKBfHQFDAwFU4CCfgqFhy9+kZJWgzSKSAcPZn+BfQENDw8OljGWJAFeDoZPYTBnC1GdSXqnsoBolSulX2GyP6hgvnG0KrS3NJNhuSQhACH5BAkHABAALAAAAAAYABgAAAWaICSOJCQIZZoupGGQRKCOC0CMijIiwz2LABtQZxoMfjQhxAXszWQ7gOwECRhh0MCJJRJARTUoIHFAgbfI6uBwAJS01J/i4PClVYHvfV8lbLlIBmwFbQt+aGmChG18jXeGT4dICQxlb4g/AQUMDER9XjR6BAdiDQwINDBmkAsPDVh4cX4imw53iLKuaVqAcUsPqEiidkt6j4AzIQAh+QQJBwAQACwAAAAAGAAYAAAFmSAkjiREEGWaBiSCtCoZCMsIAKOg1LEo0KKbaKFQ9EYLoOkFuQlirNxzCQkUW9GZ0hQd4nyDAWr4G/esYSbyZFYZwu3jqiuvr8u8I2BwOAwASXh1e31/doeHC3klWnElfAlTd46MfQUGk2stCVEGBQWSdCciDg5VDAVYKoEiDQ0iBwxGcj9RDw8+qHIzebc2DJJQJK6qiKVyIQAh+QQJBwAQACwAAAAAGAAYAAAFmSAkjiS0LGWaBiRBtCoZCKgoCCMB1DF0sz6cCQDo5W62l28XAyZFpyECBv3lnCbhUqHMIo0Qg4Jbmn1jRCa4iV27TzfXGjEecOFWMN1OdvvfPGUuXSoKBw6EXokrAwcHRVU0UAeEBANAAAmUI1gNDyhjJgUHLW0iDg8FIqOnBQZrDA9TELE2rEYIDw4jta2LMpCrqld/YQpgIQAh+QQJBwAQACwAAAAAGAAYAAAFmyAkjiS0LGWaBiRBkKw6BgIqCsJcyyMe4yJajhcEml5H26o1PN2QQd3uFiv2AADlAgflIbDdZLgkABOJgep5LfWty4p4zeU+w+XsvJWXliEKDwdEBgMKYQ4PDw1qK3EDCCMAiQ5BCV0LCj+FSDQkgCgGBiYHAy2MIgoMghAHqw4HAGsNDEMFBTekdgwKI7aRB2MwkL2rVHoQoWchACH5BAkHABAALAAAAAAYABgAAAWWICSOJLQsZZoGJEGQrDoGAioKwlzLIx7jIlqOFwSaXkfbqjU83ZBB3e4WK0qrCxyU55peid0qcUwuixyNx6PhILsAcAJazXYj4lvz2MkLiFsHDAlEcABKZwwMBX8pBgoKQxAIigpBA1sLBj+PSDQkB4uSACYDlTMyBgWDEKVnl2QFBUigN61gBQYjtLV5JZ4jtlR6omMhACH5BAkHABAALAAAAAAYABgAAAWaICSOJLQsZZoGJEGQrDoGAioKwlzLIx7jIlqOFwSaXkdbidYanm7I4AjwYDh6saJuJ3JUG1mZi9srPA7EcRimJLrfJYWZUVC8TziXnEG3u/E+cIJaPAFrPQl1aQAIbRAGBZGHJQiMUQKRBkEKbQsAPZaEXQcslSYKmjMyAAdXj34ACkNEiUgDA5t+PAQHn6Ogjkuzry2DNwhuIQAh+QQFBwAQACwAAAAAGAAYAAAFnCAkjiS0LGVaBgBJEGSguo8zCsK4CPIsMg+ECCcKEH0ix6MwhJl4KiOp8UCdmrEbo6EoHpxF8A6aBBZ6vhf5dmAkkGr0CoWs21WGQ2FvsI9xC3l7B311fy93iWGKJQQOhHCAJQB6A3IqcWwJLU90i2FkUiMKlhBELEI6MwgDXRAGhQgAYD6tTqRFAJxpA6mvrqazSKJJhUWMpjlIIQA7) center no-repeat}[_nghost-%COMP%]     .pdfViewer .page .loadingIcon.notVisible{background:none}[_nghost-%COMP%]     .pdfViewer.enablePermissions .textLayer span{-webkit-user-select:none!important;user-select:none!important;cursor:not-allowed}[_nghost-%COMP%]     .pdfPresentationMode .pdfViewer{padding-bottom:0}[_nghost-%COMP%]     .pdfPresentationMode .spread{margin:0}[_nghost-%COMP%]     .pdfPresentationMode .pdfViewer .page{margin:0 auto;border:2px solid transparent}"]}),i})(),t=(()=>{class i{}return i.\u0275fac=function(l){return new(l||i)},i.\u0275mod=G.oAB({type:i}),i.\u0275inj=G.cJS({}),i})()},5592:(ue,L,ne)=>{"use strict";ne.d(L,{r:()=>O});var y=ne(9671),oe=ne(4650),G=(()=>{return(a=G||(G={}))[a.Up=1]="Up",a[a.Down=3]="Down",a[a.Right=6]="Right",a[a.Left=8]="Left",a[a.UpMirrored=2]="UpMirrored",a[a.DownMirrored=4]="DownMirrored",a[a.LeftMirrored=5]="LeftMirrored",a[a.RightMirrored=7]="RightMirrored",a[a.Default=0]="Default",a[a.NotJpeg=-1]="NotJpeg",a[a.NotDefined=-2]="NotDefined",G;var a})();class W{}W.getOrientation=a=>new Promise((v,g)=>{try{const f=new FileReader;f.onload=()=>{const r=new DataView(f.result);if(!r.byteLength||65496!==r.getUint16(0,!1))return v(G.NotDefined);const p=r.byteLength;let n=2;for(;n<p;){const s=r.getUint16(n,!1);if(n+=2,65505===s){if(1165519206!==r.getUint32(n+=2,!1))return v(G.NotJpeg);const u=18761===r.getUint16(n+=6,!1);n+=r.getUint32(n+4,u);const S=r.getUint16(n,u);n+=2;for(let d=0;d<S;d++)if(274===r.getUint16(n+12*d,u))return v(r.getUint16(n+12*d+8,u))}else{if(65280!=(65280&s))break;n+=r.getUint16(n,!1)}}return v(G.NotJpeg)},f.readAsArrayBuffer(a)}catch{return g(G.Default)}}),W.uploadFile=(a,v=!0)=>new Promise(function(g,f){const r=/^((?!chrome|android).)*safari/i.test(navigator.userAgent);Promise.resolve(r).then(p=>p?W.generateUploadInputNative(window.document,v):W.generateUploadInputRenderer(a,v)).then(p=>{const n=p?Array.from(p):[],s=n.map(d=>W.getOrientation(d)),u=n.map(d=>W.fileToDataURL(d));let S=[];Promise.all(s).then(d=>(S=d,Promise.all(u))).then(d=>{if(v){const _=d.map((t,i)=>({image:t,orientation:S[i]}));g(_)}else g({image:d[0],orientation:S[0]})})})}),W.fileToDataURL=a=>new Promise((v,g)=>{const f=new FileReader;f.onload=r=>{v(r.target.result)};
1try{f.readAsDataURL(a)}catch(r){g(`ngx-image-compress - probably no file have been selected: ${r}`)}}),W.generateUploadInputRenderer=(a,v=!0)=>new Promise((g,f)=>{const r=a.createElement("input");a.setStyle(r,"display","none"),a.setProperty(r,"type","file"),a.setProperty(r,"accept","image/*"),v&&a.setProperty(r,"multiple","true"),a.listen(r,"click",p=>{p.target.value=""}),a.listen(r,"change",p=>{g(p.target.files)}),r.click()}),W.generateUploadInputNative=(a,v=!0)=>{let g=!1;return new Promise((f,r)=>{const p=a.createElement("input");p.id="upload-input"+new Date,p.style.display="none",p.setAttribute("type","file"),v&&p.setAttribute("multiple","true"),a.body.appendChild(p),p.addEventListener("change",()=>{g=!0,f(p.files),a.body.removeChild(a.getElementById(p.id))},{once:!0}),window.addEventListener("focus",()=>{setTimeout(()=>{!g&&a.getElementById(p.id)&&(r(new Error("onblur")),a.body.removeChild(a.getElementById(p.id)))},300)},{once:!0}),p.click()})},W.compress=(a,v,g,f=50,r=50,p=0,n=0)=>new Promise(function(s,u){r/=100,f/=100;const S=new Image;S.onload=()=>{const d=g.createElement("canvas"),_=d.getContext("2d");if(!_)return u("No canvas context available");let t=S.naturalWidth,i=S.naturalHeight;if(!CSS.supports("image-orientation","from-image")&&(v===G.Right||v===G.Left)){const k=t;t=i,i=k}f=Math.min(f,p?p/t:1,n?n/i:1),d.width=t*f,d.height=i*f;const m=Math.PI/180;CSS.supports("image-orientation","from-image")||v===G.Up?_.drawImage(S,0,0,d.width,d.height):v===G.Right?(_.save(),_.rotate(90*m),_.translate(0,-d.width),_.drawImage(S,0,0,d.height,d.width),_.restore()):v===G.Left?(_.save(),_.rotate(-90*m),_.translate(-d.width,0),_.drawImage(S,0,0,d.height,d.width),_.restore()):v===G.Down?(_.save(),_.rotate(180*m),_.translate(-d.width,-d.height),_.drawImage(S,0,0,d.width,d.height),_.restore()):_.drawImage(S,0,0,d.width,d.height);const x=a.substr(5,a.split(";")[0].length-5),M=d.toDataURL(x,r);s(M)},S.onerror=d=>u(d),S.src=a}),W.byteCount=a=>encodeURI(a).split(/%..|./).length-1,W.getImageMaxSize=function(){var a=(0,y.Z)(function*(v,g,f){const p=u=>(u/1024/1024).toFixed(2);g&&console.debug("NgxImageCompress - Opening upload window");let s,n=yield W.uploadFile(f,!1);for(let u=0;u<10;u++){const S=W.byteCount(n.image);s=yield W.compress(n.image,n.orientation,f,50,100);const d=W.byteCount(s);if(console.debug("NgxImageCompress -","Compression from",p(S),"MB to",p(d),"MB"),d>=S)throw 0===u?(g&&console.debug("NgxImageCompress -","File can't be reduced at all - returning the original",p(S),"MB large"),n.image):(g&&console.debug("NgxImageCompress -","File can't be reduced more - returning the best we can, which is ",p(S),"MB large"),n.image);if(d<1024*v*1024)return g&&console.debug("NgxImageCompress -","Here your file",p(d),"MB large"),s;if(9===u)throw g&&console.debug("NgxImageCompress -","File can't reach the desired size after",10,"tries. Returning file ",p(S),"MB large"),n.image;g&&console.debug("NgxImageCompress -","Reached",p(d),"MB large. Trying another time after",u+1,"times"),n.image=s}throw g&&console.debug("NgxImageCompress - Unexpected error"),""});return function(v,g,f){return a.apply(this,arguments)}}();let O=(()=>{class a{constructor(g){this.DOC_ORIENTATION=G,this.render=g.createRenderer(null,null)}byteCount(g){return W.byteCount(g)}getOrientation(g){return W.getOrientation(g)}uploadFile(){return W.uploadFile(this.render,!1)}uploadMultipleFiles(){return W.uploadFile(this.render,!0)}compressFile(g,f,r=50,p=50,n=0,s=0){return W.compress(g,f,this.render,r,p,n,s)}uploadAndGetImageWithMaxSize(g=1,f=!1){return W.getImageMaxSize(g,f,this.render)}}return a.\u0275fac=function(g){return new(g||a)(oe.LFG(oe.FYo))},a.\u0275prov=oe.Yz7({token:a,factory:a.\u0275fac,providedIn:"root"}),a})()}}]);

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.