@sandeepmvn/react-pdf-annotator-v2 1.2.13 → 1.2.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
(function(t,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("react/jsx-runtime"),require("react")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react"],e):(t=typeof globalThis<"u"?globalThis:t||self,e(t.ReactPdfAnnotator={},t.jsxRuntime,t.React))})(this,function(exports,jsxRuntime,react){"use strict";var Qr=Object.defineProperty;var mr=t=>{throw TypeError(t)};var $r=(t,e,r)=>e in t?Qr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var $e=(t,e,r)=>$r(t,typeof e!="symbol"?e+"":e,r),Nt=(t,e,r)=>e.has(t)||mr("Cannot "+r);var b=(t,e,r)=>(Nt(t,e,"read from private field"),r?r.call(t):e.get(t)),de=(t,e,r)=>e.has(t)?mr("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,r),ue=(t,e,r,n)=>(Nt(t,e,"write to private field"),n?n.call(t,r):e.set(t,r),r),te=(t,e,r)=>(Nt(t,e,"access private method"),r);var ft=(t,e,r,n)=>({set _(a){ue(t,e,a,r)},get _(){return b(t,e,n)}});function getDefaultExportFromCjs(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function getAugmentedNamespace(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var r=function n(){return this instanceof n?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var a=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(r,n,a.get?a:{enumerable:!0,get:function(){return t[n]}})}),r}function commonjsRequire(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var pdf={exports:{}};const __viteBrowserExternal={},__viteBrowserExternal$1=Object.freeze(Object.defineProperty({__proto__:null,default:__viteBrowserExternal},Symbol.toStringTag,{value:"Module"})),require$$5=getAugmentedNamespace(__viteBrowserExternal$1);(function(module,exports$1){(function(e,r){module.exports=e.pdfjsLib=r()})(globalThis,()=>(()=>{var __webpack_modules__=[,(t,e)=>{var ze;Object.defineProperty(e,"__esModule",{value:!0}),e.VerbosityLevel=e.Util=e.UnknownErrorException=e.UnexpectedResponseException=e.TextRenderingMode=e.RenderingIntentFlag=e.PromiseCapability=e.PermissionFlag=e.PasswordResponses=e.PasswordException=e.PageActionEventType=e.OPS=e.MissingPDFException=e.MAX_IMAGE_SIZE_TO_CACHE=e.LINE_FACTOR=e.LINE_DESCENT_FACTOR=e.InvalidPDFException=e.ImageKind=e.IDENTITY_MATRIX=e.FormatError=e.FeatureTest=e.FONT_IDENTITY_MATRIX=e.DocumentActionEventType=e.CMapCompressionType=e.BaseException=e.BASELINE_FACTOR=e.AnnotationType=e.AnnotationReplyType=e.AnnotationPrefix=e.AnnotationMode=e.AnnotationFlag=e.AnnotationFieldFlag=e.AnnotationEditorType=e.AnnotationEditorPrefix=e.AnnotationEditorParamsType=e.AnnotationBorderStyleType=e.AnnotationActionEventType=e.AbortException=void 0,e.assert=B,e.bytesToString=ve,e.createValidAbsoluteUrl=Q,e.getModificationDate=Te,e.getUuid=Ee,e.getVerbosityLevel=K,e.info=J,e.isArrayBuffer=ie,e.isArrayEqual=_e,e.isNodeJS=void 0,e.normalizeUnicode=Me,e.objectFromMap=Ce,e.objectSize=Se,e.setVerbosityLevel=$,e.shadow=N,e.string32=xe,e.stringToBytes=me,e.stringToPDFString=ye,e.stringToUTF8String=Fe,e.unreachable=se,e.utf8StringToString=Pe,e.warn=Y;const r=typeof process=="object"&&process+""=="[object process]"&&!process.versions.nw&&!(process.versions.electron&&process.type&&process.type!=="browser");e.isNodeJS=r;const n=[1,0,0,1,0,0];e.IDENTITY_MATRIX=n;const a=[.001,0,0,.001,0,0];e.FONT_IDENTITY_MATRIX=a;const s=1e7;e.MAX_IMAGE_SIZE_TO_CACHE=s;const o=1.35;e.LINE_FACTOR=o;const h=.35;e.LINE_DESCENT_FACTOR=h;const d=h/o;e.BASELINE_FACTOR=d;const l={ANY:1,DISPLAY:2,PRINT:4,SAVE:8,ANNOTATIONS_FORMS:16,ANNOTATIONS_STORAGE:32,ANNOTATIONS_DISABLE:64,OPLIST:256};e.RenderingIntentFlag=l;const u={DISABLE:0,ENABLE:1,ENABLE_FORMS:2,ENABLE_STORAGE:3};e.AnnotationMode=u;const p="pdfjs_internal_editor_";e.AnnotationEditorPrefix=p;const g={DISABLE:-1,NONE:0,FREETEXT:3,STAMP:13,INK:15};e.AnnotationEditorType=g;const f={RESIZE:1,CREATE:2,FREETEXT_SIZE:11,FREETEXT_COLOR:12,FREETEXT_OPACITY:13,INK_COLOR:21,INK_THICKNESS:22,INK_OPACITY:23};e.AnnotationEditorParamsType=f;const v={PRINT:4,MODIFY_CONTENTS:8,COPY:16,MODIFY_ANNOTATIONS:32,FILL_INTERACTIVE_FORMS:256,COPY_FOR_ACCESSIBILITY:512,ASSEMBLE:1024,PRINT_HIGH_QUALITY:2048};e.PermissionFlag=v;const y={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};e.TextRenderingMode=y;const x={GRAYSCALE_1BPP:1,RGB_24BPP:2,RGBA_32BPP:3};e.ImageKind=x;const m={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};e.AnnotationType=m;const w={GROUP:"Group",REPLY:"R"};e.AnnotationReplyType=w;const R={INVISIBLE:1,HIDDEN:2,PRINT:4,NOZOOM:8,NOROTATE:16,NOVIEW:32,READONLY:64,LOCKED:128,TOGGLENOVIEW:256,LOCKEDCONTENTS:512};e.AnnotationFlag=R;const _={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};e.AnnotationFieldFlag=_;const S={SOLID:1,DASHED:2,BEVELED:3,INSET:4,UNDERLINE:5};e.AnnotationBorderStyleType=S;const F={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"};e.AnnotationActionEventType=F;const A={WC:"WillClose",WS:"WillSave",DS:"DidSave",WP:"WillPrint",DP:"DidPrint"};e.DocumentActionEventType=A;const D={O:"PageOpen",C:"PageClose"};e.PageActionEventType=D;const T={ERRORS:0,WARNINGS:1,INFOS:5};e.VerbosityLevel=T;const M={NONE:0,BINARY:1};e.CMapCompressionType=M;const C={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,beginAnnotation:80,endAnnotation:81,paintImageMaskXObject:83,paintImageMaskXObjectGroup:84,paintImageXObject:85,paintInlineImageXObject:86,paintInlineImageXObjectGroup:87,paintImageXObjectRepeat:88,paintImageMaskXObjectRepeat:89,paintSolidColorImageMask:90,constructPath:91};e.OPS=C;const k={NEED_PASSWORD:1,INCORRECT_PASSWORD:2};e.PasswordResponses=k;let O=T.WARNINGS;function $(be){Number.isInteger(be)&&(O=be)}function K(){return O}function J(be){O>=T.INFOS&&console.log(`Info: ${be}`)}function Y(be){O>=T.WARNINGS&&console.log(`Warning: ${be}`)}function se(be){throw new Error(be)}function B(be,oe){be||se(oe)}function V(be){switch(be==null?void 0:be.protocol){case"http:":case"https:":case"ftp:":case"mailto:":case"tel:":return!0;default:return!1}}function Q(be,oe=null,ae=null){if(!be)return null;try{if(ae&&typeof be=="string"){if(ae.addDefaultProtocol&&be.startsWith("www.")){const We=be.match(/\./g);(We==null?void 0:We.length)>=2&&(be=`http://${be}`)}if(ae.tryConvertEncoding)try{be=Fe(be)}catch{}}const Re=oe?new URL(be,oe):new URL(be);if(V(Re))return Re}catch{}return null}function N(be,oe,ae,Re=!1){return Object.defineProperty(be,oe,{value:ae,enumerable:!Re,configurable:!0,writable:!1}),ae}const P=function(){function oe(ae,Re){this.constructor===oe&&se("Cannot initialize BaseException."),this.message=ae,this.name=Re}return oe.prototype=new Error,oe.constructor=oe,oe}();e.BaseException=P;class E extends P{constructor(oe,ae){super(oe,"PasswordException"),this.code=ae}}e.PasswordException=E;class I extends P{constructor(oe,ae){super(oe,"UnknownErrorException"),this.details=ae}}e.UnknownErrorException=I;class z extends P{constructor(oe){super(oe,"InvalidPDFException")}}e.InvalidPDFException=z;class G extends P{constructor(oe){super(oe,"MissingPDFException")}}e.MissingPDFException=G;class H extends P{constructor(oe,ae){super(oe,"UnexpectedResponseException"),this.status=ae}}e.UnexpectedResponseException=H;class ee extends P{constructor(oe){super(oe,"FormatError")}}e.FormatError=ee;class ce extends P{constructor(oe){super(oe,"AbortException")}}e.AbortException=ce;function ve(be){(typeof be!="object"||(be==null?void 0:be.length)===void 0)&&se("Invalid argument for bytesToString");const oe=be.length,ae=8192;if(oe<ae)return String.fromCharCode.apply(null,be);const Re=[];for(let We=0;We<oe;We+=ae){const Ve=Math.min(We+ae,oe),X=be.subarray(We,Ve);Re.push(String.fromCharCode.apply(null,X))}return Re.join("")}function me(be){typeof be!="string"&&se("Invalid argument for stringToBytes");const oe=be.length,ae=new Uint8Array(oe);for(let Re=0;Re<oe;++Re)ae[Re]=be.charCodeAt(Re)&255;return ae}function xe(be){return String.fromCharCode(be>>24&255,be>>16&255,be>>8&255,be&255)}function Se(be){return Object.keys(be).length}function Ce(be){const oe=Object.create(null);for(const[ae,Re]of be)oe[ae]=Re;return oe}function ne(){const be=new Uint8Array(4);return be[0]=1,new Uint32Array(be.buffer,0,1)[0]===1}function le(){try{return new Function(""),!0}catch{return!1}}class L{static get isLittleEndian(){return N(this,"isLittleEndian",ne())}static get isEvalSupported(){return N(this,"isEvalSupported",le())}static get isOffscreenCanvasSupported(){return N(this,"isOffscreenCanvasSupported",typeof OffscreenCanvas<"u")}static get platform(){return typeof navigator>"u"?N(this,"platform",{isWin:!1,isMac:!1}):N(this,"platform",{isWin:navigator.platform.includes("Win"),isMac:navigator.platform.includes("Mac")})}static get isCSSRoundSupported(){var oe,ae;return N(this,"isCSSRoundSupported",(ae=(oe=globalThis.CSS)==null?void 0:oe.supports)==null?void 0:ae.call(oe,"width: round(1.5px, 1px)"))}}e.FeatureTest=L;const Z=[...Array(256).keys()].map(be=>be.toString(16).padStart(2,"0"));class re{static makeHexColor(oe,ae,Re){return`#${Z[oe]}${Z[ae]}${Z[Re]}`}static scaleMinMax(oe,ae){let Re;oe[0]?(oe[0]<0&&(Re=ae[0],ae[0]=ae[1],ae[1]=Re),ae[0]*=oe[0],ae[1]*=oe[0],oe[3]<0&&(Re=ae[2],ae[2]=ae[3],ae[3]=Re),ae[2]*=oe[3],ae[3]*=oe[3]):(Re=ae[0],ae[0]=ae[2],ae[2]=Re,Re=ae[1],ae[1]=ae[3],ae[3]=Re,oe[1]<0&&(Re=ae[2],ae[2]=ae[3],ae[3]=Re),ae[2]*=oe[1],ae[3]*=oe[1],oe[2]<0&&(Re=ae[0],ae[0]=ae[1],ae[1]=Re),ae[0]*=oe[2],ae[1]*=oe[2]),ae[0]+=oe[4],ae[1]+=oe[4],ae[2]+=oe[5],ae[3]+=oe[5]}static transform(oe,ae){return[oe[0]*ae[0]+oe[2]*ae[1],oe[1]*ae[0]+oe[3]*ae[1],oe[0]*ae[2]+oe[2]*ae[3],oe[1]*ae[2]+oe[3]*ae[3],oe[0]*ae[4]+oe[2]*ae[5]+oe[4],oe[1]*ae[4]+oe[3]*ae[5]+oe[5]]}static applyTransform(oe,ae){const Re=oe[0]*ae[0]+oe[1]*ae[2]+ae[4],We=oe[0]*ae[1]+oe[1]*ae[3]+ae[5];return[Re,We]}static applyInverseTransform(oe,ae){const Re=ae[0]*ae[3]-ae[1]*ae[2],We=(oe[0]*ae[3]-oe[1]*ae[2]+ae[2]*ae[5]-ae[4]*ae[3])/Re,Ve=(-oe[0]*ae[1]+oe[1]*ae[0]+ae[4]*ae[1]-ae[5]*ae[0])/Re;return[We,Ve]}static getAxialAlignedBoundingBox(oe,ae){const Re=this.applyTransform(oe,ae),We=this.applyTransform(oe.slice(2,4),ae),Ve=this.applyTransform([oe[0],oe[3]],ae),X=this.applyTransform([oe[2],oe[1]],ae);return[Math.min(Re[0],We[0],Ve[0],X[0]),Math.min(Re[1],We[1],Ve[1],X[1]),Math.max(Re[0],We[0],Ve[0],X[0]),Math.max(Re[1],We[1],Ve[1],X[1])]}static inverseTransform(oe){const ae=oe[0]*oe[3]-oe[1]*oe[2];return[oe[3]/ae,-oe[1]/ae,-oe[2]/ae,oe[0]/ae,(oe[2]*oe[5]-oe[4]*oe[3])/ae,(oe[4]*oe[1]-oe[5]*oe[0])/ae]}static singularValueDecompose2dScale(oe){const ae=[oe[0],oe[2],oe[1],oe[3]],Re=oe[0]*ae[0]+oe[1]*ae[2],We=oe[0]*ae[1]+oe[1]*ae[3],Ve=oe[2]*ae[0]+oe[3]*ae[2],X=oe[2]*ae[1]+oe[3]*ae[3],ge=(Re+X)/2,ke=Math.sqrt((Re+X)**2-4*(Re*X-Ve*We))/2,Be=ge+ke||1,He=ge-ke||1;return[Math.sqrt(Be),Math.sqrt(He)]}static normalizeRect(oe){const ae=oe.slice(0);return oe[0]>oe[2]&&(ae[0]=oe[2],ae[2]=oe[0]),oe[1]>oe[3]&&(ae[1]=oe[3],ae[3]=oe[1]),ae}static intersect(oe,ae){const Re=Math.max(Math.min(oe[0],oe[2]),Math.min(ae[0],ae[2])),We=Math.min(Math.max(oe[0],oe[2]),Math.max(ae[0],ae[2]));if(Re>We)return null;const Ve=Math.max(Math.min(oe[1],oe[3]),Math.min(ae[1],ae[3])),X=Math.min(Math.max(oe[1],oe[3]),Math.max(ae[1],ae[3]));return Ve>X?null:[Re,Ve,We,X]}static bezierBoundingBox(oe,ae,Re,We,Ve,X,ge,ke){const Be=[],He=[[],[]];let Ne,U,j,W,fe,pe,Ae,we;for(let Ge=0;Ge<2;++Ge){if(Ge===0?(U=6*oe-12*Re+6*Ve,Ne=-3*oe+9*Re-9*Ve+3*ge,j=3*Re-3*oe):(U=6*ae-12*We+6*X,Ne=-3*ae+9*We-9*X+3*ke,j=3*We-3*ae),Math.abs(Ne)<1e-12){if(Math.abs(U)<1e-12)continue;W=-j/U,0<W&&W<1&&Be.push(W);continue}Ae=U*U-4*j*Ne,we=Math.sqrt(Ae),!(Ae<0)&&(fe=(-U+we)/(2*Ne),0<fe&&fe<1&&Be.push(fe),pe=(-U-we)/(2*Ne),0<pe&&pe<1&&Be.push(pe))}let je=Be.length,Le;const De=je;for(;je--;)W=Be[je],Le=1-W,He[0][je]=Le*Le*Le*oe+3*Le*Le*W*Re+3*Le*W*W*Ve+W*W*W*ge,He[1][je]=Le*Le*Le*ae+3*Le*Le*W*We+3*Le*W*W*X+W*W*W*ke;return He[0][De]=oe,He[1][De]=ae,He[0][De+1]=ge,He[1][De+1]=ke,He[0].length=He[1].length=De+2,[Math.min(...He[0]),Math.min(...He[1]),Math.max(...He[0]),Math.max(...He[1])]}}e.Util=re;const he=[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 ye(be){if(be[0]>="ï"){let ae;if(be[0]==="þ"&&be[1]==="ÿ"?ae="utf-16be":be[0]==="ÿ"&&be[1]==="þ"?ae="utf-16le":be[0]==="ï"&&be[1]==="»"&&be[2]==="¿"&&(ae="utf-8"),ae)try{const Re=new TextDecoder(ae,{fatal:!0}),We=me(be);return Re.decode(We)}catch(Re){Y(`stringToPDFString: "${Re}".`)}}const oe=[];for(let ae=0,Re=be.length;ae<Re;ae++){const We=he[be.charCodeAt(ae)];oe.push(We?String.fromCharCode(We):be.charAt(ae))}return oe.join("")}function Fe(be){return decodeURIComponent(escape(be))}function Pe(be){return unescape(encodeURIComponent(be))}function ie(be){return typeof be=="object"&&(be==null?void 0:be.byteLength)!==void 0}function _e(be,oe){if(be.length!==oe.length)return!1;for(let ae=0,Re=be.length;ae<Re;ae++)if(be[ae]!==oe[ae])return!1;return!0}function Te(be=new Date){return[be.getUTCFullYear().toString(),(be.getUTCMonth()+1).toString().padStart(2,"0"),be.getUTCDate().toString().padStart(2,"0"),be.getUTCHours().toString().padStart(2,"0"),be.getUTCMinutes().toString().padStart(2,"0"),be.getUTCSeconds().toString().padStart(2,"0")].join("")}class Ke{constructor(){de(this,ze,!1);this.promise=new Promise((oe,ae)=>{this.resolve=Re=>{ue(this,ze,!0),oe(Re)},this.reject=Re=>{ue(this,ze,!0),ae(Re)}})}get settled(){return b(this,ze)}}ze=new WeakMap,e.PromiseCapability=Ke;let qe=null,Ye=null;function Me(be){return qe||(qe=/([\u00a0\u00b5\u037e\u0eb3\u2000-\u200a\u202f\u2126\ufb00-\ufb04\ufb06\ufb20-\ufb36\ufb38-\ufb3c\ufb3e\ufb40-\ufb41\ufb43-\ufb44\ufb46-\ufba1\ufba4-\ufba9\ufbae-\ufbb1\ufbd3-\ufbdc\ufbde-\ufbe7\ufbea-\ufbf8\ufbfc-\ufbfd\ufc00-\ufc5d\ufc64-\ufcf1\ufcf5-\ufd3d\ufd88\ufdf4\ufdfa-\ufdfb\ufe71\ufe77\ufe79\ufe7b\ufe7d]+)|(\ufb05+)/gu,Ye=new Map([["ſt","ſt"]])),be.replaceAll(qe,(oe,ae,Re)=>ae?ae.normalize("NFKC"):Ye.get(Re))}function Ee(){if(typeof crypto<"u"&&typeof(crypto==null?void 0:crypto.randomUUID)=="function")return crypto.randomUUID();const be=new Uint8Array(32);if(typeof crypto<"u"&&typeof(crypto==null?void 0:crypto.getRandomValues)=="function")crypto.getRandomValues(be);else for(let oe=0;oe<32;oe++)be[oe]=Math.floor(Math.random()*255);return ve(be)}const Ie="pdfjs_internal_id_";e.AnnotationPrefix=Ie},(__unused_webpack_module,exports$1,__w_pdfjs_require__)=>{var t,r,n,a,lt,St,h,d,l,u,p,g,f,v,y,At,m,w,Mt,_,S;Object.defineProperty(exports$1,"__esModule",{value:!0}),exports$1.RenderTask=exports$1.PDFWorkerUtil=exports$1.PDFWorker=exports$1.PDFPageProxy=exports$1.PDFDocumentProxy=exports$1.PDFDocumentLoadingTask=exports$1.PDFDataRangeTransport=exports$1.LoopbackPort=exports$1.DefaultStandardFontDataFactory=exports$1.DefaultFilterFactory=exports$1.DefaultCanvasFactory=exports$1.DefaultCMapReaderFactory=void 0,Object.defineProperty(exports$1,"SVGGraphics",{enumerable:!0,get:function(){return _displaySvg.SVGGraphics}}),exports$1.build=void 0,exports$1.getDocument=getDocument,exports$1.version=void 0;var _util=__w_pdfjs_require__(1),_annotation_storage=__w_pdfjs_require__(3),_display_utils=__w_pdfjs_require__(6),_font_loader=__w_pdfjs_require__(9),_displayNode_utils=__w_pdfjs_require__(10),_canvas=__w_pdfjs_require__(11),_worker_options=__w_pdfjs_require__(14),_message_handler=__w_pdfjs_require__(15),_metadata=__w_pdfjs_require__(16),_optional_content_config=__w_pdfjs_require__(17),_transport_stream=__w_pdfjs_require__(18),_displayFetch_stream=__w_pdfjs_require__(19),_displayNetwork=__w_pdfjs_require__(22),_displayNode_stream=__w_pdfjs_require__(23),_displaySvg=__w_pdfjs_require__(24),_xfa_text=__w_pdfjs_require__(25);const DEFAULT_RANGE_CHUNK_SIZE=65536,RENDERING_CANCELLED_TIMEOUT=100,DELAYED_CLEANUP_TIMEOUT=5e3,DefaultCanvasFactory=_util.isNodeJS?_displayNode_utils.NodeCanvasFactory:_display_utils.DOMCanvasFactory;exports$1.DefaultCanvasFactory=DefaultCanvasFactory;const DefaultCMapReaderFactory=_util.isNodeJS?_displayNode_utils.NodeCMapReaderFactory:_display_utils.DOMCMapReaderFactory;exports$1.DefaultCMapReaderFactory=DefaultCMapReaderFactory;const DefaultFilterFactory=_util.isNodeJS?_displayNode_utils.NodeFilterFactory:_display_utils.DOMFilterFactory;exports$1.DefaultFilterFactory=DefaultFilterFactory;const DefaultStandardFontDataFactory=_util.isNodeJS?_displayNode_utils.NodeStandardFontDataFactory:_display_utils.DOMStandardFontDataFactory;exports$1.DefaultStandardFontDataFactory=DefaultStandardFontDataFactory;function getDocument(A){if(typeof A=="string"||A instanceof URL?A={url:A}:(0,_util.isArrayBuffer)(A)&&(A={data:A}),typeof A!="object")throw new Error("Invalid parameter in getDocument, need parameter object.");if(!A.url&&!A.data&&!A.range)throw new Error("Invalid parameter object: need either .data, .range or .url");const D=new PDFDocumentLoadingTask,{docId:T}=D,M=A.url?getUrlProp(A.url):null,C=A.data?getDataProp(A.data):null,k=A.httpHeaders||null,O=A.withCredentials===!0,$=A.password??null,K=A.range instanceof PDFDataRangeTransport?A.range:null,J=Number.isInteger(A.rangeChunkSize)&&A.rangeChunkSize>0?A.rangeChunkSize:DEFAULT_RANGE_CHUNK_SIZE;let Y=A.worker instanceof PDFWorker?A.worker:null;const se=A.verbosity,B=typeof A.docBaseUrl=="string"&&!(0,_display_utils.isDataScheme)(A.docBaseUrl)?A.docBaseUrl:null,V=typeof A.cMapUrl=="string"?A.cMapUrl:null,Q=A.cMapPacked!==!1,N=A.CMapReaderFactory||DefaultCMapReaderFactory,P=typeof A.standardFontDataUrl=="string"?A.standardFontDataUrl:null,E=A.StandardFontDataFactory||DefaultStandardFontDataFactory,I=A.stopAtErrors!==!0,z=Number.isInteger(A.maxImageSize)&&A.maxImageSize>-1?A.maxImageSize:-1,G=A.isEvalSupported!==!1,H=typeof A.isOffscreenCanvasSupported=="boolean"?A.isOffscreenCanvasSupported:!_util.isNodeJS,ee=Number.isInteger(A.canvasMaxAreaInBytes)?A.canvasMaxAreaInBytes:-1,ce=typeof A.disableFontFace=="boolean"?A.disableFontFace:_util.isNodeJS,ve=A.fontExtraProperties===!0,me=A.enableXfa===!0,xe=A.ownerDocument||globalThis.document,Se=A.disableRange===!0,Ce=A.disableStream===!0,ne=A.disableAutoFetch===!0,le=A.pdfBug===!0,L=K?K.length:A.length??NaN,Z=typeof A.useSystemFonts=="boolean"?A.useSystemFonts:!_util.isNodeJS&&!ce,re=typeof A.useWorkerFetch=="boolean"?A.useWorkerFetch:N===_display_utils.DOMCMapReaderFactory&&E===_display_utils.DOMStandardFontDataFactory&&V&&P&&(0,_display_utils.isValidFetchUrl)(V,document.baseURI)&&(0,_display_utils.isValidFetchUrl)(P,document.baseURI),he=A.canvasFactory||new DefaultCanvasFactory({ownerDocument:xe}),ye=A.filterFactory||new DefaultFilterFactory({docId:T,ownerDocument:xe}),Fe=null;(0,_util.setVerbosityLevel)(se);const Pe={canvasFactory:he,filterFactory:ye};if(re||(Pe.cMapReaderFactory=new N({baseUrl:V,isCompressed:Q}),Pe.standardFontDataFactory=new E({baseUrl:P})),!Y){const Te={verbosity:se,port:_worker_options.GlobalWorkerOptions.workerPort};Y=Te.port?PDFWorker.fromPort(Te):new PDFWorker(Te),D._worker=Y}const ie={docId:T,apiVersion:"3.11.174",data:C,password:$,disableAutoFetch:ne,rangeChunkSize:J,length:L,docBaseUrl:B,enableXfa:me,evaluatorOptions:{maxImageSize:z,disableFontFace:ce,ignoreErrors:I,isEvalSupported:G,isOffscreenCanvasSupported:H,canvasMaxAreaInBytes:ee,fontExtraProperties:ve,useSystemFonts:Z,cMapUrl:re?V:null,standardFontDataUrl:re?P:null}},_e={ignoreErrors:I,isEvalSupported:G,disableFontFace:ce,fontExtraProperties:ve,enableXfa:me,ownerDocument:xe,disableAutoFetch:ne,pdfBug:le,styleElement:Fe};return Y.promise.then(function(){if(D.destroyed)throw new Error("Loading aborted");const Te=_fetchDocument(Y,ie),Ke=new Promise(function(qe){let Ye;K?Ye=new _transport_stream.PDFDataTransportStream({length:L,initialData:K.initialData,progressiveDone:K.progressiveDone,contentDispositionFilename:K.contentDispositionFilename,disableRange:Se,disableStream:Ce},K):C||(Ye=(Ee=>_util.isNodeJS?new _displayNode_stream.PDFNodeStream(Ee):(0,_display_utils.isValidFetchUrl)(Ee.url)?new _displayFetch_stream.PDFFetchStream(Ee):new _displayNetwork.PDFNetworkStream(Ee))({url:M,length:L,httpHeaders:k,withCredentials:O,rangeChunkSize:J,disableRange:Se,disableStream:Ce})),qe(Ye)});return Promise.all([Te,Ke]).then(function([qe,Ye]){if(D.destroyed)throw new Error("Loading aborted");const Me=new _message_handler.MessageHandler(T,qe,Y.port),Ee=new WorkerTransport(Me,D,Ye,_e,Pe);D._transport=Ee,Me.send("Ready",null)})}).catch(D._capability.reject),D}async function _fetchDocument(A,D){if(A.destroyed)throw new Error("Worker was destroyed");const T=await A.messageHandler.sendWithPromise("GetDocRequest",D,D.data?[D.data.buffer]:null);if(A.destroyed)throw new Error("Worker was destroyed");return T}function getUrlProp(A){if(A instanceof URL)return A.href;try{return new URL(A,window.location).href}catch{if(_util.isNodeJS&&typeof A=="string")return A}throw new Error("Invalid PDF url data: either string or URL-object is expected in the url property.")}function getDataProp(A){if(_util.isNodeJS&&typeof Buffer<"u"&&A instanceof Buffer)throw new Error("Please provide binary data as `Uint8Array`, rather than `Buffer`.");if(A instanceof Uint8Array&&A.byteLength===A.buffer.byteLength)return A;if(typeof A=="string")return(0,_util.stringToBytes)(A);if(typeof A=="object"&&!isNaN(A==null?void 0:A.length)||(0,_util.isArrayBuffer)(A))return new Uint8Array(A);throw new Error("Invalid PDF binary data: either TypedArray, string, or array-like object is expected in the data property.")}const e=class e{constructor(){this._capability=new _util.PromiseCapability,this._transport=null,this._worker=null,this.docId=`d${ft(e,t)._++}`,this.destroyed=!1,this.onPassword=null,this.onProgress=null}get promise(){return this._capability.promise}async destroy(){var D,T,M;this.destroyed=!0;try{(D=this._worker)!=null&&D.port&&(this._worker._pendingDestroy=!0),await((T=this._transport)==null?void 0:T.destroy())}catch(C){throw(M=this._worker)!=null&&M.port&&delete this._worker._pendingDestroy,C}this._transport=null,this._worker&&(this._worker.destroy(),this._worker=null)}};t=new WeakMap,de(e,t,0);let PDFDocumentLoadingTask=e;exports$1.PDFDocumentLoadingTask=PDFDocumentLoadingTask;class PDFDataRangeTransport{constructor(D,T,M=!1,C=null){this.length=D,this.initialData=T,this.progressiveDone=M,this.contentDispositionFilename=C,this._rangeListeners=[],this._progressListeners=[],this._progressiveReadListeners=[],this._progressiveDoneListeners=[],this._readyCapability=new _util.PromiseCapability}addRangeListener(D){this._rangeListeners.push(D)}addProgressListener(D){this._progressListeners.push(D)}addProgressiveReadListener(D){this._progressiveReadListeners.push(D)}addProgressiveDoneListener(D){this._progressiveDoneListeners.push(D)}onDataRange(D,T){for(const M of this._rangeListeners)M(D,T)}onDataProgress(D,T){this._readyCapability.promise.then(()=>{for(const M of this._progressListeners)M(D,T)})}onDataProgressiveRead(D){this._readyCapability.promise.then(()=>{for(const T of this._progressiveReadListeners)T(D)})}onDataProgressiveDone(){this._readyCapability.promise.then(()=>{for(const D of this._progressiveDoneListeners)D()})}transportReady(){this._readyCapability.resolve()}requestDataRange(D,T){(0,_util.unreachable)("Abstract method PDFDataRangeTransport.requestDataRange")}abort(){}}exports$1.PDFDataRangeTransport=PDFDataRangeTransport;class PDFDocumentProxy{constructor(D,T){this._pdfInfo=D,this._transport=T,Object.defineProperty(this,"getJavaScript",{value:()=>((0,_display_utils.deprecated)("`PDFDocumentProxy.getJavaScript`, please use `PDFDocumentProxy.getJSActions` instead."),this.getJSActions().then(M=>{if(!M)return M;const C=[];for(const k in M)C.push(...M[k]);return C}))})}get annotationStorage(){return this._transport.annotationStorage}get filterFactory(){return this._transport.filterFactory}get numPages(){return this._pdfInfo.numPages}get fingerprints(){return this._pdfInfo.fingerprints}get isPureXfa(){return(0,_util.shadow)(this,"isPureXfa",!!this._transport._htmlForXfa)}get allXfaHtml(){return this._transport._htmlForXfa}getPage(D){return this._transport.getPage(D)}getPageIndex(D){return this._transport.getPageIndex(D)}getDestinations(){return this._transport.getDestinations()}getDestination(D){return this._transport.getDestination(D)}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()}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()}saveDocument(){return this._transport.saveDocument()}getDownloadInfo(){return this._transport.downloadInfoCapability.promise}cleanup(D=!1){return this._transport.startCleanup(D||this.isPureXfa)}destroy(){return this.loadingTask.destroy()}get loadingParams(){return this._transport.loadingParams}get loadingTask(){return this._transport.loadingTask}getFieldObjects(){return this._transport.getFieldObjects()}hasJSActions(){return this._transport.hasJSActions()}getCalculationOrderIds(){return this._transport.getCalculationOrderIds()}}exports$1.PDFDocumentProxy=PDFDocumentProxy;class PDFPageProxy{constructor(D,T,M,C=!1){de(this,a);de(this,r,null);de(this,n,!1);this._pageIndex=D,this._pageInfo=T,this._transport=M,this._stats=C?new _display_utils.StatTimer:null,this._pdfBug=C,this.commonObjs=M.commonObjs,this.objs=new PDFObjects,this._maybeCleanupAfterRender=!1,this._intentStates=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:D,rotation:T=this.rotate,offsetX:M=0,offsetY:C=0,dontFlip:k=!1}={}){return new _display_utils.PageViewport({viewBox:this.view,scale:D,rotation:T,offsetX:M,offsetY:C,dontFlip:k})}getAnnotations({intent:D="display"}={}){const T=this._transport.getRenderingIntent(D);return this._transport.getAnnotations(this._pageIndex,T.renderingIntent)}getJSActions(){return this._transport.getPageJSActions(this._pageIndex)}get filterFactory(){return this._transport.filterFactory}get isPureXfa(){return(0,_util.shadow)(this,"isPureXfa",!!this._transport._htmlForXfa)}async getXfa(){var D;return((D=this._transport._htmlForXfa)==null?void 0:D.children[this._pageIndex])||null}render({canvasContext:D,viewport:T,intent:M="display",annotationMode:C=_util.AnnotationMode.ENABLE,transform:k=null,background:O=null,optionalContentConfigPromise:$=null,annotationCanvasMap:K=null,pageColors:J=null,printAnnotationStorage:Y=null}){var E,I;(E=this._stats)==null||E.time("Overall");const se=this._transport.getRenderingIntent(M,C,Y);ue(this,n,!1),te(this,a,St).call(this),$||($=this._transport.getOptionalContentConfig());let B=this._intentStates.get(se.cacheKey);B||(B=Object.create(null),this._intentStates.set(se.cacheKey,B)),B.streamReaderCancelTimeout&&(clearTimeout(B.streamReaderCancelTimeout),B.streamReaderCancelTimeout=null);const V=!!(se.renderingIntent&_util.RenderingIntentFlag.PRINT);B.displayReadyCapability||(B.displayReadyCapability=new _util.PromiseCapability,B.operatorList={fnArray:[],argsArray:[],lastChunk:!1,separateAnnots:null},(I=this._stats)==null||I.time("Page Request"),this._pumpOperatorList(se));const Q=z=>{var G,H;B.renderTasks.delete(N),(this._maybeCleanupAfterRender||V)&&ue(this,n,!0),te(this,a,lt).call(this,!V),z?(N.capability.reject(z),this._abortOperatorList({intentState:B,reason:z instanceof Error?z:new Error(z)})):N.capability.resolve(),(G=this._stats)==null||G.timeEnd("Rendering"),(H=this._stats)==null||H.timeEnd("Overall")},N=new InternalRenderTask({callback:Q,params:{canvasContext:D,viewport:T,transform:k,background:O},objs:this.objs,commonObjs:this.commonObjs,annotationCanvasMap:K,operatorList:B.operatorList,pageIndex:this._pageIndex,canvasFactory:this._transport.canvasFactory,filterFactory:this._transport.filterFactory,useRequestAnimationFrame:!V,pdfBug:this._pdfBug,pageColors:J});(B.renderTasks||(B.renderTasks=new Set)).add(N);const P=N.task;return Promise.all([B.displayReadyCapability.promise,$]).then(([z,G])=>{var H;if(this.destroyed){Q();return}(H=this._stats)==null||H.time("Rendering"),N.initializeGraphics({transparency:z,optionalContentConfig:G}),N.operatorListChanged()}).catch(Q),P}getOperatorList({intent:D="display",annotationMode:T=_util.AnnotationMode.ENABLE,printAnnotationStorage:M=null}={}){var K;function C(){O.operatorList.lastChunk&&(O.opListReadCapability.resolve(O.operatorList),O.renderTasks.delete($))}const k=this._transport.getRenderingIntent(D,T,M,!0);let O=this._intentStates.get(k.cacheKey);O||(O=Object.create(null),this._intentStates.set(k.cacheKey,O));let $;return O.opListReadCapability||($=Object.create(null),$.operatorListChanged=C,O.opListReadCapability=new _util.PromiseCapability,(O.renderTasks||(O.renderTasks=new Set)).add($),O.operatorList={fnArray:[],argsArray:[],lastChunk:!1,separateAnnots:null},(K=this._stats)==null||K.time("Page Request"),this._pumpOperatorList(k)),O.opListReadCapability.promise}streamTextContent({includeMarkedContent:D=!1,disableNormalization:T=!1}={}){return this._transport.messageHandler.sendWithStream("GetTextContent",{pageIndex:this._pageIndex,includeMarkedContent:D===!0,disableNormalization:T===!0},{highWaterMark:100,size(C){return C.items.length}})}getTextContent(D={}){if(this._transport._htmlForXfa)return this.getXfa().then(M=>_xfa_text.XfaText.textContent(M));const T=this.streamTextContent(D);return new Promise(function(M,C){function k(){O.read().then(function({value:K,done:J}){if(J){M($);return}Object.assign($.styles,K.styles),$.items.push(...K.items),k()},C)}const O=T.getReader(),$={items:[],styles:Object.create(null)};k()})}getStructTree(){return this._transport.getStructTree(this._pageIndex)}_destroy(){this.destroyed=!0;const D=[];for(const T of this._intentStates.values())if(this._abortOperatorList({intentState:T,reason:new Error("Page was destroyed."),force:!0}),!T.opListReadCapability)for(const M of T.renderTasks)D.push(M.completed),M.cancel();return this.objs.clear(),ue(this,n,!1),te(this,a,St).call(this),Promise.all(D)}cleanup(D=!1){ue(this,n,!0);const T=te(this,a,lt).call(this,!1);return D&&T&&this._stats&&(this._stats=new _display_utils.StatTimer),T}_startRenderPage(D,T){var C,k;const M=this._intentStates.get(T);M&&((C=this._stats)==null||C.timeEnd("Page Request"),(k=M.displayReadyCapability)==null||k.resolve(D))}_renderPageChunk(D,T){for(let M=0,C=D.length;M<C;M++)T.operatorList.fnArray.push(D.fnArray[M]),T.operatorList.argsArray.push(D.argsArray[M]);T.operatorList.lastChunk=D.lastChunk,T.operatorList.separateAnnots=D.separateAnnots;for(const M of T.renderTasks)M.operatorListChanged();D.lastChunk&&te(this,a,lt).call(this,!0)}_pumpOperatorList({renderingIntent:D,cacheKey:T,annotationStorageSerializable:M}){const{map:C,transfers:k}=M,$=this._transport.messageHandler.sendWithStream("GetOperatorList",{pageIndex:this._pageIndex,intent:D,cacheKey:T,annotationStorage:C},k).getReader(),K=this._intentStates.get(T);K.streamReader=$;const J=()=>{$.read().then(({value:Y,done:se})=>{if(se){K.streamReader=null;return}this._transport.destroyed||(this._renderPageChunk(Y,K),J())},Y=>{if(K.streamReader=null,!this._transport.destroyed){if(K.operatorList){K.operatorList.lastChunk=!0;for(const se of K.renderTasks)se.operatorListChanged();te(this,a,lt).call(this,!0)}if(K.displayReadyCapability)K.displayReadyCapability.reject(Y);else if(K.opListReadCapability)K.opListReadCapability.reject(Y);else throw Y}})};J()}_abortOperatorList({intentState:D,reason:T,force:M=!1}){if(D.streamReader){if(D.streamReaderCancelTimeout&&(clearTimeout(D.streamReaderCancelTimeout),D.streamReaderCancelTimeout=null),!M){if(D.renderTasks.size>0)return;if(T instanceof _display_utils.RenderingCancelledException){let C=RENDERING_CANCELLED_TIMEOUT;T.extraDelay>0&&T.extraDelay<1e3&&(C+=T.extraDelay),D.streamReaderCancelTimeout=setTimeout(()=>{D.streamReaderCancelTimeout=null,this._abortOperatorList({intentState:D,reason:T,force:!0})},C);return}}if(D.streamReader.cancel(new _util.AbortException(T.message)).catch(()=>{}),D.streamReader=null,!this._transport.destroyed){for(const[C,k]of this._intentStates)if(k===D){this._intentStates.delete(C);break}this.cleanup()}}}get stats(){return this._stats}}r=new WeakMap,n=new WeakMap,a=new WeakSet,lt=function(D=!1){if(te(this,a,St).call(this),!b(this,n)||this.destroyed)return!1;if(D)return ue(this,r,setTimeout(()=>{ue(this,r,null),te(this,a,lt).call(this,!1)},DELAYED_CLEANUP_TIMEOUT)),!1;for(const{renderTasks:T,operatorList:M}of this._intentStates.values())if(T.size>0||!M.lastChunk)return!1;return this._intentStates.clear(),this.objs.clear(),ue(this,n,!1),!0},St=function(){b(this,r)&&(clearTimeout(b(this,r)),ue(this,r,null))},exports$1.PDFPageProxy=PDFPageProxy;class LoopbackPort{constructor(){de(this,h,new Set);de(this,d,Promise.resolve())}postMessage(D,T){const M={data:structuredClone(D,T?{transfer:T}:null)};b(this,d).then(()=>{for(const C of b(this,h))C.call(this,M)})}addEventListener(D,T){b(this,h).add(T)}removeEventListener(D,T){b(this,h).delete(T)}terminate(){b(this,h).clear()}}h=new WeakMap,d=new WeakMap,exports$1.LoopbackPort=LoopbackPort;const PDFWorkerUtil={isWorkerDisabled:!1,fallbackWorkerSrc:null,fakeWorkerId:0};exports$1.PDFWorkerUtil=PDFWorkerUtil;{if(_util.isNodeJS&&typeof commonjsRequire=="function")PDFWorkerUtil.isWorkerDisabled=!0,PDFWorkerUtil.fallbackWorkerSrc="./pdf.worker.js";else if(typeof document=="object"){const A=(l=document==null?void 0:document.currentScript)==null?void 0:l.src;A&&(PDFWorkerUtil.fallbackWorkerSrc=A.replace(/(\.(?:min\.)?js)(\?.*)?$/i,".worker$1$2"))}PDFWorkerUtil.isSameOrigin=function(A,D){let T;try{if(T=new URL(A),!T.origin||T.origin==="null")return!1}catch{return!1}const M=new URL(D,T);return T.origin===M.origin},PDFWorkerUtil.createCDNWrapper=function(A){const D=`importScripts("${A}");`;return URL.createObjectURL(new Blob([D]))}}const _PDFWorker=class _PDFWorker{constructor({name:A=null,port:D=null,verbosity:T=(0,_util.getVerbosityLevel)()}={}){var M;if(this.name=A,this.destroyed=!1,this.verbosity=T,this._readyCapability=new _util.PromiseCapability,this._port=null,this._webWorker=null,this._messageHandler=null,D){if((M=b(_PDFWorker,u))!=null&&M.has(D))throw new Error("Cannot use more than one PDFWorker per port.");(b(_PDFWorker,u)||ue(_PDFWorker,u,new WeakMap)).set(D,this),this._initializeFromPort(D);return}this._initialize()}get promise(){return this._readyCapability.promise}get port(){return this._port}get messageHandler(){return this._messageHandler}_initializeFromPort(A){this._port=A,this._messageHandler=new _message_handler.MessageHandler("main","worker",A),this._messageHandler.on("ready",function(){}),this._readyCapability.resolve(),this._messageHandler.send("configure",{verbosity:this.verbosity})}_initialize(){if(!PDFWorkerUtil.isWorkerDisabled&&!_PDFWorker._mainThreadWorkerMessageHandler){let{workerSrc:A}=_PDFWorker;try{PDFWorkerUtil.isSameOrigin(window.location.href,A)||(A=PDFWorkerUtil.createCDNWrapper(new URL(A,window.location).href));const D=new Worker(A),T=new _message_handler.MessageHandler("main","worker",D),M=()=>{D.removeEventListener("error",C),T.destroy(),D.terminate(),this.destroyed?this._readyCapability.reject(new Error("Worker was destroyed")):this._setupFakeWorker()},C=()=>{this._webWorker||M()};D.addEventListener("error",C),T.on("test",O=>{if(D.removeEventListener("error",C),this.destroyed){M();return}O?(this._messageHandler=T,this._port=D,this._webWorker=D,this._readyCapability.resolve(),T.send("configure",{verbosity:this.verbosity})):(this._setupFakeWorker(),T.destroy(),D.terminate())}),T.on("ready",O=>{if(D.removeEventListener("error",C),this.destroyed){M();return}try{k()}catch{this._setupFakeWorker()}});const k=()=>{const O=new Uint8Array;T.send("test",O,[O.buffer])};k();return}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(A=>{if(this.destroyed){this._readyCapability.reject(new Error("Worker was destroyed"));return}const D=new LoopbackPort;this._port=D;const T=`fake${PDFWorkerUtil.fakeWorkerId++}`,M=new _message_handler.MessageHandler(T+"_worker",T,D);A.setup(M,D);const C=new _message_handler.MessageHandler(T,T+"_worker",D);this._messageHandler=C,this._readyCapability.resolve(),C.send("configure",{verbosity:this.verbosity})}).catch(A=>{this._readyCapability.reject(new Error(`Setting up fake worker failed: "${A.message}".`))})}destroy(){var A;this.destroyed=!0,this._webWorker&&(this._webWorker.terminate(),this._webWorker=null),(A=b(_PDFWorker,u))==null||A.delete(this._port),this._port=null,this._messageHandler&&(this._messageHandler.destroy(),this._messageHandler=null)}static fromPort(A){var T;if(!(A!=null&&A.port))throw new Error("PDFWorker.fromPort - invalid method signature.");const D=(T=b(this,u))==null?void 0:T.get(A.port);if(D){if(D._pendingDestroy)throw new Error("PDFWorker.fromPort - the worker is being destroyed.\nPlease remember to await `PDFDocumentLoadingTask.destroy()`-calls.");return D}return new _PDFWorker(A)}static get workerSrc(){if(_worker_options.GlobalWorkerOptions.workerSrc)return _worker_options.GlobalWorkerOptions.workerSrc;if(PDFWorkerUtil.fallbackWorkerSrc!==null)return _util.isNodeJS||(0,_display_utils.deprecated)('No "GlobalWorkerOptions.workerSrc" specified.'),PDFWorkerUtil.fallbackWorkerSrc;throw new Error('No "GlobalWorkerOptions.workerSrc" specified.')}static get _mainThreadWorkerMessageHandler(){var A;try{return((A=globalThis.pdfjsWorker)==null?void 0:A.WorkerMessageHandler)||null}catch{return null}}static get _setupFakeWorkerGlobal(){const loader=async()=>{const mainWorkerMessageHandler=this._mainThreadWorkerMessageHandler;if(mainWorkerMessageHandler)return mainWorkerMessageHandler;if(_util.isNodeJS&&typeof commonjsRequire=="function"){const worker=eval("require")(this.workerSrc);return worker.WorkerMessageHandler}return await(0,_display_utils.loadScript)(this.workerSrc),window.pdfjsWorker.WorkerMessageHandler};return(0,_util.shadow)(this,"_setupFakeWorkerGlobal",loader())}};u=new WeakMap,de(_PDFWorker,u);let PDFWorker=_PDFWorker;exports$1.PDFWorker=PDFWorker;class WorkerTransport{constructor(D,T,M,C,k){de(this,y);de(this,p,new Map);de(this,g,new Map);de(this,f,new Map);de(this,v,null);this.messageHandler=D,this.loadingTask=T,this.commonObjs=new PDFObjects,this.fontLoader=new _font_loader.FontLoader({ownerDocument:C.ownerDocument,styleElement:C.styleElement}),this._params=C,this.canvasFactory=k.canvasFactory,this.filterFactory=k.filterFactory,this.cMapReaderFactory=k.cMapReaderFactory,this.standardFontDataFactory=k.standardFontDataFactory,this.destroyed=!1,this.destroyCapability=null,this._networkStream=M,this._fullReader=null,this._lastProgress=null,this.downloadInfoCapability=new _util.PromiseCapability,this.setupMessageHandler()}get annotationStorage(){return(0,_util.shadow)(this,"annotationStorage",new _annotation_storage.AnnotationStorage)}getRenderingIntent(D,T=_util.AnnotationMode.ENABLE,M=null,C=!1){let k=_util.RenderingIntentFlag.DISPLAY,O=_annotation_storage.SerializableEmpty;switch(D){case"any":k=_util.RenderingIntentFlag.ANY;break;case"display":break;case"print":k=_util.RenderingIntentFlag.PRINT;break;default:(0,_util.warn)(`getRenderingIntent - invalid intent: ${D}`)}switch(T){case _util.AnnotationMode.DISABLE:k+=_util.RenderingIntentFlag.ANNOTATIONS_DISABLE;break;case _util.AnnotationMode.ENABLE:break;case _util.AnnotationMode.ENABLE_FORMS:k+=_util.RenderingIntentFlag.ANNOTATIONS_FORMS;break;case _util.AnnotationMode.ENABLE_STORAGE:k+=_util.RenderingIntentFlag.ANNOTATIONS_STORAGE,O=(k&_util.RenderingIntentFlag.PRINT&&M instanceof _annotation_storage.PrintAnnotationStorage?M:this.annotationStorage).serializable;break;default:(0,_util.warn)(`getRenderingIntent - invalid annotationMode: ${T}`)}return C&&(k+=_util.RenderingIntentFlag.OPLIST),{renderingIntent:k,cacheKey:`${k}_${O.hash}`,annotationStorageSerializable:O}}destroy(){var M;if(this.destroyCapability)return this.destroyCapability.promise;this.destroyed=!0,this.destroyCapability=new _util.PromiseCapability,(M=b(this,v))==null||M.reject(new Error("Worker was destroyed during onPassword callback"));const D=[];for(const C of b(this,g).values())D.push(C._destroy());b(this,g).clear(),b(this,f).clear(),this.hasOwnProperty("annotationStorage")&&this.annotationStorage.resetModified();const T=this.messageHandler.sendWithPromise("Terminate",null);return D.push(T),Promise.all(D).then(()=>{var C;this.commonObjs.clear(),this.fontLoader.clear(),b(this,p).clear(),this.filterFactory.destroy(),(C=this._networkStream)==null||C.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:D,loadingTask:T}=this;D.on("GetReader",(M,C)=>{(0,_util.assert)(this._networkStream,"GetReader - no `IPDFStream` instance available."),this._fullReader=this._networkStream.getFullReader(),this._fullReader.onProgress=k=>{this._lastProgress={loaded:k.loaded,total:k.total}},C.onPull=()=>{this._fullReader.read().then(function({value:k,done:O}){if(O){C.close();return}(0,_util.assert)(k instanceof ArrayBuffer,"GetReader - expected an ArrayBuffer."),C.enqueue(new Uint8Array(k),1,[k])}).catch(k=>{C.error(k)})},C.onCancel=k=>{this._fullReader.cancel(k),C.ready.catch(O=>{if(!this.destroyed)throw O})}}),D.on("ReaderHeadersReady",M=>{const C=new _util.PromiseCapability,k=this._fullReader;return k.headersReady.then(()=>{var O;(!k.isStreamingSupported||!k.isRangeSupported)&&(this._lastProgress&&((O=T.onProgress)==null||O.call(T,this._lastProgress)),k.onProgress=$=>{var K;(K=T.onProgress)==null||K.call(T,{loaded:$.loaded,total:$.total})}),C.resolve({isStreamingSupported:k.isStreamingSupported,isRangeSupported:k.isRangeSupported,contentLength:k.contentLength})},C.reject),C.promise}),D.on("GetRangeReader",(M,C)=>{(0,_util.assert)(this._networkStream,"GetRangeReader - no `IPDFStream` instance available.");const k=this._networkStream.getRangeReader(M.begin,M.end);if(!k){C.close();return}C.onPull=()=>{k.read().then(function({value:O,done:$}){if($){C.close();return}(0,_util.assert)(O instanceof ArrayBuffer,"GetRangeReader - expected an ArrayBuffer."),C.enqueue(new Uint8Array(O),1,[O])}).catch(O=>{C.error(O)})},C.onCancel=O=>{k.cancel(O),C.ready.catch($=>{if(!this.destroyed)throw $})}}),D.on("GetDoc",({pdfInfo:M})=>{this._numPages=M.numPages,this._htmlForXfa=M.htmlForXfa,delete M.htmlForXfa,T._capability.resolve(new PDFDocumentProxy(M,this))}),D.on("DocException",function(M){let C;switch(M.name){case"PasswordException":C=new _util.PasswordException(M.message,M.code);break;case"InvalidPDFException":C=new _util.InvalidPDFException(M.message);break;case"MissingPDFException":C=new _util.MissingPDFException(M.message);break;case"UnexpectedResponseException":C=new _util.UnexpectedResponseException(M.message,M.status);break;case"UnknownErrorException":C=new _util.UnknownErrorException(M.message,M.details);break;default:(0,_util.unreachable)("DocException - expected a valid Error.")}T._capability.reject(C)}),D.on("PasswordRequest",M=>{if(ue(this,v,new _util.PromiseCapability),T.onPassword){const C=k=>{k instanceof Error?b(this,v).reject(k):b(this,v).resolve({password:k})};try{T.onPassword(C,M.code)}catch(k){b(this,v).reject(k)}}else b(this,v).reject(new _util.PasswordException(M.message,M.code));return b(this,v).promise}),D.on("DataLoaded",M=>{var C;(C=T.onProgress)==null||C.call(T,{loaded:M.length,total:M.length}),this.downloadInfoCapability.resolve(M)}),D.on("StartRenderPage",M=>{if(this.destroyed)return;b(this,g).get(M.pageIndex)._startRenderPage(M.transparency,M.cacheKey)}),D.on("commonobj",([M,C,k])=>{var O;if(!this.destroyed&&!this.commonObjs.has(M))switch(C){case"Font":const $=this._params;if("error"in k){const Y=k.error;(0,_util.warn)(`Error during font loading: ${Y}`),this.commonObjs.resolve(M,Y);break}const K=$.pdfBug&&((O=globalThis.FontInspector)!=null&&O.enabled)?(Y,se)=>globalThis.FontInspector.fontAdded(Y,se):null,J=new _font_loader.FontFaceObject(k,{isEvalSupported:$.isEvalSupported,disableFontFace:$.disableFontFace,ignoreErrors:$.ignoreErrors,inspectFont:K});this.fontLoader.bind(J).catch(Y=>D.sendWithPromise("FontFallback",{id:M})).finally(()=>{!$.fontExtraProperties&&J.data&&(J.data=null),this.commonObjs.resolve(M,J)});break;case"FontPath":case"Image":case"Pattern":this.commonObjs.resolve(M,k);break;default:throw new Error(`Got unknown common object type ${C}`)}}),D.on("obj",([M,C,k,O])=>{var K;if(this.destroyed)return;const $=b(this,g).get(C);if(!$.objs.has(M))switch(k){case"Image":if($.objs.resolve(M,O),O){let J;if(O.bitmap){const{width:Y,height:se}=O;J=Y*se*4}else J=((K=O.data)==null?void 0:K.length)||0;J>_util.MAX_IMAGE_SIZE_TO_CACHE&&($._maybeCleanupAfterRender=!0)}break;case"Pattern":$.objs.resolve(M,O);break;default:throw new Error(`Got unknown object type ${k}`)}}),D.on("DocProgress",M=>{var C;this.destroyed||(C=T.onProgress)==null||C.call(T,{loaded:M.loaded,total:M.total})}),D.on("FetchBuiltInCMap",M=>this.destroyed?Promise.reject(new Error("Worker was destroyed.")):this.cMapReaderFactory?this.cMapReaderFactory.fetch(M):Promise.reject(new Error("CMapReaderFactory not initialized, see the `useWorkerFetch` parameter."))),D.on("FetchStandardFontData",M=>this.destroyed?Promise.reject(new Error("Worker was destroyed.")):this.standardFontDataFactory?this.standardFontDataFactory.fetch(M):Promise.reject(new Error("StandardFontDataFactory not initialized, see the `useWorkerFetch` parameter.")))}getData(){return this.messageHandler.sendWithPromise("GetData",null)}saveDocument(){var M;this.annotationStorage.size<=0&&(0,_util.warn)("saveDocument called while `annotationStorage` is empty, please use the getData-method instead.");const{map:D,transfers:T}=this.annotationStorage.serializable;return this.messageHandler.sendWithPromise("SaveDocument",{isPureXfa:!!this._htmlForXfa,numPages:this._numPages,annotationStorage:D,filename:((M=this._fullReader)==null?void 0:M.filename)??null},T).finally(()=>{this.annotationStorage.resetModified()})}getPage(D){if(!Number.isInteger(D)||D<=0||D>this._numPages)return Promise.reject(new Error("Invalid page request."));const T=D-1,M=b(this,f).get(T);if(M)return M;const C=this.messageHandler.sendWithPromise("GetPage",{pageIndex:T}).then(k=>{if(this.destroyed)throw new Error("Transport destroyed");const O=new PDFPageProxy(T,k,this,this._params.pdfBug);return b(this,g).set(T,O),O});return b(this,f).set(T,C),C}getPageIndex(D){return typeof D!="object"||D===null||!Number.isInteger(D.num)||D.num<0||!Number.isInteger(D.gen)||D.gen<0?Promise.reject(new Error("Invalid pageIndex request.")):this.messageHandler.sendWithPromise("GetPageIndex",{num:D.num,gen:D.gen})}getAnnotations(D,T){return this.messageHandler.sendWithPromise("GetAnnotations",{pageIndex:D,intent:T})}getFieldObjects(){return te(this,y,At).call(this,"GetFieldObjects")}hasJSActions(){return te(this,y,At).call(this,"HasJSActions")}getCalculationOrderIds(){return this.messageHandler.sendWithPromise("GetCalculationOrderIds",null)}getDestinations(){return this.messageHandler.sendWithPromise("GetDestinations",null)}getDestination(D){return typeof D!="string"?Promise.reject(new Error("Invalid destination request.")):this.messageHandler.sendWithPromise("GetDestination",{id:D})}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)}getDocJSActions(){return te(this,y,At).call(this,"GetDocJSActions")}getPageJSActions(D){return this.messageHandler.sendWithPromise("GetPageJSActions",{pageIndex:D})}getStructTree(D){return this.messageHandler.sendWithPromise("GetStructTree",{pageIndex:D})}getOutline(){return this.messageHandler.sendWithPromise("GetOutline",null)}getOptionalContentConfig(){return this.messageHandler.sendWithPromise("GetOptionalContentConfig",null).then(D=>new _optional_content_config.OptionalContentConfig(D))}getPermissions(){return this.messageHandler.sendWithPromise("GetPermissions",null)}getMetadata(){const D="GetMetadata",T=b(this,p).get(D);if(T)return T;const M=this.messageHandler.sendWithPromise(D,null).then(C=>{var k,O;return{info:C[0],metadata:C[1]?new _metadata.Metadata(C[1]):null,contentDispositionFilename:((k=this._fullReader)==null?void 0:k.filename)??null,contentLength:((O=this._fullReader)==null?void 0:O.contentLength)??null}});return b(this,p).set(D,M),M}getMarkInfo(){return this.messageHandler.sendWithPromise("GetMarkInfo",null)}async startCleanup(D=!1){if(!this.destroyed){await this.messageHandler.sendWithPromise("Cleanup",null);for(const T of b(this,g).values())if(!T.cleanup())throw new Error(`startCleanup: Page ${T.pageNumber} is currently rendering.`);this.commonObjs.clear(),D||this.fontLoader.clear(),b(this,p).clear(),this.filterFactory.destroy(!0)}}get loadingParams(){const{disableAutoFetch:D,enableXfa:T}=this._params;return(0,_util.shadow)(this,"loadingParams",{disableAutoFetch:D,enableXfa:T})}}p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakSet,At=function(D,T=null){const M=b(this,p).get(D);if(M)return M;const C=this.messageHandler.sendWithPromise(D,T);return b(this,p).set(D,C),C};class PDFObjects{constructor(){de(this,w);de(this,m,Object.create(null))}get(D,T=null){if(T){const C=te(this,w,Mt).call(this,D);return C.capability.promise.then(()=>T(C.data)),null}const M=b(this,m)[D];if(!(M!=null&&M.capability.settled))throw new Error(`Requesting object that isn't resolved yet ${D}.`);return M.data}has(D){const T=b(this,m)[D];return(T==null?void 0:T.capability.settled)||!1}resolve(D,T=null){const M=te(this,w,Mt).call(this,D);M.data=T,M.capability.resolve()}clear(){var D;for(const T in b(this,m)){const{data:M}=b(this,m)[T];(D=M==null?void 0:M.bitmap)==null||D.close()}ue(this,m,Object.create(null))}}m=new WeakMap,w=new WeakSet,Mt=function(D){var T;return(T=b(this,m))[D]||(T[D]={capability:new _util.PromiseCapability,data:null})};class RenderTask{constructor(D){de(this,_,null);ue(this,_,D),this.onContinue=null}get promise(){return b(this,_).capability.promise}cancel(D=0){b(this,_).cancel(null,D)}get separateAnnots(){const{separateAnnots:D}=b(this,_).operatorList;if(!D)return!1;const{annotationCanvasMap:T}=b(this,_);return D.form||D.canvas&&(T==null?void 0:T.size)>0}}_=new WeakMap,exports$1.RenderTask=RenderTask;const F=class F{constructor({callback:D,params:T,objs:M,commonObjs:C,annotationCanvasMap:k,operatorList:O,pageIndex:$,canvasFactory:K,filterFactory:J,useRequestAnimationFrame:Y=!1,pdfBug:se=!1,pageColors:B=null}){this.callback=D,this.params=T,this.objs=M,this.commonObjs=C,this.annotationCanvasMap=k,this.operatorListIdx=null,this.operatorList=O,this._pageIndex=$,this.canvasFactory=K,this.filterFactory=J,this._pdfBug=se,this.pageColors=B,this.running=!1,this.graphicsReadyCallback=null,this.graphicsReady=!1,this._useRequestAnimationFrame=Y===!0&&typeof window<"u",this.cancelled=!1,this.capability=new _util.PromiseCapability,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=T.canvasContext.canvas}get completed(){return this.capability.promise.catch(function(){})}initializeGraphics({transparency:D=!1,optionalContentConfig:T}){var $,K;if(this.cancelled)return;if(this._canvas){if(b(F,S).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.");b(F,S).add(this._canvas)}this._pdfBug&&(($=globalThis.StepperManager)!=null&&$.enabled)&&(this.stepper=globalThis.StepperManager.create(this._pageIndex),this.stepper.init(this.operatorList),this.stepper.nextBreakPoint=this.stepper.getNextBreakPoint());const{canvasContext:M,viewport:C,transform:k,background:O}=this.params;this.gfx=new _canvas.CanvasGraphics(M,this.commonObjs,this.objs,this.canvasFactory,this.filterFactory,{optionalContentConfig:T},this.annotationCanvasMap,this.pageColors),this.gfx.beginDrawing({transform:k,viewport:C,transparency:D,background:O}),this.operatorListIdx=0,this.graphicsReady=!0,(K=this.graphicsReadyCallback)==null||K.call(this)}cancel(D=null,T=0){var M;this.running=!1,this.cancelled=!0,(M=this.gfx)==null||M.endDrawing(),b(F,S).delete(this._canvas),this.callback(D||new _display_utils.RenderingCancelledException(`Rendering cancelled, page ${this._pageIndex+1}`,T))}operatorListChanged(){var D;if(!this.graphicsReady){this.graphicsReadyCallback||(this.graphicsReadyCallback=this._continueBound);return}(D=this.stepper)==null||D.updateOperatorList(this.operatorList),!this.running&&this._continue()}_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)}async _next(){this.cancelled||(this.operatorListIdx=this.gfx.executeOperatorList(this.operatorList,this.operatorListIdx,this._continueBound,this.stepper),this.operatorListIdx===this.operatorList.argsArray.length&&(this.running=!1,this.operatorList.lastChunk&&(this.gfx.endDrawing(),b(F,S).delete(this._canvas),this.callback())))}};S=new WeakMap,de(F,S,new WeakSet);let InternalRenderTask=F;const version="3.11.174";exports$1.version=version;const build="ce8716743";exports$1.build=build},(t,e,r)=>{var l,u,p,yr,f;Object.defineProperty(e,"__esModule",{value:!0}),e.SerializableEmpty=e.PrintAnnotationStorage=e.AnnotationStorage=void 0;var n=r(1),a=r(4),s=r(8);const o=Object.freeze({map:null,hash:"",transfers:void 0});e.SerializableEmpty=o;class h{constructor(){de(this,p);de(this,l,!1);de(this,u,new Map);this.onSetModified=null,this.onResetModified=null,this.onAnnotationEditor=null}getValue(y,x){const m=b(this,u).get(y);return m===void 0?x:Object.assign(x,m)}getRawValue(y){return b(this,u).get(y)}remove(y){if(b(this,u).delete(y),b(this,u).size===0&&this.resetModified(),typeof this.onAnnotationEditor=="function"){for(const x of b(this,u).values())if(x instanceof a.AnnotationEditor)return;this.onAnnotationEditor(null)}}setValue(y,x){const m=b(this,u).get(y);let w=!1;if(m!==void 0)for(const[R,_]of Object.entries(x))m[R]!==_&&(w=!0,m[R]=_);else w=!0,b(this,u).set(y,x);w&&te(this,p,yr).call(this),x instanceof a.AnnotationEditor&&typeof this.onAnnotationEditor=="function"&&this.onAnnotationEditor(x.constructor._type)}has(y){return b(this,u).has(y)}getAll(){return b(this,u).size>0?(0,n.objectFromMap)(b(this,u)):null}setAll(y){for(const[x,m]of Object.entries(y))this.setValue(x,m)}get size(){return b(this,u).size}resetModified(){b(this,l)&&(ue(this,l,!1),typeof this.onResetModified=="function"&&this.onResetModified())}get print(){return new d(this)}get serializable(){if(b(this,u).size===0)return o;const y=new Map,x=new s.MurmurHash3_64,m=[],w=Object.create(null);let R=!1;for(const[_,S]of b(this,u)){const F=S instanceof a.AnnotationEditor?S.serialize(!1,w):S;F&&(y.set(_,F),x.update(`${_}:${JSON.stringify(F)}`),R||(R=!!F.bitmap))}if(R)for(const _ of y.values())_.bitmap&&m.push(_.bitmap);return y.size>0?{map:y,hash:x.hexdigest(),transfers:m}:o}}l=new WeakMap,u=new WeakMap,p=new WeakSet,yr=function(){b(this,l)||(ue(this,l,!0),typeof this.onSetModified=="function"&&this.onSetModified())},e.AnnotationStorage=h;class d extends h{constructor(x){super();de(this,f);const{map:m,hash:w,transfers:R}=x.serializable,_=structuredClone(m,R?{transfer:R}:null);ue(this,f,{map:_,hash:w,transfers:R})}get print(){(0,n.unreachable)("Should not call PrintAnnotationStorage.print")}get serializable(){return b(this,f)}}f=new WeakMap,e.PrintAnnotationStorage=d},(t,e,r)=>{var d,l,u,p,g,f,v,y,x,m,w,R,_,S,F,Lt,Bt,T,jt,Ut,br,xr,Sr,zt,Ar;Object.defineProperty(e,"__esModule",{value:!0}),e.AnnotationEditor=void 0;var n=r(5),a=r(1),s=r(6);const Y=class Y{constructor(B){de(this,F);de(this,d,"");de(this,l,!1);de(this,u,null);de(this,p,null);de(this,g,null);de(this,f,!1);de(this,v,null);de(this,y,this.focusin.bind(this));de(this,x,this.focusout.bind(this));de(this,m,!1);de(this,w,!1);de(this,R,!1);$e(this,"_initialOptions",Object.create(null));$e(this,"_uiManager",null);$e(this,"_focusEventsAllowed",!0);$e(this,"_l10nPromise",null);de(this,_,!1);de(this,S,Y._zIndex++);this.constructor===Y&&(0,a.unreachable)("Cannot initialize AnnotationEditor."),this.parent=B.parent,this.id=B.id,this.width=this.height=null,this.pageIndex=B.parent.pageIndex,this.name=B.name,this.div=null,this._uiManager=B.uiManager,this.annotationElementId=null,this._willKeepAspectRatio=!1,this._initialOptions.isCentered=B.isCentered,this._structTreeParentId=null;const{rotation:V,rawDims:{pageWidth:Q,pageHeight:N,pageX:P,pageY:E}}=this.parent.viewport;this.rotation=V,this.pageRotation=(360+V-this._uiManager.viewParameters.rotation)%360,this.pageDimensions=[Q,N],this.pageTranslation=[P,E];const[I,z]=this.parentDimensions;this.x=B.x/I,this.y=B.y/z,this.isAttachedToDOM=!1,this.deleted=!1}get editorType(){return Object.getPrototypeOf(this).constructor._type}static get _defaultLineColor(){return(0,a.shadow)(this,"_defaultLineColor",this._colorManager.getHexCode("CanvasText"))}static deleteAnnotationElement(B){const V=new h({id:B.parent.getNextId(),parent:B.parent,uiManager:B._uiManager});V.annotationElementId=B.annotationElementId,V.deleted=!0,V._uiManager.addToAnnotationStorage(V)}static initialize(B,V=null){if(Y._l10nPromise||(Y._l10nPromise=new Map(["editor_alt_text_button_label","editor_alt_text_edit_button_label","editor_alt_text_decorative_tooltip"].map(N=>[N,B.get(N)]))),V!=null&&V.strings)for(const N of V.strings)Y._l10nPromise.set(N,B.get(N));if(Y._borderLineWidth!==-1)return;const Q=getComputedStyle(document.documentElement);Y._borderLineWidth=parseFloat(Q.getPropertyValue("--outline-width"))||0}static updateDefaultParams(B,V){}static get defaultPropertiesToUpdate(){return[]}static isHandlingMimeForPasting(B){return!1}static paste(B,V){(0,a.unreachable)("Not implemented")}get propertiesToUpdate(){return[]}get _isDraggable(){return b(this,_)}set _isDraggable(B){var V;ue(this,_,B),(V=this.div)==null||V.classList.toggle("draggable",B)}center(){const[B,V]=this.pageDimensions;switch(this.parentRotation){case 90:this.x-=this.height*V/(B*2),this.y+=this.width*B/(V*2);break;case 180:this.x+=this.width/2,this.y+=this.height/2;break;case 270:this.x+=this.height*V/(B*2),this.y-=this.width*B/(V*2);break;default:this.x-=this.width/2,this.y-=this.height/2;break}this.fixAndSetPosition()}addCommands(B){this._uiManager.addCommands(B)}get currentLayer(){return this._uiManager.currentLayer}setInBackground(){this.div.style.zIndex=0}setInForeground(){this.div.style.zIndex=b(this,S)}setParent(B){B!==null&&(this.pageIndex=B.pageIndex,this.pageDimensions=B.pageDimensions),this.parent=B}focusin(B){this._focusEventsAllowed&&(b(this,m)?ue(this,m,!1):this.parent.setSelected(this))}focusout(B){var Q;if(!this._focusEventsAllowed||!this.isAttachedToDOM)return;const V=B.relatedTarget;V!=null&&V.closest(`#${this.id}`)||(B.preventDefault(),(Q=this.parent)!=null&&Q.isMultipleSelection||this.commitOrRemove())}commitOrRemove(){this.isEmpty()?this.remove():this.commit()}commit(){this.addToAnnotationStorage()}addToAnnotationStorage(){this._uiManager.addToAnnotationStorage(this)}setAt(B,V,Q,N){const[P,E]=this.parentDimensions;[Q,N]=this.screenToPageTranslation(Q,N),this.x=(B+Q)/P,this.y=(V+N)/E,this.fixAndSetPosition()}translate(B,V){te(this,F,Lt).call(this,this.parentDimensions,B,V)}translateInPage(B,V){te(this,F,Lt).call(this,this.pageDimensions,B,V),this.div.scrollIntoView({block:"nearest"})}drag(B,V){const[Q,N]=this.parentDimensions;if(this.x+=B/Q,this.y+=V/N,this.parent&&(this.x<0||this.x>1||this.y<0||this.y>1)){const{x:G,y:H}=this.div.getBoundingClientRect();this.parent.findNewParent(this,G,H)&&(this.x-=Math.floor(this.x),this.y-=Math.floor(this.y))}let{x:P,y:E}=this;const[I,z]=te(this,F,Bt).call(this);P+=I,E+=z,this.div.style.left=`${(100*P).toFixed(2)}%`,this.div.style.top=`${(100*E).toFixed(2)}%`,this.div.scrollIntoView({block:"nearest"})}fixAndSetPosition(){const[B,V]=this.pageDimensions;let{x:Q,y:N,width:P,height:E}=this;switch(P*=B,E*=V,Q*=B,N*=V,this.rotation){case 0:Q=Math.max(0,Math.min(B-P,Q)),N=Math.max(0,Math.min(V-E,N));break;case 90:Q=Math.max(0,Math.min(B-E,Q)),N=Math.min(V,Math.max(P,N));break;case 180:Q=Math.min(B,Math.max(P,Q)),N=Math.min(V,Math.max(E,N));break;case 270:Q=Math.min(B,Math.max(E,Q)),N=Math.max(0,Math.min(V-P,N));break}this.x=Q/=B,this.y=N/=V;const[I,z]=te(this,F,Bt).call(this);Q+=I,N+=z;const{style:G}=this.div;G.left=`${(100*Q).toFixed(2)}%`,G.top=`${(100*N).toFixed(2)}%`,this.moveInDOM()}screenToPageTranslation(B,V){var Q;return te(Q=Y,T,jt).call(Q,B,V,this.parentRotation)}pageTranslationToScreen(B,V){var Q;return te(Q=Y,T,jt).call(Q,B,V,360-this.parentRotation)}get parentScale(){return this._uiManager.viewParameters.realScale}get parentRotation(){return(this._uiManager.viewParameters.rotation+this.pageRotation)%360}get parentDimensions(){const{parentScale:B,pageDimensions:[V,Q]}=this,N=V*B,P=Q*B;return a.FeatureTest.isCSSRoundSupported?[Math.round(N),Math.round(P)]:[N,P]}setDims(B,V){var P;const[Q,N]=this.parentDimensions;this.div.style.width=`${(100*B/Q).toFixed(2)}%`,b(this,f)||(this.div.style.height=`${(100*V/N).toFixed(2)}%`),(P=b(this,u))==null||P.classList.toggle("small",B<Y.SMALL_EDITOR_SIZE||V<Y.SMALL_EDITOR_SIZE)}fixDims(){const{style:B}=this.div,{height:V,width:Q}=B,N=Q.endsWith("%"),P=!b(this,f)&&V.endsWith("%");if(N&&P)return;const[E,I]=this.parentDimensions;N||(B.width=`${(100*parseFloat(Q)/E).toFixed(2)}%`),!b(this,f)&&!P&&(B.height=`${(100*parseFloat(V)/I).toFixed(2)}%`)}getInitialTranslation(){return[0,0]}async addAltTextButton(){if(b(this,u))return;const B=ue(this,u,document.createElement("button"));B.className="altText";const V=await Y._l10nPromise.get("editor_alt_text_button_label");B.textContent=V,B.setAttribute("aria-label",V),B.tabIndex="0",B.addEventListener("contextmenu",s.noContextMenu),B.addEventListener("pointerdown",Q=>Q.stopPropagation()),B.addEventListener("click",Q=>{Q.preventDefault(),this._uiManager.editAltText(this)},{capture:!0}),B.addEventListener("keydown",Q=>{Q.target===B&&Q.key==="Enter"&&(Q.preventDefault(),this._uiManager.editAltText(this))}),te(this,F,zt).call(this),this.div.append(B),Y.SMALL_EDITOR_SIZE||(Y.SMALL_EDITOR_SIZE=Math.min(128,Math.round(B.getBoundingClientRect().width*1.4)))}getClientDimensions(){return this.div.getBoundingClientRect()}get altTextData(){return{altText:b(this,d),decorative:b(this,l)}}set altTextData({altText:B,decorative:V}){b(this,d)===B&&b(this,l)===V||(ue(this,d,B),ue(this,l,V),te(this,F,zt).call(this))}render(){this.div=document.createElement("div"),this.div.setAttribute("data-editor-rotation",(360-this.rotation)%360),this.div.className=this.name,this.div.setAttribute("id",this.id),this.div.setAttribute("tabIndex",0),this.setInForeground(),this.div.addEventListener("focusin",b(this,y)),this.div.addEventListener("focusout",b(this,x));const[B,V]=this.parentDimensions;this.parentRotation%180!==0&&(this.div.style.maxWidth=`${(100*V/B).toFixed(2)}%`,this.div.style.maxHeight=`${(100*B/V).toFixed(2)}%`);const[Q,N]=this.getInitialTranslation();return this.translate(Q,N),(0,n.bindEvents)(this,this.div,["pointerdown"]),this.div}pointerdown(B){const{isMac:V}=a.FeatureTest.platform;if(B.button!==0||B.ctrlKey&&V){B.preventDefault();return}ue(this,m,!0),te(this,F,Ar).call(this,B)}moveInDOM(){var B;(B=this.parent)==null||B.moveEditorInDOM(this)}_setParentAndPosition(B,V,Q){B.changeParent(this),this.x=V,this.y=Q,this.fixAndSetPosition()}getRect(B,V){const Q=this.parentScale,[N,P]=this.pageDimensions,[E,I]=this.pageTranslation,z=B/Q,G=V/Q,H=this.x*N,ee=this.y*P,ce=this.width*N,ve=this.height*P;switch(this.rotation){case 0:return[H+z+E,P-ee-G-ve+I,H+z+ce+E,P-ee-G+I];case 90:return[H+G+E,P-ee+z+I,H+G+ve+E,P-ee+z+ce+I];case 180:return[H-z-ce+E,P-ee+G+I,H-z+E,P-ee+G+ve+I];case 270:return[H-G-ve+E,P-ee-z-ce+I,H-G+E,P-ee-z+I];default:throw new Error("Invalid rotation")}}getRectInCurrentCoords(B,V){const[Q,N,P,E]=B,I=P-Q,z=E-N;switch(this.rotation){case 0:return[Q,V-E,I,z];case 90:return[Q,V-N,z,I];case 180:return[P,V-N,I,z];case 270:return[P,V-E,z,I];default:throw new Error("Invalid rotation")}}onceAdded(){}isEmpty(){return!1}enableEditMode(){ue(this,R,!0)}disableEditMode(){ue(this,R,!1)}isInEditMode(){return b(this,R)}shouldGetKeyboardEvents(){return!1}needsToBeRebuilt(){return this.div&&!this.isAttachedToDOM}rebuild(){var B,V;(B=this.div)==null||B.addEventListener("focusin",b(this,y)),(V=this.div)==null||V.addEventListener("focusout",b(this,x))}serialize(B=!1,V=null){(0,a.unreachable)("An editor must be serializable")}static deserialize(B,V,Q){const N=new this.prototype.constructor({parent:V,id:V.getNextId(),uiManager:Q});N.rotation=B.rotation;const[P,E]=N.pageDimensions,[I,z,G,H]=N.getRectInCurrentCoords(B.rect,E);return N.x=I/P,N.y=z/E,N.width=G/P,N.height=H/E,N}remove(){var B;this.div.removeEventListener("focusin",b(this,y)),this.div.removeEventListener("focusout",b(this,x)),this.isEmpty()||this.commit(),this.parent?this.parent.remove(this):this._uiManager.removeEditor(this),(B=b(this,u))==null||B.remove(),ue(this,u,null),ue(this,p,null)}get isResizable(){return!1}makeResizable(){this.isResizable&&(te(this,F,br).call(this),b(this,v).classList.remove("hidden"))}select(){var B;this.makeResizable(),(B=this.div)==null||B.classList.add("selectedEditor")}unselect(){var B,V,Q;(B=b(this,v))==null||B.classList.add("hidden"),(V=this.div)==null||V.classList.remove("selectedEditor"),(Q=this.div)!=null&&Q.contains(document.activeElement)&&this._uiManager.currentLayer.div.focus()}updateParams(B,V){}disableEditing(){b(this,u)&&(b(this,u).hidden=!0)}enableEditing(){b(this,u)&&(b(this,u).hidden=!1)}enterInEditMode(){}get contentDiv(){return this.div}get isEditing(){return b(this,w)}set isEditing(B){ue(this,w,B),this.parent&&(B?(this.parent.setSelected(this),this.parent.setActiveEditor(this)):this.parent.setActiveEditor(null))}setAspectRatio(B,V){ue(this,f,!0);const Q=B/V,{style:N}=this.div;N.aspectRatio=Q,N.height="auto"}static get MIN_SIZE(){return 16}};d=new WeakMap,l=new WeakMap,u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakMap,x=new WeakMap,m=new WeakMap,w=new WeakMap,R=new WeakMap,_=new WeakMap,S=new WeakMap,F=new WeakSet,Lt=function([B,V],Q,N){[Q,N]=this.screenToPageTranslation(Q,N),this.x+=Q/B,this.y+=N/V,this.fixAndSetPosition()},Bt=function(){const[B,V]=this.parentDimensions,{_borderLineWidth:Q}=Y,N=Q/B,P=Q/V;switch(this.rotation){case 90:return[-N,P];case 180:return[N,P];case 270:return[N,-P];default:return[-N,-P]}},T=new WeakSet,jt=function(B,V,Q){switch(Q){case 90:return[V,-B];case 180:return[-B,-V];case 270:return[-V,B];default:return[B,V]}},Ut=function(B){switch(B){case 90:{const[V,Q]=this.pageDimensions;return[0,-V/Q,Q/V,0]}case 180:return[-1,0,0,-1];case 270:{const[V,Q]=this.pageDimensions;return[0,V/Q,-Q/V,0]}default:return[1,0,0,1]}},br=function(){if(b(this,v))return;ue(this,v,document.createElement("div")),b(this,v).classList.add("resizers");const B=["topLeft","topRight","bottomRight","bottomLeft"];this._willKeepAspectRatio||B.push("topMiddle","middleRight","bottomMiddle","middleLeft");for(const V of B){const Q=document.createElement("div");b(this,v).append(Q),Q.classList.add("resizer",V),Q.addEventListener("pointerdown",te(this,F,xr).bind(this,V)),Q.addEventListener("contextmenu",s.noContextMenu)}this.div.prepend(b(this,v))},xr=function(B,V){V.preventDefault();const{isMac:Q}=a.FeatureTest.platform;if(V.button!==0||V.ctrlKey&&Q)return;const N=te(this,F,Sr).bind(this,B),P=this._isDraggable;this._isDraggable=!1;const E={passive:!0,capture:!0};window.addEventListener("pointermove",N,E);const I=this.x,z=this.y,G=this.width,H=this.height,ee=this.parent.div.style.cursor,ce=this.div.style.cursor;this.div.style.cursor=this.parent.div.style.cursor=window.getComputedStyle(V.target).cursor;const ve=()=>{this._isDraggable=P,window.removeEventListener("pointerup",ve),window.removeEventListener("blur",ve),window.removeEventListener("pointermove",N,E),this.parent.div.style.cursor=ee,this.div.style.cursor=ce;const me=this.x,xe=this.y,Se=this.width,Ce=this.height;me===I&&xe===z&&Se===G&&Ce===H||this.addCommands({cmd:()=>{this.width=Se,this.height=Ce,this.x=me,this.y=xe;const[ne,le]=this.parentDimensions;this.setDims(ne*Se,le*Ce),this.fixAndSetPosition()},undo:()=>{this.width=G,this.height=H,this.x=I,this.y=z;const[ne,le]=this.parentDimensions;this.setDims(ne*G,le*H),this.fixAndSetPosition()},mustExec:!0})};window.addEventListener("pointerup",ve),window.addEventListener("blur",ve)},Sr=function(B,V){const[Q,N]=this.parentDimensions,P=this.x,E=this.y,I=this.width,z=this.height,G=Y.MIN_SIZE/Q,H=Y.MIN_SIZE/N,ee=Me=>Math.round(Me*1e4)/1e4,ce=te(this,F,Ut).call(this,this.rotation),ve=(Me,Ee)=>[ce[0]*Me+ce[2]*Ee,ce[1]*Me+ce[3]*Ee],me=te(this,F,Ut).call(this,360-this.rotation),xe=(Me,Ee)=>[me[0]*Me+me[2]*Ee,me[1]*Me+me[3]*Ee];let Se,Ce,ne=!1,le=!1;switch(B){case"topLeft":ne=!0,Se=(Me,Ee)=>[0,0],Ce=(Me,Ee)=>[Me,Ee];break;case"topMiddle":Se=(Me,Ee)=>[Me/2,0],Ce=(Me,Ee)=>[Me/2,Ee];break;case"topRight":ne=!0,Se=(Me,Ee)=>[Me,0],Ce=(Me,Ee)=>[0,Ee];break;case"middleRight":le=!0,Se=(Me,Ee)=>[Me,Ee/2],Ce=(Me,Ee)=>[0,Ee/2];break;case"bottomRight":ne=!0,Se=(Me,Ee)=>[Me,Ee],Ce=(Me,Ee)=>[0,0];break;case"bottomMiddle":Se=(Me,Ee)=>[Me/2,Ee],Ce=(Me,Ee)=>[Me/2,0];break;case"bottomLeft":ne=!0,Se=(Me,Ee)=>[0,Ee],Ce=(Me,Ee)=>[Me,0];break;case"middleLeft":le=!0,Se=(Me,Ee)=>[0,Ee/2],Ce=(Me,Ee)=>[Me,Ee/2];break}const L=Se(I,z),Z=Ce(I,z);let re=ve(...Z);const he=ee(P+re[0]),ye=ee(E+re[1]);let Fe=1,Pe=1,[ie,_e]=this.screenToPageTranslation(V.movementX,V.movementY);if([ie,_e]=xe(ie/Q,_e/N),ne){const Me=Math.hypot(I,z);Fe=Pe=Math.max(Math.min(Math.hypot(Z[0]-L[0]-ie,Z[1]-L[1]-_e)/Me,1/I,1/z),G/I,H/z)}else le?Fe=Math.max(G,Math.min(1,Math.abs(Z[0]-L[0]-ie)))/I:Pe=Math.max(H,Math.min(1,Math.abs(Z[1]-L[1]-_e)))/z;const Te=ee(I*Fe),Ke=ee(z*Pe);re=ve(...Ce(Te,Ke));const qe=he-re[0],Ye=ye-re[1];this.width=Te,this.height=Ke,this.x=qe,this.y=Ye,this.setDims(Q*Te,N*Ke),this.fixAndSetPosition()},zt=async function(){var Q;const B=b(this,u);if(!B)return;if(!b(this,d)&&!b(this,l)){B.classList.remove("done"),(Q=b(this,p))==null||Q.remove();return}Y._l10nPromise.get("editor_alt_text_edit_button_label").then(N=>{B.setAttribute("aria-label",N)});let V=b(this,p);if(!V){ue(this,p,V=document.createElement("span")),V.className="tooltip",V.setAttribute("role","tooltip");const N=V.id=`alt-text-tooltip-${this.id}`;B.setAttribute("aria-describedby",N);const P=100;B.addEventListener("mouseenter",()=>{ue(this,g,setTimeout(()=>{ue(this,g,null),b(this,p).classList.add("show"),this._uiManager._eventBus.dispatch("reporttelemetry",{source:this,details:{type:"editing",subtype:this.editorType,data:{action:"alt_text_tooltip"}}})},P))}),B.addEventListener("mouseleave",()=>{var E;clearTimeout(b(this,g)),ue(this,g,null),(E=b(this,p))==null||E.classList.remove("show")})}B.classList.add("done"),V.innerText=b(this,l)?await Y._l10nPromise.get("editor_alt_text_decorative_tooltip"):b(this,d),V.parentNode||B.append(V)},Ar=function(B){if(!this._isDraggable)return;const V=this._uiManager.isSelected(this);this._uiManager.setUpDragSession();let Q,N;V&&(Q={passive:!0,capture:!0},N=E=>{const[I,z]=this.screenToPageTranslation(E.movementX,E.movementY);this._uiManager.dragSelectedEditors(I,z)},window.addEventListener("pointermove",N,Q));const P=()=>{if(window.removeEventListener("pointerup",P),window.removeEventListener("blur",P),V&&window.removeEventListener("pointermove",N,Q),ue(this,m,!1),!this._uiManager.endDragSession()){const{isMac:E}=a.FeatureTest.platform;B.ctrlKey&&!E||B.shiftKey||B.metaKey&&E?this.parent.toggleSelected(this):this.parent.setSelected(this)}};window.addEventListener("pointerup",P),window.addEventListener("blur",P)},de(Y,T),$e(Y,"_borderLineWidth",-1),$e(Y,"_colorManager",new n.ColorManager),$e(Y,"_zIndex",1),$e(Y,"SMALL_EDITOR_SIZE",0);let o=Y;e.AnnotationEditor=o;class h extends o{constructor(B){super(B),this.annotationElementId=B.annotationElementId,this.deleted=!0}serialize(){return{id:this.annotationElementId,deleted:!0,pageIndex:this.pageIndex}}}},(t,e,r)=>{var f,v,y,x,m,Ht,_,S,F,A,D,Fr,C,k,O,$,K,J,Y,se,B,V,Q,N,P,E,I,z,G,H,ee,ce,ve,me,xe,Se,Ce,ne,le,L,Z,re,he,ye,Fe,Pe,ie,Cr,Gt,Wt,Ft,Vt,qt,rt,pt,Pr,wr,Xt,gt,Kt;Object.defineProperty(e,"__esModule",{value:!0}),e.KeyboardManager=e.CommandManager=e.ColorManager=e.AnnotationEditorUIManager=void 0,e.bindEvents=s,e.opacityToHex=o;var n=r(1),a=r(6);function s(Ve,X,ge){for(const ke of ge)X.addEventListener(ke,Ve[ke].bind(Ve))}function o(Ve){return Math.round(Math.min(255,Math.max(1,255*Ve))).toString(16).padStart(2,"0")}class h{constructor(){de(this,f,0)}getId(){return`${n.AnnotationEditorPrefix}${ft(this,f)._++}`}}f=new WeakMap;const R=class R{constructor(){de(this,m);de(this,v,(0,n.getUuid)());de(this,y,0);de(this,x,null)}static get _isSVGFittingCanvas(){const X='data:image/svg+xml;charset=UTF-8,<svg viewBox="0 0 1 1" width="1" height="1" xmlns="http://www.w3.org/2000/svg"><rect width="1" height="1" style="fill:red;"/></svg>',ke=new OffscreenCanvas(1,3).getContext("2d"),Be=new Image;Be.src=X;const He=Be.decode().then(()=>(ke.drawImage(Be,0,0,1,1,0,0,1,3),new Uint32Array(ke.getImageData(0,0,1,1).data.buffer)[0]===0));return(0,n.shadow)(this,"_isSVGFittingCanvas",He)}async getFromFile(X){const{lastModified:ge,name:ke,size:Be,type:He}=X;return te(this,m,Ht).call(this,`${ge}_${ke}_${Be}_${He}`,X)}async getFromUrl(X){return te(this,m,Ht).call(this,X,X)}async getFromId(X){b(this,x)||ue(this,x,new Map);const ge=b(this,x).get(X);return ge?ge.bitmap?(ge.refCounter+=1,ge):ge.file?this.getFromFile(ge.file):this.getFromUrl(ge.url):null}getSvgUrl(X){const ge=b(this,x).get(X);return ge!=null&&ge.isSvg?ge.svgUrl:null}deleteId(X){b(this,x)||ue(this,x,new Map);const ge=b(this,x).get(X);ge&&(ge.refCounter-=1,ge.refCounter===0&&(ge.bitmap=null))}isValidId(X){return X.startsWith(`image_${b(this,v)}_`)}};v=new WeakMap,y=new WeakMap,x=new WeakMap,m=new WeakSet,Ht=async function(X,ge){b(this,x)||ue(this,x,new Map);let ke=b(this,x).get(X);if(ke===null)return null;if(ke!=null&&ke.bitmap)return ke.refCounter+=1,ke;try{ke||(ke={bitmap:null,id:`image_${b(this,v)}_${ft(this,y)._++}`,refCounter:0,isSvg:!1});let Be;if(typeof ge=="string"){ke.url=ge;const He=await fetch(ge);if(!He.ok)throw new Error(He.statusText);Be=await He.blob()}else Be=ke.file=ge;if(Be.type==="image/svg+xml"){const He=R._isSVGFittingCanvas,Ne=new FileReader,U=new Image,j=new Promise((W,fe)=>{U.onload=()=>{ke.bitmap=U,ke.isSvg=!0,W()},Ne.onload=async()=>{const pe=ke.svgUrl=Ne.result;U.src=await He?`${pe}#svgView(preserveAspectRatio(none))`:pe},U.onerror=Ne.onerror=fe});Ne.readAsDataURL(Be),await j}else ke.bitmap=await createImageBitmap(Be);ke.refCounter=1}catch(Be){console.error(Be),ke=null}return b(this,x).set(X,ke),ke&&b(this,x).set(ke.id,ke),ke};let d=R;class l{constructor(X=128){de(this,_,[]);de(this,S,!1);de(this,F);de(this,A,-1);ue(this,F,X)}add({cmd:X,undo:ge,mustExec:ke,type:Be=NaN,overwriteIfSameType:He=!1,keepUndo:Ne=!1}){if(ke&&X(),b(this,S))return;const U={cmd:X,undo:ge,type:Be};if(b(this,A)===-1){b(this,_).length>0&&(b(this,_).length=0),ue(this,A,0),b(this,_).push(U);return}if(He&&b(this,_)[b(this,A)].type===Be){Ne&&(U.undo=b(this,_)[b(this,A)].undo),b(this,_)[b(this,A)]=U;return}const j=b(this,A)+1;j===b(this,F)?b(this,_).splice(0,1):(ue(this,A,j),j<b(this,_).length&&b(this,_).splice(j)),b(this,_).push(U)}undo(){b(this,A)!==-1&&(ue(this,S,!0),b(this,_)[b(this,A)].undo(),ue(this,S,!1),ue(this,A,b(this,A)-1))}redo(){b(this,A)<b(this,_).length-1&&(ue(this,A,b(this,A)+1),ue(this,S,!0),b(this,_)[b(this,A)].cmd(),ue(this,S,!1))}hasSomethingToUndo(){return b(this,A)!==-1}hasSomethingToRedo(){return b(this,A)<b(this,_).length-1}destroy(){ue(this,_,null)}}_=new WeakMap,S=new WeakMap,F=new WeakMap,A=new WeakMap,e.CommandManager=l;class u{constructor(X){de(this,D);this.buffer=[],this.callbacks=new Map,this.allKeys=new Set;const{isMac:ge}=n.FeatureTest.platform;for(const[ke,Be,He={}]of X)for(const Ne of ke){const U=Ne.startsWith("mac+");ge&&U?(this.callbacks.set(Ne.slice(4),{callback:Be,options:He}),this.allKeys.add(Ne.split("+").at(-1))):!ge&&!U&&(this.callbacks.set(Ne,{callback:Be,options:He}),this.allKeys.add(Ne.split("+").at(-1)))}}exec(X,ge){if(!this.allKeys.has(ge.key))return;const ke=this.callbacks.get(te(this,D,Fr).call(this,ge));if(!ke)return;const{callback:Be,options:{bubbles:He=!1,args:Ne=[],checker:U=null}}=ke;U&&!U(X,ge)||(Be.bind(X,...Ne)(),He||(ge.stopPropagation(),ge.preventDefault()))}}D=new WeakSet,Fr=function(X){X.altKey&&this.buffer.push("alt"),X.ctrlKey&&this.buffer.push("ctrl"),X.metaKey&&this.buffer.push("meta"),X.shiftKey&&this.buffer.push("shift"),this.buffer.push(X.key);const ge=this.buffer.join("+");return this.buffer.length=0,ge},e.KeyboardManager=u;const M=class M{get _colors(){const X=new Map([["CanvasText",null],["Canvas",null]]);return(0,a.getColorValues)(X),(0,n.shadow)(this,"_colors",X)}convert(X){const ge=(0,a.getRGB)(X);if(!window.matchMedia("(forced-colors: active)").matches)return ge;for(const[ke,Be]of this._colors)if(Be.every((He,Ne)=>He===ge[Ne]))return M._colorsMapping.get(ke);return ge}getHexCode(X){const ge=this._colors.get(X);return ge?n.Util.makeHexColor(...ge):X}};$e(M,"_colorsMapping",new Map([["CanvasText",[0,0,0]],["Canvas",[255,255,255]]]));let p=M;e.ColorManager=p;const We=class We{constructor(X,ge,ke,Be,He,Ne){de(this,ie);de(this,C,null);de(this,k,new Map);de(this,O,new Map);de(this,$,null);de(this,K,null);de(this,J,new l);de(this,Y,0);de(this,se,new Set);de(this,B,null);de(this,V,null);de(this,Q,new Set);de(this,N,null);de(this,P,new h);de(this,E,!1);de(this,I,!1);de(this,z,null);de(this,G,n.AnnotationEditorType.NONE);de(this,H,new Set);de(this,ee,null);de(this,ce,this.blur.bind(this));de(this,ve,this.focus.bind(this));de(this,me,this.copy.bind(this));de(this,xe,this.cut.bind(this));de(this,Se,this.paste.bind(this));de(this,Ce,this.keydown.bind(this));de(this,ne,this.onEditingAction.bind(this));de(this,le,this.onPageChanging.bind(this));de(this,L,this.onScaleChanging.bind(this));de(this,Z,this.onRotationChanging.bind(this));de(this,re,{isEditing:!1,isEmpty:!0,hasSomethingToUndo:!1,hasSomethingToRedo:!1,hasSelectedEditor:!1});de(this,he,[0,0]);de(this,ye,null);de(this,Fe,null);de(this,Pe,null);ue(this,Fe,X),ue(this,Pe,ge),ue(this,$,ke),this._eventBus=Be,this._eventBus._on("editingaction",b(this,ne)),this._eventBus._on("pagechanging",b(this,le)),this._eventBus._on("scalechanging",b(this,L)),this._eventBus._on("rotationchanging",b(this,Z)),ue(this,K,He.annotationStorage),ue(this,N,He.filterFactory),ue(this,ee,Ne),this.viewParameters={realScale:a.PixelsPerInch.PDF_TO_CSS_UNITS,rotation:0}}static get _keyboardManager(){const X=We.prototype,ge=He=>{const{activeElement:Ne}=document;return Ne&&b(He,Fe).contains(Ne)&&He.hasSomethingToControl()},ke=this.TRANSLATE_SMALL,Be=this.TRANSLATE_BIG;return(0,n.shadow)(this,"_keyboardManager",new u([[["ctrl+a","mac+meta+a"],X.selectAll],[["ctrl+z","mac+meta+z"],X.undo],[["ctrl+y","ctrl+shift+z","mac+meta+shift+z","ctrl+shift+Z","mac+meta+shift+Z"],X.redo],[["Backspace","alt+Backspace","ctrl+Backspace","shift+Backspace","mac+Backspace","mac+alt+Backspace","mac+ctrl+Backspace","Delete","ctrl+Delete","shift+Delete","mac+Delete"],X.delete],[["Escape","mac+Escape"],X.unselectAll],[["ArrowLeft","mac+ArrowLeft"],X.translateSelectedEditors,{args:[-ke,0],checker:ge}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],X.translateSelectedEditors,{args:[-Be,0],checker:ge}],[["ArrowRight","mac+ArrowRight"],X.translateSelectedEditors,{args:[ke,0],checker:ge}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],X.translateSelectedEditors,{args:[Be,0],checker:ge}],[["ArrowUp","mac+ArrowUp"],X.translateSelectedEditors,{args:[0,-ke],checker:ge}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],X.translateSelectedEditors,{args:[0,-Be],checker:ge}],[["ArrowDown","mac+ArrowDown"],X.translateSelectedEditors,{args:[0,ke],checker:ge}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],X.translateSelectedEditors,{args:[0,Be],checker:ge}]]))}destroy(){te(this,ie,Ft).call(this),te(this,ie,Gt).call(this),this._eventBus._off("editingaction",b(this,ne)),this._eventBus._off("pagechanging",b(this,le)),this._eventBus._off("scalechanging",b(this,L)),this._eventBus._off("rotationchanging",b(this,Z));for(const X of b(this,O).values())X.destroy();b(this,O).clear(),b(this,k).clear(),b(this,Q).clear(),ue(this,C,null),b(this,H).clear(),b(this,J).destroy(),b(this,$).destroy()}get hcmFilter(){return(0,n.shadow)(this,"hcmFilter",b(this,ee)?b(this,N).addHCMFilter(b(this,ee).foreground,b(this,ee).background):"none")}get direction(){return(0,n.shadow)(this,"direction",getComputedStyle(b(this,Fe)).direction)}editAltText(X){var ge;(ge=b(this,$))==null||ge.editAltText(this,X)}onPageChanging({pageNumber:X}){ue(this,Y,X-1)}focusMainContainer(){b(this,Fe).focus()}findParent(X,ge){for(const ke of b(this,O).values()){const{x:Be,y:He,width:Ne,height:U}=ke.div.getBoundingClientRect();if(X>=Be&&X<=Be+Ne&&ge>=He&&ge<=He+U)return ke}return null}disableUserSelect(X=!1){b(this,Pe).classList.toggle("noUserSelect",X)}addShouldRescale(X){b(this,Q).add(X)}removeShouldRescale(X){b(this,Q).delete(X)}onScaleChanging({scale:X}){this.commitOrRemove(),this.viewParameters.realScale=X*a.PixelsPerInch.PDF_TO_CSS_UNITS;for(const ge of b(this,Q))ge.onScaleChanging()}onRotationChanging({pagesRotation:X}){this.commitOrRemove(),this.viewParameters.rotation=X}addToAnnotationStorage(X){!X.isEmpty()&&b(this,K)&&!b(this,K).has(X.id)&&b(this,K).setValue(X.id,X)}blur(){if(!this.hasSelection)return;const{activeElement:X}=document;for(const ge of b(this,H))if(ge.div.contains(X)){ue(this,z,[ge,X]),ge._focusEventsAllowed=!1;break}}focus(){if(!b(this,z))return;const[X,ge]=b(this,z);ue(this,z,null),ge.addEventListener("focusin",()=>{X._focusEventsAllowed=!0},{once:!0}),ge.focus()}addEditListeners(){te(this,ie,Wt).call(this),te(this,ie,Vt).call(this)}removeEditListeners(){te(this,ie,Ft).call(this),te(this,ie,qt).call(this)}copy(X){var ke;if(X.preventDefault(),(ke=b(this,C))==null||ke.commitOrRemove(),!this.hasSelection)return;const ge=[];for(const Be of b(this,H)){const He=Be.serialize(!0);He&&ge.push(He)}ge.length!==0&&X.clipboardData.setData("application/pdfjs",JSON.stringify(ge))}cut(X){this.copy(X),this.delete()}paste(X){X.preventDefault();const{clipboardData:ge}=X;for(const He of ge.items)for(const Ne of b(this,V))if(Ne.isHandlingMimeForPasting(He.type)){Ne.paste(He,this.currentLayer);return}let ke=ge.getData("application/pdfjs");if(!ke)return;try{ke=JSON.parse(ke)}catch(He){(0,n.warn)(`paste: "${He.message}".`);return}if(!Array.isArray(ke))return;this.unselectAll();const Be=this.currentLayer;try{const He=[];for(const j of ke){const W=Be.deserialize(j);if(!W)return;He.push(W)}const Ne=()=>{for(const j of He)te(this,ie,Xt).call(this,j);te(this,ie,Kt).call(this,He)},U=()=>{for(const j of He)j.remove()};this.addCommands({cmd:Ne,undo:U,mustExec:!0})}catch(He){(0,n.warn)(`paste: "${He.message}".`)}}keydown(X){var ge;(ge=this.getActive())!=null&&ge.shouldGetKeyboardEvents()||We._keyboardManager.exec(this,X)}onEditingAction(X){["undo","redo","delete","selectAll"].includes(X.name)&&this[X.name]()}setEditingState(X){X?(te(this,ie,Cr).call(this),te(this,ie,Wt).call(this),te(this,ie,Vt).call(this),te(this,ie,rt).call(this,{isEditing:b(this,G)!==n.AnnotationEditorType.NONE,isEmpty:te(this,ie,gt).call(this),hasSomethingToUndo:b(this,J).hasSomethingToUndo(),hasSomethingToRedo:b(this,J).hasSomethingToRedo(),hasSelectedEditor:!1})):(te(this,ie,Gt).call(this),te(this,ie,Ft).call(this),te(this,ie,qt).call(this),te(this,ie,rt).call(this,{isEditing:!1}),this.disableUserSelect(!1))}registerEditorTypes(X){if(!b(this,V)){ue(this,V,X);for(const ge of b(this,V))te(this,ie,pt).call(this,ge.defaultPropertiesToUpdate)}}getId(){return b(this,P).getId()}get currentLayer(){return b(this,O).get(b(this,Y))}getLayer(X){return b(this,O).get(X)}get currentPageIndex(){return b(this,Y)}addLayer(X){b(this,O).set(X.pageIndex,X),b(this,E)?X.enable():X.disable()}removeLayer(X){b(this,O).delete(X.pageIndex)}updateMode(X,ge=null){if(b(this,G)!==X){if(ue(this,G,X),X===n.AnnotationEditorType.NONE){this.setEditingState(!1),te(this,ie,wr).call(this);return}this.setEditingState(!0),te(this,ie,Pr).call(this),this.unselectAll();for(const ke of b(this,O).values())ke.updateMode(X);if(ge){for(const ke of b(this,k).values())if(ke.annotationElementId===ge){this.setSelected(ke),ke.enterInEditMode();break}}}}updateToolbar(X){X!==b(this,G)&&this._eventBus.dispatch("switchannotationeditormode",{source:this,mode:X})}updateParams(X,ge){if(b(this,V)){if(X===n.AnnotationEditorParamsType.CREATE){this.currentLayer.addNewEditor(X);return}for(const ke of b(this,H))ke.updateParams(X,ge);for(const ke of b(this,V))ke.updateDefaultParams(X,ge)}}enableWaiting(X=!1){if(b(this,I)!==X){ue(this,I,X);for(const ge of b(this,O).values())X?ge.disableClick():ge.enableClick(),ge.div.classList.toggle("waiting",X)}}getEditors(X){const ge=[];for(const ke of b(this,k).values())ke.pageIndex===X&&ge.push(ke);return ge}getEditor(X){return b(this,k).get(X)}addEditor(X){b(this,k).set(X.id,X)}removeEditor(X){var ge;b(this,k).delete(X.id),this.unselect(X),(!X.annotationElementId||!b(this,se).has(X.annotationElementId))&&((ge=b(this,K))==null||ge.remove(X.id))}addDeletedAnnotationElement(X){b(this,se).add(X.annotationElementId),X.deleted=!0}isDeletedAnnotationElement(X){return b(this,se).has(X)}removeDeletedAnnotationElement(X){b(this,se).delete(X.annotationElementId),X.deleted=!1}setActiveEditor(X){b(this,C)!==X&&(ue(this,C,X),X&&te(this,ie,pt).call(this,X.propertiesToUpdate))}toggleSelected(X){if(b(this,H).has(X)){b(this,H).delete(X),X.unselect(),te(this,ie,rt).call(this,{hasSelectedEditor:this.hasSelection});return}b(this,H).add(X),X.select(),te(this,ie,pt).call(this,X.propertiesToUpdate),te(this,ie,rt).call(this,{hasSelectedEditor:!0})}setSelected(X){for(const ge of b(this,H))ge!==X&&ge.unselect();b(this,H).clear(),b(this,H).add(X),X.select(),te(this,ie,pt).call(this,X.propertiesToUpdate),te(this,ie,rt).call(this,{hasSelectedEditor:!0})}isSelected(X){return b(this,H).has(X)}unselect(X){X.unselect(),b(this,H).delete(X),te(this,ie,rt).call(this,{hasSelectedEditor:this.hasSelection})}get hasSelection(){return b(this,H).size!==0}undo(){b(this,J).undo(),te(this,ie,rt).call(this,{hasSomethingToUndo:b(this,J).hasSomethingToUndo(),hasSomethingToRedo:!0,isEmpty:te(this,ie,gt).call(this)})}redo(){b(this,J).redo(),te(this,ie,rt).call(this,{hasSomethingToUndo:!0,hasSomethingToRedo:b(this,J).hasSomethingToRedo(),isEmpty:te(this,ie,gt).call(this)})}addCommands(X){b(this,J).add(X),te(this,ie,rt).call(this,{hasSomethingToUndo:!0,hasSomethingToRedo:!1,isEmpty:te(this,ie,gt).call(this)})}delete(){if(this.commitOrRemove(),!this.hasSelection)return;const X=[...b(this,H)],ge=()=>{for(const Be of X)Be.remove()},ke=()=>{for(const Be of X)te(this,ie,Xt).call(this,Be)};this.addCommands({cmd:ge,undo:ke,mustExec:!0})}commitOrRemove(){var X;(X=b(this,C))==null||X.commitOrRemove()}hasSomethingToControl(){return b(this,C)||this.hasSelection}selectAll(){for(const X of b(this,H))X.commit();te(this,ie,Kt).call(this,b(this,k).values())}unselectAll(){if(b(this,C)){b(this,C).commitOrRemove();return}if(this.hasSelection){for(const X of b(this,H))X.unselect();b(this,H).clear(),te(this,ie,rt).call(this,{hasSelectedEditor:!1})}}translateSelectedEditors(X,ge,ke=!1){if(ke||this.commitOrRemove(),!this.hasSelection)return;b(this,he)[0]+=X,b(this,he)[1]+=ge;const[Be,He]=b(this,he),Ne=[...b(this,H)],U=1e3;b(this,ye)&&clearTimeout(b(this,ye)),ue(this,ye,setTimeout(()=>{ue(this,ye,null),b(this,he)[0]=b(this,he)[1]=0,this.addCommands({cmd:()=>{for(const j of Ne)b(this,k).has(j.id)&&j.translateInPage(Be,He)},undo:()=>{for(const j of Ne)b(this,k).has(j.id)&&j.translateInPage(-Be,-He)},mustExec:!1})},U));for(const j of Ne)j.translateInPage(X,ge)}setUpDragSession(){if(this.hasSelection){this.disableUserSelect(!0),ue(this,B,new Map);for(const X of b(this,H))b(this,B).set(X,{savedX:X.x,savedY:X.y,savedPageIndex:X.pageIndex,newX:0,newY:0,newPageIndex:-1})}}endDragSession(){if(!b(this,B))return!1;this.disableUserSelect(!1);const X=b(this,B);ue(this,B,null);let ge=!1;for(const[{x:Be,y:He,pageIndex:Ne},U]of X)U.newX=Be,U.newY=He,U.newPageIndex=Ne,ge||(ge=Be!==U.savedX||He!==U.savedY||Ne!==U.savedPageIndex);if(!ge)return!1;const ke=(Be,He,Ne,U)=>{if(b(this,k).has(Be.id)){const j=b(this,O).get(U);j?Be._setParentAndPosition(j,He,Ne):(Be.pageIndex=U,Be.x=He,Be.y=Ne)}};return this.addCommands({cmd:()=>{for(const[Be,{newX:He,newY:Ne,newPageIndex:U}]of X)ke(Be,He,Ne,U)},undo:()=>{for(const[Be,{savedX:He,savedY:Ne,savedPageIndex:U}]of X)ke(Be,He,Ne,U)},mustExec:!0}),!0}dragSelectedEditors(X,ge){if(b(this,B))for(const ke of b(this,B).keys())ke.drag(X,ge)}rebuild(X){if(X.parent===null){const ge=this.getLayer(X.pageIndex);ge?(ge.changeParent(X),ge.addOrRebuild(X)):(this.addEditor(X),this.addToAnnotationStorage(X),X.rebuild())}else X.parent.addOrRebuild(X)}isActive(X){return b(this,C)===X}getActive(){return b(this,C)}getMode(){return b(this,G)}get imageManager(){return(0,n.shadow)(this,"imageManager",new d)}};C=new WeakMap,k=new WeakMap,O=new WeakMap,$=new WeakMap,K=new WeakMap,J=new WeakMap,Y=new WeakMap,se=new WeakMap,B=new WeakMap,V=new WeakMap,Q=new WeakMap,N=new WeakMap,P=new WeakMap,E=new WeakMap,I=new WeakMap,z=new WeakMap,G=new WeakMap,H=new WeakMap,ee=new WeakMap,ce=new WeakMap,ve=new WeakMap,me=new WeakMap,xe=new WeakMap,Se=new WeakMap,Ce=new WeakMap,ne=new WeakMap,le=new WeakMap,L=new WeakMap,Z=new WeakMap,re=new WeakMap,he=new WeakMap,ye=new WeakMap,Fe=new WeakMap,Pe=new WeakMap,ie=new WeakSet,Cr=function(){window.addEventListener("focus",b(this,ve)),window.addEventListener("blur",b(this,ce))},Gt=function(){window.removeEventListener("focus",b(this,ve)),window.removeEventListener("blur",b(this,ce))},Wt=function(){window.addEventListener("keydown",b(this,Ce),{capture:!0})},Ft=function(){window.removeEventListener("keydown",b(this,Ce),{capture:!0})},Vt=function(){document.addEventListener("copy",b(this,me)),document.addEventListener("cut",b(this,xe)),document.addEventListener("paste",b(this,Se))},qt=function(){document.removeEventListener("copy",b(this,me)),document.removeEventListener("cut",b(this,xe)),document.removeEventListener("paste",b(this,Se))},rt=function(X){Object.entries(X).some(([ke,Be])=>b(this,re)[ke]!==Be)&&this._eventBus.dispatch("annotationeditorstateschanged",{source:this,details:Object.assign(b(this,re),X)})},pt=function(X){this._eventBus.dispatch("annotationeditorparamschanged",{source:this,details:X})},Pr=function(){if(!b(this,E)){ue(this,E,!0);for(const X of b(this,O).values())X.enable()}},wr=function(){if(this.unselectAll(),b(this,E)){ue(this,E,!1);for(const X of b(this,O).values())X.disable()}},Xt=function(X){const ge=b(this,O).get(X.pageIndex);ge?ge.addOrRebuild(X):this.addEditor(X)},gt=function(){if(b(this,k).size===0)return!0;if(b(this,k).size===1)for(const X of b(this,k).values())return X.isEmpty();return!1},Kt=function(X){b(this,H).clear();for(const ge of X)ge.isEmpty()||(b(this,H).add(ge),ge.select());te(this,ie,rt).call(this,{hasSelectedEditor:!0})},$e(We,"TRANSLATE_SMALL",1),$e(We,"TRANSLATE_BIG",10);let g=We;e.AnnotationEditorUIManager=g},(t,e,r)=>{var Y,se,B,V,Q,N,P,E,I,z,G,H,ct,ht,Zt,Ct,Pt,vt,mt;Object.defineProperty(e,"__esModule",{value:!0}),e.StatTimer=e.RenderingCancelledException=e.PixelsPerInch=e.PageViewport=e.PDFDateString=e.DOMStandardFontDataFactory=e.DOMSVGFactory=e.DOMFilterFactory=e.DOMCanvasFactory=e.DOMCMapReaderFactory=void 0,e.deprecated=A,e.getColorValues=k,e.getCurrentTransform=O,e.getCurrentTransformInverse=$,e.getFilenameFromUrl=m,e.getPdfFilenameFromUrl=w,e.getRGB=C,e.getXfaPageViewport=M,e.isDataScheme=y,e.isPdfFile=x,e.isValidFetchUrl=_,e.loadScript=F,e.noContextMenu=S,e.setLayerDimensions=K;var n=r(7),a=r(1);const s="http://www.w3.org/2000/svg",J=class J{};$e(J,"CSS",96),$e(J,"PDF",72),$e(J,"PDF_TO_CSS_UNITS",J.CSS/J.PDF);let o=J;e.PixelsPerInch=o;class h extends n.BaseFilterFactory{constructor({docId:L,ownerDocument:Z=globalThis.document}={}){super();de(this,H);de(this,Y);de(this,se);de(this,B);de(this,V);de(this,Q);de(this,N);de(this,P);de(this,E);de(this,I);de(this,z);de(this,G,0);ue(this,B,L),ue(this,V,Z)}addFilter(L){if(!L)return"none";let Z=b(this,H,ct).get(L);if(Z)return Z;let re,he,ye,Fe;if(L.length===1){const Te=L[0],Ke=new Array(256);for(let qe=0;qe<256;qe++)Ke[qe]=Te[qe]/255;Fe=re=he=ye=Ke.join(",")}else{const[Te,Ke,qe]=L,Ye=new Array(256),Me=new Array(256),Ee=new Array(256);for(let Ie=0;Ie<256;Ie++)Ye[Ie]=Te[Ie]/255,Me[Ie]=Ke[Ie]/255,Ee[Ie]=qe[Ie]/255;re=Ye.join(","),he=Me.join(","),ye=Ee.join(","),Fe=`${re}${he}${ye}`}if(Z=b(this,H,ct).get(Fe),Z)return b(this,H,ct).set(L,Z),Z;const Pe=`g_${b(this,B)}_transfer_map_${ft(this,G)._++}`,ie=`url(#${Pe})`;b(this,H,ct).set(L,ie),b(this,H,ct).set(Fe,ie);const _e=te(this,H,Ct).call(this,Pe);return te(this,H,vt).call(this,re,he,ye,_e),ie}addHCMFilter(L,Z){var Ke;const re=`${L}-${Z}`;if(b(this,N)===re)return b(this,P);if(ue(this,N,re),ue(this,P,"none"),(Ke=b(this,Q))==null||Ke.remove(),!L||!Z)return b(this,P);const he=te(this,H,mt).call(this,L);L=a.Util.makeHexColor(...he);const ye=te(this,H,mt).call(this,Z);if(Z=a.Util.makeHexColor(...ye),b(this,H,ht).style.color="",L==="#000000"&&Z==="#ffffff"||L===Z)return b(this,P);const Fe=new Array(256);for(let qe=0;qe<=255;qe++){const Ye=qe/255;Fe[qe]=Ye<=.03928?Ye/12.92:((Ye+.055)/1.055)**2.4}const Pe=Fe.join(","),ie=`g_${b(this,B)}_hcm_filter`,_e=ue(this,E,te(this,H,Ct).call(this,ie));te(this,H,vt).call(this,Pe,Pe,Pe,_e),te(this,H,Zt).call(this,_e);const Te=(qe,Ye)=>{const Me=he[qe]/255,Ee=ye[qe]/255,Ie=new Array(Ye+1);for(let ze=0;ze<=Ye;ze++)Ie[ze]=Me+ze/Ye*(Ee-Me);return Ie.join(",")};return te(this,H,vt).call(this,Te(0,5),Te(1,5),Te(2,5),_e),ue(this,P,`url(#${ie})`),b(this,P)}addHighlightHCMFilter(L,Z,re,he){var Ee;const ye=`${L}-${Z}-${re}-${he}`;if(b(this,I)===ye)return b(this,z);if(ue(this,I,ye),ue(this,z,"none"),(Ee=b(this,E))==null||Ee.remove(),!L||!Z)return b(this,z);const[Fe,Pe]=[L,Z].map(te(this,H,mt).bind(this));let ie=Math.round(.2126*Fe[0]+.7152*Fe[1]+.0722*Fe[2]),_e=Math.round(.2126*Pe[0]+.7152*Pe[1]+.0722*Pe[2]),[Te,Ke]=[re,he].map(te(this,H,mt).bind(this));_e<ie&&([ie,_e,Te,Ke]=[_e,ie,Ke,Te]),b(this,H,ht).style.color="";const qe=(Ie,ze,be)=>{const oe=new Array(256),ae=(_e-ie)/be,Re=Ie/255,We=(ze-Ie)/(255*be);let Ve=0;for(let X=0;X<=be;X++){const ge=Math.round(ie+X*ae),ke=Re+X*We;for(let Be=Ve;Be<=ge;Be++)oe[Be]=ke;Ve=ge+1}for(let X=Ve;X<256;X++)oe[X]=oe[Ve-1];return oe.join(",")},Ye=`g_${b(this,B)}_hcm_highlight_filter`,Me=ue(this,E,te(this,H,Ct).call(this,Ye));return te(this,H,Zt).call(this,Me),te(this,H,vt).call(this,qe(Te[0],Ke[0],5),qe(Te[1],Ke[1],5),qe(Te[2],Ke[2],5),Me),ue(this,z,`url(#${Ye})`),b(this,z)}destroy(L=!1){L&&(b(this,P)||b(this,z))||(b(this,se)&&(b(this,se).parentNode.parentNode.remove(),ue(this,se,null)),b(this,Y)&&(b(this,Y).clear(),ue(this,Y,null)),ue(this,G,0))}}Y=new WeakMap,se=new WeakMap,B=new WeakMap,V=new WeakMap,Q=new WeakMap,N=new WeakMap,P=new WeakMap,E=new WeakMap,I=new WeakMap,z=new WeakMap,G=new WeakMap,H=new WeakSet,ct=function(){return b(this,Y)||ue(this,Y,new Map)},ht=function(){if(!b(this,se)){const L=b(this,V).createElement("div"),{style:Z}=L;Z.visibility="hidden",Z.contain="strict",Z.width=Z.height=0,Z.position="absolute",Z.top=Z.left=0,Z.zIndex=-1;const re=b(this,V).createElementNS(s,"svg");re.setAttribute("width",0),re.setAttribute("height",0),ue(this,se,b(this,V).createElementNS(s,"defs")),L.append(re),re.append(b(this,se)),b(this,V).body.append(L)}return b(this,se)},Zt=function(L){const Z=b(this,V).createElementNS(s,"feColorMatrix");Z.setAttribute("type","matrix"),Z.setAttribute("values","0.2126 0.7152 0.0722 0 0 0.2126 0.7152 0.0722 0 0 0.2126 0.7152 0.0722 0 0 0 0 0 1 0"),L.append(Z)},Ct=function(L){const Z=b(this,V).createElementNS(s,"filter");return Z.setAttribute("color-interpolation-filters","sRGB"),Z.setAttribute("id",L),b(this,H,ht).append(Z),Z},Pt=function(L,Z,re){const he=b(this,V).createElementNS(s,Z);he.setAttribute("type","discrete"),he.setAttribute("tableValues",re),L.append(he)},vt=function(L,Z,re,he){const ye=b(this,V).createElementNS(s,"feComponentTransfer");he.append(ye),te(this,H,Pt).call(this,ye,"feFuncR",L),te(this,H,Pt).call(this,ye,"feFuncG",Z),te(this,H,Pt).call(this,ye,"feFuncB",re)},mt=function(L){return b(this,H,ht).style.color=L,C(getComputedStyle(b(this,H,ht)).getPropertyValue("color"))},e.DOMFilterFactory=h;class d extends n.BaseCanvasFactory{constructor({ownerDocument:le=globalThis.document}={}){super(),this._document=le}_createCanvas(le,L){const Z=this._document.createElement("canvas");return Z.width=le,Z.height=L,Z}}e.DOMCanvasFactory=d;async function l(ne,le=!1){if(_(ne,document.baseURI)){const L=await fetch(ne);if(!L.ok)throw new Error(L.statusText);return le?new Uint8Array(await L.arrayBuffer()):(0,a.stringToBytes)(await L.text())}return new Promise((L,Z)=>{const re=new XMLHttpRequest;re.open("GET",ne,!0),le&&(re.responseType="arraybuffer"),re.onreadystatechange=()=>{if(re.readyState===XMLHttpRequest.DONE){if(re.status===200||re.status===0){let he;if(le&&re.response?he=new Uint8Array(re.response):!le&&re.responseText&&(he=(0,a.stringToBytes)(re.responseText)),he){L(he);return}}Z(new Error(re.statusText))}},re.send(null)})}class u extends n.BaseCMapReaderFactory{_fetchData(le,L){return l(le,this.isCompressed).then(Z=>({cMapData:Z,compressionType:L}))}}e.DOMCMapReaderFactory=u;class p extends n.BaseStandardFontDataFactory{_fetchData(le){return l(le,!0)}}e.DOMStandardFontDataFactory=p;class g extends n.BaseSVGFactory{_createSVG(le){return document.createElementNS(s,le)}}e.DOMSVGFactory=g;class f{constructor({viewBox:le,scale:L,rotation:Z,offsetX:re=0,offsetY:he=0,dontFlip:ye=!1}){this.viewBox=le,this.scale=L,this.rotation=Z,this.offsetX=re,this.offsetY=he;const Fe=(le[2]+le[0])/2,Pe=(le[3]+le[1])/2;let ie,_e,Te,Ke;switch(Z%=360,Z<0&&(Z+=360),Z){case 180:ie=-1,_e=0,Te=0,Ke=1;break;case 90:ie=0,_e=1,Te=1,Ke=0;break;case 270:ie=0,_e=-1,Te=-1,Ke=0;break;case 0:ie=1,_e=0,Te=0,Ke=-1;break;default:throw new Error("PageViewport: Invalid rotation, must be a multiple of 90 degrees.")}ye&&(Te=-Te,Ke=-Ke);let qe,Ye,Me,Ee;ie===0?(qe=Math.abs(Pe-le[1])*L+re,Ye=Math.abs(Fe-le[0])*L+he,Me=(le[3]-le[1])*L,Ee=(le[2]-le[0])*L):(qe=Math.abs(Fe-le[0])*L+re,Ye=Math.abs(Pe-le[1])*L+he,Me=(le[2]-le[0])*L,Ee=(le[3]-le[1])*L),this.transform=[ie*L,_e*L,Te*L,Ke*L,qe-ie*L*Fe-Te*L*Pe,Ye-_e*L*Fe-Ke*L*Pe],this.width=Me,this.height=Ee}get rawDims(){const{viewBox:le}=this;return(0,a.shadow)(this,"rawDims",{pageWidth:le[2]-le[0],pageHeight:le[3]-le[1],pageX:le[0],pageY:le[1]})}clone({scale:le=this.scale,rotation:L=this.rotation,offsetX:Z=this.offsetX,offsetY:re=this.offsetY,dontFlip:he=!1}={}){return new f({viewBox:this.viewBox.slice(),scale:le,rotation:L,offsetX:Z,offsetY:re,dontFlip:he})}convertToViewportPoint(le,L){return a.Util.applyTransform([le,L],this.transform)}convertToViewportRectangle(le){const L=a.Util.applyTransform([le[0],le[1]],this.transform),Z=a.Util.applyTransform([le[2],le[3]],this.transform);return[L[0],L[1],Z[0],Z[1]]}convertToPdfPoint(le,L){return a.Util.applyInverseTransform([le,L],this.transform)}}e.PageViewport=f;class v extends a.BaseException{constructor(le,L=0){super(le,"RenderingCancelledException"),this.extraDelay=L}}e.RenderingCancelledException=v;function y(ne){const le=ne.length;let L=0;for(;L<le&&ne[L].trim()==="";)L++;return ne.substring(L,L+5).toLowerCase()==="data:"}function x(ne){return typeof ne=="string"&&/\.pdf$/i.test(ne)}function m(ne,le=!1){return le||([ne]=ne.split(/[#?]/,1)),ne.substring(ne.lastIndexOf("/")+1)}function w(ne,le="document.pdf"){if(typeof ne!="string")return le;if(y(ne))return(0,a.warn)('getPdfFilenameFromUrl: ignore "data:"-URL for performance reasons.'),le;const L=/^(?:(?:[^:]+:)?\/\/[^/]+)?([^?#]*)(\?[^#]*)?(#.*)?$/,Z=/[^/?#=]+\.pdf\b(?!.*\.pdf\b)/i,re=L.exec(ne);let he=Z.exec(re[1])||Z.exec(re[2])||Z.exec(re[3]);if(he&&(he=he[0],he.includes("%")))try{he=Z.exec(decodeURIComponent(he))[0]}catch{}return he||le}class R{constructor(){$e(this,"started",Object.create(null));$e(this,"times",[])}time(le){le in this.started&&(0,a.warn)(`Timer is already running for ${le}`),this.started[le]=Date.now()}timeEnd(le){le in this.started||(0,a.warn)(`Timer has not been started for ${le}`),this.times.push({name:le,start:this.started[le],end:Date.now()}),delete this.started[le]}toString(){const le=[];let L=0;for(const{name:Z}of this.times)L=Math.max(Z.length,L);for(const{name:Z,start:re,end:he}of this.times)le.push(`${Z.padEnd(L)} ${he-re}ms
|
|
2
|
-
`);return le.join("")}}e.StatTimer=R;function _(ne,le){try{const{protocol:L}=le?new URL(ne,le):new URL(ne);return L==="http:"||L==="https:"}catch{return!1}}function S(ne){ne.preventDefault()}function F(ne,le=!1){return new Promise((L,Z)=>{const re=document.createElement("script");re.src=ne,re.onload=function(he){le&&re.remove(),L(he)},re.onerror=function(){Z(new Error(`Cannot load script at: ${re.src}`))},(document.head||document.documentElement).append(re)})}function A(ne){console.log("Deprecated API usage: "+ne)}let D;class T{static toDateObject(le){if(!le||typeof le!="string")return null;D||(D=new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?"));const L=D.exec(le);if(!L)return null;const Z=parseInt(L[1],10);let re=parseInt(L[2],10);re=re>=1&&re<=12?re-1:0;let he=parseInt(L[3],10);he=he>=1&&he<=31?he:1;let ye=parseInt(L[4],10);ye=ye>=0&&ye<=23?ye:0;let Fe=parseInt(L[5],10);Fe=Fe>=0&&Fe<=59?Fe:0;let Pe=parseInt(L[6],10);Pe=Pe>=0&&Pe<=59?Pe:0;const ie=L[7]||"Z";let _e=parseInt(L[8],10);_e=_e>=0&&_e<=23?_e:0;let Te=parseInt(L[9],10)||0;return Te=Te>=0&&Te<=59?Te:0,ie==="-"?(ye+=_e,Fe+=Te):ie==="+"&&(ye-=_e,Fe-=Te),new Date(Date.UTC(Z,re,he,ye,Fe,Pe))}}e.PDFDateString=T;function M(ne,{scale:le=1,rotation:L=0}){const{width:Z,height:re}=ne.attributes.style,he=[0,0,parseInt(Z),parseInt(re)];return new f({viewBox:he,scale:le,rotation:L})}function C(ne){if(ne.startsWith("#")){const le=parseInt(ne.slice(1),16);return[(le&16711680)>>16,(le&65280)>>8,le&255]}return ne.startsWith("rgb(")?ne.slice(4,-1).split(",").map(le=>parseInt(le)):ne.startsWith("rgba(")?ne.slice(5,-1).split(",").map(le=>parseInt(le)).slice(0,3):((0,a.warn)(`Not a valid color format: "${ne}"`),[0,0,0])}function k(ne){const le=document.createElement("span");le.style.visibility="hidden",document.body.append(le);for(const L of ne.keys()){le.style.color=L;const Z=window.getComputedStyle(le).color;ne.set(L,C(Z))}le.remove()}function O(ne){const{a:le,b:L,c:Z,d:re,e:he,f:ye}=ne.getTransform();return[le,L,Z,re,he,ye]}function $(ne){const{a:le,b:L,c:Z,d:re,e:he,f:ye}=ne.getTransform().invertSelf();return[le,L,Z,re,he,ye]}function K(ne,le,L=!1,Z=!0){if(le instanceof f){const{pageWidth:re,pageHeight:he}=le.rawDims,{style:ye}=ne,Fe=a.FeatureTest.isCSSRoundSupported,Pe=`var(--scale-factor) * ${re}px`,ie=`var(--scale-factor) * ${he}px`,_e=Fe?`round(${Pe}, 1px)`:`calc(${Pe})`,Te=Fe?`round(${ie}, 1px)`:`calc(${ie})`;!L||le.rotation%180===0?(ye.width=_e,ye.height=Te):(ye.width=Te,ye.height=_e)}Z&&ne.setAttribute("data-main-rotation",le.rotation)}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.BaseStandardFontDataFactory=e.BaseSVGFactory=e.BaseFilterFactory=e.BaseCanvasFactory=e.BaseCMapReaderFactory=void 0;var n=r(1);class a{constructor(){this.constructor===a&&(0,n.unreachable)("Cannot initialize BaseFilterFactory.")}addFilter(u){return"none"}addHCMFilter(u,p){return"none"}addHighlightHCMFilter(u,p,g,f){return"none"}destroy(u=!1){}}e.BaseFilterFactory=a;class s{constructor(){this.constructor===s&&(0,n.unreachable)("Cannot initialize BaseCanvasFactory.")}create(u,p){if(u<=0||p<=0)throw new Error("Invalid canvas size");const g=this._createCanvas(u,p);return{canvas:g,context:g.getContext("2d")}}reset(u,p,g){if(!u.canvas)throw new Error("Canvas is not specified");if(p<=0||g<=0)throw new Error("Invalid canvas size");u.canvas.width=p,u.canvas.height=g}destroy(u){if(!u.canvas)throw new Error("Canvas is not specified");u.canvas.width=0,u.canvas.height=0,u.canvas=null,u.context=null}_createCanvas(u,p){(0,n.unreachable)("Abstract method `_createCanvas` called.")}}e.BaseCanvasFactory=s;class o{constructor({baseUrl:u=null,isCompressed:p=!0}){this.constructor===o&&(0,n.unreachable)("Cannot initialize BaseCMapReaderFactory."),this.baseUrl=u,this.isCompressed=p}async fetch({name:u}){if(!this.baseUrl)throw new Error('The CMap "baseUrl" parameter must be specified, ensure that the "cMapUrl" and "cMapPacked" API parameters are provided.');if(!u)throw new Error("CMap name must be specified.");const p=this.baseUrl+u+(this.isCompressed?".bcmap":""),g=this.isCompressed?n.CMapCompressionType.BINARY:n.CMapCompressionType.NONE;return this._fetchData(p,g).catch(f=>{throw new Error(`Unable to load ${this.isCompressed?"binary ":""}CMap at: ${p}`)})}_fetchData(u,p){(0,n.unreachable)("Abstract method `_fetchData` called.")}}e.BaseCMapReaderFactory=o;class h{constructor({baseUrl:u=null}){this.constructor===h&&(0,n.unreachable)("Cannot initialize BaseStandardFontDataFactory."),this.baseUrl=u}async fetch({filename:u}){if(!this.baseUrl)throw new Error('The standard font "baseUrl" parameter must be specified, ensure that the "standardFontDataUrl" API parameter is provided.');if(!u)throw new Error("Font filename must be specified.");const p=`${this.baseUrl}${u}`;return this._fetchData(p).catch(g=>{throw new Error(`Unable to load font data at: ${p}`)})}_fetchData(u){(0,n.unreachable)("Abstract method `_fetchData` called.")}}e.BaseStandardFontDataFactory=h;class d{constructor(){this.constructor===d&&(0,n.unreachable)("Cannot initialize BaseSVGFactory.")}create(u,p,g=!1){if(u<=0||p<=0)throw new Error("Invalid SVG dimensions");const f=this._createSVG("svg:svg");return f.setAttribute("version","1.1"),g||(f.setAttribute("width",`${u}px`),f.setAttribute("height",`${p}px`)),f.setAttribute("preserveAspectRatio","none"),f.setAttribute("viewBox",`0 0 ${u} ${p}`),f}createElement(u){if(typeof u!="string")throw new Error("Invalid SVG element type");return this._createSVG(u)}_createSVG(u){(0,n.unreachable)("Abstract method `_createSVG` called.")}}e.BaseSVGFactory=d},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.MurmurHash3_64=void 0;var n=r(1);const a=3285377520,s=4294901760,o=65535;class h{constructor(l){this.h1=l?l&4294967295:a,this.h2=l?l&4294967295:a}update(l){let u,p;if(typeof l=="string"){u=new Uint8Array(l.length*2),p=0;for(let A=0,D=l.length;A<D;A++){const T=l.charCodeAt(A);T<=255?u[p++]=T:(u[p++]=T>>>8,u[p++]=T&255)}}else if((0,n.isArrayBuffer)(l))u=l.slice(),p=u.byteLength;else throw new Error("Wrong data format in MurmurHash3_64_update. Input must be a string or array.");const g=p>>2,f=p-g*4,v=new Uint32Array(u.buffer,0,g);let y=0,x=0,m=this.h1,w=this.h2;const R=3432918353,_=461845907,S=R&o,F=_&o;for(let A=0;A<g;A++)A&1?(y=v[A],y=y*R&s|y*S&o,y=y<<15|y>>>17,y=y*_&s|y*F&o,m^=y,m=m<<13|m>>>19,m=m*5+3864292196):(x=v[A],x=x*R&s|x*S&o,x=x<<15|x>>>17,x=x*_&s|x*F&o,w^=x,w=w<<13|w>>>19,w=w*5+3864292196);switch(y=0,f){case 3:y^=u[g*4+2]<<16;case 2:y^=u[g*4+1]<<8;case 1:y^=u[g*4],y=y*R&s|y*S&o,y=y<<15|y>>>17,y=y*_&s|y*F&o,g&1?m^=y:w^=y}this.h1=m,this.h2=w}hexdigest(){let l=this.h1,u=this.h2;return l^=u>>>1,l=l*3981806797&s|l*36045&o,u=u*4283543511&s|((u<<16|l>>>16)*2950163797&s)>>>16,l^=u>>>1,l=l*444984403&s|l*60499&o,u=u*3301882366&s|((u<<16|l>>>16)*3120437893&s)>>>16,l^=u>>>1,(l>>>0).toString(16).padStart(8,"0")+(u>>>0).toString(16).padStart(8,"0")}}e.MurmurHash3_64=h},(t,e,r)=>{var o;Object.defineProperty(e,"__esModule",{value:!0}),e.FontLoader=e.FontFaceObject=void 0;var n=r(1);class a{constructor({ownerDocument:d=globalThis.document,styleElement:l=null}){de(this,o,new Set);this._document=d,this.nativeFontFaces=new Set,this.styleElement=null,this.loadingRequests=[],this.loadTestFontId=0}addNativeFontFace(d){this.nativeFontFaces.add(d),this._document.fonts.add(d)}removeNativeFontFace(d){this.nativeFontFaces.delete(d),this._document.fonts.delete(d)}insertRule(d){this.styleElement||(this.styleElement=this._document.createElement("style"),this._document.documentElement.getElementsByTagName("head")[0].append(this.styleElement));const l=this.styleElement.sheet;l.insertRule(d,l.cssRules.length)}clear(){for(const d of this.nativeFontFaces)this._document.fonts.delete(d);this.nativeFontFaces.clear(),b(this,o).clear(),this.styleElement&&(this.styleElement.remove(),this.styleElement=null)}async loadSystemFont(d){if(!(!d||b(this,o).has(d.loadedName))){if((0,n.assert)(!this.disableFontFace,"loadSystemFont shouldn't be called when `disableFontFace` is set."),this.isFontLoadingAPISupported){const{loadedName:l,src:u,style:p}=d,g=new FontFace(l,u,p);this.addNativeFontFace(g);try{await g.load(),b(this,o).add(l)}catch{(0,n.warn)(`Cannot load system font: ${d.baseFontName}, installing it could help to improve PDF rendering.`),this.removeNativeFontFace(g)}return}(0,n.unreachable)("Not implemented: loadSystemFont without the Font Loading API.")}}async bind(d){if(d.attached||d.missingFile&&!d.systemFontInfo)return;if(d.attached=!0,d.systemFontInfo){await this.loadSystemFont(d.systemFontInfo);return}if(this.isFontLoadingAPISupported){const u=d.createNativeFontFace();if(u){this.addNativeFontFace(u);try{await u.loaded}catch(p){throw(0,n.warn)(`Failed to load font '${u.family}': '${p}'.`),d.disableFontFace=!0,p}}return}const l=d.createFontFaceRule();if(l){if(this.insertRule(l),this.isSyncFontLoadingSupported)return;await new Promise(u=>{const p=this._queueLoadingCallback(u);this._prepareFontLoadEvent(d,p)})}}get isFontLoadingAPISupported(){var l;const d=!!((l=this._document)!=null&&l.fonts);return(0,n.shadow)(this,"isFontLoadingAPISupported",d)}get isSyncFontLoadingSupported(){let d=!1;return(n.isNodeJS||typeof navigator<"u"&&/Mozilla\/5.0.*?rv:\d+.*? Gecko/.test(navigator.userAgent))&&(d=!0),(0,n.shadow)(this,"isSyncFontLoadingSupported",d)}_queueLoadingCallback(d){function l(){for((0,n.assert)(!p.done,"completeRequest() cannot be called twice."),p.done=!0;u.length>0&&u[0].done;){const g=u.shift();setTimeout(g.callback,0)}}const{loadingRequests:u}=this,p={done:!1,complete:l,callback:d};return u.push(p),p}get _loadTestFont(){const d=atob("T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQAFQAABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABD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AAAAAAAAAAAAAAAAAAMAAAAAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAAAAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgcA/gXBIwMAYuL+nz5tQXkD5j3CBLnEQACAQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYAAABAQAADwACAQEEE/t3Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQAAAAAAAABAAAAAMmJbzEAAAAAzgTjFQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA==");return(0,n.shadow)(this,"_loadTestFont",d)}_prepareFontLoadEvent(d,l){function u(C,k){return C.charCodeAt(k)<<24|C.charCodeAt(k+1)<<16|C.charCodeAt(k+2)<<8|C.charCodeAt(k+3)&255}function p(C,k,O,$){const K=C.substring(0,k),J=C.substring(k+O);return K+$+J}let g,f;const v=this._document.createElement("canvas");v.width=1,v.height=1;const y=v.getContext("2d");let x=0;function m(C,k){if(++x>30){(0,n.warn)("Load test font never loaded."),k();return}if(y.font="30px "+C,y.fillText(".",0,20),y.getImageData(0,0,1,1).data[3]>0){k();return}setTimeout(m.bind(null,C,k))}const w=`lt${Date.now()}${this.loadTestFontId++}`;let R=this._loadTestFont;R=p(R,976,w.length,w);const S=16,F=1482184792;let A=u(R,S);for(g=0,f=w.length-3;g<f;g+=4)A=A-F+u(w,g)|0;g<w.length&&(A=A-F+u(w+"XXX",g)|0),R=p(R,S,4,(0,n.string32)(A));const D=`url(data:font/opentype;base64,${btoa(R)});`,T=`@font-face {font-family:"${w}";src:${D}}`;this.insertRule(T);const M=this._document.createElement("div");M.style.visibility="hidden",M.style.width=M.style.height="10px",M.style.position="absolute",M.style.top=M.style.left="0px";for(const C of[d.loadedName,w]){const k=this._document.createElement("span");k.textContent="Hi",k.style.fontFamily=C,M.append(k)}this._document.body.append(M),m(w,()=>{M.remove(),l.complete()})}}o=new WeakMap,e.FontLoader=a;class s{constructor(d,{isEvalSupported:l=!0,disableFontFace:u=!1,ignoreErrors:p=!1,inspectFont:g=null}){this.compiledGlyphs=Object.create(null);for(const f in d)this[f]=d[f];this.isEvalSupported=l!==!1,this.disableFontFace=u===!0,this.ignoreErrors=p===!0,this._inspectFont=g}createNativeFontFace(){var l;if(!this.data||this.disableFontFace)return null;let d;if(!this.cssFontInfo)d=new FontFace(this.loadedName,this.data,{});else{const u={weight:this.cssFontInfo.fontWeight};this.cssFontInfo.italicAngle&&(u.style=`oblique ${this.cssFontInfo.italicAngle}deg`),d=new FontFace(this.cssFontInfo.fontFamily,this.data,u)}return(l=this._inspectFont)==null||l.call(this,this),d}createFontFaceRule(){var p;if(!this.data||this.disableFontFace)return null;const d=(0,n.bytesToString)(this.data),l=`url(data:${this.mimetype};base64,${btoa(d)});`;let u;if(!this.cssFontInfo)u=`@font-face {font-family:"${this.loadedName}";src:${l}}`;else{let g=`font-weight: ${this.cssFontInfo.fontWeight};`;this.cssFontInfo.italicAngle&&(g+=`font-style: oblique ${this.cssFontInfo.italicAngle}deg;`),u=`@font-face {font-family:"${this.cssFontInfo.fontFamily}";${g}src:${l}}`}return(p=this._inspectFont)==null||p.call(this,this,l),u}getPathGenerator(d,l){if(this.compiledGlyphs[l]!==void 0)return this.compiledGlyphs[l];let u;try{u=d.get(this.loadedName+"_path_"+l)}catch(p){if(!this.ignoreErrors)throw p;return(0,n.warn)(`getPathGenerator - ignoring character: "${p}".`),this.compiledGlyphs[l]=function(g,f){}}if(this.isEvalSupported&&n.FeatureTest.isEvalSupported){const p=[];for(const g of u){const f=g.args!==void 0?g.args.join(","):"";p.push("c.",g.cmd,"(",f,`);
|
|
3
|
-
`)}return this.compiledGlyphs[l]=new Function("c","size",p.join(""))}return this.compiledGlyphs[l]=function(p,g){for(const f of u)f.cmd==="scale"&&(f.args=[g,-g]),p[f.cmd].apply(p,f.args)}}}e.FontFaceObject=s},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.NodeStandardFontDataFactory=e.NodeFilterFactory=e.NodeCanvasFactory=e.NodeCMapReaderFactory=void 0;var n=r(7);r(1);const a=function(l){return new Promise((u,p)=>{require$$5.readFile(l,(f,v)=>{if(f||!v){p(new Error(f));return}u(new Uint8Array(v))})})};class s extends n.BaseFilterFactory{}e.NodeFilterFactory=s;class o extends n.BaseCanvasFactory{_createCanvas(u,p){return require$$5.createCanvas(u,p)}}e.NodeCanvasFactory=o;class h extends n.BaseCMapReaderFactory{_fetchData(u,p){return a(u).then(g=>({cMapData:g,compressionType:p}))}}e.NodeCMapReaderFactory=h;class d extends n.BaseStandardFontDataFactory{_fetchData(u){return a(u)}}e.NodeStandardFontDataFactory=d},(t,e,r)=>{var se,Yt,Jt;Object.defineProperty(e,"__esModule",{value:!0}),e.CanvasGraphics=void 0;var n=r(1),a=r(6),s=r(12),o=r(13);const h=16,d=100,l=4096,u=15,p=10,g=1e3,f=16;function v(N,P){if(N._removeMirroring)throw new Error("Context is already forwarding operations.");N.__originalSave=N.save,N.__originalRestore=N.restore,N.__originalRotate=N.rotate,N.__originalScale=N.scale,N.__originalTranslate=N.translate,N.__originalTransform=N.transform,N.__originalSetTransform=N.setTransform,N.__originalResetTransform=N.resetTransform,N.__originalClip=N.clip,N.__originalMoveTo=N.moveTo,N.__originalLineTo=N.lineTo,N.__originalBezierCurveTo=N.bezierCurveTo,N.__originalRect=N.rect,N.__originalClosePath=N.closePath,N.__originalBeginPath=N.beginPath,N._removeMirroring=()=>{N.save=N.__originalSave,N.restore=N.__originalRestore,N.rotate=N.__originalRotate,N.scale=N.__originalScale,N.translate=N.__originalTranslate,N.transform=N.__originalTransform,N.setTransform=N.__originalSetTransform,N.resetTransform=N.__originalResetTransform,N.clip=N.__originalClip,N.moveTo=N.__originalMoveTo,N.lineTo=N.__originalLineTo,N.bezierCurveTo=N.__originalBezierCurveTo,N.rect=N.__originalRect,N.closePath=N.__originalClosePath,N.beginPath=N.__originalBeginPath,delete N._removeMirroring},N.save=function(){P.save(),this.__originalSave()},N.restore=function(){P.restore(),this.__originalRestore()},N.translate=function(I,z){P.translate(I,z),this.__originalTranslate(I,z)},N.scale=function(I,z){P.scale(I,z),this.__originalScale(I,z)},N.transform=function(I,z,G,H,ee,ce){P.transform(I,z,G,H,ee,ce),this.__originalTransform(I,z,G,H,ee,ce)},N.setTransform=function(I,z,G,H,ee,ce){P.setTransform(I,z,G,H,ee,ce),this.__originalSetTransform(I,z,G,H,ee,ce)},N.resetTransform=function(){P.resetTransform(),this.__originalResetTransform()},N.rotate=function(I){P.rotate(I),this.__originalRotate(I)},N.clip=function(I){P.clip(I),this.__originalClip(I)},N.moveTo=function(E,I){P.moveTo(E,I),this.__originalMoveTo(E,I)},N.lineTo=function(E,I){P.lineTo(E,I),this.__originalLineTo(E,I)},N.bezierCurveTo=function(E,I,z,G,H,ee){P.bezierCurveTo(E,I,z,G,H,ee),this.__originalBezierCurveTo(E,I,z,G,H,ee)},N.rect=function(E,I,z,G){P.rect(E,I,z,G),this.__originalRect(E,I,z,G)},N.closePath=function(){P.closePath(),this.__originalClosePath()},N.beginPath=function(){P.beginPath(),this.__originalBeginPath()}}class y{constructor(P){this.canvasFactory=P,this.cache=Object.create(null)}getCanvas(P,E,I){let z;return this.cache[P]!==void 0?(z=this.cache[P],this.canvasFactory.reset(z,E,I)):(z=this.canvasFactory.create(E,I),this.cache[P]=z),z}delete(P){delete this.cache[P]}clear(){for(const P in this.cache){const E=this.cache[P];this.canvasFactory.destroy(E),delete this.cache[P]}}}function x(N,P,E,I,z,G,H,ee,ce,ve){const[me,xe,Se,Ce,ne,le]=(0,a.getCurrentTransform)(N);if(xe===0&&Se===0){const re=H*me+ne,he=Math.round(re),ye=ee*Ce+le,Fe=Math.round(ye),Pe=(H+ce)*me+ne,ie=Math.abs(Math.round(Pe)-he)||1,_e=(ee+ve)*Ce+le,Te=Math.abs(Math.round(_e)-Fe)||1;return N.setTransform(Math.sign(me),0,0,Math.sign(Ce),he,Fe),N.drawImage(P,E,I,z,G,0,0,ie,Te),N.setTransform(me,xe,Se,Ce,ne,le),[ie,Te]}if(me===0&&Ce===0){const re=ee*Se+ne,he=Math.round(re),ye=H*xe+le,Fe=Math.round(ye),Pe=(ee+ve)*Se+ne,ie=Math.abs(Math.round(Pe)-he)||1,_e=(H+ce)*xe+le,Te=Math.abs(Math.round(_e)-Fe)||1;return N.setTransform(0,Math.sign(xe),Math.sign(Se),0,he,Fe),N.drawImage(P,E,I,z,G,0,0,Te,ie),N.setTransform(me,xe,Se,Ce,ne,le),[Te,ie]}N.drawImage(P,E,I,z,G,H,ee,ce,ve);const L=Math.hypot(me,xe),Z=Math.hypot(Se,Ce);return[L*ce,Z*ve]}function m(N){const{width:P,height:E}=N;if(P>g||E>g)return null;const I=1e3,z=new Uint8Array([0,2,4,0,1,0,5,4,8,10,0,8,0,2,1,0]),G=P+1;let H=new Uint8Array(G*(E+1)),ee,ce,ve;const me=P+7&-8;let xe=new Uint8Array(me*E),Se=0;for(const Z of N.data){let re=128;for(;re>0;)xe[Se++]=Z&re?0:255,re>>=1}let Ce=0;for(Se=0,xe[Se]!==0&&(H[0]=1,++Ce),ce=1;ce<P;ce++)xe[Se]!==xe[Se+1]&&(H[ce]=xe[Se]?2:1,++Ce),Se++;for(xe[Se]!==0&&(H[ce]=2,++Ce),ee=1;ee<E;ee++){Se=ee*me,ve=ee*G,xe[Se-me]!==xe[Se]&&(H[ve]=xe[Se]?1:8,++Ce);let Z=(xe[Se]?4:0)+(xe[Se-me]?8:0);for(ce=1;ce<P;ce++)Z=(Z>>2)+(xe[Se+1]?4:0)+(xe[Se-me+1]?8:0),z[Z]&&(H[ve+ce]=z[Z],++Ce),Se++;if(xe[Se-me]!==xe[Se]&&(H[ve+ce]=xe[Se]?2:4,++Ce),Ce>I)return null}for(Se=me*(E-1),ve=ee*G,xe[Se]!==0&&(H[ve]=8,++Ce),ce=1;ce<P;ce++)xe[Se]!==xe[Se+1]&&(H[ve+ce]=xe[Se]?4:8,++Ce),Se++;if(xe[Se]!==0&&(H[ve+ce]=4,++Ce),Ce>I)return null;const ne=new Int32Array([0,G,-1,0,-G,0,0,0,1]),le=new Path2D;for(ee=0;Ce&&ee<=E;ee++){let Z=ee*G;const re=Z+P;for(;Z<re&&!H[Z];)Z++;if(Z===re)continue;le.moveTo(Z%G,ee);const he=Z;let ye=H[Z];do{const Fe=ne[ye];do Z+=Fe;while(!H[Z]);const Pe=H[Z];Pe!==5&&Pe!==10?(ye=Pe,H[Z]=0):(ye=Pe&51*ye>>4,H[Z]&=ye>>2|ye<<2),le.lineTo(Z%G,Z/G|0),H[Z]||--Ce}while(he!==Z);--ee}return xe=null,H=null,function(Z){Z.save(),Z.scale(1/P,-1/E),Z.translate(0,-E),Z.fill(le),Z.beginPath(),Z.restore()}}class w{constructor(P,E){this.alphaIsShape=!1,this.fontSize=0,this.fontSizeScale=1,this.textMatrix=n.IDENTITY_MATRIX,this.textMatrixScale=1,this.fontMatrix=n.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=n.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="none",this.startNewPathAndClipBox([0,0,P,E])}clone(){const P=Object.create(this);return P.clipBox=this.clipBox.slice(),P}setCurrentPoint(P,E){this.x=P,this.y=E}updatePathMinMax(P,E,I){[E,I]=n.Util.applyTransform([E,I],P),this.minX=Math.min(this.minX,E),this.minY=Math.min(this.minY,I),this.maxX=Math.max(this.maxX,E),this.maxY=Math.max(this.maxY,I)}updateRectMinMax(P,E){const I=n.Util.applyTransform(E,P),z=n.Util.applyTransform(E.slice(2),P);this.minX=Math.min(this.minX,I[0],z[0]),this.minY=Math.min(this.minY,I[1],z[1]),this.maxX=Math.max(this.maxX,I[0],z[0]),this.maxY=Math.max(this.maxY,I[1],z[1])}updateScalingPathMinMax(P,E){n.Util.scaleMinMax(P,E),this.minX=Math.min(this.minX,E[0]),this.maxX=Math.max(this.maxX,E[1]),this.minY=Math.min(this.minY,E[2]),this.maxY=Math.max(this.maxY,E[3])}updateCurvePathMinMax(P,E,I,z,G,H,ee,ce,ve,me){const xe=n.Util.bezierBoundingBox(E,I,z,G,H,ee,ce,ve);if(me){me[0]=Math.min(me[0],xe[0],xe[2]),me[1]=Math.max(me[1],xe[0],xe[2]),me[2]=Math.min(me[2],xe[1],xe[3]),me[3]=Math.max(me[3],xe[1],xe[3]);return}this.updateRectMinMax(P,xe)}getPathBoundingBox(P=s.PathType.FILL,E=null){const I=[this.minX,this.minY,this.maxX,this.maxY];if(P===s.PathType.STROKE){E||(0,n.unreachable)("Stroke bounding box must include transform.");const z=n.Util.singularValueDecompose2dScale(E),G=z[0]*this.lineWidth/2,H=z[1]*this.lineWidth/2;I[0]-=G,I[1]-=H,I[2]+=G,I[3]+=H}return I}updateClipFromPath(){const P=n.Util.intersect(this.clipBox,this.getPathBoundingBox());this.startNewPathAndClipBox(P||[0,0,0,0])}isEmptyClip(){return this.minX===1/0}startNewPathAndClipBox(P){this.clipBox=P,this.minX=1/0,this.minY=1/0,this.maxX=0,this.maxY=0}getClippedPathBoundingBox(P=s.PathType.FILL,E=null){return n.Util.intersect(this.clipBox,this.getPathBoundingBox(P,E))}}function R(N,P){if(typeof ImageData<"u"&&P instanceof ImageData){N.putImageData(P,0,0);return}const E=P.height,I=P.width,z=E%f,G=(E-z)/f,H=z===0?G:G+1,ee=N.createImageData(I,f);let ce=0,ve;const me=P.data,xe=ee.data;let Se,Ce,ne,le;if(P.kind===n.ImageKind.GRAYSCALE_1BPP){const L=me.byteLength,Z=new Uint32Array(xe.buffer,0,xe.byteLength>>2),re=Z.length,he=I+7>>3,ye=4294967295,Fe=n.FeatureTest.isLittleEndian?4278190080:255;for(Se=0;Se<H;Se++){for(ne=Se<G?f:z,ve=0,Ce=0;Ce<ne;Ce++){const Pe=L-ce;let ie=0;const _e=Pe>he?I:Pe*8-7,Te=_e&-8;let Ke=0,qe=0;for(;ie<Te;ie+=8)qe=me[ce++],Z[ve++]=qe&128?ye:Fe,Z[ve++]=qe&64?ye:Fe,Z[ve++]=qe&32?ye:Fe,Z[ve++]=qe&16?ye:Fe,Z[ve++]=qe&8?ye:Fe,Z[ve++]=qe&4?ye:Fe,Z[ve++]=qe&2?ye:Fe,Z[ve++]=qe&1?ye:Fe;for(;ie<_e;ie++)Ke===0&&(qe=me[ce++],Ke=128),Z[ve++]=qe&Ke?ye:Fe,Ke>>=1}for(;ve<re;)Z[ve++]=0;N.putImageData(ee,0,Se*f)}}else if(P.kind===n.ImageKind.RGBA_32BPP){for(Ce=0,le=I*f*4,Se=0;Se<G;Se++)xe.set(me.subarray(ce,ce+le)),ce+=le,N.putImageData(ee,0,Ce),Ce+=f;Se<H&&(le=I*z*4,xe.set(me.subarray(ce,ce+le)),N.putImageData(ee,0,Ce))}else if(P.kind===n.ImageKind.RGB_24BPP)for(ne=f,le=I*ne,Se=0;Se<H;Se++){for(Se>=G&&(ne=z,le=I*ne),ve=0,Ce=le;Ce--;)xe[ve++]=me[ce++],xe[ve++]=me[ce++],xe[ve++]=me[ce++],xe[ve++]=255;N.putImageData(ee,0,Se*f)}else throw new Error(`bad image kind: ${P.kind}`)}function _(N,P){if(P.bitmap){N.drawImage(P.bitmap,0,0);return}const E=P.height,I=P.width,z=E%f,G=(E-z)/f,H=z===0?G:G+1,ee=N.createImageData(I,f);let ce=0;const ve=P.data,me=ee.data;for(let xe=0;xe<H;xe++){const Se=xe<G?f:z;({srcPos:ce}=(0,o.convertBlackAndWhiteToRGBA)({src:ve,srcPos:ce,dest:me,width:I,height:Se,nonBlackColor:0})),N.putImageData(ee,0,xe*f)}}function S(N,P){const E=["strokeStyle","fillStyle","fillRule","globalAlpha","lineWidth","lineCap","lineJoin","miterLimit","globalCompositeOperation","font","filter"];for(const I of E)N[I]!==void 0&&(P[I]=N[I]);N.setLineDash!==void 0&&(P.setLineDash(N.getLineDash()),P.lineDashOffset=N.lineDashOffset)}function F(N){if(N.strokeStyle=N.fillStyle="#000000",N.fillRule="nonzero",N.globalAlpha=1,N.lineWidth=1,N.lineCap="butt",N.lineJoin="miter",N.miterLimit=10,N.globalCompositeOperation="source-over",N.font="10px sans-serif",N.setLineDash!==void 0&&(N.setLineDash([]),N.lineDashOffset=0),!n.isNodeJS){const{filter:P}=N;P!=="none"&&P!==""&&(N.filter="none")}}function A(N,P,E,I){const z=N.length;for(let G=3;G<z;G+=4){const H=N[G];if(H===0)N[G-3]=P,N[G-2]=E,N[G-1]=I;else if(H<255){const ee=255-H;N[G-3]=N[G-3]*H+P*ee>>8,N[G-2]=N[G-2]*H+E*ee>>8,N[G-1]=N[G-1]*H+I*ee>>8}}}function D(N,P,E){const I=N.length,z=1/255;for(let G=3;G<I;G+=4){const H=E?E[N[G]]:N[G];P[G]=P[G]*H*z|0}}function T(N,P,E){const I=N.length;for(let z=3;z<I;z+=4){const G=N[z-3]*77+N[z-2]*152+N[z-1]*28;P[z]=E?P[z]*E[G>>8]>>8:P[z]*G>>16}}function M(N,P,E,I,z,G,H,ee,ce,ve,me){const xe=!!G,Se=xe?G[0]:0,Ce=xe?G[1]:0,ne=xe?G[2]:0,le=z==="Luminosity"?T:D,Z=Math.min(I,Math.ceil(1048576/E));for(let re=0;re<I;re+=Z){const he=Math.min(Z,I-re),ye=N.getImageData(ee-ve,re+(ce-me),E,he),Fe=P.getImageData(ee,re+ce,E,he);xe&&A(ye.data,Se,Ce,ne),le(ye.data,Fe.data,H),P.putImageData(Fe,ee,re+ce)}}function C(N,P,E,I){const z=I[0],G=I[1],H=I[2]-z,ee=I[3]-G;H===0||ee===0||(M(P.context,E,H,ee,P.subtype,P.backdrop,P.transferMap,z,G,P.offsetX,P.offsetY),N.save(),N.globalAlpha=1,N.globalCompositeOperation="source-over",N.setTransform(1,0,0,1,0,0),N.drawImage(E.canvas,0,0),N.restore())}function k(N,P){const E=n.Util.singularValueDecompose2dScale(N);E[0]=Math.fround(E[0]),E[1]=Math.fround(E[1]);const I=Math.fround((globalThis.devicePixelRatio||1)*a.PixelsPerInch.PDF_TO_CSS_UNITS);return P!==void 0?P:E[0]<=I||E[1]<=I}const O=["butt","round","square"],$=["miter","round","bevel"],K={},J={},Q=class Q{constructor(P,E,I,z,G,{optionalContentConfig:H,markedContentStack:ee=null},ce,ve){de(this,se);this.ctx=P,this.current=new w(this.ctx.canvas.width,this.ctx.canvas.height),this.stateStack=[],this.pendingClip=null,this.pendingEOFill=!1,this.res=null,this.xobjs=null,this.commonObjs=E,this.objs=I,this.canvasFactory=z,this.filterFactory=G,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=ee||[],this.optionalContentConfig=H,this.cachedCanvases=new y(this.canvasFactory),this.cachedPatterns=new Map,this.annotationCanvasMap=ce,this.viewportScale=1,this.outputScaleX=1,this.outputScaleY=1,this.pageColors=ve,this._cachedScaleForStroking=[-1,0],this._cachedGetSinglePixelWidth=null,this._cachedBitmapsMap=new Map}getObject(P,E=null){return typeof P=="string"?P.startsWith("g_")?this.commonObjs.get(P):this.objs.get(P):E}beginDrawing({transform:P,viewport:E,transparency:I=!1,background:z=null}){const G=this.ctx.canvas.width,H=this.ctx.canvas.height,ee=this.ctx.fillStyle;if(this.ctx.fillStyle=z||"#ffffff",this.ctx.fillRect(0,0,G,H),this.ctx.fillStyle=ee,I){const ce=this.cachedCanvases.getCanvas("transparent",G,H);this.compositeCtx=this.ctx,this.transparentCanvas=ce.canvas,this.ctx=ce.context,this.ctx.save(),this.ctx.transform(...(0,a.getCurrentTransform)(this.compositeCtx))}this.ctx.save(),F(this.ctx),P&&(this.ctx.transform(...P),this.outputScaleX=P[0],this.outputScaleY=P[0]),this.ctx.transform(...E.transform),this.viewportScale=E.scale,this.baseTransform=(0,a.getCurrentTransform)(this.ctx)}executeOperatorList(P,E,I,z){const G=P.argsArray,H=P.fnArray;let ee=E||0;const ce=G.length;if(ce===ee)return ee;const ve=ce-ee>p&&typeof I=="function",me=ve?Date.now()+u:0;let xe=0;const Se=this.commonObjs,Ce=this.objs;let ne;for(;;){if(z!==void 0&&ee===z.nextBreakPoint)return z.breakIt(ee,I),ee;if(ne=H[ee],ne!==n.OPS.dependency)this[ne].apply(this,G[ee]);else for(const le of G[ee]){const L=le.startsWith("g_")?Se:Ce;if(!L.has(le))return L.get(le,I),ee}if(ee++,ee===ce)return ee;if(ve&&++xe>p){if(Date.now()>me)return I(),ee;xe=0}}}endDrawing(){te(this,se,Yt).call(this),this.cachedCanvases.clear(),this.cachedPatterns.clear();for(const P of this._cachedBitmapsMap.values()){for(const E of P.values())typeof HTMLCanvasElement<"u"&&E instanceof HTMLCanvasElement&&(E.width=E.height=0);P.clear()}this._cachedBitmapsMap.clear(),te(this,se,Jt).call(this)}_scaleImage(P,E){const I=P.width,z=P.height;let G=Math.max(Math.hypot(E[0],E[1]),1),H=Math.max(Math.hypot(E[2],E[3]),1),ee=I,ce=z,ve="prescale1",me,xe;for(;G>2&&ee>1||H>2&&ce>1;){let Se=ee,Ce=ce;G>2&&ee>1&&(Se=ee>=16384?Math.floor(ee/2)-1||1:Math.ceil(ee/2),G/=ee/Se),H>2&&ce>1&&(Ce=ce>=16384?Math.floor(ce/2)-1||1:Math.ceil(ce)/2,H/=ce/Ce),me=this.cachedCanvases.getCanvas(ve,Se,Ce),xe=me.context,xe.clearRect(0,0,Se,Ce),xe.drawImage(P,0,0,ee,ce,0,0,Se,Ce),P=me.canvas,ee=Se,ce=Ce,ve=ve==="prescale1"?"prescale2":"prescale1"}return{img:P,paintWidth:ee,paintHeight:ce}}_createMaskCanvas(P){const E=this.ctx,{width:I,height:z}=P,G=this.current.fillColor,H=this.current.patternFill,ee=(0,a.getCurrentTransform)(E);let ce,ve,me,xe;if((P.bitmap||P.data)&&P.count>1){const ie=P.bitmap||P.data.buffer;ve=JSON.stringify(H?ee:[ee.slice(0,4),G]),ce=this._cachedBitmapsMap.get(ie),ce||(ce=new Map,this._cachedBitmapsMap.set(ie,ce));const _e=ce.get(ve);if(_e&&!H){const Te=Math.round(Math.min(ee[0],ee[2])+ee[4]),Ke=Math.round(Math.min(ee[1],ee[3])+ee[5]);return{canvas:_e,offsetX:Te,offsetY:Ke}}me=_e}me||(xe=this.cachedCanvases.getCanvas("maskCanvas",I,z),_(xe.context,P));let Se=n.Util.transform(ee,[1/I,0,0,-1/z,0,0]);Se=n.Util.transform(Se,[1,0,0,1,0,-z]);const Ce=n.Util.applyTransform([0,0],Se),ne=n.Util.applyTransform([I,z],Se),le=n.Util.normalizeRect([Ce[0],Ce[1],ne[0],ne[1]]),L=Math.round(le[2]-le[0])||1,Z=Math.round(le[3]-le[1])||1,re=this.cachedCanvases.getCanvas("fillCanvas",L,Z),he=re.context,ye=Math.min(Ce[0],ne[0]),Fe=Math.min(Ce[1],ne[1]);he.translate(-ye,-Fe),he.transform(...Se),me||(me=this._scaleImage(xe.canvas,(0,a.getCurrentTransformInverse)(he)),me=me.img,ce&&H&&ce.set(ve,me)),he.imageSmoothingEnabled=k((0,a.getCurrentTransform)(he),P.interpolate),x(he,me,0,0,me.width,me.height,0,0,I,z),he.globalCompositeOperation="source-in";const Pe=n.Util.transform((0,a.getCurrentTransformInverse)(he),[1,0,0,1,-ye,-Fe]);return he.fillStyle=H?G.getPattern(E,this,Pe,s.PathType.FILL):G,he.fillRect(0,0,I,z),ce&&!H&&(this.cachedCanvases.delete("fillCanvas"),ce.set(ve,re.canvas)),{canvas:re.canvas,offsetX:Math.round(ye),offsetY:Math.round(Fe)}}setLineWidth(P){P!==this.current.lineWidth&&(this._cachedScaleForStroking[0]=-1),this.current.lineWidth=P,this.ctx.lineWidth=P}setLineCap(P){this.ctx.lineCap=O[P]}setLineJoin(P){this.ctx.lineJoin=$[P]}setMiterLimit(P){this.ctx.miterLimit=P}setDash(P,E){const I=this.ctx;I.setLineDash!==void 0&&(I.setLineDash(P),I.lineDashOffset=E)}setRenderingIntent(P){}setFlatness(P){}setGState(P){for(const[E,I]of P)switch(E){case"LW":this.setLineWidth(I);break;case"LC":this.setLineCap(I);break;case"LJ":this.setLineJoin(I);break;case"ML":this.setMiterLimit(I);break;case"D":this.setDash(I[0],I[1]);break;case"RI":this.setRenderingIntent(I);break;case"FL":this.setFlatness(I);break;case"Font":this.setFont(I[0],I[1]);break;case"CA":this.current.strokeAlpha=I;break;case"ca":this.current.fillAlpha=I,this.ctx.globalAlpha=I;break;case"BM":this.ctx.globalCompositeOperation=I;break;case"SMask":this.current.activeSMask=I?this.tempSMask:null,this.tempSMask=null,this.checkSMaskState();break;case"TR":this.ctx.filter=this.current.transferMaps=this.filterFactory.addFilter(I);break}}get inSMaskMode(){return!!this.suspendedCtx}checkSMaskState(){const P=this.inSMaskMode;this.current.activeSMask&&!P?this.beginSMaskMode():!this.current.activeSMask&&P&&this.endSMaskMode()}beginSMaskMode(){if(this.inSMaskMode)throw new Error("beginSMaskMode called while already in smask mode");const P=this.ctx.canvas.width,E=this.ctx.canvas.height,I="smaskGroupAt"+this.groupLevel,z=this.cachedCanvases.getCanvas(I,P,E);this.suspendedCtx=this.ctx,this.ctx=z.context;const G=this.ctx;G.setTransform(...(0,a.getCurrentTransform)(this.suspendedCtx)),S(this.suspendedCtx,G),v(G,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(),S(this.ctx,this.suspendedCtx),this.ctx=this.suspendedCtx,this.suspendedCtx=null}compose(P){if(!this.current.activeSMask)return;P?(P[0]=Math.floor(P[0]),P[1]=Math.floor(P[1]),P[2]=Math.ceil(P[2]),P[3]=Math.ceil(P[3])):P=[0,0,this.ctx.canvas.width,this.ctx.canvas.height];const E=this.current.activeSMask,I=this.suspendedCtx;C(I,E,this.ctx,P),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?(S(this.ctx,this.suspendedCtx),this.suspendedCtx.save()):this.ctx.save();const P=this.current;this.stateStack.push(P),this.current=P.clone()}restore(){this.stateStack.length===0&&this.inSMaskMode&&this.endSMaskMode(),this.stateStack.length!==0&&(this.current=this.stateStack.pop(),this.inSMaskMode?(this.suspendedCtx.restore(),S(this.suspendedCtx,this.ctx)):this.ctx.restore(),this.checkSMaskState(),this.pendingClip=null,this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null)}transform(P,E,I,z,G,H){this.ctx.transform(P,E,I,z,G,H),this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null}constructPath(P,E,I){const z=this.ctx,G=this.current;let H=G.x,ee=G.y,ce,ve;const me=(0,a.getCurrentTransform)(z),xe=me[0]===0&&me[3]===0||me[1]===0&&me[2]===0,Se=xe?I.slice(0):null;for(let Ce=0,ne=0,le=P.length;Ce<le;Ce++)switch(P[Ce]|0){case n.OPS.rectangle:H=E[ne++],ee=E[ne++];const L=E[ne++],Z=E[ne++],re=H+L,he=ee+Z;z.moveTo(H,ee),L===0||Z===0?z.lineTo(re,he):(z.lineTo(re,ee),z.lineTo(re,he),z.lineTo(H,he)),xe||G.updateRectMinMax(me,[H,ee,re,he]),z.closePath();break;case n.OPS.moveTo:H=E[ne++],ee=E[ne++],z.moveTo(H,ee),xe||G.updatePathMinMax(me,H,ee);break;case n.OPS.lineTo:H=E[ne++],ee=E[ne++],z.lineTo(H,ee),xe||G.updatePathMinMax(me,H,ee);break;case n.OPS.curveTo:ce=H,ve=ee,H=E[ne+4],ee=E[ne+5],z.bezierCurveTo(E[ne],E[ne+1],E[ne+2],E[ne+3],H,ee),G.updateCurvePathMinMax(me,ce,ve,E[ne],E[ne+1],E[ne+2],E[ne+3],H,ee,Se),ne+=6;break;case n.OPS.curveTo2:ce=H,ve=ee,z.bezierCurveTo(H,ee,E[ne],E[ne+1],E[ne+2],E[ne+3]),G.updateCurvePathMinMax(me,ce,ve,H,ee,E[ne],E[ne+1],E[ne+2],E[ne+3],Se),H=E[ne+2],ee=E[ne+3],ne+=4;break;case n.OPS.curveTo3:ce=H,ve=ee,H=E[ne+2],ee=E[ne+3],z.bezierCurveTo(E[ne],E[ne+1],H,ee,H,ee),G.updateCurvePathMinMax(me,ce,ve,E[ne],E[ne+1],H,ee,H,ee,Se),ne+=4;break;case n.OPS.closePath:z.closePath();break}xe&&G.updateScalingPathMinMax(me,Se),G.setCurrentPoint(H,ee)}closePath(){this.ctx.closePath()}stroke(P=!0){const E=this.ctx,I=this.current.strokeColor;E.globalAlpha=this.current.strokeAlpha,this.contentVisible&&(typeof I=="object"&&(I!=null&&I.getPattern)?(E.save(),E.strokeStyle=I.getPattern(E,this,(0,a.getCurrentTransformInverse)(E),s.PathType.STROKE),this.rescaleAndStroke(!1),E.restore()):this.rescaleAndStroke(!0)),P&&this.consumePath(this.current.getClippedPathBoundingBox()),E.globalAlpha=this.current.fillAlpha}closeStroke(){this.closePath(),this.stroke()}fill(P=!0){const E=this.ctx,I=this.current.fillColor,z=this.current.patternFill;let G=!1;z&&(E.save(),E.fillStyle=I.getPattern(E,this,(0,a.getCurrentTransformInverse)(E),s.PathType.FILL),G=!0);const H=this.current.getClippedPathBoundingBox();this.contentVisible&&H!==null&&(this.pendingEOFill?(E.fill("evenodd"),this.pendingEOFill=!1):E.fill()),G&&E.restore(),P&&this.consumePath(H)}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=J}beginText(){this.current.textMatrix=n.IDENTITY_MATRIX,this.current.textMatrixScale=1,this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0}endText(){const P=this.pendingTextPaths,E=this.ctx;if(P===void 0){E.beginPath();return}E.save(),E.beginPath();for(const I of P)E.setTransform(...I.transform),E.translate(I.x,I.y),I.addToPath(E,I.fontSize);E.restore(),E.clip(),E.beginPath(),delete this.pendingTextPaths}setCharSpacing(P){this.current.charSpacing=P}setWordSpacing(P){this.current.wordSpacing=P}setHScale(P){this.current.textHScale=P/100}setLeading(P){this.current.leading=-P}setFont(P,E){var me;const I=this.commonObjs.get(P),z=this.current;if(!I)throw new Error(`Can't find font for ${P}`);if(z.fontMatrix=I.fontMatrix||n.FONT_IDENTITY_MATRIX,(z.fontMatrix[0]===0||z.fontMatrix[3]===0)&&(0,n.warn)("Invalid font matrix for font "+P),E<0?(E=-E,z.fontDirection=-1):z.fontDirection=1,this.current.font=I,this.current.fontSize=E,I.isType3Font)return;const G=I.loadedName||"sans-serif",H=((me=I.systemFontInfo)==null?void 0:me.css)||`"${G}", ${I.fallbackName}`;let ee="normal";I.black?ee="900":I.bold&&(ee="bold");const ce=I.italic?"italic":"normal";let ve=E;E<h?ve=h:E>d&&(ve=d),this.current.fontSizeScale=E/ve,this.ctx.font=`${ce} ${ee} ${ve}px ${H}`}setTextRenderingMode(P){this.current.textRenderingMode=P}setTextRise(P){this.current.textRise=P}moveText(P,E){this.current.x=this.current.lineX+=P,this.current.y=this.current.lineY+=E}setLeadingMoveText(P,E){this.setLeading(-E),this.moveText(P,E)}setTextMatrix(P,E,I,z,G,H){this.current.textMatrix=[P,E,I,z,G,H],this.current.textMatrixScale=Math.hypot(P,E),this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0}nextLine(){this.moveText(0,this.current.leading)}paintChar(P,E,I,z){const G=this.ctx,H=this.current,ee=H.font,ce=H.textRenderingMode,ve=H.fontSize/H.fontSizeScale,me=ce&n.TextRenderingMode.FILL_STROKE_MASK,xe=!!(ce&n.TextRenderingMode.ADD_TO_PATH_FLAG),Se=H.patternFill&&!ee.missingFile;let Ce;(ee.disableFontFace||xe||Se)&&(Ce=ee.getPathGenerator(this.commonObjs,P)),ee.disableFontFace||Se?(G.save(),G.translate(E,I),G.beginPath(),Ce(G,ve),z&&G.setTransform(...z),(me===n.TextRenderingMode.FILL||me===n.TextRenderingMode.FILL_STROKE)&&G.fill(),(me===n.TextRenderingMode.STROKE||me===n.TextRenderingMode.FILL_STROKE)&&G.stroke(),G.restore()):((me===n.TextRenderingMode.FILL||me===n.TextRenderingMode.FILL_STROKE)&&G.fillText(P,E,I),(me===n.TextRenderingMode.STROKE||me===n.TextRenderingMode.FILL_STROKE)&&G.strokeText(P,E,I)),xe&&(this.pendingTextPaths||(this.pendingTextPaths=[])).push({transform:(0,a.getCurrentTransform)(G),x:E,y:I,fontSize:ve,addToPath:Ce})}get isFontSubpixelAAEnabled(){const{context:P}=this.cachedCanvases.getCanvas("isFontSubpixelAAEnabled",10,10);P.scale(1.5,1),P.fillText("I",0,10);const E=P.getImageData(0,0,10,10).data;let I=!1;for(let z=3;z<E.length;z+=4)if(E[z]>0&&E[z]<255){I=!0;break}return(0,n.shadow)(this,"isFontSubpixelAAEnabled",I)}showText(P){const E=this.current,I=E.font;if(I.isType3Font)return this.showType3Text(P);const z=E.fontSize;if(z===0)return;const G=this.ctx,H=E.fontSizeScale,ee=E.charSpacing,ce=E.wordSpacing,ve=E.fontDirection,me=E.textHScale*ve,xe=P.length,Se=I.vertical,Ce=Se?1:-1,ne=I.defaultVMetrics,le=z*E.fontMatrix[0],L=E.textRenderingMode===n.TextRenderingMode.FILL&&!I.disableFontFace&&!E.patternFill;G.save(),G.transform(...E.textMatrix),G.translate(E.x,E.y+E.textRise),ve>0?G.scale(me,-1):G.scale(me,1);let Z;if(E.patternFill){G.save();const Pe=E.fillColor.getPattern(G,this,(0,a.getCurrentTransformInverse)(G),s.PathType.FILL);Z=(0,a.getCurrentTransform)(G),G.restore(),G.fillStyle=Pe}let re=E.lineWidth;const he=E.textMatrixScale;if(he===0||re===0){const Pe=E.textRenderingMode&n.TextRenderingMode.FILL_STROKE_MASK;(Pe===n.TextRenderingMode.STROKE||Pe===n.TextRenderingMode.FILL_STROKE)&&(re=this.getSinglePixelWidth())}else re/=he;if(H!==1&&(G.scale(H,H),re/=H),G.lineWidth=re,I.isInvalidPDFjsFont){const Pe=[];let ie=0;for(const _e of P)Pe.push(_e.unicode),ie+=_e.width;G.fillText(Pe.join(""),0,0),E.x+=ie*le*me,G.restore(),this.compose();return}let ye=0,Fe;for(Fe=0;Fe<xe;++Fe){const Pe=P[Fe];if(typeof Pe=="number"){ye+=Ce*Pe*z/1e3;continue}let ie=!1;const _e=(Pe.isSpace?ce:0)+ee,Te=Pe.fontChar,Ke=Pe.accent;let qe,Ye,Me=Pe.width;if(Se){const Ie=Pe.vmetric||ne,ze=-(Pe.vmetric?Ie[1]:Me*.5)*le,be=Ie[2]*le;Me=Ie?-Ie[0]:Me,qe=ze/H,Ye=(ye+be)/H}else qe=ye/H,Ye=0;if(I.remeasure&&Me>0){const Ie=G.measureText(Te).width*1e3/z*H;if(Me<Ie&&this.isFontSubpixelAAEnabled){const ze=Me/Ie;ie=!0,G.save(),G.scale(ze,1),qe/=ze}else Me!==Ie&&(qe+=(Me-Ie)/2e3*z/H)}if(this.contentVisible&&(Pe.isInFont||I.missingFile)){if(L&&!Ke)G.fillText(Te,qe,Ye);else if(this.paintChar(Te,qe,Ye,Z),Ke){const Ie=qe+z*Ke.offset.x/H,ze=Ye-z*Ke.offset.y/H;this.paintChar(Ke.fontChar,Ie,ze,Z)}}const Ee=Se?Me*le-_e*ve:Me*le+_e*ve;ye+=Ee,ie&&G.restore()}Se?E.y-=ye:E.x+=ye*me,G.restore(),this.compose()}showType3Text(P){const E=this.ctx,I=this.current,z=I.font,G=I.fontSize,H=I.fontDirection,ee=z.vertical?1:-1,ce=I.charSpacing,ve=I.wordSpacing,me=I.textHScale*H,xe=I.fontMatrix||n.FONT_IDENTITY_MATRIX,Se=P.length,Ce=I.textRenderingMode===n.TextRenderingMode.INVISIBLE;let ne,le,L,Z;if(!(Ce||G===0)){for(this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null,E.save(),E.transform(...I.textMatrix),E.translate(I.x,I.y),E.scale(me,H),ne=0;ne<Se;++ne){if(le=P[ne],typeof le=="number"){Z=ee*le*G/1e3,this.ctx.translate(Z,0),I.x+=Z*me;continue}const re=(le.isSpace?ve:0)+ce,he=z.charProcOperatorList[le.operatorListId];if(!he){(0,n.warn)(`Type3 character "${le.operatorListId}" is not available.`);continue}this.contentVisible&&(this.processingType3=le,this.save(),E.scale(G,G),E.transform(...xe),this.executeOperatorList(he),this.restore()),L=n.Util.applyTransform([le.width,0],xe)[0]*G+re,E.translate(L,0),I.x+=L*me}E.restore(),this.processingType3=null}}setCharWidth(P,E){}setCharWidthAndBounds(P,E,I,z,G,H){this.ctx.rect(I,z,G-I,H-z),this.ctx.clip(),this.endPath()}getColorN_Pattern(P){let E;if(P[0]==="TilingPattern"){const I=P[1],z=this.baseTransform||(0,a.getCurrentTransform)(this.ctx),G={createCanvasGraphics:H=>new Q(H,this.commonObjs,this.objs,this.canvasFactory,this.filterFactory,{optionalContentConfig:this.optionalContentConfig,markedContentStack:this.markedContentStack})};E=new s.TilingPattern(P,I,this.ctx,G,z)}else E=this._getPattern(P[1],P[2]);return E}setStrokeColorN(){this.current.strokeColor=this.getColorN_Pattern(arguments)}setFillColorN(){this.current.fillColor=this.getColorN_Pattern(arguments),this.current.patternFill=!0}setStrokeRGBColor(P,E,I){const z=n.Util.makeHexColor(P,E,I);this.ctx.strokeStyle=z,this.current.strokeColor=z}setFillRGBColor(P,E,I){const z=n.Util.makeHexColor(P,E,I);this.ctx.fillStyle=z,this.current.fillColor=z,this.current.patternFill=!1}_getPattern(P,E=null){let I;return this.cachedPatterns.has(P)?I=this.cachedPatterns.get(P):(I=(0,s.getShadingPattern)(this.getObject(P)),this.cachedPatterns.set(P,I)),E&&(I.matrix=E),I}shadingFill(P){if(!this.contentVisible)return;const E=this.ctx;this.save();const I=this._getPattern(P);E.fillStyle=I.getPattern(E,this,(0,a.getCurrentTransformInverse)(E),s.PathType.SHADING);const z=(0,a.getCurrentTransformInverse)(E);if(z){const{width:G,height:H}=E.canvas,[ee,ce,ve,me]=n.Util.getAxialAlignedBoundingBox([0,0,G,H],z);this.ctx.fillRect(ee,ce,ve-ee,me-ce)}else this.ctx.fillRect(-1e10,-1e10,2e10,2e10);this.compose(this.current.getClippedPathBoundingBox()),this.restore()}beginInlineImage(){(0,n.unreachable)("Should not call beginInlineImage")}beginImageData(){(0,n.unreachable)("Should not call beginImageData")}paintFormXObjectBegin(P,E){if(this.contentVisible&&(this.save(),this.baseTransformStack.push(this.baseTransform),Array.isArray(P)&&P.length===6&&this.transform(...P),this.baseTransform=(0,a.getCurrentTransform)(this.ctx),E)){const I=E[2]-E[0],z=E[3]-E[1];this.ctx.rect(E[0],E[1],I,z),this.current.updateRectMinMax((0,a.getCurrentTransform)(this.ctx),E),this.clip(),this.endPath()}}paintFormXObjectEnd(){this.contentVisible&&(this.restore(),this.baseTransform=this.baseTransformStack.pop())}beginGroup(P){if(!this.contentVisible)return;this.save(),this.inSMaskMode&&(this.endSMaskMode(),this.current.activeSMask=null);const E=this.ctx;P.isolated||(0,n.info)("TODO: Support non-isolated groups."),P.knockout&&(0,n.warn)("Knockout groups not supported.");const I=(0,a.getCurrentTransform)(E);if(P.matrix&&E.transform(...P.matrix),!P.bbox)throw new Error("Bounding box is required.");let z=n.Util.getAxialAlignedBoundingBox(P.bbox,(0,a.getCurrentTransform)(E));const G=[0,0,E.canvas.width,E.canvas.height];z=n.Util.intersect(z,G)||[0,0,0,0];const H=Math.floor(z[0]),ee=Math.floor(z[1]);let ce=Math.max(Math.ceil(z[2])-H,1),ve=Math.max(Math.ceil(z[3])-ee,1),me=1,xe=1;ce>l&&(me=ce/l,ce=l),ve>l&&(xe=ve/l,ve=l),this.current.startNewPathAndClipBox([0,0,ce,ve]);let Se="groupAt"+this.groupLevel;P.smask&&(Se+="_smask_"+this.smaskCounter++%2);const Ce=this.cachedCanvases.getCanvas(Se,ce,ve),ne=Ce.context;ne.scale(1/me,1/xe),ne.translate(-H,-ee),ne.transform(...I),P.smask?this.smaskStack.push({canvas:Ce.canvas,context:ne,offsetX:H,offsetY:ee,scaleX:me,scaleY:xe,subtype:P.smask.subtype,backdrop:P.smask.backdrop,transferMap:P.smask.transferMap||null,startTransformInverse:null}):(E.setTransform(1,0,0,1,0,0),E.translate(H,ee),E.scale(me,xe),E.save()),S(E,ne),this.ctx=ne,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(E),this.groupLevel++}endGroup(P){if(!this.contentVisible)return;this.groupLevel--;const E=this.ctx,I=this.groupStack.pop();if(this.ctx=I,this.ctx.imageSmoothingEnabled=!1,P.smask)this.tempSMask=this.smaskStack.pop(),this.restore();else{this.ctx.restore();const z=(0,a.getCurrentTransform)(this.ctx);this.restore(),this.ctx.save(),this.ctx.setTransform(...z);const G=n.Util.getAxialAlignedBoundingBox([0,0,E.canvas.width,E.canvas.height],z);this.ctx.drawImage(E.canvas,0,0),this.ctx.restore(),this.compose(G)}}beginAnnotation(P,E,I,z,G){if(te(this,se,Yt).call(this),F(this.ctx),this.ctx.save(),this.save(),this.baseTransform&&this.ctx.setTransform(...this.baseTransform),Array.isArray(E)&&E.length===4){const H=E[2]-E[0],ee=E[3]-E[1];if(G&&this.annotationCanvasMap){I=I.slice(),I[4]-=E[0],I[5]-=E[1],E=E.slice(),E[0]=E[1]=0,E[2]=H,E[3]=ee;const[ce,ve]=n.Util.singularValueDecompose2dScale((0,a.getCurrentTransform)(this.ctx)),{viewportScale:me}=this,xe=Math.ceil(H*this.outputScaleX*me),Se=Math.ceil(ee*this.outputScaleY*me);this.annotationCanvas=this.canvasFactory.create(xe,Se);const{canvas:Ce,context:ne}=this.annotationCanvas;this.annotationCanvasMap.set(P,Ce),this.annotationCanvas.savedCtx=this.ctx,this.ctx=ne,this.ctx.save(),this.ctx.setTransform(ce,0,0,-ve,0,ee*ve),F(this.ctx)}else F(this.ctx),this.ctx.rect(E[0],E[1],H,ee),this.ctx.clip(),this.endPath()}this.current=new w(this.ctx.canvas.width,this.ctx.canvas.height),this.transform(...I),this.transform(...z)}endAnnotation(){this.annotationCanvas&&(this.ctx.restore(),te(this,se,Jt).call(this),this.ctx=this.annotationCanvas.savedCtx,delete this.annotationCanvas.savedCtx,delete this.annotationCanvas)}paintImageMaskXObject(P){if(!this.contentVisible)return;const E=P.count;P=this.getObject(P.data,P),P.count=E;const I=this.ctx,z=this.processingType3;if(z&&(z.compiled===void 0&&(z.compiled=m(P)),z.compiled)){z.compiled(I);return}const G=this._createMaskCanvas(P),H=G.canvas;I.save(),I.setTransform(1,0,0,1,0,0),I.drawImage(H,G.offsetX,G.offsetY),I.restore(),this.compose()}paintImageMaskXObjectRepeat(P,E,I=0,z=0,G,H){if(!this.contentVisible)return;P=this.getObject(P.data,P);const ee=this.ctx;ee.save();const ce=(0,a.getCurrentTransform)(ee);ee.transform(E,I,z,G,0,0);const ve=this._createMaskCanvas(P);ee.setTransform(1,0,0,1,ve.offsetX-ce[4],ve.offsetY-ce[5]);for(let me=0,xe=H.length;me<xe;me+=2){const Se=n.Util.transform(ce,[E,I,z,G,H[me],H[me+1]]),[Ce,ne]=n.Util.applyTransform([0,0],Se);ee.drawImage(ve.canvas,Ce,ne)}ee.restore(),this.compose()}paintImageMaskXObjectGroup(P){if(!this.contentVisible)return;const E=this.ctx,I=this.current.fillColor,z=this.current.patternFill;for(const G of P){const{data:H,width:ee,height:ce,transform:ve}=G,me=this.cachedCanvases.getCanvas("maskCanvas",ee,ce),xe=me.context;xe.save();const Se=this.getObject(H,G);_(xe,Se),xe.globalCompositeOperation="source-in",xe.fillStyle=z?I.getPattern(xe,this,(0,a.getCurrentTransformInverse)(E),s.PathType.FILL):I,xe.fillRect(0,0,ee,ce),xe.restore(),E.save(),E.transform(...ve),E.scale(1,-1),x(E,me.canvas,0,0,ee,ce,0,-1,1,1),E.restore()}this.compose()}paintImageXObject(P){if(!this.contentVisible)return;const E=this.getObject(P);if(!E){(0,n.warn)("Dependent image isn't ready yet");return}this.paintInlineImageXObject(E)}paintImageXObjectRepeat(P,E,I,z){if(!this.contentVisible)return;const G=this.getObject(P);if(!G){(0,n.warn)("Dependent image isn't ready yet");return}const H=G.width,ee=G.height,ce=[];for(let ve=0,me=z.length;ve<me;ve+=2)ce.push({transform:[E,0,0,I,z[ve],z[ve+1]],x:0,y:0,w:H,h:ee});this.paintInlineImageXObjectGroup(G,ce)}applyTransferMapsToCanvas(P){return this.current.transferMaps!=="none"&&(P.filter=this.current.transferMaps,P.drawImage(P.canvas,0,0),P.filter="none"),P.canvas}applyTransferMapsToBitmap(P){if(this.current.transferMaps==="none")return P.bitmap;const{bitmap:E,width:I,height:z}=P,G=this.cachedCanvases.getCanvas("inlineImage",I,z),H=G.context;return H.filter=this.current.transferMaps,H.drawImage(E,0,0),H.filter="none",G.canvas}paintInlineImageXObject(P){if(!this.contentVisible)return;const E=P.width,I=P.height,z=this.ctx;if(this.save(),!n.isNodeJS){const{filter:ee}=z;ee!=="none"&&ee!==""&&(z.filter="none")}z.scale(1/E,-1/I);let G;if(P.bitmap)G=this.applyTransferMapsToBitmap(P);else if(typeof HTMLElement=="function"&&P instanceof HTMLElement||!P.data)G=P;else{const ce=this.cachedCanvases.getCanvas("inlineImage",E,I).context;R(ce,P),G=this.applyTransferMapsToCanvas(ce)}const H=this._scaleImage(G,(0,a.getCurrentTransformInverse)(z));z.imageSmoothingEnabled=k((0,a.getCurrentTransform)(z),P.interpolate),x(z,H.img,0,0,H.paintWidth,H.paintHeight,0,-I,E,I),this.compose(),this.restore()}paintInlineImageXObjectGroup(P,E){if(!this.contentVisible)return;const I=this.ctx;let z;if(P.bitmap)z=P.bitmap;else{const G=P.width,H=P.height,ce=this.cachedCanvases.getCanvas("inlineImage",G,H).context;R(ce,P),z=this.applyTransferMapsToCanvas(ce)}for(const G of E)I.save(),I.transform(...G.transform),I.scale(1,-1),x(I,z,G.x,G.y,G.w,G.h,0,-1,1,1),I.restore();this.compose()}paintSolidColorImageMask(){this.contentVisible&&(this.ctx.fillRect(0,0,1,1),this.compose())}markPoint(P){}markPointProps(P,E){}beginMarkedContent(P){this.markedContentStack.push({visible:!0})}beginMarkedContentProps(P,E){P==="OC"?this.markedContentStack.push({visible:this.optionalContentConfig.isVisible(E)}):this.markedContentStack.push({visible:!0}),this.contentVisible=this.isContentVisible()}endMarkedContent(){this.markedContentStack.pop(),this.contentVisible=this.isContentVisible()}beginCompat(){}endCompat(){}consumePath(P){const E=this.current.isEmptyClip();this.pendingClip&&this.current.updateClipFromPath(),this.pendingClip||this.compose(P);const I=this.ctx;this.pendingClip&&(E||(this.pendingClip===J?I.clip("evenodd"):I.clip()),this.pendingClip=null),this.current.startNewPathAndClipBox(this.current.clipBox),I.beginPath()}getSinglePixelWidth(){if(!this._cachedGetSinglePixelWidth){const P=(0,a.getCurrentTransform)(this.ctx);if(P[1]===0&&P[2]===0)this._cachedGetSinglePixelWidth=1/Math.min(Math.abs(P[0]),Math.abs(P[3]));else{const E=Math.abs(P[0]*P[3]-P[2]*P[1]),I=Math.hypot(P[0],P[2]),z=Math.hypot(P[1],P[3]);this._cachedGetSinglePixelWidth=Math.max(I,z)/E}}return this._cachedGetSinglePixelWidth}getScaleForStroking(){if(this._cachedScaleForStroking[0]===-1){const{lineWidth:P}=this.current,{a:E,b:I,c:z,d:G}=this.ctx.getTransform();let H,ee;if(I===0&&z===0){const ce=Math.abs(E),ve=Math.abs(G);if(ce===ve)if(P===0)H=ee=1/ce;else{const me=ce*P;H=ee=me<1?1/me:1}else if(P===0)H=1/ce,ee=1/ve;else{const me=ce*P,xe=ve*P;H=me<1?1/me:1,ee=xe<1?1/xe:1}}else{const ce=Math.abs(E*G-I*z),ve=Math.hypot(E,I),me=Math.hypot(z,G);if(P===0)H=me/ce,ee=ve/ce;else{const xe=P*ce;H=me>xe?me/xe:1,ee=ve>xe?ve/xe:1}}this._cachedScaleForStroking[0]=H,this._cachedScaleForStroking[1]=ee}return this._cachedScaleForStroking}rescaleAndStroke(P){const{ctx:E}=this,{lineWidth:I}=this.current,[z,G]=this.getScaleForStroking();if(E.lineWidth=I||1,z===1&&G===1){E.stroke();return}const H=E.getLineDash();if(P&&E.save(),E.scale(z,G),H.length>0){const ee=Math.max(z,G);E.setLineDash(H.map(ce=>ce/ee)),E.lineDashOffset/=ee}E.stroke(),P&&E.restore()}isContentVisible(){for(let P=this.markedContentStack.length-1;P>=0;P--)if(!this.markedContentStack[P].visible)return!1;return!0}};se=new WeakSet,Yt=function(){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)},Jt=function(){if(this.pageColors){const P=this.filterFactory.addHCMFilter(this.pageColors.foreground,this.pageColors.background);if(P!=="none"){const E=this.ctx.filter;this.ctx.filter=P,this.ctx.drawImage(this.ctx.canvas,0,0),this.ctx.filter=E}}};let Y=Q;e.CanvasGraphics=Y;for(const N in n.OPS)Y.prototype[N]!==void 0&&(Y.prototype[n.OPS[N]]=Y.prototype[N])},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.TilingPattern=e.PathType=void 0,e.getShadingPattern=f;var n=r(1),a=r(6);const s={FILL:"Fill",STROKE:"Stroke",SHADING:"Shading"};e.PathType=s;function o(m,w){if(!w)return;const R=w[2]-w[0],_=w[3]-w[1],S=new Path2D;S.rect(w[0],w[1],R,_),m.clip(S)}class h{constructor(){this.constructor===h&&(0,n.unreachable)("Cannot initialize BaseShadingPattern.")}getPattern(){(0,n.unreachable)("Abstract method `getPattern` called.")}}class d extends h{constructor(w){super(),this._type=w[1],this._bbox=w[2],this._colorStops=w[3],this._p0=w[4],this._p1=w[5],this._r0=w[6],this._r1=w[7],this.matrix=null}_createGradient(w){let R;this._type==="axial"?R=w.createLinearGradient(this._p0[0],this._p0[1],this._p1[0],this._p1[1]):this._type==="radial"&&(R=w.createRadialGradient(this._p0[0],this._p0[1],this._r0,this._p1[0],this._p1[1],this._r1));for(const _ of this._colorStops)R.addColorStop(_[0],_[1]);return R}getPattern(w,R,_,S){let F;if(S===s.STROKE||S===s.FILL){const A=R.current.getClippedPathBoundingBox(S,(0,a.getCurrentTransform)(w))||[0,0,0,0],D=Math.ceil(A[2]-A[0])||1,T=Math.ceil(A[3]-A[1])||1,M=R.cachedCanvases.getCanvas("pattern",D,T,!0),C=M.context;C.clearRect(0,0,C.canvas.width,C.canvas.height),C.beginPath(),C.rect(0,0,C.canvas.width,C.canvas.height),C.translate(-A[0],-A[1]),_=n.Util.transform(_,[1,0,0,1,A[0],A[1]]),C.transform(...R.baseTransform),this.matrix&&C.transform(...this.matrix),o(C,this._bbox),C.fillStyle=this._createGradient(C),C.fill(),F=w.createPattern(M.canvas,"no-repeat");const k=new DOMMatrix(_);F.setTransform(k)}else o(w,this._bbox),F=this._createGradient(w);return F}}function l(m,w,R,_,S,F,A,D){const T=w.coords,M=w.colors,C=m.data,k=m.width*4;let O;T[R+1]>T[_+1]&&(O=R,R=_,_=O,O=F,F=A,A=O),T[_+1]>T[S+1]&&(O=_,_=S,S=O,O=A,A=D,D=O),T[R+1]>T[_+1]&&(O=R,R=_,_=O,O=F,F=A,A=O);const $=(T[R]+w.offsetX)*w.scaleX,K=(T[R+1]+w.offsetY)*w.scaleY,J=(T[_]+w.offsetX)*w.scaleX,Y=(T[_+1]+w.offsetY)*w.scaleY,se=(T[S]+w.offsetX)*w.scaleX,B=(T[S+1]+w.offsetY)*w.scaleY;if(K>=B)return;const V=M[F],Q=M[F+1],N=M[F+2],P=M[A],E=M[A+1],I=M[A+2],z=M[D],G=M[D+1],H=M[D+2],ee=Math.round(K),ce=Math.round(B);let ve,me,xe,Se,Ce,ne,le,L;for(let Z=ee;Z<=ce;Z++){if(Z<Y){const Pe=Z<K?0:(K-Z)/(K-Y);ve=$-($-J)*Pe,me=V-(V-P)*Pe,xe=Q-(Q-E)*Pe,Se=N-(N-I)*Pe}else{let Pe;Z>B?Pe=1:Y===B?Pe=0:Pe=(Y-Z)/(Y-B),ve=J-(J-se)*Pe,me=P-(P-z)*Pe,xe=E-(E-G)*Pe,Se=I-(I-H)*Pe}let re;Z<K?re=0:Z>B?re=1:re=(K-Z)/(K-B),Ce=$-($-se)*re,ne=V-(V-z)*re,le=Q-(Q-G)*re,L=N-(N-H)*re;const he=Math.round(Math.min(ve,Ce)),ye=Math.round(Math.max(ve,Ce));let Fe=k*Z+he*4;for(let Pe=he;Pe<=ye;Pe++)re=(ve-Pe)/(ve-Ce),re<0?re=0:re>1&&(re=1),C[Fe++]=me-(me-ne)*re|0,C[Fe++]=xe-(xe-le)*re|0,C[Fe++]=Se-(Se-L)*re|0,C[Fe++]=255}}function u(m,w,R){const _=w.coords,S=w.colors;let F,A;switch(w.type){case"lattice":const D=w.verticesPerRow,T=Math.floor(_.length/D)-1,M=D-1;for(F=0;F<T;F++){let C=F*D;for(let k=0;k<M;k++,C++)l(m,R,_[C],_[C+1],_[C+D],S[C],S[C+1],S[C+D]),l(m,R,_[C+D+1],_[C+1],_[C+D],S[C+D+1],S[C+1],S[C+D])}break;case"triangles":for(F=0,A=_.length;F<A;F+=3)l(m,R,_[F],_[F+1],_[F+2],S[F],S[F+1],S[F+2]);break;default:throw new Error("illegal figure")}}class p extends h{constructor(w){super(),this._coords=w[2],this._colors=w[3],this._figures=w[4],this._bounds=w[5],this._bbox=w[7],this._background=w[8],this.matrix=null}_createMeshCanvas(w,R,_){const D=Math.floor(this._bounds[0]),T=Math.floor(this._bounds[1]),M=Math.ceil(this._bounds[2])-D,C=Math.ceil(this._bounds[3])-T,k=Math.min(Math.ceil(Math.abs(M*w[0]*1.1)),3e3),O=Math.min(Math.ceil(Math.abs(C*w[1]*1.1)),3e3),$=M/k,K=C/O,J={coords:this._coords,colors:this._colors,offsetX:-D,offsetY:-T,scaleX:1/$,scaleY:1/K},Y=k+2*2,se=O+2*2,B=_.getCanvas("mesh",Y,se,!1),V=B.context,Q=V.createImageData(k,O);if(R){const P=Q.data;for(let E=0,I=P.length;E<I;E+=4)P[E]=R[0],P[E+1]=R[1],P[E+2]=R[2],P[E+3]=255}for(const P of this._figures)u(Q,P,J);return V.putImageData(Q,2,2),{canvas:B.canvas,offsetX:D-2*$,offsetY:T-2*K,scaleX:$,scaleY:K}}getPattern(w,R,_,S){o(w,this._bbox);let F;if(S===s.SHADING)F=n.Util.singularValueDecompose2dScale((0,a.getCurrentTransform)(w));else if(F=n.Util.singularValueDecompose2dScale(R.baseTransform),this.matrix){const D=n.Util.singularValueDecompose2dScale(this.matrix);F=[F[0]*D[0],F[1]*D[1]]}const A=this._createMeshCanvas(F,S===s.SHADING?null:this._background,R.cachedCanvases);return S!==s.SHADING&&(w.setTransform(...R.baseTransform),this.matrix&&w.transform(...this.matrix)),w.translate(A.offsetX,A.offsetY),w.scale(A.scaleX,A.scaleY),w.createPattern(A.canvas,"no-repeat")}}class g extends h{getPattern(){return"hotpink"}}function f(m){switch(m[0]){case"RadialAxial":return new d(m);case"Mesh":return new p(m);case"Dummy":return new g}throw new Error(`Unknown IR type: ${m[0]}`)}const v={COLORED:1,UNCOLORED:2},x=class x{constructor(w,R,_,S,F){this.operatorList=w[2],this.matrix=w[3]||[1,0,0,1,0,0],this.bbox=w[4],this.xstep=w[5],this.ystep=w[6],this.paintType=w[7],this.tilingType=w[8],this.color=R,this.ctx=_,this.canvasGraphicsFactory=S,this.baseTransform=F}createPatternCanvas(w){const R=this.operatorList,_=this.bbox,S=this.xstep,F=this.ystep,A=this.paintType,D=this.tilingType,T=this.color,M=this.canvasGraphicsFactory;(0,n.info)("TilingType: "+D);const C=_[0],k=_[1],O=_[2],$=_[3],K=n.Util.singularValueDecompose2dScale(this.matrix),J=n.Util.singularValueDecompose2dScale(this.baseTransform),Y=[K[0]*J[0],K[1]*J[1]],se=this.getSizeAndScale(S,this.ctx.canvas.width,Y[0]),B=this.getSizeAndScale(F,this.ctx.canvas.height,Y[1]),V=w.cachedCanvases.getCanvas("pattern",se.size,B.size,!0),Q=V.context,N=M.createCanvasGraphics(Q);N.groupLevel=w.groupLevel,this.setFillAndStrokeStyleToContext(N,A,T);let P=C,E=k,I=O,z=$;return C<0&&(P=0,I+=Math.abs(C)),k<0&&(E=0,z+=Math.abs(k)),Q.translate(-(se.scale*P),-(B.scale*E)),N.transform(se.scale,0,0,B.scale,0,0),Q.save(),this.clipBbox(N,P,E,I,z),N.baseTransform=(0,a.getCurrentTransform)(N.ctx),N.executeOperatorList(R),N.endDrawing(),{canvas:V.canvas,scaleX:se.scale,scaleY:B.scale,offsetX:P,offsetY:E}}getSizeAndScale(w,R,_){w=Math.abs(w);const S=Math.max(x.MAX_PATTERN_SIZE,R);let F=Math.ceil(w*_);return F>=S?F=S:_=F/w,{scale:_,size:F}}clipBbox(w,R,_,S,F){const A=S-R,D=F-_;w.ctx.rect(R,_,A,D),w.current.updateRectMinMax((0,a.getCurrentTransform)(w.ctx),[R,_,S,F]),w.clip(),w.endPath()}setFillAndStrokeStyleToContext(w,R,_){const S=w.ctx,F=w.current;switch(R){case v.COLORED:const A=this.ctx;S.fillStyle=A.fillStyle,S.strokeStyle=A.strokeStyle,F.fillColor=A.fillStyle,F.strokeColor=A.strokeStyle;break;case v.UNCOLORED:const D=n.Util.makeHexColor(_[0],_[1],_[2]);S.fillStyle=D,S.strokeStyle=D,F.fillColor=D,F.strokeColor=D;break;default:throw new n.FormatError(`Unsupported paint type: ${R}`)}}getPattern(w,R,_,S){let F=_;S!==s.SHADING&&(F=n.Util.transform(F,R.baseTransform),this.matrix&&(F=n.Util.transform(F,this.matrix)));const A=this.createPatternCanvas(R);let D=new DOMMatrix(F);D=D.translate(A.offsetX,A.offsetY),D=D.scale(1/A.scaleX,1/A.scaleY);const T=w.createPattern(A.canvas,"repeat");return T.setTransform(D),T}};$e(x,"MAX_PATTERN_SIZE",3e3);let y=x;e.TilingPattern=y},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.convertBlackAndWhiteToRGBA=s,e.convertToRGBA=a,e.grayToRGBA=h;var n=r(1);function a(d){switch(d.kind){case n.ImageKind.GRAYSCALE_1BPP:return s(d);case n.ImageKind.RGB_24BPP:return o(d)}return null}function s({src:d,srcPos:l=0,dest:u,width:p,height:g,nonBlackColor:f=4294967295,inverseDecode:v=!1}){const y=n.FeatureTest.isLittleEndian?4278190080:255,[x,m]=v?[f,y]:[y,f],w=p>>3,R=p&7,_=d.length;u=new Uint32Array(u.buffer);let S=0;for(let F=0;F<g;F++){for(const D=l+w;l<D;l++){const T=l<_?d[l]:255;u[S++]=T&128?m:x,u[S++]=T&64?m:x,u[S++]=T&32?m:x,u[S++]=T&16?m:x,u[S++]=T&8?m:x,u[S++]=T&4?m:x,u[S++]=T&2?m:x,u[S++]=T&1?m:x}if(R===0)continue;const A=l<_?d[l++]:255;for(let D=0;D<R;D++)u[S++]=A&1<<7-D?m:x}return{srcPos:l,destPos:S}}function o({src:d,srcPos:l=0,dest:u,destPos:p=0,width:g,height:f}){let v=0;const y=d.length>>2,x=new Uint32Array(d.buffer,l,y);if(n.FeatureTest.isLittleEndian){for(;v<y-2;v+=3,p+=4){const m=x[v],w=x[v+1],R=x[v+2];u[p]=m|4278190080,u[p+1]=m>>>24|w<<8|4278190080,u[p+2]=w>>>16|R<<16|4278190080,u[p+3]=R>>>8|4278190080}for(let m=v*4,w=d.length;m<w;m+=3)u[p++]=d[m]|d[m+1]<<8|d[m+2]<<16|4278190080}else{for(;v<y-2;v+=3,p+=4){const m=x[v],w=x[v+1],R=x[v+2];u[p]=m|255,u[p+1]=m<<24|w>>>8|255,u[p+2]=w<<16|R>>>16|255,u[p+3]=R<<8|255}for(let m=v*4,w=d.length;m<w;m+=3)u[p++]=d[m]<<24|d[m+1]<<16|d[m+2]<<8|255}return{srcPos:l,destPos:p}}function h(d,l){if(n.FeatureTest.isLittleEndian)for(let u=0,p=d.length;u<p;u++)l[u]=d[u]*65793|4278190080;else for(let u=0,p=d.length;u<p;u++)l[u]=d[u]*16843008|255}},(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.GlobalWorkerOptions=void 0;const r=Object.create(null);e.GlobalWorkerOptions=r,r.workerPort=null,r.workerSrc=""},(t,e,r)=>{var d,Dr,Er,wt;Object.defineProperty(e,"__esModule",{value:!0}),e.MessageHandler=void 0;var n=r(1);const a={DATA:1,ERROR:2},s={CANCEL:1,CANCEL_COMPLETE:2,CLOSE:3,ENQUEUE:4,ERROR:5,PULL:6,PULL_COMPLETE:7,START_COMPLETE:8};function o(g){switch(g instanceof Error||typeof g=="object"&&g!==null||(0,n.unreachable)('wrapReason: Expected "reason" to be a (possibly cloned) Error.'),g.name){case"AbortException":return new n.AbortException(g.message);case"MissingPDFException":return new n.MissingPDFException(g.message);case"PasswordException":return new n.PasswordException(g.message,g.code);case"UnexpectedResponseException":return new n.UnexpectedResponseException(g.message,g.status);case"UnknownErrorException":return new n.UnknownErrorException(g.message,g.details);default:return new n.UnknownErrorException(g.message,g.toString())}}class h{constructor(f,v,y){de(this,d);this.sourceName=f,this.targetName=v,this.comObj=y,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=x=>{const m=x.data;if(m.targetName!==this.sourceName)return;if(m.stream){te(this,d,Er).call(this,m);return}if(m.callback){const R=m.callbackId,_=this.callbackCapabilities[R];if(!_)throw new Error(`Cannot resolve callback ${R}`);if(delete this.callbackCapabilities[R],m.callback===a.DATA)_.resolve(m.data);else if(m.callback===a.ERROR)_.reject(o(m.reason));else throw new Error("Unexpected callback case");return}const w=this.actionHandler[m.action];if(!w)throw new Error(`Unknown action from worker: ${m.action}`);if(m.callbackId){const R=this.sourceName,_=m.sourceName;new Promise(function(S){S(w(m.data))}).then(function(S){y.postMessage({sourceName:R,targetName:_,callback:a.DATA,callbackId:m.callbackId,data:S})},function(S){y.postMessage({sourceName:R,targetName:_,callback:a.ERROR,callbackId:m.callbackId,reason:o(S)})});return}if(m.streamId){te(this,d,Dr).call(this,m);return}w(m.data)},y.addEventListener("message",this._onComObjOnMessage)}on(f,v){const y=this.actionHandler;if(y[f])throw new Error(`There is already an actionName called "${f}"`);y[f]=v}send(f,v,y){this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:f,data:v},y)}sendWithPromise(f,v,y){const x=this.callbackId++,m=new n.PromiseCapability;this.callbackCapabilities[x]=m;try{this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:f,callbackId:x,data:v},y)}catch(w){m.reject(w)}return m.promise}sendWithStream(f,v,y,x){const m=this.streamId++,w=this.sourceName,R=this.targetName,_=this.comObj;return new ReadableStream({start:S=>{const F=new n.PromiseCapability;return this.streamControllers[m]={controller:S,startCall:F,pullCall:null,cancelCall:null,isClosed:!1},_.postMessage({sourceName:w,targetName:R,action:f,streamId:m,data:v,desiredSize:S.desiredSize},x),F.promise},pull:S=>{const F=new n.PromiseCapability;return this.streamControllers[m].pullCall=F,_.postMessage({sourceName:w,targetName:R,stream:s.PULL,streamId:m,desiredSize:S.desiredSize}),F.promise},cancel:S=>{(0,n.assert)(S instanceof Error,"cancel must have a valid reason");const F=new n.PromiseCapability;return this.streamControllers[m].cancelCall=F,this.streamControllers[m].isClosed=!0,_.postMessage({sourceName:w,targetName:R,stream:s.CANCEL,streamId:m,reason:o(S)}),F.promise}},y)}destroy(){this.comObj.removeEventListener("message",this._onComObjOnMessage)}}d=new WeakSet,Dr=function(f){const v=f.streamId,y=this.sourceName,x=f.sourceName,m=this.comObj,w=this,R=this.actionHandler[f.action],_={enqueue(S,F=1,A){if(this.isCancelled)return;const D=this.desiredSize;this.desiredSize-=F,D>0&&this.desiredSize<=0&&(this.sinkCapability=new n.PromiseCapability,this.ready=this.sinkCapability.promise),m.postMessage({sourceName:y,targetName:x,stream:s.ENQUEUE,streamId:v,chunk:S},A)},close(){this.isCancelled||(this.isCancelled=!0,m.postMessage({sourceName:y,targetName:x,stream:s.CLOSE,streamId:v}),delete w.streamSinks[v])},error(S){(0,n.assert)(S instanceof Error,"error must have a valid reason"),!this.isCancelled&&(this.isCancelled=!0,m.postMessage({sourceName:y,targetName:x,stream:s.ERROR,streamId:v,reason:o(S)}))},sinkCapability:new n.PromiseCapability,onPull:null,onCancel:null,isCancelled:!1,desiredSize:f.desiredSize,ready:null};_.sinkCapability.resolve(),_.ready=_.sinkCapability.promise,this.streamSinks[v]=_,new Promise(function(S){S(R(f.data,_))}).then(function(){m.postMessage({sourceName:y,targetName:x,stream:s.START_COMPLETE,streamId:v,success:!0})},function(S){m.postMessage({sourceName:y,targetName:x,stream:s.START_COMPLETE,streamId:v,reason:o(S)})})},Er=function(f){const v=f.streamId,y=this.sourceName,x=f.sourceName,m=this.comObj,w=this.streamControllers[v],R=this.streamSinks[v];switch(f.stream){case s.START_COMPLETE:f.success?w.startCall.resolve():w.startCall.reject(o(f.reason));break;case s.PULL_COMPLETE:f.success?w.pullCall.resolve():w.pullCall.reject(o(f.reason));break;case s.PULL:if(!R){m.postMessage({sourceName:y,targetName:x,stream:s.PULL_COMPLETE,streamId:v,success:!0});break}R.desiredSize<=0&&f.desiredSize>0&&R.sinkCapability.resolve(),R.desiredSize=f.desiredSize,new Promise(function(_){var S;_((S=R.onPull)==null?void 0:S.call(R))}).then(function(){m.postMessage({sourceName:y,targetName:x,stream:s.PULL_COMPLETE,streamId:v,success:!0})},function(_){m.postMessage({sourceName:y,targetName:x,stream:s.PULL_COMPLETE,streamId:v,reason:o(_)})});break;case s.ENQUEUE:if((0,n.assert)(w,"enqueue should have stream controller"),w.isClosed)break;w.controller.enqueue(f.chunk);break;case s.CLOSE:if((0,n.assert)(w,"close should have stream controller"),w.isClosed)break;w.isClosed=!0,w.controller.close(),te(this,d,wt).call(this,w,v);break;case s.ERROR:(0,n.assert)(w,"error should have stream controller"),w.controller.error(o(f.reason)),te(this,d,wt).call(this,w,v);break;case s.CANCEL_COMPLETE:f.success?w.cancelCall.resolve():w.cancelCall.reject(o(f.reason)),te(this,d,wt).call(this,w,v);break;case s.CANCEL:if(!R)break;new Promise(function(_){var S;_((S=R.onCancel)==null?void 0:S.call(R,o(f.reason)))}).then(function(){m.postMessage({sourceName:y,targetName:x,stream:s.CANCEL_COMPLETE,streamId:v,success:!0})},function(_){m.postMessage({sourceName:y,targetName:x,stream:s.CANCEL_COMPLETE,streamId:v,reason:o(_)})}),R.sinkCapability.reject(o(f.reason)),R.isCancelled=!0,delete this.streamSinks[v];break;default:throw new Error("Unexpected stream case")}},wt=async function(f,v){var y,x,m;await Promise.allSettled([(y=f.startCall)==null?void 0:y.promise,(x=f.pullCall)==null?void 0:x.promise,(m=f.cancelCall)==null?void 0:m.promise]),delete this.streamControllers[v]},e.MessageHandler=h},(t,e,r)=>{var s,o;Object.defineProperty(e,"__esModule",{value:!0}),e.Metadata=void 0;var n=r(1);class a{constructor({parsedData:d,rawData:l}){de(this,s);de(this,o);ue(this,s,d),ue(this,o,l)}getRaw(){return b(this,o)}get(d){return b(this,s).get(d)??null}getAll(){return(0,n.objectFromMap)(b(this,s))}has(d){return b(this,s).has(d)}}s=new WeakMap,o=new WeakMap,e.Metadata=a},(t,e,r)=>{var d,l,u,p,g,f,Qt;Object.defineProperty(e,"__esModule",{value:!0}),e.OptionalContentConfig=void 0;var n=r(1),a=r(8);const s=Symbol("INTERNAL");class o{constructor(x,m){de(this,d,!0);this.name=x,this.intent=m}get visible(){return b(this,d)}_setVisible(x,m){x!==s&&(0,n.unreachable)("Internal method `_setVisible` called."),ue(this,d,m)}}d=new WeakMap;class h{constructor(x){de(this,f);de(this,l,null);de(this,u,new Map);de(this,p,null);de(this,g,null);if(this.name=null,this.creator=null,x!==null){this.name=x.name,this.creator=x.creator,ue(this,g,x.order);for(const m of x.groups)b(this,u).set(m.id,new o(m.name,m.intent));if(x.baseState==="OFF")for(const m of b(this,u).values())m._setVisible(s,!1);for(const m of x.on)b(this,u).get(m)._setVisible(s,!0);for(const m of x.off)b(this,u).get(m)._setVisible(s,!1);ue(this,p,this.getHash())}}isVisible(x){if(b(this,u).size===0)return!0;if(!x)return(0,n.warn)("Optional content group not defined."),!0;if(x.type==="OCG")return b(this,u).has(x.id)?b(this,u).get(x.id).visible:((0,n.warn)(`Optional content group not found: ${x.id}`),!0);if(x.type==="OCMD"){if(x.expression)return te(this,f,Qt).call(this,x.expression);if(!x.policy||x.policy==="AnyOn"){for(const m of x.ids){if(!b(this,u).has(m))return(0,n.warn)(`Optional content group not found: ${m}`),!0;if(b(this,u).get(m).visible)return!0}return!1}else if(x.policy==="AllOn"){for(const m of x.ids){if(!b(this,u).has(m))return(0,n.warn)(`Optional content group not found: ${m}`),!0;if(!b(this,u).get(m).visible)return!1}return!0}else if(x.policy==="AnyOff"){for(const m of x.ids){if(!b(this,u).has(m))return(0,n.warn)(`Optional content group not found: ${m}`),!0;if(!b(this,u).get(m).visible)return!0}return!1}else if(x.policy==="AllOff"){for(const m of x.ids){if(!b(this,u).has(m))return(0,n.warn)(`Optional content group not found: ${m}`),!0;if(b(this,u).get(m).visible)return!1}return!0}return(0,n.warn)(`Unknown optional content policy ${x.policy}.`),!0}return(0,n.warn)(`Unknown group type ${x.type}.`),!0}setVisibility(x,m=!0){if(!b(this,u).has(x)){(0,n.warn)(`Optional content group not found: ${x}`);return}b(this,u).get(x)._setVisible(s,!!m),ue(this,l,null)}get hasInitialVisibility(){return b(this,p)===null||this.getHash()===b(this,p)}getOrder(){return b(this,u).size?b(this,g)?b(this,g).slice():[...b(this,u).keys()]:null}getGroups(){return b(this,u).size>0?(0,n.objectFromMap)(b(this,u)):null}getGroup(x){return b(this,u).get(x)||null}getHash(){if(b(this,l)!==null)return b(this,l);const x=new a.MurmurHash3_64;for(const[m,w]of b(this,u))x.update(`${m}:${w.visible}`);return ue(this,l,x.hexdigest())}}l=new WeakMap,u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakSet,Qt=function(x){const m=x.length;if(m<2)return!0;const w=x[0];for(let R=1;R<m;R++){const _=x[R];let S;if(Array.isArray(_))S=te(this,f,Qt).call(this,_);else if(b(this,u).has(_))S=b(this,u).get(_).visible;else return(0,n.warn)(`Optional content group not found: ${_}`),!0;switch(w){case"And":if(!S)return!1;break;case"Or":if(S)return!0;break;case"Not":return!S;default:return!0}}return w==="And"},e.OptionalContentConfig=h},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.PDFDataTransportStream=void 0;var n=r(1),a=r(6);class s{constructor({length:l,initialData:u,progressiveDone:p=!1,contentDispositionFilename:g=null,disableRange:f=!1,disableStream:v=!1},y){if((0,n.assert)(y,'PDFDataTransportStream - missing required "pdfDataRangeTransport" argument.'),this._queuedChunks=[],this._progressiveDone=p,this._contentDispositionFilename=g,(u==null?void 0:u.length)>0){const x=u instanceof Uint8Array&&u.byteLength===u.buffer.byteLength?u.buffer:new Uint8Array(u).buffer;this._queuedChunks.push(x)}this._pdfDataRangeTransport=y,this._isStreamingSupported=!v,this._isRangeSupported=!f,this._contentLength=l,this._fullRequestReader=null,this._rangeReaders=[],this._pdfDataRangeTransport.addRangeListener((x,m)=>{this._onReceiveData({begin:x,chunk:m})}),this._pdfDataRangeTransport.addProgressListener((x,m)=>{this._onProgress({loaded:x,total:m})}),this._pdfDataRangeTransport.addProgressiveReadListener(x=>{this._onReceiveData({chunk:x})}),this._pdfDataRangeTransport.addProgressiveDoneListener(()=>{this._onProgressiveDone()}),this._pdfDataRangeTransport.transportReady()}_onReceiveData({begin:l,chunk:u}){const p=u instanceof Uint8Array&&u.byteLength===u.buffer.byteLength?u.buffer:new Uint8Array(u).buffer;if(l===void 0)this._fullRequestReader?this._fullRequestReader._enqueue(p):this._queuedChunks.push(p);else{const g=this._rangeReaders.some(function(f){return f._begin!==l?!1:(f._enqueue(p),!0)});(0,n.assert)(g,"_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found.")}}get _progressiveDataLength(){var l;return((l=this._fullRequestReader)==null?void 0:l._loaded)??0}_onProgress(l){var u,p,g,f;l.total===void 0?(p=(u=this._rangeReaders[0])==null?void 0:u.onProgress)==null||p.call(u,{loaded:l.loaded}):(f=(g=this._fullRequestReader)==null?void 0:g.onProgress)==null||f.call(g,{loaded:l.loaded,total:l.total})}_onProgressiveDone(){var l;(l=this._fullRequestReader)==null||l.progressiveDone(),this._progressiveDone=!0}_removeRangeReader(l){const u=this._rangeReaders.indexOf(l);u>=0&&this._rangeReaders.splice(u,1)}getFullReader(){(0,n.assert)(!this._fullRequestReader,"PDFDataTransportStream.getFullReader can only be called once.");const l=this._queuedChunks;return this._queuedChunks=null,new o(this,l,this._progressiveDone,this._contentDispositionFilename)}getRangeReader(l,u){if(u<=this._progressiveDataLength)return null;const p=new h(this,l,u);return this._pdfDataRangeTransport.requestDataRange(l,u),this._rangeReaders.push(p),p}cancelAllRequests(l){var u;(u=this._fullRequestReader)==null||u.cancel(l);for(const p of this._rangeReaders.slice(0))p.cancel(l);this._pdfDataRangeTransport.abort()}}e.PDFDataTransportStream=s;class o{constructor(l,u,p=!1,g=null){this._stream=l,this._done=p||!1,this._filename=(0,a.isPdfFile)(g)?g:null,this._queuedChunks=u||[],this._loaded=0;for(const f of this._queuedChunks)this._loaded+=f.byteLength;this._requests=[],this._headersReady=Promise.resolve(),l._fullRequestReader=this,this.onProgress=null}_enqueue(l){this._done||(this._requests.length>0?this._requests.shift().resolve({value:l,done:!1}):this._queuedChunks.push(l),this._loaded+=l.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}async read(){if(this._queuedChunks.length>0)return{value:this._queuedChunks.shift(),done:!1};if(this._done)return{value:void 0,done:!0};const l=new n.PromiseCapability;return this._requests.push(l),l.promise}cancel(l){this._done=!0;for(const u of this._requests)u.resolve({value:void 0,done:!0});this._requests.length=0}progressiveDone(){this._done||(this._done=!0)}}class h{constructor(l,u,p){this._stream=l,this._begin=u,this._end=p,this._queuedChunk=null,this._requests=[],this._done=!1,this.onProgress=null}_enqueue(l){if(!this._done){if(this._requests.length===0)this._queuedChunk=l;else{this._requests.shift().resolve({value:l,done:!1});for(const p of this._requests)p.resolve({value:void 0,done:!0});this._requests.length=0}this._done=!0,this._stream._removeRangeReader(this)}}get isStreamingSupported(){return!1}async read(){if(this._queuedChunk){const u=this._queuedChunk;return this._queuedChunk=null,{value:u,done:!1}}if(this._done)return{value:void 0,done:!0};const l=new n.PromiseCapability;return this._requests.push(l),l.promise}cancel(l){this._done=!0;for(const u of this._requests)u.resolve({value:void 0,done:!0});this._requests.length=0,this._stream._removeRangeReader(this)}}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.PDFFetchStream=void 0;var n=r(1),a=r(20);function s(p,g,f){return{method:"GET",headers:p,signal:f.signal,mode:"cors",credentials:g?"include":"same-origin",redirect:"follow"}}function o(p){const g=new Headers;for(const f in p){const v=p[f];v!==void 0&&g.append(f,v)}return g}function h(p){return p instanceof Uint8Array?p.buffer:p instanceof ArrayBuffer?p:((0,n.warn)(`getArrayBuffer - unexpected data format: ${p}`),new Uint8Array(p).buffer)}class d{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(){var g;return((g=this._fullRequestReader)==null?void 0:g._loaded)??0}getFullReader(){return(0,n.assert)(!this._fullRequestReader,"PDFFetchStream.getFullReader can only be called once."),this._fullRequestReader=new l(this),this._fullRequestReader}getRangeReader(g,f){if(f<=this._progressiveDataLength)return null;const v=new u(this,g,f);return this._rangeRequestReaders.push(v),v}cancelAllRequests(g){var f;(f=this._fullRequestReader)==null||f.cancel(g);for(const v of this._rangeRequestReaders.slice(0))v.cancel(g)}}e.PDFFetchStream=d;class l{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=new n.PromiseCapability,this._disableRange=f.disableRange||!1,this._rangeChunkSize=f.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._abortController=new AbortController,this._isStreamingSupported=!f.disableStream,this._isRangeSupported=!f.disableRange,this._headers=o(this._stream.httpHeaders);const v=f.url;fetch(v,s(this._headers,this._withCredentials,this._abortController)).then(y=>{if(!(0,a.validateResponseStatus)(y.status))throw(0,a.createResponseStatusError)(y.status,v);this._reader=y.body.getReader(),this._headersCapability.resolve();const x=R=>y.headers.get(R),{allowRangeRequests:m,suggestedLength:w}=(0,a.validateRangeRequestCapabilities)({getResponseHeader:x,isHttp:this._stream.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=m,this._contentLength=w||this._contentLength,this._filename=(0,a.extractFilenameFromHeader)(x),!this._isStreamingSupported&&this._isRangeSupported&&this.cancel(new n.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}async read(){var v;await this._headersCapability.promise;const{value:g,done:f}=await this._reader.read();return f?{value:g,done:f}:(this._loaded+=g.byteLength,(v=this.onProgress)==null||v.call(this,{loaded:this._loaded,total:this._contentLength}),{value:h(g),done:!1})}cancel(g){var f;(f=this._reader)==null||f.cancel(g),this._abortController.abort()}}class u{constructor(g,f,v){this._stream=g,this._reader=null,this._loaded=0;const y=g.source;this._withCredentials=y.withCredentials||!1,this._readCapability=new n.PromiseCapability,this._isStreamingSupported=!y.disableStream,this._abortController=new AbortController,this._headers=o(this._stream.httpHeaders),this._headers.append("Range",`bytes=${f}-${v-1}`);const x=y.url;fetch(x,s(this._headers,this._withCredentials,this._abortController)).then(m=>{if(!(0,a.validateResponseStatus)(m.status))throw(0,a.createResponseStatusError)(m.status,x);this._readCapability.resolve(),this._reader=m.body.getReader()}).catch(this._readCapability.reject),this.onProgress=null}get isStreamingSupported(){return this._isStreamingSupported}async read(){var v;await this._readCapability.promise;const{value:g,done:f}=await this._reader.read();return f?{value:g,done:f}:(this._loaded+=g.byteLength,(v=this.onProgress)==null||v.call(this,{loaded:this._loaded}),{value:h(g),done:!1})}cancel(g){var f;(f=this._reader)==null||f.cancel(g),this._abortController.abort()}}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.createResponseStatusError=d,e.extractFilenameFromHeader=h,e.validateRangeRequestCapabilities=o,e.validateResponseStatus=l;var n=r(1),a=r(21),s=r(6);function o({getResponseHeader:u,isHttp:p,rangeChunkSize:g,disableRange:f}){const v={allowRangeRequests:!1,suggestedLength:void 0},y=parseInt(u("Content-Length"),10);return!Number.isInteger(y)||(v.suggestedLength=y,y<=2*g)||f||!p||u("Accept-Ranges")!=="bytes"||(u("Content-Encoding")||"identity")!=="identity"||(v.allowRangeRequests=!0),v}function h(u){const p=u("Content-Disposition");if(p){let g=(0,a.getFilenameFromContentDispositionHeader)(p);if(g.includes("%"))try{g=decodeURIComponent(g)}catch{}if((0,s.isPdfFile)(g))return g}return null}function d(u,p){return u===404||u===0&&p.startsWith("file:")?new n.MissingPDFException('Missing PDF "'+p+'".'):new n.UnexpectedResponseException(`Unexpected server response (${u}) while retrieving PDF "${p}".`,u)}function l(u){return u===200||u===206}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.getFilenameFromContentDispositionHeader=a;var n=r(1);function a(s){let o=!0,h=d("filename\\*","i").exec(s);if(h){h=h[1];let y=g(h);return y=unescape(y),y=f(y),y=v(y),u(y)}if(h=p(s),h){const y=v(h);return u(y)}if(h=d("filename","i").exec(s),h){h=h[1];let y=g(h);return y=v(y),u(y)}function d(y,x){return new RegExp("(?:^|;)\\s*"+y+'\\s*=\\s*([^";\\s][^;\\s]*|"(?:[^"\\\\]|\\\\"?)+"?)',x)}function l(y,x){if(y){if(!/^[\x00-\xFF]+$/.test(x))return x;try{const m=new TextDecoder(y,{fatal:!0}),w=(0,n.stringToBytes)(x);x=m.decode(w),o=!1}catch{}}return x}function u(y){return o&&/[\x80-\xff]/.test(y)&&(y=l("utf-8",y),o&&(y=l("iso-8859-1",y))),y}function p(y){const x=[];let m;const w=d("filename\\*((?!0\\d)\\d+)(\\*?)","ig");for(;(m=w.exec(y))!==null;){let[,_,S,F]=m;if(_=parseInt(_,10),_ in x){if(_===0)break;continue}x[_]=[S,F]}const R=[];for(let _=0;_<x.length&&_ in x;++_){let[S,F]=x[_];F=g(F),S&&(F=unescape(F),_===0&&(F=f(F))),R.push(F)}return R.join("")}function g(y){if(y.startsWith('"')){const x=y.slice(1).split('\\"');for(let m=0;m<x.length;++m){const w=x[m].indexOf('"');w!==-1&&(x[m]=x[m].slice(0,w),x.length=m+1),x[m]=x[m].replaceAll(/\\(.)/g,"$1")}y=x.join('"')}return y}function f(y){const x=y.indexOf("'");if(x===-1)return y;const m=y.slice(0,x),R=y.slice(x+1).replace(/^[^']*'/,"");return l(m,R)}function v(y){return!y.startsWith("=?")||/[\x00-\x19\x80-\xff]/.test(y)?y:y.replaceAll(/=\?([\w-]*)\?([QqBb])\?((?:[^?]|\?(?!=))*)\?=/g,function(x,m,w,R){if(w==="q"||w==="Q")return R=R.replaceAll("_"," "),R=R.replaceAll(/=([0-9a-fA-F]{2})/g,function(_,S){return String.fromCharCode(parseInt(S,16))}),l(m,R);try{R=atob(R)}catch{}return l(m,R)})}return""}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.PDFNetworkStream=void 0;var n=r(1),a=r(20);const s=200,o=206;function h(g){const f=g.response;return typeof f!="string"?f:(0,n.stringToBytes)(f).buffer}class d{constructor(f,v={}){this.url=f,this.isHttp=/^https?:/i.test(f),this.httpHeaders=this.isHttp&&v.httpHeaders||Object.create(null),this.withCredentials=v.withCredentials||!1,this.currXhrId=0,this.pendingRequests=Object.create(null)}requestRange(f,v,y){const x={begin:f,end:v};for(const m in y)x[m]=y[m];return this.request(x)}requestFull(f){return this.request(f)}request(f){const v=new XMLHttpRequest,y=this.currXhrId++,x=this.pendingRequests[y]={xhr:v};v.open("GET",this.url),v.withCredentials=this.withCredentials;for(const m in this.httpHeaders){const w=this.httpHeaders[m];w!==void 0&&v.setRequestHeader(m,w)}return this.isHttp&&"begin"in f&&"end"in f?(v.setRequestHeader("Range",`bytes=${f.begin}-${f.end-1}`),x.expectedStatus=o):x.expectedStatus=s,v.responseType="arraybuffer",f.onError&&(v.onerror=function(m){f.onError(v.status)}),v.onreadystatechange=this.onStateChange.bind(this,y),v.onprogress=this.onProgress.bind(this,y),x.onHeadersReceived=f.onHeadersReceived,x.onDone=f.onDone,x.onError=f.onError,x.onProgress=f.onProgress,v.send(null),y}onProgress(f,v){var x;const y=this.pendingRequests[f];y&&((x=y.onProgress)==null||x.call(y,v))}onStateChange(f,v){var _,S,F;const y=this.pendingRequests[f];if(!y)return;const x=y.xhr;if(x.readyState>=2&&y.onHeadersReceived&&(y.onHeadersReceived(),delete y.onHeadersReceived),x.readyState!==4||!(f in this.pendingRequests))return;if(delete this.pendingRequests[f],x.status===0&&this.isHttp){(_=y.onError)==null||_.call(y,x.status);return}const m=x.status||s;if(!(m===s&&y.expectedStatus===o)&&m!==y.expectedStatus){(S=y.onError)==null||S.call(y,x.status);return}const R=h(x);if(m===o){const A=x.getResponseHeader("Content-Range"),D=/bytes (\d+)-(\d+)\/(\d+)/.exec(A);y.onDone({begin:parseInt(D[1],10),chunk:R})}else R?y.onDone({begin:0,chunk:R}):(F=y.onError)==null||F.call(y,x.status)}getRequestXhr(f){return this.pendingRequests[f].xhr}isPendingRequest(f){return f in this.pendingRequests}abortRequest(f){const v=this.pendingRequests[f].xhr;delete this.pendingRequests[f],v.abort()}}class l{constructor(f){this._source=f,this._manager=new d(f.url,{httpHeaders:f.httpHeaders,withCredentials:f.withCredentials}),this._rangeChunkSize=f.rangeChunkSize,this._fullRequestReader=null,this._rangeRequestReaders=[]}_onRangeRequestReaderClosed(f){const v=this._rangeRequestReaders.indexOf(f);v>=0&&this._rangeRequestReaders.splice(v,1)}getFullReader(){return(0,n.assert)(!this._fullRequestReader,"PDFNetworkStream.getFullReader can only be called once."),this._fullRequestReader=new u(this._manager,this._source),this._fullRequestReader}getRangeReader(f,v){const y=new p(this._manager,f,v);return y.onClosed=this._onRangeRequestReaderClosed.bind(this),this._rangeRequestReaders.push(y),y}cancelAllRequests(f){var v;(v=this._fullRequestReader)==null||v.cancel(f);for(const y of this._rangeRequestReaders.slice(0))y.cancel(f)}}e.PDFNetworkStream=l;class u{constructor(f,v){this._manager=f;const y={onHeadersReceived:this._onHeadersReceived.bind(this),onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=v.url,this._fullRequestId=f.requestFull(y),this._headersReceivedCapability=new n.PromiseCapability,this._disableRange=v.disableRange||!1,this._contentLength=v.length,this._rangeChunkSize=v.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 f=this._fullRequestId,v=this._manager.getRequestXhr(f),y=w=>v.getResponseHeader(w),{allowRangeRequests:x,suggestedLength:m}=(0,a.validateRangeRequestCapabilities)({getResponseHeader:y,isHttp:this._manager.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});x&&(this._isRangeSupported=!0),this._contentLength=m||this._contentLength,this._filename=(0,a.extractFilenameFromHeader)(y),this._isRangeSupported&&this._manager.abortRequest(f),this._headersReceivedCapability.resolve()}_onDone(f){if(f&&(this._requests.length>0?this._requests.shift().resolve({value:f.chunk,done:!1}):this._cachedChunks.push(f.chunk)),this._done=!0,!(this._cachedChunks.length>0)){for(const v of this._requests)v.resolve({value:void 0,done:!0});this._requests.length=0}}_onError(f){this._storedError=(0,a.createResponseStatusError)(f,this._url),this._headersReceivedCapability.reject(this._storedError);for(const v of this._requests)v.reject(this._storedError);this._requests.length=0,this._cachedChunks.length=0}_onProgress(f){var v;(v=this.onProgress)==null||v.call(this,{loaded:f.loaded,total:f.lengthComputable?f.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}async read(){if(this._storedError)throw this._storedError;if(this._cachedChunks.length>0)return{value:this._cachedChunks.shift(),done:!1};if(this._done)return{value:void 0,done:!0};const f=new n.PromiseCapability;return this._requests.push(f),f.promise}cancel(f){this._done=!0,this._headersReceivedCapability.reject(f);for(const v of this._requests)v.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._fullRequestId)&&this._manager.abortRequest(this._fullRequestId),this._fullRequestReader=null}}class p{constructor(f,v,y){this._manager=f;const x={onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=f.url,this._requestId=f.requestRange(v,y,x),this._requests=[],this._queuedChunk=null,this._done=!1,this._storedError=void 0,this.onProgress=null,this.onClosed=null}_close(){var f;(f=this.onClosed)==null||f.call(this,this)}_onDone(f){const v=f.chunk;this._requests.length>0?this._requests.shift().resolve({value:v,done:!1}):this._queuedChunk=v,this._done=!0;for(const y of this._requests)y.resolve({value:void 0,done:!0});this._requests.length=0,this._close()}_onError(f){this._storedError=(0,a.createResponseStatusError)(f,this._url);for(const v of this._requests)v.reject(this._storedError);this._requests.length=0,this._queuedChunk=null}_onProgress(f){var v;this.isStreamingSupported||(v=this.onProgress)==null||v.call(this,{loaded:f.loaded})}get isStreamingSupported(){return!1}async read(){if(this._storedError)throw this._storedError;if(this._queuedChunk!==null){const v=this._queuedChunk;return this._queuedChunk=null,{value:v,done:!1}}if(this._done)return{value:void 0,done:!0};const f=new n.PromiseCapability;return this._requests.push(f),f.promise}cancel(f){this._done=!0;for(const v of this._requests)v.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._requestId)&&this._manager.abortRequest(this._requestId),this._close()}}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.PDFNodeStream=void 0;var n=r(1),a=r(20);const s=/^file:\/\/\/[a-zA-Z]:\//;function o(y){const x=require$$5,m=x.parse(y);return m.protocol==="file:"||m.host?m:/^[a-z]:[/\\]/i.test(y)?x.parse(`file:///${y}`):(m.host||(m.protocol="file:"),m)}class h{constructor(x){this.source=x,this.url=o(x.url),this.isHttp=this.url.protocol==="http:"||this.url.protocol==="https:",this.isFsUrl=this.url.protocol==="file:",this.httpHeaders=this.isHttp&&x.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){var x;return((x=this._fullRequestReader)==null?void 0:x._loaded)??0}getFullReader(){return(0,n.assert)(!this._fullRequestReader,"PDFNodeStream.getFullReader can only be called once."),this._fullRequestReader=this.isFsUrl?new f(this):new p(this),this._fullRequestReader}getRangeReader(x,m){if(m<=this._progressiveDataLength)return null;const w=this.isFsUrl?new v(this,x,m):new g(this,x,m);return this._rangeRequestReaders.push(w),w}cancelAllRequests(x){var m;(m=this._fullRequestReader)==null||m.cancel(x);for(const w of this._rangeRequestReaders.slice(0))w.cancel(x)}}e.PDFNodeStream=h;class d{constructor(x){this._url=x.url,this._done=!1,this._storedError=null,this.onProgress=null;const m=x.source;this._contentLength=m.length,this._loaded=0,this._filename=null,this._disableRange=m.disableRange||!1,this._rangeChunkSize=m.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._isStreamingSupported=!m.disableStream,this._isRangeSupported=!m.disableRange,this._readableStream=null,this._readCapability=new n.PromiseCapability,this._headersCapability=new n.PromiseCapability}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}async read(){var w;if(await this._readCapability.promise,this._done)return{value:void 0,done:!0};if(this._storedError)throw this._storedError;const x=this._readableStream.read();return x===null?(this._readCapability=new n.PromiseCapability,this.read()):(this._loaded+=x.length,(w=this.onProgress)==null||w.call(this,{loaded:this._loaded,total:this._contentLength}),{value:new Uint8Array(x).buffer,done:!1})}cancel(x){if(!this._readableStream){this._error(x);return}this._readableStream.destroy(x)}_error(x){this._storedError=x,this._readCapability.resolve()}_setReadableStream(x){this._readableStream=x,x.on("readable",()=>{this._readCapability.resolve()}),x.on("end",()=>{x.destroy(),this._done=!0,this._readCapability.resolve()}),x.on("error",m=>{this._error(m)}),!this._isStreamingSupported&&this._isRangeSupported&&this._error(new n.AbortException("streaming is disabled")),this._storedError&&this._readableStream.destroy(this._storedError)}}class l{constructor(x){this._url=x.url,this._done=!1,this._storedError=null,this.onProgress=null,this._loaded=0,this._readableStream=null,this._readCapability=new n.PromiseCapability;const m=x.source;this._isStreamingSupported=!m.disableStream}get isStreamingSupported(){return this._isStreamingSupported}async read(){var w;if(await this._readCapability.promise,this._done)return{value:void 0,done:!0};if(this._storedError)throw this._storedError;const x=this._readableStream.read();return x===null?(this._readCapability=new n.PromiseCapability,this.read()):(this._loaded+=x.length,(w=this.onProgress)==null||w.call(this,{loaded:this._loaded}),{value:new Uint8Array(x).buffer,done:!1})}cancel(x){if(!this._readableStream){this._error(x);return}this._readableStream.destroy(x)}_error(x){this._storedError=x,this._readCapability.resolve()}_setReadableStream(x){this._readableStream=x,x.on("readable",()=>{this._readCapability.resolve()}),x.on("end",()=>{x.destroy(),this._done=!0,this._readCapability.resolve()}),x.on("error",m=>{this._error(m)}),this._storedError&&this._readableStream.destroy(this._storedError)}}function u(y,x){return{protocol:y.protocol,auth:y.auth,host:y.hostname,port:y.port,path:y.path,method:"GET",headers:x}}class p extends d{constructor(x){super(x);const m=w=>{if(w.statusCode===404){const F=new n.MissingPDFException(`Missing PDF "${this._url}".`);this._storedError=F,this._headersCapability.reject(F);return}this._headersCapability.resolve(),this._setReadableStream(w);const R=F=>this._readableStream.headers[F.toLowerCase()],{allowRangeRequests:_,suggestedLength:S}=(0,a.validateRangeRequestCapabilities)({getResponseHeader:R,isHttp:x.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=_,this._contentLength=S||this._contentLength,this._filename=(0,a.extractFilenameFromHeader)(R)};if(this._request=null,this._url.protocol==="http:"){const w=require$$5;this._request=w.request(u(this._url,x.httpHeaders),m)}else{const w=require$$5;this._request=w.request(u(this._url,x.httpHeaders),m)}this._request.on("error",w=>{this._storedError=w,this._headersCapability.reject(w)}),this._request.end()}}class g extends l{constructor(x,m,w){super(x),this._httpHeaders={};for(const _ in x.httpHeaders){const S=x.httpHeaders[_];S!==void 0&&(this._httpHeaders[_]=S)}this._httpHeaders.Range=`bytes=${m}-${w-1}`;const R=_=>{if(_.statusCode===404){const S=new n.MissingPDFException(`Missing PDF "${this._url}".`);this._storedError=S;return}this._setReadableStream(_)};if(this._request=null,this._url.protocol==="http:"){const _=require$$5;this._request=_.request(u(this._url,this._httpHeaders),R)}else{const _=require$$5;this._request=_.request(u(this._url,this._httpHeaders),R)}this._request.on("error",_=>{this._storedError=_}),this._request.end()}}class f extends d{constructor(x){super(x);let m=decodeURIComponent(this._url.path);s.test(this._url.href)&&(m=m.replace(/^\//,""));const w=require$$5;w.lstat(m,(R,_)=>{if(R){R.code==="ENOENT"&&(R=new n.MissingPDFException(`Missing PDF "${m}".`)),this._storedError=R,this._headersCapability.reject(R);return}this._contentLength=_.size,this._setReadableStream(w.createReadStream(m)),this._headersCapability.resolve()})}}class v extends l{constructor(x,m,w){super(x);let R=decodeURIComponent(this._url.path);s.test(this._url.href)&&(R=R.replace(/^\//,""));const _=require$$5;this._setReadableStream(_.createReadStream(R,{start:m,end:w-1}))}}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.SVGGraphics=void 0;var n=r(6),a=r(1);const s={fontStyle:"normal",fontWeight:"normal",fillColor:"#000000"},o="http://www.w3.org/XML/1998/namespace",h="http://www.w3.org/1999/xlink",d=["butt","round","square"],l=["miter","round","bevel"],u=function(_,S="",F=!1){if(URL.createObjectURL&&typeof Blob<"u"&&!F)return URL.createObjectURL(new Blob([_],{type:S}));const A="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";let D=`data:${S};base64,`;for(let T=0,M=_.length;T<M;T+=3){const C=_[T]&255,k=_[T+1]&255,O=_[T+2]&255,$=C>>2,K=(C&3)<<4|k>>4,J=T+1<M?(k&15)<<2|O>>6:64,Y=T+2<M?O&63:64;D+=A[$]+A[K]+A[J]+A[Y]}return D},p=function(){const _=new Uint8Array([137,80,78,71,13,10,26,10]),S=12,F=new Int32Array(256);for(let O=0;O<256;O++){let $=O;for(let K=0;K<8;K++)$=$&1?3988292384^$>>1&2147483647:$>>1&2147483647;F[O]=$}function A(O,$,K){let J=-1;for(let Y=$;Y<K;Y++){const se=(J^O[Y])&255,B=F[se];J=J>>>8^B}return J^-1}function D(O,$,K,J){let Y=J;const se=$.length;K[Y]=se>>24&255,K[Y+1]=se>>16&255,K[Y+2]=se>>8&255,K[Y+3]=se&255,Y+=4,K[Y]=O.charCodeAt(0)&255,K[Y+1]=O.charCodeAt(1)&255,K[Y+2]=O.charCodeAt(2)&255,K[Y+3]=O.charCodeAt(3)&255,Y+=4,K.set($,Y),Y+=$.length;const B=A(K,J+4,Y);K[Y]=B>>24&255,K[Y+1]=B>>16&255,K[Y+2]=B>>8&255,K[Y+3]=B&255}function T(O,$,K){let J=1,Y=0;for(let se=$;se<K;++se)J=(J+(O[se]&255))%65521,Y=(Y+J)%65521;return Y<<16|J}function M(O){if(!a.isNodeJS)return C(O);try{const $=parseInt(process.versions.node)>=8?O:Buffer.from(O),K=require$$5.deflateSync($,{level:9});return K instanceof Uint8Array?K:new Uint8Array(K)}catch($){(0,a.warn)("Not compressing PNG because zlib.deflateSync is unavailable: "+$)}return C(O)}function C(O){let $=O.length;const K=65535,J=Math.ceil($/K),Y=new Uint8Array(2+$+J*5+4);let se=0;Y[se++]=120,Y[se++]=156;let B=0;for(;$>K;)Y[se++]=0,Y[se++]=255,Y[se++]=255,Y[se++]=0,Y[se++]=0,Y.set(O.subarray(B,B+K),se),se+=K,B+=K,$-=K;Y[se++]=1,Y[se++]=$&255,Y[se++]=$>>8&255,Y[se++]=~$&65535&255,Y[se++]=(~$&65535)>>8&255,Y.set(O.subarray(B),se),se+=O.length-B;const V=T(O,0,O.length);return Y[se++]=V>>24&255,Y[se++]=V>>16&255,Y[se++]=V>>8&255,Y[se++]=V&255,Y}function k(O,$,K,J){const Y=O.width,se=O.height;let B,V,Q;const N=O.data;switch($){case a.ImageKind.GRAYSCALE_1BPP:V=0,B=1,Q=Y+7>>3;break;case a.ImageKind.RGB_24BPP:V=2,B=8,Q=Y*3;break;case a.ImageKind.RGBA_32BPP:V=6,B=8,Q=Y*4;break;default:throw new Error("invalid format")}const P=new Uint8Array((1+Q)*se);let E=0,I=0;for(let ve=0;ve<se;++ve)P[E++]=0,P.set(N.subarray(I,I+Q),E),I+=Q,E+=Q;if($===a.ImageKind.GRAYSCALE_1BPP&&J){E=0;for(let ve=0;ve<se;ve++){E++;for(let me=0;me<Q;me++)P[E++]^=255}}const z=new Uint8Array([Y>>24&255,Y>>16&255,Y>>8&255,Y&255,se>>24&255,se>>16&255,se>>8&255,se&255,B,V,0,0,0]),G=M(P),H=_.length+S*3+z.length+G.length,ee=new Uint8Array(H);let ce=0;return ee.set(_,ce),ce+=_.length,D("IHDR",z,ee,ce),ce+=S+z.length,D("IDATA",G,ee,ce),ce+=S+G.length,D("IEND",new Uint8Array(0),ee,ce),u(ee,"image/png",K)}return function($,K,J){const Y=$.kind===void 0?a.ImageKind.GRAYSCALE_1BPP:$.kind;return k($,Y,K,J)}}();class g{constructor(){this.fontSizeScale=1,this.fontWeight=s.fontWeight,this.fontSize=0,this.textMatrix=a.IDENTITY_MATRIX,this.fontMatrix=a.FONT_IDENTITY_MATRIX,this.leading=0,this.textRenderingMode=a.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=s.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(S,F){this.x=S,this.y=F}}function f(_){let S=[];const F=[];for(const A of _){if(A.fn==="save"){S.push({fnId:92,fn:"group",items:[]}),F.push(S),S=S.at(-1).items;continue}A.fn==="restore"?S=F.pop():S.push(A)}return S}function v(_){if(Number.isInteger(_))return _.toString();const S=_.toFixed(10);let F=S.length-1;if(S[F]!=="0")return S;do F--;while(S[F]==="0");return S.substring(0,S[F]==="."?F:F+1)}function y(_){if(_[4]===0&&_[5]===0){if(_[1]===0&&_[2]===0)return _[0]===1&&_[3]===1?"":`scale(${v(_[0])} ${v(_[3])})`;if(_[0]===_[3]&&_[1]===-_[2]){const S=Math.acos(_[0])*180/Math.PI;return`rotate(${v(S)})`}}else if(_[0]===1&&_[1]===0&&_[2]===0&&_[3]===1)return`translate(${v(_[4])} ${v(_[5])})`;return`matrix(${v(_[0])} ${v(_[1])} ${v(_[2])} ${v(_[3])} ${v(_[4])} ${v(_[5])})`}let x=0,m=0,w=0;class R{constructor(S,F,A=!1){(0,n.deprecated)("The SVG back-end is no longer maintained and *may* be removed in the future."),this.svgFactory=new n.DOMSVGFactory,this.current=new g,this.transformMatrix=a.IDENTITY_MATRIX,this.transformStack=[],this.extraStack=[],this.commonObjs=S,this.objs=F,this.pendingClip=null,this.pendingEOFill=!1,this.embedFonts=!1,this.embeddedFonts=Object.create(null),this.cssStyle=null,this.forceDataSchema=!!A,this._operatorIdMapping=[];for(const D in a.OPS)this._operatorIdMapping[a.OPS[D]]=D}getObject(S,F=null){return typeof S=="string"?S.startsWith("g_")?this.commonObjs.get(S):this.objs.get(S):F}save(){this.transformStack.push(this.transformMatrix);const S=this.current;this.extraStack.push(S),this.current=S.clone()}restore(){this.transformMatrix=this.transformStack.pop(),this.current=this.extraStack.pop(),this.pendingClip=null,this.tgrp=null}group(S){this.save(),this.executeOpTree(S),this.restore()}loadDependencies(S){const F=S.fnArray,A=S.argsArray;for(let D=0,T=F.length;D<T;D++)if(F[D]===a.OPS.dependency)for(const M of A[D]){const C=M.startsWith("g_")?this.commonObjs:this.objs,k=new Promise(O=>{C.get(M,O)});this.current.dependencies.push(k)}return Promise.all(this.current.dependencies)}transform(S,F,A,D,T,M){const C=[S,F,A,D,T,M];this.transformMatrix=a.Util.transform(this.transformMatrix,C),this.tgrp=null}getSVG(S,F){this.viewport=F;const A=this._initialize(F);return this.loadDependencies(S).then(()=>(this.transformMatrix=a.IDENTITY_MATRIX,this.executeOpTree(this.convertOpList(S)),A))}convertOpList(S){const F=this._operatorIdMapping,A=S.argsArray,D=S.fnArray,T=[];for(let M=0,C=D.length;M<C;M++){const k=D[M];T.push({fnId:k,fn:F[k],args:A[M]})}return f(T)}executeOpTree(S){for(const F of S){const A=F.fn,D=F.fnId,T=F.args;switch(D|0){case a.OPS.beginText:this.beginText();break;case a.OPS.dependency:break;case a.OPS.setLeading:this.setLeading(T);break;case a.OPS.setLeadingMoveText:this.setLeadingMoveText(T[0],T[1]);break;case a.OPS.setFont:this.setFont(T);break;case a.OPS.showText:this.showText(T[0]);break;case a.OPS.showSpacedText:this.showText(T[0]);break;case a.OPS.endText:this.endText();break;case a.OPS.moveText:this.moveText(T[0],T[1]);break;case a.OPS.setCharSpacing:this.setCharSpacing(T[0]);break;case a.OPS.setWordSpacing:this.setWordSpacing(T[0]);break;case a.OPS.setHScale:this.setHScale(T[0]);break;case a.OPS.setTextMatrix:this.setTextMatrix(T[0],T[1],T[2],T[3],T[4],T[5]);break;case a.OPS.setTextRise:this.setTextRise(T[0]);break;case a.OPS.setTextRenderingMode:this.setTextRenderingMode(T[0]);break;case a.OPS.setLineWidth:this.setLineWidth(T[0]);break;case a.OPS.setLineJoin:this.setLineJoin(T[0]);break;case a.OPS.setLineCap:this.setLineCap(T[0]);break;case a.OPS.setMiterLimit:this.setMiterLimit(T[0]);break;case a.OPS.setFillRGBColor:this.setFillRGBColor(T[0],T[1],T[2]);break;case a.OPS.setStrokeRGBColor:this.setStrokeRGBColor(T[0],T[1],T[2]);break;case a.OPS.setStrokeColorN:this.setStrokeColorN(T);break;case a.OPS.setFillColorN:this.setFillColorN(T);break;case a.OPS.shadingFill:this.shadingFill(T[0]);break;case a.OPS.setDash:this.setDash(T[0],T[1]);break;case a.OPS.setRenderingIntent:this.setRenderingIntent(T[0]);break;case a.OPS.setFlatness:this.setFlatness(T[0]);break;case a.OPS.setGState:this.setGState(T[0]);break;case a.OPS.fill:this.fill();break;case a.OPS.eoFill:this.eoFill();break;case a.OPS.stroke:this.stroke();break;case a.OPS.fillStroke:this.fillStroke();break;case a.OPS.eoFillStroke:this.eoFillStroke();break;case a.OPS.clip:this.clip("nonzero");break;case a.OPS.eoClip:this.clip("evenodd");break;case a.OPS.paintSolidColorImageMask:this.paintSolidColorImageMask();break;case a.OPS.paintImageXObject:this.paintImageXObject(T[0]);break;case a.OPS.paintInlineImageXObject:this.paintInlineImageXObject(T[0]);break;case a.OPS.paintImageMaskXObject:this.paintImageMaskXObject(T[0]);break;case a.OPS.paintFormXObjectBegin:this.paintFormXObjectBegin(T[0],T[1]);break;case a.OPS.paintFormXObjectEnd:this.paintFormXObjectEnd();break;case a.OPS.closePath:this.closePath();break;case a.OPS.closeStroke:this.closeStroke();break;case a.OPS.closeFillStroke:this.closeFillStroke();break;case a.OPS.closeEOFillStroke:this.closeEOFillStroke();break;case a.OPS.nextLine:this.nextLine();break;case a.OPS.transform:this.transform(T[0],T[1],T[2],T[3],T[4],T[5]);break;case a.OPS.constructPath:this.constructPath(T[0],T[1]);break;case a.OPS.endPath:this.endPath();break;case 92:this.group(F.items);break;default:(0,a.warn)(`Unimplemented operator ${A}`);break}}}setWordSpacing(S){this.current.wordSpacing=S}setCharSpacing(S){this.current.charSpacing=S}nextLine(){this.moveText(0,this.current.leading)}setTextMatrix(S,F,A,D,T,M){const C=this.current;C.textMatrix=C.lineMatrix=[S,F,A,D,T,M],C.textMatrixScale=Math.hypot(S,F),C.x=C.lineX=0,C.y=C.lineY=0,C.xcoords=[],C.ycoords=[],C.tspan=this.svgFactory.createElement("svg:tspan"),C.tspan.setAttributeNS(null,"font-family",C.fontFamily),C.tspan.setAttributeNS(null,"font-size",`${v(C.fontSize)}px`),C.tspan.setAttributeNS(null,"y",v(-C.y)),C.txtElement=this.svgFactory.createElement("svg:text"),C.txtElement.append(C.tspan)}beginText(){const S=this.current;S.x=S.lineX=0,S.y=S.lineY=0,S.textMatrix=a.IDENTITY_MATRIX,S.lineMatrix=a.IDENTITY_MATRIX,S.textMatrixScale=1,S.tspan=this.svgFactory.createElement("svg:tspan"),S.txtElement=this.svgFactory.createElement("svg:text"),S.txtgrp=this.svgFactory.createElement("svg:g"),S.xcoords=[],S.ycoords=[]}moveText(S,F){const A=this.current;A.x=A.lineX+=S,A.y=A.lineY+=F,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",`${v(A.fontSize)}px`),A.tspan.setAttributeNS(null,"y",v(-A.y))}showText(S){const F=this.current,A=F.font,D=F.fontSize;if(D===0)return;const T=F.fontSizeScale,M=F.charSpacing,C=F.wordSpacing,k=F.fontDirection,O=F.textHScale*k,$=A.vertical,K=$?1:-1,J=A.defaultVMetrics,Y=D*F.fontMatrix[0];let se=0;for(const Q of S){if(Q===null){se+=k*C;continue}else if(typeof Q=="number"){se+=K*Q*D/1e3;continue}const N=(Q.isSpace?C:0)+M,P=Q.fontChar;let E,I,z=Q.width;if($){let H;const ee=Q.vmetric||J;H=Q.vmetric?ee[1]:z*.5,H=-H*Y;const ce=ee[2]*Y;z=ee?-ee[0]:z,E=H/T,I=(se+ce)/T}else E=se/T,I=0;(Q.isInFont||A.missingFile)&&(F.xcoords.push(F.x+E),$&&F.ycoords.push(-F.y+I),F.tspan.textContent+=P);const G=$?z*Y-N*k:z*Y+N*k;se+=G}F.tspan.setAttributeNS(null,"x",F.xcoords.map(v).join(" ")),$?F.tspan.setAttributeNS(null,"y",F.ycoords.map(v).join(" ")):F.tspan.setAttributeNS(null,"y",v(-F.y)),$?F.y-=se:F.x+=se*O,F.tspan.setAttributeNS(null,"font-family",F.fontFamily),F.tspan.setAttributeNS(null,"font-size",`${v(F.fontSize)}px`),F.fontStyle!==s.fontStyle&&F.tspan.setAttributeNS(null,"font-style",F.fontStyle),F.fontWeight!==s.fontWeight&&F.tspan.setAttributeNS(null,"font-weight",F.fontWeight);const B=F.textRenderingMode&a.TextRenderingMode.FILL_STROKE_MASK;if(B===a.TextRenderingMode.FILL||B===a.TextRenderingMode.FILL_STROKE?(F.fillColor!==s.fillColor&&F.tspan.setAttributeNS(null,"fill",F.fillColor),F.fillAlpha<1&&F.tspan.setAttributeNS(null,"fill-opacity",F.fillAlpha)):F.textRenderingMode===a.TextRenderingMode.ADD_TO_PATH?F.tspan.setAttributeNS(null,"fill","transparent"):F.tspan.setAttributeNS(null,"fill","none"),B===a.TextRenderingMode.STROKE||B===a.TextRenderingMode.FILL_STROKE){const Q=1/(F.textMatrixScale||1);this._setStrokeAttributes(F.tspan,Q)}let V=F.textMatrix;F.textRise!==0&&(V=V.slice(),V[5]+=F.textRise),F.txtElement.setAttributeNS(null,"transform",`${y(V)} scale(${v(O)}, -1)`),F.txtElement.setAttributeNS(o,"xml:space","preserve"),F.txtElement.append(F.tspan),F.txtgrp.append(F.txtElement),this._ensureTransformGroup().append(F.txtElement)}setLeadingMoveText(S,F){this.setLeading(-F),this.moveText(S,F)}addFontStyle(S){if(!S.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.append(this.cssStyle));const F=u(S.data,S.mimetype,this.forceDataSchema);this.cssStyle.textContent+=`@font-face { font-family: "${S.loadedName}"; src: url(${F}); }
|
|
4
|
-
`}setFont(S){const F=this.current,A=this.commonObjs.get(S[0]);let D=S[1];F.font=A,this.embedFonts&&!A.missingFile&&!this.embeddedFonts[A.loadedName]&&(this.addFontStyle(A),this.embeddedFonts[A.loadedName]=A),F.fontMatrix=A.fontMatrix||a.FONT_IDENTITY_MATRIX;let T="normal";A.black?T="900":A.bold&&(T="bold");const M=A.italic?"italic":"normal";D<0?(D=-D,F.fontDirection=-1):F.fontDirection=1,F.fontSize=D,F.fontFamily=A.loadedName,F.fontWeight=T,F.fontStyle=M,F.tspan=this.svgFactory.createElement("svg:tspan"),F.tspan.setAttributeNS(null,"y",v(-F.y)),F.xcoords=[],F.ycoords=[]}endText(){var F;const S=this.current;S.textRenderingMode&a.TextRenderingMode.ADD_TO_PATH_FLAG&&((F=S.txtElement)!=null&&F.hasChildNodes())&&(S.element=S.txtElement,this.clip("nonzero"),this.endPath())}setLineWidth(S){S>0&&(this.current.lineWidth=S)}setLineCap(S){this.current.lineCap=d[S]}setLineJoin(S){this.current.lineJoin=l[S]}setMiterLimit(S){this.current.miterLimit=S}setStrokeAlpha(S){this.current.strokeAlpha=S}setStrokeRGBColor(S,F,A){this.current.strokeColor=a.Util.makeHexColor(S,F,A)}setFillAlpha(S){this.current.fillAlpha=S}setFillRGBColor(S,F,A){this.current.fillColor=a.Util.makeHexColor(S,F,A),this.current.tspan=this.svgFactory.createElement("svg:tspan"),this.current.xcoords=[],this.current.ycoords=[]}setStrokeColorN(S){this.current.strokeColor=this._makeColorN_Pattern(S)}setFillColorN(S){this.current.fillColor=this._makeColorN_Pattern(S)}shadingFill(S){const{width:F,height:A}=this.viewport,D=a.Util.inverseTransform(this.transformMatrix),[T,M,C,k]=a.Util.getAxialAlignedBoundingBox([0,0,F,A],D),O=this.svgFactory.createElement("svg:rect");O.setAttributeNS(null,"x",T),O.setAttributeNS(null,"y",M),O.setAttributeNS(null,"width",C-T),O.setAttributeNS(null,"height",k-M),O.setAttributeNS(null,"fill",this._makeShadingPattern(S)),this.current.fillAlpha<1&&O.setAttributeNS(null,"fill-opacity",this.current.fillAlpha),this._ensureTransformGroup().append(O)}_makeColorN_Pattern(S){return S[0]==="TilingPattern"?this._makeTilingPattern(S):this._makeShadingPattern(S)}_makeTilingPattern(S){const F=S[1],A=S[2],D=S[3]||a.IDENTITY_MATRIX,[T,M,C,k]=S[4],O=S[5],$=S[6],K=S[7],J=`shading${w++}`,[Y,se,B,V]=a.Util.normalizeRect([...a.Util.applyTransform([T,M],D),...a.Util.applyTransform([C,k],D)]),[Q,N]=a.Util.singularValueDecompose2dScale(D),P=O*Q,E=$*N,I=this.svgFactory.createElement("svg:pattern");I.setAttributeNS(null,"id",J),I.setAttributeNS(null,"patternUnits","userSpaceOnUse"),I.setAttributeNS(null,"width",P),I.setAttributeNS(null,"height",E),I.setAttributeNS(null,"x",`${Y}`),I.setAttributeNS(null,"y",`${se}`);const z=this.svg,G=this.transformMatrix,H=this.current.fillColor,ee=this.current.strokeColor,ce=this.svgFactory.create(B-Y,V-se);if(this.svg=ce,this.transformMatrix=D,K===2){const ve=a.Util.makeHexColor(...F);this.current.fillColor=ve,this.current.strokeColor=ve}return this.executeOpTree(this.convertOpList(A)),this.svg=z,this.transformMatrix=G,this.current.fillColor=H,this.current.strokeColor=ee,I.append(ce.childNodes[0]),this.defs.append(I),`url(#${J})`}_makeShadingPattern(S){switch(typeof S=="string"&&(S=this.objs.get(S)),S[0]){case"RadialAxial":const F=`shading${w++}`,A=S[3];let D;switch(S[1]){case"axial":const T=S[4],M=S[5];D=this.svgFactory.createElement("svg:linearGradient"),D.setAttributeNS(null,"id",F),D.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),D.setAttributeNS(null,"x1",T[0]),D.setAttributeNS(null,"y1",T[1]),D.setAttributeNS(null,"x2",M[0]),D.setAttributeNS(null,"y2",M[1]);break;case"radial":const C=S[4],k=S[5],O=S[6],$=S[7];D=this.svgFactory.createElement("svg:radialGradient"),D.setAttributeNS(null,"id",F),D.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),D.setAttributeNS(null,"cx",k[0]),D.setAttributeNS(null,"cy",k[1]),D.setAttributeNS(null,"r",$),D.setAttributeNS(null,"fx",C[0]),D.setAttributeNS(null,"fy",C[1]),D.setAttributeNS(null,"fr",O);break;default:throw new Error(`Unknown RadialAxial type: ${S[1]}`)}for(const T of A){const M=this.svgFactory.createElement("svg:stop");M.setAttributeNS(null,"offset",T[0]),M.setAttributeNS(null,"stop-color",T[1]),D.append(M)}return this.defs.append(D),`url(#${F})`;case"Mesh":return(0,a.warn)("Unimplemented pattern Mesh"),null;case"Dummy":return"hotpink";default:throw new Error(`Unknown IR type: ${S[0]}`)}}setDash(S,F){this.current.dashArray=S,this.current.dashPhase=F}constructPath(S,F){const A=this.current;let D=A.x,T=A.y,M=[],C=0;for(const k of S)switch(k|0){case a.OPS.rectangle:D=F[C++],T=F[C++];const O=F[C++],$=F[C++],K=D+O,J=T+$;M.push("M",v(D),v(T),"L",v(K),v(T),"L",v(K),v(J),"L",v(D),v(J),"Z");break;case a.OPS.moveTo:D=F[C++],T=F[C++],M.push("M",v(D),v(T));break;case a.OPS.lineTo:D=F[C++],T=F[C++],M.push("L",v(D),v(T));break;case a.OPS.curveTo:D=F[C+4],T=F[C+5],M.push("C",v(F[C]),v(F[C+1]),v(F[C+2]),v(F[C+3]),v(D),v(T)),C+=6;break;case a.OPS.curveTo2:M.push("C",v(D),v(T),v(F[C]),v(F[C+1]),v(F[C+2]),v(F[C+3])),D=F[C+2],T=F[C+3],C+=4;break;case a.OPS.curveTo3:D=F[C+2],T=F[C+3],M.push("C",v(F[C]),v(F[C+1]),v(D),v(T),v(D),v(T)),C+=4;break;case a.OPS.closePath:M.push("Z");break}M=M.join(" "),A.path&&S.length>0&&S[0]!==a.OPS.rectangle&&S[0]!==a.OPS.moveTo?M=A.path.getAttributeNS(null,"d")+M:(A.path=this.svgFactory.createElement("svg:path"),this._ensureTransformGroup().append(A.path)),A.path.setAttributeNS(null,"d",M),A.path.setAttributeNS(null,"fill","none"),A.element=A.path,A.setCurrentPoint(D,T)}endPath(){const S=this.current;if(S.path=null,!this.pendingClip)return;if(!S.element){this.pendingClip=null;return}const F=`clippath${x++}`,A=this.svgFactory.createElement("svg:clipPath");A.setAttributeNS(null,"id",F),A.setAttributeNS(null,"transform",y(this.transformMatrix));const D=S.element.cloneNode(!0);if(this.pendingClip==="evenodd"?D.setAttributeNS(null,"clip-rule","evenodd"):D.setAttributeNS(null,"clip-rule","nonzero"),this.pendingClip=null,A.append(D),this.defs.append(A),S.activeClipUrl){S.clipGroup=null;for(const T of this.extraStack)T.clipGroup=null;A.setAttributeNS(null,"clip-path",S.activeClipUrl)}S.activeClipUrl=`url(#${F})`,this.tgrp=null}clip(S){this.pendingClip=S}closePath(){const S=this.current;if(S.path){const F=`${S.path.getAttributeNS(null,"d")}Z`;S.path.setAttributeNS(null,"d",F)}}setLeading(S){this.current.leading=-S}setTextRise(S){this.current.textRise=S}setTextRenderingMode(S){this.current.textRenderingMode=S}setHScale(S){this.current.textHScale=S/100}setRenderingIntent(S){}setFlatness(S){}setGState(S){for(const[F,A]of S)switch(F){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,a.warn)(`Unimplemented graphic state operator ${F}`);break}}fill(){const S=this.current;S.element&&(S.element.setAttributeNS(null,"fill",S.fillColor),S.element.setAttributeNS(null,"fill-opacity",S.fillAlpha),this.endPath())}stroke(){const S=this.current;S.element&&(this._setStrokeAttributes(S.element),S.element.setAttributeNS(null,"fill","none"),this.endPath())}_setStrokeAttributes(S,F=1){const A=this.current;let D=A.dashArray;F!==1&&D.length>0&&(D=D.map(function(T){return F*T})),S.setAttributeNS(null,"stroke",A.strokeColor),S.setAttributeNS(null,"stroke-opacity",A.strokeAlpha),S.setAttributeNS(null,"stroke-miterlimit",v(A.miterLimit)),S.setAttributeNS(null,"stroke-linecap",A.lineCap),S.setAttributeNS(null,"stroke-linejoin",A.lineJoin),S.setAttributeNS(null,"stroke-width",v(F*A.lineWidth)+"px"),S.setAttributeNS(null,"stroke-dasharray",D.map(v).join(" ")),S.setAttributeNS(null,"stroke-dashoffset",v(F*A.dashPhase)+"px")}eoFill(){var S;(S=this.current.element)==null||S.setAttributeNS(null,"fill-rule","evenodd"),this.fill()}fillStroke(){this.stroke(),this.fill()}eoFillStroke(){var S;(S=this.current.element)==null||S.setAttributeNS(null,"fill-rule","evenodd"),this.fillStroke()}closeStroke(){this.closePath(),this.stroke()}closeFillStroke(){this.closePath(),this.fillStroke()}closeEOFillStroke(){this.closePath(),this.eoFillStroke()}paintSolidColorImageMask(){const S=this.svgFactory.createElement("svg:rect");S.setAttributeNS(null,"x","0"),S.setAttributeNS(null,"y","0"),S.setAttributeNS(null,"width","1px"),S.setAttributeNS(null,"height","1px"),S.setAttributeNS(null,"fill",this.current.fillColor),this._ensureTransformGroup().append(S)}paintImageXObject(S){const F=this.getObject(S);if(!F){(0,a.warn)(`Dependent image with object ID ${S} is not ready yet`);return}this.paintInlineImageXObject(F)}paintInlineImageXObject(S,F){const A=S.width,D=S.height,T=p(S,this.forceDataSchema,!!F),M=this.svgFactory.createElement("svg:rect");M.setAttributeNS(null,"x","0"),M.setAttributeNS(null,"y","0"),M.setAttributeNS(null,"width",v(A)),M.setAttributeNS(null,"height",v(D)),this.current.element=M,this.clip("nonzero");const C=this.svgFactory.createElement("svg:image");C.setAttributeNS(h,"xlink:href",T),C.setAttributeNS(null,"x","0"),C.setAttributeNS(null,"y",v(-D)),C.setAttributeNS(null,"width",v(A)+"px"),C.setAttributeNS(null,"height",v(D)+"px"),C.setAttributeNS(null,"transform",`scale(${v(1/A)} ${v(-1/D)})`),F?F.append(C):this._ensureTransformGroup().append(C)}paintImageMaskXObject(S){const F=this.getObject(S.data,S);if(F.bitmap){(0,a.warn)("paintImageMaskXObject: ImageBitmap support is not implemented, ensure that the `isOffscreenCanvasSupported` API parameter is disabled.");return}const A=this.current,D=F.width,T=F.height,M=A.fillColor;A.maskId=`mask${m++}`;const C=this.svgFactory.createElement("svg:mask");C.setAttributeNS(null,"id",A.maskId);const k=this.svgFactory.createElement("svg:rect");k.setAttributeNS(null,"x","0"),k.setAttributeNS(null,"y","0"),k.setAttributeNS(null,"width",v(D)),k.setAttributeNS(null,"height",v(T)),k.setAttributeNS(null,"fill",M),k.setAttributeNS(null,"mask",`url(#${A.maskId})`),this.defs.append(C),this._ensureTransformGroup().append(k),this.paintInlineImageXObject(F,C)}paintFormXObjectBegin(S,F){if(Array.isArray(S)&&S.length===6&&this.transform(S[0],S[1],S[2],S[3],S[4],S[5]),F){const A=F[2]-F[0],D=F[3]-F[1],T=this.svgFactory.createElement("svg:rect");T.setAttributeNS(null,"x",F[0]),T.setAttributeNS(null,"y",F[1]),T.setAttributeNS(null,"width",v(A)),T.setAttributeNS(null,"height",v(D)),this.current.element=T,this.clip("nonzero"),this.endPath()}}paintFormXObjectEnd(){}_initialize(S){const F=this.svgFactory.create(S.width,S.height),A=this.svgFactory.createElement("svg:defs");F.append(A),this.defs=A;const D=this.svgFactory.createElement("svg:g");return D.setAttributeNS(null,"transform",y(S.transform)),F.append(D),this.svg=D,F}_ensureClipGroup(){if(!this.current.clipGroup){const S=this.svgFactory.createElement("svg:g");S.setAttributeNS(null,"clip-path",this.current.activeClipUrl),this.svg.append(S),this.current.clipGroup=S}return this.current.clipGroup}_ensureTransformGroup(){return this.tgrp||(this.tgrp=this.svgFactory.createElement("svg:g"),this.tgrp.setAttributeNS(null,"transform",y(this.transformMatrix)),this.current.activeClipUrl?this._ensureClipGroup().append(this.tgrp):this.svg.append(this.tgrp)),this.tgrp}}e.SVGGraphics=R},(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.XfaText=void 0;class r{static textContent(a){const s=[],o={items:s,styles:Object.create(null)};function h(d){var p;if(!d)return;let l=null;const u=d.name;if(u==="#text")l=d.value;else if(r.shouldBuildText(u))(p=d==null?void 0:d.attributes)!=null&&p.textContent?l=d.attributes.textContent:d.value&&(l=d.value);else return;if(l!==null&&s.push({str:l}),!!d.children)for(const g of d.children)h(g)}return h(a),o}static shouldBuildText(a){return!(a==="textarea"||a==="input"||a==="option"||a==="select")}}e.XfaText=r},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.TextLayerRenderTask=void 0,e.renderTextLayer=y,e.updateTextLayer=x;var n=r(1),a=r(6);const s=1e5,o=30,h=.8,d=new Map;function l(m,w){let R;if(w&&n.FeatureTest.isOffscreenCanvasSupported)R=new OffscreenCanvas(m,m).getContext("2d",{alpha:!1});else{const _=document.createElement("canvas");_.width=_.height=m,R=_.getContext("2d",{alpha:!1})}return R}function u(m,w){const R=d.get(m);if(R)return R;const _=l(o,w);_.font=`${o}px ${m}`;const S=_.measureText("");let F=S.fontBoundingBoxAscent,A=Math.abs(S.fontBoundingBoxDescent);if(F){const T=F/(F+A);return d.set(m,T),_.canvas.width=_.canvas.height=0,T}_.strokeStyle="red",_.clearRect(0,0,o,o),_.strokeText("g",0,0);let D=_.getImageData(0,0,o,o).data;A=0;for(let T=D.length-1-3;T>=0;T-=4)if(D[T]>0){A=Math.ceil(T/4/o);break}_.clearRect(0,0,o,o),_.strokeText("A",0,o),D=_.getImageData(0,0,o,o).data,F=0;for(let T=0,M=D.length;T<M;T+=4)if(D[T]>0){F=o-Math.floor(T/4/o);break}if(_.canvas.width=_.canvas.height=0,F){const T=F/(F+A);return d.set(m,T),T}return d.set(m,h),h}function p(m,w,R){const _=document.createElement("span"),S={angle:0,canvasWidth:0,hasText:w.str!=="",hasEOL:w.hasEOL,fontSize:0};m._textDivs.push(_);const F=n.Util.transform(m._transform,w.transform);let A=Math.atan2(F[1],F[0]);const D=R[w.fontName];D.vertical&&(A+=Math.PI/2);const T=Math.hypot(F[2],F[3]),M=T*u(D.fontFamily,m._isOffscreenCanvasSupported);let C,k;A===0?(C=F[4],k=F[5]-M):(C=F[4]+M*Math.sin(A),k=F[5]-M*Math.cos(A));const O="calc(var(--scale-factor)*",$=_.style;m._container===m._rootContainer?($.left=`${(100*C/m._pageWidth).toFixed(2)}%`,$.top=`${(100*k/m._pageHeight).toFixed(2)}%`):($.left=`${O}${C.toFixed(2)}px)`,$.top=`${O}${k.toFixed(2)}px)`),$.fontSize=`${O}${T.toFixed(2)}px)`,$.fontFamily=D.fontFamily,S.fontSize=T,_.setAttribute("role","presentation"),_.textContent=w.str,_.dir=w.dir,m._fontInspectorEnabled&&(_.dataset.fontName=w.fontName),A!==0&&(S.angle=A*(180/Math.PI));let K=!1;if(w.str.length>1)K=!0;else if(w.str!==" "&&w.transform[0]!==w.transform[3]){const J=Math.abs(w.transform[0]),Y=Math.abs(w.transform[3]);J!==Y&&Math.max(J,Y)/Math.min(J,Y)>1.5&&(K=!0)}K&&(S.canvasWidth=D.vertical?w.height:w.width),m._textDivProperties.set(_,S),m._isReadableStream&&m._layoutText(_)}function g(m){const{div:w,scale:R,properties:_,ctx:S,prevFontSize:F,prevFontFamily:A}=m,{style:D}=w;let T="";if(_.canvasWidth!==0&&_.hasText){const{fontFamily:M}=D,{canvasWidth:C,fontSize:k}=_;(F!==k||A!==M)&&(S.font=`${k*R}px ${M}`,m.prevFontSize=k,m.prevFontFamily=M);const{width:O}=S.measureText(w.textContent);O>0&&(T=`scaleX(${C*R/O})`)}_.angle!==0&&(T=`rotate(${_.angle}deg) ${T}`),T.length>0&&(D.transform=T)}function f(m){if(m._canceled)return;const w=m._textDivs,R=m._capability;if(w.length>s){R.resolve();return}if(!m._isReadableStream)for(const S of w)m._layoutText(S);R.resolve()}class v{constructor({textContentSource:w,container:R,viewport:_,textDivs:S,textDivProperties:F,textContentItemsStr:A,isOffscreenCanvasSupported:D}){var O;this._textContentSource=w,this._isReadableStream=w instanceof ReadableStream,this._container=this._rootContainer=R,this._textDivs=S||[],this._textContentItemsStr=A||[],this._isOffscreenCanvasSupported=D,this._fontInspectorEnabled=!!((O=globalThis.FontInspector)!=null&&O.enabled),this._reader=null,this._textDivProperties=F||new WeakMap,this._canceled=!1,this._capability=new n.PromiseCapability,this._layoutTextParams={prevFontSize:null,prevFontFamily:null,div:null,scale:_.scale*(globalThis.devicePixelRatio||1),properties:null,ctx:l(0,D)};const{pageWidth:T,pageHeight:M,pageX:C,pageY:k}=_.rawDims;this._transform=[1,0,0,-1,-C,k+M],this._pageWidth=T,this._pageHeight=M,(0,a.setLayerDimensions)(R,_),this._capability.promise.finally(()=>{this._layoutTextParams=null}).catch(()=>{})}get promise(){return this._capability.promise}cancel(){this._canceled=!0,this._reader&&(this._reader.cancel(new n.AbortException("TextLayer task cancelled.")).catch(()=>{}),this._reader=null),this._capability.reject(new n.AbortException("TextLayer task cancelled."))}_processItems(w,R){for(const _ of w){if(_.str===void 0){if(_.type==="beginMarkedContentProps"||_.type==="beginMarkedContent"){const S=this._container;this._container=document.createElement("span"),this._container.classList.add("markedContent"),_.id!==null&&this._container.setAttribute("id",`${_.id}`),S.append(this._container)}else _.type==="endMarkedContent"&&(this._container=this._container.parentNode);continue}this._textContentItemsStr.push(_.str),p(this,_,R)}}_layoutText(w){const R=this._layoutTextParams.properties=this._textDivProperties.get(w);if(this._layoutTextParams.div=w,g(this._layoutTextParams),R.hasText&&this._container.append(w),R.hasEOL){const _=document.createElement("br");_.setAttribute("role","presentation"),this._container.append(_)}}_render(){const w=new n.PromiseCapability;let R=Object.create(null);if(this._isReadableStream){const _=()=>{this._reader.read().then(({value:S,done:F})=>{if(F){w.resolve();return}Object.assign(R,S.styles),this._processItems(S.items,R),_()},w.reject)};this._reader=this._textContentSource.getReader(),_()}else if(this._textContentSource){const{items:_,styles:S}=this._textContentSource;this._processItems(_,S),w.resolve()}else throw new Error('No "textContentSource" parameter specified.');w.promise.then(()=>{R=null,f(this)},this._capability.reject)}}e.TextLayerRenderTask=v;function y(m){!m.textContentSource&&(m.textContent||m.textContentStream)&&((0,a.deprecated)("The TextLayerRender `textContent`/`textContentStream` parameters will be removed in the future, please use `textContentSource` instead."),m.textContentSource=m.textContent||m.textContentStream);const{container:w,viewport:R}=m,_=getComputedStyle(w),S=_.getPropertyValue("visibility"),F=parseFloat(_.getPropertyValue("--scale-factor"));S==="visible"&&(!F||Math.abs(F-R.scale)>1e-5)&&console.error("The `--scale-factor` CSS-variable must be set, to the same value as `viewport.scale`, either on the `container`-element itself or higher up in the DOM.");const A=new v(m);return A._render(),A}function x({container:m,viewport:w,textDivs:R,textDivProperties:_,isOffscreenCanvasSupported:S,mustRotate:F=!0,mustRescale:A=!0}){if(F&&(0,a.setLayerDimensions)(m,{rotation:w.rotation}),A){const D=l(0,S),M={prevFontSize:null,prevFontFamily:null,div:null,scale:w.scale*(globalThis.devicePixelRatio||1),properties:null,ctx:D};for(const C of R)M.properties=_.get(C),M.div=C,g(M)}}},(t,e,r)=>{var u,p,g,f,v,y,x,m,w,R,_,$t,Dt,er,tr;Object.defineProperty(e,"__esModule",{value:!0}),e.AnnotationEditorLayer=void 0;var n=r(1),a=r(4),s=r(28),o=r(33),h=r(6),d=r(34);const T=class T{constructor({uiManager:C,pageIndex:k,div:O,accessibilityManager:$,annotationLayer:K,viewport:J,l10n:Y}){de(this,_);de(this,u);de(this,p,!1);de(this,g,null);de(this,f,this.pointerup.bind(this));de(this,v,this.pointerdown.bind(this));de(this,y,new Map);de(this,x,!1);de(this,m,!1);de(this,w,!1);de(this,R);const se=[s.FreeTextEditor,o.InkEditor,d.StampEditor];if(!T._initialized){T._initialized=!0;for(const B of se)B.initialize(Y)}C.registerEditorTypes(se),ue(this,R,C),this.pageIndex=k,this.div=O,ue(this,u,$),ue(this,g,K),this.viewport=J,b(this,R).addLayer(this)}get isEmpty(){return b(this,y).size===0}updateToolbar(C){b(this,R).updateToolbar(C)}updateMode(C=b(this,R).getMode()){te(this,_,tr).call(this),C===n.AnnotationEditorType.INK?(this.addInkEditorIfNeeded(!1),this.disableClick()):this.enableClick(),C!==n.AnnotationEditorType.NONE&&(this.div.classList.toggle("freeTextEditing",C===n.AnnotationEditorType.FREETEXT),this.div.classList.toggle("inkEditing",C===n.AnnotationEditorType.INK),this.div.classList.toggle("stampEditing",C===n.AnnotationEditorType.STAMP),this.div.hidden=!1)}addInkEditorIfNeeded(C){if(!C&&b(this,R).getMode()!==n.AnnotationEditorType.INK)return;if(!C){for(const O of b(this,y).values())if(O.isEmpty()){O.setInBackground();return}}te(this,_,Dt).call(this,{offsetX:0,offsetY:0},!1).setInBackground()}setEditingState(C){b(this,R).setEditingState(C)}addCommands(C){b(this,R).addCommands(C)}enable(){this.div.style.pointerEvents="auto";const C=new Set;for(const O of b(this,y).values())O.enableEditing(),O.annotationElementId&&C.add(O.annotationElementId);if(!b(this,g))return;const k=b(this,g).getEditableAnnotations();for(const O of k){if(O.hide(),b(this,R).isDeletedAnnotationElement(O.data.id)||C.has(O.data.id))continue;const $=this.deserialize(O);$&&(this.addOrRebuild($),$.enableEditing())}}disable(){var k;ue(this,w,!0),this.div.style.pointerEvents="none";const C=new Set;for(const O of b(this,y).values()){if(O.disableEditing(),!O.annotationElementId||O.serialize()!==null){C.add(O.annotationElementId);continue}(k=this.getEditableAnnotation(O.annotationElementId))==null||k.show(),O.remove()}if(b(this,g)){const O=b(this,g).getEditableAnnotations();for(const $ of O){const{id:K}=$.data;C.has(K)||b(this,R).isDeletedAnnotationElement(K)||$.show()}}te(this,_,tr).call(this),this.isEmpty&&(this.div.hidden=!0),ue(this,w,!1)}getEditableAnnotation(C){var k;return((k=b(this,g))==null?void 0:k.getEditableAnnotation(C))||null}setActiveEditor(C){b(this,R).getActive()!==C&&b(this,R).setActiveEditor(C)}enableClick(){this.div.addEventListener("pointerdown",b(this,v)),this.div.addEventListener("pointerup",b(this,f))}disableClick(){this.div.removeEventListener("pointerdown",b(this,v)),this.div.removeEventListener("pointerup",b(this,f))}attach(C){b(this,y).set(C.id,C);const{annotationElementId:k}=C;k&&b(this,R).isDeletedAnnotationElement(k)&&b(this,R).removeDeletedAnnotationElement(C)}detach(C){var k;b(this,y).delete(C.id),(k=b(this,u))==null||k.removePointerInTextLayer(C.contentDiv),!b(this,w)&&C.annotationElementId&&b(this,R).addDeletedAnnotationElement(C)}remove(C){this.detach(C),b(this,R).removeEditor(C),C.div.contains(document.activeElement)&&setTimeout(()=>{b(this,R).focusMainContainer()},0),C.div.remove(),C.isAttachedToDOM=!1,b(this,m)||this.addInkEditorIfNeeded(!1)}changeParent(C){var k;C.parent!==this&&(C.annotationElementId&&(b(this,R).addDeletedAnnotationElement(C.annotationElementId),a.AnnotationEditor.deleteAnnotationElement(C),C.annotationElementId=null),this.attach(C),(k=C.parent)==null||k.detach(C),C.setParent(this),C.div&&C.isAttachedToDOM&&(C.div.remove(),this.div.append(C.div)))}add(C){if(this.changeParent(C),b(this,R).addEditor(C),this.attach(C),!C.isAttachedToDOM){const k=C.render();this.div.append(k),C.isAttachedToDOM=!0}C.fixAndSetPosition(),C.onceAdded(),b(this,R).addToAnnotationStorage(C)}moveEditorInDOM(C){var O;if(!C.isAttachedToDOM)return;const{activeElement:k}=document;C.div.contains(k)&&(C._focusEventsAllowed=!1,setTimeout(()=>{C.div.contains(document.activeElement)?C._focusEventsAllowed=!0:(C.div.addEventListener("focusin",()=>{C._focusEventsAllowed=!0},{once:!0}),k.focus())},0)),C._structTreeParentId=(O=b(this,u))==null?void 0:O.moveElementInDOM(this.div,C.div,C.contentDiv,!0)}addOrRebuild(C){C.needsToBeRebuilt()?C.rebuild():this.add(C)}addUndoableEditor(C){const k=()=>C._uiManager.rebuild(C),O=()=>{C.remove()};this.addCommands({cmd:k,undo:O,mustExec:!1})}getNextId(){return b(this,R).getId()}pasteEditor(C,k){b(this,R).updateToolbar(C),b(this,R).updateMode(C);const{offsetX:O,offsetY:$}=te(this,_,er).call(this),K=this.getNextId(),J=te(this,_,$t).call(this,{parent:this,id:K,x:O,y:$,uiManager:b(this,R),isCentered:!0,...k});J&&this.add(J)}deserialize(C){switch(C.annotationType??C.annotationEditorType){case n.AnnotationEditorType.FREETEXT:return s.FreeTextEditor.deserialize(C,this,b(this,R));case n.AnnotationEditorType.INK:return o.InkEditor.deserialize(C,this,b(this,R));case n.AnnotationEditorType.STAMP:return d.StampEditor.deserialize(C,this,b(this,R))}return null}addNewEditor(){te(this,_,Dt).call(this,te(this,_,er).call(this),!0)}setSelected(C){b(this,R).setSelected(C)}toggleSelected(C){b(this,R).toggleSelected(C)}isSelected(C){return b(this,R).isSelected(C)}unselect(C){b(this,R).unselect(C)}pointerup(C){const{isMac:k}=n.FeatureTest.platform;if(!(C.button!==0||C.ctrlKey&&k)&&C.target===this.div&&b(this,x)){if(ue(this,x,!1),!b(this,p)){ue(this,p,!0);return}if(b(this,R).getMode()===n.AnnotationEditorType.STAMP){b(this,R).unselectAll();return}te(this,_,Dt).call(this,C,!1)}}pointerdown(C){if(b(this,x)){ue(this,x,!1);return}const{isMac:k}=n.FeatureTest.platform;if(C.button!==0||C.ctrlKey&&k||C.target!==this.div)return;ue(this,x,!0);const O=b(this,R).getActive();ue(this,p,!O||O.isEmpty())}findNewParent(C,k,O){const $=b(this,R).findParent(k,O);return $===null||$===this?!1:($.changeParent(C),!0)}destroy(){var C,k;((C=b(this,R).getActive())==null?void 0:C.parent)===this&&(b(this,R).commitOrRemove(),b(this,R).setActiveEditor(null));for(const O of b(this,y).values())(k=b(this,u))==null||k.removePointerInTextLayer(O.contentDiv),O.setParent(null),O.isAttachedToDOM=!1,O.div.remove();this.div=null,b(this,y).clear(),b(this,R).removeLayer(this)}render({viewport:C}){this.viewport=C,(0,h.setLayerDimensions)(this.div,C);for(const k of b(this,R).getEditors(this.pageIndex))this.add(k);this.updateMode()}update({viewport:C}){b(this,R).commitOrRemove(),this.viewport=C,(0,h.setLayerDimensions)(this.div,{rotation:C.rotation}),this.updateMode()}get pageDimensions(){const{pageWidth:C,pageHeight:k}=this.viewport.rawDims;return[C,k]}};u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakMap,x=new WeakMap,m=new WeakMap,w=new WeakMap,R=new WeakMap,_=new WeakSet,$t=function(C){switch(b(this,R).getMode()){case n.AnnotationEditorType.FREETEXT:return new s.FreeTextEditor(C);case n.AnnotationEditorType.INK:return new o.InkEditor(C);case n.AnnotationEditorType.STAMP:return new d.StampEditor(C)}return null},Dt=function(C,k){const O=this.getNextId(),$=te(this,_,$t).call(this,{parent:this,id:O,x:C.offsetX,y:C.offsetY,uiManager:b(this,R),isCentered:k});return $&&this.add($),$},er=function(){const{x:C,y:k,width:O,height:$}=this.div.getBoundingClientRect(),K=Math.max(0,C),J=Math.max(0,k),Y=Math.min(window.innerWidth,C+O),se=Math.min(window.innerHeight,k+$),B=(K+Y)/2-C,V=(J+se)/2-k,[Q,N]=this.viewport.rotation%180===0?[B,V]:[V,B];return{offsetX:Q,offsetY:N}},tr=function(){ue(this,m,!0);for(const C of b(this,y).values())C.isEmpty()&&C.remove();ue(this,m,!1)},$e(T,"_initialized",!1);let l=T;e.AnnotationEditorLayer=l},(t,e,r)=>{var d,l,u,p,g,f,v,y,x,m,Tr,_r,Rr,yt,rr,kr,nr;Object.defineProperty(e,"__esModule",{value:!0}),e.FreeTextEditor=void 0;var n=r(1),a=r(5),s=r(4),o=r(29);const T=class T extends s.AnnotationEditor{constructor(k){super({...k,name:"freeTextEditor"});de(this,m);de(this,d,this.editorDivBlur.bind(this));de(this,l,this.editorDivFocus.bind(this));de(this,u,this.editorDivInput.bind(this));de(this,p,this.editorDivKeydown.bind(this));de(this,g);de(this,f,"");de(this,v,`${this.id}-editor`);de(this,y);de(this,x,null);ue(this,g,k.color||T._defaultColor||s.AnnotationEditor._defaultLineColor),ue(this,y,k.fontSize||T._defaultFontSize)}static get _keyboardManager(){const k=T.prototype,O=J=>J.isEmpty(),$=a.AnnotationEditorUIManager.TRANSLATE_SMALL,K=a.AnnotationEditorUIManager.TRANSLATE_BIG;return(0,n.shadow)(this,"_keyboardManager",new a.KeyboardManager([[["ctrl+s","mac+meta+s","ctrl+p","mac+meta+p"],k.commitOrRemove,{bubbles:!0}],[["ctrl+Enter","mac+meta+Enter","Escape","mac+Escape"],k.commitOrRemove],[["ArrowLeft","mac+ArrowLeft"],k._translateEmpty,{args:[-$,0],checker:O}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],k._translateEmpty,{args:[-K,0],checker:O}],[["ArrowRight","mac+ArrowRight"],k._translateEmpty,{args:[$,0],checker:O}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],k._translateEmpty,{args:[K,0],checker:O}],[["ArrowUp","mac+ArrowUp"],k._translateEmpty,{args:[0,-$],checker:O}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],k._translateEmpty,{args:[0,-K],checker:O}],[["ArrowDown","mac+ArrowDown"],k._translateEmpty,{args:[0,$],checker:O}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],k._translateEmpty,{args:[0,K],checker:O}]]))}static initialize(k){s.AnnotationEditor.initialize(k,{strings:["free_text2_default_content","editor_free_text2_aria_label"]});const O=getComputedStyle(document.documentElement);this._internalPadding=parseFloat(O.getPropertyValue("--freetext-padding"))}static updateDefaultParams(k,O){switch(k){case n.AnnotationEditorParamsType.FREETEXT_SIZE:T._defaultFontSize=O;break;case n.AnnotationEditorParamsType.FREETEXT_COLOR:T._defaultColor=O;break}}updateParams(k,O){switch(k){case n.AnnotationEditorParamsType.FREETEXT_SIZE:te(this,m,Tr).call(this,O);break;case n.AnnotationEditorParamsType.FREETEXT_COLOR:te(this,m,_r).call(this,O);break}}static get defaultPropertiesToUpdate(){return[[n.AnnotationEditorParamsType.FREETEXT_SIZE,T._defaultFontSize],[n.AnnotationEditorParamsType.FREETEXT_COLOR,T._defaultColor||s.AnnotationEditor._defaultLineColor]]}get propertiesToUpdate(){return[[n.AnnotationEditorParamsType.FREETEXT_SIZE,b(this,y)],[n.AnnotationEditorParamsType.FREETEXT_COLOR,b(this,g)]]}_translateEmpty(k,O){this._uiManager.translateSelectedEditors(k,O,!0)}getInitialTranslation(){const k=this.parentScale;return[-T._internalPadding*k,-(T._internalPadding+b(this,y))*k]}rebuild(){this.parent&&(super.rebuild(),this.div!==null&&(this.isAttachedToDOM||this.parent.add(this)))}enableEditMode(){this.isInEditMode()||(this.parent.setEditingState(!1),this.parent.updateToolbar(n.AnnotationEditorType.FREETEXT),super.enableEditMode(),this.overlayDiv.classList.remove("enabled"),this.editorDiv.contentEditable=!0,this._isDraggable=!1,this.div.removeAttribute("aria-activedescendant"),this.editorDiv.addEventListener("keydown",b(this,p)),this.editorDiv.addEventListener("focus",b(this,l)),this.editorDiv.addEventListener("blur",b(this,d)),this.editorDiv.addEventListener("input",b(this,u)))}disableEditMode(){this.isInEditMode()&&(this.parent.setEditingState(!0),super.disableEditMode(),this.overlayDiv.classList.add("enabled"),this.editorDiv.contentEditable=!1,this.div.setAttribute("aria-activedescendant",b(this,v)),this._isDraggable=!0,this.editorDiv.removeEventListener("keydown",b(this,p)),this.editorDiv.removeEventListener("focus",b(this,l)),this.editorDiv.removeEventListener("blur",b(this,d)),this.editorDiv.removeEventListener("input",b(this,u)),this.div.focus({preventScroll:!0}),this.isEditing=!1,this.parent.div.classList.add("freeTextEditing"))}focusin(k){this._focusEventsAllowed&&(super.focusin(k),k.target!==this.editorDiv&&this.editorDiv.focus())}onceAdded(){var k;if(this.width){te(this,m,nr).call(this);return}this.enableEditMode(),this.editorDiv.focus(),(k=this._initialOptions)!=null&&k.isCentered&&this.center(),this._initialOptions=null}isEmpty(){return!this.editorDiv||this.editorDiv.innerText.trim()===""}remove(){this.isEditing=!1,this.parent&&(this.parent.setEditingState(!0),this.parent.div.classList.add("freeTextEditing")),super.remove()}commit(){if(!this.isInEditMode())return;super.commit(),this.disableEditMode();const k=b(this,f),O=ue(this,f,te(this,m,Rr).call(this).trimEnd());if(k===O)return;const $=K=>{if(ue(this,f,K),!K){this.remove();return}te(this,m,rr).call(this),this._uiManager.rebuild(this),te(this,m,yt).call(this)};this.addCommands({cmd:()=>{$(O)},undo:()=>{$(k)},mustExec:!1}),te(this,m,yt).call(this)}shouldGetKeyboardEvents(){return this.isInEditMode()}enterInEditMode(){this.enableEditMode(),this.editorDiv.focus()}dblclick(k){this.enterInEditMode()}keydown(k){k.target===this.div&&k.key==="Enter"&&(this.enterInEditMode(),k.preventDefault())}editorDivKeydown(k){T._keyboardManager.exec(this,k)}editorDivFocus(k){this.isEditing=!0}editorDivBlur(k){this.isEditing=!1}editorDivInput(k){this.parent.div.classList.toggle("freeTextEditing",this.isEmpty())}disableEditing(){this.editorDiv.setAttribute("role","comment"),this.editorDiv.removeAttribute("aria-multiline")}enableEditing(){this.editorDiv.setAttribute("role","textbox"),this.editorDiv.setAttribute("aria-multiline",!0)}render(){if(this.div)return this.div;let k,O;this.width&&(k=this.x,O=this.y),super.render(),this.editorDiv=document.createElement("div"),this.editorDiv.className="internal",this.editorDiv.setAttribute("id",b(this,v)),this.enableEditing(),s.AnnotationEditor._l10nPromise.get("editor_free_text2_aria_label").then(K=>{var J;return(J=this.editorDiv)==null?void 0:J.setAttribute("aria-label",K)}),s.AnnotationEditor._l10nPromise.get("free_text2_default_content").then(K=>{var J;return(J=this.editorDiv)==null?void 0:J.setAttribute("default-content",K)}),this.editorDiv.contentEditable=!0;const{style:$}=this.editorDiv;if($.fontSize=`calc(${b(this,y)}px * var(--scale-factor))`,$.color=b(this,g),this.div.append(this.editorDiv),this.overlayDiv=document.createElement("div"),this.overlayDiv.classList.add("overlay","enabled"),this.div.append(this.overlayDiv),(0,a.bindEvents)(this,this.div,["dblclick","keydown"]),this.width){const[K,J]=this.parentDimensions;if(this.annotationElementId){const{position:Y}=b(this,x);let[se,B]=this.getInitialTranslation();[se,B]=this.pageTranslationToScreen(se,B);const[V,Q]=this.pageDimensions,[N,P]=this.pageTranslation;let E,I;switch(this.rotation){case 0:E=k+(Y[0]-N)/V,I=O+this.height-(Y[1]-P)/Q;break;case 90:E=k+(Y[0]-N)/V,I=O-(Y[1]-P)/Q,[se,B]=[B,-se];break;case 180:E=k-this.width+(Y[0]-N)/V,I=O-(Y[1]-P)/Q,[se,B]=[-se,-B];break;case 270:E=k+(Y[0]-N-this.height*Q)/V,I=O+(Y[1]-P-this.width*V)/Q,[se,B]=[-B,se];break}this.setAt(E*K,I*J,se,B)}else this.setAt(k*K,O*J,this.width*K,this.height*J);te(this,m,rr).call(this),this._isDraggable=!0,this.editorDiv.contentEditable=!1}else this._isDraggable=!1,this.editorDiv.contentEditable=!0;return this.div}get contentDiv(){return this.editorDiv}static deserialize(k,O,$){let K=null;if(k instanceof o.FreeTextAnnotationElement){const{data:{defaultAppearanceData:{fontSize:Y,fontColor:se},rect:B,rotation:V,id:Q},textContent:N,textPosition:P,parent:{page:{pageNumber:E}}}=k;if(!N||N.length===0)return null;K=k={annotationType:n.AnnotationEditorType.FREETEXT,color:Array.from(se),fontSize:Y,value:N.join(`
|
|
5
|
-
`),position:P,pageIndex:E-1,rect:B,rotation:V,id:Q,deleted:!1}}const J=super.deserialize(k,O,$);return ue(J,y,k.fontSize),ue(J,g,n.Util.makeHexColor(...k.color)),ue(J,f,k.value),J.annotationElementId=k.id||null,ue(J,
|
|
1
|
+
(function(t,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("react/jsx-runtime"),require("react")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react"],e):(t=typeof globalThis<"u"?globalThis:t||self,e(t.ReactPdfAnnotator={},t.jsxRuntime,t.React))})(this,function(exports,jsxRuntime,react){"use strict";var Qr=Object.defineProperty;var mr=t=>{throw TypeError(t)};var $r=(t,e,r)=>e in t?Qr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var $e=(t,e,r)=>$r(t,typeof e!="symbol"?e+"":e,r),Nt=(t,e,r)=>e.has(t)||mr("Cannot "+r);var b=(t,e,r)=>(Nt(t,e,"read from private field"),r?r.call(t):e.get(t)),de=(t,e,r)=>e.has(t)?mr("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,r),ue=(t,e,r,n)=>(Nt(t,e,"write to private field"),n?n.call(t,r):e.set(t,r),r),te=(t,e,r)=>(Nt(t,e,"access private method"),r);var ft=(t,e,r,n)=>({set _(a){ue(t,e,a,r)},get _(){return b(t,e,n)}});function getDefaultExportFromCjs(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function getAugmentedNamespace(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var r=function n(){return this instanceof n?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var a=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(r,n,a.get?a:{enumerable:!0,get:function(){return t[n]}})}),r}function commonjsRequire(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var pdf={exports:{}};const __viteBrowserExternal={},__viteBrowserExternal$1=Object.freeze(Object.defineProperty({__proto__:null,default:__viteBrowserExternal},Symbol.toStringTag,{value:"Module"})),require$$5=getAugmentedNamespace(__viteBrowserExternal$1);(function(module,exports$1){(function(e,r){module.exports=e.pdfjsLib=r()})(globalThis,()=>(()=>{var __webpack_modules__=[,(t,e)=>{var ze;Object.defineProperty(e,"__esModule",{value:!0}),e.VerbosityLevel=e.Util=e.UnknownErrorException=e.UnexpectedResponseException=e.TextRenderingMode=e.RenderingIntentFlag=e.PromiseCapability=e.PermissionFlag=e.PasswordResponses=e.PasswordException=e.PageActionEventType=e.OPS=e.MissingPDFException=e.MAX_IMAGE_SIZE_TO_CACHE=e.LINE_FACTOR=e.LINE_DESCENT_FACTOR=e.InvalidPDFException=e.ImageKind=e.IDENTITY_MATRIX=e.FormatError=e.FeatureTest=e.FONT_IDENTITY_MATRIX=e.DocumentActionEventType=e.CMapCompressionType=e.BaseException=e.BASELINE_FACTOR=e.AnnotationType=e.AnnotationReplyType=e.AnnotationPrefix=e.AnnotationMode=e.AnnotationFlag=e.AnnotationFieldFlag=e.AnnotationEditorType=e.AnnotationEditorPrefix=e.AnnotationEditorParamsType=e.AnnotationBorderStyleType=e.AnnotationActionEventType=e.AbortException=void 0,e.assert=B,e.bytesToString=ve,e.createValidAbsoluteUrl=Q,e.getModificationDate=Te,e.getUuid=Ee,e.getVerbosityLevel=K,e.info=J,e.isArrayBuffer=ie,e.isArrayEqual=_e,e.isNodeJS=void 0,e.normalizeUnicode=Me,e.objectFromMap=Ce,e.objectSize=Se,e.setVerbosityLevel=$,e.shadow=N,e.string32=xe,e.stringToBytes=me,e.stringToPDFString=ye,e.stringToUTF8String=Fe,e.unreachable=se,e.utf8StringToString=Pe,e.warn=Y;const r=typeof process=="object"&&process+""=="[object process]"&&!process.versions.nw&&!(process.versions.electron&&process.type&&process.type!=="browser");e.isNodeJS=r;const n=[1,0,0,1,0,0];e.IDENTITY_MATRIX=n;const a=[.001,0,0,.001,0,0];e.FONT_IDENTITY_MATRIX=a;const s=1e7;e.MAX_IMAGE_SIZE_TO_CACHE=s;const o=1.35;e.LINE_FACTOR=o;const h=.35;e.LINE_DESCENT_FACTOR=h;const d=h/o;e.BASELINE_FACTOR=d;const l={ANY:1,DISPLAY:2,PRINT:4,SAVE:8,ANNOTATIONS_FORMS:16,ANNOTATIONS_STORAGE:32,ANNOTATIONS_DISABLE:64,OPLIST:256};e.RenderingIntentFlag=l;const u={DISABLE:0,ENABLE:1,ENABLE_FORMS:2,ENABLE_STORAGE:3};e.AnnotationMode=u;const p="pdfjs_internal_editor_";e.AnnotationEditorPrefix=p;const g={DISABLE:-1,NONE:0,FREETEXT:3,STAMP:13,INK:15};e.AnnotationEditorType=g;const f={RESIZE:1,CREATE:2,FREETEXT_SIZE:11,FREETEXT_COLOR:12,FREETEXT_OPACITY:13,INK_COLOR:21,INK_THICKNESS:22,INK_OPACITY:23};e.AnnotationEditorParamsType=f;const v={PRINT:4,MODIFY_CONTENTS:8,COPY:16,MODIFY_ANNOTATIONS:32,FILL_INTERACTIVE_FORMS:256,COPY_FOR_ACCESSIBILITY:512,ASSEMBLE:1024,PRINT_HIGH_QUALITY:2048};e.PermissionFlag=v;const y={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};e.TextRenderingMode=y;const S={GRAYSCALE_1BPP:1,RGB_24BPP:2,RGBA_32BPP:3};e.ImageKind=S;const m={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};e.AnnotationType=m;const w={GROUP:"Group",REPLY:"R"};e.AnnotationReplyType=w;const R={INVISIBLE:1,HIDDEN:2,PRINT:4,NOZOOM:8,NOROTATE:16,NOVIEW:32,READONLY:64,LOCKED:128,TOGGLENOVIEW:256,LOCKEDCONTENTS:512};e.AnnotationFlag=R;const _={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};e.AnnotationFieldFlag=_;const x={SOLID:1,DASHED:2,BEVELED:3,INSET:4,UNDERLINE:5};e.AnnotationBorderStyleType=x;const F={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"};e.AnnotationActionEventType=F;const A={WC:"WillClose",WS:"WillSave",DS:"DidSave",WP:"WillPrint",DP:"DidPrint"};e.DocumentActionEventType=A;const D={O:"PageOpen",C:"PageClose"};e.PageActionEventType=D;const T={ERRORS:0,WARNINGS:1,INFOS:5};e.VerbosityLevel=T;const M={NONE:0,BINARY:1};e.CMapCompressionType=M;const C={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,beginAnnotation:80,endAnnotation:81,paintImageMaskXObject:83,paintImageMaskXObjectGroup:84,paintImageXObject:85,paintInlineImageXObject:86,paintInlineImageXObjectGroup:87,paintImageXObjectRepeat:88,paintImageMaskXObjectRepeat:89,paintSolidColorImageMask:90,constructPath:91};e.OPS=C;const k={NEED_PASSWORD:1,INCORRECT_PASSWORD:2};e.PasswordResponses=k;let O=T.WARNINGS;function $(be){Number.isInteger(be)&&(O=be)}function K(){return O}function J(be){O>=T.INFOS&&console.log(`Info: ${be}`)}function Y(be){O>=T.WARNINGS&&console.log(`Warning: ${be}`)}function se(be){throw new Error(be)}function B(be,oe){be||se(oe)}function V(be){switch(be==null?void 0:be.protocol){case"http:":case"https:":case"ftp:":case"mailto:":case"tel:":return!0;default:return!1}}function Q(be,oe=null,ae=null){if(!be)return null;try{if(ae&&typeof be=="string"){if(ae.addDefaultProtocol&&be.startsWith("www.")){const We=be.match(/\./g);(We==null?void 0:We.length)>=2&&(be=`http://${be}`)}if(ae.tryConvertEncoding)try{be=Fe(be)}catch{}}const Re=oe?new URL(be,oe):new URL(be);if(V(Re))return Re}catch{}return null}function N(be,oe,ae,Re=!1){return Object.defineProperty(be,oe,{value:ae,enumerable:!Re,configurable:!0,writable:!1}),ae}const P=function(){function oe(ae,Re){this.constructor===oe&&se("Cannot initialize BaseException."),this.message=ae,this.name=Re}return oe.prototype=new Error,oe.constructor=oe,oe}();e.BaseException=P;class E extends P{constructor(oe,ae){super(oe,"PasswordException"),this.code=ae}}e.PasswordException=E;class I extends P{constructor(oe,ae){super(oe,"UnknownErrorException"),this.details=ae}}e.UnknownErrorException=I;class z extends P{constructor(oe){super(oe,"InvalidPDFException")}}e.InvalidPDFException=z;class G extends P{constructor(oe){super(oe,"MissingPDFException")}}e.MissingPDFException=G;class H extends P{constructor(oe,ae){super(oe,"UnexpectedResponseException"),this.status=ae}}e.UnexpectedResponseException=H;class ee extends P{constructor(oe){super(oe,"FormatError")}}e.FormatError=ee;class ce extends P{constructor(oe){super(oe,"AbortException")}}e.AbortException=ce;function ve(be){(typeof be!="object"||(be==null?void 0:be.length)===void 0)&&se("Invalid argument for bytesToString");const oe=be.length,ae=8192;if(oe<ae)return String.fromCharCode.apply(null,be);const Re=[];for(let We=0;We<oe;We+=ae){const Ve=Math.min(We+ae,oe),X=be.subarray(We,Ve);Re.push(String.fromCharCode.apply(null,X))}return Re.join("")}function me(be){typeof be!="string"&&se("Invalid argument for stringToBytes");const oe=be.length,ae=new Uint8Array(oe);for(let Re=0;Re<oe;++Re)ae[Re]=be.charCodeAt(Re)&255;return ae}function xe(be){return String.fromCharCode(be>>24&255,be>>16&255,be>>8&255,be&255)}function Se(be){return Object.keys(be).length}function Ce(be){const oe=Object.create(null);for(const[ae,Re]of be)oe[ae]=Re;return oe}function ne(){const be=new Uint8Array(4);return be[0]=1,new Uint32Array(be.buffer,0,1)[0]===1}function le(){try{return new Function(""),!0}catch{return!1}}class L{static get isLittleEndian(){return N(this,"isLittleEndian",ne())}static get isEvalSupported(){return N(this,"isEvalSupported",le())}static get isOffscreenCanvasSupported(){return N(this,"isOffscreenCanvasSupported",typeof OffscreenCanvas<"u")}static get platform(){return typeof navigator>"u"?N(this,"platform",{isWin:!1,isMac:!1}):N(this,"platform",{isWin:navigator.platform.includes("Win"),isMac:navigator.platform.includes("Mac")})}static get isCSSRoundSupported(){var oe,ae;return N(this,"isCSSRoundSupported",(ae=(oe=globalThis.CSS)==null?void 0:oe.supports)==null?void 0:ae.call(oe,"width: round(1.5px, 1px)"))}}e.FeatureTest=L;const Z=[...Array(256).keys()].map(be=>be.toString(16).padStart(2,"0"));class re{static makeHexColor(oe,ae,Re){return`#${Z[oe]}${Z[ae]}${Z[Re]}`}static scaleMinMax(oe,ae){let Re;oe[0]?(oe[0]<0&&(Re=ae[0],ae[0]=ae[1],ae[1]=Re),ae[0]*=oe[0],ae[1]*=oe[0],oe[3]<0&&(Re=ae[2],ae[2]=ae[3],ae[3]=Re),ae[2]*=oe[3],ae[3]*=oe[3]):(Re=ae[0],ae[0]=ae[2],ae[2]=Re,Re=ae[1],ae[1]=ae[3],ae[3]=Re,oe[1]<0&&(Re=ae[2],ae[2]=ae[3],ae[3]=Re),ae[2]*=oe[1],ae[3]*=oe[1],oe[2]<0&&(Re=ae[0],ae[0]=ae[1],ae[1]=Re),ae[0]*=oe[2],ae[1]*=oe[2]),ae[0]+=oe[4],ae[1]+=oe[4],ae[2]+=oe[5],ae[3]+=oe[5]}static transform(oe,ae){return[oe[0]*ae[0]+oe[2]*ae[1],oe[1]*ae[0]+oe[3]*ae[1],oe[0]*ae[2]+oe[2]*ae[3],oe[1]*ae[2]+oe[3]*ae[3],oe[0]*ae[4]+oe[2]*ae[5]+oe[4],oe[1]*ae[4]+oe[3]*ae[5]+oe[5]]}static applyTransform(oe,ae){const Re=oe[0]*ae[0]+oe[1]*ae[2]+ae[4],We=oe[0]*ae[1]+oe[1]*ae[3]+ae[5];return[Re,We]}static applyInverseTransform(oe,ae){const Re=ae[0]*ae[3]-ae[1]*ae[2],We=(oe[0]*ae[3]-oe[1]*ae[2]+ae[2]*ae[5]-ae[4]*ae[3])/Re,Ve=(-oe[0]*ae[1]+oe[1]*ae[0]+ae[4]*ae[1]-ae[5]*ae[0])/Re;return[We,Ve]}static getAxialAlignedBoundingBox(oe,ae){const Re=this.applyTransform(oe,ae),We=this.applyTransform(oe.slice(2,4),ae),Ve=this.applyTransform([oe[0],oe[3]],ae),X=this.applyTransform([oe[2],oe[1]],ae);return[Math.min(Re[0],We[0],Ve[0],X[0]),Math.min(Re[1],We[1],Ve[1],X[1]),Math.max(Re[0],We[0],Ve[0],X[0]),Math.max(Re[1],We[1],Ve[1],X[1])]}static inverseTransform(oe){const ae=oe[0]*oe[3]-oe[1]*oe[2];return[oe[3]/ae,-oe[1]/ae,-oe[2]/ae,oe[0]/ae,(oe[2]*oe[5]-oe[4]*oe[3])/ae,(oe[4]*oe[1]-oe[5]*oe[0])/ae]}static singularValueDecompose2dScale(oe){const ae=[oe[0],oe[2],oe[1],oe[3]],Re=oe[0]*ae[0]+oe[1]*ae[2],We=oe[0]*ae[1]+oe[1]*ae[3],Ve=oe[2]*ae[0]+oe[3]*ae[2],X=oe[2]*ae[1]+oe[3]*ae[3],ge=(Re+X)/2,ke=Math.sqrt((Re+X)**2-4*(Re*X-Ve*We))/2,Be=ge+ke||1,He=ge-ke||1;return[Math.sqrt(Be),Math.sqrt(He)]}static normalizeRect(oe){const ae=oe.slice(0);return oe[0]>oe[2]&&(ae[0]=oe[2],ae[2]=oe[0]),oe[1]>oe[3]&&(ae[1]=oe[3],ae[3]=oe[1]),ae}static intersect(oe,ae){const Re=Math.max(Math.min(oe[0],oe[2]),Math.min(ae[0],ae[2])),We=Math.min(Math.max(oe[0],oe[2]),Math.max(ae[0],ae[2]));if(Re>We)return null;const Ve=Math.max(Math.min(oe[1],oe[3]),Math.min(ae[1],ae[3])),X=Math.min(Math.max(oe[1],oe[3]),Math.max(ae[1],ae[3]));return Ve>X?null:[Re,Ve,We,X]}static bezierBoundingBox(oe,ae,Re,We,Ve,X,ge,ke){const Be=[],He=[[],[]];let Ne,U,j,W,fe,pe,Ae,we;for(let Ge=0;Ge<2;++Ge){if(Ge===0?(U=6*oe-12*Re+6*Ve,Ne=-3*oe+9*Re-9*Ve+3*ge,j=3*Re-3*oe):(U=6*ae-12*We+6*X,Ne=-3*ae+9*We-9*X+3*ke,j=3*We-3*ae),Math.abs(Ne)<1e-12){if(Math.abs(U)<1e-12)continue;W=-j/U,0<W&&W<1&&Be.push(W);continue}Ae=U*U-4*j*Ne,we=Math.sqrt(Ae),!(Ae<0)&&(fe=(-U+we)/(2*Ne),0<fe&&fe<1&&Be.push(fe),pe=(-U-we)/(2*Ne),0<pe&&pe<1&&Be.push(pe))}let je=Be.length,Le;const De=je;for(;je--;)W=Be[je],Le=1-W,He[0][je]=Le*Le*Le*oe+3*Le*Le*W*Re+3*Le*W*W*Ve+W*W*W*ge,He[1][je]=Le*Le*Le*ae+3*Le*Le*W*We+3*Le*W*W*X+W*W*W*ke;return He[0][De]=oe,He[1][De]=ae,He[0][De+1]=ge,He[1][De+1]=ke,He[0].length=He[1].length=De+2,[Math.min(...He[0]),Math.min(...He[1]),Math.max(...He[0]),Math.max(...He[1])]}}e.Util=re;const he=[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 ye(be){if(be[0]>="ï"){let ae;if(be[0]==="þ"&&be[1]==="ÿ"?ae="utf-16be":be[0]==="ÿ"&&be[1]==="þ"?ae="utf-16le":be[0]==="ï"&&be[1]==="»"&&be[2]==="¿"&&(ae="utf-8"),ae)try{const Re=new TextDecoder(ae,{fatal:!0}),We=me(be);return Re.decode(We)}catch(Re){Y(`stringToPDFString: "${Re}".`)}}const oe=[];for(let ae=0,Re=be.length;ae<Re;ae++){const We=he[be.charCodeAt(ae)];oe.push(We?String.fromCharCode(We):be.charAt(ae))}return oe.join("")}function Fe(be){return decodeURIComponent(escape(be))}function Pe(be){return unescape(encodeURIComponent(be))}function ie(be){return typeof be=="object"&&(be==null?void 0:be.byteLength)!==void 0}function _e(be,oe){if(be.length!==oe.length)return!1;for(let ae=0,Re=be.length;ae<Re;ae++)if(be[ae]!==oe[ae])return!1;return!0}function Te(be=new Date){return[be.getUTCFullYear().toString(),(be.getUTCMonth()+1).toString().padStart(2,"0"),be.getUTCDate().toString().padStart(2,"0"),be.getUTCHours().toString().padStart(2,"0"),be.getUTCMinutes().toString().padStart(2,"0"),be.getUTCSeconds().toString().padStart(2,"0")].join("")}class Ke{constructor(){de(this,ze,!1);this.promise=new Promise((oe,ae)=>{this.resolve=Re=>{ue(this,ze,!0),oe(Re)},this.reject=Re=>{ue(this,ze,!0),ae(Re)}})}get settled(){return b(this,ze)}}ze=new WeakMap,e.PromiseCapability=Ke;let qe=null,Ye=null;function Me(be){return qe||(qe=/([\u00a0\u00b5\u037e\u0eb3\u2000-\u200a\u202f\u2126\ufb00-\ufb04\ufb06\ufb20-\ufb36\ufb38-\ufb3c\ufb3e\ufb40-\ufb41\ufb43-\ufb44\ufb46-\ufba1\ufba4-\ufba9\ufbae-\ufbb1\ufbd3-\ufbdc\ufbde-\ufbe7\ufbea-\ufbf8\ufbfc-\ufbfd\ufc00-\ufc5d\ufc64-\ufcf1\ufcf5-\ufd3d\ufd88\ufdf4\ufdfa-\ufdfb\ufe71\ufe77\ufe79\ufe7b\ufe7d]+)|(\ufb05+)/gu,Ye=new Map([["ſt","ſt"]])),be.replaceAll(qe,(oe,ae,Re)=>ae?ae.normalize("NFKC"):Ye.get(Re))}function Ee(){if(typeof crypto<"u"&&typeof(crypto==null?void 0:crypto.randomUUID)=="function")return crypto.randomUUID();const be=new Uint8Array(32);if(typeof crypto<"u"&&typeof(crypto==null?void 0:crypto.getRandomValues)=="function")crypto.getRandomValues(be);else for(let oe=0;oe<32;oe++)be[oe]=Math.floor(Math.random()*255);return ve(be)}const Ie="pdfjs_internal_id_";e.AnnotationPrefix=Ie},(__unused_webpack_module,exports$1,__w_pdfjs_require__)=>{var t,r,n,a,lt,St,h,d,l,u,p,g,f,v,y,At,m,w,Mt,_,x;Object.defineProperty(exports$1,"__esModule",{value:!0}),exports$1.RenderTask=exports$1.PDFWorkerUtil=exports$1.PDFWorker=exports$1.PDFPageProxy=exports$1.PDFDocumentProxy=exports$1.PDFDocumentLoadingTask=exports$1.PDFDataRangeTransport=exports$1.LoopbackPort=exports$1.DefaultStandardFontDataFactory=exports$1.DefaultFilterFactory=exports$1.DefaultCanvasFactory=exports$1.DefaultCMapReaderFactory=void 0,Object.defineProperty(exports$1,"SVGGraphics",{enumerable:!0,get:function(){return _displaySvg.SVGGraphics}}),exports$1.build=void 0,exports$1.getDocument=getDocument,exports$1.version=void 0;var _util=__w_pdfjs_require__(1),_annotation_storage=__w_pdfjs_require__(3),_display_utils=__w_pdfjs_require__(6),_font_loader=__w_pdfjs_require__(9),_displayNode_utils=__w_pdfjs_require__(10),_canvas=__w_pdfjs_require__(11),_worker_options=__w_pdfjs_require__(14),_message_handler=__w_pdfjs_require__(15),_metadata=__w_pdfjs_require__(16),_optional_content_config=__w_pdfjs_require__(17),_transport_stream=__w_pdfjs_require__(18),_displayFetch_stream=__w_pdfjs_require__(19),_displayNetwork=__w_pdfjs_require__(22),_displayNode_stream=__w_pdfjs_require__(23),_displaySvg=__w_pdfjs_require__(24),_xfa_text=__w_pdfjs_require__(25);const DEFAULT_RANGE_CHUNK_SIZE=65536,RENDERING_CANCELLED_TIMEOUT=100,DELAYED_CLEANUP_TIMEOUT=5e3,DefaultCanvasFactory=_util.isNodeJS?_displayNode_utils.NodeCanvasFactory:_display_utils.DOMCanvasFactory;exports$1.DefaultCanvasFactory=DefaultCanvasFactory;const DefaultCMapReaderFactory=_util.isNodeJS?_displayNode_utils.NodeCMapReaderFactory:_display_utils.DOMCMapReaderFactory;exports$1.DefaultCMapReaderFactory=DefaultCMapReaderFactory;const DefaultFilterFactory=_util.isNodeJS?_displayNode_utils.NodeFilterFactory:_display_utils.DOMFilterFactory;exports$1.DefaultFilterFactory=DefaultFilterFactory;const DefaultStandardFontDataFactory=_util.isNodeJS?_displayNode_utils.NodeStandardFontDataFactory:_display_utils.DOMStandardFontDataFactory;exports$1.DefaultStandardFontDataFactory=DefaultStandardFontDataFactory;function getDocument(A){if(typeof A=="string"||A instanceof URL?A={url:A}:(0,_util.isArrayBuffer)(A)&&(A={data:A}),typeof A!="object")throw new Error("Invalid parameter in getDocument, need parameter object.");if(!A.url&&!A.data&&!A.range)throw new Error("Invalid parameter object: need either .data, .range or .url");const D=new PDFDocumentLoadingTask,{docId:T}=D,M=A.url?getUrlProp(A.url):null,C=A.data?getDataProp(A.data):null,k=A.httpHeaders||null,O=A.withCredentials===!0,$=A.password??null,K=A.range instanceof PDFDataRangeTransport?A.range:null,J=Number.isInteger(A.rangeChunkSize)&&A.rangeChunkSize>0?A.rangeChunkSize:DEFAULT_RANGE_CHUNK_SIZE;let Y=A.worker instanceof PDFWorker?A.worker:null;const se=A.verbosity,B=typeof A.docBaseUrl=="string"&&!(0,_display_utils.isDataScheme)(A.docBaseUrl)?A.docBaseUrl:null,V=typeof A.cMapUrl=="string"?A.cMapUrl:null,Q=A.cMapPacked!==!1,N=A.CMapReaderFactory||DefaultCMapReaderFactory,P=typeof A.standardFontDataUrl=="string"?A.standardFontDataUrl:null,E=A.StandardFontDataFactory||DefaultStandardFontDataFactory,I=A.stopAtErrors!==!0,z=Number.isInteger(A.maxImageSize)&&A.maxImageSize>-1?A.maxImageSize:-1,G=A.isEvalSupported!==!1,H=typeof A.isOffscreenCanvasSupported=="boolean"?A.isOffscreenCanvasSupported:!_util.isNodeJS,ee=Number.isInteger(A.canvasMaxAreaInBytes)?A.canvasMaxAreaInBytes:-1,ce=typeof A.disableFontFace=="boolean"?A.disableFontFace:_util.isNodeJS,ve=A.fontExtraProperties===!0,me=A.enableXfa===!0,xe=A.ownerDocument||globalThis.document,Se=A.disableRange===!0,Ce=A.disableStream===!0,ne=A.disableAutoFetch===!0,le=A.pdfBug===!0,L=K?K.length:A.length??NaN,Z=typeof A.useSystemFonts=="boolean"?A.useSystemFonts:!_util.isNodeJS&&!ce,re=typeof A.useWorkerFetch=="boolean"?A.useWorkerFetch:N===_display_utils.DOMCMapReaderFactory&&E===_display_utils.DOMStandardFontDataFactory&&V&&P&&(0,_display_utils.isValidFetchUrl)(V,document.baseURI)&&(0,_display_utils.isValidFetchUrl)(P,document.baseURI),he=A.canvasFactory||new DefaultCanvasFactory({ownerDocument:xe}),ye=A.filterFactory||new DefaultFilterFactory({docId:T,ownerDocument:xe}),Fe=null;(0,_util.setVerbosityLevel)(se);const Pe={canvasFactory:he,filterFactory:ye};if(re||(Pe.cMapReaderFactory=new N({baseUrl:V,isCompressed:Q}),Pe.standardFontDataFactory=new E({baseUrl:P})),!Y){const Te={verbosity:se,port:_worker_options.GlobalWorkerOptions.workerPort};Y=Te.port?PDFWorker.fromPort(Te):new PDFWorker(Te),D._worker=Y}const ie={docId:T,apiVersion:"3.11.174",data:C,password:$,disableAutoFetch:ne,rangeChunkSize:J,length:L,docBaseUrl:B,enableXfa:me,evaluatorOptions:{maxImageSize:z,disableFontFace:ce,ignoreErrors:I,isEvalSupported:G,isOffscreenCanvasSupported:H,canvasMaxAreaInBytes:ee,fontExtraProperties:ve,useSystemFonts:Z,cMapUrl:re?V:null,standardFontDataUrl:re?P:null}},_e={ignoreErrors:I,isEvalSupported:G,disableFontFace:ce,fontExtraProperties:ve,enableXfa:me,ownerDocument:xe,disableAutoFetch:ne,pdfBug:le,styleElement:Fe};return Y.promise.then(function(){if(D.destroyed)throw new Error("Loading aborted");const Te=_fetchDocument(Y,ie),Ke=new Promise(function(qe){let Ye;K?Ye=new _transport_stream.PDFDataTransportStream({length:L,initialData:K.initialData,progressiveDone:K.progressiveDone,contentDispositionFilename:K.contentDispositionFilename,disableRange:Se,disableStream:Ce},K):C||(Ye=(Ee=>_util.isNodeJS?new _displayNode_stream.PDFNodeStream(Ee):(0,_display_utils.isValidFetchUrl)(Ee.url)?new _displayFetch_stream.PDFFetchStream(Ee):new _displayNetwork.PDFNetworkStream(Ee))({url:M,length:L,httpHeaders:k,withCredentials:O,rangeChunkSize:J,disableRange:Se,disableStream:Ce})),qe(Ye)});return Promise.all([Te,Ke]).then(function([qe,Ye]){if(D.destroyed)throw new Error("Loading aborted");const Me=new _message_handler.MessageHandler(T,qe,Y.port),Ee=new WorkerTransport(Me,D,Ye,_e,Pe);D._transport=Ee,Me.send("Ready",null)})}).catch(D._capability.reject),D}async function _fetchDocument(A,D){if(A.destroyed)throw new Error("Worker was destroyed");const T=await A.messageHandler.sendWithPromise("GetDocRequest",D,D.data?[D.data.buffer]:null);if(A.destroyed)throw new Error("Worker was destroyed");return T}function getUrlProp(A){if(A instanceof URL)return A.href;try{return new URL(A,window.location).href}catch{if(_util.isNodeJS&&typeof A=="string")return A}throw new Error("Invalid PDF url data: either string or URL-object is expected in the url property.")}function getDataProp(A){if(_util.isNodeJS&&typeof Buffer<"u"&&A instanceof Buffer)throw new Error("Please provide binary data as `Uint8Array`, rather than `Buffer`.");if(A instanceof Uint8Array&&A.byteLength===A.buffer.byteLength)return A;if(typeof A=="string")return(0,_util.stringToBytes)(A);if(typeof A=="object"&&!isNaN(A==null?void 0:A.length)||(0,_util.isArrayBuffer)(A))return new Uint8Array(A);throw new Error("Invalid PDF binary data: either TypedArray, string, or array-like object is expected in the data property.")}const e=class e{constructor(){this._capability=new _util.PromiseCapability,this._transport=null,this._worker=null,this.docId=`d${ft(e,t)._++}`,this.destroyed=!1,this.onPassword=null,this.onProgress=null}get promise(){return this._capability.promise}async destroy(){var D,T,M;this.destroyed=!0;try{(D=this._worker)!=null&&D.port&&(this._worker._pendingDestroy=!0),await((T=this._transport)==null?void 0:T.destroy())}catch(C){throw(M=this._worker)!=null&&M.port&&delete this._worker._pendingDestroy,C}this._transport=null,this._worker&&(this._worker.destroy(),this._worker=null)}};t=new WeakMap,de(e,t,0);let PDFDocumentLoadingTask=e;exports$1.PDFDocumentLoadingTask=PDFDocumentLoadingTask;class PDFDataRangeTransport{constructor(D,T,M=!1,C=null){this.length=D,this.initialData=T,this.progressiveDone=M,this.contentDispositionFilename=C,this._rangeListeners=[],this._progressListeners=[],this._progressiveReadListeners=[],this._progressiveDoneListeners=[],this._readyCapability=new _util.PromiseCapability}addRangeListener(D){this._rangeListeners.push(D)}addProgressListener(D){this._progressListeners.push(D)}addProgressiveReadListener(D){this._progressiveReadListeners.push(D)}addProgressiveDoneListener(D){this._progressiveDoneListeners.push(D)}onDataRange(D,T){for(const M of this._rangeListeners)M(D,T)}onDataProgress(D,T){this._readyCapability.promise.then(()=>{for(const M of this._progressListeners)M(D,T)})}onDataProgressiveRead(D){this._readyCapability.promise.then(()=>{for(const T of this._progressiveReadListeners)T(D)})}onDataProgressiveDone(){this._readyCapability.promise.then(()=>{for(const D of this._progressiveDoneListeners)D()})}transportReady(){this._readyCapability.resolve()}requestDataRange(D,T){(0,_util.unreachable)("Abstract method PDFDataRangeTransport.requestDataRange")}abort(){}}exports$1.PDFDataRangeTransport=PDFDataRangeTransport;class PDFDocumentProxy{constructor(D,T){this._pdfInfo=D,this._transport=T,Object.defineProperty(this,"getJavaScript",{value:()=>((0,_display_utils.deprecated)("`PDFDocumentProxy.getJavaScript`, please use `PDFDocumentProxy.getJSActions` instead."),this.getJSActions().then(M=>{if(!M)return M;const C=[];for(const k in M)C.push(...M[k]);return C}))})}get annotationStorage(){return this._transport.annotationStorage}get filterFactory(){return this._transport.filterFactory}get numPages(){return this._pdfInfo.numPages}get fingerprints(){return this._pdfInfo.fingerprints}get isPureXfa(){return(0,_util.shadow)(this,"isPureXfa",!!this._transport._htmlForXfa)}get allXfaHtml(){return this._transport._htmlForXfa}getPage(D){return this._transport.getPage(D)}getPageIndex(D){return this._transport.getPageIndex(D)}getDestinations(){return this._transport.getDestinations()}getDestination(D){return this._transport.getDestination(D)}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()}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()}saveDocument(){return this._transport.saveDocument()}getDownloadInfo(){return this._transport.downloadInfoCapability.promise}cleanup(D=!1){return this._transport.startCleanup(D||this.isPureXfa)}destroy(){return this.loadingTask.destroy()}get loadingParams(){return this._transport.loadingParams}get loadingTask(){return this._transport.loadingTask}getFieldObjects(){return this._transport.getFieldObjects()}hasJSActions(){return this._transport.hasJSActions()}getCalculationOrderIds(){return this._transport.getCalculationOrderIds()}}exports$1.PDFDocumentProxy=PDFDocumentProxy;class PDFPageProxy{constructor(D,T,M,C=!1){de(this,a);de(this,r,null);de(this,n,!1);this._pageIndex=D,this._pageInfo=T,this._transport=M,this._stats=C?new _display_utils.StatTimer:null,this._pdfBug=C,this.commonObjs=M.commonObjs,this.objs=new PDFObjects,this._maybeCleanupAfterRender=!1,this._intentStates=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:D,rotation:T=this.rotate,offsetX:M=0,offsetY:C=0,dontFlip:k=!1}={}){return new _display_utils.PageViewport({viewBox:this.view,scale:D,rotation:T,offsetX:M,offsetY:C,dontFlip:k})}getAnnotations({intent:D="display"}={}){const T=this._transport.getRenderingIntent(D);return this._transport.getAnnotations(this._pageIndex,T.renderingIntent)}getJSActions(){return this._transport.getPageJSActions(this._pageIndex)}get filterFactory(){return this._transport.filterFactory}get isPureXfa(){return(0,_util.shadow)(this,"isPureXfa",!!this._transport._htmlForXfa)}async getXfa(){var D;return((D=this._transport._htmlForXfa)==null?void 0:D.children[this._pageIndex])||null}render({canvasContext:D,viewport:T,intent:M="display",annotationMode:C=_util.AnnotationMode.ENABLE,transform:k=null,background:O=null,optionalContentConfigPromise:$=null,annotationCanvasMap:K=null,pageColors:J=null,printAnnotationStorage:Y=null}){var E,I;(E=this._stats)==null||E.time("Overall");const se=this._transport.getRenderingIntent(M,C,Y);ue(this,n,!1),te(this,a,St).call(this),$||($=this._transport.getOptionalContentConfig());let B=this._intentStates.get(se.cacheKey);B||(B=Object.create(null),this._intentStates.set(se.cacheKey,B)),B.streamReaderCancelTimeout&&(clearTimeout(B.streamReaderCancelTimeout),B.streamReaderCancelTimeout=null);const V=!!(se.renderingIntent&_util.RenderingIntentFlag.PRINT);B.displayReadyCapability||(B.displayReadyCapability=new _util.PromiseCapability,B.operatorList={fnArray:[],argsArray:[],lastChunk:!1,separateAnnots:null},(I=this._stats)==null||I.time("Page Request"),this._pumpOperatorList(se));const Q=z=>{var G,H;B.renderTasks.delete(N),(this._maybeCleanupAfterRender||V)&&ue(this,n,!0),te(this,a,lt).call(this,!V),z?(N.capability.reject(z),this._abortOperatorList({intentState:B,reason:z instanceof Error?z:new Error(z)})):N.capability.resolve(),(G=this._stats)==null||G.timeEnd("Rendering"),(H=this._stats)==null||H.timeEnd("Overall")},N=new InternalRenderTask({callback:Q,params:{canvasContext:D,viewport:T,transform:k,background:O},objs:this.objs,commonObjs:this.commonObjs,annotationCanvasMap:K,operatorList:B.operatorList,pageIndex:this._pageIndex,canvasFactory:this._transport.canvasFactory,filterFactory:this._transport.filterFactory,useRequestAnimationFrame:!V,pdfBug:this._pdfBug,pageColors:J});(B.renderTasks||(B.renderTasks=new Set)).add(N);const P=N.task;return Promise.all([B.displayReadyCapability.promise,$]).then(([z,G])=>{var H;if(this.destroyed){Q();return}(H=this._stats)==null||H.time("Rendering"),N.initializeGraphics({transparency:z,optionalContentConfig:G}),N.operatorListChanged()}).catch(Q),P}getOperatorList({intent:D="display",annotationMode:T=_util.AnnotationMode.ENABLE,printAnnotationStorage:M=null}={}){var K;function C(){O.operatorList.lastChunk&&(O.opListReadCapability.resolve(O.operatorList),O.renderTasks.delete($))}const k=this._transport.getRenderingIntent(D,T,M,!0);let O=this._intentStates.get(k.cacheKey);O||(O=Object.create(null),this._intentStates.set(k.cacheKey,O));let $;return O.opListReadCapability||($=Object.create(null),$.operatorListChanged=C,O.opListReadCapability=new _util.PromiseCapability,(O.renderTasks||(O.renderTasks=new Set)).add($),O.operatorList={fnArray:[],argsArray:[],lastChunk:!1,separateAnnots:null},(K=this._stats)==null||K.time("Page Request"),this._pumpOperatorList(k)),O.opListReadCapability.promise}streamTextContent({includeMarkedContent:D=!1,disableNormalization:T=!1}={}){return this._transport.messageHandler.sendWithStream("GetTextContent",{pageIndex:this._pageIndex,includeMarkedContent:D===!0,disableNormalization:T===!0},{highWaterMark:100,size(C){return C.items.length}})}getTextContent(D={}){if(this._transport._htmlForXfa)return this.getXfa().then(M=>_xfa_text.XfaText.textContent(M));const T=this.streamTextContent(D);return new Promise(function(M,C){function k(){O.read().then(function({value:K,done:J}){if(J){M($);return}Object.assign($.styles,K.styles),$.items.push(...K.items),k()},C)}const O=T.getReader(),$={items:[],styles:Object.create(null)};k()})}getStructTree(){return this._transport.getStructTree(this._pageIndex)}_destroy(){this.destroyed=!0;const D=[];for(const T of this._intentStates.values())if(this._abortOperatorList({intentState:T,reason:new Error("Page was destroyed."),force:!0}),!T.opListReadCapability)for(const M of T.renderTasks)D.push(M.completed),M.cancel();return this.objs.clear(),ue(this,n,!1),te(this,a,St).call(this),Promise.all(D)}cleanup(D=!1){ue(this,n,!0);const T=te(this,a,lt).call(this,!1);return D&&T&&this._stats&&(this._stats=new _display_utils.StatTimer),T}_startRenderPage(D,T){var C,k;const M=this._intentStates.get(T);M&&((C=this._stats)==null||C.timeEnd("Page Request"),(k=M.displayReadyCapability)==null||k.resolve(D))}_renderPageChunk(D,T){for(let M=0,C=D.length;M<C;M++)T.operatorList.fnArray.push(D.fnArray[M]),T.operatorList.argsArray.push(D.argsArray[M]);T.operatorList.lastChunk=D.lastChunk,T.operatorList.separateAnnots=D.separateAnnots;for(const M of T.renderTasks)M.operatorListChanged();D.lastChunk&&te(this,a,lt).call(this,!0)}_pumpOperatorList({renderingIntent:D,cacheKey:T,annotationStorageSerializable:M}){const{map:C,transfers:k}=M,$=this._transport.messageHandler.sendWithStream("GetOperatorList",{pageIndex:this._pageIndex,intent:D,cacheKey:T,annotationStorage:C},k).getReader(),K=this._intentStates.get(T);K.streamReader=$;const J=()=>{$.read().then(({value:Y,done:se})=>{if(se){K.streamReader=null;return}this._transport.destroyed||(this._renderPageChunk(Y,K),J())},Y=>{if(K.streamReader=null,!this._transport.destroyed){if(K.operatorList){K.operatorList.lastChunk=!0;for(const se of K.renderTasks)se.operatorListChanged();te(this,a,lt).call(this,!0)}if(K.displayReadyCapability)K.displayReadyCapability.reject(Y);else if(K.opListReadCapability)K.opListReadCapability.reject(Y);else throw Y}})};J()}_abortOperatorList({intentState:D,reason:T,force:M=!1}){if(D.streamReader){if(D.streamReaderCancelTimeout&&(clearTimeout(D.streamReaderCancelTimeout),D.streamReaderCancelTimeout=null),!M){if(D.renderTasks.size>0)return;if(T instanceof _display_utils.RenderingCancelledException){let C=RENDERING_CANCELLED_TIMEOUT;T.extraDelay>0&&T.extraDelay<1e3&&(C+=T.extraDelay),D.streamReaderCancelTimeout=setTimeout(()=>{D.streamReaderCancelTimeout=null,this._abortOperatorList({intentState:D,reason:T,force:!0})},C);return}}if(D.streamReader.cancel(new _util.AbortException(T.message)).catch(()=>{}),D.streamReader=null,!this._transport.destroyed){for(const[C,k]of this._intentStates)if(k===D){this._intentStates.delete(C);break}this.cleanup()}}}get stats(){return this._stats}}r=new WeakMap,n=new WeakMap,a=new WeakSet,lt=function(D=!1){if(te(this,a,St).call(this),!b(this,n)||this.destroyed)return!1;if(D)return ue(this,r,setTimeout(()=>{ue(this,r,null),te(this,a,lt).call(this,!1)},DELAYED_CLEANUP_TIMEOUT)),!1;for(const{renderTasks:T,operatorList:M}of this._intentStates.values())if(T.size>0||!M.lastChunk)return!1;return this._intentStates.clear(),this.objs.clear(),ue(this,n,!1),!0},St=function(){b(this,r)&&(clearTimeout(b(this,r)),ue(this,r,null))},exports$1.PDFPageProxy=PDFPageProxy;class LoopbackPort{constructor(){de(this,h,new Set);de(this,d,Promise.resolve())}postMessage(D,T){const M={data:structuredClone(D,T?{transfer:T}:null)};b(this,d).then(()=>{for(const C of b(this,h))C.call(this,M)})}addEventListener(D,T){b(this,h).add(T)}removeEventListener(D,T){b(this,h).delete(T)}terminate(){b(this,h).clear()}}h=new WeakMap,d=new WeakMap,exports$1.LoopbackPort=LoopbackPort;const PDFWorkerUtil={isWorkerDisabled:!1,fallbackWorkerSrc:null,fakeWorkerId:0};exports$1.PDFWorkerUtil=PDFWorkerUtil;{if(_util.isNodeJS&&typeof commonjsRequire=="function")PDFWorkerUtil.isWorkerDisabled=!0,PDFWorkerUtil.fallbackWorkerSrc="./pdf.worker.js";else if(typeof document=="object"){const A=(l=document==null?void 0:document.currentScript)==null?void 0:l.src;A&&(PDFWorkerUtil.fallbackWorkerSrc=A.replace(/(\.(?:min\.)?js)(\?.*)?$/i,".worker$1$2"))}PDFWorkerUtil.isSameOrigin=function(A,D){let T;try{if(T=new URL(A),!T.origin||T.origin==="null")return!1}catch{return!1}const M=new URL(D,T);return T.origin===M.origin},PDFWorkerUtil.createCDNWrapper=function(A){const D=`importScripts("${A}");`;return URL.createObjectURL(new Blob([D]))}}const _PDFWorker=class _PDFWorker{constructor({name:A=null,port:D=null,verbosity:T=(0,_util.getVerbosityLevel)()}={}){var M;if(this.name=A,this.destroyed=!1,this.verbosity=T,this._readyCapability=new _util.PromiseCapability,this._port=null,this._webWorker=null,this._messageHandler=null,D){if((M=b(_PDFWorker,u))!=null&&M.has(D))throw new Error("Cannot use more than one PDFWorker per port.");(b(_PDFWorker,u)||ue(_PDFWorker,u,new WeakMap)).set(D,this),this._initializeFromPort(D);return}this._initialize()}get promise(){return this._readyCapability.promise}get port(){return this._port}get messageHandler(){return this._messageHandler}_initializeFromPort(A){this._port=A,this._messageHandler=new _message_handler.MessageHandler("main","worker",A),this._messageHandler.on("ready",function(){}),this._readyCapability.resolve(),this._messageHandler.send("configure",{verbosity:this.verbosity})}_initialize(){if(!PDFWorkerUtil.isWorkerDisabled&&!_PDFWorker._mainThreadWorkerMessageHandler){let{workerSrc:A}=_PDFWorker;try{PDFWorkerUtil.isSameOrigin(window.location.href,A)||(A=PDFWorkerUtil.createCDNWrapper(new URL(A,window.location).href));const D=new Worker(A),T=new _message_handler.MessageHandler("main","worker",D),M=()=>{D.removeEventListener("error",C),T.destroy(),D.terminate(),this.destroyed?this._readyCapability.reject(new Error("Worker was destroyed")):this._setupFakeWorker()},C=()=>{this._webWorker||M()};D.addEventListener("error",C),T.on("test",O=>{if(D.removeEventListener("error",C),this.destroyed){M();return}O?(this._messageHandler=T,this._port=D,this._webWorker=D,this._readyCapability.resolve(),T.send("configure",{verbosity:this.verbosity})):(this._setupFakeWorker(),T.destroy(),D.terminate())}),T.on("ready",O=>{if(D.removeEventListener("error",C),this.destroyed){M();return}try{k()}catch{this._setupFakeWorker()}});const k=()=>{const O=new Uint8Array;T.send("test",O,[O.buffer])};k();return}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(A=>{if(this.destroyed){this._readyCapability.reject(new Error("Worker was destroyed"));return}const D=new LoopbackPort;this._port=D;const T=`fake${PDFWorkerUtil.fakeWorkerId++}`,M=new _message_handler.MessageHandler(T+"_worker",T,D);A.setup(M,D);const C=new _message_handler.MessageHandler(T,T+"_worker",D);this._messageHandler=C,this._readyCapability.resolve(),C.send("configure",{verbosity:this.verbosity})}).catch(A=>{this._readyCapability.reject(new Error(`Setting up fake worker failed: "${A.message}".`))})}destroy(){var A;this.destroyed=!0,this._webWorker&&(this._webWorker.terminate(),this._webWorker=null),(A=b(_PDFWorker,u))==null||A.delete(this._port),this._port=null,this._messageHandler&&(this._messageHandler.destroy(),this._messageHandler=null)}static fromPort(A){var T;if(!(A!=null&&A.port))throw new Error("PDFWorker.fromPort - invalid method signature.");const D=(T=b(this,u))==null?void 0:T.get(A.port);if(D){if(D._pendingDestroy)throw new Error("PDFWorker.fromPort - the worker is being destroyed.\nPlease remember to await `PDFDocumentLoadingTask.destroy()`-calls.");return D}return new _PDFWorker(A)}static get workerSrc(){if(_worker_options.GlobalWorkerOptions.workerSrc)return _worker_options.GlobalWorkerOptions.workerSrc;if(PDFWorkerUtil.fallbackWorkerSrc!==null)return _util.isNodeJS||(0,_display_utils.deprecated)('No "GlobalWorkerOptions.workerSrc" specified.'),PDFWorkerUtil.fallbackWorkerSrc;throw new Error('No "GlobalWorkerOptions.workerSrc" specified.')}static get _mainThreadWorkerMessageHandler(){var A;try{return((A=globalThis.pdfjsWorker)==null?void 0:A.WorkerMessageHandler)||null}catch{return null}}static get _setupFakeWorkerGlobal(){const loader=async()=>{const mainWorkerMessageHandler=this._mainThreadWorkerMessageHandler;if(mainWorkerMessageHandler)return mainWorkerMessageHandler;if(_util.isNodeJS&&typeof commonjsRequire=="function"){const worker=eval("require")(this.workerSrc);return worker.WorkerMessageHandler}return await(0,_display_utils.loadScript)(this.workerSrc),window.pdfjsWorker.WorkerMessageHandler};return(0,_util.shadow)(this,"_setupFakeWorkerGlobal",loader())}};u=new WeakMap,de(_PDFWorker,u);let PDFWorker=_PDFWorker;exports$1.PDFWorker=PDFWorker;class WorkerTransport{constructor(D,T,M,C,k){de(this,y);de(this,p,new Map);de(this,g,new Map);de(this,f,new Map);de(this,v,null);this.messageHandler=D,this.loadingTask=T,this.commonObjs=new PDFObjects,this.fontLoader=new _font_loader.FontLoader({ownerDocument:C.ownerDocument,styleElement:C.styleElement}),this._params=C,this.canvasFactory=k.canvasFactory,this.filterFactory=k.filterFactory,this.cMapReaderFactory=k.cMapReaderFactory,this.standardFontDataFactory=k.standardFontDataFactory,this.destroyed=!1,this.destroyCapability=null,this._networkStream=M,this._fullReader=null,this._lastProgress=null,this.downloadInfoCapability=new _util.PromiseCapability,this.setupMessageHandler()}get annotationStorage(){return(0,_util.shadow)(this,"annotationStorage",new _annotation_storage.AnnotationStorage)}getRenderingIntent(D,T=_util.AnnotationMode.ENABLE,M=null,C=!1){let k=_util.RenderingIntentFlag.DISPLAY,O=_annotation_storage.SerializableEmpty;switch(D){case"any":k=_util.RenderingIntentFlag.ANY;break;case"display":break;case"print":k=_util.RenderingIntentFlag.PRINT;break;default:(0,_util.warn)(`getRenderingIntent - invalid intent: ${D}`)}switch(T){case _util.AnnotationMode.DISABLE:k+=_util.RenderingIntentFlag.ANNOTATIONS_DISABLE;break;case _util.AnnotationMode.ENABLE:break;case _util.AnnotationMode.ENABLE_FORMS:k+=_util.RenderingIntentFlag.ANNOTATIONS_FORMS;break;case _util.AnnotationMode.ENABLE_STORAGE:k+=_util.RenderingIntentFlag.ANNOTATIONS_STORAGE,O=(k&_util.RenderingIntentFlag.PRINT&&M instanceof _annotation_storage.PrintAnnotationStorage?M:this.annotationStorage).serializable;break;default:(0,_util.warn)(`getRenderingIntent - invalid annotationMode: ${T}`)}return C&&(k+=_util.RenderingIntentFlag.OPLIST),{renderingIntent:k,cacheKey:`${k}_${O.hash}`,annotationStorageSerializable:O}}destroy(){var M;if(this.destroyCapability)return this.destroyCapability.promise;this.destroyed=!0,this.destroyCapability=new _util.PromiseCapability,(M=b(this,v))==null||M.reject(new Error("Worker was destroyed during onPassword callback"));const D=[];for(const C of b(this,g).values())D.push(C._destroy());b(this,g).clear(),b(this,f).clear(),this.hasOwnProperty("annotationStorage")&&this.annotationStorage.resetModified();const T=this.messageHandler.sendWithPromise("Terminate",null);return D.push(T),Promise.all(D).then(()=>{var C;this.commonObjs.clear(),this.fontLoader.clear(),b(this,p).clear(),this.filterFactory.destroy(),(C=this._networkStream)==null||C.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:D,loadingTask:T}=this;D.on("GetReader",(M,C)=>{(0,_util.assert)(this._networkStream,"GetReader - no `IPDFStream` instance available."),this._fullReader=this._networkStream.getFullReader(),this._fullReader.onProgress=k=>{this._lastProgress={loaded:k.loaded,total:k.total}},C.onPull=()=>{this._fullReader.read().then(function({value:k,done:O}){if(O){C.close();return}(0,_util.assert)(k instanceof ArrayBuffer,"GetReader - expected an ArrayBuffer."),C.enqueue(new Uint8Array(k),1,[k])}).catch(k=>{C.error(k)})},C.onCancel=k=>{this._fullReader.cancel(k),C.ready.catch(O=>{if(!this.destroyed)throw O})}}),D.on("ReaderHeadersReady",M=>{const C=new _util.PromiseCapability,k=this._fullReader;return k.headersReady.then(()=>{var O;(!k.isStreamingSupported||!k.isRangeSupported)&&(this._lastProgress&&((O=T.onProgress)==null||O.call(T,this._lastProgress)),k.onProgress=$=>{var K;(K=T.onProgress)==null||K.call(T,{loaded:$.loaded,total:$.total})}),C.resolve({isStreamingSupported:k.isStreamingSupported,isRangeSupported:k.isRangeSupported,contentLength:k.contentLength})},C.reject),C.promise}),D.on("GetRangeReader",(M,C)=>{(0,_util.assert)(this._networkStream,"GetRangeReader - no `IPDFStream` instance available.");const k=this._networkStream.getRangeReader(M.begin,M.end);if(!k){C.close();return}C.onPull=()=>{k.read().then(function({value:O,done:$}){if($){C.close();return}(0,_util.assert)(O instanceof ArrayBuffer,"GetRangeReader - expected an ArrayBuffer."),C.enqueue(new Uint8Array(O),1,[O])}).catch(O=>{C.error(O)})},C.onCancel=O=>{k.cancel(O),C.ready.catch($=>{if(!this.destroyed)throw $})}}),D.on("GetDoc",({pdfInfo:M})=>{this._numPages=M.numPages,this._htmlForXfa=M.htmlForXfa,delete M.htmlForXfa,T._capability.resolve(new PDFDocumentProxy(M,this))}),D.on("DocException",function(M){let C;switch(M.name){case"PasswordException":C=new _util.PasswordException(M.message,M.code);break;case"InvalidPDFException":C=new _util.InvalidPDFException(M.message);break;case"MissingPDFException":C=new _util.MissingPDFException(M.message);break;case"UnexpectedResponseException":C=new _util.UnexpectedResponseException(M.message,M.status);break;case"UnknownErrorException":C=new _util.UnknownErrorException(M.message,M.details);break;default:(0,_util.unreachable)("DocException - expected a valid Error.")}T._capability.reject(C)}),D.on("PasswordRequest",M=>{if(ue(this,v,new _util.PromiseCapability),T.onPassword){const C=k=>{k instanceof Error?b(this,v).reject(k):b(this,v).resolve({password:k})};try{T.onPassword(C,M.code)}catch(k){b(this,v).reject(k)}}else b(this,v).reject(new _util.PasswordException(M.message,M.code));return b(this,v).promise}),D.on("DataLoaded",M=>{var C;(C=T.onProgress)==null||C.call(T,{loaded:M.length,total:M.length}),this.downloadInfoCapability.resolve(M)}),D.on("StartRenderPage",M=>{if(this.destroyed)return;b(this,g).get(M.pageIndex)._startRenderPage(M.transparency,M.cacheKey)}),D.on("commonobj",([M,C,k])=>{var O;if(!this.destroyed&&!this.commonObjs.has(M))switch(C){case"Font":const $=this._params;if("error"in k){const Y=k.error;(0,_util.warn)(`Error during font loading: ${Y}`),this.commonObjs.resolve(M,Y);break}const K=$.pdfBug&&((O=globalThis.FontInspector)!=null&&O.enabled)?(Y,se)=>globalThis.FontInspector.fontAdded(Y,se):null,J=new _font_loader.FontFaceObject(k,{isEvalSupported:$.isEvalSupported,disableFontFace:$.disableFontFace,ignoreErrors:$.ignoreErrors,inspectFont:K});this.fontLoader.bind(J).catch(Y=>D.sendWithPromise("FontFallback",{id:M})).finally(()=>{!$.fontExtraProperties&&J.data&&(J.data=null),this.commonObjs.resolve(M,J)});break;case"FontPath":case"Image":case"Pattern":this.commonObjs.resolve(M,k);break;default:throw new Error(`Got unknown common object type ${C}`)}}),D.on("obj",([M,C,k,O])=>{var K;if(this.destroyed)return;const $=b(this,g).get(C);if(!$.objs.has(M))switch(k){case"Image":if($.objs.resolve(M,O),O){let J;if(O.bitmap){const{width:Y,height:se}=O;J=Y*se*4}else J=((K=O.data)==null?void 0:K.length)||0;J>_util.MAX_IMAGE_SIZE_TO_CACHE&&($._maybeCleanupAfterRender=!0)}break;case"Pattern":$.objs.resolve(M,O);break;default:throw new Error(`Got unknown object type ${k}`)}}),D.on("DocProgress",M=>{var C;this.destroyed||(C=T.onProgress)==null||C.call(T,{loaded:M.loaded,total:M.total})}),D.on("FetchBuiltInCMap",M=>this.destroyed?Promise.reject(new Error("Worker was destroyed.")):this.cMapReaderFactory?this.cMapReaderFactory.fetch(M):Promise.reject(new Error("CMapReaderFactory not initialized, see the `useWorkerFetch` parameter."))),D.on("FetchStandardFontData",M=>this.destroyed?Promise.reject(new Error("Worker was destroyed.")):this.standardFontDataFactory?this.standardFontDataFactory.fetch(M):Promise.reject(new Error("StandardFontDataFactory not initialized, see the `useWorkerFetch` parameter.")))}getData(){return this.messageHandler.sendWithPromise("GetData",null)}saveDocument(){var M;this.annotationStorage.size<=0&&(0,_util.warn)("saveDocument called while `annotationStorage` is empty, please use the getData-method instead.");const{map:D,transfers:T}=this.annotationStorage.serializable;return this.messageHandler.sendWithPromise("SaveDocument",{isPureXfa:!!this._htmlForXfa,numPages:this._numPages,annotationStorage:D,filename:((M=this._fullReader)==null?void 0:M.filename)??null},T).finally(()=>{this.annotationStorage.resetModified()})}getPage(D){if(!Number.isInteger(D)||D<=0||D>this._numPages)return Promise.reject(new Error("Invalid page request."));const T=D-1,M=b(this,f).get(T);if(M)return M;const C=this.messageHandler.sendWithPromise("GetPage",{pageIndex:T}).then(k=>{if(this.destroyed)throw new Error("Transport destroyed");const O=new PDFPageProxy(T,k,this,this._params.pdfBug);return b(this,g).set(T,O),O});return b(this,f).set(T,C),C}getPageIndex(D){return typeof D!="object"||D===null||!Number.isInteger(D.num)||D.num<0||!Number.isInteger(D.gen)||D.gen<0?Promise.reject(new Error("Invalid pageIndex request.")):this.messageHandler.sendWithPromise("GetPageIndex",{num:D.num,gen:D.gen})}getAnnotations(D,T){return this.messageHandler.sendWithPromise("GetAnnotations",{pageIndex:D,intent:T})}getFieldObjects(){return te(this,y,At).call(this,"GetFieldObjects")}hasJSActions(){return te(this,y,At).call(this,"HasJSActions")}getCalculationOrderIds(){return this.messageHandler.sendWithPromise("GetCalculationOrderIds",null)}getDestinations(){return this.messageHandler.sendWithPromise("GetDestinations",null)}getDestination(D){return typeof D!="string"?Promise.reject(new Error("Invalid destination request.")):this.messageHandler.sendWithPromise("GetDestination",{id:D})}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)}getDocJSActions(){return te(this,y,At).call(this,"GetDocJSActions")}getPageJSActions(D){return this.messageHandler.sendWithPromise("GetPageJSActions",{pageIndex:D})}getStructTree(D){return this.messageHandler.sendWithPromise("GetStructTree",{pageIndex:D})}getOutline(){return this.messageHandler.sendWithPromise("GetOutline",null)}getOptionalContentConfig(){return this.messageHandler.sendWithPromise("GetOptionalContentConfig",null).then(D=>new _optional_content_config.OptionalContentConfig(D))}getPermissions(){return this.messageHandler.sendWithPromise("GetPermissions",null)}getMetadata(){const D="GetMetadata",T=b(this,p).get(D);if(T)return T;const M=this.messageHandler.sendWithPromise(D,null).then(C=>{var k,O;return{info:C[0],metadata:C[1]?new _metadata.Metadata(C[1]):null,contentDispositionFilename:((k=this._fullReader)==null?void 0:k.filename)??null,contentLength:((O=this._fullReader)==null?void 0:O.contentLength)??null}});return b(this,p).set(D,M),M}getMarkInfo(){return this.messageHandler.sendWithPromise("GetMarkInfo",null)}async startCleanup(D=!1){if(!this.destroyed){await this.messageHandler.sendWithPromise("Cleanup",null);for(const T of b(this,g).values())if(!T.cleanup())throw new Error(`startCleanup: Page ${T.pageNumber} is currently rendering.`);this.commonObjs.clear(),D||this.fontLoader.clear(),b(this,p).clear(),this.filterFactory.destroy(!0)}}get loadingParams(){const{disableAutoFetch:D,enableXfa:T}=this._params;return(0,_util.shadow)(this,"loadingParams",{disableAutoFetch:D,enableXfa:T})}}p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakSet,At=function(D,T=null){const M=b(this,p).get(D);if(M)return M;const C=this.messageHandler.sendWithPromise(D,T);return b(this,p).set(D,C),C};class PDFObjects{constructor(){de(this,w);de(this,m,Object.create(null))}get(D,T=null){if(T){const C=te(this,w,Mt).call(this,D);return C.capability.promise.then(()=>T(C.data)),null}const M=b(this,m)[D];if(!(M!=null&&M.capability.settled))throw new Error(`Requesting object that isn't resolved yet ${D}.`);return M.data}has(D){const T=b(this,m)[D];return(T==null?void 0:T.capability.settled)||!1}resolve(D,T=null){const M=te(this,w,Mt).call(this,D);M.data=T,M.capability.resolve()}clear(){var D;for(const T in b(this,m)){const{data:M}=b(this,m)[T];(D=M==null?void 0:M.bitmap)==null||D.close()}ue(this,m,Object.create(null))}}m=new WeakMap,w=new WeakSet,Mt=function(D){var T;return(T=b(this,m))[D]||(T[D]={capability:new _util.PromiseCapability,data:null})};class RenderTask{constructor(D){de(this,_,null);ue(this,_,D),this.onContinue=null}get promise(){return b(this,_).capability.promise}cancel(D=0){b(this,_).cancel(null,D)}get separateAnnots(){const{separateAnnots:D}=b(this,_).operatorList;if(!D)return!1;const{annotationCanvasMap:T}=b(this,_);return D.form||D.canvas&&(T==null?void 0:T.size)>0}}_=new WeakMap,exports$1.RenderTask=RenderTask;const F=class F{constructor({callback:D,params:T,objs:M,commonObjs:C,annotationCanvasMap:k,operatorList:O,pageIndex:$,canvasFactory:K,filterFactory:J,useRequestAnimationFrame:Y=!1,pdfBug:se=!1,pageColors:B=null}){this.callback=D,this.params=T,this.objs=M,this.commonObjs=C,this.annotationCanvasMap=k,this.operatorListIdx=null,this.operatorList=O,this._pageIndex=$,this.canvasFactory=K,this.filterFactory=J,this._pdfBug=se,this.pageColors=B,this.running=!1,this.graphicsReadyCallback=null,this.graphicsReady=!1,this._useRequestAnimationFrame=Y===!0&&typeof window<"u",this.cancelled=!1,this.capability=new _util.PromiseCapability,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=T.canvasContext.canvas}get completed(){return this.capability.promise.catch(function(){})}initializeGraphics({transparency:D=!1,optionalContentConfig:T}){var $,K;if(this.cancelled)return;if(this._canvas){if(b(F,x).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.");b(F,x).add(this._canvas)}this._pdfBug&&(($=globalThis.StepperManager)!=null&&$.enabled)&&(this.stepper=globalThis.StepperManager.create(this._pageIndex),this.stepper.init(this.operatorList),this.stepper.nextBreakPoint=this.stepper.getNextBreakPoint());const{canvasContext:M,viewport:C,transform:k,background:O}=this.params;this.gfx=new _canvas.CanvasGraphics(M,this.commonObjs,this.objs,this.canvasFactory,this.filterFactory,{optionalContentConfig:T},this.annotationCanvasMap,this.pageColors),this.gfx.beginDrawing({transform:k,viewport:C,transparency:D,background:O}),this.operatorListIdx=0,this.graphicsReady=!0,(K=this.graphicsReadyCallback)==null||K.call(this)}cancel(D=null,T=0){var M;this.running=!1,this.cancelled=!0,(M=this.gfx)==null||M.endDrawing(),b(F,x).delete(this._canvas),this.callback(D||new _display_utils.RenderingCancelledException(`Rendering cancelled, page ${this._pageIndex+1}`,T))}operatorListChanged(){var D;if(!this.graphicsReady){this.graphicsReadyCallback||(this.graphicsReadyCallback=this._continueBound);return}(D=this.stepper)==null||D.updateOperatorList(this.operatorList),!this.running&&this._continue()}_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)}async _next(){this.cancelled||(this.operatorListIdx=this.gfx.executeOperatorList(this.operatorList,this.operatorListIdx,this._continueBound,this.stepper),this.operatorListIdx===this.operatorList.argsArray.length&&(this.running=!1,this.operatorList.lastChunk&&(this.gfx.endDrawing(),b(F,x).delete(this._canvas),this.callback())))}};x=new WeakMap,de(F,x,new WeakSet);let InternalRenderTask=F;const version="3.11.174";exports$1.version=version;const build="ce8716743";exports$1.build=build},(t,e,r)=>{var l,u,p,yr,f;Object.defineProperty(e,"__esModule",{value:!0}),e.SerializableEmpty=e.PrintAnnotationStorage=e.AnnotationStorage=void 0;var n=r(1),a=r(4),s=r(8);const o=Object.freeze({map:null,hash:"",transfers:void 0});e.SerializableEmpty=o;class h{constructor(){de(this,p);de(this,l,!1);de(this,u,new Map);this.onSetModified=null,this.onResetModified=null,this.onAnnotationEditor=null}getValue(y,S){const m=b(this,u).get(y);return m===void 0?S:Object.assign(S,m)}getRawValue(y){return b(this,u).get(y)}remove(y){if(b(this,u).delete(y),b(this,u).size===0&&this.resetModified(),typeof this.onAnnotationEditor=="function"){for(const S of b(this,u).values())if(S instanceof a.AnnotationEditor)return;this.onAnnotationEditor(null)}}setValue(y,S){const m=b(this,u).get(y);let w=!1;if(m!==void 0)for(const[R,_]of Object.entries(S))m[R]!==_&&(w=!0,m[R]=_);else w=!0,b(this,u).set(y,S);w&&te(this,p,yr).call(this),S instanceof a.AnnotationEditor&&typeof this.onAnnotationEditor=="function"&&this.onAnnotationEditor(S.constructor._type)}has(y){return b(this,u).has(y)}getAll(){return b(this,u).size>0?(0,n.objectFromMap)(b(this,u)):null}setAll(y){for(const[S,m]of Object.entries(y))this.setValue(S,m)}get size(){return b(this,u).size}resetModified(){b(this,l)&&(ue(this,l,!1),typeof this.onResetModified=="function"&&this.onResetModified())}get print(){return new d(this)}get serializable(){if(b(this,u).size===0)return o;const y=new Map,S=new s.MurmurHash3_64,m=[],w=Object.create(null);let R=!1;for(const[_,x]of b(this,u)){const F=x instanceof a.AnnotationEditor?x.serialize(!1,w):x;F&&(y.set(_,F),S.update(`${_}:${JSON.stringify(F)}`),R||(R=!!F.bitmap))}if(R)for(const _ of y.values())_.bitmap&&m.push(_.bitmap);return y.size>0?{map:y,hash:S.hexdigest(),transfers:m}:o}}l=new WeakMap,u=new WeakMap,p=new WeakSet,yr=function(){b(this,l)||(ue(this,l,!0),typeof this.onSetModified=="function"&&this.onSetModified())},e.AnnotationStorage=h;class d extends h{constructor(S){super();de(this,f);const{map:m,hash:w,transfers:R}=S.serializable,_=structuredClone(m,R?{transfer:R}:null);ue(this,f,{map:_,hash:w,transfers:R})}get print(){(0,n.unreachable)("Should not call PrintAnnotationStorage.print")}get serializable(){return b(this,f)}}f=new WeakMap,e.PrintAnnotationStorage=d},(t,e,r)=>{var d,l,u,p,g,f,v,y,S,m,w,R,_,x,F,Lt,Bt,T,jt,Ut,br,xr,Sr,zt,Ar;Object.defineProperty(e,"__esModule",{value:!0}),e.AnnotationEditor=void 0;var n=r(5),a=r(1),s=r(6);const Y=class Y{constructor(B){de(this,F);de(this,d,"");de(this,l,!1);de(this,u,null);de(this,p,null);de(this,g,null);de(this,f,!1);de(this,v,null);de(this,y,this.focusin.bind(this));de(this,S,this.focusout.bind(this));de(this,m,!1);de(this,w,!1);de(this,R,!1);$e(this,"_initialOptions",Object.create(null));$e(this,"_uiManager",null);$e(this,"_focusEventsAllowed",!0);$e(this,"_l10nPromise",null);de(this,_,!1);de(this,x,Y._zIndex++);this.constructor===Y&&(0,a.unreachable)("Cannot initialize AnnotationEditor."),this.parent=B.parent,this.id=B.id,this.width=this.height=null,this.pageIndex=B.parent.pageIndex,this.name=B.name,this.div=null,this._uiManager=B.uiManager,this.annotationElementId=null,this._willKeepAspectRatio=!1,this._initialOptions.isCentered=B.isCentered,this._structTreeParentId=null;const{rotation:V,rawDims:{pageWidth:Q,pageHeight:N,pageX:P,pageY:E}}=this.parent.viewport;this.rotation=V,this.pageRotation=(360+V-this._uiManager.viewParameters.rotation)%360,this.pageDimensions=[Q,N],this.pageTranslation=[P,E];const[I,z]=this.parentDimensions;this.x=B.x/I,this.y=B.y/z,this.isAttachedToDOM=!1,this.deleted=!1}get editorType(){return Object.getPrototypeOf(this).constructor._type}static get _defaultLineColor(){return(0,a.shadow)(this,"_defaultLineColor",this._colorManager.getHexCode("CanvasText"))}static deleteAnnotationElement(B){const V=new h({id:B.parent.getNextId(),parent:B.parent,uiManager:B._uiManager});V.annotationElementId=B.annotationElementId,V.deleted=!0,V._uiManager.addToAnnotationStorage(V)}static initialize(B,V=null){if(Y._l10nPromise||(Y._l10nPromise=new Map(["editor_alt_text_button_label","editor_alt_text_edit_button_label","editor_alt_text_decorative_tooltip"].map(N=>[N,B.get(N)]))),V!=null&&V.strings)for(const N of V.strings)Y._l10nPromise.set(N,B.get(N));if(Y._borderLineWidth!==-1)return;const Q=getComputedStyle(document.documentElement);Y._borderLineWidth=parseFloat(Q.getPropertyValue("--outline-width"))||0}static updateDefaultParams(B,V){}static get defaultPropertiesToUpdate(){return[]}static isHandlingMimeForPasting(B){return!1}static paste(B,V){(0,a.unreachable)("Not implemented")}get propertiesToUpdate(){return[]}get _isDraggable(){return b(this,_)}set _isDraggable(B){var V;ue(this,_,B),(V=this.div)==null||V.classList.toggle("draggable",B)}center(){const[B,V]=this.pageDimensions;switch(this.parentRotation){case 90:this.x-=this.height*V/(B*2),this.y+=this.width*B/(V*2);break;case 180:this.x+=this.width/2,this.y+=this.height/2;break;case 270:this.x+=this.height*V/(B*2),this.y-=this.width*B/(V*2);break;default:this.x-=this.width/2,this.y-=this.height/2;break}this.fixAndSetPosition()}addCommands(B){this._uiManager.addCommands(B)}get currentLayer(){return this._uiManager.currentLayer}setInBackground(){this.div.style.zIndex=0}setInForeground(){this.div.style.zIndex=b(this,x)}setParent(B){B!==null&&(this.pageIndex=B.pageIndex,this.pageDimensions=B.pageDimensions),this.parent=B}focusin(B){this._focusEventsAllowed&&(b(this,m)?ue(this,m,!1):this.parent.setSelected(this))}focusout(B){var Q;if(!this._focusEventsAllowed||!this.isAttachedToDOM)return;const V=B.relatedTarget;V!=null&&V.closest(`#${this.id}`)||(B.preventDefault(),(Q=this.parent)!=null&&Q.isMultipleSelection||this.commitOrRemove())}commitOrRemove(){this.isEmpty()?this.remove():this.commit()}commit(){this.addToAnnotationStorage()}addToAnnotationStorage(){this._uiManager.addToAnnotationStorage(this)}setAt(B,V,Q,N){const[P,E]=this.parentDimensions;[Q,N]=this.screenToPageTranslation(Q,N),this.x=(B+Q)/P,this.y=(V+N)/E,this.fixAndSetPosition()}translate(B,V){te(this,F,Lt).call(this,this.parentDimensions,B,V)}translateInPage(B,V){te(this,F,Lt).call(this,this.pageDimensions,B,V),this.div.scrollIntoView({block:"nearest"})}drag(B,V){const[Q,N]=this.parentDimensions;if(this.x+=B/Q,this.y+=V/N,this.parent&&(this.x<0||this.x>1||this.y<0||this.y>1)){const{x:G,y:H}=this.div.getBoundingClientRect();this.parent.findNewParent(this,G,H)&&(this.x-=Math.floor(this.x),this.y-=Math.floor(this.y))}let{x:P,y:E}=this;const[I,z]=te(this,F,Bt).call(this);P+=I,E+=z,this.div.style.left=`${(100*P).toFixed(2)}%`,this.div.style.top=`${(100*E).toFixed(2)}%`,this.div.scrollIntoView({block:"nearest"})}fixAndSetPosition(){const[B,V]=this.pageDimensions;let{x:Q,y:N,width:P,height:E}=this;switch(P*=B,E*=V,Q*=B,N*=V,this.rotation){case 0:Q=Math.max(0,Math.min(B-P,Q)),N=Math.max(0,Math.min(V-E,N));break;case 90:Q=Math.max(0,Math.min(B-E,Q)),N=Math.min(V,Math.max(P,N));break;case 180:Q=Math.min(B,Math.max(P,Q)),N=Math.min(V,Math.max(E,N));break;case 270:Q=Math.min(B,Math.max(E,Q)),N=Math.max(0,Math.min(V-P,N));break}this.x=Q/=B,this.y=N/=V;const[I,z]=te(this,F,Bt).call(this);Q+=I,N+=z;const{style:G}=this.div;G.left=`${(100*Q).toFixed(2)}%`,G.top=`${(100*N).toFixed(2)}%`,this.moveInDOM()}screenToPageTranslation(B,V){var Q;return te(Q=Y,T,jt).call(Q,B,V,this.parentRotation)}pageTranslationToScreen(B,V){var Q;return te(Q=Y,T,jt).call(Q,B,V,360-this.parentRotation)}get parentScale(){return this._uiManager.viewParameters.realScale}get parentRotation(){return(this._uiManager.viewParameters.rotation+this.pageRotation)%360}get parentDimensions(){const{parentScale:B,pageDimensions:[V,Q]}=this,N=V*B,P=Q*B;return a.FeatureTest.isCSSRoundSupported?[Math.round(N),Math.round(P)]:[N,P]}setDims(B,V){var P;const[Q,N]=this.parentDimensions;this.div.style.width=`${(100*B/Q).toFixed(2)}%`,b(this,f)||(this.div.style.height=`${(100*V/N).toFixed(2)}%`),(P=b(this,u))==null||P.classList.toggle("small",B<Y.SMALL_EDITOR_SIZE||V<Y.SMALL_EDITOR_SIZE)}fixDims(){const{style:B}=this.div,{height:V,width:Q}=B,N=Q.endsWith("%"),P=!b(this,f)&&V.endsWith("%");if(N&&P)return;const[E,I]=this.parentDimensions;N||(B.width=`${(100*parseFloat(Q)/E).toFixed(2)}%`),!b(this,f)&&!P&&(B.height=`${(100*parseFloat(V)/I).toFixed(2)}%`)}getInitialTranslation(){return[0,0]}async addAltTextButton(){if(b(this,u))return;const B=ue(this,u,document.createElement("button"));B.className="altText";const V=await Y._l10nPromise.get("editor_alt_text_button_label");B.textContent=V,B.setAttribute("aria-label",V),B.tabIndex="0",B.addEventListener("contextmenu",s.noContextMenu),B.addEventListener("pointerdown",Q=>Q.stopPropagation()),B.addEventListener("click",Q=>{Q.preventDefault(),this._uiManager.editAltText(this)},{capture:!0}),B.addEventListener("keydown",Q=>{Q.target===B&&Q.key==="Enter"&&(Q.preventDefault(),this._uiManager.editAltText(this))}),te(this,F,zt).call(this),this.div.append(B),Y.SMALL_EDITOR_SIZE||(Y.SMALL_EDITOR_SIZE=Math.min(128,Math.round(B.getBoundingClientRect().width*1.4)))}getClientDimensions(){return this.div.getBoundingClientRect()}get altTextData(){return{altText:b(this,d),decorative:b(this,l)}}set altTextData({altText:B,decorative:V}){b(this,d)===B&&b(this,l)===V||(ue(this,d,B),ue(this,l,V),te(this,F,zt).call(this))}render(){this.div=document.createElement("div"),this.div.setAttribute("data-editor-rotation",(360-this.rotation)%360),this.div.className=this.name,this.div.setAttribute("id",this.id),this.div.setAttribute("tabIndex",0),this.setInForeground(),this.div.addEventListener("focusin",b(this,y)),this.div.addEventListener("focusout",b(this,S));const[B,V]=this.parentDimensions;this.parentRotation%180!==0&&(this.div.style.maxWidth=`${(100*V/B).toFixed(2)}%`,this.div.style.maxHeight=`${(100*B/V).toFixed(2)}%`);const[Q,N]=this.getInitialTranslation();return this.translate(Q,N),(0,n.bindEvents)(this,this.div,["pointerdown"]),this.div}pointerdown(B){const{isMac:V}=a.FeatureTest.platform;if(B.button!==0||B.ctrlKey&&V){B.preventDefault();return}ue(this,m,!0),te(this,F,Ar).call(this,B)}moveInDOM(){var B;(B=this.parent)==null||B.moveEditorInDOM(this)}_setParentAndPosition(B,V,Q){B.changeParent(this),this.x=V,this.y=Q,this.fixAndSetPosition()}getRect(B,V){const Q=this.parentScale,[N,P]=this.pageDimensions,[E,I]=this.pageTranslation,z=B/Q,G=V/Q,H=this.x*N,ee=this.y*P,ce=this.width*N,ve=this.height*P;switch(this.rotation){case 0:return[H+z+E,P-ee-G-ve+I,H+z+ce+E,P-ee-G+I];case 90:return[H+G+E,P-ee+z+I,H+G+ve+E,P-ee+z+ce+I];case 180:return[H-z-ce+E,P-ee+G+I,H-z+E,P-ee+G+ve+I];case 270:return[H-G-ve+E,P-ee-z-ce+I,H-G+E,P-ee-z+I];default:throw new Error("Invalid rotation")}}getRectInCurrentCoords(B,V){const[Q,N,P,E]=B,I=P-Q,z=E-N;switch(this.rotation){case 0:return[Q,V-E,I,z];case 90:return[Q,V-N,z,I];case 180:return[P,V-N,I,z];case 270:return[P,V-E,z,I];default:throw new Error("Invalid rotation")}}onceAdded(){}isEmpty(){return!1}enableEditMode(){ue(this,R,!0)}disableEditMode(){ue(this,R,!1)}isInEditMode(){return b(this,R)}shouldGetKeyboardEvents(){return!1}needsToBeRebuilt(){return this.div&&!this.isAttachedToDOM}rebuild(){var B,V;(B=this.div)==null||B.addEventListener("focusin",b(this,y)),(V=this.div)==null||V.addEventListener("focusout",b(this,S))}serialize(B=!1,V=null){(0,a.unreachable)("An editor must be serializable")}static deserialize(B,V,Q){const N=new this.prototype.constructor({parent:V,id:V.getNextId(),uiManager:Q});N.rotation=B.rotation;const[P,E]=N.pageDimensions,[I,z,G,H]=N.getRectInCurrentCoords(B.rect,E);return N.x=I/P,N.y=z/E,N.width=G/P,N.height=H/E,N}remove(){var B;this.div.removeEventListener("focusin",b(this,y)),this.div.removeEventListener("focusout",b(this,S)),this.isEmpty()||this.commit(),this.parent?this.parent.remove(this):this._uiManager.removeEditor(this),(B=b(this,u))==null||B.remove(),ue(this,u,null),ue(this,p,null)}get isResizable(){return!1}makeResizable(){this.isResizable&&(te(this,F,br).call(this),b(this,v).classList.remove("hidden"))}select(){var B;this.makeResizable(),(B=this.div)==null||B.classList.add("selectedEditor")}unselect(){var B,V,Q;(B=b(this,v))==null||B.classList.add("hidden"),(V=this.div)==null||V.classList.remove("selectedEditor"),(Q=this.div)!=null&&Q.contains(document.activeElement)&&this._uiManager.currentLayer.div.focus()}updateParams(B,V){}disableEditing(){b(this,u)&&(b(this,u).hidden=!0)}enableEditing(){b(this,u)&&(b(this,u).hidden=!1)}enterInEditMode(){}get contentDiv(){return this.div}get isEditing(){return b(this,w)}set isEditing(B){ue(this,w,B),this.parent&&(B?(this.parent.setSelected(this),this.parent.setActiveEditor(this)):this.parent.setActiveEditor(null))}setAspectRatio(B,V){ue(this,f,!0);const Q=B/V,{style:N}=this.div;N.aspectRatio=Q,N.height="auto"}static get MIN_SIZE(){return 16}};d=new WeakMap,l=new WeakMap,u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakMap,S=new WeakMap,m=new WeakMap,w=new WeakMap,R=new WeakMap,_=new WeakMap,x=new WeakMap,F=new WeakSet,Lt=function([B,V],Q,N){[Q,N]=this.screenToPageTranslation(Q,N),this.x+=Q/B,this.y+=N/V,this.fixAndSetPosition()},Bt=function(){const[B,V]=this.parentDimensions,{_borderLineWidth:Q}=Y,N=Q/B,P=Q/V;switch(this.rotation){case 90:return[-N,P];case 180:return[N,P];case 270:return[N,-P];default:return[-N,-P]}},T=new WeakSet,jt=function(B,V,Q){switch(Q){case 90:return[V,-B];case 180:return[-B,-V];case 270:return[-V,B];default:return[B,V]}},Ut=function(B){switch(B){case 90:{const[V,Q]=this.pageDimensions;return[0,-V/Q,Q/V,0]}case 180:return[-1,0,0,-1];case 270:{const[V,Q]=this.pageDimensions;return[0,V/Q,-Q/V,0]}default:return[1,0,0,1]}},br=function(){if(b(this,v))return;ue(this,v,document.createElement("div")),b(this,v).classList.add("resizers");const B=["topLeft","topRight","bottomRight","bottomLeft"];this._willKeepAspectRatio||B.push("topMiddle","middleRight","bottomMiddle","middleLeft");for(const V of B){const Q=document.createElement("div");b(this,v).append(Q),Q.classList.add("resizer",V),Q.addEventListener("pointerdown",te(this,F,xr).bind(this,V)),Q.addEventListener("contextmenu",s.noContextMenu)}this.div.prepend(b(this,v))},xr=function(B,V){V.preventDefault();const{isMac:Q}=a.FeatureTest.platform;if(V.button!==0||V.ctrlKey&&Q)return;const N=te(this,F,Sr).bind(this,B),P=this._isDraggable;this._isDraggable=!1;const E={passive:!0,capture:!0};window.addEventListener("pointermove",N,E);const I=this.x,z=this.y,G=this.width,H=this.height,ee=this.parent.div.style.cursor,ce=this.div.style.cursor;this.div.style.cursor=this.parent.div.style.cursor=window.getComputedStyle(V.target).cursor;const ve=()=>{this._isDraggable=P,window.removeEventListener("pointerup",ve),window.removeEventListener("blur",ve),window.removeEventListener("pointermove",N,E),this.parent.div.style.cursor=ee,this.div.style.cursor=ce;const me=this.x,xe=this.y,Se=this.width,Ce=this.height;me===I&&xe===z&&Se===G&&Ce===H||this.addCommands({cmd:()=>{this.width=Se,this.height=Ce,this.x=me,this.y=xe;const[ne,le]=this.parentDimensions;this.setDims(ne*Se,le*Ce),this.fixAndSetPosition()},undo:()=>{this.width=G,this.height=H,this.x=I,this.y=z;const[ne,le]=this.parentDimensions;this.setDims(ne*G,le*H),this.fixAndSetPosition()},mustExec:!0})};window.addEventListener("pointerup",ve),window.addEventListener("blur",ve)},Sr=function(B,V){const[Q,N]=this.parentDimensions,P=this.x,E=this.y,I=this.width,z=this.height,G=Y.MIN_SIZE/Q,H=Y.MIN_SIZE/N,ee=Me=>Math.round(Me*1e4)/1e4,ce=te(this,F,Ut).call(this,this.rotation),ve=(Me,Ee)=>[ce[0]*Me+ce[2]*Ee,ce[1]*Me+ce[3]*Ee],me=te(this,F,Ut).call(this,360-this.rotation),xe=(Me,Ee)=>[me[0]*Me+me[2]*Ee,me[1]*Me+me[3]*Ee];let Se,Ce,ne=!1,le=!1;switch(B){case"topLeft":ne=!0,Se=(Me,Ee)=>[0,0],Ce=(Me,Ee)=>[Me,Ee];break;case"topMiddle":Se=(Me,Ee)=>[Me/2,0],Ce=(Me,Ee)=>[Me/2,Ee];break;case"topRight":ne=!0,Se=(Me,Ee)=>[Me,0],Ce=(Me,Ee)=>[0,Ee];break;case"middleRight":le=!0,Se=(Me,Ee)=>[Me,Ee/2],Ce=(Me,Ee)=>[0,Ee/2];break;case"bottomRight":ne=!0,Se=(Me,Ee)=>[Me,Ee],Ce=(Me,Ee)=>[0,0];break;case"bottomMiddle":Se=(Me,Ee)=>[Me/2,Ee],Ce=(Me,Ee)=>[Me/2,0];break;case"bottomLeft":ne=!0,Se=(Me,Ee)=>[0,Ee],Ce=(Me,Ee)=>[Me,0];break;case"middleLeft":le=!0,Se=(Me,Ee)=>[0,Ee/2],Ce=(Me,Ee)=>[Me,Ee/2];break}const L=Se(I,z),Z=Ce(I,z);let re=ve(...Z);const he=ee(P+re[0]),ye=ee(E+re[1]);let Fe=1,Pe=1,[ie,_e]=this.screenToPageTranslation(V.movementX,V.movementY);if([ie,_e]=xe(ie/Q,_e/N),ne){const Me=Math.hypot(I,z);Fe=Pe=Math.max(Math.min(Math.hypot(Z[0]-L[0]-ie,Z[1]-L[1]-_e)/Me,1/I,1/z),G/I,H/z)}else le?Fe=Math.max(G,Math.min(1,Math.abs(Z[0]-L[0]-ie)))/I:Pe=Math.max(H,Math.min(1,Math.abs(Z[1]-L[1]-_e)))/z;const Te=ee(I*Fe),Ke=ee(z*Pe);re=ve(...Ce(Te,Ke));const qe=he-re[0],Ye=ye-re[1];this.width=Te,this.height=Ke,this.x=qe,this.y=Ye,this.setDims(Q*Te,N*Ke),this.fixAndSetPosition()},zt=async function(){var Q;const B=b(this,u);if(!B)return;if(!b(this,d)&&!b(this,l)){B.classList.remove("done"),(Q=b(this,p))==null||Q.remove();return}Y._l10nPromise.get("editor_alt_text_edit_button_label").then(N=>{B.setAttribute("aria-label",N)});let V=b(this,p);if(!V){ue(this,p,V=document.createElement("span")),V.className="tooltip",V.setAttribute("role","tooltip");const N=V.id=`alt-text-tooltip-${this.id}`;B.setAttribute("aria-describedby",N);const P=100;B.addEventListener("mouseenter",()=>{ue(this,g,setTimeout(()=>{ue(this,g,null),b(this,p).classList.add("show"),this._uiManager._eventBus.dispatch("reporttelemetry",{source:this,details:{type:"editing",subtype:this.editorType,data:{action:"alt_text_tooltip"}}})},P))}),B.addEventListener("mouseleave",()=>{var E;clearTimeout(b(this,g)),ue(this,g,null),(E=b(this,p))==null||E.classList.remove("show")})}B.classList.add("done"),V.innerText=b(this,l)?await Y._l10nPromise.get("editor_alt_text_decorative_tooltip"):b(this,d),V.parentNode||B.append(V)},Ar=function(B){if(!this._isDraggable)return;const V=this._uiManager.isSelected(this);this._uiManager.setUpDragSession();let Q,N;V&&(Q={passive:!0,capture:!0},N=E=>{const[I,z]=this.screenToPageTranslation(E.movementX,E.movementY);this._uiManager.dragSelectedEditors(I,z)},window.addEventListener("pointermove",N,Q));const P=()=>{if(window.removeEventListener("pointerup",P),window.removeEventListener("blur",P),V&&window.removeEventListener("pointermove",N,Q),ue(this,m,!1),!this._uiManager.endDragSession()){const{isMac:E}=a.FeatureTest.platform;B.ctrlKey&&!E||B.shiftKey||B.metaKey&&E?this.parent.toggleSelected(this):this.parent.setSelected(this)}};window.addEventListener("pointerup",P),window.addEventListener("blur",P)},de(Y,T),$e(Y,"_borderLineWidth",-1),$e(Y,"_colorManager",new n.ColorManager),$e(Y,"_zIndex",1),$e(Y,"SMALL_EDITOR_SIZE",0);let o=Y;e.AnnotationEditor=o;class h extends o{constructor(B){super(B),this.annotationElementId=B.annotationElementId,this.deleted=!0}serialize(){return{id:this.annotationElementId,deleted:!0,pageIndex:this.pageIndex}}}},(t,e,r)=>{var f,v,y,S,m,Ht,_,x,F,A,D,Fr,C,k,O,$,K,J,Y,se,B,V,Q,N,P,E,I,z,G,H,ee,ce,ve,me,xe,Se,Ce,ne,le,L,Z,re,he,ye,Fe,Pe,ie,Cr,Gt,Wt,Ft,Vt,qt,rt,pt,Pr,wr,Xt,gt,Kt;Object.defineProperty(e,"__esModule",{value:!0}),e.KeyboardManager=e.CommandManager=e.ColorManager=e.AnnotationEditorUIManager=void 0,e.bindEvents=s,e.opacityToHex=o;var n=r(1),a=r(6);function s(Ve,X,ge){for(const ke of ge)X.addEventListener(ke,Ve[ke].bind(Ve))}function o(Ve){return Math.round(Math.min(255,Math.max(1,255*Ve))).toString(16).padStart(2,"0")}class h{constructor(){de(this,f,0)}getId(){return`${n.AnnotationEditorPrefix}${ft(this,f)._++}`}}f=new WeakMap;const R=class R{constructor(){de(this,m);de(this,v,(0,n.getUuid)());de(this,y,0);de(this,S,null)}static get _isSVGFittingCanvas(){const X='data:image/svg+xml;charset=UTF-8,<svg viewBox="0 0 1 1" width="1" height="1" xmlns="http://www.w3.org/2000/svg"><rect width="1" height="1" style="fill:red;"/></svg>',ke=new OffscreenCanvas(1,3).getContext("2d"),Be=new Image;Be.src=X;const He=Be.decode().then(()=>(ke.drawImage(Be,0,0,1,1,0,0,1,3),new Uint32Array(ke.getImageData(0,0,1,1).data.buffer)[0]===0));return(0,n.shadow)(this,"_isSVGFittingCanvas",He)}async getFromFile(X){const{lastModified:ge,name:ke,size:Be,type:He}=X;return te(this,m,Ht).call(this,`${ge}_${ke}_${Be}_${He}`,X)}async getFromUrl(X){return te(this,m,Ht).call(this,X,X)}async getFromId(X){b(this,S)||ue(this,S,new Map);const ge=b(this,S).get(X);return ge?ge.bitmap?(ge.refCounter+=1,ge):ge.file?this.getFromFile(ge.file):this.getFromUrl(ge.url):null}getSvgUrl(X){const ge=b(this,S).get(X);return ge!=null&&ge.isSvg?ge.svgUrl:null}deleteId(X){b(this,S)||ue(this,S,new Map);const ge=b(this,S).get(X);ge&&(ge.refCounter-=1,ge.refCounter===0&&(ge.bitmap=null))}isValidId(X){return X.startsWith(`image_${b(this,v)}_`)}};v=new WeakMap,y=new WeakMap,S=new WeakMap,m=new WeakSet,Ht=async function(X,ge){b(this,S)||ue(this,S,new Map);let ke=b(this,S).get(X);if(ke===null)return null;if(ke!=null&&ke.bitmap)return ke.refCounter+=1,ke;try{ke||(ke={bitmap:null,id:`image_${b(this,v)}_${ft(this,y)._++}`,refCounter:0,isSvg:!1});let Be;if(typeof ge=="string"){ke.url=ge;const He=await fetch(ge);if(!He.ok)throw new Error(He.statusText);Be=await He.blob()}else Be=ke.file=ge;if(Be.type==="image/svg+xml"){const He=R._isSVGFittingCanvas,Ne=new FileReader,U=new Image,j=new Promise((W,fe)=>{U.onload=()=>{ke.bitmap=U,ke.isSvg=!0,W()},Ne.onload=async()=>{const pe=ke.svgUrl=Ne.result;U.src=await He?`${pe}#svgView(preserveAspectRatio(none))`:pe},U.onerror=Ne.onerror=fe});Ne.readAsDataURL(Be),await j}else ke.bitmap=await createImageBitmap(Be);ke.refCounter=1}catch(Be){console.error(Be),ke=null}return b(this,S).set(X,ke),ke&&b(this,S).set(ke.id,ke),ke};let d=R;class l{constructor(X=128){de(this,_,[]);de(this,x,!1);de(this,F);de(this,A,-1);ue(this,F,X)}add({cmd:X,undo:ge,mustExec:ke,type:Be=NaN,overwriteIfSameType:He=!1,keepUndo:Ne=!1}){if(ke&&X(),b(this,x))return;const U={cmd:X,undo:ge,type:Be};if(b(this,A)===-1){b(this,_).length>0&&(b(this,_).length=0),ue(this,A,0),b(this,_).push(U);return}if(He&&b(this,_)[b(this,A)].type===Be){Ne&&(U.undo=b(this,_)[b(this,A)].undo),b(this,_)[b(this,A)]=U;return}const j=b(this,A)+1;j===b(this,F)?b(this,_).splice(0,1):(ue(this,A,j),j<b(this,_).length&&b(this,_).splice(j)),b(this,_).push(U)}undo(){b(this,A)!==-1&&(ue(this,x,!0),b(this,_)[b(this,A)].undo(),ue(this,x,!1),ue(this,A,b(this,A)-1))}redo(){b(this,A)<b(this,_).length-1&&(ue(this,A,b(this,A)+1),ue(this,x,!0),b(this,_)[b(this,A)].cmd(),ue(this,x,!1))}hasSomethingToUndo(){return b(this,A)!==-1}hasSomethingToRedo(){return b(this,A)<b(this,_).length-1}destroy(){ue(this,_,null)}}_=new WeakMap,x=new WeakMap,F=new WeakMap,A=new WeakMap,e.CommandManager=l;class u{constructor(X){de(this,D);this.buffer=[],this.callbacks=new Map,this.allKeys=new Set;const{isMac:ge}=n.FeatureTest.platform;for(const[ke,Be,He={}]of X)for(const Ne of ke){const U=Ne.startsWith("mac+");ge&&U?(this.callbacks.set(Ne.slice(4),{callback:Be,options:He}),this.allKeys.add(Ne.split("+").at(-1))):!ge&&!U&&(this.callbacks.set(Ne,{callback:Be,options:He}),this.allKeys.add(Ne.split("+").at(-1)))}}exec(X,ge){if(!this.allKeys.has(ge.key))return;const ke=this.callbacks.get(te(this,D,Fr).call(this,ge));if(!ke)return;const{callback:Be,options:{bubbles:He=!1,args:Ne=[],checker:U=null}}=ke;U&&!U(X,ge)||(Be.bind(X,...Ne)(),He||(ge.stopPropagation(),ge.preventDefault()))}}D=new WeakSet,Fr=function(X){X.altKey&&this.buffer.push("alt"),X.ctrlKey&&this.buffer.push("ctrl"),X.metaKey&&this.buffer.push("meta"),X.shiftKey&&this.buffer.push("shift"),this.buffer.push(X.key);const ge=this.buffer.join("+");return this.buffer.length=0,ge},e.KeyboardManager=u;const M=class M{get _colors(){const X=new Map([["CanvasText",null],["Canvas",null]]);return(0,a.getColorValues)(X),(0,n.shadow)(this,"_colors",X)}convert(X){const ge=(0,a.getRGB)(X);if(!window.matchMedia("(forced-colors: active)").matches)return ge;for(const[ke,Be]of this._colors)if(Be.every((He,Ne)=>He===ge[Ne]))return M._colorsMapping.get(ke);return ge}getHexCode(X){const ge=this._colors.get(X);return ge?n.Util.makeHexColor(...ge):X}};$e(M,"_colorsMapping",new Map([["CanvasText",[0,0,0]],["Canvas",[255,255,255]]]));let p=M;e.ColorManager=p;const We=class We{constructor(X,ge,ke,Be,He,Ne){de(this,ie);de(this,C,null);de(this,k,new Map);de(this,O,new Map);de(this,$,null);de(this,K,null);de(this,J,new l);de(this,Y,0);de(this,se,new Set);de(this,B,null);de(this,V,null);de(this,Q,new Set);de(this,N,null);de(this,P,new h);de(this,E,!1);de(this,I,!1);de(this,z,null);de(this,G,n.AnnotationEditorType.NONE);de(this,H,new Set);de(this,ee,null);de(this,ce,this.blur.bind(this));de(this,ve,this.focus.bind(this));de(this,me,this.copy.bind(this));de(this,xe,this.cut.bind(this));de(this,Se,this.paste.bind(this));de(this,Ce,this.keydown.bind(this));de(this,ne,this.onEditingAction.bind(this));de(this,le,this.onPageChanging.bind(this));de(this,L,this.onScaleChanging.bind(this));de(this,Z,this.onRotationChanging.bind(this));de(this,re,{isEditing:!1,isEmpty:!0,hasSomethingToUndo:!1,hasSomethingToRedo:!1,hasSelectedEditor:!1});de(this,he,[0,0]);de(this,ye,null);de(this,Fe,null);de(this,Pe,null);ue(this,Fe,X),ue(this,Pe,ge),ue(this,$,ke),this._eventBus=Be,this._eventBus._on("editingaction",b(this,ne)),this._eventBus._on("pagechanging",b(this,le)),this._eventBus._on("scalechanging",b(this,L)),this._eventBus._on("rotationchanging",b(this,Z)),ue(this,K,He.annotationStorage),ue(this,N,He.filterFactory),ue(this,ee,Ne),this.viewParameters={realScale:a.PixelsPerInch.PDF_TO_CSS_UNITS,rotation:0}}static get _keyboardManager(){const X=We.prototype,ge=He=>{const{activeElement:Ne}=document;return Ne&&b(He,Fe).contains(Ne)&&He.hasSomethingToControl()},ke=this.TRANSLATE_SMALL,Be=this.TRANSLATE_BIG;return(0,n.shadow)(this,"_keyboardManager",new u([[["ctrl+a","mac+meta+a"],X.selectAll],[["ctrl+z","mac+meta+z"],X.undo],[["ctrl+y","ctrl+shift+z","mac+meta+shift+z","ctrl+shift+Z","mac+meta+shift+Z"],X.redo],[["Backspace","alt+Backspace","ctrl+Backspace","shift+Backspace","mac+Backspace","mac+alt+Backspace","mac+ctrl+Backspace","Delete","ctrl+Delete","shift+Delete","mac+Delete"],X.delete],[["Escape","mac+Escape"],X.unselectAll],[["ArrowLeft","mac+ArrowLeft"],X.translateSelectedEditors,{args:[-ke,0],checker:ge}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],X.translateSelectedEditors,{args:[-Be,0],checker:ge}],[["ArrowRight","mac+ArrowRight"],X.translateSelectedEditors,{args:[ke,0],checker:ge}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],X.translateSelectedEditors,{args:[Be,0],checker:ge}],[["ArrowUp","mac+ArrowUp"],X.translateSelectedEditors,{args:[0,-ke],checker:ge}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],X.translateSelectedEditors,{args:[0,-Be],checker:ge}],[["ArrowDown","mac+ArrowDown"],X.translateSelectedEditors,{args:[0,ke],checker:ge}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],X.translateSelectedEditors,{args:[0,Be],checker:ge}]]))}destroy(){te(this,ie,Ft).call(this),te(this,ie,Gt).call(this),this._eventBus._off("editingaction",b(this,ne)),this._eventBus._off("pagechanging",b(this,le)),this._eventBus._off("scalechanging",b(this,L)),this._eventBus._off("rotationchanging",b(this,Z));for(const X of b(this,O).values())X.destroy();b(this,O).clear(),b(this,k).clear(),b(this,Q).clear(),ue(this,C,null),b(this,H).clear(),b(this,J).destroy(),b(this,$).destroy()}get hcmFilter(){return(0,n.shadow)(this,"hcmFilter",b(this,ee)?b(this,N).addHCMFilter(b(this,ee).foreground,b(this,ee).background):"none")}get direction(){return(0,n.shadow)(this,"direction",getComputedStyle(b(this,Fe)).direction)}editAltText(X){var ge;(ge=b(this,$))==null||ge.editAltText(this,X)}onPageChanging({pageNumber:X}){ue(this,Y,X-1)}focusMainContainer(){b(this,Fe).focus()}findParent(X,ge){for(const ke of b(this,O).values()){const{x:Be,y:He,width:Ne,height:U}=ke.div.getBoundingClientRect();if(X>=Be&&X<=Be+Ne&&ge>=He&&ge<=He+U)return ke}return null}disableUserSelect(X=!1){b(this,Pe).classList.toggle("noUserSelect",X)}addShouldRescale(X){b(this,Q).add(X)}removeShouldRescale(X){b(this,Q).delete(X)}onScaleChanging({scale:X}){this.commitOrRemove(),this.viewParameters.realScale=X*a.PixelsPerInch.PDF_TO_CSS_UNITS;for(const ge of b(this,Q))ge.onScaleChanging()}onRotationChanging({pagesRotation:X}){this.commitOrRemove(),this.viewParameters.rotation=X}addToAnnotationStorage(X){!X.isEmpty()&&b(this,K)&&!b(this,K).has(X.id)&&b(this,K).setValue(X.id,X)}blur(){if(!this.hasSelection)return;const{activeElement:X}=document;for(const ge of b(this,H))if(ge.div.contains(X)){ue(this,z,[ge,X]),ge._focusEventsAllowed=!1;break}}focus(){if(!b(this,z))return;const[X,ge]=b(this,z);ue(this,z,null),ge.addEventListener("focusin",()=>{X._focusEventsAllowed=!0},{once:!0}),ge.focus()}addEditListeners(){te(this,ie,Wt).call(this),te(this,ie,Vt).call(this)}removeEditListeners(){te(this,ie,Ft).call(this),te(this,ie,qt).call(this)}copy(X){var ke;if(X.preventDefault(),(ke=b(this,C))==null||ke.commitOrRemove(),!this.hasSelection)return;const ge=[];for(const Be of b(this,H)){const He=Be.serialize(!0);He&&ge.push(He)}ge.length!==0&&X.clipboardData.setData("application/pdfjs",JSON.stringify(ge))}cut(X){this.copy(X),this.delete()}paste(X){X.preventDefault();const{clipboardData:ge}=X;for(const He of ge.items)for(const Ne of b(this,V))if(Ne.isHandlingMimeForPasting(He.type)){Ne.paste(He,this.currentLayer);return}let ke=ge.getData("application/pdfjs");if(!ke)return;try{ke=JSON.parse(ke)}catch(He){(0,n.warn)(`paste: "${He.message}".`);return}if(!Array.isArray(ke))return;this.unselectAll();const Be=this.currentLayer;try{const He=[];for(const j of ke){const W=Be.deserialize(j);if(!W)return;He.push(W)}const Ne=()=>{for(const j of He)te(this,ie,Xt).call(this,j);te(this,ie,Kt).call(this,He)},U=()=>{for(const j of He)j.remove()};this.addCommands({cmd:Ne,undo:U,mustExec:!0})}catch(He){(0,n.warn)(`paste: "${He.message}".`)}}keydown(X){var ge;(ge=this.getActive())!=null&&ge.shouldGetKeyboardEvents()||We._keyboardManager.exec(this,X)}onEditingAction(X){["undo","redo","delete","selectAll"].includes(X.name)&&this[X.name]()}setEditingState(X){X?(te(this,ie,Cr).call(this),te(this,ie,Wt).call(this),te(this,ie,Vt).call(this),te(this,ie,rt).call(this,{isEditing:b(this,G)!==n.AnnotationEditorType.NONE,isEmpty:te(this,ie,gt).call(this),hasSomethingToUndo:b(this,J).hasSomethingToUndo(),hasSomethingToRedo:b(this,J).hasSomethingToRedo(),hasSelectedEditor:!1})):(te(this,ie,Gt).call(this),te(this,ie,Ft).call(this),te(this,ie,qt).call(this),te(this,ie,rt).call(this,{isEditing:!1}),this.disableUserSelect(!1))}registerEditorTypes(X){if(!b(this,V)){ue(this,V,X);for(const ge of b(this,V))te(this,ie,pt).call(this,ge.defaultPropertiesToUpdate)}}getId(){return b(this,P).getId()}get currentLayer(){return b(this,O).get(b(this,Y))}getLayer(X){return b(this,O).get(X)}get currentPageIndex(){return b(this,Y)}addLayer(X){b(this,O).set(X.pageIndex,X),b(this,E)?X.enable():X.disable()}removeLayer(X){b(this,O).delete(X.pageIndex)}updateMode(X,ge=null){if(b(this,G)!==X){if(ue(this,G,X),X===n.AnnotationEditorType.NONE){this.setEditingState(!1),te(this,ie,wr).call(this);return}this.setEditingState(!0),te(this,ie,Pr).call(this),this.unselectAll();for(const ke of b(this,O).values())ke.updateMode(X);if(ge){for(const ke of b(this,k).values())if(ke.annotationElementId===ge){this.setSelected(ke),ke.enterInEditMode();break}}}}updateToolbar(X){X!==b(this,G)&&this._eventBus.dispatch("switchannotationeditormode",{source:this,mode:X})}updateParams(X,ge){if(b(this,V)){if(X===n.AnnotationEditorParamsType.CREATE){this.currentLayer.addNewEditor(X);return}for(const ke of b(this,H))ke.updateParams(X,ge);for(const ke of b(this,V))ke.updateDefaultParams(X,ge)}}enableWaiting(X=!1){if(b(this,I)!==X){ue(this,I,X);for(const ge of b(this,O).values())X?ge.disableClick():ge.enableClick(),ge.div.classList.toggle("waiting",X)}}getEditors(X){const ge=[];for(const ke of b(this,k).values())ke.pageIndex===X&&ge.push(ke);return ge}getEditor(X){return b(this,k).get(X)}addEditor(X){b(this,k).set(X.id,X)}removeEditor(X){var ge;b(this,k).delete(X.id),this.unselect(X),(!X.annotationElementId||!b(this,se).has(X.annotationElementId))&&((ge=b(this,K))==null||ge.remove(X.id))}addDeletedAnnotationElement(X){b(this,se).add(X.annotationElementId),X.deleted=!0}isDeletedAnnotationElement(X){return b(this,se).has(X)}removeDeletedAnnotationElement(X){b(this,se).delete(X.annotationElementId),X.deleted=!1}setActiveEditor(X){b(this,C)!==X&&(ue(this,C,X),X&&te(this,ie,pt).call(this,X.propertiesToUpdate))}toggleSelected(X){if(b(this,H).has(X)){b(this,H).delete(X),X.unselect(),te(this,ie,rt).call(this,{hasSelectedEditor:this.hasSelection});return}b(this,H).add(X),X.select(),te(this,ie,pt).call(this,X.propertiesToUpdate),te(this,ie,rt).call(this,{hasSelectedEditor:!0})}setSelected(X){for(const ge of b(this,H))ge!==X&&ge.unselect();b(this,H).clear(),b(this,H).add(X),X.select(),te(this,ie,pt).call(this,X.propertiesToUpdate),te(this,ie,rt).call(this,{hasSelectedEditor:!0})}isSelected(X){return b(this,H).has(X)}unselect(X){X.unselect(),b(this,H).delete(X),te(this,ie,rt).call(this,{hasSelectedEditor:this.hasSelection})}get hasSelection(){return b(this,H).size!==0}undo(){b(this,J).undo(),te(this,ie,rt).call(this,{hasSomethingToUndo:b(this,J).hasSomethingToUndo(),hasSomethingToRedo:!0,isEmpty:te(this,ie,gt).call(this)})}redo(){b(this,J).redo(),te(this,ie,rt).call(this,{hasSomethingToUndo:!0,hasSomethingToRedo:b(this,J).hasSomethingToRedo(),isEmpty:te(this,ie,gt).call(this)})}addCommands(X){b(this,J).add(X),te(this,ie,rt).call(this,{hasSomethingToUndo:!0,hasSomethingToRedo:!1,isEmpty:te(this,ie,gt).call(this)})}delete(){if(this.commitOrRemove(),!this.hasSelection)return;const X=[...b(this,H)],ge=()=>{for(const Be of X)Be.remove()},ke=()=>{for(const Be of X)te(this,ie,Xt).call(this,Be)};this.addCommands({cmd:ge,undo:ke,mustExec:!0})}commitOrRemove(){var X;(X=b(this,C))==null||X.commitOrRemove()}hasSomethingToControl(){return b(this,C)||this.hasSelection}selectAll(){for(const X of b(this,H))X.commit();te(this,ie,Kt).call(this,b(this,k).values())}unselectAll(){if(b(this,C)){b(this,C).commitOrRemove();return}if(this.hasSelection){for(const X of b(this,H))X.unselect();b(this,H).clear(),te(this,ie,rt).call(this,{hasSelectedEditor:!1})}}translateSelectedEditors(X,ge,ke=!1){if(ke||this.commitOrRemove(),!this.hasSelection)return;b(this,he)[0]+=X,b(this,he)[1]+=ge;const[Be,He]=b(this,he),Ne=[...b(this,H)],U=1e3;b(this,ye)&&clearTimeout(b(this,ye)),ue(this,ye,setTimeout(()=>{ue(this,ye,null),b(this,he)[0]=b(this,he)[1]=0,this.addCommands({cmd:()=>{for(const j of Ne)b(this,k).has(j.id)&&j.translateInPage(Be,He)},undo:()=>{for(const j of Ne)b(this,k).has(j.id)&&j.translateInPage(-Be,-He)},mustExec:!1})},U));for(const j of Ne)j.translateInPage(X,ge)}setUpDragSession(){if(this.hasSelection){this.disableUserSelect(!0),ue(this,B,new Map);for(const X of b(this,H))b(this,B).set(X,{savedX:X.x,savedY:X.y,savedPageIndex:X.pageIndex,newX:0,newY:0,newPageIndex:-1})}}endDragSession(){if(!b(this,B))return!1;this.disableUserSelect(!1);const X=b(this,B);ue(this,B,null);let ge=!1;for(const[{x:Be,y:He,pageIndex:Ne},U]of X)U.newX=Be,U.newY=He,U.newPageIndex=Ne,ge||(ge=Be!==U.savedX||He!==U.savedY||Ne!==U.savedPageIndex);if(!ge)return!1;const ke=(Be,He,Ne,U)=>{if(b(this,k).has(Be.id)){const j=b(this,O).get(U);j?Be._setParentAndPosition(j,He,Ne):(Be.pageIndex=U,Be.x=He,Be.y=Ne)}};return this.addCommands({cmd:()=>{for(const[Be,{newX:He,newY:Ne,newPageIndex:U}]of X)ke(Be,He,Ne,U)},undo:()=>{for(const[Be,{savedX:He,savedY:Ne,savedPageIndex:U}]of X)ke(Be,He,Ne,U)},mustExec:!0}),!0}dragSelectedEditors(X,ge){if(b(this,B))for(const ke of b(this,B).keys())ke.drag(X,ge)}rebuild(X){if(X.parent===null){const ge=this.getLayer(X.pageIndex);ge?(ge.changeParent(X),ge.addOrRebuild(X)):(this.addEditor(X),this.addToAnnotationStorage(X),X.rebuild())}else X.parent.addOrRebuild(X)}isActive(X){return b(this,C)===X}getActive(){return b(this,C)}getMode(){return b(this,G)}get imageManager(){return(0,n.shadow)(this,"imageManager",new d)}};C=new WeakMap,k=new WeakMap,O=new WeakMap,$=new WeakMap,K=new WeakMap,J=new WeakMap,Y=new WeakMap,se=new WeakMap,B=new WeakMap,V=new WeakMap,Q=new WeakMap,N=new WeakMap,P=new WeakMap,E=new WeakMap,I=new WeakMap,z=new WeakMap,G=new WeakMap,H=new WeakMap,ee=new WeakMap,ce=new WeakMap,ve=new WeakMap,me=new WeakMap,xe=new WeakMap,Se=new WeakMap,Ce=new WeakMap,ne=new WeakMap,le=new WeakMap,L=new WeakMap,Z=new WeakMap,re=new WeakMap,he=new WeakMap,ye=new WeakMap,Fe=new WeakMap,Pe=new WeakMap,ie=new WeakSet,Cr=function(){window.addEventListener("focus",b(this,ve)),window.addEventListener("blur",b(this,ce))},Gt=function(){window.removeEventListener("focus",b(this,ve)),window.removeEventListener("blur",b(this,ce))},Wt=function(){window.addEventListener("keydown",b(this,Ce),{capture:!0})},Ft=function(){window.removeEventListener("keydown",b(this,Ce),{capture:!0})},Vt=function(){document.addEventListener("copy",b(this,me)),document.addEventListener("cut",b(this,xe)),document.addEventListener("paste",b(this,Se))},qt=function(){document.removeEventListener("copy",b(this,me)),document.removeEventListener("cut",b(this,xe)),document.removeEventListener("paste",b(this,Se))},rt=function(X){Object.entries(X).some(([ke,Be])=>b(this,re)[ke]!==Be)&&this._eventBus.dispatch("annotationeditorstateschanged",{source:this,details:Object.assign(b(this,re),X)})},pt=function(X){this._eventBus.dispatch("annotationeditorparamschanged",{source:this,details:X})},Pr=function(){if(!b(this,E)){ue(this,E,!0);for(const X of b(this,O).values())X.enable()}},wr=function(){if(this.unselectAll(),b(this,E)){ue(this,E,!1);for(const X of b(this,O).values())X.disable()}},Xt=function(X){const ge=b(this,O).get(X.pageIndex);ge?ge.addOrRebuild(X):this.addEditor(X)},gt=function(){if(b(this,k).size===0)return!0;if(b(this,k).size===1)for(const X of b(this,k).values())return X.isEmpty();return!1},Kt=function(X){b(this,H).clear();for(const ge of X)ge.isEmpty()||(b(this,H).add(ge),ge.select());te(this,ie,rt).call(this,{hasSelectedEditor:!0})},$e(We,"TRANSLATE_SMALL",1),$e(We,"TRANSLATE_BIG",10);let g=We;e.AnnotationEditorUIManager=g},(t,e,r)=>{var Y,se,B,V,Q,N,P,E,I,z,G,H,ct,ht,Zt,Ct,Pt,vt,mt;Object.defineProperty(e,"__esModule",{value:!0}),e.StatTimer=e.RenderingCancelledException=e.PixelsPerInch=e.PageViewport=e.PDFDateString=e.DOMStandardFontDataFactory=e.DOMSVGFactory=e.DOMFilterFactory=e.DOMCanvasFactory=e.DOMCMapReaderFactory=void 0,e.deprecated=A,e.getColorValues=k,e.getCurrentTransform=O,e.getCurrentTransformInverse=$,e.getFilenameFromUrl=m,e.getPdfFilenameFromUrl=w,e.getRGB=C,e.getXfaPageViewport=M,e.isDataScheme=y,e.isPdfFile=S,e.isValidFetchUrl=_,e.loadScript=F,e.noContextMenu=x,e.setLayerDimensions=K;var n=r(7),a=r(1);const s="http://www.w3.org/2000/svg",J=class J{};$e(J,"CSS",96),$e(J,"PDF",72),$e(J,"PDF_TO_CSS_UNITS",J.CSS/J.PDF);let o=J;e.PixelsPerInch=o;class h extends n.BaseFilterFactory{constructor({docId:L,ownerDocument:Z=globalThis.document}={}){super();de(this,H);de(this,Y);de(this,se);de(this,B);de(this,V);de(this,Q);de(this,N);de(this,P);de(this,E);de(this,I);de(this,z);de(this,G,0);ue(this,B,L),ue(this,V,Z)}addFilter(L){if(!L)return"none";let Z=b(this,H,ct).get(L);if(Z)return Z;let re,he,ye,Fe;if(L.length===1){const Te=L[0],Ke=new Array(256);for(let qe=0;qe<256;qe++)Ke[qe]=Te[qe]/255;Fe=re=he=ye=Ke.join(",")}else{const[Te,Ke,qe]=L,Ye=new Array(256),Me=new Array(256),Ee=new Array(256);for(let Ie=0;Ie<256;Ie++)Ye[Ie]=Te[Ie]/255,Me[Ie]=Ke[Ie]/255,Ee[Ie]=qe[Ie]/255;re=Ye.join(","),he=Me.join(","),ye=Ee.join(","),Fe=`${re}${he}${ye}`}if(Z=b(this,H,ct).get(Fe),Z)return b(this,H,ct).set(L,Z),Z;const Pe=`g_${b(this,B)}_transfer_map_${ft(this,G)._++}`,ie=`url(#${Pe})`;b(this,H,ct).set(L,ie),b(this,H,ct).set(Fe,ie);const _e=te(this,H,Ct).call(this,Pe);return te(this,H,vt).call(this,re,he,ye,_e),ie}addHCMFilter(L,Z){var Ke;const re=`${L}-${Z}`;if(b(this,N)===re)return b(this,P);if(ue(this,N,re),ue(this,P,"none"),(Ke=b(this,Q))==null||Ke.remove(),!L||!Z)return b(this,P);const he=te(this,H,mt).call(this,L);L=a.Util.makeHexColor(...he);const ye=te(this,H,mt).call(this,Z);if(Z=a.Util.makeHexColor(...ye),b(this,H,ht).style.color="",L==="#000000"&&Z==="#ffffff"||L===Z)return b(this,P);const Fe=new Array(256);for(let qe=0;qe<=255;qe++){const Ye=qe/255;Fe[qe]=Ye<=.03928?Ye/12.92:((Ye+.055)/1.055)**2.4}const Pe=Fe.join(","),ie=`g_${b(this,B)}_hcm_filter`,_e=ue(this,E,te(this,H,Ct).call(this,ie));te(this,H,vt).call(this,Pe,Pe,Pe,_e),te(this,H,Zt).call(this,_e);const Te=(qe,Ye)=>{const Me=he[qe]/255,Ee=ye[qe]/255,Ie=new Array(Ye+1);for(let ze=0;ze<=Ye;ze++)Ie[ze]=Me+ze/Ye*(Ee-Me);return Ie.join(",")};return te(this,H,vt).call(this,Te(0,5),Te(1,5),Te(2,5),_e),ue(this,P,`url(#${ie})`),b(this,P)}addHighlightHCMFilter(L,Z,re,he){var Ee;const ye=`${L}-${Z}-${re}-${he}`;if(b(this,I)===ye)return b(this,z);if(ue(this,I,ye),ue(this,z,"none"),(Ee=b(this,E))==null||Ee.remove(),!L||!Z)return b(this,z);const[Fe,Pe]=[L,Z].map(te(this,H,mt).bind(this));let ie=Math.round(.2126*Fe[0]+.7152*Fe[1]+.0722*Fe[2]),_e=Math.round(.2126*Pe[0]+.7152*Pe[1]+.0722*Pe[2]),[Te,Ke]=[re,he].map(te(this,H,mt).bind(this));_e<ie&&([ie,_e,Te,Ke]=[_e,ie,Ke,Te]),b(this,H,ht).style.color="";const qe=(Ie,ze,be)=>{const oe=new Array(256),ae=(_e-ie)/be,Re=Ie/255,We=(ze-Ie)/(255*be);let Ve=0;for(let X=0;X<=be;X++){const ge=Math.round(ie+X*ae),ke=Re+X*We;for(let Be=Ve;Be<=ge;Be++)oe[Be]=ke;Ve=ge+1}for(let X=Ve;X<256;X++)oe[X]=oe[Ve-1];return oe.join(",")},Ye=`g_${b(this,B)}_hcm_highlight_filter`,Me=ue(this,E,te(this,H,Ct).call(this,Ye));return te(this,H,Zt).call(this,Me),te(this,H,vt).call(this,qe(Te[0],Ke[0],5),qe(Te[1],Ke[1],5),qe(Te[2],Ke[2],5),Me),ue(this,z,`url(#${Ye})`),b(this,z)}destroy(L=!1){L&&(b(this,P)||b(this,z))||(b(this,se)&&(b(this,se).parentNode.parentNode.remove(),ue(this,se,null)),b(this,Y)&&(b(this,Y).clear(),ue(this,Y,null)),ue(this,G,0))}}Y=new WeakMap,se=new WeakMap,B=new WeakMap,V=new WeakMap,Q=new WeakMap,N=new WeakMap,P=new WeakMap,E=new WeakMap,I=new WeakMap,z=new WeakMap,G=new WeakMap,H=new WeakSet,ct=function(){return b(this,Y)||ue(this,Y,new Map)},ht=function(){if(!b(this,se)){const L=b(this,V).createElement("div"),{style:Z}=L;Z.visibility="hidden",Z.contain="strict",Z.width=Z.height=0,Z.position="absolute",Z.top=Z.left=0,Z.zIndex=-1;const re=b(this,V).createElementNS(s,"svg");re.setAttribute("width",0),re.setAttribute("height",0),ue(this,se,b(this,V).createElementNS(s,"defs")),L.append(re),re.append(b(this,se)),b(this,V).body.append(L)}return b(this,se)},Zt=function(L){const Z=b(this,V).createElementNS(s,"feColorMatrix");Z.setAttribute("type","matrix"),Z.setAttribute("values","0.2126 0.7152 0.0722 0 0 0.2126 0.7152 0.0722 0 0 0.2126 0.7152 0.0722 0 0 0 0 0 1 0"),L.append(Z)},Ct=function(L){const Z=b(this,V).createElementNS(s,"filter");return Z.setAttribute("color-interpolation-filters","sRGB"),Z.setAttribute("id",L),b(this,H,ht).append(Z),Z},Pt=function(L,Z,re){const he=b(this,V).createElementNS(s,Z);he.setAttribute("type","discrete"),he.setAttribute("tableValues",re),L.append(he)},vt=function(L,Z,re,he){const ye=b(this,V).createElementNS(s,"feComponentTransfer");he.append(ye),te(this,H,Pt).call(this,ye,"feFuncR",L),te(this,H,Pt).call(this,ye,"feFuncG",Z),te(this,H,Pt).call(this,ye,"feFuncB",re)},mt=function(L){return b(this,H,ht).style.color=L,C(getComputedStyle(b(this,H,ht)).getPropertyValue("color"))},e.DOMFilterFactory=h;class d extends n.BaseCanvasFactory{constructor({ownerDocument:le=globalThis.document}={}){super(),this._document=le}_createCanvas(le,L){const Z=this._document.createElement("canvas");return Z.width=le,Z.height=L,Z}}e.DOMCanvasFactory=d;async function l(ne,le=!1){if(_(ne,document.baseURI)){const L=await fetch(ne);if(!L.ok)throw new Error(L.statusText);return le?new Uint8Array(await L.arrayBuffer()):(0,a.stringToBytes)(await L.text())}return new Promise((L,Z)=>{const re=new XMLHttpRequest;re.open("GET",ne,!0),le&&(re.responseType="arraybuffer"),re.onreadystatechange=()=>{if(re.readyState===XMLHttpRequest.DONE){if(re.status===200||re.status===0){let he;if(le&&re.response?he=new Uint8Array(re.response):!le&&re.responseText&&(he=(0,a.stringToBytes)(re.responseText)),he){L(he);return}}Z(new Error(re.statusText))}},re.send(null)})}class u extends n.BaseCMapReaderFactory{_fetchData(le,L){return l(le,this.isCompressed).then(Z=>({cMapData:Z,compressionType:L}))}}e.DOMCMapReaderFactory=u;class p extends n.BaseStandardFontDataFactory{_fetchData(le){return l(le,!0)}}e.DOMStandardFontDataFactory=p;class g extends n.BaseSVGFactory{_createSVG(le){return document.createElementNS(s,le)}}e.DOMSVGFactory=g;class f{constructor({viewBox:le,scale:L,rotation:Z,offsetX:re=0,offsetY:he=0,dontFlip:ye=!1}){this.viewBox=le,this.scale=L,this.rotation=Z,this.offsetX=re,this.offsetY=he;const Fe=(le[2]+le[0])/2,Pe=(le[3]+le[1])/2;let ie,_e,Te,Ke;switch(Z%=360,Z<0&&(Z+=360),Z){case 180:ie=-1,_e=0,Te=0,Ke=1;break;case 90:ie=0,_e=1,Te=1,Ke=0;break;case 270:ie=0,_e=-1,Te=-1,Ke=0;break;case 0:ie=1,_e=0,Te=0,Ke=-1;break;default:throw new Error("PageViewport: Invalid rotation, must be a multiple of 90 degrees.")}ye&&(Te=-Te,Ke=-Ke);let qe,Ye,Me,Ee;ie===0?(qe=Math.abs(Pe-le[1])*L+re,Ye=Math.abs(Fe-le[0])*L+he,Me=(le[3]-le[1])*L,Ee=(le[2]-le[0])*L):(qe=Math.abs(Fe-le[0])*L+re,Ye=Math.abs(Pe-le[1])*L+he,Me=(le[2]-le[0])*L,Ee=(le[3]-le[1])*L),this.transform=[ie*L,_e*L,Te*L,Ke*L,qe-ie*L*Fe-Te*L*Pe,Ye-_e*L*Fe-Ke*L*Pe],this.width=Me,this.height=Ee}get rawDims(){const{viewBox:le}=this;return(0,a.shadow)(this,"rawDims",{pageWidth:le[2]-le[0],pageHeight:le[3]-le[1],pageX:le[0],pageY:le[1]})}clone({scale:le=this.scale,rotation:L=this.rotation,offsetX:Z=this.offsetX,offsetY:re=this.offsetY,dontFlip:he=!1}={}){return new f({viewBox:this.viewBox.slice(),scale:le,rotation:L,offsetX:Z,offsetY:re,dontFlip:he})}convertToViewportPoint(le,L){return a.Util.applyTransform([le,L],this.transform)}convertToViewportRectangle(le){const L=a.Util.applyTransform([le[0],le[1]],this.transform),Z=a.Util.applyTransform([le[2],le[3]],this.transform);return[L[0],L[1],Z[0],Z[1]]}convertToPdfPoint(le,L){return a.Util.applyInverseTransform([le,L],this.transform)}}e.PageViewport=f;class v extends a.BaseException{constructor(le,L=0){super(le,"RenderingCancelledException"),this.extraDelay=L}}e.RenderingCancelledException=v;function y(ne){const le=ne.length;let L=0;for(;L<le&&ne[L].trim()==="";)L++;return ne.substring(L,L+5).toLowerCase()==="data:"}function S(ne){return typeof ne=="string"&&/\.pdf$/i.test(ne)}function m(ne,le=!1){return le||([ne]=ne.split(/[#?]/,1)),ne.substring(ne.lastIndexOf("/")+1)}function w(ne,le="document.pdf"){if(typeof ne!="string")return le;if(y(ne))return(0,a.warn)('getPdfFilenameFromUrl: ignore "data:"-URL for performance reasons.'),le;const L=/^(?:(?:[^:]+:)?\/\/[^/]+)?([^?#]*)(\?[^#]*)?(#.*)?$/,Z=/[^/?#=]+\.pdf\b(?!.*\.pdf\b)/i,re=L.exec(ne);let he=Z.exec(re[1])||Z.exec(re[2])||Z.exec(re[3]);if(he&&(he=he[0],he.includes("%")))try{he=Z.exec(decodeURIComponent(he))[0]}catch{}return he||le}class R{constructor(){$e(this,"started",Object.create(null));$e(this,"times",[])}time(le){le in this.started&&(0,a.warn)(`Timer is already running for ${le}`),this.started[le]=Date.now()}timeEnd(le){le in this.started||(0,a.warn)(`Timer has not been started for ${le}`),this.times.push({name:le,start:this.started[le],end:Date.now()}),delete this.started[le]}toString(){const le=[];let L=0;for(const{name:Z}of this.times)L=Math.max(Z.length,L);for(const{name:Z,start:re,end:he}of this.times)le.push(`${Z.padEnd(L)} ${he-re}ms
|
|
2
|
+
`);return le.join("")}}e.StatTimer=R;function _(ne,le){try{const{protocol:L}=le?new URL(ne,le):new URL(ne);return L==="http:"||L==="https:"}catch{return!1}}function x(ne){ne.preventDefault()}function F(ne,le=!1){return new Promise((L,Z)=>{const re=document.createElement("script");re.src=ne,re.onload=function(he){le&&re.remove(),L(he)},re.onerror=function(){Z(new Error(`Cannot load script at: ${re.src}`))},(document.head||document.documentElement).append(re)})}function A(ne){console.log("Deprecated API usage: "+ne)}let D;class T{static toDateObject(le){if(!le||typeof le!="string")return null;D||(D=new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?"));const L=D.exec(le);if(!L)return null;const Z=parseInt(L[1],10);let re=parseInt(L[2],10);re=re>=1&&re<=12?re-1:0;let he=parseInt(L[3],10);he=he>=1&&he<=31?he:1;let ye=parseInt(L[4],10);ye=ye>=0&&ye<=23?ye:0;let Fe=parseInt(L[5],10);Fe=Fe>=0&&Fe<=59?Fe:0;let Pe=parseInt(L[6],10);Pe=Pe>=0&&Pe<=59?Pe:0;const ie=L[7]||"Z";let _e=parseInt(L[8],10);_e=_e>=0&&_e<=23?_e:0;let Te=parseInt(L[9],10)||0;return Te=Te>=0&&Te<=59?Te:0,ie==="-"?(ye+=_e,Fe+=Te):ie==="+"&&(ye-=_e,Fe-=Te),new Date(Date.UTC(Z,re,he,ye,Fe,Pe))}}e.PDFDateString=T;function M(ne,{scale:le=1,rotation:L=0}){const{width:Z,height:re}=ne.attributes.style,he=[0,0,parseInt(Z),parseInt(re)];return new f({viewBox:he,scale:le,rotation:L})}function C(ne){if(ne.startsWith("#")){const le=parseInt(ne.slice(1),16);return[(le&16711680)>>16,(le&65280)>>8,le&255]}return ne.startsWith("rgb(")?ne.slice(4,-1).split(",").map(le=>parseInt(le)):ne.startsWith("rgba(")?ne.slice(5,-1).split(",").map(le=>parseInt(le)).slice(0,3):((0,a.warn)(`Not a valid color format: "${ne}"`),[0,0,0])}function k(ne){const le=document.createElement("span");le.style.visibility="hidden",document.body.append(le);for(const L of ne.keys()){le.style.color=L;const Z=window.getComputedStyle(le).color;ne.set(L,C(Z))}le.remove()}function O(ne){const{a:le,b:L,c:Z,d:re,e:he,f:ye}=ne.getTransform();return[le,L,Z,re,he,ye]}function $(ne){const{a:le,b:L,c:Z,d:re,e:he,f:ye}=ne.getTransform().invertSelf();return[le,L,Z,re,he,ye]}function K(ne,le,L=!1,Z=!0){if(le instanceof f){const{pageWidth:re,pageHeight:he}=le.rawDims,{style:ye}=ne,Fe=a.FeatureTest.isCSSRoundSupported,Pe=`var(--scale-factor) * ${re}px`,ie=`var(--scale-factor) * ${he}px`,_e=Fe?`round(${Pe}, 1px)`:`calc(${Pe})`,Te=Fe?`round(${ie}, 1px)`:`calc(${ie})`;!L||le.rotation%180===0?(ye.width=_e,ye.height=Te):(ye.width=Te,ye.height=_e)}Z&&ne.setAttribute("data-main-rotation",le.rotation)}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.BaseStandardFontDataFactory=e.BaseSVGFactory=e.BaseFilterFactory=e.BaseCanvasFactory=e.BaseCMapReaderFactory=void 0;var n=r(1);class a{constructor(){this.constructor===a&&(0,n.unreachable)("Cannot initialize BaseFilterFactory.")}addFilter(u){return"none"}addHCMFilter(u,p){return"none"}addHighlightHCMFilter(u,p,g,f){return"none"}destroy(u=!1){}}e.BaseFilterFactory=a;class s{constructor(){this.constructor===s&&(0,n.unreachable)("Cannot initialize BaseCanvasFactory.")}create(u,p){if(u<=0||p<=0)throw new Error("Invalid canvas size");const g=this._createCanvas(u,p);return{canvas:g,context:g.getContext("2d")}}reset(u,p,g){if(!u.canvas)throw new Error("Canvas is not specified");if(p<=0||g<=0)throw new Error("Invalid canvas size");u.canvas.width=p,u.canvas.height=g}destroy(u){if(!u.canvas)throw new Error("Canvas is not specified");u.canvas.width=0,u.canvas.height=0,u.canvas=null,u.context=null}_createCanvas(u,p){(0,n.unreachable)("Abstract method `_createCanvas` called.")}}e.BaseCanvasFactory=s;class o{constructor({baseUrl:u=null,isCompressed:p=!0}){this.constructor===o&&(0,n.unreachable)("Cannot initialize BaseCMapReaderFactory."),this.baseUrl=u,this.isCompressed=p}async fetch({name:u}){if(!this.baseUrl)throw new Error('The CMap "baseUrl" parameter must be specified, ensure that the "cMapUrl" and "cMapPacked" API parameters are provided.');if(!u)throw new Error("CMap name must be specified.");const p=this.baseUrl+u+(this.isCompressed?".bcmap":""),g=this.isCompressed?n.CMapCompressionType.BINARY:n.CMapCompressionType.NONE;return this._fetchData(p,g).catch(f=>{throw new Error(`Unable to load ${this.isCompressed?"binary ":""}CMap at: ${p}`)})}_fetchData(u,p){(0,n.unreachable)("Abstract method `_fetchData` called.")}}e.BaseCMapReaderFactory=o;class h{constructor({baseUrl:u=null}){this.constructor===h&&(0,n.unreachable)("Cannot initialize BaseStandardFontDataFactory."),this.baseUrl=u}async fetch({filename:u}){if(!this.baseUrl)throw new Error('The standard font "baseUrl" parameter must be specified, ensure that the "standardFontDataUrl" API parameter is provided.');if(!u)throw new Error("Font filename must be specified.");const p=`${this.baseUrl}${u}`;return this._fetchData(p).catch(g=>{throw new Error(`Unable to load font data at: ${p}`)})}_fetchData(u){(0,n.unreachable)("Abstract method `_fetchData` called.")}}e.BaseStandardFontDataFactory=h;class d{constructor(){this.constructor===d&&(0,n.unreachable)("Cannot initialize BaseSVGFactory.")}create(u,p,g=!1){if(u<=0||p<=0)throw new Error("Invalid SVG dimensions");const f=this._createSVG("svg:svg");return f.setAttribute("version","1.1"),g||(f.setAttribute("width",`${u}px`),f.setAttribute("height",`${p}px`)),f.setAttribute("preserveAspectRatio","none"),f.setAttribute("viewBox",`0 0 ${u} ${p}`),f}createElement(u){if(typeof u!="string")throw new Error("Invalid SVG element type");return this._createSVG(u)}_createSVG(u){(0,n.unreachable)("Abstract method `_createSVG` called.")}}e.BaseSVGFactory=d},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.MurmurHash3_64=void 0;var n=r(1);const a=3285377520,s=4294901760,o=65535;class h{constructor(l){this.h1=l?l&4294967295:a,this.h2=l?l&4294967295:a}update(l){let u,p;if(typeof l=="string"){u=new Uint8Array(l.length*2),p=0;for(let A=0,D=l.length;A<D;A++){const T=l.charCodeAt(A);T<=255?u[p++]=T:(u[p++]=T>>>8,u[p++]=T&255)}}else if((0,n.isArrayBuffer)(l))u=l.slice(),p=u.byteLength;else throw new Error("Wrong data format in MurmurHash3_64_update. Input must be a string or array.");const g=p>>2,f=p-g*4,v=new Uint32Array(u.buffer,0,g);let y=0,S=0,m=this.h1,w=this.h2;const R=3432918353,_=461845907,x=R&o,F=_&o;for(let A=0;A<g;A++)A&1?(y=v[A],y=y*R&s|y*x&o,y=y<<15|y>>>17,y=y*_&s|y*F&o,m^=y,m=m<<13|m>>>19,m=m*5+3864292196):(S=v[A],S=S*R&s|S*x&o,S=S<<15|S>>>17,S=S*_&s|S*F&o,w^=S,w=w<<13|w>>>19,w=w*5+3864292196);switch(y=0,f){case 3:y^=u[g*4+2]<<16;case 2:y^=u[g*4+1]<<8;case 1:y^=u[g*4],y=y*R&s|y*x&o,y=y<<15|y>>>17,y=y*_&s|y*F&o,g&1?m^=y:w^=y}this.h1=m,this.h2=w}hexdigest(){let l=this.h1,u=this.h2;return l^=u>>>1,l=l*3981806797&s|l*36045&o,u=u*4283543511&s|((u<<16|l>>>16)*2950163797&s)>>>16,l^=u>>>1,l=l*444984403&s|l*60499&o,u=u*3301882366&s|((u<<16|l>>>16)*3120437893&s)>>>16,l^=u>>>1,(l>>>0).toString(16).padStart(8,"0")+(u>>>0).toString(16).padStart(8,"0")}}e.MurmurHash3_64=h},(t,e,r)=>{var o;Object.defineProperty(e,"__esModule",{value:!0}),e.FontLoader=e.FontFaceObject=void 0;var n=r(1);class a{constructor({ownerDocument:d=globalThis.document,styleElement:l=null}){de(this,o,new Set);this._document=d,this.nativeFontFaces=new Set,this.styleElement=null,this.loadingRequests=[],this.loadTestFontId=0}addNativeFontFace(d){this.nativeFontFaces.add(d),this._document.fonts.add(d)}removeNativeFontFace(d){this.nativeFontFaces.delete(d),this._document.fonts.delete(d)}insertRule(d){this.styleElement||(this.styleElement=this._document.createElement("style"),this._document.documentElement.getElementsByTagName("head")[0].append(this.styleElement));const l=this.styleElement.sheet;l.insertRule(d,l.cssRules.length)}clear(){for(const d of this.nativeFontFaces)this._document.fonts.delete(d);this.nativeFontFaces.clear(),b(this,o).clear(),this.styleElement&&(this.styleElement.remove(),this.styleElement=null)}async loadSystemFont(d){if(!(!d||b(this,o).has(d.loadedName))){if((0,n.assert)(!this.disableFontFace,"loadSystemFont shouldn't be called when `disableFontFace` is set."),this.isFontLoadingAPISupported){const{loadedName:l,src:u,style:p}=d,g=new FontFace(l,u,p);this.addNativeFontFace(g);try{await g.load(),b(this,o).add(l)}catch{(0,n.warn)(`Cannot load system font: ${d.baseFontName}, installing it could help to improve PDF rendering.`),this.removeNativeFontFace(g)}return}(0,n.unreachable)("Not implemented: loadSystemFont without the Font Loading API.")}}async bind(d){if(d.attached||d.missingFile&&!d.systemFontInfo)return;if(d.attached=!0,d.systemFontInfo){await this.loadSystemFont(d.systemFontInfo);return}if(this.isFontLoadingAPISupported){const u=d.createNativeFontFace();if(u){this.addNativeFontFace(u);try{await u.loaded}catch(p){throw(0,n.warn)(`Failed to load font '${u.family}': '${p}'.`),d.disableFontFace=!0,p}}return}const l=d.createFontFaceRule();if(l){if(this.insertRule(l),this.isSyncFontLoadingSupported)return;await new Promise(u=>{const p=this._queueLoadingCallback(u);this._prepareFontLoadEvent(d,p)})}}get isFontLoadingAPISupported(){var l;const d=!!((l=this._document)!=null&&l.fonts);return(0,n.shadow)(this,"isFontLoadingAPISupported",d)}get isSyncFontLoadingSupported(){let d=!1;return(n.isNodeJS||typeof navigator<"u"&&/Mozilla\/5.0.*?rv:\d+.*? Gecko/.test(navigator.userAgent))&&(d=!0),(0,n.shadow)(this,"isSyncFontLoadingSupported",d)}_queueLoadingCallback(d){function l(){for((0,n.assert)(!p.done,"completeRequest() cannot be called twice."),p.done=!0;u.length>0&&u[0].done;){const g=u.shift();setTimeout(g.callback,0)}}const{loadingRequests:u}=this,p={done:!1,complete:l,callback:d};return u.push(p),p}get _loadTestFont(){const d=atob("T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQAFQAABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABDQLUAAACNAAAAUJoZWFk/xVFDQAAALwAAAA2aGhlYQdkA+oAAAD0AAAAJGhtdHgD6AAAAAAEWAAAAAZtYXhwAAJQAAAAARgAAAAGbmFtZVjmdH4AAAGAAAAAsXBvc3T/hgAzAAADeAAAACAAAQAAAAEAALZRFsRfDzz1AAsD6AAAAADOBOTLAAAAAM4KHDwAAAAAA+gDIQAAAAgAAgAAAAAAAAABAAADIQAAAFoD6AAAAAAD6AABAAAAAAAAAAAAAAAAAAAAAQAAUAAAAgAAAAQD6AH0AAUAAAKKArw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AAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA==");return(0,n.shadow)(this,"_loadTestFont",d)}_prepareFontLoadEvent(d,l){function u(C,k){return C.charCodeAt(k)<<24|C.charCodeAt(k+1)<<16|C.charCodeAt(k+2)<<8|C.charCodeAt(k+3)&255}function p(C,k,O,$){const K=C.substring(0,k),J=C.substring(k+O);return K+$+J}let g,f;const v=this._document.createElement("canvas");v.width=1,v.height=1;const y=v.getContext("2d");let S=0;function m(C,k){if(++S>30){(0,n.warn)("Load test font never loaded."),k();return}if(y.font="30px "+C,y.fillText(".",0,20),y.getImageData(0,0,1,1).data[3]>0){k();return}setTimeout(m.bind(null,C,k))}const w=`lt${Date.now()}${this.loadTestFontId++}`;let R=this._loadTestFont;R=p(R,976,w.length,w);const x=16,F=1482184792;let A=u(R,x);for(g=0,f=w.length-3;g<f;g+=4)A=A-F+u(w,g)|0;g<w.length&&(A=A-F+u(w+"XXX",g)|0),R=p(R,x,4,(0,n.string32)(A));const D=`url(data:font/opentype;base64,${btoa(R)});`,T=`@font-face {font-family:"${w}";src:${D}}`;this.insertRule(T);const M=this._document.createElement("div");M.style.visibility="hidden",M.style.width=M.style.height="10px",M.style.position="absolute",M.style.top=M.style.left="0px";for(const C of[d.loadedName,w]){const k=this._document.createElement("span");k.textContent="Hi",k.style.fontFamily=C,M.append(k)}this._document.body.append(M),m(w,()=>{M.remove(),l.complete()})}}o=new WeakMap,e.FontLoader=a;class s{constructor(d,{isEvalSupported:l=!0,disableFontFace:u=!1,ignoreErrors:p=!1,inspectFont:g=null}){this.compiledGlyphs=Object.create(null);for(const f in d)this[f]=d[f];this.isEvalSupported=l!==!1,this.disableFontFace=u===!0,this.ignoreErrors=p===!0,this._inspectFont=g}createNativeFontFace(){var l;if(!this.data||this.disableFontFace)return null;let d;if(!this.cssFontInfo)d=new FontFace(this.loadedName,this.data,{});else{const u={weight:this.cssFontInfo.fontWeight};this.cssFontInfo.italicAngle&&(u.style=`oblique ${this.cssFontInfo.italicAngle}deg`),d=new FontFace(this.cssFontInfo.fontFamily,this.data,u)}return(l=this._inspectFont)==null||l.call(this,this),d}createFontFaceRule(){var p;if(!this.data||this.disableFontFace)return null;const d=(0,n.bytesToString)(this.data),l=`url(data:${this.mimetype};base64,${btoa(d)});`;let u;if(!this.cssFontInfo)u=`@font-face {font-family:"${this.loadedName}";src:${l}}`;else{let g=`font-weight: ${this.cssFontInfo.fontWeight};`;this.cssFontInfo.italicAngle&&(g+=`font-style: oblique ${this.cssFontInfo.italicAngle}deg;`),u=`@font-face {font-family:"${this.cssFontInfo.fontFamily}";${g}src:${l}}`}return(p=this._inspectFont)==null||p.call(this,this,l),u}getPathGenerator(d,l){if(this.compiledGlyphs[l]!==void 0)return this.compiledGlyphs[l];let u;try{u=d.get(this.loadedName+"_path_"+l)}catch(p){if(!this.ignoreErrors)throw p;return(0,n.warn)(`getPathGenerator - ignoring character: "${p}".`),this.compiledGlyphs[l]=function(g,f){}}if(this.isEvalSupported&&n.FeatureTest.isEvalSupported){const p=[];for(const g of u){const f=g.args!==void 0?g.args.join(","):"";p.push("c.",g.cmd,"(",f,`);
|
|
3
|
+
`)}return this.compiledGlyphs[l]=new Function("c","size",p.join(""))}return this.compiledGlyphs[l]=function(p,g){for(const f of u)f.cmd==="scale"&&(f.args=[g,-g]),p[f.cmd].apply(p,f.args)}}}e.FontFaceObject=s},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.NodeStandardFontDataFactory=e.NodeFilterFactory=e.NodeCanvasFactory=e.NodeCMapReaderFactory=void 0;var n=r(7);r(1);const a=function(l){return new Promise((u,p)=>{require$$5.readFile(l,(f,v)=>{if(f||!v){p(new Error(f));return}u(new Uint8Array(v))})})};class s extends n.BaseFilterFactory{}e.NodeFilterFactory=s;class o extends n.BaseCanvasFactory{_createCanvas(u,p){return require$$5.createCanvas(u,p)}}e.NodeCanvasFactory=o;class h extends n.BaseCMapReaderFactory{_fetchData(u,p){return a(u).then(g=>({cMapData:g,compressionType:p}))}}e.NodeCMapReaderFactory=h;class d extends n.BaseStandardFontDataFactory{_fetchData(u){return a(u)}}e.NodeStandardFontDataFactory=d},(t,e,r)=>{var se,Yt,Jt;Object.defineProperty(e,"__esModule",{value:!0}),e.CanvasGraphics=void 0;var n=r(1),a=r(6),s=r(12),o=r(13);const h=16,d=100,l=4096,u=15,p=10,g=1e3,f=16;function v(N,P){if(N._removeMirroring)throw new Error("Context is already forwarding operations.");N.__originalSave=N.save,N.__originalRestore=N.restore,N.__originalRotate=N.rotate,N.__originalScale=N.scale,N.__originalTranslate=N.translate,N.__originalTransform=N.transform,N.__originalSetTransform=N.setTransform,N.__originalResetTransform=N.resetTransform,N.__originalClip=N.clip,N.__originalMoveTo=N.moveTo,N.__originalLineTo=N.lineTo,N.__originalBezierCurveTo=N.bezierCurveTo,N.__originalRect=N.rect,N.__originalClosePath=N.closePath,N.__originalBeginPath=N.beginPath,N._removeMirroring=()=>{N.save=N.__originalSave,N.restore=N.__originalRestore,N.rotate=N.__originalRotate,N.scale=N.__originalScale,N.translate=N.__originalTranslate,N.transform=N.__originalTransform,N.setTransform=N.__originalSetTransform,N.resetTransform=N.__originalResetTransform,N.clip=N.__originalClip,N.moveTo=N.__originalMoveTo,N.lineTo=N.__originalLineTo,N.bezierCurveTo=N.__originalBezierCurveTo,N.rect=N.__originalRect,N.closePath=N.__originalClosePath,N.beginPath=N.__originalBeginPath,delete N._removeMirroring},N.save=function(){P.save(),this.__originalSave()},N.restore=function(){P.restore(),this.__originalRestore()},N.translate=function(I,z){P.translate(I,z),this.__originalTranslate(I,z)},N.scale=function(I,z){P.scale(I,z),this.__originalScale(I,z)},N.transform=function(I,z,G,H,ee,ce){P.transform(I,z,G,H,ee,ce),this.__originalTransform(I,z,G,H,ee,ce)},N.setTransform=function(I,z,G,H,ee,ce){P.setTransform(I,z,G,H,ee,ce),this.__originalSetTransform(I,z,G,H,ee,ce)},N.resetTransform=function(){P.resetTransform(),this.__originalResetTransform()},N.rotate=function(I){P.rotate(I),this.__originalRotate(I)},N.clip=function(I){P.clip(I),this.__originalClip(I)},N.moveTo=function(E,I){P.moveTo(E,I),this.__originalMoveTo(E,I)},N.lineTo=function(E,I){P.lineTo(E,I),this.__originalLineTo(E,I)},N.bezierCurveTo=function(E,I,z,G,H,ee){P.bezierCurveTo(E,I,z,G,H,ee),this.__originalBezierCurveTo(E,I,z,G,H,ee)},N.rect=function(E,I,z,G){P.rect(E,I,z,G),this.__originalRect(E,I,z,G)},N.closePath=function(){P.closePath(),this.__originalClosePath()},N.beginPath=function(){P.beginPath(),this.__originalBeginPath()}}class y{constructor(P){this.canvasFactory=P,this.cache=Object.create(null)}getCanvas(P,E,I){let z;return this.cache[P]!==void 0?(z=this.cache[P],this.canvasFactory.reset(z,E,I)):(z=this.canvasFactory.create(E,I),this.cache[P]=z),z}delete(P){delete this.cache[P]}clear(){for(const P in this.cache){const E=this.cache[P];this.canvasFactory.destroy(E),delete this.cache[P]}}}function S(N,P,E,I,z,G,H,ee,ce,ve){const[me,xe,Se,Ce,ne,le]=(0,a.getCurrentTransform)(N);if(xe===0&&Se===0){const re=H*me+ne,he=Math.round(re),ye=ee*Ce+le,Fe=Math.round(ye),Pe=(H+ce)*me+ne,ie=Math.abs(Math.round(Pe)-he)||1,_e=(ee+ve)*Ce+le,Te=Math.abs(Math.round(_e)-Fe)||1;return N.setTransform(Math.sign(me),0,0,Math.sign(Ce),he,Fe),N.drawImage(P,E,I,z,G,0,0,ie,Te),N.setTransform(me,xe,Se,Ce,ne,le),[ie,Te]}if(me===0&&Ce===0){const re=ee*Se+ne,he=Math.round(re),ye=H*xe+le,Fe=Math.round(ye),Pe=(ee+ve)*Se+ne,ie=Math.abs(Math.round(Pe)-he)||1,_e=(H+ce)*xe+le,Te=Math.abs(Math.round(_e)-Fe)||1;return N.setTransform(0,Math.sign(xe),Math.sign(Se),0,he,Fe),N.drawImage(P,E,I,z,G,0,0,Te,ie),N.setTransform(me,xe,Se,Ce,ne,le),[Te,ie]}N.drawImage(P,E,I,z,G,H,ee,ce,ve);const L=Math.hypot(me,xe),Z=Math.hypot(Se,Ce);return[L*ce,Z*ve]}function m(N){const{width:P,height:E}=N;if(P>g||E>g)return null;const I=1e3,z=new Uint8Array([0,2,4,0,1,0,5,4,8,10,0,8,0,2,1,0]),G=P+1;let H=new Uint8Array(G*(E+1)),ee,ce,ve;const me=P+7&-8;let xe=new Uint8Array(me*E),Se=0;for(const Z of N.data){let re=128;for(;re>0;)xe[Se++]=Z&re?0:255,re>>=1}let Ce=0;for(Se=0,xe[Se]!==0&&(H[0]=1,++Ce),ce=1;ce<P;ce++)xe[Se]!==xe[Se+1]&&(H[ce]=xe[Se]?2:1,++Ce),Se++;for(xe[Se]!==0&&(H[ce]=2,++Ce),ee=1;ee<E;ee++){Se=ee*me,ve=ee*G,xe[Se-me]!==xe[Se]&&(H[ve]=xe[Se]?1:8,++Ce);let Z=(xe[Se]?4:0)+(xe[Se-me]?8:0);for(ce=1;ce<P;ce++)Z=(Z>>2)+(xe[Se+1]?4:0)+(xe[Se-me+1]?8:0),z[Z]&&(H[ve+ce]=z[Z],++Ce),Se++;if(xe[Se-me]!==xe[Se]&&(H[ve+ce]=xe[Se]?2:4,++Ce),Ce>I)return null}for(Se=me*(E-1),ve=ee*G,xe[Se]!==0&&(H[ve]=8,++Ce),ce=1;ce<P;ce++)xe[Se]!==xe[Se+1]&&(H[ve+ce]=xe[Se]?4:8,++Ce),Se++;if(xe[Se]!==0&&(H[ve+ce]=4,++Ce),Ce>I)return null;const ne=new Int32Array([0,G,-1,0,-G,0,0,0,1]),le=new Path2D;for(ee=0;Ce&&ee<=E;ee++){let Z=ee*G;const re=Z+P;for(;Z<re&&!H[Z];)Z++;if(Z===re)continue;le.moveTo(Z%G,ee);const he=Z;let ye=H[Z];do{const Fe=ne[ye];do Z+=Fe;while(!H[Z]);const Pe=H[Z];Pe!==5&&Pe!==10?(ye=Pe,H[Z]=0):(ye=Pe&51*ye>>4,H[Z]&=ye>>2|ye<<2),le.lineTo(Z%G,Z/G|0),H[Z]||--Ce}while(he!==Z);--ee}return xe=null,H=null,function(Z){Z.save(),Z.scale(1/P,-1/E),Z.translate(0,-E),Z.fill(le),Z.beginPath(),Z.restore()}}class w{constructor(P,E){this.alphaIsShape=!1,this.fontSize=0,this.fontSizeScale=1,this.textMatrix=n.IDENTITY_MATRIX,this.textMatrixScale=1,this.fontMatrix=n.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=n.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="none",this.startNewPathAndClipBox([0,0,P,E])}clone(){const P=Object.create(this);return P.clipBox=this.clipBox.slice(),P}setCurrentPoint(P,E){this.x=P,this.y=E}updatePathMinMax(P,E,I){[E,I]=n.Util.applyTransform([E,I],P),this.minX=Math.min(this.minX,E),this.minY=Math.min(this.minY,I),this.maxX=Math.max(this.maxX,E),this.maxY=Math.max(this.maxY,I)}updateRectMinMax(P,E){const I=n.Util.applyTransform(E,P),z=n.Util.applyTransform(E.slice(2),P);this.minX=Math.min(this.minX,I[0],z[0]),this.minY=Math.min(this.minY,I[1],z[1]),this.maxX=Math.max(this.maxX,I[0],z[0]),this.maxY=Math.max(this.maxY,I[1],z[1])}updateScalingPathMinMax(P,E){n.Util.scaleMinMax(P,E),this.minX=Math.min(this.minX,E[0]),this.maxX=Math.max(this.maxX,E[1]),this.minY=Math.min(this.minY,E[2]),this.maxY=Math.max(this.maxY,E[3])}updateCurvePathMinMax(P,E,I,z,G,H,ee,ce,ve,me){const xe=n.Util.bezierBoundingBox(E,I,z,G,H,ee,ce,ve);if(me){me[0]=Math.min(me[0],xe[0],xe[2]),me[1]=Math.max(me[1],xe[0],xe[2]),me[2]=Math.min(me[2],xe[1],xe[3]),me[3]=Math.max(me[3],xe[1],xe[3]);return}this.updateRectMinMax(P,xe)}getPathBoundingBox(P=s.PathType.FILL,E=null){const I=[this.minX,this.minY,this.maxX,this.maxY];if(P===s.PathType.STROKE){E||(0,n.unreachable)("Stroke bounding box must include transform.");const z=n.Util.singularValueDecompose2dScale(E),G=z[0]*this.lineWidth/2,H=z[1]*this.lineWidth/2;I[0]-=G,I[1]-=H,I[2]+=G,I[3]+=H}return I}updateClipFromPath(){const P=n.Util.intersect(this.clipBox,this.getPathBoundingBox());this.startNewPathAndClipBox(P||[0,0,0,0])}isEmptyClip(){return this.minX===1/0}startNewPathAndClipBox(P){this.clipBox=P,this.minX=1/0,this.minY=1/0,this.maxX=0,this.maxY=0}getClippedPathBoundingBox(P=s.PathType.FILL,E=null){return n.Util.intersect(this.clipBox,this.getPathBoundingBox(P,E))}}function R(N,P){if(typeof ImageData<"u"&&P instanceof ImageData){N.putImageData(P,0,0);return}const E=P.height,I=P.width,z=E%f,G=(E-z)/f,H=z===0?G:G+1,ee=N.createImageData(I,f);let ce=0,ve;const me=P.data,xe=ee.data;let Se,Ce,ne,le;if(P.kind===n.ImageKind.GRAYSCALE_1BPP){const L=me.byteLength,Z=new Uint32Array(xe.buffer,0,xe.byteLength>>2),re=Z.length,he=I+7>>3,ye=4294967295,Fe=n.FeatureTest.isLittleEndian?4278190080:255;for(Se=0;Se<H;Se++){for(ne=Se<G?f:z,ve=0,Ce=0;Ce<ne;Ce++){const Pe=L-ce;let ie=0;const _e=Pe>he?I:Pe*8-7,Te=_e&-8;let Ke=0,qe=0;for(;ie<Te;ie+=8)qe=me[ce++],Z[ve++]=qe&128?ye:Fe,Z[ve++]=qe&64?ye:Fe,Z[ve++]=qe&32?ye:Fe,Z[ve++]=qe&16?ye:Fe,Z[ve++]=qe&8?ye:Fe,Z[ve++]=qe&4?ye:Fe,Z[ve++]=qe&2?ye:Fe,Z[ve++]=qe&1?ye:Fe;for(;ie<_e;ie++)Ke===0&&(qe=me[ce++],Ke=128),Z[ve++]=qe&Ke?ye:Fe,Ke>>=1}for(;ve<re;)Z[ve++]=0;N.putImageData(ee,0,Se*f)}}else if(P.kind===n.ImageKind.RGBA_32BPP){for(Ce=0,le=I*f*4,Se=0;Se<G;Se++)xe.set(me.subarray(ce,ce+le)),ce+=le,N.putImageData(ee,0,Ce),Ce+=f;Se<H&&(le=I*z*4,xe.set(me.subarray(ce,ce+le)),N.putImageData(ee,0,Ce))}else if(P.kind===n.ImageKind.RGB_24BPP)for(ne=f,le=I*ne,Se=0;Se<H;Se++){for(Se>=G&&(ne=z,le=I*ne),ve=0,Ce=le;Ce--;)xe[ve++]=me[ce++],xe[ve++]=me[ce++],xe[ve++]=me[ce++],xe[ve++]=255;N.putImageData(ee,0,Se*f)}else throw new Error(`bad image kind: ${P.kind}`)}function _(N,P){if(P.bitmap){N.drawImage(P.bitmap,0,0);return}const E=P.height,I=P.width,z=E%f,G=(E-z)/f,H=z===0?G:G+1,ee=N.createImageData(I,f);let ce=0;const ve=P.data,me=ee.data;for(let xe=0;xe<H;xe++){const Se=xe<G?f:z;({srcPos:ce}=(0,o.convertBlackAndWhiteToRGBA)({src:ve,srcPos:ce,dest:me,width:I,height:Se,nonBlackColor:0})),N.putImageData(ee,0,xe*f)}}function x(N,P){const E=["strokeStyle","fillStyle","fillRule","globalAlpha","lineWidth","lineCap","lineJoin","miterLimit","globalCompositeOperation","font","filter"];for(const I of E)N[I]!==void 0&&(P[I]=N[I]);N.setLineDash!==void 0&&(P.setLineDash(N.getLineDash()),P.lineDashOffset=N.lineDashOffset)}function F(N){if(N.strokeStyle=N.fillStyle="#000000",N.fillRule="nonzero",N.globalAlpha=1,N.lineWidth=1,N.lineCap="butt",N.lineJoin="miter",N.miterLimit=10,N.globalCompositeOperation="source-over",N.font="10px sans-serif",N.setLineDash!==void 0&&(N.setLineDash([]),N.lineDashOffset=0),!n.isNodeJS){const{filter:P}=N;P!=="none"&&P!==""&&(N.filter="none")}}function A(N,P,E,I){const z=N.length;for(let G=3;G<z;G+=4){const H=N[G];if(H===0)N[G-3]=P,N[G-2]=E,N[G-1]=I;else if(H<255){const ee=255-H;N[G-3]=N[G-3]*H+P*ee>>8,N[G-2]=N[G-2]*H+E*ee>>8,N[G-1]=N[G-1]*H+I*ee>>8}}}function D(N,P,E){const I=N.length,z=1/255;for(let G=3;G<I;G+=4){const H=E?E[N[G]]:N[G];P[G]=P[G]*H*z|0}}function T(N,P,E){const I=N.length;for(let z=3;z<I;z+=4){const G=N[z-3]*77+N[z-2]*152+N[z-1]*28;P[z]=E?P[z]*E[G>>8]>>8:P[z]*G>>16}}function M(N,P,E,I,z,G,H,ee,ce,ve,me){const xe=!!G,Se=xe?G[0]:0,Ce=xe?G[1]:0,ne=xe?G[2]:0,le=z==="Luminosity"?T:D,Z=Math.min(I,Math.ceil(1048576/E));for(let re=0;re<I;re+=Z){const he=Math.min(Z,I-re),ye=N.getImageData(ee-ve,re+(ce-me),E,he),Fe=P.getImageData(ee,re+ce,E,he);xe&&A(ye.data,Se,Ce,ne),le(ye.data,Fe.data,H),P.putImageData(Fe,ee,re+ce)}}function C(N,P,E,I){const z=I[0],G=I[1],H=I[2]-z,ee=I[3]-G;H===0||ee===0||(M(P.context,E,H,ee,P.subtype,P.backdrop,P.transferMap,z,G,P.offsetX,P.offsetY),N.save(),N.globalAlpha=1,N.globalCompositeOperation="source-over",N.setTransform(1,0,0,1,0,0),N.drawImage(E.canvas,0,0),N.restore())}function k(N,P){const E=n.Util.singularValueDecompose2dScale(N);E[0]=Math.fround(E[0]),E[1]=Math.fround(E[1]);const I=Math.fround((globalThis.devicePixelRatio||1)*a.PixelsPerInch.PDF_TO_CSS_UNITS);return P!==void 0?P:E[0]<=I||E[1]<=I}const O=["butt","round","square"],$=["miter","round","bevel"],K={},J={},Q=class Q{constructor(P,E,I,z,G,{optionalContentConfig:H,markedContentStack:ee=null},ce,ve){de(this,se);this.ctx=P,this.current=new w(this.ctx.canvas.width,this.ctx.canvas.height),this.stateStack=[],this.pendingClip=null,this.pendingEOFill=!1,this.res=null,this.xobjs=null,this.commonObjs=E,this.objs=I,this.canvasFactory=z,this.filterFactory=G,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=ee||[],this.optionalContentConfig=H,this.cachedCanvases=new y(this.canvasFactory),this.cachedPatterns=new Map,this.annotationCanvasMap=ce,this.viewportScale=1,this.outputScaleX=1,this.outputScaleY=1,this.pageColors=ve,this._cachedScaleForStroking=[-1,0],this._cachedGetSinglePixelWidth=null,this._cachedBitmapsMap=new Map}getObject(P,E=null){return typeof P=="string"?P.startsWith("g_")?this.commonObjs.get(P):this.objs.get(P):E}beginDrawing({transform:P,viewport:E,transparency:I=!1,background:z=null}){const G=this.ctx.canvas.width,H=this.ctx.canvas.height,ee=this.ctx.fillStyle;if(this.ctx.fillStyle=z||"#ffffff",this.ctx.fillRect(0,0,G,H),this.ctx.fillStyle=ee,I){const ce=this.cachedCanvases.getCanvas("transparent",G,H);this.compositeCtx=this.ctx,this.transparentCanvas=ce.canvas,this.ctx=ce.context,this.ctx.save(),this.ctx.transform(...(0,a.getCurrentTransform)(this.compositeCtx))}this.ctx.save(),F(this.ctx),P&&(this.ctx.transform(...P),this.outputScaleX=P[0],this.outputScaleY=P[0]),this.ctx.transform(...E.transform),this.viewportScale=E.scale,this.baseTransform=(0,a.getCurrentTransform)(this.ctx)}executeOperatorList(P,E,I,z){const G=P.argsArray,H=P.fnArray;let ee=E||0;const ce=G.length;if(ce===ee)return ee;const ve=ce-ee>p&&typeof I=="function",me=ve?Date.now()+u:0;let xe=0;const Se=this.commonObjs,Ce=this.objs;let ne;for(;;){if(z!==void 0&&ee===z.nextBreakPoint)return z.breakIt(ee,I),ee;if(ne=H[ee],ne!==n.OPS.dependency)this[ne].apply(this,G[ee]);else for(const le of G[ee]){const L=le.startsWith("g_")?Se:Ce;if(!L.has(le))return L.get(le,I),ee}if(ee++,ee===ce)return ee;if(ve&&++xe>p){if(Date.now()>me)return I(),ee;xe=0}}}endDrawing(){te(this,se,Yt).call(this),this.cachedCanvases.clear(),this.cachedPatterns.clear();for(const P of this._cachedBitmapsMap.values()){for(const E of P.values())typeof HTMLCanvasElement<"u"&&E instanceof HTMLCanvasElement&&(E.width=E.height=0);P.clear()}this._cachedBitmapsMap.clear(),te(this,se,Jt).call(this)}_scaleImage(P,E){const I=P.width,z=P.height;let G=Math.max(Math.hypot(E[0],E[1]),1),H=Math.max(Math.hypot(E[2],E[3]),1),ee=I,ce=z,ve="prescale1",me,xe;for(;G>2&&ee>1||H>2&&ce>1;){let Se=ee,Ce=ce;G>2&&ee>1&&(Se=ee>=16384?Math.floor(ee/2)-1||1:Math.ceil(ee/2),G/=ee/Se),H>2&&ce>1&&(Ce=ce>=16384?Math.floor(ce/2)-1||1:Math.ceil(ce)/2,H/=ce/Ce),me=this.cachedCanvases.getCanvas(ve,Se,Ce),xe=me.context,xe.clearRect(0,0,Se,Ce),xe.drawImage(P,0,0,ee,ce,0,0,Se,Ce),P=me.canvas,ee=Se,ce=Ce,ve=ve==="prescale1"?"prescale2":"prescale1"}return{img:P,paintWidth:ee,paintHeight:ce}}_createMaskCanvas(P){const E=this.ctx,{width:I,height:z}=P,G=this.current.fillColor,H=this.current.patternFill,ee=(0,a.getCurrentTransform)(E);let ce,ve,me,xe;if((P.bitmap||P.data)&&P.count>1){const ie=P.bitmap||P.data.buffer;ve=JSON.stringify(H?ee:[ee.slice(0,4),G]),ce=this._cachedBitmapsMap.get(ie),ce||(ce=new Map,this._cachedBitmapsMap.set(ie,ce));const _e=ce.get(ve);if(_e&&!H){const Te=Math.round(Math.min(ee[0],ee[2])+ee[4]),Ke=Math.round(Math.min(ee[1],ee[3])+ee[5]);return{canvas:_e,offsetX:Te,offsetY:Ke}}me=_e}me||(xe=this.cachedCanvases.getCanvas("maskCanvas",I,z),_(xe.context,P));let Se=n.Util.transform(ee,[1/I,0,0,-1/z,0,0]);Se=n.Util.transform(Se,[1,0,0,1,0,-z]);const Ce=n.Util.applyTransform([0,0],Se),ne=n.Util.applyTransform([I,z],Se),le=n.Util.normalizeRect([Ce[0],Ce[1],ne[0],ne[1]]),L=Math.round(le[2]-le[0])||1,Z=Math.round(le[3]-le[1])||1,re=this.cachedCanvases.getCanvas("fillCanvas",L,Z),he=re.context,ye=Math.min(Ce[0],ne[0]),Fe=Math.min(Ce[1],ne[1]);he.translate(-ye,-Fe),he.transform(...Se),me||(me=this._scaleImage(xe.canvas,(0,a.getCurrentTransformInverse)(he)),me=me.img,ce&&H&&ce.set(ve,me)),he.imageSmoothingEnabled=k((0,a.getCurrentTransform)(he),P.interpolate),S(he,me,0,0,me.width,me.height,0,0,I,z),he.globalCompositeOperation="source-in";const Pe=n.Util.transform((0,a.getCurrentTransformInverse)(he),[1,0,0,1,-ye,-Fe]);return he.fillStyle=H?G.getPattern(E,this,Pe,s.PathType.FILL):G,he.fillRect(0,0,I,z),ce&&!H&&(this.cachedCanvases.delete("fillCanvas"),ce.set(ve,re.canvas)),{canvas:re.canvas,offsetX:Math.round(ye),offsetY:Math.round(Fe)}}setLineWidth(P){P!==this.current.lineWidth&&(this._cachedScaleForStroking[0]=-1),this.current.lineWidth=P,this.ctx.lineWidth=P}setLineCap(P){this.ctx.lineCap=O[P]}setLineJoin(P){this.ctx.lineJoin=$[P]}setMiterLimit(P){this.ctx.miterLimit=P}setDash(P,E){const I=this.ctx;I.setLineDash!==void 0&&(I.setLineDash(P),I.lineDashOffset=E)}setRenderingIntent(P){}setFlatness(P){}setGState(P){for(const[E,I]of P)switch(E){case"LW":this.setLineWidth(I);break;case"LC":this.setLineCap(I);break;case"LJ":this.setLineJoin(I);break;case"ML":this.setMiterLimit(I);break;case"D":this.setDash(I[0],I[1]);break;case"RI":this.setRenderingIntent(I);break;case"FL":this.setFlatness(I);break;case"Font":this.setFont(I[0],I[1]);break;case"CA":this.current.strokeAlpha=I;break;case"ca":this.current.fillAlpha=I,this.ctx.globalAlpha=I;break;case"BM":this.ctx.globalCompositeOperation=I;break;case"SMask":this.current.activeSMask=I?this.tempSMask:null,this.tempSMask=null,this.checkSMaskState();break;case"TR":this.ctx.filter=this.current.transferMaps=this.filterFactory.addFilter(I);break}}get inSMaskMode(){return!!this.suspendedCtx}checkSMaskState(){const P=this.inSMaskMode;this.current.activeSMask&&!P?this.beginSMaskMode():!this.current.activeSMask&&P&&this.endSMaskMode()}beginSMaskMode(){if(this.inSMaskMode)throw new Error("beginSMaskMode called while already in smask mode");const P=this.ctx.canvas.width,E=this.ctx.canvas.height,I="smaskGroupAt"+this.groupLevel,z=this.cachedCanvases.getCanvas(I,P,E);this.suspendedCtx=this.ctx,this.ctx=z.context;const G=this.ctx;G.setTransform(...(0,a.getCurrentTransform)(this.suspendedCtx)),x(this.suspendedCtx,G),v(G,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(),x(this.ctx,this.suspendedCtx),this.ctx=this.suspendedCtx,this.suspendedCtx=null}compose(P){if(!this.current.activeSMask)return;P?(P[0]=Math.floor(P[0]),P[1]=Math.floor(P[1]),P[2]=Math.ceil(P[2]),P[3]=Math.ceil(P[3])):P=[0,0,this.ctx.canvas.width,this.ctx.canvas.height];const E=this.current.activeSMask,I=this.suspendedCtx;C(I,E,this.ctx,P),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?(x(this.ctx,this.suspendedCtx),this.suspendedCtx.save()):this.ctx.save();const P=this.current;this.stateStack.push(P),this.current=P.clone()}restore(){this.stateStack.length===0&&this.inSMaskMode&&this.endSMaskMode(),this.stateStack.length!==0&&(this.current=this.stateStack.pop(),this.inSMaskMode?(this.suspendedCtx.restore(),x(this.suspendedCtx,this.ctx)):this.ctx.restore(),this.checkSMaskState(),this.pendingClip=null,this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null)}transform(P,E,I,z,G,H){this.ctx.transform(P,E,I,z,G,H),this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null}constructPath(P,E,I){const z=this.ctx,G=this.current;let H=G.x,ee=G.y,ce,ve;const me=(0,a.getCurrentTransform)(z),xe=me[0]===0&&me[3]===0||me[1]===0&&me[2]===0,Se=xe?I.slice(0):null;for(let Ce=0,ne=0,le=P.length;Ce<le;Ce++)switch(P[Ce]|0){case n.OPS.rectangle:H=E[ne++],ee=E[ne++];const L=E[ne++],Z=E[ne++],re=H+L,he=ee+Z;z.moveTo(H,ee),L===0||Z===0?z.lineTo(re,he):(z.lineTo(re,ee),z.lineTo(re,he),z.lineTo(H,he)),xe||G.updateRectMinMax(me,[H,ee,re,he]),z.closePath();break;case n.OPS.moveTo:H=E[ne++],ee=E[ne++],z.moveTo(H,ee),xe||G.updatePathMinMax(me,H,ee);break;case n.OPS.lineTo:H=E[ne++],ee=E[ne++],z.lineTo(H,ee),xe||G.updatePathMinMax(me,H,ee);break;case n.OPS.curveTo:ce=H,ve=ee,H=E[ne+4],ee=E[ne+5],z.bezierCurveTo(E[ne],E[ne+1],E[ne+2],E[ne+3],H,ee),G.updateCurvePathMinMax(me,ce,ve,E[ne],E[ne+1],E[ne+2],E[ne+3],H,ee,Se),ne+=6;break;case n.OPS.curveTo2:ce=H,ve=ee,z.bezierCurveTo(H,ee,E[ne],E[ne+1],E[ne+2],E[ne+3]),G.updateCurvePathMinMax(me,ce,ve,H,ee,E[ne],E[ne+1],E[ne+2],E[ne+3],Se),H=E[ne+2],ee=E[ne+3],ne+=4;break;case n.OPS.curveTo3:ce=H,ve=ee,H=E[ne+2],ee=E[ne+3],z.bezierCurveTo(E[ne],E[ne+1],H,ee,H,ee),G.updateCurvePathMinMax(me,ce,ve,E[ne],E[ne+1],H,ee,H,ee,Se),ne+=4;break;case n.OPS.closePath:z.closePath();break}xe&&G.updateScalingPathMinMax(me,Se),G.setCurrentPoint(H,ee)}closePath(){this.ctx.closePath()}stroke(P=!0){const E=this.ctx,I=this.current.strokeColor;E.globalAlpha=this.current.strokeAlpha,this.contentVisible&&(typeof I=="object"&&(I!=null&&I.getPattern)?(E.save(),E.strokeStyle=I.getPattern(E,this,(0,a.getCurrentTransformInverse)(E),s.PathType.STROKE),this.rescaleAndStroke(!1),E.restore()):this.rescaleAndStroke(!0)),P&&this.consumePath(this.current.getClippedPathBoundingBox()),E.globalAlpha=this.current.fillAlpha}closeStroke(){this.closePath(),this.stroke()}fill(P=!0){const E=this.ctx,I=this.current.fillColor,z=this.current.patternFill;let G=!1;z&&(E.save(),E.fillStyle=I.getPattern(E,this,(0,a.getCurrentTransformInverse)(E),s.PathType.FILL),G=!0);const H=this.current.getClippedPathBoundingBox();this.contentVisible&&H!==null&&(this.pendingEOFill?(E.fill("evenodd"),this.pendingEOFill=!1):E.fill()),G&&E.restore(),P&&this.consumePath(H)}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=J}beginText(){this.current.textMatrix=n.IDENTITY_MATRIX,this.current.textMatrixScale=1,this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0}endText(){const P=this.pendingTextPaths,E=this.ctx;if(P===void 0){E.beginPath();return}E.save(),E.beginPath();for(const I of P)E.setTransform(...I.transform),E.translate(I.x,I.y),I.addToPath(E,I.fontSize);E.restore(),E.clip(),E.beginPath(),delete this.pendingTextPaths}setCharSpacing(P){this.current.charSpacing=P}setWordSpacing(P){this.current.wordSpacing=P}setHScale(P){this.current.textHScale=P/100}setLeading(P){this.current.leading=-P}setFont(P,E){var me;const I=this.commonObjs.get(P),z=this.current;if(!I)throw new Error(`Can't find font for ${P}`);if(z.fontMatrix=I.fontMatrix||n.FONT_IDENTITY_MATRIX,(z.fontMatrix[0]===0||z.fontMatrix[3]===0)&&(0,n.warn)("Invalid font matrix for font "+P),E<0?(E=-E,z.fontDirection=-1):z.fontDirection=1,this.current.font=I,this.current.fontSize=E,I.isType3Font)return;const G=I.loadedName||"sans-serif",H=((me=I.systemFontInfo)==null?void 0:me.css)||`"${G}", ${I.fallbackName}`;let ee="normal";I.black?ee="900":I.bold&&(ee="bold");const ce=I.italic?"italic":"normal";let ve=E;E<h?ve=h:E>d&&(ve=d),this.current.fontSizeScale=E/ve,this.ctx.font=`${ce} ${ee} ${ve}px ${H}`}setTextRenderingMode(P){this.current.textRenderingMode=P}setTextRise(P){this.current.textRise=P}moveText(P,E){this.current.x=this.current.lineX+=P,this.current.y=this.current.lineY+=E}setLeadingMoveText(P,E){this.setLeading(-E),this.moveText(P,E)}setTextMatrix(P,E,I,z,G,H){this.current.textMatrix=[P,E,I,z,G,H],this.current.textMatrixScale=Math.hypot(P,E),this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0}nextLine(){this.moveText(0,this.current.leading)}paintChar(P,E,I,z){const G=this.ctx,H=this.current,ee=H.font,ce=H.textRenderingMode,ve=H.fontSize/H.fontSizeScale,me=ce&n.TextRenderingMode.FILL_STROKE_MASK,xe=!!(ce&n.TextRenderingMode.ADD_TO_PATH_FLAG),Se=H.patternFill&&!ee.missingFile;let Ce;(ee.disableFontFace||xe||Se)&&(Ce=ee.getPathGenerator(this.commonObjs,P)),ee.disableFontFace||Se?(G.save(),G.translate(E,I),G.beginPath(),Ce(G,ve),z&&G.setTransform(...z),(me===n.TextRenderingMode.FILL||me===n.TextRenderingMode.FILL_STROKE)&&G.fill(),(me===n.TextRenderingMode.STROKE||me===n.TextRenderingMode.FILL_STROKE)&&G.stroke(),G.restore()):((me===n.TextRenderingMode.FILL||me===n.TextRenderingMode.FILL_STROKE)&&G.fillText(P,E,I),(me===n.TextRenderingMode.STROKE||me===n.TextRenderingMode.FILL_STROKE)&&G.strokeText(P,E,I)),xe&&(this.pendingTextPaths||(this.pendingTextPaths=[])).push({transform:(0,a.getCurrentTransform)(G),x:E,y:I,fontSize:ve,addToPath:Ce})}get isFontSubpixelAAEnabled(){const{context:P}=this.cachedCanvases.getCanvas("isFontSubpixelAAEnabled",10,10);P.scale(1.5,1),P.fillText("I",0,10);const E=P.getImageData(0,0,10,10).data;let I=!1;for(let z=3;z<E.length;z+=4)if(E[z]>0&&E[z]<255){I=!0;break}return(0,n.shadow)(this,"isFontSubpixelAAEnabled",I)}showText(P){const E=this.current,I=E.font;if(I.isType3Font)return this.showType3Text(P);const z=E.fontSize;if(z===0)return;const G=this.ctx,H=E.fontSizeScale,ee=E.charSpacing,ce=E.wordSpacing,ve=E.fontDirection,me=E.textHScale*ve,xe=P.length,Se=I.vertical,Ce=Se?1:-1,ne=I.defaultVMetrics,le=z*E.fontMatrix[0],L=E.textRenderingMode===n.TextRenderingMode.FILL&&!I.disableFontFace&&!E.patternFill;G.save(),G.transform(...E.textMatrix),G.translate(E.x,E.y+E.textRise),ve>0?G.scale(me,-1):G.scale(me,1);let Z;if(E.patternFill){G.save();const Pe=E.fillColor.getPattern(G,this,(0,a.getCurrentTransformInverse)(G),s.PathType.FILL);Z=(0,a.getCurrentTransform)(G),G.restore(),G.fillStyle=Pe}let re=E.lineWidth;const he=E.textMatrixScale;if(he===0||re===0){const Pe=E.textRenderingMode&n.TextRenderingMode.FILL_STROKE_MASK;(Pe===n.TextRenderingMode.STROKE||Pe===n.TextRenderingMode.FILL_STROKE)&&(re=this.getSinglePixelWidth())}else re/=he;if(H!==1&&(G.scale(H,H),re/=H),G.lineWidth=re,I.isInvalidPDFjsFont){const Pe=[];let ie=0;for(const _e of P)Pe.push(_e.unicode),ie+=_e.width;G.fillText(Pe.join(""),0,0),E.x+=ie*le*me,G.restore(),this.compose();return}let ye=0,Fe;for(Fe=0;Fe<xe;++Fe){const Pe=P[Fe];if(typeof Pe=="number"){ye+=Ce*Pe*z/1e3;continue}let ie=!1;const _e=(Pe.isSpace?ce:0)+ee,Te=Pe.fontChar,Ke=Pe.accent;let qe,Ye,Me=Pe.width;if(Se){const Ie=Pe.vmetric||ne,ze=-(Pe.vmetric?Ie[1]:Me*.5)*le,be=Ie[2]*le;Me=Ie?-Ie[0]:Me,qe=ze/H,Ye=(ye+be)/H}else qe=ye/H,Ye=0;if(I.remeasure&&Me>0){const Ie=G.measureText(Te).width*1e3/z*H;if(Me<Ie&&this.isFontSubpixelAAEnabled){const ze=Me/Ie;ie=!0,G.save(),G.scale(ze,1),qe/=ze}else Me!==Ie&&(qe+=(Me-Ie)/2e3*z/H)}if(this.contentVisible&&(Pe.isInFont||I.missingFile)){if(L&&!Ke)G.fillText(Te,qe,Ye);else if(this.paintChar(Te,qe,Ye,Z),Ke){const Ie=qe+z*Ke.offset.x/H,ze=Ye-z*Ke.offset.y/H;this.paintChar(Ke.fontChar,Ie,ze,Z)}}const Ee=Se?Me*le-_e*ve:Me*le+_e*ve;ye+=Ee,ie&&G.restore()}Se?E.y-=ye:E.x+=ye*me,G.restore(),this.compose()}showType3Text(P){const E=this.ctx,I=this.current,z=I.font,G=I.fontSize,H=I.fontDirection,ee=z.vertical?1:-1,ce=I.charSpacing,ve=I.wordSpacing,me=I.textHScale*H,xe=I.fontMatrix||n.FONT_IDENTITY_MATRIX,Se=P.length,Ce=I.textRenderingMode===n.TextRenderingMode.INVISIBLE;let ne,le,L,Z;if(!(Ce||G===0)){for(this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null,E.save(),E.transform(...I.textMatrix),E.translate(I.x,I.y),E.scale(me,H),ne=0;ne<Se;++ne){if(le=P[ne],typeof le=="number"){Z=ee*le*G/1e3,this.ctx.translate(Z,0),I.x+=Z*me;continue}const re=(le.isSpace?ve:0)+ce,he=z.charProcOperatorList[le.operatorListId];if(!he){(0,n.warn)(`Type3 character "${le.operatorListId}" is not available.`);continue}this.contentVisible&&(this.processingType3=le,this.save(),E.scale(G,G),E.transform(...xe),this.executeOperatorList(he),this.restore()),L=n.Util.applyTransform([le.width,0],xe)[0]*G+re,E.translate(L,0),I.x+=L*me}E.restore(),this.processingType3=null}}setCharWidth(P,E){}setCharWidthAndBounds(P,E,I,z,G,H){this.ctx.rect(I,z,G-I,H-z),this.ctx.clip(),this.endPath()}getColorN_Pattern(P){let E;if(P[0]==="TilingPattern"){const I=P[1],z=this.baseTransform||(0,a.getCurrentTransform)(this.ctx),G={createCanvasGraphics:H=>new Q(H,this.commonObjs,this.objs,this.canvasFactory,this.filterFactory,{optionalContentConfig:this.optionalContentConfig,markedContentStack:this.markedContentStack})};E=new s.TilingPattern(P,I,this.ctx,G,z)}else E=this._getPattern(P[1],P[2]);return E}setStrokeColorN(){this.current.strokeColor=this.getColorN_Pattern(arguments)}setFillColorN(){this.current.fillColor=this.getColorN_Pattern(arguments),this.current.patternFill=!0}setStrokeRGBColor(P,E,I){const z=n.Util.makeHexColor(P,E,I);this.ctx.strokeStyle=z,this.current.strokeColor=z}setFillRGBColor(P,E,I){const z=n.Util.makeHexColor(P,E,I);this.ctx.fillStyle=z,this.current.fillColor=z,this.current.patternFill=!1}_getPattern(P,E=null){let I;return this.cachedPatterns.has(P)?I=this.cachedPatterns.get(P):(I=(0,s.getShadingPattern)(this.getObject(P)),this.cachedPatterns.set(P,I)),E&&(I.matrix=E),I}shadingFill(P){if(!this.contentVisible)return;const E=this.ctx;this.save();const I=this._getPattern(P);E.fillStyle=I.getPattern(E,this,(0,a.getCurrentTransformInverse)(E),s.PathType.SHADING);const z=(0,a.getCurrentTransformInverse)(E);if(z){const{width:G,height:H}=E.canvas,[ee,ce,ve,me]=n.Util.getAxialAlignedBoundingBox([0,0,G,H],z);this.ctx.fillRect(ee,ce,ve-ee,me-ce)}else this.ctx.fillRect(-1e10,-1e10,2e10,2e10);this.compose(this.current.getClippedPathBoundingBox()),this.restore()}beginInlineImage(){(0,n.unreachable)("Should not call beginInlineImage")}beginImageData(){(0,n.unreachable)("Should not call beginImageData")}paintFormXObjectBegin(P,E){if(this.contentVisible&&(this.save(),this.baseTransformStack.push(this.baseTransform),Array.isArray(P)&&P.length===6&&this.transform(...P),this.baseTransform=(0,a.getCurrentTransform)(this.ctx),E)){const I=E[2]-E[0],z=E[3]-E[1];this.ctx.rect(E[0],E[1],I,z),this.current.updateRectMinMax((0,a.getCurrentTransform)(this.ctx),E),this.clip(),this.endPath()}}paintFormXObjectEnd(){this.contentVisible&&(this.restore(),this.baseTransform=this.baseTransformStack.pop())}beginGroup(P){if(!this.contentVisible)return;this.save(),this.inSMaskMode&&(this.endSMaskMode(),this.current.activeSMask=null);const E=this.ctx;P.isolated||(0,n.info)("TODO: Support non-isolated groups."),P.knockout&&(0,n.warn)("Knockout groups not supported.");const I=(0,a.getCurrentTransform)(E);if(P.matrix&&E.transform(...P.matrix),!P.bbox)throw new Error("Bounding box is required.");let z=n.Util.getAxialAlignedBoundingBox(P.bbox,(0,a.getCurrentTransform)(E));const G=[0,0,E.canvas.width,E.canvas.height];z=n.Util.intersect(z,G)||[0,0,0,0];const H=Math.floor(z[0]),ee=Math.floor(z[1]);let ce=Math.max(Math.ceil(z[2])-H,1),ve=Math.max(Math.ceil(z[3])-ee,1),me=1,xe=1;ce>l&&(me=ce/l,ce=l),ve>l&&(xe=ve/l,ve=l),this.current.startNewPathAndClipBox([0,0,ce,ve]);let Se="groupAt"+this.groupLevel;P.smask&&(Se+="_smask_"+this.smaskCounter++%2);const Ce=this.cachedCanvases.getCanvas(Se,ce,ve),ne=Ce.context;ne.scale(1/me,1/xe),ne.translate(-H,-ee),ne.transform(...I),P.smask?this.smaskStack.push({canvas:Ce.canvas,context:ne,offsetX:H,offsetY:ee,scaleX:me,scaleY:xe,subtype:P.smask.subtype,backdrop:P.smask.backdrop,transferMap:P.smask.transferMap||null,startTransformInverse:null}):(E.setTransform(1,0,0,1,0,0),E.translate(H,ee),E.scale(me,xe),E.save()),x(E,ne),this.ctx=ne,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(E),this.groupLevel++}endGroup(P){if(!this.contentVisible)return;this.groupLevel--;const E=this.ctx,I=this.groupStack.pop();if(this.ctx=I,this.ctx.imageSmoothingEnabled=!1,P.smask)this.tempSMask=this.smaskStack.pop(),this.restore();else{this.ctx.restore();const z=(0,a.getCurrentTransform)(this.ctx);this.restore(),this.ctx.save(),this.ctx.setTransform(...z);const G=n.Util.getAxialAlignedBoundingBox([0,0,E.canvas.width,E.canvas.height],z);this.ctx.drawImage(E.canvas,0,0),this.ctx.restore(),this.compose(G)}}beginAnnotation(P,E,I,z,G){if(te(this,se,Yt).call(this),F(this.ctx),this.ctx.save(),this.save(),this.baseTransform&&this.ctx.setTransform(...this.baseTransform),Array.isArray(E)&&E.length===4){const H=E[2]-E[0],ee=E[3]-E[1];if(G&&this.annotationCanvasMap){I=I.slice(),I[4]-=E[0],I[5]-=E[1],E=E.slice(),E[0]=E[1]=0,E[2]=H,E[3]=ee;const[ce,ve]=n.Util.singularValueDecompose2dScale((0,a.getCurrentTransform)(this.ctx)),{viewportScale:me}=this,xe=Math.ceil(H*this.outputScaleX*me),Se=Math.ceil(ee*this.outputScaleY*me);this.annotationCanvas=this.canvasFactory.create(xe,Se);const{canvas:Ce,context:ne}=this.annotationCanvas;this.annotationCanvasMap.set(P,Ce),this.annotationCanvas.savedCtx=this.ctx,this.ctx=ne,this.ctx.save(),this.ctx.setTransform(ce,0,0,-ve,0,ee*ve),F(this.ctx)}else F(this.ctx),this.ctx.rect(E[0],E[1],H,ee),this.ctx.clip(),this.endPath()}this.current=new w(this.ctx.canvas.width,this.ctx.canvas.height),this.transform(...I),this.transform(...z)}endAnnotation(){this.annotationCanvas&&(this.ctx.restore(),te(this,se,Jt).call(this),this.ctx=this.annotationCanvas.savedCtx,delete this.annotationCanvas.savedCtx,delete this.annotationCanvas)}paintImageMaskXObject(P){if(!this.contentVisible)return;const E=P.count;P=this.getObject(P.data,P),P.count=E;const I=this.ctx,z=this.processingType3;if(z&&(z.compiled===void 0&&(z.compiled=m(P)),z.compiled)){z.compiled(I);return}const G=this._createMaskCanvas(P),H=G.canvas;I.save(),I.setTransform(1,0,0,1,0,0),I.drawImage(H,G.offsetX,G.offsetY),I.restore(),this.compose()}paintImageMaskXObjectRepeat(P,E,I=0,z=0,G,H){if(!this.contentVisible)return;P=this.getObject(P.data,P);const ee=this.ctx;ee.save();const ce=(0,a.getCurrentTransform)(ee);ee.transform(E,I,z,G,0,0);const ve=this._createMaskCanvas(P);ee.setTransform(1,0,0,1,ve.offsetX-ce[4],ve.offsetY-ce[5]);for(let me=0,xe=H.length;me<xe;me+=2){const Se=n.Util.transform(ce,[E,I,z,G,H[me],H[me+1]]),[Ce,ne]=n.Util.applyTransform([0,0],Se);ee.drawImage(ve.canvas,Ce,ne)}ee.restore(),this.compose()}paintImageMaskXObjectGroup(P){if(!this.contentVisible)return;const E=this.ctx,I=this.current.fillColor,z=this.current.patternFill;for(const G of P){const{data:H,width:ee,height:ce,transform:ve}=G,me=this.cachedCanvases.getCanvas("maskCanvas",ee,ce),xe=me.context;xe.save();const Se=this.getObject(H,G);_(xe,Se),xe.globalCompositeOperation="source-in",xe.fillStyle=z?I.getPattern(xe,this,(0,a.getCurrentTransformInverse)(E),s.PathType.FILL):I,xe.fillRect(0,0,ee,ce),xe.restore(),E.save(),E.transform(...ve),E.scale(1,-1),S(E,me.canvas,0,0,ee,ce,0,-1,1,1),E.restore()}this.compose()}paintImageXObject(P){if(!this.contentVisible)return;const E=this.getObject(P);if(!E){(0,n.warn)("Dependent image isn't ready yet");return}this.paintInlineImageXObject(E)}paintImageXObjectRepeat(P,E,I,z){if(!this.contentVisible)return;const G=this.getObject(P);if(!G){(0,n.warn)("Dependent image isn't ready yet");return}const H=G.width,ee=G.height,ce=[];for(let ve=0,me=z.length;ve<me;ve+=2)ce.push({transform:[E,0,0,I,z[ve],z[ve+1]],x:0,y:0,w:H,h:ee});this.paintInlineImageXObjectGroup(G,ce)}applyTransferMapsToCanvas(P){return this.current.transferMaps!=="none"&&(P.filter=this.current.transferMaps,P.drawImage(P.canvas,0,0),P.filter="none"),P.canvas}applyTransferMapsToBitmap(P){if(this.current.transferMaps==="none")return P.bitmap;const{bitmap:E,width:I,height:z}=P,G=this.cachedCanvases.getCanvas("inlineImage",I,z),H=G.context;return H.filter=this.current.transferMaps,H.drawImage(E,0,0),H.filter="none",G.canvas}paintInlineImageXObject(P){if(!this.contentVisible)return;const E=P.width,I=P.height,z=this.ctx;if(this.save(),!n.isNodeJS){const{filter:ee}=z;ee!=="none"&&ee!==""&&(z.filter="none")}z.scale(1/E,-1/I);let G;if(P.bitmap)G=this.applyTransferMapsToBitmap(P);else if(typeof HTMLElement=="function"&&P instanceof HTMLElement||!P.data)G=P;else{const ce=this.cachedCanvases.getCanvas("inlineImage",E,I).context;R(ce,P),G=this.applyTransferMapsToCanvas(ce)}const H=this._scaleImage(G,(0,a.getCurrentTransformInverse)(z));z.imageSmoothingEnabled=k((0,a.getCurrentTransform)(z),P.interpolate),S(z,H.img,0,0,H.paintWidth,H.paintHeight,0,-I,E,I),this.compose(),this.restore()}paintInlineImageXObjectGroup(P,E){if(!this.contentVisible)return;const I=this.ctx;let z;if(P.bitmap)z=P.bitmap;else{const G=P.width,H=P.height,ce=this.cachedCanvases.getCanvas("inlineImage",G,H).context;R(ce,P),z=this.applyTransferMapsToCanvas(ce)}for(const G of E)I.save(),I.transform(...G.transform),I.scale(1,-1),S(I,z,G.x,G.y,G.w,G.h,0,-1,1,1),I.restore();this.compose()}paintSolidColorImageMask(){this.contentVisible&&(this.ctx.fillRect(0,0,1,1),this.compose())}markPoint(P){}markPointProps(P,E){}beginMarkedContent(P){this.markedContentStack.push({visible:!0})}beginMarkedContentProps(P,E){P==="OC"?this.markedContentStack.push({visible:this.optionalContentConfig.isVisible(E)}):this.markedContentStack.push({visible:!0}),this.contentVisible=this.isContentVisible()}endMarkedContent(){this.markedContentStack.pop(),this.contentVisible=this.isContentVisible()}beginCompat(){}endCompat(){}consumePath(P){const E=this.current.isEmptyClip();this.pendingClip&&this.current.updateClipFromPath(),this.pendingClip||this.compose(P);const I=this.ctx;this.pendingClip&&(E||(this.pendingClip===J?I.clip("evenodd"):I.clip()),this.pendingClip=null),this.current.startNewPathAndClipBox(this.current.clipBox),I.beginPath()}getSinglePixelWidth(){if(!this._cachedGetSinglePixelWidth){const P=(0,a.getCurrentTransform)(this.ctx);if(P[1]===0&&P[2]===0)this._cachedGetSinglePixelWidth=1/Math.min(Math.abs(P[0]),Math.abs(P[3]));else{const E=Math.abs(P[0]*P[3]-P[2]*P[1]),I=Math.hypot(P[0],P[2]),z=Math.hypot(P[1],P[3]);this._cachedGetSinglePixelWidth=Math.max(I,z)/E}}return this._cachedGetSinglePixelWidth}getScaleForStroking(){if(this._cachedScaleForStroking[0]===-1){const{lineWidth:P}=this.current,{a:E,b:I,c:z,d:G}=this.ctx.getTransform();let H,ee;if(I===0&&z===0){const ce=Math.abs(E),ve=Math.abs(G);if(ce===ve)if(P===0)H=ee=1/ce;else{const me=ce*P;H=ee=me<1?1/me:1}else if(P===0)H=1/ce,ee=1/ve;else{const me=ce*P,xe=ve*P;H=me<1?1/me:1,ee=xe<1?1/xe:1}}else{const ce=Math.abs(E*G-I*z),ve=Math.hypot(E,I),me=Math.hypot(z,G);if(P===0)H=me/ce,ee=ve/ce;else{const xe=P*ce;H=me>xe?me/xe:1,ee=ve>xe?ve/xe:1}}this._cachedScaleForStroking[0]=H,this._cachedScaleForStroking[1]=ee}return this._cachedScaleForStroking}rescaleAndStroke(P){const{ctx:E}=this,{lineWidth:I}=this.current,[z,G]=this.getScaleForStroking();if(E.lineWidth=I||1,z===1&&G===1){E.stroke();return}const H=E.getLineDash();if(P&&E.save(),E.scale(z,G),H.length>0){const ee=Math.max(z,G);E.setLineDash(H.map(ce=>ce/ee)),E.lineDashOffset/=ee}E.stroke(),P&&E.restore()}isContentVisible(){for(let P=this.markedContentStack.length-1;P>=0;P--)if(!this.markedContentStack[P].visible)return!1;return!0}};se=new WeakSet,Yt=function(){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)},Jt=function(){if(this.pageColors){const P=this.filterFactory.addHCMFilter(this.pageColors.foreground,this.pageColors.background);if(P!=="none"){const E=this.ctx.filter;this.ctx.filter=P,this.ctx.drawImage(this.ctx.canvas,0,0),this.ctx.filter=E}}};let Y=Q;e.CanvasGraphics=Y;for(const N in n.OPS)Y.prototype[N]!==void 0&&(Y.prototype[n.OPS[N]]=Y.prototype[N])},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.TilingPattern=e.PathType=void 0,e.getShadingPattern=f;var n=r(1),a=r(6);const s={FILL:"Fill",STROKE:"Stroke",SHADING:"Shading"};e.PathType=s;function o(m,w){if(!w)return;const R=w[2]-w[0],_=w[3]-w[1],x=new Path2D;x.rect(w[0],w[1],R,_),m.clip(x)}class h{constructor(){this.constructor===h&&(0,n.unreachable)("Cannot initialize BaseShadingPattern.")}getPattern(){(0,n.unreachable)("Abstract method `getPattern` called.")}}class d extends h{constructor(w){super(),this._type=w[1],this._bbox=w[2],this._colorStops=w[3],this._p0=w[4],this._p1=w[5],this._r0=w[6],this._r1=w[7],this.matrix=null}_createGradient(w){let R;this._type==="axial"?R=w.createLinearGradient(this._p0[0],this._p0[1],this._p1[0],this._p1[1]):this._type==="radial"&&(R=w.createRadialGradient(this._p0[0],this._p0[1],this._r0,this._p1[0],this._p1[1],this._r1));for(const _ of this._colorStops)R.addColorStop(_[0],_[1]);return R}getPattern(w,R,_,x){let F;if(x===s.STROKE||x===s.FILL){const A=R.current.getClippedPathBoundingBox(x,(0,a.getCurrentTransform)(w))||[0,0,0,0],D=Math.ceil(A[2]-A[0])||1,T=Math.ceil(A[3]-A[1])||1,M=R.cachedCanvases.getCanvas("pattern",D,T,!0),C=M.context;C.clearRect(0,0,C.canvas.width,C.canvas.height),C.beginPath(),C.rect(0,0,C.canvas.width,C.canvas.height),C.translate(-A[0],-A[1]),_=n.Util.transform(_,[1,0,0,1,A[0],A[1]]),C.transform(...R.baseTransform),this.matrix&&C.transform(...this.matrix),o(C,this._bbox),C.fillStyle=this._createGradient(C),C.fill(),F=w.createPattern(M.canvas,"no-repeat");const k=new DOMMatrix(_);F.setTransform(k)}else o(w,this._bbox),F=this._createGradient(w);return F}}function l(m,w,R,_,x,F,A,D){const T=w.coords,M=w.colors,C=m.data,k=m.width*4;let O;T[R+1]>T[_+1]&&(O=R,R=_,_=O,O=F,F=A,A=O),T[_+1]>T[x+1]&&(O=_,_=x,x=O,O=A,A=D,D=O),T[R+1]>T[_+1]&&(O=R,R=_,_=O,O=F,F=A,A=O);const $=(T[R]+w.offsetX)*w.scaleX,K=(T[R+1]+w.offsetY)*w.scaleY,J=(T[_]+w.offsetX)*w.scaleX,Y=(T[_+1]+w.offsetY)*w.scaleY,se=(T[x]+w.offsetX)*w.scaleX,B=(T[x+1]+w.offsetY)*w.scaleY;if(K>=B)return;const V=M[F],Q=M[F+1],N=M[F+2],P=M[A],E=M[A+1],I=M[A+2],z=M[D],G=M[D+1],H=M[D+2],ee=Math.round(K),ce=Math.round(B);let ve,me,xe,Se,Ce,ne,le,L;for(let Z=ee;Z<=ce;Z++){if(Z<Y){const Pe=Z<K?0:(K-Z)/(K-Y);ve=$-($-J)*Pe,me=V-(V-P)*Pe,xe=Q-(Q-E)*Pe,Se=N-(N-I)*Pe}else{let Pe;Z>B?Pe=1:Y===B?Pe=0:Pe=(Y-Z)/(Y-B),ve=J-(J-se)*Pe,me=P-(P-z)*Pe,xe=E-(E-G)*Pe,Se=I-(I-H)*Pe}let re;Z<K?re=0:Z>B?re=1:re=(K-Z)/(K-B),Ce=$-($-se)*re,ne=V-(V-z)*re,le=Q-(Q-G)*re,L=N-(N-H)*re;const he=Math.round(Math.min(ve,Ce)),ye=Math.round(Math.max(ve,Ce));let Fe=k*Z+he*4;for(let Pe=he;Pe<=ye;Pe++)re=(ve-Pe)/(ve-Ce),re<0?re=0:re>1&&(re=1),C[Fe++]=me-(me-ne)*re|0,C[Fe++]=xe-(xe-le)*re|0,C[Fe++]=Se-(Se-L)*re|0,C[Fe++]=255}}function u(m,w,R){const _=w.coords,x=w.colors;let F,A;switch(w.type){case"lattice":const D=w.verticesPerRow,T=Math.floor(_.length/D)-1,M=D-1;for(F=0;F<T;F++){let C=F*D;for(let k=0;k<M;k++,C++)l(m,R,_[C],_[C+1],_[C+D],x[C],x[C+1],x[C+D]),l(m,R,_[C+D+1],_[C+1],_[C+D],x[C+D+1],x[C+1],x[C+D])}break;case"triangles":for(F=0,A=_.length;F<A;F+=3)l(m,R,_[F],_[F+1],_[F+2],x[F],x[F+1],x[F+2]);break;default:throw new Error("illegal figure")}}class p extends h{constructor(w){super(),this._coords=w[2],this._colors=w[3],this._figures=w[4],this._bounds=w[5],this._bbox=w[7],this._background=w[8],this.matrix=null}_createMeshCanvas(w,R,_){const D=Math.floor(this._bounds[0]),T=Math.floor(this._bounds[1]),M=Math.ceil(this._bounds[2])-D,C=Math.ceil(this._bounds[3])-T,k=Math.min(Math.ceil(Math.abs(M*w[0]*1.1)),3e3),O=Math.min(Math.ceil(Math.abs(C*w[1]*1.1)),3e3),$=M/k,K=C/O,J={coords:this._coords,colors:this._colors,offsetX:-D,offsetY:-T,scaleX:1/$,scaleY:1/K},Y=k+2*2,se=O+2*2,B=_.getCanvas("mesh",Y,se,!1),V=B.context,Q=V.createImageData(k,O);if(R){const P=Q.data;for(let E=0,I=P.length;E<I;E+=4)P[E]=R[0],P[E+1]=R[1],P[E+2]=R[2],P[E+3]=255}for(const P of this._figures)u(Q,P,J);return V.putImageData(Q,2,2),{canvas:B.canvas,offsetX:D-2*$,offsetY:T-2*K,scaleX:$,scaleY:K}}getPattern(w,R,_,x){o(w,this._bbox);let F;if(x===s.SHADING)F=n.Util.singularValueDecompose2dScale((0,a.getCurrentTransform)(w));else if(F=n.Util.singularValueDecompose2dScale(R.baseTransform),this.matrix){const D=n.Util.singularValueDecompose2dScale(this.matrix);F=[F[0]*D[0],F[1]*D[1]]}const A=this._createMeshCanvas(F,x===s.SHADING?null:this._background,R.cachedCanvases);return x!==s.SHADING&&(w.setTransform(...R.baseTransform),this.matrix&&w.transform(...this.matrix)),w.translate(A.offsetX,A.offsetY),w.scale(A.scaleX,A.scaleY),w.createPattern(A.canvas,"no-repeat")}}class g extends h{getPattern(){return"hotpink"}}function f(m){switch(m[0]){case"RadialAxial":return new d(m);case"Mesh":return new p(m);case"Dummy":return new g}throw new Error(`Unknown IR type: ${m[0]}`)}const v={COLORED:1,UNCOLORED:2},S=class S{constructor(w,R,_,x,F){this.operatorList=w[2],this.matrix=w[3]||[1,0,0,1,0,0],this.bbox=w[4],this.xstep=w[5],this.ystep=w[6],this.paintType=w[7],this.tilingType=w[8],this.color=R,this.ctx=_,this.canvasGraphicsFactory=x,this.baseTransform=F}createPatternCanvas(w){const R=this.operatorList,_=this.bbox,x=this.xstep,F=this.ystep,A=this.paintType,D=this.tilingType,T=this.color,M=this.canvasGraphicsFactory;(0,n.info)("TilingType: "+D);const C=_[0],k=_[1],O=_[2],$=_[3],K=n.Util.singularValueDecompose2dScale(this.matrix),J=n.Util.singularValueDecompose2dScale(this.baseTransform),Y=[K[0]*J[0],K[1]*J[1]],se=this.getSizeAndScale(x,this.ctx.canvas.width,Y[0]),B=this.getSizeAndScale(F,this.ctx.canvas.height,Y[1]),V=w.cachedCanvases.getCanvas("pattern",se.size,B.size,!0),Q=V.context,N=M.createCanvasGraphics(Q);N.groupLevel=w.groupLevel,this.setFillAndStrokeStyleToContext(N,A,T);let P=C,E=k,I=O,z=$;return C<0&&(P=0,I+=Math.abs(C)),k<0&&(E=0,z+=Math.abs(k)),Q.translate(-(se.scale*P),-(B.scale*E)),N.transform(se.scale,0,0,B.scale,0,0),Q.save(),this.clipBbox(N,P,E,I,z),N.baseTransform=(0,a.getCurrentTransform)(N.ctx),N.executeOperatorList(R),N.endDrawing(),{canvas:V.canvas,scaleX:se.scale,scaleY:B.scale,offsetX:P,offsetY:E}}getSizeAndScale(w,R,_){w=Math.abs(w);const x=Math.max(S.MAX_PATTERN_SIZE,R);let F=Math.ceil(w*_);return F>=x?F=x:_=F/w,{scale:_,size:F}}clipBbox(w,R,_,x,F){const A=x-R,D=F-_;w.ctx.rect(R,_,A,D),w.current.updateRectMinMax((0,a.getCurrentTransform)(w.ctx),[R,_,x,F]),w.clip(),w.endPath()}setFillAndStrokeStyleToContext(w,R,_){const x=w.ctx,F=w.current;switch(R){case v.COLORED:const A=this.ctx;x.fillStyle=A.fillStyle,x.strokeStyle=A.strokeStyle,F.fillColor=A.fillStyle,F.strokeColor=A.strokeStyle;break;case v.UNCOLORED:const D=n.Util.makeHexColor(_[0],_[1],_[2]);x.fillStyle=D,x.strokeStyle=D,F.fillColor=D,F.strokeColor=D;break;default:throw new n.FormatError(`Unsupported paint type: ${R}`)}}getPattern(w,R,_,x){let F=_;x!==s.SHADING&&(F=n.Util.transform(F,R.baseTransform),this.matrix&&(F=n.Util.transform(F,this.matrix)));const A=this.createPatternCanvas(R);let D=new DOMMatrix(F);D=D.translate(A.offsetX,A.offsetY),D=D.scale(1/A.scaleX,1/A.scaleY);const T=w.createPattern(A.canvas,"repeat");return T.setTransform(D),T}};$e(S,"MAX_PATTERN_SIZE",3e3);let y=S;e.TilingPattern=y},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.convertBlackAndWhiteToRGBA=s,e.convertToRGBA=a,e.grayToRGBA=h;var n=r(1);function a(d){switch(d.kind){case n.ImageKind.GRAYSCALE_1BPP:return s(d);case n.ImageKind.RGB_24BPP:return o(d)}return null}function s({src:d,srcPos:l=0,dest:u,width:p,height:g,nonBlackColor:f=4294967295,inverseDecode:v=!1}){const y=n.FeatureTest.isLittleEndian?4278190080:255,[S,m]=v?[f,y]:[y,f],w=p>>3,R=p&7,_=d.length;u=new Uint32Array(u.buffer);let x=0;for(let F=0;F<g;F++){for(const D=l+w;l<D;l++){const T=l<_?d[l]:255;u[x++]=T&128?m:S,u[x++]=T&64?m:S,u[x++]=T&32?m:S,u[x++]=T&16?m:S,u[x++]=T&8?m:S,u[x++]=T&4?m:S,u[x++]=T&2?m:S,u[x++]=T&1?m:S}if(R===0)continue;const A=l<_?d[l++]:255;for(let D=0;D<R;D++)u[x++]=A&1<<7-D?m:S}return{srcPos:l,destPos:x}}function o({src:d,srcPos:l=0,dest:u,destPos:p=0,width:g,height:f}){let v=0;const y=d.length>>2,S=new Uint32Array(d.buffer,l,y);if(n.FeatureTest.isLittleEndian){for(;v<y-2;v+=3,p+=4){const m=S[v],w=S[v+1],R=S[v+2];u[p]=m|4278190080,u[p+1]=m>>>24|w<<8|4278190080,u[p+2]=w>>>16|R<<16|4278190080,u[p+3]=R>>>8|4278190080}for(let m=v*4,w=d.length;m<w;m+=3)u[p++]=d[m]|d[m+1]<<8|d[m+2]<<16|4278190080}else{for(;v<y-2;v+=3,p+=4){const m=S[v],w=S[v+1],R=S[v+2];u[p]=m|255,u[p+1]=m<<24|w>>>8|255,u[p+2]=w<<16|R>>>16|255,u[p+3]=R<<8|255}for(let m=v*4,w=d.length;m<w;m+=3)u[p++]=d[m]<<24|d[m+1]<<16|d[m+2]<<8|255}return{srcPos:l,destPos:p}}function h(d,l){if(n.FeatureTest.isLittleEndian)for(let u=0,p=d.length;u<p;u++)l[u]=d[u]*65793|4278190080;else for(let u=0,p=d.length;u<p;u++)l[u]=d[u]*16843008|255}},(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.GlobalWorkerOptions=void 0;const r=Object.create(null);e.GlobalWorkerOptions=r,r.workerPort=null,r.workerSrc=""},(t,e,r)=>{var d,Dr,Er,wt;Object.defineProperty(e,"__esModule",{value:!0}),e.MessageHandler=void 0;var n=r(1);const a={DATA:1,ERROR:2},s={CANCEL:1,CANCEL_COMPLETE:2,CLOSE:3,ENQUEUE:4,ERROR:5,PULL:6,PULL_COMPLETE:7,START_COMPLETE:8};function o(g){switch(g instanceof Error||typeof g=="object"&&g!==null||(0,n.unreachable)('wrapReason: Expected "reason" to be a (possibly cloned) Error.'),g.name){case"AbortException":return new n.AbortException(g.message);case"MissingPDFException":return new n.MissingPDFException(g.message);case"PasswordException":return new n.PasswordException(g.message,g.code);case"UnexpectedResponseException":return new n.UnexpectedResponseException(g.message,g.status);case"UnknownErrorException":return new n.UnknownErrorException(g.message,g.details);default:return new n.UnknownErrorException(g.message,g.toString())}}class h{constructor(f,v,y){de(this,d);this.sourceName=f,this.targetName=v,this.comObj=y,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=S=>{const m=S.data;if(m.targetName!==this.sourceName)return;if(m.stream){te(this,d,Er).call(this,m);return}if(m.callback){const R=m.callbackId,_=this.callbackCapabilities[R];if(!_)throw new Error(`Cannot resolve callback ${R}`);if(delete this.callbackCapabilities[R],m.callback===a.DATA)_.resolve(m.data);else if(m.callback===a.ERROR)_.reject(o(m.reason));else throw new Error("Unexpected callback case");return}const w=this.actionHandler[m.action];if(!w)throw new Error(`Unknown action from worker: ${m.action}`);if(m.callbackId){const R=this.sourceName,_=m.sourceName;new Promise(function(x){x(w(m.data))}).then(function(x){y.postMessage({sourceName:R,targetName:_,callback:a.DATA,callbackId:m.callbackId,data:x})},function(x){y.postMessage({sourceName:R,targetName:_,callback:a.ERROR,callbackId:m.callbackId,reason:o(x)})});return}if(m.streamId){te(this,d,Dr).call(this,m);return}w(m.data)},y.addEventListener("message",this._onComObjOnMessage)}on(f,v){const y=this.actionHandler;if(y[f])throw new Error(`There is already an actionName called "${f}"`);y[f]=v}send(f,v,y){this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:f,data:v},y)}sendWithPromise(f,v,y){const S=this.callbackId++,m=new n.PromiseCapability;this.callbackCapabilities[S]=m;try{this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:f,callbackId:S,data:v},y)}catch(w){m.reject(w)}return m.promise}sendWithStream(f,v,y,S){const m=this.streamId++,w=this.sourceName,R=this.targetName,_=this.comObj;return new ReadableStream({start:x=>{const F=new n.PromiseCapability;return this.streamControllers[m]={controller:x,startCall:F,pullCall:null,cancelCall:null,isClosed:!1},_.postMessage({sourceName:w,targetName:R,action:f,streamId:m,data:v,desiredSize:x.desiredSize},S),F.promise},pull:x=>{const F=new n.PromiseCapability;return this.streamControllers[m].pullCall=F,_.postMessage({sourceName:w,targetName:R,stream:s.PULL,streamId:m,desiredSize:x.desiredSize}),F.promise},cancel:x=>{(0,n.assert)(x instanceof Error,"cancel must have a valid reason");const F=new n.PromiseCapability;return this.streamControllers[m].cancelCall=F,this.streamControllers[m].isClosed=!0,_.postMessage({sourceName:w,targetName:R,stream:s.CANCEL,streamId:m,reason:o(x)}),F.promise}},y)}destroy(){this.comObj.removeEventListener("message",this._onComObjOnMessage)}}d=new WeakSet,Dr=function(f){const v=f.streamId,y=this.sourceName,S=f.sourceName,m=this.comObj,w=this,R=this.actionHandler[f.action],_={enqueue(x,F=1,A){if(this.isCancelled)return;const D=this.desiredSize;this.desiredSize-=F,D>0&&this.desiredSize<=0&&(this.sinkCapability=new n.PromiseCapability,this.ready=this.sinkCapability.promise),m.postMessage({sourceName:y,targetName:S,stream:s.ENQUEUE,streamId:v,chunk:x},A)},close(){this.isCancelled||(this.isCancelled=!0,m.postMessage({sourceName:y,targetName:S,stream:s.CLOSE,streamId:v}),delete w.streamSinks[v])},error(x){(0,n.assert)(x instanceof Error,"error must have a valid reason"),!this.isCancelled&&(this.isCancelled=!0,m.postMessage({sourceName:y,targetName:S,stream:s.ERROR,streamId:v,reason:o(x)}))},sinkCapability:new n.PromiseCapability,onPull:null,onCancel:null,isCancelled:!1,desiredSize:f.desiredSize,ready:null};_.sinkCapability.resolve(),_.ready=_.sinkCapability.promise,this.streamSinks[v]=_,new Promise(function(x){x(R(f.data,_))}).then(function(){m.postMessage({sourceName:y,targetName:S,stream:s.START_COMPLETE,streamId:v,success:!0})},function(x){m.postMessage({sourceName:y,targetName:S,stream:s.START_COMPLETE,streamId:v,reason:o(x)})})},Er=function(f){const v=f.streamId,y=this.sourceName,S=f.sourceName,m=this.comObj,w=this.streamControllers[v],R=this.streamSinks[v];switch(f.stream){case s.START_COMPLETE:f.success?w.startCall.resolve():w.startCall.reject(o(f.reason));break;case s.PULL_COMPLETE:f.success?w.pullCall.resolve():w.pullCall.reject(o(f.reason));break;case s.PULL:if(!R){m.postMessage({sourceName:y,targetName:S,stream:s.PULL_COMPLETE,streamId:v,success:!0});break}R.desiredSize<=0&&f.desiredSize>0&&R.sinkCapability.resolve(),R.desiredSize=f.desiredSize,new Promise(function(_){var x;_((x=R.onPull)==null?void 0:x.call(R))}).then(function(){m.postMessage({sourceName:y,targetName:S,stream:s.PULL_COMPLETE,streamId:v,success:!0})},function(_){m.postMessage({sourceName:y,targetName:S,stream:s.PULL_COMPLETE,streamId:v,reason:o(_)})});break;case s.ENQUEUE:if((0,n.assert)(w,"enqueue should have stream controller"),w.isClosed)break;w.controller.enqueue(f.chunk);break;case s.CLOSE:if((0,n.assert)(w,"close should have stream controller"),w.isClosed)break;w.isClosed=!0,w.controller.close(),te(this,d,wt).call(this,w,v);break;case s.ERROR:(0,n.assert)(w,"error should have stream controller"),w.controller.error(o(f.reason)),te(this,d,wt).call(this,w,v);break;case s.CANCEL_COMPLETE:f.success?w.cancelCall.resolve():w.cancelCall.reject(o(f.reason)),te(this,d,wt).call(this,w,v);break;case s.CANCEL:if(!R)break;new Promise(function(_){var x;_((x=R.onCancel)==null?void 0:x.call(R,o(f.reason)))}).then(function(){m.postMessage({sourceName:y,targetName:S,stream:s.CANCEL_COMPLETE,streamId:v,success:!0})},function(_){m.postMessage({sourceName:y,targetName:S,stream:s.CANCEL_COMPLETE,streamId:v,reason:o(_)})}),R.sinkCapability.reject(o(f.reason)),R.isCancelled=!0,delete this.streamSinks[v];break;default:throw new Error("Unexpected stream case")}},wt=async function(f,v){var y,S,m;await Promise.allSettled([(y=f.startCall)==null?void 0:y.promise,(S=f.pullCall)==null?void 0:S.promise,(m=f.cancelCall)==null?void 0:m.promise]),delete this.streamControllers[v]},e.MessageHandler=h},(t,e,r)=>{var s,o;Object.defineProperty(e,"__esModule",{value:!0}),e.Metadata=void 0;var n=r(1);class a{constructor({parsedData:d,rawData:l}){de(this,s);de(this,o);ue(this,s,d),ue(this,o,l)}getRaw(){return b(this,o)}get(d){return b(this,s).get(d)??null}getAll(){return(0,n.objectFromMap)(b(this,s))}has(d){return b(this,s).has(d)}}s=new WeakMap,o=new WeakMap,e.Metadata=a},(t,e,r)=>{var d,l,u,p,g,f,Qt;Object.defineProperty(e,"__esModule",{value:!0}),e.OptionalContentConfig=void 0;var n=r(1),a=r(8);const s=Symbol("INTERNAL");class o{constructor(S,m){de(this,d,!0);this.name=S,this.intent=m}get visible(){return b(this,d)}_setVisible(S,m){S!==s&&(0,n.unreachable)("Internal method `_setVisible` called."),ue(this,d,m)}}d=new WeakMap;class h{constructor(S){de(this,f);de(this,l,null);de(this,u,new Map);de(this,p,null);de(this,g,null);if(this.name=null,this.creator=null,S!==null){this.name=S.name,this.creator=S.creator,ue(this,g,S.order);for(const m of S.groups)b(this,u).set(m.id,new o(m.name,m.intent));if(S.baseState==="OFF")for(const m of b(this,u).values())m._setVisible(s,!1);for(const m of S.on)b(this,u).get(m)._setVisible(s,!0);for(const m of S.off)b(this,u).get(m)._setVisible(s,!1);ue(this,p,this.getHash())}}isVisible(S){if(b(this,u).size===0)return!0;if(!S)return(0,n.warn)("Optional content group not defined."),!0;if(S.type==="OCG")return b(this,u).has(S.id)?b(this,u).get(S.id).visible:((0,n.warn)(`Optional content group not found: ${S.id}`),!0);if(S.type==="OCMD"){if(S.expression)return te(this,f,Qt).call(this,S.expression);if(!S.policy||S.policy==="AnyOn"){for(const m of S.ids){if(!b(this,u).has(m))return(0,n.warn)(`Optional content group not found: ${m}`),!0;if(b(this,u).get(m).visible)return!0}return!1}else if(S.policy==="AllOn"){for(const m of S.ids){if(!b(this,u).has(m))return(0,n.warn)(`Optional content group not found: ${m}`),!0;if(!b(this,u).get(m).visible)return!1}return!0}else if(S.policy==="AnyOff"){for(const m of S.ids){if(!b(this,u).has(m))return(0,n.warn)(`Optional content group not found: ${m}`),!0;if(!b(this,u).get(m).visible)return!0}return!1}else if(S.policy==="AllOff"){for(const m of S.ids){if(!b(this,u).has(m))return(0,n.warn)(`Optional content group not found: ${m}`),!0;if(b(this,u).get(m).visible)return!1}return!0}return(0,n.warn)(`Unknown optional content policy ${S.policy}.`),!0}return(0,n.warn)(`Unknown group type ${S.type}.`),!0}setVisibility(S,m=!0){if(!b(this,u).has(S)){(0,n.warn)(`Optional content group not found: ${S}`);return}b(this,u).get(S)._setVisible(s,!!m),ue(this,l,null)}get hasInitialVisibility(){return b(this,p)===null||this.getHash()===b(this,p)}getOrder(){return b(this,u).size?b(this,g)?b(this,g).slice():[...b(this,u).keys()]:null}getGroups(){return b(this,u).size>0?(0,n.objectFromMap)(b(this,u)):null}getGroup(S){return b(this,u).get(S)||null}getHash(){if(b(this,l)!==null)return b(this,l);const S=new a.MurmurHash3_64;for(const[m,w]of b(this,u))S.update(`${m}:${w.visible}`);return ue(this,l,S.hexdigest())}}l=new WeakMap,u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakSet,Qt=function(S){const m=S.length;if(m<2)return!0;const w=S[0];for(let R=1;R<m;R++){const _=S[R];let x;if(Array.isArray(_))x=te(this,f,Qt).call(this,_);else if(b(this,u).has(_))x=b(this,u).get(_).visible;else return(0,n.warn)(`Optional content group not found: ${_}`),!0;switch(w){case"And":if(!x)return!1;break;case"Or":if(x)return!0;break;case"Not":return!x;default:return!0}}return w==="And"},e.OptionalContentConfig=h},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.PDFDataTransportStream=void 0;var n=r(1),a=r(6);class s{constructor({length:l,initialData:u,progressiveDone:p=!1,contentDispositionFilename:g=null,disableRange:f=!1,disableStream:v=!1},y){if((0,n.assert)(y,'PDFDataTransportStream - missing required "pdfDataRangeTransport" argument.'),this._queuedChunks=[],this._progressiveDone=p,this._contentDispositionFilename=g,(u==null?void 0:u.length)>0){const S=u instanceof Uint8Array&&u.byteLength===u.buffer.byteLength?u.buffer:new Uint8Array(u).buffer;this._queuedChunks.push(S)}this._pdfDataRangeTransport=y,this._isStreamingSupported=!v,this._isRangeSupported=!f,this._contentLength=l,this._fullRequestReader=null,this._rangeReaders=[],this._pdfDataRangeTransport.addRangeListener((S,m)=>{this._onReceiveData({begin:S,chunk:m})}),this._pdfDataRangeTransport.addProgressListener((S,m)=>{this._onProgress({loaded:S,total:m})}),this._pdfDataRangeTransport.addProgressiveReadListener(S=>{this._onReceiveData({chunk:S})}),this._pdfDataRangeTransport.addProgressiveDoneListener(()=>{this._onProgressiveDone()}),this._pdfDataRangeTransport.transportReady()}_onReceiveData({begin:l,chunk:u}){const p=u instanceof Uint8Array&&u.byteLength===u.buffer.byteLength?u.buffer:new Uint8Array(u).buffer;if(l===void 0)this._fullRequestReader?this._fullRequestReader._enqueue(p):this._queuedChunks.push(p);else{const g=this._rangeReaders.some(function(f){return f._begin!==l?!1:(f._enqueue(p),!0)});(0,n.assert)(g,"_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found.")}}get _progressiveDataLength(){var l;return((l=this._fullRequestReader)==null?void 0:l._loaded)??0}_onProgress(l){var u,p,g,f;l.total===void 0?(p=(u=this._rangeReaders[0])==null?void 0:u.onProgress)==null||p.call(u,{loaded:l.loaded}):(f=(g=this._fullRequestReader)==null?void 0:g.onProgress)==null||f.call(g,{loaded:l.loaded,total:l.total})}_onProgressiveDone(){var l;(l=this._fullRequestReader)==null||l.progressiveDone(),this._progressiveDone=!0}_removeRangeReader(l){const u=this._rangeReaders.indexOf(l);u>=0&&this._rangeReaders.splice(u,1)}getFullReader(){(0,n.assert)(!this._fullRequestReader,"PDFDataTransportStream.getFullReader can only be called once.");const l=this._queuedChunks;return this._queuedChunks=null,new o(this,l,this._progressiveDone,this._contentDispositionFilename)}getRangeReader(l,u){if(u<=this._progressiveDataLength)return null;const p=new h(this,l,u);return this._pdfDataRangeTransport.requestDataRange(l,u),this._rangeReaders.push(p),p}cancelAllRequests(l){var u;(u=this._fullRequestReader)==null||u.cancel(l);for(const p of this._rangeReaders.slice(0))p.cancel(l);this._pdfDataRangeTransport.abort()}}e.PDFDataTransportStream=s;class o{constructor(l,u,p=!1,g=null){this._stream=l,this._done=p||!1,this._filename=(0,a.isPdfFile)(g)?g:null,this._queuedChunks=u||[],this._loaded=0;for(const f of this._queuedChunks)this._loaded+=f.byteLength;this._requests=[],this._headersReady=Promise.resolve(),l._fullRequestReader=this,this.onProgress=null}_enqueue(l){this._done||(this._requests.length>0?this._requests.shift().resolve({value:l,done:!1}):this._queuedChunks.push(l),this._loaded+=l.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}async read(){if(this._queuedChunks.length>0)return{value:this._queuedChunks.shift(),done:!1};if(this._done)return{value:void 0,done:!0};const l=new n.PromiseCapability;return this._requests.push(l),l.promise}cancel(l){this._done=!0;for(const u of this._requests)u.resolve({value:void 0,done:!0});this._requests.length=0}progressiveDone(){this._done||(this._done=!0)}}class h{constructor(l,u,p){this._stream=l,this._begin=u,this._end=p,this._queuedChunk=null,this._requests=[],this._done=!1,this.onProgress=null}_enqueue(l){if(!this._done){if(this._requests.length===0)this._queuedChunk=l;else{this._requests.shift().resolve({value:l,done:!1});for(const p of this._requests)p.resolve({value:void 0,done:!0});this._requests.length=0}this._done=!0,this._stream._removeRangeReader(this)}}get isStreamingSupported(){return!1}async read(){if(this._queuedChunk){const u=this._queuedChunk;return this._queuedChunk=null,{value:u,done:!1}}if(this._done)return{value:void 0,done:!0};const l=new n.PromiseCapability;return this._requests.push(l),l.promise}cancel(l){this._done=!0;for(const u of this._requests)u.resolve({value:void 0,done:!0});this._requests.length=0,this._stream._removeRangeReader(this)}}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.PDFFetchStream=void 0;var n=r(1),a=r(20);function s(p,g,f){return{method:"GET",headers:p,signal:f.signal,mode:"cors",credentials:g?"include":"same-origin",redirect:"follow"}}function o(p){const g=new Headers;for(const f in p){const v=p[f];v!==void 0&&g.append(f,v)}return g}function h(p){return p instanceof Uint8Array?p.buffer:p instanceof ArrayBuffer?p:((0,n.warn)(`getArrayBuffer - unexpected data format: ${p}`),new Uint8Array(p).buffer)}class d{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(){var g;return((g=this._fullRequestReader)==null?void 0:g._loaded)??0}getFullReader(){return(0,n.assert)(!this._fullRequestReader,"PDFFetchStream.getFullReader can only be called once."),this._fullRequestReader=new l(this),this._fullRequestReader}getRangeReader(g,f){if(f<=this._progressiveDataLength)return null;const v=new u(this,g,f);return this._rangeRequestReaders.push(v),v}cancelAllRequests(g){var f;(f=this._fullRequestReader)==null||f.cancel(g);for(const v of this._rangeRequestReaders.slice(0))v.cancel(g)}}e.PDFFetchStream=d;class l{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=new n.PromiseCapability,this._disableRange=f.disableRange||!1,this._rangeChunkSize=f.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._abortController=new AbortController,this._isStreamingSupported=!f.disableStream,this._isRangeSupported=!f.disableRange,this._headers=o(this._stream.httpHeaders);const v=f.url;fetch(v,s(this._headers,this._withCredentials,this._abortController)).then(y=>{if(!(0,a.validateResponseStatus)(y.status))throw(0,a.createResponseStatusError)(y.status,v);this._reader=y.body.getReader(),this._headersCapability.resolve();const S=R=>y.headers.get(R),{allowRangeRequests:m,suggestedLength:w}=(0,a.validateRangeRequestCapabilities)({getResponseHeader:S,isHttp:this._stream.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=m,this._contentLength=w||this._contentLength,this._filename=(0,a.extractFilenameFromHeader)(S),!this._isStreamingSupported&&this._isRangeSupported&&this.cancel(new n.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}async read(){var v;await this._headersCapability.promise;const{value:g,done:f}=await this._reader.read();return f?{value:g,done:f}:(this._loaded+=g.byteLength,(v=this.onProgress)==null||v.call(this,{loaded:this._loaded,total:this._contentLength}),{value:h(g),done:!1})}cancel(g){var f;(f=this._reader)==null||f.cancel(g),this._abortController.abort()}}class u{constructor(g,f,v){this._stream=g,this._reader=null,this._loaded=0;const y=g.source;this._withCredentials=y.withCredentials||!1,this._readCapability=new n.PromiseCapability,this._isStreamingSupported=!y.disableStream,this._abortController=new AbortController,this._headers=o(this._stream.httpHeaders),this._headers.append("Range",`bytes=${f}-${v-1}`);const S=y.url;fetch(S,s(this._headers,this._withCredentials,this._abortController)).then(m=>{if(!(0,a.validateResponseStatus)(m.status))throw(0,a.createResponseStatusError)(m.status,S);this._readCapability.resolve(),this._reader=m.body.getReader()}).catch(this._readCapability.reject),this.onProgress=null}get isStreamingSupported(){return this._isStreamingSupported}async read(){var v;await this._readCapability.promise;const{value:g,done:f}=await this._reader.read();return f?{value:g,done:f}:(this._loaded+=g.byteLength,(v=this.onProgress)==null||v.call(this,{loaded:this._loaded}),{value:h(g),done:!1})}cancel(g){var f;(f=this._reader)==null||f.cancel(g),this._abortController.abort()}}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.createResponseStatusError=d,e.extractFilenameFromHeader=h,e.validateRangeRequestCapabilities=o,e.validateResponseStatus=l;var n=r(1),a=r(21),s=r(6);function o({getResponseHeader:u,isHttp:p,rangeChunkSize:g,disableRange:f}){const v={allowRangeRequests:!1,suggestedLength:void 0},y=parseInt(u("Content-Length"),10);return!Number.isInteger(y)||(v.suggestedLength=y,y<=2*g)||f||!p||u("Accept-Ranges")!=="bytes"||(u("Content-Encoding")||"identity")!=="identity"||(v.allowRangeRequests=!0),v}function h(u){const p=u("Content-Disposition");if(p){let g=(0,a.getFilenameFromContentDispositionHeader)(p);if(g.includes("%"))try{g=decodeURIComponent(g)}catch{}if((0,s.isPdfFile)(g))return g}return null}function d(u,p){return u===404||u===0&&p.startsWith("file:")?new n.MissingPDFException('Missing PDF "'+p+'".'):new n.UnexpectedResponseException(`Unexpected server response (${u}) while retrieving PDF "${p}".`,u)}function l(u){return u===200||u===206}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.getFilenameFromContentDispositionHeader=a;var n=r(1);function a(s){let o=!0,h=d("filename\\*","i").exec(s);if(h){h=h[1];let y=g(h);return y=unescape(y),y=f(y),y=v(y),u(y)}if(h=p(s),h){const y=v(h);return u(y)}if(h=d("filename","i").exec(s),h){h=h[1];let y=g(h);return y=v(y),u(y)}function d(y,S){return new RegExp("(?:^|;)\\s*"+y+'\\s*=\\s*([^";\\s][^;\\s]*|"(?:[^"\\\\]|\\\\"?)+"?)',S)}function l(y,S){if(y){if(!/^[\x00-\xFF]+$/.test(S))return S;try{const m=new TextDecoder(y,{fatal:!0}),w=(0,n.stringToBytes)(S);S=m.decode(w),o=!1}catch{}}return S}function u(y){return o&&/[\x80-\xff]/.test(y)&&(y=l("utf-8",y),o&&(y=l("iso-8859-1",y))),y}function p(y){const S=[];let m;const w=d("filename\\*((?!0\\d)\\d+)(\\*?)","ig");for(;(m=w.exec(y))!==null;){let[,_,x,F]=m;if(_=parseInt(_,10),_ in S){if(_===0)break;continue}S[_]=[x,F]}const R=[];for(let _=0;_<S.length&&_ in S;++_){let[x,F]=S[_];F=g(F),x&&(F=unescape(F),_===0&&(F=f(F))),R.push(F)}return R.join("")}function g(y){if(y.startsWith('"')){const S=y.slice(1).split('\\"');for(let m=0;m<S.length;++m){const w=S[m].indexOf('"');w!==-1&&(S[m]=S[m].slice(0,w),S.length=m+1),S[m]=S[m].replaceAll(/\\(.)/g,"$1")}y=S.join('"')}return y}function f(y){const S=y.indexOf("'");if(S===-1)return y;const m=y.slice(0,S),R=y.slice(S+1).replace(/^[^']*'/,"");return l(m,R)}function v(y){return!y.startsWith("=?")||/[\x00-\x19\x80-\xff]/.test(y)?y:y.replaceAll(/=\?([\w-]*)\?([QqBb])\?((?:[^?]|\?(?!=))*)\?=/g,function(S,m,w,R){if(w==="q"||w==="Q")return R=R.replaceAll("_"," "),R=R.replaceAll(/=([0-9a-fA-F]{2})/g,function(_,x){return String.fromCharCode(parseInt(x,16))}),l(m,R);try{R=atob(R)}catch{}return l(m,R)})}return""}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.PDFNetworkStream=void 0;var n=r(1),a=r(20);const s=200,o=206;function h(g){const f=g.response;return typeof f!="string"?f:(0,n.stringToBytes)(f).buffer}class d{constructor(f,v={}){this.url=f,this.isHttp=/^https?:/i.test(f),this.httpHeaders=this.isHttp&&v.httpHeaders||Object.create(null),this.withCredentials=v.withCredentials||!1,this.currXhrId=0,this.pendingRequests=Object.create(null)}requestRange(f,v,y){const S={begin:f,end:v};for(const m in y)S[m]=y[m];return this.request(S)}requestFull(f){return this.request(f)}request(f){const v=new XMLHttpRequest,y=this.currXhrId++,S=this.pendingRequests[y]={xhr:v};v.open("GET",this.url),v.withCredentials=this.withCredentials;for(const m in this.httpHeaders){const w=this.httpHeaders[m];w!==void 0&&v.setRequestHeader(m,w)}return this.isHttp&&"begin"in f&&"end"in f?(v.setRequestHeader("Range",`bytes=${f.begin}-${f.end-1}`),S.expectedStatus=o):S.expectedStatus=s,v.responseType="arraybuffer",f.onError&&(v.onerror=function(m){f.onError(v.status)}),v.onreadystatechange=this.onStateChange.bind(this,y),v.onprogress=this.onProgress.bind(this,y),S.onHeadersReceived=f.onHeadersReceived,S.onDone=f.onDone,S.onError=f.onError,S.onProgress=f.onProgress,v.send(null),y}onProgress(f,v){var S;const y=this.pendingRequests[f];y&&((S=y.onProgress)==null||S.call(y,v))}onStateChange(f,v){var _,x,F;const y=this.pendingRequests[f];if(!y)return;const S=y.xhr;if(S.readyState>=2&&y.onHeadersReceived&&(y.onHeadersReceived(),delete y.onHeadersReceived),S.readyState!==4||!(f in this.pendingRequests))return;if(delete this.pendingRequests[f],S.status===0&&this.isHttp){(_=y.onError)==null||_.call(y,S.status);return}const m=S.status||s;if(!(m===s&&y.expectedStatus===o)&&m!==y.expectedStatus){(x=y.onError)==null||x.call(y,S.status);return}const R=h(S);if(m===o){const A=S.getResponseHeader("Content-Range"),D=/bytes (\d+)-(\d+)\/(\d+)/.exec(A);y.onDone({begin:parseInt(D[1],10),chunk:R})}else R?y.onDone({begin:0,chunk:R}):(F=y.onError)==null||F.call(y,S.status)}getRequestXhr(f){return this.pendingRequests[f].xhr}isPendingRequest(f){return f in this.pendingRequests}abortRequest(f){const v=this.pendingRequests[f].xhr;delete this.pendingRequests[f],v.abort()}}class l{constructor(f){this._source=f,this._manager=new d(f.url,{httpHeaders:f.httpHeaders,withCredentials:f.withCredentials}),this._rangeChunkSize=f.rangeChunkSize,this._fullRequestReader=null,this._rangeRequestReaders=[]}_onRangeRequestReaderClosed(f){const v=this._rangeRequestReaders.indexOf(f);v>=0&&this._rangeRequestReaders.splice(v,1)}getFullReader(){return(0,n.assert)(!this._fullRequestReader,"PDFNetworkStream.getFullReader can only be called once."),this._fullRequestReader=new u(this._manager,this._source),this._fullRequestReader}getRangeReader(f,v){const y=new p(this._manager,f,v);return y.onClosed=this._onRangeRequestReaderClosed.bind(this),this._rangeRequestReaders.push(y),y}cancelAllRequests(f){var v;(v=this._fullRequestReader)==null||v.cancel(f);for(const y of this._rangeRequestReaders.slice(0))y.cancel(f)}}e.PDFNetworkStream=l;class u{constructor(f,v){this._manager=f;const y={onHeadersReceived:this._onHeadersReceived.bind(this),onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=v.url,this._fullRequestId=f.requestFull(y),this._headersReceivedCapability=new n.PromiseCapability,this._disableRange=v.disableRange||!1,this._contentLength=v.length,this._rangeChunkSize=v.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 f=this._fullRequestId,v=this._manager.getRequestXhr(f),y=w=>v.getResponseHeader(w),{allowRangeRequests:S,suggestedLength:m}=(0,a.validateRangeRequestCapabilities)({getResponseHeader:y,isHttp:this._manager.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});S&&(this._isRangeSupported=!0),this._contentLength=m||this._contentLength,this._filename=(0,a.extractFilenameFromHeader)(y),this._isRangeSupported&&this._manager.abortRequest(f),this._headersReceivedCapability.resolve()}_onDone(f){if(f&&(this._requests.length>0?this._requests.shift().resolve({value:f.chunk,done:!1}):this._cachedChunks.push(f.chunk)),this._done=!0,!(this._cachedChunks.length>0)){for(const v of this._requests)v.resolve({value:void 0,done:!0});this._requests.length=0}}_onError(f){this._storedError=(0,a.createResponseStatusError)(f,this._url),this._headersReceivedCapability.reject(this._storedError);for(const v of this._requests)v.reject(this._storedError);this._requests.length=0,this._cachedChunks.length=0}_onProgress(f){var v;(v=this.onProgress)==null||v.call(this,{loaded:f.loaded,total:f.lengthComputable?f.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}async read(){if(this._storedError)throw this._storedError;if(this._cachedChunks.length>0)return{value:this._cachedChunks.shift(),done:!1};if(this._done)return{value:void 0,done:!0};const f=new n.PromiseCapability;return this._requests.push(f),f.promise}cancel(f){this._done=!0,this._headersReceivedCapability.reject(f);for(const v of this._requests)v.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._fullRequestId)&&this._manager.abortRequest(this._fullRequestId),this._fullRequestReader=null}}class p{constructor(f,v,y){this._manager=f;const S={onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=f.url,this._requestId=f.requestRange(v,y,S),this._requests=[],this._queuedChunk=null,this._done=!1,this._storedError=void 0,this.onProgress=null,this.onClosed=null}_close(){var f;(f=this.onClosed)==null||f.call(this,this)}_onDone(f){const v=f.chunk;this._requests.length>0?this._requests.shift().resolve({value:v,done:!1}):this._queuedChunk=v,this._done=!0;for(const y of this._requests)y.resolve({value:void 0,done:!0});this._requests.length=0,this._close()}_onError(f){this._storedError=(0,a.createResponseStatusError)(f,this._url);for(const v of this._requests)v.reject(this._storedError);this._requests.length=0,this._queuedChunk=null}_onProgress(f){var v;this.isStreamingSupported||(v=this.onProgress)==null||v.call(this,{loaded:f.loaded})}get isStreamingSupported(){return!1}async read(){if(this._storedError)throw this._storedError;if(this._queuedChunk!==null){const v=this._queuedChunk;return this._queuedChunk=null,{value:v,done:!1}}if(this._done)return{value:void 0,done:!0};const f=new n.PromiseCapability;return this._requests.push(f),f.promise}cancel(f){this._done=!0;for(const v of this._requests)v.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._requestId)&&this._manager.abortRequest(this._requestId),this._close()}}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.PDFNodeStream=void 0;var n=r(1),a=r(20);const s=/^file:\/\/\/[a-zA-Z]:\//;function o(y){const S=require$$5,m=S.parse(y);return m.protocol==="file:"||m.host?m:/^[a-z]:[/\\]/i.test(y)?S.parse(`file:///${y}`):(m.host||(m.protocol="file:"),m)}class h{constructor(S){this.source=S,this.url=o(S.url),this.isHttp=this.url.protocol==="http:"||this.url.protocol==="https:",this.isFsUrl=this.url.protocol==="file:",this.httpHeaders=this.isHttp&&S.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){var S;return((S=this._fullRequestReader)==null?void 0:S._loaded)??0}getFullReader(){return(0,n.assert)(!this._fullRequestReader,"PDFNodeStream.getFullReader can only be called once."),this._fullRequestReader=this.isFsUrl?new f(this):new p(this),this._fullRequestReader}getRangeReader(S,m){if(m<=this._progressiveDataLength)return null;const w=this.isFsUrl?new v(this,S,m):new g(this,S,m);return this._rangeRequestReaders.push(w),w}cancelAllRequests(S){var m;(m=this._fullRequestReader)==null||m.cancel(S);for(const w of this._rangeRequestReaders.slice(0))w.cancel(S)}}e.PDFNodeStream=h;class d{constructor(S){this._url=S.url,this._done=!1,this._storedError=null,this.onProgress=null;const m=S.source;this._contentLength=m.length,this._loaded=0,this._filename=null,this._disableRange=m.disableRange||!1,this._rangeChunkSize=m.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._isStreamingSupported=!m.disableStream,this._isRangeSupported=!m.disableRange,this._readableStream=null,this._readCapability=new n.PromiseCapability,this._headersCapability=new n.PromiseCapability}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}async read(){var w;if(await this._readCapability.promise,this._done)return{value:void 0,done:!0};if(this._storedError)throw this._storedError;const S=this._readableStream.read();return S===null?(this._readCapability=new n.PromiseCapability,this.read()):(this._loaded+=S.length,(w=this.onProgress)==null||w.call(this,{loaded:this._loaded,total:this._contentLength}),{value:new Uint8Array(S).buffer,done:!1})}cancel(S){if(!this._readableStream){this._error(S);return}this._readableStream.destroy(S)}_error(S){this._storedError=S,this._readCapability.resolve()}_setReadableStream(S){this._readableStream=S,S.on("readable",()=>{this._readCapability.resolve()}),S.on("end",()=>{S.destroy(),this._done=!0,this._readCapability.resolve()}),S.on("error",m=>{this._error(m)}),!this._isStreamingSupported&&this._isRangeSupported&&this._error(new n.AbortException("streaming is disabled")),this._storedError&&this._readableStream.destroy(this._storedError)}}class l{constructor(S){this._url=S.url,this._done=!1,this._storedError=null,this.onProgress=null,this._loaded=0,this._readableStream=null,this._readCapability=new n.PromiseCapability;const m=S.source;this._isStreamingSupported=!m.disableStream}get isStreamingSupported(){return this._isStreamingSupported}async read(){var w;if(await this._readCapability.promise,this._done)return{value:void 0,done:!0};if(this._storedError)throw this._storedError;const S=this._readableStream.read();return S===null?(this._readCapability=new n.PromiseCapability,this.read()):(this._loaded+=S.length,(w=this.onProgress)==null||w.call(this,{loaded:this._loaded}),{value:new Uint8Array(S).buffer,done:!1})}cancel(S){if(!this._readableStream){this._error(S);return}this._readableStream.destroy(S)}_error(S){this._storedError=S,this._readCapability.resolve()}_setReadableStream(S){this._readableStream=S,S.on("readable",()=>{this._readCapability.resolve()}),S.on("end",()=>{S.destroy(),this._done=!0,this._readCapability.resolve()}),S.on("error",m=>{this._error(m)}),this._storedError&&this._readableStream.destroy(this._storedError)}}function u(y,S){return{protocol:y.protocol,auth:y.auth,host:y.hostname,port:y.port,path:y.path,method:"GET",headers:S}}class p extends d{constructor(S){super(S);const m=w=>{if(w.statusCode===404){const F=new n.MissingPDFException(`Missing PDF "${this._url}".`);this._storedError=F,this._headersCapability.reject(F);return}this._headersCapability.resolve(),this._setReadableStream(w);const R=F=>this._readableStream.headers[F.toLowerCase()],{allowRangeRequests:_,suggestedLength:x}=(0,a.validateRangeRequestCapabilities)({getResponseHeader:R,isHttp:S.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=_,this._contentLength=x||this._contentLength,this._filename=(0,a.extractFilenameFromHeader)(R)};if(this._request=null,this._url.protocol==="http:"){const w=require$$5;this._request=w.request(u(this._url,S.httpHeaders),m)}else{const w=require$$5;this._request=w.request(u(this._url,S.httpHeaders),m)}this._request.on("error",w=>{this._storedError=w,this._headersCapability.reject(w)}),this._request.end()}}class g extends l{constructor(S,m,w){super(S),this._httpHeaders={};for(const _ in S.httpHeaders){const x=S.httpHeaders[_];x!==void 0&&(this._httpHeaders[_]=x)}this._httpHeaders.Range=`bytes=${m}-${w-1}`;const R=_=>{if(_.statusCode===404){const x=new n.MissingPDFException(`Missing PDF "${this._url}".`);this._storedError=x;return}this._setReadableStream(_)};if(this._request=null,this._url.protocol==="http:"){const _=require$$5;this._request=_.request(u(this._url,this._httpHeaders),R)}else{const _=require$$5;this._request=_.request(u(this._url,this._httpHeaders),R)}this._request.on("error",_=>{this._storedError=_}),this._request.end()}}class f extends d{constructor(S){super(S);let m=decodeURIComponent(this._url.path);s.test(this._url.href)&&(m=m.replace(/^\//,""));const w=require$$5;w.lstat(m,(R,_)=>{if(R){R.code==="ENOENT"&&(R=new n.MissingPDFException(`Missing PDF "${m}".`)),this._storedError=R,this._headersCapability.reject(R);return}this._contentLength=_.size,this._setReadableStream(w.createReadStream(m)),this._headersCapability.resolve()})}}class v extends l{constructor(S,m,w){super(S);let R=decodeURIComponent(this._url.path);s.test(this._url.href)&&(R=R.replace(/^\//,""));const _=require$$5;this._setReadableStream(_.createReadStream(R,{start:m,end:w-1}))}}},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.SVGGraphics=void 0;var n=r(6),a=r(1);const s={fontStyle:"normal",fontWeight:"normal",fillColor:"#000000"},o="http://www.w3.org/XML/1998/namespace",h="http://www.w3.org/1999/xlink",d=["butt","round","square"],l=["miter","round","bevel"],u=function(_,x="",F=!1){if(URL.createObjectURL&&typeof Blob<"u"&&!F)return URL.createObjectURL(new Blob([_],{type:x}));const A="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";let D=`data:${x};base64,`;for(let T=0,M=_.length;T<M;T+=3){const C=_[T]&255,k=_[T+1]&255,O=_[T+2]&255,$=C>>2,K=(C&3)<<4|k>>4,J=T+1<M?(k&15)<<2|O>>6:64,Y=T+2<M?O&63:64;D+=A[$]+A[K]+A[J]+A[Y]}return D},p=function(){const _=new Uint8Array([137,80,78,71,13,10,26,10]),x=12,F=new Int32Array(256);for(let O=0;O<256;O++){let $=O;for(let K=0;K<8;K++)$=$&1?3988292384^$>>1&2147483647:$>>1&2147483647;F[O]=$}function A(O,$,K){let J=-1;for(let Y=$;Y<K;Y++){const se=(J^O[Y])&255,B=F[se];J=J>>>8^B}return J^-1}function D(O,$,K,J){let Y=J;const se=$.length;K[Y]=se>>24&255,K[Y+1]=se>>16&255,K[Y+2]=se>>8&255,K[Y+3]=se&255,Y+=4,K[Y]=O.charCodeAt(0)&255,K[Y+1]=O.charCodeAt(1)&255,K[Y+2]=O.charCodeAt(2)&255,K[Y+3]=O.charCodeAt(3)&255,Y+=4,K.set($,Y),Y+=$.length;const B=A(K,J+4,Y);K[Y]=B>>24&255,K[Y+1]=B>>16&255,K[Y+2]=B>>8&255,K[Y+3]=B&255}function T(O,$,K){let J=1,Y=0;for(let se=$;se<K;++se)J=(J+(O[se]&255))%65521,Y=(Y+J)%65521;return Y<<16|J}function M(O){if(!a.isNodeJS)return C(O);try{const $=parseInt(process.versions.node)>=8?O:Buffer.from(O),K=require$$5.deflateSync($,{level:9});return K instanceof Uint8Array?K:new Uint8Array(K)}catch($){(0,a.warn)("Not compressing PNG because zlib.deflateSync is unavailable: "+$)}return C(O)}function C(O){let $=O.length;const K=65535,J=Math.ceil($/K),Y=new Uint8Array(2+$+J*5+4);let se=0;Y[se++]=120,Y[se++]=156;let B=0;for(;$>K;)Y[se++]=0,Y[se++]=255,Y[se++]=255,Y[se++]=0,Y[se++]=0,Y.set(O.subarray(B,B+K),se),se+=K,B+=K,$-=K;Y[se++]=1,Y[se++]=$&255,Y[se++]=$>>8&255,Y[se++]=~$&65535&255,Y[se++]=(~$&65535)>>8&255,Y.set(O.subarray(B),se),se+=O.length-B;const V=T(O,0,O.length);return Y[se++]=V>>24&255,Y[se++]=V>>16&255,Y[se++]=V>>8&255,Y[se++]=V&255,Y}function k(O,$,K,J){const Y=O.width,se=O.height;let B,V,Q;const N=O.data;switch($){case a.ImageKind.GRAYSCALE_1BPP:V=0,B=1,Q=Y+7>>3;break;case a.ImageKind.RGB_24BPP:V=2,B=8,Q=Y*3;break;case a.ImageKind.RGBA_32BPP:V=6,B=8,Q=Y*4;break;default:throw new Error("invalid format")}const P=new Uint8Array((1+Q)*se);let E=0,I=0;for(let ve=0;ve<se;++ve)P[E++]=0,P.set(N.subarray(I,I+Q),E),I+=Q,E+=Q;if($===a.ImageKind.GRAYSCALE_1BPP&&J){E=0;for(let ve=0;ve<se;ve++){E++;for(let me=0;me<Q;me++)P[E++]^=255}}const z=new Uint8Array([Y>>24&255,Y>>16&255,Y>>8&255,Y&255,se>>24&255,se>>16&255,se>>8&255,se&255,B,V,0,0,0]),G=M(P),H=_.length+x*3+z.length+G.length,ee=new Uint8Array(H);let ce=0;return ee.set(_,ce),ce+=_.length,D("IHDR",z,ee,ce),ce+=x+z.length,D("IDATA",G,ee,ce),ce+=x+G.length,D("IEND",new Uint8Array(0),ee,ce),u(ee,"image/png",K)}return function($,K,J){const Y=$.kind===void 0?a.ImageKind.GRAYSCALE_1BPP:$.kind;return k($,Y,K,J)}}();class g{constructor(){this.fontSizeScale=1,this.fontWeight=s.fontWeight,this.fontSize=0,this.textMatrix=a.IDENTITY_MATRIX,this.fontMatrix=a.FONT_IDENTITY_MATRIX,this.leading=0,this.textRenderingMode=a.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=s.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(x,F){this.x=x,this.y=F}}function f(_){let x=[];const F=[];for(const A of _){if(A.fn==="save"){x.push({fnId:92,fn:"group",items:[]}),F.push(x),x=x.at(-1).items;continue}A.fn==="restore"?x=F.pop():x.push(A)}return x}function v(_){if(Number.isInteger(_))return _.toString();const x=_.toFixed(10);let F=x.length-1;if(x[F]!=="0")return x;do F--;while(x[F]==="0");return x.substring(0,x[F]==="."?F:F+1)}function y(_){if(_[4]===0&&_[5]===0){if(_[1]===0&&_[2]===0)return _[0]===1&&_[3]===1?"":`scale(${v(_[0])} ${v(_[3])})`;if(_[0]===_[3]&&_[1]===-_[2]){const x=Math.acos(_[0])*180/Math.PI;return`rotate(${v(x)})`}}else if(_[0]===1&&_[1]===0&&_[2]===0&&_[3]===1)return`translate(${v(_[4])} ${v(_[5])})`;return`matrix(${v(_[0])} ${v(_[1])} ${v(_[2])} ${v(_[3])} ${v(_[4])} ${v(_[5])})`}let S=0,m=0,w=0;class R{constructor(x,F,A=!1){(0,n.deprecated)("The SVG back-end is no longer maintained and *may* be removed in the future."),this.svgFactory=new n.DOMSVGFactory,this.current=new g,this.transformMatrix=a.IDENTITY_MATRIX,this.transformStack=[],this.extraStack=[],this.commonObjs=x,this.objs=F,this.pendingClip=null,this.pendingEOFill=!1,this.embedFonts=!1,this.embeddedFonts=Object.create(null),this.cssStyle=null,this.forceDataSchema=!!A,this._operatorIdMapping=[];for(const D in a.OPS)this._operatorIdMapping[a.OPS[D]]=D}getObject(x,F=null){return typeof x=="string"?x.startsWith("g_")?this.commonObjs.get(x):this.objs.get(x):F}save(){this.transformStack.push(this.transformMatrix);const x=this.current;this.extraStack.push(x),this.current=x.clone()}restore(){this.transformMatrix=this.transformStack.pop(),this.current=this.extraStack.pop(),this.pendingClip=null,this.tgrp=null}group(x){this.save(),this.executeOpTree(x),this.restore()}loadDependencies(x){const F=x.fnArray,A=x.argsArray;for(let D=0,T=F.length;D<T;D++)if(F[D]===a.OPS.dependency)for(const M of A[D]){const C=M.startsWith("g_")?this.commonObjs:this.objs,k=new Promise(O=>{C.get(M,O)});this.current.dependencies.push(k)}return Promise.all(this.current.dependencies)}transform(x,F,A,D,T,M){const C=[x,F,A,D,T,M];this.transformMatrix=a.Util.transform(this.transformMatrix,C),this.tgrp=null}getSVG(x,F){this.viewport=F;const A=this._initialize(F);return this.loadDependencies(x).then(()=>(this.transformMatrix=a.IDENTITY_MATRIX,this.executeOpTree(this.convertOpList(x)),A))}convertOpList(x){const F=this._operatorIdMapping,A=x.argsArray,D=x.fnArray,T=[];for(let M=0,C=D.length;M<C;M++){const k=D[M];T.push({fnId:k,fn:F[k],args:A[M]})}return f(T)}executeOpTree(x){for(const F of x){const A=F.fn,D=F.fnId,T=F.args;switch(D|0){case a.OPS.beginText:this.beginText();break;case a.OPS.dependency:break;case a.OPS.setLeading:this.setLeading(T);break;case a.OPS.setLeadingMoveText:this.setLeadingMoveText(T[0],T[1]);break;case a.OPS.setFont:this.setFont(T);break;case a.OPS.showText:this.showText(T[0]);break;case a.OPS.showSpacedText:this.showText(T[0]);break;case a.OPS.endText:this.endText();break;case a.OPS.moveText:this.moveText(T[0],T[1]);break;case a.OPS.setCharSpacing:this.setCharSpacing(T[0]);break;case a.OPS.setWordSpacing:this.setWordSpacing(T[0]);break;case a.OPS.setHScale:this.setHScale(T[0]);break;case a.OPS.setTextMatrix:this.setTextMatrix(T[0],T[1],T[2],T[3],T[4],T[5]);break;case a.OPS.setTextRise:this.setTextRise(T[0]);break;case a.OPS.setTextRenderingMode:this.setTextRenderingMode(T[0]);break;case a.OPS.setLineWidth:this.setLineWidth(T[0]);break;case a.OPS.setLineJoin:this.setLineJoin(T[0]);break;case a.OPS.setLineCap:this.setLineCap(T[0]);break;case a.OPS.setMiterLimit:this.setMiterLimit(T[0]);break;case a.OPS.setFillRGBColor:this.setFillRGBColor(T[0],T[1],T[2]);break;case a.OPS.setStrokeRGBColor:this.setStrokeRGBColor(T[0],T[1],T[2]);break;case a.OPS.setStrokeColorN:this.setStrokeColorN(T);break;case a.OPS.setFillColorN:this.setFillColorN(T);break;case a.OPS.shadingFill:this.shadingFill(T[0]);break;case a.OPS.setDash:this.setDash(T[0],T[1]);break;case a.OPS.setRenderingIntent:this.setRenderingIntent(T[0]);break;case a.OPS.setFlatness:this.setFlatness(T[0]);break;case a.OPS.setGState:this.setGState(T[0]);break;case a.OPS.fill:this.fill();break;case a.OPS.eoFill:this.eoFill();break;case a.OPS.stroke:this.stroke();break;case a.OPS.fillStroke:this.fillStroke();break;case a.OPS.eoFillStroke:this.eoFillStroke();break;case a.OPS.clip:this.clip("nonzero");break;case a.OPS.eoClip:this.clip("evenodd");break;case a.OPS.paintSolidColorImageMask:this.paintSolidColorImageMask();break;case a.OPS.paintImageXObject:this.paintImageXObject(T[0]);break;case a.OPS.paintInlineImageXObject:this.paintInlineImageXObject(T[0]);break;case a.OPS.paintImageMaskXObject:this.paintImageMaskXObject(T[0]);break;case a.OPS.paintFormXObjectBegin:this.paintFormXObjectBegin(T[0],T[1]);break;case a.OPS.paintFormXObjectEnd:this.paintFormXObjectEnd();break;case a.OPS.closePath:this.closePath();break;case a.OPS.closeStroke:this.closeStroke();break;case a.OPS.closeFillStroke:this.closeFillStroke();break;case a.OPS.closeEOFillStroke:this.closeEOFillStroke();break;case a.OPS.nextLine:this.nextLine();break;case a.OPS.transform:this.transform(T[0],T[1],T[2],T[3],T[4],T[5]);break;case a.OPS.constructPath:this.constructPath(T[0],T[1]);break;case a.OPS.endPath:this.endPath();break;case 92:this.group(F.items);break;default:(0,a.warn)(`Unimplemented operator ${A}`);break}}}setWordSpacing(x){this.current.wordSpacing=x}setCharSpacing(x){this.current.charSpacing=x}nextLine(){this.moveText(0,this.current.leading)}setTextMatrix(x,F,A,D,T,M){const C=this.current;C.textMatrix=C.lineMatrix=[x,F,A,D,T,M],C.textMatrixScale=Math.hypot(x,F),C.x=C.lineX=0,C.y=C.lineY=0,C.xcoords=[],C.ycoords=[],C.tspan=this.svgFactory.createElement("svg:tspan"),C.tspan.setAttributeNS(null,"font-family",C.fontFamily),C.tspan.setAttributeNS(null,"font-size",`${v(C.fontSize)}px`),C.tspan.setAttributeNS(null,"y",v(-C.y)),C.txtElement=this.svgFactory.createElement("svg:text"),C.txtElement.append(C.tspan)}beginText(){const x=this.current;x.x=x.lineX=0,x.y=x.lineY=0,x.textMatrix=a.IDENTITY_MATRIX,x.lineMatrix=a.IDENTITY_MATRIX,x.textMatrixScale=1,x.tspan=this.svgFactory.createElement("svg:tspan"),x.txtElement=this.svgFactory.createElement("svg:text"),x.txtgrp=this.svgFactory.createElement("svg:g"),x.xcoords=[],x.ycoords=[]}moveText(x,F){const A=this.current;A.x=A.lineX+=x,A.y=A.lineY+=F,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",`${v(A.fontSize)}px`),A.tspan.setAttributeNS(null,"y",v(-A.y))}showText(x){const F=this.current,A=F.font,D=F.fontSize;if(D===0)return;const T=F.fontSizeScale,M=F.charSpacing,C=F.wordSpacing,k=F.fontDirection,O=F.textHScale*k,$=A.vertical,K=$?1:-1,J=A.defaultVMetrics,Y=D*F.fontMatrix[0];let se=0;for(const Q of x){if(Q===null){se+=k*C;continue}else if(typeof Q=="number"){se+=K*Q*D/1e3;continue}const N=(Q.isSpace?C:0)+M,P=Q.fontChar;let E,I,z=Q.width;if($){let H;const ee=Q.vmetric||J;H=Q.vmetric?ee[1]:z*.5,H=-H*Y;const ce=ee[2]*Y;z=ee?-ee[0]:z,E=H/T,I=(se+ce)/T}else E=se/T,I=0;(Q.isInFont||A.missingFile)&&(F.xcoords.push(F.x+E),$&&F.ycoords.push(-F.y+I),F.tspan.textContent+=P);const G=$?z*Y-N*k:z*Y+N*k;se+=G}F.tspan.setAttributeNS(null,"x",F.xcoords.map(v).join(" ")),$?F.tspan.setAttributeNS(null,"y",F.ycoords.map(v).join(" ")):F.tspan.setAttributeNS(null,"y",v(-F.y)),$?F.y-=se:F.x+=se*O,F.tspan.setAttributeNS(null,"font-family",F.fontFamily),F.tspan.setAttributeNS(null,"font-size",`${v(F.fontSize)}px`),F.fontStyle!==s.fontStyle&&F.tspan.setAttributeNS(null,"font-style",F.fontStyle),F.fontWeight!==s.fontWeight&&F.tspan.setAttributeNS(null,"font-weight",F.fontWeight);const B=F.textRenderingMode&a.TextRenderingMode.FILL_STROKE_MASK;if(B===a.TextRenderingMode.FILL||B===a.TextRenderingMode.FILL_STROKE?(F.fillColor!==s.fillColor&&F.tspan.setAttributeNS(null,"fill",F.fillColor),F.fillAlpha<1&&F.tspan.setAttributeNS(null,"fill-opacity",F.fillAlpha)):F.textRenderingMode===a.TextRenderingMode.ADD_TO_PATH?F.tspan.setAttributeNS(null,"fill","transparent"):F.tspan.setAttributeNS(null,"fill","none"),B===a.TextRenderingMode.STROKE||B===a.TextRenderingMode.FILL_STROKE){const Q=1/(F.textMatrixScale||1);this._setStrokeAttributes(F.tspan,Q)}let V=F.textMatrix;F.textRise!==0&&(V=V.slice(),V[5]+=F.textRise),F.txtElement.setAttributeNS(null,"transform",`${y(V)} scale(${v(O)}, -1)`),F.txtElement.setAttributeNS(o,"xml:space","preserve"),F.txtElement.append(F.tspan),F.txtgrp.append(F.txtElement),this._ensureTransformGroup().append(F.txtElement)}setLeadingMoveText(x,F){this.setLeading(-F),this.moveText(x,F)}addFontStyle(x){if(!x.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.append(this.cssStyle));const F=u(x.data,x.mimetype,this.forceDataSchema);this.cssStyle.textContent+=`@font-face { font-family: "${x.loadedName}"; src: url(${F}); }
|
|
4
|
+
`}setFont(x){const F=this.current,A=this.commonObjs.get(x[0]);let D=x[1];F.font=A,this.embedFonts&&!A.missingFile&&!this.embeddedFonts[A.loadedName]&&(this.addFontStyle(A),this.embeddedFonts[A.loadedName]=A),F.fontMatrix=A.fontMatrix||a.FONT_IDENTITY_MATRIX;let T="normal";A.black?T="900":A.bold&&(T="bold");const M=A.italic?"italic":"normal";D<0?(D=-D,F.fontDirection=-1):F.fontDirection=1,F.fontSize=D,F.fontFamily=A.loadedName,F.fontWeight=T,F.fontStyle=M,F.tspan=this.svgFactory.createElement("svg:tspan"),F.tspan.setAttributeNS(null,"y",v(-F.y)),F.xcoords=[],F.ycoords=[]}endText(){var F;const x=this.current;x.textRenderingMode&a.TextRenderingMode.ADD_TO_PATH_FLAG&&((F=x.txtElement)!=null&&F.hasChildNodes())&&(x.element=x.txtElement,this.clip("nonzero"),this.endPath())}setLineWidth(x){x>0&&(this.current.lineWidth=x)}setLineCap(x){this.current.lineCap=d[x]}setLineJoin(x){this.current.lineJoin=l[x]}setMiterLimit(x){this.current.miterLimit=x}setStrokeAlpha(x){this.current.strokeAlpha=x}setStrokeRGBColor(x,F,A){this.current.strokeColor=a.Util.makeHexColor(x,F,A)}setFillAlpha(x){this.current.fillAlpha=x}setFillRGBColor(x,F,A){this.current.fillColor=a.Util.makeHexColor(x,F,A),this.current.tspan=this.svgFactory.createElement("svg:tspan"),this.current.xcoords=[],this.current.ycoords=[]}setStrokeColorN(x){this.current.strokeColor=this._makeColorN_Pattern(x)}setFillColorN(x){this.current.fillColor=this._makeColorN_Pattern(x)}shadingFill(x){const{width:F,height:A}=this.viewport,D=a.Util.inverseTransform(this.transformMatrix),[T,M,C,k]=a.Util.getAxialAlignedBoundingBox([0,0,F,A],D),O=this.svgFactory.createElement("svg:rect");O.setAttributeNS(null,"x",T),O.setAttributeNS(null,"y",M),O.setAttributeNS(null,"width",C-T),O.setAttributeNS(null,"height",k-M),O.setAttributeNS(null,"fill",this._makeShadingPattern(x)),this.current.fillAlpha<1&&O.setAttributeNS(null,"fill-opacity",this.current.fillAlpha),this._ensureTransformGroup().append(O)}_makeColorN_Pattern(x){return x[0]==="TilingPattern"?this._makeTilingPattern(x):this._makeShadingPattern(x)}_makeTilingPattern(x){const F=x[1],A=x[2],D=x[3]||a.IDENTITY_MATRIX,[T,M,C,k]=x[4],O=x[5],$=x[6],K=x[7],J=`shading${w++}`,[Y,se,B,V]=a.Util.normalizeRect([...a.Util.applyTransform([T,M],D),...a.Util.applyTransform([C,k],D)]),[Q,N]=a.Util.singularValueDecompose2dScale(D),P=O*Q,E=$*N,I=this.svgFactory.createElement("svg:pattern");I.setAttributeNS(null,"id",J),I.setAttributeNS(null,"patternUnits","userSpaceOnUse"),I.setAttributeNS(null,"width",P),I.setAttributeNS(null,"height",E),I.setAttributeNS(null,"x",`${Y}`),I.setAttributeNS(null,"y",`${se}`);const z=this.svg,G=this.transformMatrix,H=this.current.fillColor,ee=this.current.strokeColor,ce=this.svgFactory.create(B-Y,V-se);if(this.svg=ce,this.transformMatrix=D,K===2){const ve=a.Util.makeHexColor(...F);this.current.fillColor=ve,this.current.strokeColor=ve}return this.executeOpTree(this.convertOpList(A)),this.svg=z,this.transformMatrix=G,this.current.fillColor=H,this.current.strokeColor=ee,I.append(ce.childNodes[0]),this.defs.append(I),`url(#${J})`}_makeShadingPattern(x){switch(typeof x=="string"&&(x=this.objs.get(x)),x[0]){case"RadialAxial":const F=`shading${w++}`,A=x[3];let D;switch(x[1]){case"axial":const T=x[4],M=x[5];D=this.svgFactory.createElement("svg:linearGradient"),D.setAttributeNS(null,"id",F),D.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),D.setAttributeNS(null,"x1",T[0]),D.setAttributeNS(null,"y1",T[1]),D.setAttributeNS(null,"x2",M[0]),D.setAttributeNS(null,"y2",M[1]);break;case"radial":const C=x[4],k=x[5],O=x[6],$=x[7];D=this.svgFactory.createElement("svg:radialGradient"),D.setAttributeNS(null,"id",F),D.setAttributeNS(null,"gradientUnits","userSpaceOnUse"),D.setAttributeNS(null,"cx",k[0]),D.setAttributeNS(null,"cy",k[1]),D.setAttributeNS(null,"r",$),D.setAttributeNS(null,"fx",C[0]),D.setAttributeNS(null,"fy",C[1]),D.setAttributeNS(null,"fr",O);break;default:throw new Error(`Unknown RadialAxial type: ${x[1]}`)}for(const T of A){const M=this.svgFactory.createElement("svg:stop");M.setAttributeNS(null,"offset",T[0]),M.setAttributeNS(null,"stop-color",T[1]),D.append(M)}return this.defs.append(D),`url(#${F})`;case"Mesh":return(0,a.warn)("Unimplemented pattern Mesh"),null;case"Dummy":return"hotpink";default:throw new Error(`Unknown IR type: ${x[0]}`)}}setDash(x,F){this.current.dashArray=x,this.current.dashPhase=F}constructPath(x,F){const A=this.current;let D=A.x,T=A.y,M=[],C=0;for(const k of x)switch(k|0){case a.OPS.rectangle:D=F[C++],T=F[C++];const O=F[C++],$=F[C++],K=D+O,J=T+$;M.push("M",v(D),v(T),"L",v(K),v(T),"L",v(K),v(J),"L",v(D),v(J),"Z");break;case a.OPS.moveTo:D=F[C++],T=F[C++],M.push("M",v(D),v(T));break;case a.OPS.lineTo:D=F[C++],T=F[C++],M.push("L",v(D),v(T));break;case a.OPS.curveTo:D=F[C+4],T=F[C+5],M.push("C",v(F[C]),v(F[C+1]),v(F[C+2]),v(F[C+3]),v(D),v(T)),C+=6;break;case a.OPS.curveTo2:M.push("C",v(D),v(T),v(F[C]),v(F[C+1]),v(F[C+2]),v(F[C+3])),D=F[C+2],T=F[C+3],C+=4;break;case a.OPS.curveTo3:D=F[C+2],T=F[C+3],M.push("C",v(F[C]),v(F[C+1]),v(D),v(T),v(D),v(T)),C+=4;break;case a.OPS.closePath:M.push("Z");break}M=M.join(" "),A.path&&x.length>0&&x[0]!==a.OPS.rectangle&&x[0]!==a.OPS.moveTo?M=A.path.getAttributeNS(null,"d")+M:(A.path=this.svgFactory.createElement("svg:path"),this._ensureTransformGroup().append(A.path)),A.path.setAttributeNS(null,"d",M),A.path.setAttributeNS(null,"fill","none"),A.element=A.path,A.setCurrentPoint(D,T)}endPath(){const x=this.current;if(x.path=null,!this.pendingClip)return;if(!x.element){this.pendingClip=null;return}const F=`clippath${S++}`,A=this.svgFactory.createElement("svg:clipPath");A.setAttributeNS(null,"id",F),A.setAttributeNS(null,"transform",y(this.transformMatrix));const D=x.element.cloneNode(!0);if(this.pendingClip==="evenodd"?D.setAttributeNS(null,"clip-rule","evenodd"):D.setAttributeNS(null,"clip-rule","nonzero"),this.pendingClip=null,A.append(D),this.defs.append(A),x.activeClipUrl){x.clipGroup=null;for(const T of this.extraStack)T.clipGroup=null;A.setAttributeNS(null,"clip-path",x.activeClipUrl)}x.activeClipUrl=`url(#${F})`,this.tgrp=null}clip(x){this.pendingClip=x}closePath(){const x=this.current;if(x.path){const F=`${x.path.getAttributeNS(null,"d")}Z`;x.path.setAttributeNS(null,"d",F)}}setLeading(x){this.current.leading=-x}setTextRise(x){this.current.textRise=x}setTextRenderingMode(x){this.current.textRenderingMode=x}setHScale(x){this.current.textHScale=x/100}setRenderingIntent(x){}setFlatness(x){}setGState(x){for(const[F,A]of x)switch(F){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,a.warn)(`Unimplemented graphic state operator ${F}`);break}}fill(){const x=this.current;x.element&&(x.element.setAttributeNS(null,"fill",x.fillColor),x.element.setAttributeNS(null,"fill-opacity",x.fillAlpha),this.endPath())}stroke(){const x=this.current;x.element&&(this._setStrokeAttributes(x.element),x.element.setAttributeNS(null,"fill","none"),this.endPath())}_setStrokeAttributes(x,F=1){const A=this.current;let D=A.dashArray;F!==1&&D.length>0&&(D=D.map(function(T){return F*T})),x.setAttributeNS(null,"stroke",A.strokeColor),x.setAttributeNS(null,"stroke-opacity",A.strokeAlpha),x.setAttributeNS(null,"stroke-miterlimit",v(A.miterLimit)),x.setAttributeNS(null,"stroke-linecap",A.lineCap),x.setAttributeNS(null,"stroke-linejoin",A.lineJoin),x.setAttributeNS(null,"stroke-width",v(F*A.lineWidth)+"px"),x.setAttributeNS(null,"stroke-dasharray",D.map(v).join(" ")),x.setAttributeNS(null,"stroke-dashoffset",v(F*A.dashPhase)+"px")}eoFill(){var x;(x=this.current.element)==null||x.setAttributeNS(null,"fill-rule","evenodd"),this.fill()}fillStroke(){this.stroke(),this.fill()}eoFillStroke(){var x;(x=this.current.element)==null||x.setAttributeNS(null,"fill-rule","evenodd"),this.fillStroke()}closeStroke(){this.closePath(),this.stroke()}closeFillStroke(){this.closePath(),this.fillStroke()}closeEOFillStroke(){this.closePath(),this.eoFillStroke()}paintSolidColorImageMask(){const x=this.svgFactory.createElement("svg:rect");x.setAttributeNS(null,"x","0"),x.setAttributeNS(null,"y","0"),x.setAttributeNS(null,"width","1px"),x.setAttributeNS(null,"height","1px"),x.setAttributeNS(null,"fill",this.current.fillColor),this._ensureTransformGroup().append(x)}paintImageXObject(x){const F=this.getObject(x);if(!F){(0,a.warn)(`Dependent image with object ID ${x} is not ready yet`);return}this.paintInlineImageXObject(F)}paintInlineImageXObject(x,F){const A=x.width,D=x.height,T=p(x,this.forceDataSchema,!!F),M=this.svgFactory.createElement("svg:rect");M.setAttributeNS(null,"x","0"),M.setAttributeNS(null,"y","0"),M.setAttributeNS(null,"width",v(A)),M.setAttributeNS(null,"height",v(D)),this.current.element=M,this.clip("nonzero");const C=this.svgFactory.createElement("svg:image");C.setAttributeNS(h,"xlink:href",T),C.setAttributeNS(null,"x","0"),C.setAttributeNS(null,"y",v(-D)),C.setAttributeNS(null,"width",v(A)+"px"),C.setAttributeNS(null,"height",v(D)+"px"),C.setAttributeNS(null,"transform",`scale(${v(1/A)} ${v(-1/D)})`),F?F.append(C):this._ensureTransformGroup().append(C)}paintImageMaskXObject(x){const F=this.getObject(x.data,x);if(F.bitmap){(0,a.warn)("paintImageMaskXObject: ImageBitmap support is not implemented, ensure that the `isOffscreenCanvasSupported` API parameter is disabled.");return}const A=this.current,D=F.width,T=F.height,M=A.fillColor;A.maskId=`mask${m++}`;const C=this.svgFactory.createElement("svg:mask");C.setAttributeNS(null,"id",A.maskId);const k=this.svgFactory.createElement("svg:rect");k.setAttributeNS(null,"x","0"),k.setAttributeNS(null,"y","0"),k.setAttributeNS(null,"width",v(D)),k.setAttributeNS(null,"height",v(T)),k.setAttributeNS(null,"fill",M),k.setAttributeNS(null,"mask",`url(#${A.maskId})`),this.defs.append(C),this._ensureTransformGroup().append(k),this.paintInlineImageXObject(F,C)}paintFormXObjectBegin(x,F){if(Array.isArray(x)&&x.length===6&&this.transform(x[0],x[1],x[2],x[3],x[4],x[5]),F){const A=F[2]-F[0],D=F[3]-F[1],T=this.svgFactory.createElement("svg:rect");T.setAttributeNS(null,"x",F[0]),T.setAttributeNS(null,"y",F[1]),T.setAttributeNS(null,"width",v(A)),T.setAttributeNS(null,"height",v(D)),this.current.element=T,this.clip("nonzero"),this.endPath()}}paintFormXObjectEnd(){}_initialize(x){const F=this.svgFactory.create(x.width,x.height),A=this.svgFactory.createElement("svg:defs");F.append(A),this.defs=A;const D=this.svgFactory.createElement("svg:g");return D.setAttributeNS(null,"transform",y(x.transform)),F.append(D),this.svg=D,F}_ensureClipGroup(){if(!this.current.clipGroup){const x=this.svgFactory.createElement("svg:g");x.setAttributeNS(null,"clip-path",this.current.activeClipUrl),this.svg.append(x),this.current.clipGroup=x}return this.current.clipGroup}_ensureTransformGroup(){return this.tgrp||(this.tgrp=this.svgFactory.createElement("svg:g"),this.tgrp.setAttributeNS(null,"transform",y(this.transformMatrix)),this.current.activeClipUrl?this._ensureClipGroup().append(this.tgrp):this.svg.append(this.tgrp)),this.tgrp}}e.SVGGraphics=R},(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.XfaText=void 0;class r{static textContent(a){const s=[],o={items:s,styles:Object.create(null)};function h(d){var p;if(!d)return;let l=null;const u=d.name;if(u==="#text")l=d.value;else if(r.shouldBuildText(u))(p=d==null?void 0:d.attributes)!=null&&p.textContent?l=d.attributes.textContent:d.value&&(l=d.value);else return;if(l!==null&&s.push({str:l}),!!d.children)for(const g of d.children)h(g)}return h(a),o}static shouldBuildText(a){return!(a==="textarea"||a==="input"||a==="option"||a==="select")}}e.XfaText=r},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.TextLayerRenderTask=void 0,e.renderTextLayer=y,e.updateTextLayer=S;var n=r(1),a=r(6);const s=1e5,o=30,h=.8,d=new Map;function l(m,w){let R;if(w&&n.FeatureTest.isOffscreenCanvasSupported)R=new OffscreenCanvas(m,m).getContext("2d",{alpha:!1});else{const _=document.createElement("canvas");_.width=_.height=m,R=_.getContext("2d",{alpha:!1})}return R}function u(m,w){const R=d.get(m);if(R)return R;const _=l(o,w);_.font=`${o}px ${m}`;const x=_.measureText("");let F=x.fontBoundingBoxAscent,A=Math.abs(x.fontBoundingBoxDescent);if(F){const T=F/(F+A);return d.set(m,T),_.canvas.width=_.canvas.height=0,T}_.strokeStyle="red",_.clearRect(0,0,o,o),_.strokeText("g",0,0);let D=_.getImageData(0,0,o,o).data;A=0;for(let T=D.length-1-3;T>=0;T-=4)if(D[T]>0){A=Math.ceil(T/4/o);break}_.clearRect(0,0,o,o),_.strokeText("A",0,o),D=_.getImageData(0,0,o,o).data,F=0;for(let T=0,M=D.length;T<M;T+=4)if(D[T]>0){F=o-Math.floor(T/4/o);break}if(_.canvas.width=_.canvas.height=0,F){const T=F/(F+A);return d.set(m,T),T}return d.set(m,h),h}function p(m,w,R){const _=document.createElement("span"),x={angle:0,canvasWidth:0,hasText:w.str!=="",hasEOL:w.hasEOL,fontSize:0};m._textDivs.push(_);const F=n.Util.transform(m._transform,w.transform);let A=Math.atan2(F[1],F[0]);const D=R[w.fontName];D.vertical&&(A+=Math.PI/2);const T=Math.hypot(F[2],F[3]),M=T*u(D.fontFamily,m._isOffscreenCanvasSupported);let C,k;A===0?(C=F[4],k=F[5]-M):(C=F[4]+M*Math.sin(A),k=F[5]-M*Math.cos(A));const O="calc(var(--scale-factor)*",$=_.style;m._container===m._rootContainer?($.left=`${(100*C/m._pageWidth).toFixed(2)}%`,$.top=`${(100*k/m._pageHeight).toFixed(2)}%`):($.left=`${O}${C.toFixed(2)}px)`,$.top=`${O}${k.toFixed(2)}px)`),$.fontSize=`${O}${T.toFixed(2)}px)`,$.fontFamily=D.fontFamily,x.fontSize=T,_.setAttribute("role","presentation"),_.textContent=w.str,_.dir=w.dir,m._fontInspectorEnabled&&(_.dataset.fontName=w.fontName),A!==0&&(x.angle=A*(180/Math.PI));let K=!1;if(w.str.length>1)K=!0;else if(w.str!==" "&&w.transform[0]!==w.transform[3]){const J=Math.abs(w.transform[0]),Y=Math.abs(w.transform[3]);J!==Y&&Math.max(J,Y)/Math.min(J,Y)>1.5&&(K=!0)}K&&(x.canvasWidth=D.vertical?w.height:w.width),m._textDivProperties.set(_,x),m._isReadableStream&&m._layoutText(_)}function g(m){const{div:w,scale:R,properties:_,ctx:x,prevFontSize:F,prevFontFamily:A}=m,{style:D}=w;let T="";if(_.canvasWidth!==0&&_.hasText){const{fontFamily:M}=D,{canvasWidth:C,fontSize:k}=_;(F!==k||A!==M)&&(x.font=`${k*R}px ${M}`,m.prevFontSize=k,m.prevFontFamily=M);const{width:O}=x.measureText(w.textContent);O>0&&(T=`scaleX(${C*R/O})`)}_.angle!==0&&(T=`rotate(${_.angle}deg) ${T}`),T.length>0&&(D.transform=T)}function f(m){if(m._canceled)return;const w=m._textDivs,R=m._capability;if(w.length>s){R.resolve();return}if(!m._isReadableStream)for(const x of w)m._layoutText(x);R.resolve()}class v{constructor({textContentSource:w,container:R,viewport:_,textDivs:x,textDivProperties:F,textContentItemsStr:A,isOffscreenCanvasSupported:D}){var O;this._textContentSource=w,this._isReadableStream=w instanceof ReadableStream,this._container=this._rootContainer=R,this._textDivs=x||[],this._textContentItemsStr=A||[],this._isOffscreenCanvasSupported=D,this._fontInspectorEnabled=!!((O=globalThis.FontInspector)!=null&&O.enabled),this._reader=null,this._textDivProperties=F||new WeakMap,this._canceled=!1,this._capability=new n.PromiseCapability,this._layoutTextParams={prevFontSize:null,prevFontFamily:null,div:null,scale:_.scale*(globalThis.devicePixelRatio||1),properties:null,ctx:l(0,D)};const{pageWidth:T,pageHeight:M,pageX:C,pageY:k}=_.rawDims;this._transform=[1,0,0,-1,-C,k+M],this._pageWidth=T,this._pageHeight=M,(0,a.setLayerDimensions)(R,_),this._capability.promise.finally(()=>{this._layoutTextParams=null}).catch(()=>{})}get promise(){return this._capability.promise}cancel(){this._canceled=!0,this._reader&&(this._reader.cancel(new n.AbortException("TextLayer task cancelled.")).catch(()=>{}),this._reader=null),this._capability.reject(new n.AbortException("TextLayer task cancelled."))}_processItems(w,R){for(const _ of w){if(_.str===void 0){if(_.type==="beginMarkedContentProps"||_.type==="beginMarkedContent"){const x=this._container;this._container=document.createElement("span"),this._container.classList.add("markedContent"),_.id!==null&&this._container.setAttribute("id",`${_.id}`),x.append(this._container)}else _.type==="endMarkedContent"&&(this._container=this._container.parentNode);continue}this._textContentItemsStr.push(_.str),p(this,_,R)}}_layoutText(w){const R=this._layoutTextParams.properties=this._textDivProperties.get(w);if(this._layoutTextParams.div=w,g(this._layoutTextParams),R.hasText&&this._container.append(w),R.hasEOL){const _=document.createElement("br");_.setAttribute("role","presentation"),this._container.append(_)}}_render(){const w=new n.PromiseCapability;let R=Object.create(null);if(this._isReadableStream){const _=()=>{this._reader.read().then(({value:x,done:F})=>{if(F){w.resolve();return}Object.assign(R,x.styles),this._processItems(x.items,R),_()},w.reject)};this._reader=this._textContentSource.getReader(),_()}else if(this._textContentSource){const{items:_,styles:x}=this._textContentSource;this._processItems(_,x),w.resolve()}else throw new Error('No "textContentSource" parameter specified.');w.promise.then(()=>{R=null,f(this)},this._capability.reject)}}e.TextLayerRenderTask=v;function y(m){!m.textContentSource&&(m.textContent||m.textContentStream)&&((0,a.deprecated)("The TextLayerRender `textContent`/`textContentStream` parameters will be removed in the future, please use `textContentSource` instead."),m.textContentSource=m.textContent||m.textContentStream);const{container:w,viewport:R}=m,_=getComputedStyle(w),x=_.getPropertyValue("visibility"),F=parseFloat(_.getPropertyValue("--scale-factor"));x==="visible"&&(!F||Math.abs(F-R.scale)>1e-5)&&console.error("The `--scale-factor` CSS-variable must be set, to the same value as `viewport.scale`, either on the `container`-element itself or higher up in the DOM.");const A=new v(m);return A._render(),A}function S({container:m,viewport:w,textDivs:R,textDivProperties:_,isOffscreenCanvasSupported:x,mustRotate:F=!0,mustRescale:A=!0}){if(F&&(0,a.setLayerDimensions)(m,{rotation:w.rotation}),A){const D=l(0,x),M={prevFontSize:null,prevFontFamily:null,div:null,scale:w.scale*(globalThis.devicePixelRatio||1),properties:null,ctx:D};for(const C of R)M.properties=_.get(C),M.div=C,g(M)}}},(t,e,r)=>{var u,p,g,f,v,y,S,m,w,R,_,$t,Dt,er,tr;Object.defineProperty(e,"__esModule",{value:!0}),e.AnnotationEditorLayer=void 0;var n=r(1),a=r(4),s=r(28),o=r(33),h=r(6),d=r(34);const T=class T{constructor({uiManager:C,pageIndex:k,div:O,accessibilityManager:$,annotationLayer:K,viewport:J,l10n:Y}){de(this,_);de(this,u);de(this,p,!1);de(this,g,null);de(this,f,this.pointerup.bind(this));de(this,v,this.pointerdown.bind(this));de(this,y,new Map);de(this,S,!1);de(this,m,!1);de(this,w,!1);de(this,R);const se=[s.FreeTextEditor,o.InkEditor,d.StampEditor];if(!T._initialized){T._initialized=!0;for(const B of se)B.initialize(Y)}C.registerEditorTypes(se),ue(this,R,C),this.pageIndex=k,this.div=O,ue(this,u,$),ue(this,g,K),this.viewport=J,b(this,R).addLayer(this)}get isEmpty(){return b(this,y).size===0}updateToolbar(C){b(this,R).updateToolbar(C)}updateMode(C=b(this,R).getMode()){te(this,_,tr).call(this),C===n.AnnotationEditorType.INK?(this.addInkEditorIfNeeded(!1),this.disableClick()):this.enableClick(),C!==n.AnnotationEditorType.NONE&&(this.div.classList.toggle("freeTextEditing",C===n.AnnotationEditorType.FREETEXT),this.div.classList.toggle("inkEditing",C===n.AnnotationEditorType.INK),this.div.classList.toggle("stampEditing",C===n.AnnotationEditorType.STAMP),this.div.hidden=!1)}addInkEditorIfNeeded(C){if(!C&&b(this,R).getMode()!==n.AnnotationEditorType.INK)return;if(!C){for(const O of b(this,y).values())if(O.isEmpty()){O.setInBackground();return}}te(this,_,Dt).call(this,{offsetX:0,offsetY:0},!1).setInBackground()}setEditingState(C){b(this,R).setEditingState(C)}addCommands(C){b(this,R).addCommands(C)}enable(){this.div.style.pointerEvents="auto";const C=new Set;for(const O of b(this,y).values())O.enableEditing(),O.annotationElementId&&C.add(O.annotationElementId);if(!b(this,g))return;const k=b(this,g).getEditableAnnotations();for(const O of k){if(O.hide(),b(this,R).isDeletedAnnotationElement(O.data.id)||C.has(O.data.id))continue;const $=this.deserialize(O);$&&(this.addOrRebuild($),$.enableEditing())}}disable(){var k;ue(this,w,!0),this.div.style.pointerEvents="none";const C=new Set;for(const O of b(this,y).values()){if(O.disableEditing(),!O.annotationElementId||O.serialize()!==null){C.add(O.annotationElementId);continue}(k=this.getEditableAnnotation(O.annotationElementId))==null||k.show(),O.remove()}if(b(this,g)){const O=b(this,g).getEditableAnnotations();for(const $ of O){const{id:K}=$.data;C.has(K)||b(this,R).isDeletedAnnotationElement(K)||$.show()}}te(this,_,tr).call(this),this.isEmpty&&(this.div.hidden=!0),ue(this,w,!1)}getEditableAnnotation(C){var k;return((k=b(this,g))==null?void 0:k.getEditableAnnotation(C))||null}setActiveEditor(C){b(this,R).getActive()!==C&&b(this,R).setActiveEditor(C)}enableClick(){this.div.addEventListener("pointerdown",b(this,v)),this.div.addEventListener("pointerup",b(this,f))}disableClick(){this.div.removeEventListener("pointerdown",b(this,v)),this.div.removeEventListener("pointerup",b(this,f))}attach(C){b(this,y).set(C.id,C);const{annotationElementId:k}=C;k&&b(this,R).isDeletedAnnotationElement(k)&&b(this,R).removeDeletedAnnotationElement(C)}detach(C){var k;b(this,y).delete(C.id),(k=b(this,u))==null||k.removePointerInTextLayer(C.contentDiv),!b(this,w)&&C.annotationElementId&&b(this,R).addDeletedAnnotationElement(C)}remove(C){this.detach(C),b(this,R).removeEditor(C),C.div.contains(document.activeElement)&&setTimeout(()=>{b(this,R).focusMainContainer()},0),C.div.remove(),C.isAttachedToDOM=!1,b(this,m)||this.addInkEditorIfNeeded(!1)}changeParent(C){var k;C.parent!==this&&(C.annotationElementId&&(b(this,R).addDeletedAnnotationElement(C.annotationElementId),a.AnnotationEditor.deleteAnnotationElement(C),C.annotationElementId=null),this.attach(C),(k=C.parent)==null||k.detach(C),C.setParent(this),C.div&&C.isAttachedToDOM&&(C.div.remove(),this.div.append(C.div)))}add(C){if(this.changeParent(C),b(this,R).addEditor(C),this.attach(C),!C.isAttachedToDOM){const k=C.render();this.div.append(k),C.isAttachedToDOM=!0}C.fixAndSetPosition(),C.onceAdded(),b(this,R).addToAnnotationStorage(C)}moveEditorInDOM(C){var O;if(!C.isAttachedToDOM)return;const{activeElement:k}=document;C.div.contains(k)&&(C._focusEventsAllowed=!1,setTimeout(()=>{C.div.contains(document.activeElement)?C._focusEventsAllowed=!0:(C.div.addEventListener("focusin",()=>{C._focusEventsAllowed=!0},{once:!0}),k.focus())},0)),C._structTreeParentId=(O=b(this,u))==null?void 0:O.moveElementInDOM(this.div,C.div,C.contentDiv,!0)}addOrRebuild(C){C.needsToBeRebuilt()?C.rebuild():this.add(C)}addUndoableEditor(C){const k=()=>C._uiManager.rebuild(C),O=()=>{C.remove()};this.addCommands({cmd:k,undo:O,mustExec:!1})}getNextId(){return b(this,R).getId()}pasteEditor(C,k){b(this,R).updateToolbar(C),b(this,R).updateMode(C);const{offsetX:O,offsetY:$}=te(this,_,er).call(this),K=this.getNextId(),J=te(this,_,$t).call(this,{parent:this,id:K,x:O,y:$,uiManager:b(this,R),isCentered:!0,...k});J&&this.add(J)}deserialize(C){switch(C.annotationType??C.annotationEditorType){case n.AnnotationEditorType.FREETEXT:return s.FreeTextEditor.deserialize(C,this,b(this,R));case n.AnnotationEditorType.INK:return o.InkEditor.deserialize(C,this,b(this,R));case n.AnnotationEditorType.STAMP:return d.StampEditor.deserialize(C,this,b(this,R))}return null}addNewEditor(){te(this,_,Dt).call(this,te(this,_,er).call(this),!0)}setSelected(C){b(this,R).setSelected(C)}toggleSelected(C){b(this,R).toggleSelected(C)}isSelected(C){return b(this,R).isSelected(C)}unselect(C){b(this,R).unselect(C)}pointerup(C){const{isMac:k}=n.FeatureTest.platform;if(!(C.button!==0||C.ctrlKey&&k)&&C.target===this.div&&b(this,S)){if(ue(this,S,!1),!b(this,p)){ue(this,p,!0);return}if(b(this,R).getMode()===n.AnnotationEditorType.STAMP){b(this,R).unselectAll();return}te(this,_,Dt).call(this,C,!1)}}pointerdown(C){if(b(this,S)){ue(this,S,!1);return}const{isMac:k}=n.FeatureTest.platform;if(C.button!==0||C.ctrlKey&&k||C.target!==this.div)return;ue(this,S,!0);const O=b(this,R).getActive();ue(this,p,!O||O.isEmpty())}findNewParent(C,k,O){const $=b(this,R).findParent(k,O);return $===null||$===this?!1:($.changeParent(C),!0)}destroy(){var C,k;((C=b(this,R).getActive())==null?void 0:C.parent)===this&&(b(this,R).commitOrRemove(),b(this,R).setActiveEditor(null));for(const O of b(this,y).values())(k=b(this,u))==null||k.removePointerInTextLayer(O.contentDiv),O.setParent(null),O.isAttachedToDOM=!1,O.div.remove();this.div=null,b(this,y).clear(),b(this,R).removeLayer(this)}render({viewport:C}){this.viewport=C,(0,h.setLayerDimensions)(this.div,C);for(const k of b(this,R).getEditors(this.pageIndex))this.add(k);this.updateMode()}update({viewport:C}){b(this,R).commitOrRemove(),this.viewport=C,(0,h.setLayerDimensions)(this.div,{rotation:C.rotation}),this.updateMode()}get pageDimensions(){const{pageWidth:C,pageHeight:k}=this.viewport.rawDims;return[C,k]}};u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakMap,S=new WeakMap,m=new WeakMap,w=new WeakMap,R=new WeakMap,_=new WeakSet,$t=function(C){switch(b(this,R).getMode()){case n.AnnotationEditorType.FREETEXT:return new s.FreeTextEditor(C);case n.AnnotationEditorType.INK:return new o.InkEditor(C);case n.AnnotationEditorType.STAMP:return new d.StampEditor(C)}return null},Dt=function(C,k){const O=this.getNextId(),$=te(this,_,$t).call(this,{parent:this,id:O,x:C.offsetX,y:C.offsetY,uiManager:b(this,R),isCentered:k});return $&&this.add($),$},er=function(){const{x:C,y:k,width:O,height:$}=this.div.getBoundingClientRect(),K=Math.max(0,C),J=Math.max(0,k),Y=Math.min(window.innerWidth,C+O),se=Math.min(window.innerHeight,k+$),B=(K+Y)/2-C,V=(J+se)/2-k,[Q,N]=this.viewport.rotation%180===0?[B,V]:[V,B];return{offsetX:Q,offsetY:N}},tr=function(){ue(this,m,!0);for(const C of b(this,y).values())C.isEmpty()&&C.remove();ue(this,m,!1)},$e(T,"_initialized",!1);let l=T;e.AnnotationEditorLayer=l},(t,e,r)=>{var d,l,u,p,g,f,v,y,S,m,Tr,_r,Rr,yt,rr,kr,nr;Object.defineProperty(e,"__esModule",{value:!0}),e.FreeTextEditor=void 0;var n=r(1),a=r(5),s=r(4),o=r(29);const T=class T extends s.AnnotationEditor{constructor(k){super({...k,name:"freeTextEditor"});de(this,m);de(this,d,this.editorDivBlur.bind(this));de(this,l,this.editorDivFocus.bind(this));de(this,u,this.editorDivInput.bind(this));de(this,p,this.editorDivKeydown.bind(this));de(this,g);de(this,f,"");de(this,v,`${this.id}-editor`);de(this,y);de(this,S,null);ue(this,g,k.color||T._defaultColor||s.AnnotationEditor._defaultLineColor),ue(this,y,k.fontSize||T._defaultFontSize)}static get _keyboardManager(){const k=T.prototype,O=J=>J.isEmpty(),$=a.AnnotationEditorUIManager.TRANSLATE_SMALL,K=a.AnnotationEditorUIManager.TRANSLATE_BIG;return(0,n.shadow)(this,"_keyboardManager",new a.KeyboardManager([[["ctrl+s","mac+meta+s","ctrl+p","mac+meta+p"],k.commitOrRemove,{bubbles:!0}],[["ctrl+Enter","mac+meta+Enter","Escape","mac+Escape"],k.commitOrRemove],[["ArrowLeft","mac+ArrowLeft"],k._translateEmpty,{args:[-$,0],checker:O}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],k._translateEmpty,{args:[-K,0],checker:O}],[["ArrowRight","mac+ArrowRight"],k._translateEmpty,{args:[$,0],checker:O}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],k._translateEmpty,{args:[K,0],checker:O}],[["ArrowUp","mac+ArrowUp"],k._translateEmpty,{args:[0,-$],checker:O}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],k._translateEmpty,{args:[0,-K],checker:O}],[["ArrowDown","mac+ArrowDown"],k._translateEmpty,{args:[0,$],checker:O}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],k._translateEmpty,{args:[0,K],checker:O}]]))}static initialize(k){s.AnnotationEditor.initialize(k,{strings:["free_text2_default_content","editor_free_text2_aria_label"]});const O=getComputedStyle(document.documentElement);this._internalPadding=parseFloat(O.getPropertyValue("--freetext-padding"))}static updateDefaultParams(k,O){switch(k){case n.AnnotationEditorParamsType.FREETEXT_SIZE:T._defaultFontSize=O;break;case n.AnnotationEditorParamsType.FREETEXT_COLOR:T._defaultColor=O;break}}updateParams(k,O){switch(k){case n.AnnotationEditorParamsType.FREETEXT_SIZE:te(this,m,Tr).call(this,O);break;case n.AnnotationEditorParamsType.FREETEXT_COLOR:te(this,m,_r).call(this,O);break}}static get defaultPropertiesToUpdate(){return[[n.AnnotationEditorParamsType.FREETEXT_SIZE,T._defaultFontSize],[n.AnnotationEditorParamsType.FREETEXT_COLOR,T._defaultColor||s.AnnotationEditor._defaultLineColor]]}get propertiesToUpdate(){return[[n.AnnotationEditorParamsType.FREETEXT_SIZE,b(this,y)],[n.AnnotationEditorParamsType.FREETEXT_COLOR,b(this,g)]]}_translateEmpty(k,O){this._uiManager.translateSelectedEditors(k,O,!0)}getInitialTranslation(){const k=this.parentScale;return[-T._internalPadding*k,-(T._internalPadding+b(this,y))*k]}rebuild(){this.parent&&(super.rebuild(),this.div!==null&&(this.isAttachedToDOM||this.parent.add(this)))}enableEditMode(){this.isInEditMode()||(this.parent.setEditingState(!1),this.parent.updateToolbar(n.AnnotationEditorType.FREETEXT),super.enableEditMode(),this.overlayDiv.classList.remove("enabled"),this.editorDiv.contentEditable=!0,this._isDraggable=!1,this.div.removeAttribute("aria-activedescendant"),this.editorDiv.addEventListener("keydown",b(this,p)),this.editorDiv.addEventListener("focus",b(this,l)),this.editorDiv.addEventListener("blur",b(this,d)),this.editorDiv.addEventListener("input",b(this,u)))}disableEditMode(){this.isInEditMode()&&(this.parent.setEditingState(!0),super.disableEditMode(),this.overlayDiv.classList.add("enabled"),this.editorDiv.contentEditable=!1,this.div.setAttribute("aria-activedescendant",b(this,v)),this._isDraggable=!0,this.editorDiv.removeEventListener("keydown",b(this,p)),this.editorDiv.removeEventListener("focus",b(this,l)),this.editorDiv.removeEventListener("blur",b(this,d)),this.editorDiv.removeEventListener("input",b(this,u)),this.div.focus({preventScroll:!0}),this.isEditing=!1,this.parent.div.classList.add("freeTextEditing"))}focusin(k){this._focusEventsAllowed&&(super.focusin(k),k.target!==this.editorDiv&&this.editorDiv.focus())}onceAdded(){var k;if(this.width){te(this,m,nr).call(this);return}this.enableEditMode(),this.editorDiv.focus(),(k=this._initialOptions)!=null&&k.isCentered&&this.center(),this._initialOptions=null}isEmpty(){return!this.editorDiv||this.editorDiv.innerText.trim()===""}remove(){this.isEditing=!1,this.parent&&(this.parent.setEditingState(!0),this.parent.div.classList.add("freeTextEditing")),super.remove()}commit(){if(!this.isInEditMode())return;super.commit(),this.disableEditMode();const k=b(this,f),O=ue(this,f,te(this,m,Rr).call(this).trimEnd());if(k===O)return;const $=K=>{if(ue(this,f,K),!K){this.remove();return}te(this,m,rr).call(this),this._uiManager.rebuild(this),te(this,m,yt).call(this)};this.addCommands({cmd:()=>{$(O)},undo:()=>{$(k)},mustExec:!1}),te(this,m,yt).call(this)}shouldGetKeyboardEvents(){return this.isInEditMode()}enterInEditMode(){this.enableEditMode(),this.editorDiv.focus()}dblclick(k){this.enterInEditMode()}keydown(k){k.target===this.div&&k.key==="Enter"&&(this.enterInEditMode(),k.preventDefault())}editorDivKeydown(k){T._keyboardManager.exec(this,k)}editorDivFocus(k){this.isEditing=!0}editorDivBlur(k){this.isEditing=!1}editorDivInput(k){this.parent.div.classList.toggle("freeTextEditing",this.isEmpty())}disableEditing(){this.editorDiv.setAttribute("role","comment"),this.editorDiv.removeAttribute("aria-multiline")}enableEditing(){this.editorDiv.setAttribute("role","textbox"),this.editorDiv.setAttribute("aria-multiline",!0)}render(){if(this.div)return this.div;let k,O;this.width&&(k=this.x,O=this.y),super.render(),this.editorDiv=document.createElement("div"),this.editorDiv.className="internal",this.editorDiv.setAttribute("id",b(this,v)),this.enableEditing(),s.AnnotationEditor._l10nPromise.get("editor_free_text2_aria_label").then(K=>{var J;return(J=this.editorDiv)==null?void 0:J.setAttribute("aria-label",K)}),s.AnnotationEditor._l10nPromise.get("free_text2_default_content").then(K=>{var J;return(J=this.editorDiv)==null?void 0:J.setAttribute("default-content",K)}),this.editorDiv.contentEditable=!0;const{style:$}=this.editorDiv;if($.fontSize=`calc(${b(this,y)}px * var(--scale-factor))`,$.color=b(this,g),this.div.append(this.editorDiv),this.overlayDiv=document.createElement("div"),this.overlayDiv.classList.add("overlay","enabled"),this.div.append(this.overlayDiv),(0,a.bindEvents)(this,this.div,["dblclick","keydown"]),this.width){const[K,J]=this.parentDimensions;if(this.annotationElementId){const{position:Y}=b(this,S);let[se,B]=this.getInitialTranslation();[se,B]=this.pageTranslationToScreen(se,B);const[V,Q]=this.pageDimensions,[N,P]=this.pageTranslation;let E,I;switch(this.rotation){case 0:E=k+(Y[0]-N)/V,I=O+this.height-(Y[1]-P)/Q;break;case 90:E=k+(Y[0]-N)/V,I=O-(Y[1]-P)/Q,[se,B]=[B,-se];break;case 180:E=k-this.width+(Y[0]-N)/V,I=O-(Y[1]-P)/Q,[se,B]=[-se,-B];break;case 270:E=k+(Y[0]-N-this.height*Q)/V,I=O+(Y[1]-P-this.width*V)/Q,[se,B]=[-B,se];break}this.setAt(E*K,I*J,se,B)}else this.setAt(k*K,O*J,this.width*K,this.height*J);te(this,m,rr).call(this),this._isDraggable=!0,this.editorDiv.contentEditable=!1}else this._isDraggable=!1,this.editorDiv.contentEditable=!0;return this.div}get contentDiv(){return this.editorDiv}static deserialize(k,O,$){let K=null;if(k instanceof o.FreeTextAnnotationElement){const{data:{defaultAppearanceData:{fontSize:Y,fontColor:se},rect:B,rotation:V,id:Q},textContent:N,textPosition:P,parent:{page:{pageNumber:E}}}=k;if(!N||N.length===0)return null;K=k={annotationType:n.AnnotationEditorType.FREETEXT,color:Array.from(se),fontSize:Y,value:N.join(`
|
|
5
|
+
`),position:P,pageIndex:E-1,rect:B,rotation:V,id:Q,deleted:!1}}const J=super.deserialize(k,O,$);return ue(J,y,k.fontSize),ue(J,g,n.Util.makeHexColor(...k.color)),ue(J,f,k.value),J.annotationElementId=k.id||null,ue(J,S,K),J}serialize(k=!1){if(this.isEmpty())return null;if(this.deleted)return{pageIndex:this.pageIndex,id:this.annotationElementId,deleted:!0};const O=T._internalPadding*this.parentScale,$=this.getRect(O,O),K=s.AnnotationEditor._colorManager.convert(this.isAttachedToDOM?getComputedStyle(this.editorDiv).color:b(this,g)),J={annotationType:n.AnnotationEditorType.FREETEXT,color:K,fontSize:b(this,y),value:b(this,f),pageIndex:this.pageIndex,rect:$,rotation:this.rotation,structTreeParentId:this._structTreeParentId};return k?J:this.annotationElementId&&!te(this,m,kr).call(this,J)?null:(J.id=this.annotationElementId,J)}};d=new WeakMap,l=new WeakMap,u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakMap,S=new WeakMap,m=new WeakSet,Tr=function(k){const O=K=>{this.editorDiv.style.fontSize=`calc(${K}px * var(--scale-factor))`,this.translate(0,-(K-b(this,y))*this.parentScale),ue(this,y,K),te(this,m,yt).call(this)},$=b(this,y);this.addCommands({cmd:()=>{O(k)},undo:()=>{O($)},mustExec:!0,type:n.AnnotationEditorParamsType.FREETEXT_SIZE,overwriteIfSameType:!0,keepUndo:!0})},_r=function(k){const O=b(this,g);this.addCommands({cmd:()=>{ue(this,g,this.editorDiv.style.color=k)},undo:()=>{ue(this,g,this.editorDiv.style.color=O)},mustExec:!0,type:n.AnnotationEditorParamsType.FREETEXT_COLOR,overwriteIfSameType:!0,keepUndo:!0})},Rr=function(){const k=this.editorDiv.getElementsByTagName("div");if(k.length===0)return this.editorDiv.innerText;const O=[];for(const $ of k)O.push($.innerText.replace(/\r\n?|\n/,""));return O.join(`
|
|
6
6
|
`)},yt=function(){const[k,O]=this.parentDimensions;let $;if(this.isAttachedToDOM)$=this.div.getBoundingClientRect();else{const{currentLayer:K,div:J}=this,Y=J.style.display;J.style.display="hidden",K.div.append(this.div),$=J.getBoundingClientRect(),J.remove(),J.style.display=Y}this.rotation%180===this.parentRotation%180?(this.width=$.width/k,this.height=$.height/O):(this.width=$.height/k,this.height=$.width/O),this.fixAndSetPosition()},rr=function(){if(this.editorDiv.replaceChildren(),!!b(this,f))for(const k of b(this,f).split(`
|
|
7
|
-
`)){const O=document.createElement("div");O.append(k?document.createTextNode(k):document.createElement("br")),this.editorDiv.append(O)}},kr=function(k){const{value:O,fontSize:$,color:K,rect:J,pageIndex:Y}=b(this,x);return k.value!==O||k.fontSize!==$||k.rect.some((se,B)=>Math.abs(se-J[B])>=1)||k.color.some((se,B)=>se!==K[B])||k.pageIndex!==Y},nr=function(k=!1){if(!this.annotationElementId)return;if(te(this,m,yt).call(this),!k&&(this.width===0||this.height===0)){setTimeout(()=>te(this,m,nr).call(this,!0),0);return}const O=T._internalPadding*this.parentScale;b(this,x).rect=this.getRect(O,O)},$e(T,"_freeTextDefaultContent",""),$e(T,"_internalPadding",0),$e(T,"_defaultColor",null),$e(T,"_defaultFontSize",10),$e(T,"_type","freetext");let h=T;e.FreeTextEditor=h},(t,e,r)=>{var I,G,ot,Ir,ce,ve,me,xe,Se,Ce,ne,le,L,Z,re,he,ye,Fe,Pe,ie,_e,Te,Or,Et,ir,ar,Ee,Ie,ze,be,oe,ae,Re,sr,Ve,X,ge,ke,Nr,or;Object.defineProperty(e,"__esModule",{value:!0}),e.StampAnnotationElement=e.InkAnnotationElement=e.FreeTextAnnotationElement=e.AnnotationLayer=void 0;var n=r(1),a=r(6),s=r(3),o=r(30),h=r(31),d=r(32);const l=1e3,u=9,p=new WeakSet;function g(Ne){return{width:Ne[2]-Ne[0],height:Ne[3]-Ne[1]}}class f{static create(U){switch(U.data.annotationType){case n.AnnotationType.LINK:return new y(U);case n.AnnotationType.TEXT:return new x(U);case n.AnnotationType.WIDGET:switch(U.data.fieldType){case"Tx":return new w(U);case"Btn":return U.data.radioButton?new S(U):U.data.checkBox?new _(U):new F(U);case"Ch":return new A(U);case"Sig":return new R(U)}return new m(U);case n.AnnotationType.POPUP:return new D(U);case n.AnnotationType.FREETEXT:return new M(U);case n.AnnotationType.LINE:return new C(U);case n.AnnotationType.SQUARE:return new k(U);case n.AnnotationType.CIRCLE:return new O(U);case n.AnnotationType.POLYLINE:return new $(U);case n.AnnotationType.CARET:return new J(U);case n.AnnotationType.INK:return new Y(U);case n.AnnotationType.POLYGON:return new K(U);case n.AnnotationType.HIGHLIGHT:return new se(U);case n.AnnotationType.UNDERLINE:return new B(U);case n.AnnotationType.SQUIGGLY:return new V(U);case n.AnnotationType.STRIKEOUT:return new Q(U);case n.AnnotationType.STAMP:return new N(U);case n.AnnotationType.FILEATTACHMENT:return new P(U);default:return new v(U)}}}const z=class z{constructor(U,{isRenderable:j=!1,ignoreBorder:W=!1,createQuadrilaterals:fe=!1}={}){de(this,I,!1);this.isRenderable=j,this.data=U.data,this.layer=U.layer,this.linkService=U.linkService,this.downloadManager=U.downloadManager,this.imageResourcesPath=U.imageResourcesPath,this.renderForms=U.renderForms,this.svgFactory=U.svgFactory,this.annotationStorage=U.annotationStorage,this.enableScripting=U.enableScripting,this.hasJSActions=U.hasJSActions,this._fieldObjects=U.fieldObjects,this.parent=U.parent,j&&(this.container=this._createContainer(W)),fe&&this._createQuadrilaterals()}static _hasPopupData({titleObj:U,contentsObj:j,richText:W}){return!!(U!=null&&U.str||j!=null&&j.str||W!=null&&W.str)}get hasPopupData(){return z._hasPopupData(this.data)}_createContainer(U){const{data:j,parent:{page:W,viewport:fe}}=this,pe=document.createElement("section");pe.setAttribute("data-annotation-id",j.id),this instanceof m||(pe.tabIndex=l),pe.style.zIndex=this.parent.zIndex++,this.data.popupRef&&pe.setAttribute("aria-haspopup","dialog"),j.noRotate&&pe.classList.add("norotate");const{pageWidth:Ae,pageHeight:we,pageX:je,pageY:Le}=fe.rawDims;if(!j.rect||this instanceof D){const{rotation:Xe}=j;return!j.hasOwnCanvas&&Xe!==0&&this.setRotation(Xe,pe),pe}const{width:De,height:Ge}=g(j.rect),Oe=n.Util.normalizeRect([j.rect[0],W.view[3]-j.rect[1]+W.view[1],j.rect[2],W.view[3]-j.rect[3]+W.view[1]]);if(!U&&j.borderStyle.width>0){pe.style.borderWidth=`${j.borderStyle.width}px`;const Xe=j.borderStyle.horizontalCornerRadius,Ze=j.borderStyle.verticalCornerRadius;if(Xe>0||Ze>0){const Qe=`calc(${Xe}px * var(--scale-factor)) / calc(${Ze}px * var(--scale-factor))`;pe.style.borderRadius=Qe}else if(this instanceof S){const Qe=`calc(${De}px * var(--scale-factor)) / calc(${Ge}px * var(--scale-factor))`;pe.style.borderRadius=Qe}switch(j.borderStyle.style){case n.AnnotationBorderStyleType.SOLID:pe.style.borderStyle="solid";break;case n.AnnotationBorderStyleType.DASHED:pe.style.borderStyle="dashed";break;case n.AnnotationBorderStyleType.BEVELED:(0,n.warn)("Unimplemented border style: beveled");break;case n.AnnotationBorderStyleType.INSET:(0,n.warn)("Unimplemented border style: inset");break;case n.AnnotationBorderStyleType.UNDERLINE:pe.style.borderBottomStyle="solid";break}const Je=j.borderColor||null;Je?(ue(this,I,!0),pe.style.borderColor=n.Util.makeHexColor(Je[0]|0,Je[1]|0,Je[2]|0)):pe.style.borderWidth=0}pe.style.left=`${100*(Oe[0]-je)/Ae}%`,pe.style.top=`${100*(Oe[1]-Le)/we}%`;const{rotation:Ue}=j;return j.hasOwnCanvas||Ue===0?(pe.style.width=`${100*De/Ae}%`,pe.style.height=`${100*Ge/we}%`):this.setRotation(Ue,pe),pe}setRotation(U,j=this.container){if(!this.data.rect)return;const{pageWidth:W,pageHeight:fe}=this.parent.viewport.rawDims,{width:pe,height:Ae}=g(this.data.rect);let we,je;U%180===0?(we=100*pe/W,je=100*Ae/fe):(we=100*Ae/W,je=100*pe/fe),j.style.width=`${we}%`,j.style.height=`${je}%`,j.setAttribute("data-main-rotation",(360-U)%360)}get _commonActions(){const U=(j,W,fe)=>{const pe=fe.detail[j],Ae=pe[0],we=pe.slice(1);fe.target.style[W]=o.ColorConverters[`${Ae}_HTML`](we),this.annotationStorage.setValue(this.data.id,{[W]:o.ColorConverters[`${Ae}_rgb`](we)})};return(0,n.shadow)(this,"_commonActions",{display:j=>{const{display:W}=j.detail,fe=W%2===1;this.container.style.visibility=fe?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noView:fe,noPrint:W===1||W===2})},print:j=>{this.annotationStorage.setValue(this.data.id,{noPrint:!j.detail.print})},hidden:j=>{const{hidden:W}=j.detail;this.container.style.visibility=W?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noPrint:W,noView:W})},focus:j=>{setTimeout(()=>j.target.focus({preventScroll:!1}),0)},userName:j=>{j.target.title=j.detail.userName},readonly:j=>{j.target.disabled=j.detail.readonly},required:j=>{this._setRequired(j.target,j.detail.required)},bgColor:j=>{U("bgColor","backgroundColor",j)},fillColor:j=>{U("fillColor","backgroundColor",j)},fgColor:j=>{U("fgColor","color",j)},textColor:j=>{U("textColor","color",j)},borderColor:j=>{U("borderColor","borderColor",j)},strokeColor:j=>{U("strokeColor","borderColor",j)},rotation:j=>{const W=j.detail.rotation;this.setRotation(W),this.annotationStorage.setValue(this.data.id,{rotation:W})}})}_dispatchEventFromSandbox(U,j){const W=this._commonActions;for(const fe of Object.keys(j.detail)){const pe=U[fe]||W[fe];pe==null||pe(j)}}_setDefaultPropertiesFromJS(U){if(!this.enableScripting)return;const j=this.annotationStorage.getRawValue(this.data.id);if(!j)return;const W=this._commonActions;for(const[fe,pe]of Object.entries(j)){const Ae=W[fe];if(Ae){const we={detail:{[fe]:pe},target:U};Ae(we),delete j[fe]}}}_createQuadrilaterals(){if(!this.container)return;const{quadPoints:U}=this.data;if(!U)return;const[j,W,fe,pe]=this.data.rect;if(U.length===1){const[,{x:Ze,y:Je},{x:Qe,y:tt}]=U[0];if(fe===Ze&&pe===Je&&j===Qe&&W===tt)return}const{style:Ae}=this.container;let we;if(b(this,I)){const{borderColor:Ze,borderWidth:Je}=Ae;Ae.borderWidth=0,we=["url('data:image/svg+xml;utf8,",'<svg xmlns="http://www.w3.org/2000/svg"',' preserveAspectRatio="none" viewBox="0 0 1 1">',`<g fill="transparent" stroke="${Ze}" stroke-width="${Je}">`],this.container.classList.add("hasBorder")}const je=fe-j,Le=pe-W,{svgFactory:De}=this,Ge=De.createElement("svg");Ge.classList.add("quadrilateralsContainer"),Ge.setAttribute("width",0),Ge.setAttribute("height",0);const Oe=De.createElement("defs");Ge.append(Oe);const Ue=De.createElement("clipPath"),Xe=`clippath_${this.data.id}`;Ue.setAttribute("id",Xe),Ue.setAttribute("clipPathUnits","objectBoundingBox"),Oe.append(Ue);for(const[,{x:Ze,y:Je},{x:Qe,y:tt}]of U){const et=De.createElement("rect"),nt=(Qe-j)/je,at=(pe-Je)/Le,st=(Ze-Qe)/je,vr=(Je-tt)/Le;et.setAttribute("x",nt),et.setAttribute("y",at),et.setAttribute("width",st),et.setAttribute("height",vr),Ue.append(et),we==null||we.push(`<rect vector-effect="non-scaling-stroke" x="${nt}" y="${at}" width="${st}" height="${vr}"/>`)}b(this,I)&&(we.push("</g></svg>')"),Ae.backgroundImage=we.join("")),this.container.append(Ge),this.container.style.clipPath=`url(#${Xe})`}_createPopup(){const{container:U,data:j}=this;U.setAttribute("aria-haspopup","dialog");const W=new D({data:{color:j.color,titleObj:j.titleObj,modificationDate:j.modificationDate,contentsObj:j.contentsObj,richText:j.richText,parentRect:j.rect,borderStyle:0,id:`popup_${j.id}`,rotation:j.rotation},parent:this.parent,elements:[this]});this.parent.div.append(W.render())}render(){(0,n.unreachable)("Abstract method `AnnotationElement.render` called")}_getElementsByName(U,j=null){const W=[];if(this._fieldObjects){const fe=this._fieldObjects[U];if(fe)for(const{page:pe,id:Ae,exportValues:we}of fe){if(pe===-1||Ae===j)continue;const je=typeof we=="string"?we:null,Le=document.querySelector(`[data-element-id="${Ae}"]`);if(Le&&!p.has(Le)){(0,n.warn)(`_getElementsByName - element not allowed: ${Ae}`);continue}W.push({id:Ae,exportValue:je,domElement:Le})}return W}for(const fe of document.getElementsByName(U)){const{exportValue:pe}=fe,Ae=fe.getAttribute("data-element-id");Ae!==j&&p.has(fe)&&W.push({id:Ae,exportValue:pe,domElement:fe})}return W}show(){var U;this.container&&(this.container.hidden=!1),(U=this.popup)==null||U.maybeShow()}hide(){var U;this.container&&(this.container.hidden=!0),(U=this.popup)==null||U.forceHide()}getElementsToTriggerPopup(){return this.container}addHighlightArea(){const U=this.getElementsToTriggerPopup();if(Array.isArray(U))for(const j of U)j.classList.add("highlightArea");else U.classList.add("highlightArea")}_editOnDoubleClick(){const{annotationEditorType:U,data:{id:j}}=this;this.container.addEventListener("dblclick",()=>{var W;(W=this.linkService.eventBus)==null||W.dispatch("switchannotationeditormode",{source:this,mode:U,editId:j})})}};I=new WeakMap;let v=z;class y extends v{constructor(j,W=null){super(j,{isRenderable:!0,ignoreBorder:!!(W!=null&&W.ignoreBorder),createQuadrilaterals:!0});de(this,G);this.isTooltipOnly=j.data.isTooltipOnly}render(){const{data:j,linkService:W}=this,fe=document.createElement("a");fe.setAttribute("data-element-id",j.id);let pe=!1;return j.url?(W.addLinkAttributes(fe,j.url,j.newWindow),pe=!0):j.action?(this._bindNamedAction(fe,j.action),pe=!0):j.attachment?(this._bindAttachment(fe,j.attachment),pe=!0):j.setOCGState?(te(this,G,Ir).call(this,fe,j.setOCGState),pe=!0):j.dest?(this._bindLink(fe,j.dest),pe=!0):(j.actions&&(j.actions.Action||j.actions["Mouse Up"]||j.actions["Mouse Down"])&&this.enableScripting&&this.hasJSActions&&(this._bindJSAction(fe,j),pe=!0),j.resetForm?(this._bindResetFormAction(fe,j.resetForm),pe=!0):this.isTooltipOnly&&!pe&&(this._bindLink(fe,""),pe=!0)),this.container.classList.add("linkAnnotation"),pe&&this.container.append(fe),this.container}_bindLink(j,W){j.href=this.linkService.getDestinationHash(W),j.onclick=()=>(W&&this.linkService.goToDestination(W),!1),(W||W==="")&&te(this,G,ot).call(this)}_bindNamedAction(j,W){j.href=this.linkService.getAnchorUrl(""),j.onclick=()=>(this.linkService.executeNamedAction(W),!1),te(this,G,ot).call(this)}_bindAttachment(j,W){j.href=this.linkService.getAnchorUrl(""),j.onclick=()=>{var fe;return(fe=this.downloadManager)==null||fe.openOrDownloadData(this.container,W.content,W.filename),!1},te(this,G,ot).call(this)}_bindJSAction(j,W){j.href=this.linkService.getAnchorUrl("");const fe=new Map([["Action","onclick"],["Mouse Up","onmouseup"],["Mouse Down","onmousedown"]]);for(const pe of Object.keys(W.actions)){const Ae=fe.get(pe);Ae&&(j[Ae]=()=>{var we;return(we=this.linkService.eventBus)==null||we.dispatch("dispatcheventinsandbox",{source:this,detail:{id:W.id,name:pe}}),!1})}j.onclick||(j.onclick=()=>!1),te(this,G,ot).call(this)}_bindResetFormAction(j,W){const fe=j.onclick;if(fe||(j.href=this.linkService.getAnchorUrl("")),te(this,G,ot).call(this),!this._fieldObjects){(0,n.warn)('_bindResetFormAction - "resetForm" action not supported, ensure that the `fieldObjects` parameter is provided.'),fe||(j.onclick=()=>!1);return}j.onclick=()=>{var Ge;fe==null||fe();const{fields:pe,refs:Ae,include:we}=W,je=[];if(pe.length!==0||Ae.length!==0){const Oe=new Set(Ae);for(const Ue of pe){const Xe=this._fieldObjects[Ue]||[];for(const{id:Ze}of Xe)Oe.add(Ze)}for(const Ue of Object.values(this._fieldObjects))for(const Xe of Ue)Oe.has(Xe.id)===we&&je.push(Xe)}else for(const Oe of Object.values(this._fieldObjects))je.push(...Oe);const Le=this.annotationStorage,De=[];for(const Oe of je){const{id:Ue}=Oe;switch(De.push(Ue),Oe.type){case"text":{const Ze=Oe.defaultValue||"";Le.setValue(Ue,{value:Ze});break}case"checkbox":case"radiobutton":{const Ze=Oe.defaultValue===Oe.exportValues;Le.setValue(Ue,{value:Ze});break}case"combobox":case"listbox":{const Ze=Oe.defaultValue||"";Le.setValue(Ue,{value:Ze});break}default:continue}const Xe=document.querySelector(`[data-element-id="${Ue}"]`);if(Xe){if(!p.has(Xe)){(0,n.warn)(`_bindResetFormAction - element not allowed: ${Ue}`);continue}}else continue;Xe.dispatchEvent(new Event("resetform"))}return this.enableScripting&&((Ge=this.linkService.eventBus)==null||Ge.dispatch("dispatcheventinsandbox",{source:this,detail:{id:"app",ids:De,name:"ResetForm"}})),!1}}}G=new WeakSet,ot=function(){this.container.setAttribute("data-internal-link","")},Ir=function(j,W){j.href=this.linkService.getAnchorUrl(""),j.onclick=()=>(this.linkService.executeSetOCGState(W),!1),te(this,G,ot).call(this)};class x extends v{constructor(U){super(U,{isRenderable:!0})}render(){this.container.classList.add("textAnnotation");const U=document.createElement("img");return U.src=this.imageResourcesPath+"annotation-"+this.data.name.toLowerCase()+".svg",U.alt="[{{type}} Annotation]",U.dataset.l10nId="text_annotation_type",U.dataset.l10nArgs=JSON.stringify({type:this.data.name}),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.append(U),this.container}}class m extends v{render(){return this.data.alternativeText&&(this.container.title=this.data.alternativeText),this.container}showElementAndHideCanvas(U){var j;this.data.hasOwnCanvas&&(((j=U.previousSibling)==null?void 0:j.nodeName)==="CANVAS"&&(U.previousSibling.hidden=!0),U.hidden=!1)}_getKeyModifier(U){const{isWin:j,isMac:W}=n.FeatureTest.platform;return j&&U.ctrlKey||W&&U.metaKey}_setEventListener(U,j,W,fe,pe){W.includes("mouse")?U.addEventListener(W,Ae=>{var we;(we=this.linkService.eventBus)==null||we.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:fe,value:pe(Ae),shift:Ae.shiftKey,modifier:this._getKeyModifier(Ae)}})}):U.addEventListener(W,Ae=>{var we;if(W==="blur"){if(!j.focused||!Ae.relatedTarget)return;j.focused=!1}else if(W==="focus"){if(j.focused)return;j.focused=!0}pe&&((we=this.linkService.eventBus)==null||we.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:fe,value:pe(Ae)}}))})}_setEventListeners(U,j,W,fe){var pe,Ae,we;for(const[je,Le]of W)(Le==="Action"||(pe=this.data.actions)!=null&&pe[Le])&&((Le==="Focus"||Le==="Blur")&&(j||(j={focused:!1})),this._setEventListener(U,j,je,Le,fe),Le==="Focus"&&!((Ae=this.data.actions)!=null&&Ae.Blur)?this._setEventListener(U,j,"blur","Blur",null):Le==="Blur"&&!((we=this.data.actions)!=null&&we.Focus)&&this._setEventListener(U,j,"focus","Focus",null))}_setBackgroundColor(U){const j=this.data.backgroundColor||null;U.style.backgroundColor=j===null?"transparent":n.Util.makeHexColor(j[0],j[1],j[2])}_setTextStyle(U){const j=["left","center","right"],{fontColor:W}=this.data.defaultAppearanceData,fe=this.data.defaultAppearanceData.fontSize||u,pe=U.style;let Ae;const we=2,je=Le=>Math.round(10*Le)/10;if(this.data.multiLine){const Le=Math.abs(this.data.rect[3]-this.data.rect[1]-we),De=Math.round(Le/(n.LINE_FACTOR*fe))||1,Ge=Le/De;Ae=Math.min(fe,je(Ge/n.LINE_FACTOR))}else{const Le=Math.abs(this.data.rect[3]-this.data.rect[1]-we);Ae=Math.min(fe,je(Le/n.LINE_FACTOR))}pe.fontSize=`calc(${Ae}px * var(--scale-factor))`,pe.color=n.Util.makeHexColor(W[0],W[1],W[2]),this.data.textAlignment!==null&&(pe.textAlign=j[this.data.textAlignment])}_setRequired(U,j){j?U.setAttribute("required",!0):U.removeAttribute("required"),U.setAttribute("aria-required",j)}}class w extends m{constructor(U){const j=U.renderForms||!U.data.hasAppearance&&!!U.data.fieldValue;super(U,{isRenderable:j})}setPropertyOnSiblings(U,j,W,fe){const pe=this.annotationStorage;for(const Ae of this._getElementsByName(U.name,U.id))Ae.domElement&&(Ae.domElement[j]=W),pe.setValue(Ae.id,{[fe]:W})}render(){var fe,pe;const U=this.annotationStorage,j=this.data.id;this.container.classList.add("textWidgetAnnotation");let W=null;if(this.renderForms){const Ae=U.getValue(j,{value:this.data.fieldValue});let we=Ae.value||"";const je=U.getValue(j,{charLimit:this.data.maxLen}).charLimit;je&&we.length>je&&(we=we.slice(0,je));let Le=Ae.formattedValue||((fe=this.data.textContent)==null?void 0:fe.join(`
|
|
8
|
-
`))||null;Le&&this.data.comb&&(Le=Le.replaceAll(/\s+/g,""));const De={userValue:we,formattedValue:Le,lastCommittedValue:null,commitKey:1,focused:!1};this.data.multiLine?(W=document.createElement("textarea"),W.textContent=Le??we,this.data.doNotScroll&&(W.style.overflowY="hidden")):(W=document.createElement("input"),W.type="text",W.setAttribute("value",Le??we),this.data.doNotScroll&&(W.style.overflowX="hidden")),this.data.hasOwnCanvas&&(W.hidden=!0),p.add(W),W.setAttribute("data-element-id",j),W.disabled=this.data.readOnly,W.name=this.data.fieldName,W.tabIndex=l,this._setRequired(W,this.data.required),je&&(W.maxLength=je),W.addEventListener("input",Oe=>{U.setValue(j,{value:Oe.target.value}),this.setPropertyOnSiblings(W,"value",Oe.target.value,"value"),De.formattedValue=null}),W.addEventListener("resetform",Oe=>{const Ue=this.data.defaultFieldValue??"";W.value=De.userValue=Ue,De.formattedValue=null});let Ge=Oe=>{const{formattedValue:Ue}=De;Ue!=null&&(Oe.target.value=Ue),Oe.target.scrollLeft=0};if(this.enableScripting&&this.hasJSActions){W.addEventListener("focus",Ue=>{if(De.focused)return;const{target:Xe}=Ue;De.userValue&&(Xe.value=De.userValue),De.lastCommittedValue=Xe.value,De.commitKey=1,De.focused=!0}),W.addEventListener("updatefromsandbox",Ue=>{this.showElementAndHideCanvas(Ue.target);const Xe={value(Ze){De.userValue=Ze.detail.value??"",U.setValue(j,{value:De.userValue.toString()}),Ze.target.value=De.userValue},formattedValue(Ze){const{formattedValue:Je}=Ze.detail;De.formattedValue=Je,Je!=null&&Ze.target!==document.activeElement&&(Ze.target.value=Je),U.setValue(j,{formattedValue:Je})},selRange(Ze){Ze.target.setSelectionRange(...Ze.detail.selRange)},charLimit:Ze=>{var et;const{charLimit:Je}=Ze.detail,{target:Qe}=Ze;if(Je===0){Qe.removeAttribute("maxLength");return}Qe.setAttribute("maxLength",Je);let tt=De.userValue;!tt||tt.length<=Je||(tt=tt.slice(0,Je),Qe.value=De.userValue=tt,U.setValue(j,{value:tt}),(et=this.linkService.eventBus)==null||et.dispatch("dispatcheventinsandbox",{source:this,detail:{id:j,name:"Keystroke",value:tt,willCommit:!0,commitKey:1,selStart:Qe.selectionStart,selEnd:Qe.selectionEnd}}))}};this._dispatchEventFromSandbox(Xe,Ue)}),W.addEventListener("keydown",Ue=>{var Je;De.commitKey=1;let Xe=-1;if(Ue.key==="Escape"?Xe=0:Ue.key==="Enter"&&!this.data.multiLine?Xe=2:Ue.key==="Tab"&&(De.commitKey=3),Xe===-1)return;const{value:Ze}=Ue.target;De.lastCommittedValue!==Ze&&(De.lastCommittedValue=Ze,De.userValue=Ze,(Je=this.linkService.eventBus)==null||Je.dispatch("dispatcheventinsandbox",{source:this,detail:{id:j,name:"Keystroke",value:Ze,willCommit:!0,commitKey:Xe,selStart:Ue.target.selectionStart,selEnd:Ue.target.selectionEnd}}))});const Oe=Ge;Ge=null,W.addEventListener("blur",Ue=>{var Ze;if(!De.focused||!Ue.relatedTarget)return;De.focused=!1;const{value:Xe}=Ue.target;De.userValue=Xe,De.lastCommittedValue!==Xe&&((Ze=this.linkService.eventBus)==null||Ze.dispatch("dispatcheventinsandbox",{source:this,detail:{id:j,name:"Keystroke",value:Xe,willCommit:!0,commitKey:De.commitKey,selStart:Ue.target.selectionStart,selEnd:Ue.target.selectionEnd}})),Oe(Ue)}),(pe=this.data.actions)!=null&&pe.Keystroke&&W.addEventListener("beforeinput",Ue=>{var at;De.lastCommittedValue=null;const{data:Xe,target:Ze}=Ue,{value:Je,selectionStart:Qe,selectionEnd:tt}=Ze;let et=Qe,nt=tt;switch(Ue.inputType){case"deleteWordBackward":{const st=Je.substring(0,Qe).match(/\w*[^\w]*$/);st&&(et-=st[0].length);break}case"deleteWordForward":{const st=Je.substring(Qe).match(/^[^\w]*\w*/);st&&(nt+=st[0].length);break}case"deleteContentBackward":Qe===tt&&(et-=1);break;case"deleteContentForward":Qe===tt&&(nt+=1);break}Ue.preventDefault(),(at=this.linkService.eventBus)==null||at.dispatch("dispatcheventinsandbox",{source:this,detail:{id:j,name:"Keystroke",value:Je,change:Xe||"",willCommit:!1,selStart:et,selEnd:nt}})}),this._setEventListeners(W,De,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],Ue=>Ue.target.value)}if(Ge&&W.addEventListener("blur",Ge),this.data.comb){const Ue=(this.data.rect[2]-this.data.rect[0])/je;W.classList.add("comb"),W.style.letterSpacing=`calc(${Ue}px * var(--scale-factor) - 1ch)`}}else W=document.createElement("div"),W.textContent=this.data.fieldValue,W.style.verticalAlign="middle",W.style.display="table-cell";return this._setTextStyle(W),this._setBackgroundColor(W),this._setDefaultPropertiesFromJS(W),this.container.append(W),this.container}}class R extends m{constructor(U){super(U,{isRenderable:!!U.data.hasOwnCanvas})}}class _ extends m{constructor(U){super(U,{isRenderable:U.renderForms})}render(){const U=this.annotationStorage,j=this.data,W=j.id;let fe=U.getValue(W,{value:j.exportValue===j.fieldValue}).value;typeof fe=="string"&&(fe=fe!=="Off",U.setValue(W,{value:fe})),this.container.classList.add("buttonWidgetAnnotation","checkBox");const pe=document.createElement("input");return p.add(pe),pe.setAttribute("data-element-id",W),pe.disabled=j.readOnly,this._setRequired(pe,this.data.required),pe.type="checkbox",pe.name=j.fieldName,fe&&pe.setAttribute("checked",!0),pe.setAttribute("exportValue",j.exportValue),pe.tabIndex=l,pe.addEventListener("change",Ae=>{const{name:we,checked:je}=Ae.target;for(const Le of this._getElementsByName(we,W)){const De=je&&Le.exportValue===j.exportValue;Le.domElement&&(Le.domElement.checked=De),U.setValue(Le.id,{value:De})}U.setValue(W,{value:je})}),pe.addEventListener("resetform",Ae=>{const we=j.defaultFieldValue||"Off";Ae.target.checked=we===j.exportValue}),this.enableScripting&&this.hasJSActions&&(pe.addEventListener("updatefromsandbox",Ae=>{const we={value(je){je.target.checked=je.detail.value!=="Off",U.setValue(W,{value:je.target.checked})}};this._dispatchEventFromSandbox(we,Ae)}),this._setEventListeners(pe,null,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],Ae=>Ae.target.checked)),this._setBackgroundColor(pe),this._setDefaultPropertiesFromJS(pe),this.container.append(pe),this.container}}class S extends m{constructor(U){super(U,{isRenderable:U.renderForms})}render(){this.container.classList.add("buttonWidgetAnnotation","radioButton");const U=this.annotationStorage,j=this.data,W=j.id;let fe=U.getValue(W,{value:j.fieldValue===j.buttonValue}).value;typeof fe=="string"&&(fe=fe!==j.buttonValue,U.setValue(W,{value:fe}));const pe=document.createElement("input");if(p.add(pe),pe.setAttribute("data-element-id",W),pe.disabled=j.readOnly,this._setRequired(pe,this.data.required),pe.type="radio",pe.name=j.fieldName,fe&&pe.setAttribute("checked",!0),pe.tabIndex=l,pe.addEventListener("change",Ae=>{const{name:we,checked:je}=Ae.target;for(const Le of this._getElementsByName(we,W))U.setValue(Le.id,{value:!1});U.setValue(W,{value:je})}),pe.addEventListener("resetform",Ae=>{const we=j.defaultFieldValue;Ae.target.checked=we!=null&&we===j.buttonValue}),this.enableScripting&&this.hasJSActions){const Ae=j.buttonValue;pe.addEventListener("updatefromsandbox",we=>{const je={value:Le=>{const De=Ae===Le.detail.value;for(const Ge of this._getElementsByName(Le.target.name)){const Oe=De&&Ge.id===W;Ge.domElement&&(Ge.domElement.checked=Oe),U.setValue(Ge.id,{value:Oe})}}};this._dispatchEventFromSandbox(je,we)}),this._setEventListeners(pe,null,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],we=>we.target.checked)}return this._setBackgroundColor(pe),this._setDefaultPropertiesFromJS(pe),this.container.append(pe),this.container}}class F extends y{constructor(U){super(U,{ignoreBorder:U.data.hasAppearance})}render(){const U=super.render();U.classList.add("buttonWidgetAnnotation","pushButton"),this.data.alternativeText&&(U.title=this.data.alternativeText);const j=U.lastChild;return this.enableScripting&&this.hasJSActions&&j&&(this._setDefaultPropertiesFromJS(j),j.addEventListener("updatefromsandbox",W=>{this._dispatchEventFromSandbox({},W)})),U}}class A extends m{constructor(U){super(U,{isRenderable:U.renderForms})}render(){this.container.classList.add("choiceWidgetAnnotation");const U=this.annotationStorage,j=this.data.id,W=U.getValue(j,{value:this.data.fieldValue}),fe=document.createElement("select");p.add(fe),fe.setAttribute("data-element-id",j),fe.disabled=this.data.readOnly,this._setRequired(fe,this.data.required),fe.name=this.data.fieldName,fe.tabIndex=l;let pe=this.data.combo&&this.data.options.length>0;this.data.combo||(fe.size=this.data.options.length,this.data.multiSelect&&(fe.multiple=!0)),fe.addEventListener("resetform",De=>{const Ge=this.data.defaultFieldValue;for(const Oe of fe.options)Oe.selected=Oe.value===Ge});for(const De of this.data.options){const Ge=document.createElement("option");Ge.textContent=De.displayValue,Ge.value=De.exportValue,W.value.includes(De.exportValue)&&(Ge.setAttribute("selected",!0),pe=!1),fe.append(Ge)}let Ae=null;if(pe){const De=document.createElement("option");De.value=" ",De.setAttribute("hidden",!0),De.setAttribute("selected",!0),fe.prepend(De),Ae=()=>{De.remove(),fe.removeEventListener("input",Ae),Ae=null},fe.addEventListener("input",Ae)}const we=De=>{const Ge=De?"value":"textContent",{options:Oe,multiple:Ue}=fe;return Ue?Array.prototype.filter.call(Oe,Xe=>Xe.selected).map(Xe=>Xe[Ge]):Oe.selectedIndex===-1?null:Oe[Oe.selectedIndex][Ge]};let je=we(!1);const Le=De=>{const Ge=De.target.options;return Array.prototype.map.call(Ge,Oe=>({displayValue:Oe.textContent,exportValue:Oe.value}))};return this.enableScripting&&this.hasJSActions?(fe.addEventListener("updatefromsandbox",De=>{const Ge={value(Oe){Ae==null||Ae();const Ue=Oe.detail.value,Xe=new Set(Array.isArray(Ue)?Ue:[Ue]);for(const Ze of fe.options)Ze.selected=Xe.has(Ze.value);U.setValue(j,{value:we(!0)}),je=we(!1)},multipleSelection(Oe){fe.multiple=!0},remove(Oe){const Ue=fe.options,Xe=Oe.detail.remove;Ue[Xe].selected=!1,fe.remove(Xe),Ue.length>0&&Array.prototype.findIndex.call(Ue,Je=>Je.selected)===-1&&(Ue[0].selected=!0),U.setValue(j,{value:we(!0),items:Le(Oe)}),je=we(!1)},clear(Oe){for(;fe.length!==0;)fe.remove(0);U.setValue(j,{value:null,items:[]}),je=we(!1)},insert(Oe){const{index:Ue,displayValue:Xe,exportValue:Ze}=Oe.detail.insert,Je=fe.children[Ue],Qe=document.createElement("option");Qe.textContent=Xe,Qe.value=Ze,Je?Je.before(Qe):fe.append(Qe),U.setValue(j,{value:we(!0),items:Le(Oe)}),je=we(!1)},items(Oe){const{items:Ue}=Oe.detail;for(;fe.length!==0;)fe.remove(0);for(const Xe of Ue){const{displayValue:Ze,exportValue:Je}=Xe,Qe=document.createElement("option");Qe.textContent=Ze,Qe.value=Je,fe.append(Qe)}fe.options.length>0&&(fe.options[0].selected=!0),U.setValue(j,{value:we(!0),items:Le(Oe)}),je=we(!1)},indices(Oe){const Ue=new Set(Oe.detail.indices);for(const Xe of Oe.target.options)Xe.selected=Ue.has(Xe.index);U.setValue(j,{value:we(!0)}),je=we(!1)},editable(Oe){Oe.target.disabled=!Oe.detail.editable}};this._dispatchEventFromSandbox(Ge,De)}),fe.addEventListener("input",De=>{var Oe;const Ge=we(!0);U.setValue(j,{value:Ge}),De.preventDefault(),(Oe=this.linkService.eventBus)==null||Oe.dispatch("dispatcheventinsandbox",{source:this,detail:{id:j,name:"Keystroke",value:je,changeEx:Ge,willCommit:!1,commitKey:1,keyDown:!1}})}),this._setEventListeners(fe,null,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"],["input","Action"],["input","Validate"]],De=>De.target.value)):fe.addEventListener("input",function(De){U.setValue(j,{value:we(!0)})}),this.data.combo&&this._setTextStyle(fe),this._setBackgroundColor(fe),this._setDefaultPropertiesFromJS(fe),this.container.append(fe),this.container}}class D extends v{constructor(U){const{data:j,elements:W}=U;super(U,{isRenderable:v._hasPopupData(j)}),this.elements=W}render(){this.container.classList.add("popupAnnotation");const U=new T({container:this.container,color:this.data.color,titleObj:this.data.titleObj,modificationDate:this.data.modificationDate,contentsObj:this.data.contentsObj,richText:this.data.richText,rect:this.data.rect,parentRect:this.data.parentRect||null,parent:this.parent,elements:this.elements,open:this.data.open}),j=[];for(const W of this.elements)W.popup=U,j.push(W.data.id),W.addHighlightArea();return this.container.setAttribute("aria-controls",j.map(W=>`${n.AnnotationPrefix}${W}`).join(",")),this.container}}class T{constructor({container:U,color:j,elements:W,titleObj:fe,modificationDate:pe,contentsObj:Ae,richText:we,parent:je,rect:Le,parentRect:De,open:Ge}){de(this,Te);de(this,ce,null);de(this,ve,te(this,Te,Or).bind(this));de(this,me,te(this,Te,ar).bind(this));de(this,xe,te(this,Te,ir).bind(this));de(this,Se,te(this,Te,Et).bind(this));de(this,Ce,null);de(this,ne,null);de(this,le,null);de(this,L,null);de(this,Z,null);de(this,re,null);de(this,he,!1);de(this,ye,null);de(this,Fe,null);de(this,Pe,null);de(this,ie,null);de(this,_e,!1);var Ue;ue(this,ne,U),ue(this,ie,fe),ue(this,le,Ae),ue(this,Pe,we),ue(this,Z,je),ue(this,Ce,j),ue(this,Fe,Le),ue(this,re,De),ue(this,L,W);const Oe=a.PDFDateString.toDateObject(pe);Oe&&ue(this,ce,je.l10n.get("annotation_date_string",{date:Oe.toLocaleDateString(),time:Oe.toLocaleTimeString()})),this.trigger=W.flatMap(Xe=>Xe.getElementsToTriggerPopup());for(const Xe of this.trigger)Xe.addEventListener("click",b(this,Se)),Xe.addEventListener("mouseenter",b(this,xe)),Xe.addEventListener("mouseleave",b(this,me)),Xe.classList.add("popupTriggerArea");for(const Xe of W)(Ue=Xe.container)==null||Ue.addEventListener("keydown",b(this,ve));b(this,ne).hidden=!0,Ge&&te(this,Te,Et).call(this)}render(){if(b(this,ye))return;const{page:{view:U},viewport:{rawDims:{pageWidth:j,pageHeight:W,pageX:fe,pageY:pe}}}=b(this,Z),Ae=ue(this,ye,document.createElement("div"));if(Ae.className="popup",b(this,Ce)){const et=Ae.style.outlineColor=n.Util.makeHexColor(...b(this,Ce));CSS.supports("background-color","color-mix(in srgb, red 30%, white)")?Ae.style.backgroundColor=`color-mix(in srgb, ${et} 30%, white)`:Ae.style.backgroundColor=n.Util.makeHexColor(...b(this,Ce).map(at=>Math.floor(.7*(255-at)+at)))}const we=document.createElement("span");we.className="header";const je=document.createElement("h1");if(we.append(je),{dir:je.dir,str:je.textContent}=b(this,ie),Ae.append(we),b(this,ce)){const et=document.createElement("span");et.classList.add("popupDate"),b(this,ce).then(nt=>{et.textContent=nt}),we.append(et)}const Le=b(this,le),De=b(this,Pe);if(De!=null&&De.str&&(!(Le!=null&&Le.str)||Le.str===De.str))d.XfaLayer.render({xfaHtml:De.html,intent:"richText",div:Ae}),Ae.lastChild.classList.add("richText","popupContent");else{const et=this._formatContents(Le);Ae.append(et)}let Ge=!!b(this,re),Oe=Ge?b(this,re):b(this,Fe);for(const et of b(this,L))if(!Oe||n.Util.intersect(et.data.rect,Oe)!==null){Oe=et.data.rect,Ge=!0;break}const Ue=n.Util.normalizeRect([Oe[0],U[3]-Oe[1]+U[1],Oe[2],U[3]-Oe[3]+U[1]]),Ze=Ge?Oe[2]-Oe[0]+5:0,Je=Ue[0]+Ze,Qe=Ue[1],{style:tt}=b(this,ne);tt.left=`${100*(Je-fe)/j}%`,tt.top=`${100*(Qe-pe)/W}%`,b(this,ne).append(Ae)}_formatContents({str:U,dir:j}){const W=document.createElement("p");W.classList.add("popupContent"),W.dir=j;const fe=U.split(/(?:\r\n?|\n)/);for(let pe=0,Ae=fe.length;pe<Ae;++pe){const we=fe[pe];W.append(document.createTextNode(we)),pe<Ae-1&&W.append(document.createElement("br"))}return W}forceHide(){ue(this,_e,this.isVisible),b(this,_e)&&(b(this,ne).hidden=!0)}maybeShow(){b(this,_e)&&(ue(this,_e,!1),b(this,ne).hidden=!1)}get isVisible(){return b(this,ne).hidden===!1}}ce=new WeakMap,ve=new WeakMap,me=new WeakMap,xe=new WeakMap,Se=new WeakMap,Ce=new WeakMap,ne=new WeakMap,le=new WeakMap,L=new WeakMap,Z=new WeakMap,re=new WeakMap,he=new WeakMap,ye=new WeakMap,Fe=new WeakMap,Pe=new WeakMap,ie=new WeakMap,_e=new WeakMap,Te=new WeakSet,Or=function(U){U.altKey||U.shiftKey||U.ctrlKey||U.metaKey||(U.key==="Enter"||U.key==="Escape"&&b(this,he))&&te(this,Te,Et).call(this)},Et=function(){ue(this,he,!b(this,he)),b(this,he)?(te(this,Te,ir).call(this),b(this,ne).addEventListener("click",b(this,Se)),b(this,ne).addEventListener("keydown",b(this,ve))):(te(this,Te,ar).call(this),b(this,ne).removeEventListener("click",b(this,Se)),b(this,ne).removeEventListener("keydown",b(this,ve)))},ir=function(){b(this,ye)||this.render(),this.isVisible?b(this,he)&&b(this,ne).classList.add("focused"):(b(this,ne).hidden=!1,b(this,ne).style.zIndex=parseInt(b(this,ne).style.zIndex)+1e3)},ar=function(){b(this,ne).classList.remove("focused"),!(b(this,he)||!this.isVisible)&&(b(this,ne).hidden=!0,b(this,ne).style.zIndex=parseInt(b(this,ne).style.zIndex)-1e3)};class M extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0}),this.textContent=U.data.textContent,this.textPosition=U.data.textPosition,this.annotationEditorType=n.AnnotationEditorType.FREETEXT}render(){if(this.container.classList.add("freeTextAnnotation"),this.textContent){const U=document.createElement("div");U.classList.add("annotationTextContent"),U.setAttribute("role","comment");for(const j of this.textContent){const W=document.createElement("span");W.textContent=j,U.append(W)}this.container.append(U)}return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this._editOnDoubleClick(),this.container}}e.FreeTextAnnotationElement=M;class C extends v{constructor(j){super(j,{isRenderable:!0,ignoreBorder:!0});de(this,Ee,null)}render(){this.container.classList.add("lineAnnotation");const j=this.data,{width:W,height:fe}=g(j.rect),pe=this.svgFactory.create(W,fe,!0),Ae=ue(this,Ee,this.svgFactory.createElement("svg:line"));return Ae.setAttribute("x1",j.rect[2]-j.lineCoordinates[0]),Ae.setAttribute("y1",j.rect[3]-j.lineCoordinates[1]),Ae.setAttribute("x2",j.rect[2]-j.lineCoordinates[2]),Ae.setAttribute("y2",j.rect[3]-j.lineCoordinates[3]),Ae.setAttribute("stroke-width",j.borderStyle.width||1),Ae.setAttribute("stroke","transparent"),Ae.setAttribute("fill","transparent"),pe.append(Ae),this.container.append(pe),!j.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return b(this,Ee)}addHighlightArea(){this.container.classList.add("highlightArea")}}Ee=new WeakMap;class k extends v{constructor(j){super(j,{isRenderable:!0,ignoreBorder:!0});de(this,Ie,null)}render(){this.container.classList.add("squareAnnotation");const j=this.data,{width:W,height:fe}=g(j.rect),pe=this.svgFactory.create(W,fe,!0),Ae=j.borderStyle.width,we=ue(this,Ie,this.svgFactory.createElement("svg:rect"));return we.setAttribute("x",Ae/2),we.setAttribute("y",Ae/2),we.setAttribute("width",W-Ae),we.setAttribute("height",fe-Ae),we.setAttribute("stroke-width",Ae||1),we.setAttribute("stroke","transparent"),we.setAttribute("fill","transparent"),pe.append(we),this.container.append(pe),!j.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return b(this,Ie)}addHighlightArea(){this.container.classList.add("highlightArea")}}Ie=new WeakMap;class O extends v{constructor(j){super(j,{isRenderable:!0,ignoreBorder:!0});de(this,ze,null)}render(){this.container.classList.add("circleAnnotation");const j=this.data,{width:W,height:fe}=g(j.rect),pe=this.svgFactory.create(W,fe,!0),Ae=j.borderStyle.width,we=ue(this,ze,this.svgFactory.createElement("svg:ellipse"));return we.setAttribute("cx",W/2),we.setAttribute("cy",fe/2),we.setAttribute("rx",W/2-Ae/2),we.setAttribute("ry",fe/2-Ae/2),we.setAttribute("stroke-width",Ae||1),we.setAttribute("stroke","transparent"),we.setAttribute("fill","transparent"),pe.append(we),this.container.append(pe),!j.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return b(this,ze)}addHighlightArea(){this.container.classList.add("highlightArea")}}ze=new WeakMap;class $ extends v{constructor(j){super(j,{isRenderable:!0,ignoreBorder:!0});de(this,be,null);this.containerClassName="polylineAnnotation",this.svgElementName="svg:polyline"}render(){this.container.classList.add(this.containerClassName);const j=this.data,{width:W,height:fe}=g(j.rect),pe=this.svgFactory.create(W,fe,!0);let Ae=[];for(const je of j.vertices){const Le=je.x-j.rect[0],De=j.rect[3]-je.y;Ae.push(Le+","+De)}Ae=Ae.join(" ");const we=ue(this,be,this.svgFactory.createElement(this.svgElementName));return we.setAttribute("points",Ae),we.setAttribute("stroke-width",j.borderStyle.width||1),we.setAttribute("stroke","transparent"),we.setAttribute("fill","transparent"),pe.append(we),this.container.append(pe),!j.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return b(this,be)}addHighlightArea(){this.container.classList.add("highlightArea")}}be=new WeakMap;class K extends ${constructor(U){super(U),this.containerClassName="polygonAnnotation",this.svgElementName="svg:polygon"}}class J extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0})}render(){return this.container.classList.add("caretAnnotation"),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container}}class Y extends v{constructor(j){super(j,{isRenderable:!0,ignoreBorder:!0});de(this,oe,[]);this.containerClassName="inkAnnotation",this.svgElementName="svg:polyline",this.annotationEditorType=n.AnnotationEditorType.INK}render(){this.container.classList.add(this.containerClassName);const j=this.data,{width:W,height:fe}=g(j.rect),pe=this.svgFactory.create(W,fe,!0);for(const Ae of j.inkLists){let we=[];for(const Le of Ae){const De=Le.x-j.rect[0],Ge=j.rect[3]-Le.y;we.push(`${De},${Ge}`)}we=we.join(" ");const je=this.svgFactory.createElement(this.svgElementName);b(this,oe).push(je),je.setAttribute("points",we),je.setAttribute("stroke-width",j.borderStyle.width||1),je.setAttribute("stroke","transparent"),je.setAttribute("fill","transparent"),!j.popupRef&&this.hasPopupData&&this._createPopup(),pe.append(je)}return this.container.append(pe),this.container}getElementsToTriggerPopup(){return b(this,oe)}addHighlightArea(){this.container.classList.add("highlightArea")}}oe=new WeakMap,e.InkAnnotationElement=Y;class se extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("highlightAnnotation"),this.container}}class B extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("underlineAnnotation"),this.container}}class V extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("squigglyAnnotation"),this.container}}class Q extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("strikeoutAnnotation"),this.container}}class N extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0})}render(){return this.container.classList.add("stampAnnotation"),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container}}e.StampAnnotationElement=N;class P extends v{constructor(j){var pe;super(j,{isRenderable:!0});de(this,Re);de(this,ae,null);const{filename:W,content:fe}=this.data.file;this.filename=(0,a.getFilenameFromUrl)(W,!0),this.content=fe,(pe=this.linkService.eventBus)==null||pe.dispatch("fileattachmentannotation",{source:this,filename:W,content:fe})}render(){this.container.classList.add("fileAttachmentAnnotation");const{container:j,data:W}=this;let fe;W.hasAppearance||W.fillAlpha===0?fe=document.createElement("div"):(fe=document.createElement("img"),fe.src=`${this.imageResourcesPath}annotation-${/paperclip/i.test(W.name)?"paperclip":"pushpin"}.svg`,W.fillAlpha&&W.fillAlpha<1&&(fe.style=`filter: opacity(${Math.round(W.fillAlpha*100)}%);`)),fe.addEventListener("dblclick",te(this,Re,sr).bind(this)),ue(this,ae,fe);const{isMac:pe}=n.FeatureTest.platform;return j.addEventListener("keydown",Ae=>{Ae.key==="Enter"&&(pe?Ae.metaKey:Ae.ctrlKey)&&te(this,Re,sr).call(this)}),!W.popupRef&&this.hasPopupData?this._createPopup():fe.classList.add("popupTriggerArea"),j.append(fe),j}getElementsToTriggerPopup(){return b(this,ae)}addHighlightArea(){this.container.classList.add("highlightArea")}}ae=new WeakMap,Re=new WeakSet,sr=function(){var j;(j=this.downloadManager)==null||j.openOrDownloadData(this.container,this.content,this.filename)};class E{constructor({div:U,accessibilityManager:j,annotationCanvasMap:W,l10n:fe,page:pe,viewport:Ae}){de(this,ke);de(this,Ve,null);de(this,X,null);de(this,ge,new Map);this.div=U,ue(this,Ve,j),ue(this,X,W),this.l10n=fe,this.page=pe,this.viewport=Ae,this.zIndex=0,this.l10n||(this.l10n=h.NullL10n)}async render(U){const{annotations:j}=U,W=this.div;(0,a.setLayerDimensions)(W,this.viewport);const fe=new Map,pe={data:null,layer:W,linkService:U.linkService,downloadManager:U.downloadManager,imageResourcesPath:U.imageResourcesPath||"",renderForms:U.renderForms!==!1,svgFactory:new a.DOMSVGFactory,annotationStorage:U.annotationStorage||new s.AnnotationStorage,enableScripting:U.enableScripting===!0,hasJSActions:U.hasJSActions,fieldObjects:U.fieldObjects,parent:this,elements:null};for(const Ae of j){if(Ae.noHTML)continue;const we=Ae.annotationType===n.AnnotationType.POPUP;if(we){const De=fe.get(Ae.id);if(!De)continue;pe.elements=De}else{const{width:De,height:Ge}=g(Ae.rect);if(De<=0||Ge<=0)continue}pe.data=Ae;const je=f.create(pe);if(!je.isRenderable)continue;if(!we&&Ae.popupRef){const De=fe.get(Ae.popupRef);De?De.push(je):fe.set(Ae.popupRef,[je])}je.annotationEditorType>0&&b(this,ge).set(je.data.id,je);const Le=je.render();Ae.hidden&&(Le.style.visibility="hidden"),te(this,ke,Nr).call(this,Le,Ae.id)}te(this,ke,or).call(this),await this.l10n.translate(W)}update({viewport:U}){const j=this.div;this.viewport=U,(0,a.setLayerDimensions)(j,{rotation:U.rotation}),te(this,ke,or).call(this),j.hidden=!1}getEditableAnnotations(){return Array.from(b(this,ge).values())}getEditableAnnotation(U){return b(this,ge).get(U)}}Ve=new WeakMap,X=new WeakMap,ge=new WeakMap,ke=new WeakSet,Nr=function(U,j){var fe;const W=U.firstChild||U;W.id=`${n.AnnotationPrefix}${j}`,this.div.append(U),(fe=b(this,Ve))==null||fe.moveElementInDOM(this.div,U,W,!1)},or=function(){if(!b(this,X))return;const U=this.div;for(const[j,W]of b(this,X)){const fe=U.querySelector(`[data-annotation-id="${j}"]`);if(!fe)continue;const{firstChild:pe}=fe;pe?pe.nodeName==="CANVAS"?pe.replaceWith(W):pe.before(W):fe.append(W)}b(this,X).clear()},e.AnnotationLayer=E},(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.ColorConverters=void 0;function r(s){return Math.floor(Math.max(0,Math.min(1,s))*255).toString(16).padStart(2,"0")}function n(s){return Math.max(0,Math.min(255,255*s))}class a{static CMYK_G([o,h,d,l]){return["G",1-Math.min(1,.3*o+.59*d+.11*h+l)]}static G_CMYK([o]){return["CMYK",0,0,0,1-o]}static G_RGB([o]){return["RGB",o,o,o]}static G_rgb([o]){return o=n(o),[o,o,o]}static G_HTML([o]){const h=r(o);return`#${h}${h}${h}`}static RGB_G([o,h,d]){return["G",.3*o+.59*h+.11*d]}static RGB_rgb(o){return o.map(n)}static RGB_HTML(o){return`#${o.map(r).join("")}`}static T_HTML(){return"#00000000"}static T_rgb(){return[null]}static CMYK_RGB([o,h,d,l]){return["RGB",1-Math.min(1,o+l),1-Math.min(1,d+l),1-Math.min(1,h+l)]}static CMYK_rgb([o,h,d,l]){return[n(1-Math.min(1,o+l)),n(1-Math.min(1,d+l)),n(1-Math.min(1,h+l))]}static CMYK_HTML(o){const h=this.CMYK_RGB(o).slice(1);return this.RGB_HTML(h)}static RGB_CMYK([o,h,d]){const l=1-o,u=1-h,p=1-d,g=Math.min(l,u,p);return["CMYK",l,u,p,g]}}e.ColorConverters=a},(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.NullL10n=void 0,e.getL10nFallback=n;const r={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}} × {{height}} {{unit}} ({{orientation}})",document_properties_page_size_dimension_name_string:"{{width}} × {{height}} {{unit}} ({{name}}, {{orientation}})",document_properties_linearized_yes:"Yes",document_properties_linearized_no:"No",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",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_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.",rendering_error:"An error occurred while rendering the page.",annotation_date_string:"{{date}}, {{time}}",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.",free_text2_default_content:"Start typing…",editor_free_text2_aria_label:"Text Editor",editor_ink2_aria_label:"Draw Editor",editor_ink_canvas_aria_label:"User-created image",editor_alt_text_button_label:"Alt text",editor_alt_text_edit_button_label:"Edit alt text",editor_alt_text_decorative_tooltip:"Marked as decorative"};r.print_progress_percent="{{progress}}%";function n(o,h){switch(o){case"find_match_count":o=`find_match_count[${h.total===1?"one":"other"}]`;break;case"find_match_count_limit":o=`find_match_count_limit[${h.limit===1?"one":"other"}]`;break}return r[o]||""}function a(o,h){return h?o.replaceAll(/\{\{\s*(\w+)\s*\}\}/g,(d,l)=>l in h?h[l]:"{{"+l+"}}"):o}const s={async getLanguage(){return"en-us"},async getDirection(){return"ltr"},async get(o,h=null,d=n(o,h)){return a(d,h)},async translate(o){}};e.NullL10n=s},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.XfaLayer=void 0;var n=r(25);class a{static setupStorage(o,h,d,l,u){const p=l.getValue(h,{value:null});switch(d.name){case"textarea":if(p.value!==null&&(o.textContent=p.value),u==="print")break;o.addEventListener("input",g=>{l.setValue(h,{value:g.target.value})});break;case"input":if(d.attributes.type==="radio"||d.attributes.type==="checkbox"){if(p.value===d.attributes.xfaOn?o.setAttribute("checked",!0):p.value===d.attributes.xfaOff&&o.removeAttribute("checked"),u==="print")break;o.addEventListener("change",g=>{l.setValue(h,{value:g.target.checked?g.target.getAttribute("xfaOn"):g.target.getAttribute("xfaOff")})})}else{if(p.value!==null&&o.setAttribute("value",p.value),u==="print")break;o.addEventListener("input",g=>{l.setValue(h,{value:g.target.value})})}break;case"select":if(p.value!==null){o.setAttribute("value",p.value);for(const g of d.children)g.attributes.value===p.value?g.attributes.selected=!0:g.attributes.hasOwnProperty("selected")&&delete g.attributes.selected}o.addEventListener("input",g=>{const f=g.target.options,v=f.selectedIndex===-1?"":f[f.selectedIndex].value;l.setValue(h,{value:v})});break}}static setAttributes({html:o,element:h,storage:d=null,intent:l,linkService:u}){const{attributes:p}=h,g=o instanceof HTMLAnchorElement;p.type==="radio"&&(p.name=`${p.name}-${l}`);for(const[f,v]of Object.entries(p))if(v!=null)switch(f){case"class":v.length&&o.setAttribute(f,v.join(" "));break;case"dataId":break;case"id":o.setAttribute("data-element-id",v);break;case"style":Object.assign(o.style,v);break;case"textContent":o.textContent=v;break;default:(!g||f!=="href"&&f!=="newWindow")&&o.setAttribute(f,v)}g&&u.addLinkAttributes(o,p.href,p.newWindow),d&&p.dataId&&this.setupStorage(o,p.dataId,h,d)}static render(o){var y;const h=o.annotationStorage,d=o.linkService,l=o.xfaHtml,u=o.intent||"display",p=document.createElement(l.name);l.attributes&&this.setAttributes({html:p,element:l,intent:u,linkService:d});const g=[[l,-1,p]],f=o.div;if(f.append(p),o.viewport){const x=`matrix(${o.viewport.transform.join(",")})`;f.style.transform=x}u!=="richText"&&f.setAttribute("class","xfaLayer xfaFont");const v=[];for(;g.length>0;){const[x,m,w]=g.at(-1);if(m+1===x.children.length){g.pop();continue}const R=x.children[++g.at(-1)[1]];if(R===null)continue;const{name:_}=R;if(_==="#text"){const F=document.createTextNode(R.value);v.push(F),w.append(F);continue}const S=(y=R==null?void 0:R.attributes)!=null&&y.xmlns?document.createElementNS(R.attributes.xmlns,_):document.createElement(_);if(w.append(S),R.attributes&&this.setAttributes({html:S,element:R,storage:h,intent:u,linkService:d}),R.children&&R.children.length>0)g.push([R,-1,S]);else if(R.value){const F=document.createTextNode(R.value);n.XfaText.shouldBuildText(_)&&v.push(F),S.append(F)}}for(const x of f.querySelectorAll(".xfaNonInteractive input, .xfaNonInteractive textarea"))x.setAttribute("readOnly",!0);return{textDivs:v}}static update(o){const h=`matrix(${o.viewport.transform.join(",")})`;o.div.style.transform=h,o.div.hidden=!1}}e.XfaLayer=a},(t,e,r)=>{var l,u,p,g,f,v,y,x,m,w,R,_,S,F,A,Mr,Lr,Br,jr,lr,Ur,cr,zr,Hr,Gr,Wr,Vr,it,hr,Tt,_t,dt,dr,Rt,G,qr,ur,Xr,Kr,fr,kt,ut;Object.defineProperty(e,"__esModule",{value:!0}),e.InkEditor=void 0;var n=r(1),a=r(4),s=r(29),o=r(6),h=r(5);const Ce=class Ce extends a.AnnotationEditor{constructor(L){super({...L,name:"inkEditor"});de(this,A);de(this,l,0);de(this,u,0);de(this,p,this.canvasPointermove.bind(this));de(this,g,this.canvasPointerleave.bind(this));de(this,f,this.canvasPointerup.bind(this));de(this,v,this.canvasPointerdown.bind(this));de(this,y,new Path2D);de(this,x,!1);de(this,m,!1);de(this,w,!1);de(this,R,null);de(this,_,0);de(this,S,0);de(this,F,null);this.color=L.color||null,this.thickness=L.thickness||null,this.opacity=L.opacity||null,this.paths=[],this.bezierPath2D=[],this.allRawPaths=[],this.currentPath=[],this.scaleFactor=1,this.translationX=this.translationY=0,this.x=0,this.y=0,this._willKeepAspectRatio=!0}static initialize(L){a.AnnotationEditor.initialize(L,{strings:["editor_ink_canvas_aria_label","editor_ink2_aria_label"]})}static updateDefaultParams(L,Z){switch(L){case n.AnnotationEditorParamsType.INK_THICKNESS:Ce._defaultThickness=Z;break;case n.AnnotationEditorParamsType.INK_COLOR:Ce._defaultColor=Z;break;case n.AnnotationEditorParamsType.INK_OPACITY:Ce._defaultOpacity=Z/100;break}}updateParams(L,Z){switch(L){case n.AnnotationEditorParamsType.INK_THICKNESS:te(this,A,Mr).call(this,Z);break;case n.AnnotationEditorParamsType.INK_COLOR:te(this,A,Lr).call(this,Z);break;case n.AnnotationEditorParamsType.INK_OPACITY:te(this,A,Br).call(this,Z);break}}static get defaultPropertiesToUpdate(){return[[n.AnnotationEditorParamsType.INK_THICKNESS,Ce._defaultThickness],[n.AnnotationEditorParamsType.INK_COLOR,Ce._defaultColor||a.AnnotationEditor._defaultLineColor],[n.AnnotationEditorParamsType.INK_OPACITY,Math.round(Ce._defaultOpacity*100)]]}get propertiesToUpdate(){return[[n.AnnotationEditorParamsType.INK_THICKNESS,this.thickness||Ce._defaultThickness],[n.AnnotationEditorParamsType.INK_COLOR,this.color||Ce._defaultColor||a.AnnotationEditor._defaultLineColor],[n.AnnotationEditorParamsType.INK_OPACITY,Math.round(100*(this.opacity??Ce._defaultOpacity))]]}rebuild(){this.parent&&(super.rebuild(),this.div!==null&&(this.canvas||(te(this,A,Tt).call(this),te(this,A,_t).call(this)),this.isAttachedToDOM||(this.parent.add(this),te(this,A,dt).call(this)),te(this,A,ut).call(this)))}remove(){this.canvas!==null&&(this.isEmpty()||this.commit(),this.canvas.width=this.canvas.height=0,this.canvas.remove(),this.canvas=null,b(this,R).disconnect(),ue(this,R,null),super.remove())}setParent(L){!this.parent&&L?this._uiManager.removeShouldRescale(this):this.parent&&L===null&&this._uiManager.addShouldRescale(this),super.setParent(L)}onScaleChanging(){const[L,Z]=this.parentDimensions,re=this.width*L,he=this.height*Z;this.setDimensions(re,he)}enableEditMode(){b(this,x)||this.canvas===null||(super.enableEditMode(),this._isDraggable=!1,this.canvas.addEventListener("pointerdown",b(this,v)))}disableEditMode(){!this.isInEditMode()||this.canvas===null||(super.disableEditMode(),this._isDraggable=!this.isEmpty(),this.div.classList.remove("editing"),this.canvas.removeEventListener("pointerdown",b(this,v)))}onceAdded(){this._isDraggable=!this.isEmpty()}isEmpty(){return this.paths.length===0||this.paths.length===1&&this.paths[0].length===0}commit(){b(this,x)||(super.commit(),this.isEditing=!1,this.disableEditMode(),this.setInForeground(),ue(this,x,!0),this.div.classList.add("disabled"),te(this,A,ut).call(this,!0),this.makeResizable(),this.parent.addInkEditorIfNeeded(!0),this.moveInDOM(),this.div.focus({preventScroll:!0}))}focusin(L){this._focusEventsAllowed&&(super.focusin(L),this.enableEditMode())}canvasPointerdown(L){L.button!==0||!this.isInEditMode()||b(this,x)||(this.setInForeground(),L.preventDefault(),L.type!=="mouse"&&this.div.focus(),te(this,A,Ur).call(this,L.offsetX,L.offsetY))}canvasPointermove(L){L.preventDefault(),te(this,A,cr).call(this,L.offsetX,L.offsetY)}canvasPointerup(L){L.preventDefault(),te(this,A,hr).call(this,L)}canvasPointerleave(L){te(this,A,hr).call(this,L)}get isResizable(){return!this.isEmpty()&&b(this,x)}render(){if(this.div)return this.div;let L,Z;this.width&&(L=this.x,Z=this.y),super.render(),a.AnnotationEditor._l10nPromise.get("editor_ink2_aria_label").then(Pe=>{var ie;return(ie=this.div)==null?void 0:ie.setAttribute("aria-label",Pe)});const[re,he,ye,Fe]=te(this,A,jr).call(this);if(this.setAt(re,he,0,0),this.setDims(ye,Fe),te(this,A,Tt).call(this),this.width){const[Pe,ie]=this.parentDimensions;this.setAspectRatio(this.width*Pe,this.height*ie),this.setAt(L*Pe,Z*ie,this.width*Pe,this.height*ie),ue(this,w,!0),te(this,A,dt).call(this),this.setDims(this.width*Pe,this.height*ie),te(this,A,it).call(this),this.div.classList.add("disabled")}else this.div.classList.add("editing"),this.enableEditMode();return te(this,A,_t).call(this),this.div}setDimensions(L,Z){const re=Math.round(L),he=Math.round(Z);if(b(this,_)===re&&b(this,S)===he)return;ue(this,_,re),ue(this,S,he),this.canvas.style.visibility="hidden";const[ye,Fe]=this.parentDimensions;this.width=L/ye,this.height=Z/Fe,this.fixAndSetPosition(),b(this,x)&&te(this,A,dr).call(this,L,Z),te(this,A,dt).call(this),te(this,A,it).call(this),this.canvas.style.visibility="visible",this.fixDims()}static deserialize(L,Z,re){var Ee,Ie,ze;if(L instanceof s.InkAnnotationElement)return null;const he=super.deserialize(L,Z,re);he.thickness=L.thickness,he.color=n.Util.makeHexColor(...L.color),he.opacity=L.opacity;const[ye,Fe]=he.pageDimensions,Pe=he.width*ye,ie=he.height*Fe,_e=he.parentScale,Te=L.thickness/2;ue(he,x,!0),ue(he,_,Math.round(Pe)),ue(he,S,Math.round(ie));const{paths:Ke,rect:qe,rotation:Ye}=L;for(let{bezier:be}of Ke){be=te(Ee=Ce,G,Xr).call(Ee,be,qe,Ye);const oe=[];he.paths.push(oe);let ae=_e*(be[0]-Te),Re=_e*(be[1]-Te);for(let Ve=2,X=be.length;Ve<X;Ve+=6){const ge=_e*(be[Ve]-Te),ke=_e*(be[Ve+1]-Te),Be=_e*(be[Ve+2]-Te),He=_e*(be[Ve+3]-Te),Ne=_e*(be[Ve+4]-Te),U=_e*(be[Ve+5]-Te);oe.push([[ae,Re],[ge,ke],[Be,He],[Ne,U]]),ae=Ne,Re=U}const We=te(this,G,qr).call(this,oe);he.bezierPath2D.push(We)}const Me=te(Ie=he,A,fr).call(Ie);return ue(he,u,Math.max(a.AnnotationEditor.MIN_SIZE,Me[2]-Me[0])),ue(he,l,Math.max(a.AnnotationEditor.MIN_SIZE,Me[3]-Me[1])),te(ze=he,A,dr).call(ze,Pe,ie),he}serialize(){if(this.isEmpty())return null;const L=this.getRect(0,0),Z=a.AnnotationEditor._colorManager.convert(this.ctx.strokeStyle);return{annotationType:n.AnnotationEditorType.INK,color:Z,thickness:this.thickness,opacity:this.opacity,paths:te(this,A,Kr).call(this,this.scaleFactor/this.parentScale,this.translationX,this.translationY,L),pageIndex:this.pageIndex,rect:L,rotation:this.rotation,structTreeParentId:this._structTreeParentId}}};l=new WeakMap,u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakMap,x=new WeakMap,m=new WeakMap,w=new WeakMap,R=new WeakMap,_=new WeakMap,S=new WeakMap,F=new WeakMap,A=new WeakSet,Mr=function(L){const Z=this.thickness;this.addCommands({cmd:()=>{this.thickness=L,te(this,A,ut).call(this)},undo:()=>{this.thickness=Z,te(this,A,ut).call(this)},mustExec:!0,type:n.AnnotationEditorParamsType.INK_THICKNESS,overwriteIfSameType:!0,keepUndo:!0})},Lr=function(L){const Z=this.color;this.addCommands({cmd:()=>{this.color=L,te(this,A,it).call(this)},undo:()=>{this.color=Z,te(this,A,it).call(this)},mustExec:!0,type:n.AnnotationEditorParamsType.INK_COLOR,overwriteIfSameType:!0,keepUndo:!0})},Br=function(L){L/=100;const Z=this.opacity;this.addCommands({cmd:()=>{this.opacity=L,te(this,A,it).call(this)},undo:()=>{this.opacity=Z,te(this,A,it).call(this)},mustExec:!0,type:n.AnnotationEditorParamsType.INK_OPACITY,overwriteIfSameType:!0,keepUndo:!0})},jr=function(){const{parentRotation:L,parentDimensions:[Z,re]}=this;switch(L){case 90:return[0,re,re,Z];case 180:return[Z,re,Z,re];case 270:return[Z,0,re,Z];default:return[0,0,Z,re]}},lr=function(){const{ctx:L,color:Z,opacity:re,thickness:he,parentScale:ye,scaleFactor:Fe}=this;L.lineWidth=he*ye/Fe,L.lineCap="round",L.lineJoin="round",L.miterLimit=10,L.strokeStyle=`${Z}${(0,h.opacityToHex)(re)}`},Ur=function(L,Z){this.canvas.addEventListener("contextmenu",o.noContextMenu),this.canvas.addEventListener("pointerleave",b(this,g)),this.canvas.addEventListener("pointermove",b(this,p)),this.canvas.addEventListener("pointerup",b(this,f)),this.canvas.removeEventListener("pointerdown",b(this,v)),this.isEditing=!0,b(this,w)||(ue(this,w,!0),te(this,A,dt).call(this),this.thickness||(this.thickness=Ce._defaultThickness),this.color||(this.color=Ce._defaultColor||a.AnnotationEditor._defaultLineColor),this.opacity??(this.opacity=Ce._defaultOpacity)),this.currentPath.push([L,Z]),ue(this,m,!1),te(this,A,lr).call(this),ue(this,F,()=>{te(this,A,Gr).call(this),b(this,F)&&window.requestAnimationFrame(b(this,F))}),window.requestAnimationFrame(b(this,F))},cr=function(L,Z){const[re,he]=this.currentPath.at(-1);if(this.currentPath.length>1&&L===re&&Z===he)return;const ye=this.currentPath;let Fe=b(this,y);if(ye.push([L,Z]),ue(this,m,!0),ye.length<=2){Fe.moveTo(...ye[0]),Fe.lineTo(L,Z);return}ye.length===3&&(ue(this,y,Fe=new Path2D),Fe.moveTo(...ye[0])),te(this,A,Wr).call(this,Fe,...ye.at(-3),...ye.at(-2),L,Z)},zr=function(){if(this.currentPath.length===0)return;const L=this.currentPath.at(-1);b(this,y).lineTo(...L)},Hr=function(L,Z){ue(this,F,null),L=Math.min(Math.max(L,0),this.canvas.width),Z=Math.min(Math.max(Z,0),this.canvas.height),te(this,A,cr).call(this,L,Z),te(this,A,zr).call(this);let re;if(this.currentPath.length!==1)re=te(this,A,Vr).call(this);else{const ie=[L,Z];re=[[ie,ie.slice(),ie.slice(),ie]]}const he=b(this,y),ye=this.currentPath;this.currentPath=[],ue(this,y,new Path2D);const Fe=()=>{this.allRawPaths.push(ye),this.paths.push(re),this.bezierPath2D.push(he),this.rebuild()},Pe=()=>{this.allRawPaths.pop(),this.paths.pop(),this.bezierPath2D.pop(),this.paths.length===0?this.remove():(this.canvas||(te(this,A,Tt).call(this),te(this,A,_t).call(this)),te(this,A,ut).call(this))};this.addCommands({cmd:Fe,undo:Pe,mustExec:!0})},Gr=function(){if(!b(this,m))return;ue(this,m,!1);const L=Math.ceil(this.thickness*this.parentScale),Z=this.currentPath.slice(-3),re=Z.map(Fe=>Fe[0]),he=Z.map(Fe=>Fe[1]);Math.min(...re)-L,Math.max(...re)+L,Math.min(...he)-L,Math.max(...he)+L;const{ctx:ye}=this;ye.save(),ye.clearRect(0,0,this.canvas.width,this.canvas.height);for(const Fe of this.bezierPath2D)ye.stroke(Fe);ye.stroke(b(this,y)),ye.restore()},Wr=function(L,Z,re,he,ye,Fe,Pe){const ie=(Z+he)/2,_e=(re+ye)/2,Te=(he+Fe)/2,Ke=(ye+Pe)/2;L.bezierCurveTo(ie+2*(he-ie)/3,_e+2*(ye-_e)/3,Te+2*(he-Te)/3,Ke+2*(ye-Ke)/3,Te,Ke)},Vr=function(){const L=this.currentPath;if(L.length<=2)return[[L[0],L[0],L.at(-1),L.at(-1)]];const Z=[];let re,[he,ye]=L[0];for(re=1;re<L.length-2;re++){const[qe,Ye]=L[re],[Me,Ee]=L[re+1],Ie=(qe+Me)/2,ze=(Ye+Ee)/2,be=[he+2*(qe-he)/3,ye+2*(Ye-ye)/3],oe=[Ie+2*(qe-Ie)/3,ze+2*(Ye-ze)/3];Z.push([[he,ye],be,oe,[Ie,ze]]),[he,ye]=[Ie,ze]}const[Fe,Pe]=L[re],[ie,_e]=L[re+1],Te=[he+2*(Fe-he)/3,ye+2*(Pe-ye)/3],Ke=[ie+2*(Fe-ie)/3,_e+2*(Pe-_e)/3];return Z.push([[he,ye],Te,Ke,[ie,_e]]),Z},it=function(){if(this.isEmpty()){te(this,A,Rt).call(this);return}te(this,A,lr).call(this);const{canvas:L,ctx:Z}=this;Z.setTransform(1,0,0,1,0,0),Z.clearRect(0,0,L.width,L.height),te(this,A,Rt).call(this);for(const re of this.bezierPath2D)Z.stroke(re)},hr=function(L){this.canvas.removeEventListener("pointerleave",b(this,g)),this.canvas.removeEventListener("pointermove",b(this,p)),this.canvas.removeEventListener("pointerup",b(this,f)),this.canvas.addEventListener("pointerdown",b(this,v)),setTimeout(()=>{this.canvas.removeEventListener("contextmenu",o.noContextMenu)},10),te(this,A,Hr).call(this,L.offsetX,L.offsetY),this.addToAnnotationStorage(),this.setInBackground()},Tt=function(){this.canvas=document.createElement("canvas"),this.canvas.width=this.canvas.height=0,this.canvas.className="inkEditorCanvas",a.AnnotationEditor._l10nPromise.get("editor_ink_canvas_aria_label").then(L=>{var Z;return(Z=this.canvas)==null?void 0:Z.setAttribute("aria-label",L)}),this.div.append(this.canvas),this.ctx=this.canvas.getContext("2d")},_t=function(){ue(this,R,new ResizeObserver(L=>{const Z=L[0].contentRect;Z.width&&Z.height&&this.setDimensions(Z.width,Z.height)})),b(this,R).observe(this.div)},dt=function(){if(!b(this,w))return;const[L,Z]=this.parentDimensions;this.canvas.width=Math.ceil(this.width*L),this.canvas.height=Math.ceil(this.height*Z),te(this,A,Rt).call(this)},dr=function(L,Z){const re=te(this,A,kt).call(this),he=(L-re)/b(this,u),ye=(Z-re)/b(this,l);this.scaleFactor=Math.min(he,ye)},Rt=function(){const L=te(this,A,kt).call(this)/2;this.ctx.setTransform(this.scaleFactor,0,0,this.scaleFactor,this.translationX*this.scaleFactor+L,this.translationY*this.scaleFactor+L)},G=new WeakSet,qr=function(L){const Z=new Path2D;for(let re=0,he=L.length;re<he;re++){const[ye,Fe,Pe,ie]=L[re];re===0&&Z.moveTo(...ye),Z.bezierCurveTo(Fe[0],Fe[1],Pe[0],Pe[1],ie[0],ie[1])}return Z},ur=function(L,Z,re){const[he,ye,Fe,Pe]=Z;switch(re){case 0:for(let ie=0,_e=L.length;ie<_e;ie+=2)L[ie]+=he,L[ie+1]=Pe-L[ie+1];break;case 90:for(let ie=0,_e=L.length;ie<_e;ie+=2){const Te=L[ie];L[ie]=L[ie+1]+he,L[ie+1]=Te+ye}break;case 180:for(let ie=0,_e=L.length;ie<_e;ie+=2)L[ie]=Fe-L[ie],L[ie+1]+=ye;break;case 270:for(let ie=0,_e=L.length;ie<_e;ie+=2){const Te=L[ie];L[ie]=Fe-L[ie+1],L[ie+1]=Pe-Te}break;default:throw new Error("Invalid rotation")}return L},Xr=function(L,Z,re){const[he,ye,Fe,Pe]=Z;switch(re){case 0:for(let ie=0,_e=L.length;ie<_e;ie+=2)L[ie]-=he,L[ie+1]=Pe-L[ie+1];break;case 90:for(let ie=0,_e=L.length;ie<_e;ie+=2){const Te=L[ie];L[ie]=L[ie+1]-ye,L[ie+1]=Te-he}break;case 180:for(let ie=0,_e=L.length;ie<_e;ie+=2)L[ie]=Fe-L[ie],L[ie+1]-=ye;break;case 270:for(let ie=0,_e=L.length;ie<_e;ie+=2){const Te=L[ie];L[ie]=Pe-L[ie+1],L[ie+1]=Fe-Te}break;default:throw new Error("Invalid rotation")}return L},Kr=function(L,Z,re,he){var _e,Te;const ye=[],Fe=this.thickness/2,Pe=L*Z+Fe,ie=L*re+Fe;for(const Ke of this.paths){const qe=[],Ye=[];for(let Me=0,Ee=Ke.length;Me<Ee;Me++){const[Ie,ze,be,oe]=Ke[Me],ae=L*Ie[0]+Pe,Re=L*Ie[1]+ie,We=L*ze[0]+Pe,Ve=L*ze[1]+ie,X=L*be[0]+Pe,ge=L*be[1]+ie,ke=L*oe[0]+Pe,Be=L*oe[1]+ie;Me===0&&(qe.push(ae,Re),Ye.push(ae,Re)),qe.push(We,Ve,X,ge,ke,Be),Ye.push(We,Ve),Me===Ee-1&&Ye.push(ke,Be)}ye.push({bezier:te(_e=Ce,G,ur).call(_e,qe,he,this.rotation),points:te(Te=Ce,G,ur).call(Te,Ye,he,this.rotation)})}return ye},fr=function(){let L=1/0,Z=-1/0,re=1/0,he=-1/0;for(const ye of this.paths)for(const[Fe,Pe,ie,_e]of ye){const Te=n.Util.bezierBoundingBox(...Fe,...Pe,...ie,..._e);L=Math.min(L,Te[0]),re=Math.min(re,Te[1]),Z=Math.max(Z,Te[2]),he=Math.max(he,Te[3])}return[L,re,Z,he]},kt=function(){return b(this,x)?Math.ceil(this.thickness*this.parentScale):0},ut=function(L=!1){if(this.isEmpty())return;if(!b(this,x)){te(this,A,it).call(this);return}const Z=te(this,A,fr).call(this),re=te(this,A,kt).call(this);ue(this,u,Math.max(a.AnnotationEditor.MIN_SIZE,Z[2]-Z[0])),ue(this,l,Math.max(a.AnnotationEditor.MIN_SIZE,Z[3]-Z[1]));const he=Math.ceil(re+b(this,u)*this.scaleFactor),ye=Math.ceil(re+b(this,l)*this.scaleFactor),[Fe,Pe]=this.parentDimensions;this.width=he/Fe,this.height=ye/Pe,this.setAspectRatio(he,ye);const ie=this.translationX,_e=this.translationY;this.translationX=-Z[0],this.translationY=-Z[1],te(this,A,dt).call(this),te(this,A,it).call(this),ue(this,_,he),ue(this,S,ye),this.setDims(he,ye);const Te=L?re/this.scaleFactor/2:0;this.translate(ie-this.translationX-Te,_e-this.translationY-Te)},de(Ce,G),$e(Ce,"_defaultColor",null),$e(Ce,"_defaultOpacity",1),$e(Ce,"_defaultThickness",1),$e(Ce,"_type","ink");let d=Ce;e.InkEditor=d},(t,e,r)=>{var d,l,u,p,g,f,v,y,x,m,w,bt,xt,It,pr,Zr,Yr,gr,Ot,Jr;Object.defineProperty(e,"__esModule",{value:!0}),e.StampEditor=void 0;var n=r(1),a=r(4),s=r(6),o=r(29);const k=class k extends a.AnnotationEditor{constructor(K){super({...K,name:"stampEditor"});de(this,w);de(this,d,null);de(this,l,null);de(this,u,null);de(this,p,null);de(this,g,null);de(this,f,null);de(this,v,null);de(this,y,null);de(this,x,!1);de(this,m,!1);ue(this,p,K.bitmapUrl),ue(this,g,K.bitmapFile)}static initialize(K){a.AnnotationEditor.initialize(K)}static get supportedTypes(){const K=["apng","avif","bmp","gif","jpeg","png","svg+xml","webp","x-icon"];return(0,n.shadow)(this,"supportedTypes",K.map(J=>`image/${J}`))}static get supportedTypesStr(){return(0,n.shadow)(this,"supportedTypesStr",this.supportedTypes.join(","))}static isHandlingMimeForPasting(K){return this.supportedTypes.includes(K)}static paste(K,J){J.pasteEditor(n.AnnotationEditorType.STAMP,{bitmapFile:K.getAsFile()})}remove(){var K,J;b(this,l)&&(ue(this,d,null),this._uiManager.imageManager.deleteId(b(this,l)),(K=b(this,f))==null||K.remove(),ue(this,f,null),(J=b(this,v))==null||J.disconnect(),ue(this,v,null)),super.remove()}rebuild(){if(!this.parent){b(this,l)&&te(this,w,It).call(this);return}super.rebuild(),this.div!==null&&(b(this,l)&&te(this,w,It).call(this),this.isAttachedToDOM||this.parent.add(this))}onceAdded(){this._isDraggable=!0,this.div.focus()}isEmpty(){return!(b(this,u)||b(this,d)||b(this,p)||b(this,g))}get isResizable(){return!0}render(){if(this.div)return this.div;let K,J;if(this.width&&(K=this.x,J=this.y),super.render(),this.div.hidden=!0,b(this,d)?te(this,w,pr).call(this):te(this,w,It).call(this),this.width){const[Y,se]=this.parentDimensions;this.setAt(K*Y,J*se,this.width*Y,this.height*se)}return this.div}static deserialize(K,J,Y){if(K instanceof o.StampAnnotationElement)return null;const se=super.deserialize(K,J,Y),{rect:B,bitmapUrl:V,bitmapId:Q,isSvg:N,accessibilityData:P}=K;Q&&Y.imageManager.isValidId(Q)?ue(se,l,Q):ue(se,p,V),ue(se,x,N);const[E,I]=se.pageDimensions;return se.width=(B[2]-B[0])/E,se.height=(B[3]-B[1])/I,P&&(se.altTextData=P),se}serialize(K=!1,J=null){if(this.isEmpty())return null;const Y={annotationType:n.AnnotationEditorType.STAMP,bitmapId:b(this,l),pageIndex:this.pageIndex,rect:this.getRect(0,0),rotation:this.rotation,isSvg:b(this,x),structTreeParentId:this._structTreeParentId};if(K)return Y.bitmapUrl=te(this,w,Ot).call(this,!0),Y.accessibilityData=this.altTextData,Y;const{decorative:se,altText:B}=this.altTextData;if(!se&&B&&(Y.accessibilityData={type:"Figure",alt:B}),J===null)return Y;J.stamps||(J.stamps=new Map);const V=b(this,x)?(Y.rect[2]-Y.rect[0])*(Y.rect[3]-Y.rect[1]):null;if(!J.stamps.has(b(this,l)))J.stamps.set(b(this,l),{area:V,serialized:Y}),Y.bitmap=te(this,w,Ot).call(this,!1);else if(b(this,x)){const Q=J.stamps.get(b(this,l));V>Q.area&&(Q.area=V,Q.serialized.bitmap.close(),Q.serialized.bitmap=te(this,w,Ot).call(this,!1))}return Y}};d=new WeakMap,l=new WeakMap,u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakMap,x=new WeakMap,m=new WeakMap,w=new WeakSet,bt=function(K,J=!1){if(!K){this.remove();return}ue(this,d,K.bitmap),J||(ue(this,l,K.id),ue(this,x,K.isSvg)),te(this,w,pr).call(this)},xt=function(){ue(this,u,null),this._uiManager.enableWaiting(!1),b(this,f)&&this.div.focus()},It=function(){if(b(this,l)){this._uiManager.enableWaiting(!0),this._uiManager.imageManager.getFromId(b(this,l)).then(J=>te(this,w,bt).call(this,J,!0)).finally(()=>te(this,w,xt).call(this));return}if(b(this,p)){const J=b(this,p);ue(this,p,null),this._uiManager.enableWaiting(!0),ue(this,u,this._uiManager.imageManager.getFromUrl(J).then(Y=>te(this,w,bt).call(this,Y)).finally(()=>te(this,w,xt).call(this)));return}if(b(this,g)){const J=b(this,g);ue(this,g,null),this._uiManager.enableWaiting(!0),ue(this,u,this._uiManager.imageManager.getFromFile(J).then(Y=>te(this,w,bt).call(this,Y)).finally(()=>te(this,w,xt).call(this)));return}const K=document.createElement("input");K.type="file",K.accept=k.supportedTypesStr,ue(this,u,new Promise(J=>{K.addEventListener("change",async()=>{if(!K.files||K.files.length===0)this.remove();else{this._uiManager.enableWaiting(!0);const Y=await this._uiManager.imageManager.getFromFile(K.files[0]);te(this,w,bt).call(this,Y)}J()}),K.addEventListener("cancel",()=>{this.remove(),J()})}).finally(()=>te(this,w,xt).call(this))),K.click()},pr=function(){const{div:K}=this;let{width:J,height:Y}=b(this,d);const[se,B]=this.pageDimensions,V=.75;if(this.width)J=this.width*se,Y=this.height*B;else if(J>V*se||Y>V*B){const E=Math.min(V*se/J,V*B/Y);J*=E,Y*=E}const[Q,N]=this.parentDimensions;this.setDims(J*Q/se,Y*N/B),this._uiManager.enableWaiting(!1);const P=ue(this,f,document.createElement("canvas"));K.append(P),K.hidden=!1,te(this,w,gr).call(this,J,Y),te(this,w,Jr).call(this),b(this,m)||(this.parent.addUndoableEditor(this),ue(this,m,!0)),this._uiManager._eventBus.dispatch("reporttelemetry",{source:this,details:{type:"editing",subtype:this.editorType,data:{action:"inserted_image"}}}),this.addAltTextButton()},Zr=function(K,J){var V;const[Y,se]=this.parentDimensions;this.width=K/Y,this.height=J/se,this.setDims(K,J),(V=this._initialOptions)!=null&&V.isCentered?this.center():this.fixAndSetPosition(),this._initialOptions=null,b(this,y)!==null&&clearTimeout(b(this,y)),ue(this,y,setTimeout(()=>{ue(this,y,null),te(this,w,gr).call(this,K,J)},200))},Yr=function(K,J){const{width:Y,height:se}=b(this,d);let B=Y,V=se,Q=b(this,d);for(;B>2*K||V>2*J;){const N=B,P=V;B>2*K&&(B=B>=16384?Math.floor(B/2)-1:Math.ceil(B/2)),V>2*J&&(V=V>=16384?Math.floor(V/2)-1:Math.ceil(V/2));const E=new OffscreenCanvas(B,V);E.getContext("2d").drawImage(Q,0,0,N,P,0,0,B,V),Q=E.transferToImageBitmap()}return Q},gr=function(K,J){K=Math.ceil(K),J=Math.ceil(J);const Y=b(this,f);if(!Y||Y.width===K&&Y.height===J)return;Y.width=K,Y.height=J;const se=b(this,x)?b(this,d):te(this,w,Yr).call(this,K,J),B=Y.getContext("2d");B.filter=this._uiManager.hcmFilter,B.drawImage(se,0,0,se.width,se.height,0,0,K,J)},Ot=function(K){if(K){if(b(this,x)){const se=this._uiManager.imageManager.getSvgUrl(b(this,l));if(se)return se}const J=document.createElement("canvas");return{width:J.width,height:J.height}=b(this,d),J.getContext("2d").drawImage(b(this,d),0,0),J.toDataURL()}if(b(this,x)){const[J,Y]=this.pageDimensions,se=Math.round(this.width*J*s.PixelsPerInch.PDF_TO_CSS_UNITS),B=Math.round(this.height*Y*s.PixelsPerInch.PDF_TO_CSS_UNITS),V=new OffscreenCanvas(se,B);return V.getContext("2d").drawImage(b(this,d),0,0,b(this,d).width,b(this,d).height,0,0,se,B),V.transferToImageBitmap()}return structuredClone(b(this,d))},Jr=function(){ue(this,v,new ResizeObserver(K=>{const J=K[0].contentRect;J.width&&J.height&&te(this,w,Zr).call(this,J.width,J.height)})),b(this,v).observe(this.div)},$e(k,"_type","stamp");let h=k;e.StampEditor=h}],__webpack_module_cache__={};function __w_pdfjs_require__(t){var e=__webpack_module_cache__[t];if(e!==void 0)return e.exports;var r=__webpack_module_cache__[t]={exports:{}};return __webpack_modules__[t](r,r.exports,__w_pdfjs_require__),r.exports}var __webpack_exports__={};return(()=>{var t=__webpack_exports__;Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"AbortException",{enumerable:!0,get:function(){return e.AbortException}}),Object.defineProperty(t,"AnnotationEditorLayer",{enumerable:!0,get:function(){return s.AnnotationEditorLayer}}),Object.defineProperty(t,"AnnotationEditorParamsType",{enumerable:!0,get:function(){return e.AnnotationEditorParamsType}}),Object.defineProperty(t,"AnnotationEditorType",{enumerable:!0,get:function(){return e.AnnotationEditorType}}),Object.defineProperty(t,"AnnotationEditorUIManager",{enumerable:!0,get:function(){return o.AnnotationEditorUIManager}}),Object.defineProperty(t,"AnnotationLayer",{enumerable:!0,get:function(){return h.AnnotationLayer}}),Object.defineProperty(t,"AnnotationMode",{enumerable:!0,get:function(){return e.AnnotationMode}}),Object.defineProperty(t,"CMapCompressionType",{enumerable:!0,get:function(){return e.CMapCompressionType}}),Object.defineProperty(t,"DOMSVGFactory",{enumerable:!0,get:function(){return n.DOMSVGFactory}}),Object.defineProperty(t,"FeatureTest",{enumerable:!0,get:function(){return e.FeatureTest}}),Object.defineProperty(t,"GlobalWorkerOptions",{enumerable:!0,get:function(){return d.GlobalWorkerOptions}}),Object.defineProperty(t,"ImageKind",{enumerable:!0,get:function(){return e.ImageKind}}),Object.defineProperty(t,"InvalidPDFException",{enumerable:!0,get:function(){return e.InvalidPDFException}}),Object.defineProperty(t,"MissingPDFException",{enumerable:!0,get:function(){return e.MissingPDFException}}),Object.defineProperty(t,"OPS",{enumerable:!0,get:function(){return e.OPS}}),Object.defineProperty(t,"PDFDataRangeTransport",{enumerable:!0,get:function(){return r.PDFDataRangeTransport}}),Object.defineProperty(t,"PDFDateString",{enumerable:!0,get:function(){return n.PDFDateString}}),Object.defineProperty(t,"PDFWorker",{enumerable:!0,get:function(){return r.PDFWorker}}),Object.defineProperty(t,"PasswordResponses",{enumerable:!0,get:function(){return e.PasswordResponses}}),Object.defineProperty(t,"PermissionFlag",{enumerable:!0,get:function(){return e.PermissionFlag}}),Object.defineProperty(t,"PixelsPerInch",{enumerable:!0,get:function(){return n.PixelsPerInch}}),Object.defineProperty(t,"PromiseCapability",{enumerable:!0,get:function(){return e.PromiseCapability}}),Object.defineProperty(t,"RenderingCancelledException",{enumerable:!0,get:function(){return n.RenderingCancelledException}}),Object.defineProperty(t,"SVGGraphics",{enumerable:!0,get:function(){return r.SVGGraphics}}),Object.defineProperty(t,"UnexpectedResponseException",{enumerable:!0,get:function(){return e.UnexpectedResponseException}}),Object.defineProperty(t,"Util",{enumerable:!0,get:function(){return e.Util}}),Object.defineProperty(t,"VerbosityLevel",{enumerable:!0,get:function(){return e.VerbosityLevel}}),Object.defineProperty(t,"XfaLayer",{enumerable:!0,get:function(){return l.XfaLayer}}),Object.defineProperty(t,"build",{enumerable:!0,get:function(){return r.build}}),Object.defineProperty(t,"createValidAbsoluteUrl",{enumerable:!0,get:function(){return e.createValidAbsoluteUrl}}),Object.defineProperty(t,"getDocument",{enumerable:!0,get:function(){return r.getDocument}}),Object.defineProperty(t,"getFilenameFromUrl",{enumerable:!0,get:function(){return n.getFilenameFromUrl}}),Object.defineProperty(t,"getPdfFilenameFromUrl",{enumerable:!0,get:function(){return n.getPdfFilenameFromUrl}}),Object.defineProperty(t,"getXfaPageViewport",{enumerable:!0,get:function(){return n.getXfaPageViewport}}),Object.defineProperty(t,"isDataScheme",{enumerable:!0,get:function(){return n.isDataScheme}}),Object.defineProperty(t,"isPdfFile",{enumerable:!0,get:function(){return n.isPdfFile}}),Object.defineProperty(t,"loadScript",{enumerable:!0,get:function(){return n.loadScript}}),Object.defineProperty(t,"noContextMenu",{enumerable:!0,get:function(){return n.noContextMenu}}),Object.defineProperty(t,"normalizeUnicode",{enumerable:!0,get:function(){return e.normalizeUnicode}}),Object.defineProperty(t,"renderTextLayer",{enumerable:!0,get:function(){return a.renderTextLayer}}),Object.defineProperty(t,"setLayerDimensions",{enumerable:!0,get:function(){return n.setLayerDimensions}}),Object.defineProperty(t,"shadow",{enumerable:!0,get:function(){return e.shadow}}),Object.defineProperty(t,"updateTextLayer",{enumerable:!0,get:function(){return a.updateTextLayer}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return r.version}});var e=__w_pdfjs_require__(1),r=__w_pdfjs_require__(2),n=__w_pdfjs_require__(6),a=__w_pdfjs_require__(26),s=__w_pdfjs_require__(27),o=__w_pdfjs_require__(5),h=__w_pdfjs_require__(29),d=__w_pdfjs_require__(14),l=__w_pdfjs_require__(32)})(),__webpack_exports__})())})(pdf);var pdfExports=pdf.exports;const FONT_SIZES=[8,10,12,14,16,20,24,32,48,64],STROKE_WIDTHS=[1,2,4,8,12],DEFAULT_COLOR="#ef4444",DEFAULT_FONT_SIZE=16,DEFAULT_STROKE_WIDTH=2,STAMPS=["APPROVED","CONFIDENTIAL","DRAFT","FINAL","FOR REVIEW","REVISED","ASAP","VOID"],iconProps={className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor"},SelectIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 3l7.07 16.97 2.51-7.39 7.39-2.51L3 3z",fill:"currentColor"})}),PanIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M10.05 4.575a1.575 1.575 0 10-3.15 0v3m3.15-3v-1.5a1.575 1.575 0 013.15 0v1.5m-3.15 0l.075 5.925m3.075.75V4.575m0 0a1.575 1.575 0 013.15 0V15M6.9 7.575a1.575 1.575 0 10-3.15 0v8.175a6.75 6.75 0 006.75 6.75h2.018a5.25 5.25 0 003.712-1.538l1.732-1.732a5.25 5.25 0 001.538-3.712l.003-2.024a.668.668 0 01.198-.471 1.575 1.575 0 10-2.228-2.228 3.818 3.818 0 00-1.12 2.687M6.9 7.575V12m6.27 4.318A4.49 4.49 0 0116.35 15m.002 0h-.002"})}),PenIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M16.862 4.487l1.687-1.688a1.875 1.875 0 112.652 2.652L6.832 19.82a4.5 4.5 0 01-1.897 1.13l-2.685.8.8-2.685a4.5 4.5 0 011.13-1.897L16.863 4.487zm0 0L19.5 7.125"})}),HighlighterIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9.53 16.122a3 3 0 00-5.78 1.128 2.25 2.25 0 01-2.4 2.245 4.5 4.5 0 008.4-2.245c0-.399-.078-.78-.22-1.128zm0 0a15.998 15.998 0 003.388-1.62m-5.043-.025a15.994 15.994 0 011.622-3.395m3.42 3.42a15.995 15.995 0 004.764-4.648l3.876-5.814a1.151 1.151 0 00-1.597-1.597L14.146 6.32a15.996 15.996 0 00-4.649 4.763m3.42 3.42a6.776 6.776 0 00-3.42-3.42"})}),FreeTextIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("text",{x:"12",y:"17",fontSize:"16",fontWeight:"bold",textAnchor:"middle",fill:"currentColor",stroke:"none",children:"T"})}),RectangleIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5.25 7.5A2.25 2.25 0 017.5 5.25h9a2.25 2.25 0 012.25 2.25v9a2.25 2.25 0 01-2.25-2.25h-9a2.25 2.25 0 01-2.25-2.25v-9z"})}),CircleIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 21a9 9 0 110-18 9 9 0 010 18z"})}),EraserIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M11.412 15.655L7.797 12.04m3.615 3.615L15.655 11.412m-4.243 4.243L12 12m0 0L8.345 8.345m3.655 3.655L15.655 8.345m-7.31 7.31L12 12m-3.655-3.655L12 12m0 0l3.655 3.655m-3.655-3.655L8.345 8.345m-2.299 6.501a.75.75 0 01-1.06 0l-2.122-2.121a.75.75 0 010-1.061l3.182-3.182a.75.75 0 011.06 0l2.122 2.121a.75.75 0 010 1.061l-3.182 3.182zM18.97 5.03a.75.75 0 010 1.06l-2.121 2.122a.75.75 0 01-1.06 0l-2.122-2.122a.75.75 0 010-1.06l2.122-2.122a.75.75 0 011.06 0l2.121 2.122z"})}),TrashIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M14.74 9l-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 01-2.244 2.077H8.084a2.25 2.25 0 01-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 00-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 013.478-.397m7.5 0v-.916c0-1.18-.91-2.134-2.09-2.134H8.09c-1.18 0-2.09.954-2.09 2.134v.916m7.5 0a48.667 48.667 0 00-7.5 0"})}),ZoomInIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 21l-5.197-5.197m0 0A7.5 7.5 0 105.196 5.196a7.5 7.5 0 0010.607 10.607zM10.5 7.5v6m3-3h-6"})}),ZoomOutIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 21l-5.197-5.197m0 0A7.5 7.5 0 105.196 5.196a7.5 7.5 0 0010.607 10.607zM13.5 10.5h-6"})}),DownloadIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 16.5v2.25A2.25 2.25 0 005.25 21h13.5A2.25 2.25 0 0021 18.75V16.5M16.5 12L12 16.5m0 0L7.5 12m4.5 4.5V3"})}),PrintIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6.72 13.829c-.24.03-.48.062-.72.096m.72-.096a42.415 42.415 0 0110.56 0m-10.56 0L6.34 18m10.94-4.171c.24.03.48.062.72.096m-.72-.096L17.66 18m0 0l.229 2.523a1.125 1.125 0 01-1.12 1.227H7.231c-.662 0-1.18-.568-1.12-1.227L6.34 18m11.32 0c0-1.24-.98-2.25-2.21-2.25H8.552c-1.23 0-2.21 1.01-2.21 2.25m11.32 0-2.21 2.25m-8.9-2.25L7.45 15.456a1.125 1.125 0 011.591 0l.022.022a1.125 1.125 0 010 1.591l-1.18 1.18m0-1.18a9 9 0 009.536 2.343M3.75 21a3.375 3.375 0 01-3.375-3.375V10.312c0-.178.051-.35.146-.5l2.351-4.006a1.125 1.125 0 01.97-.566h12.556c.376 0 .723.158.97.43l2.351 4.006c.095.15.146.322.146.5v7.312a3.375 3.375 0 01-3.375 3.375H3.75z"})}),UploadIcon=()=>jsxRuntime.jsx("svg",{className:"mx-auto h-12 w-12 text-gray-400",stroke:"currentColor",fill:"none",viewBox:"0 0 48 48","aria-hidden":"true",children:jsxRuntime.jsx("path",{d:"M28 8H12a4 4 0 00-4 4v20m32-12v8m0 0v8a4 4 0 01-4 4H12a4 4 0 01-4-4v-4m32-4l-3.172-3.172a4 4 0 00-5.656 0L28 28M8 32l9.172-9.172a4 4 0 015.656 0L28 28",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})}),UnderlineIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 4.5v15m-6.75-3.75h13.5"})}),StrikeoutIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 4.5v15m-6.75-7.5h13.5"})}),SquigglyIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 12c3-3 6 3 9 0s6 3 9 0"})}),StampIcon=()=>jsxRuntime.jsxs("svg",{...iconProps,children:[jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 6v6m-6 4h12m-6-8a2 2 0 100-4 2 2 0 000 4z"}),jsxRuntime.jsx("rect",{x:"6",y:"16",width:"12",height:"4",stroke:"currentColor",strokeWidth:"1.5",fill:"none",rx:"1"}),jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 20h12"})]}),SignatureIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M10.5 6h9.75M10.5 6a1.5 1.5 0 11-3 0m3 0a1.5 1.5 0 10-3 0M3.75 6H7.5m3 12h9.75m-9.75 0a1.5 1.5 0 01-3 0m3 0a1.5 1.5 0 00-3 0m-3.75 0H7.5m9-6h3.75m-3.75 0a1.5 1.5 0 01-3 0m3 0a1.5 1.5 0 00-3 0m-9.75 0h9.75"})}),InitialsIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15.75 6a3.75 3.75 0 11-7.5 0 3.75 3.75 0 017.5 0zM4.501 20.118a7.5 7.5 0 0114.998 0A17.933 17.933 0 0112 21.75c-2.676 0-5.216-.584-7.499-1.632z"})}),UndoIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9 15L3 9m0 0l6-6M3 9h12a6 6 0 010 12h-3"})}),RedoIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 15l6-6m0 0l-6-6m6 6H9a6 6 0 000 12h3"})}),MoreIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 6.75a.75.75 0 110-1.5.75.75 0 010 1.5zM12 12.75a.75.75 0 110-1.5.75.75 0 010 1.5zM12 18.75a.75.75 0 110-1.5.75.75 0 010 1.5z"})}),RotateIcon=()=>jsxRuntime.jsxs("svg",{...iconProps,children:[jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M20.25 12A8.25 8.25 0 0012 3.75c-2.23 0-4.25.88-5.74 2.31M3.75 3.75v4.5h4.5"}),jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3.75 12A8.25 8.25 0 0012 20.25c2.23 0 4.25-.88 5.74-2.31"})]}),ToolButton=({label:t,isActive:e=!1,onClick:r,children:n,disabled:a=!1})=>jsxRuntime.jsx("button",{title:t,"aria-label":t,onClick:r,disabled:a,className:`p-2 rounded-md transition-colors ${e?"bg-indigo-500 text-white":"hover:bg-gray-200 text-gray-800"} disabled:opacity-50 disabled:cursor-not-allowed`,children:n}),Toolbar=t=>{const{fileName:e,currentPage:r,totalPages:n,zoom:a,setZoom:s,setCurrentPage:o,activeTool:h,setActiveTool:d,toolColor:l,setToolColor:u,strokeWidth:p,setStrokeWidth:g,fontSize:f,setFontSize:v,onDownload:y,onPrint:x,isProcessing:m,onDelete:w,selectedAnnotationId:R,undo:_,redo:S,canUndo:F,canRedo:A,onSignatureClick:D,onInitialsClick:T,activeStamp:M,setActiveStamp:C,onRotate:k,readonly:O=!1}=t,[$,K]=react.useState(!1),[J,Y]=react.useState(!1),se=react.useRef(null);react.useEffect(()=>{const P=E=>{se.current&&!se.current.contains(E.target)&&K(!1)};return $&&document.addEventListener("mousedown",P),()=>{document.removeEventListener("mousedown",P)}},[$]);const B=P=>{const E=parseInt(P.target.value,10);E>0&&E<=n&&o(E)},V=[{tool:"SELECT",icon:jsxRuntime.jsx(SelectIcon,{}),label:"Select"},{tool:"PAN",icon:jsxRuntime.jsx(PanIcon,{}),label:"Pan"},{tool:"PEN",icon:jsxRuntime.jsx(PenIcon,{}),label:"Pen"},{tool:"HIGHLIGHTER",icon:jsxRuntime.jsx(HighlighterIcon,{}),label:"Highlighter"}],Q=[{tool:"RECTANGLE",icon:jsxRuntime.jsx(RectangleIcon,{}),label:"Rectangle"},{tool:"CIRCLE",icon:jsxRuntime.jsx(CircleIcon,{}),label:"Circle"}],N=[{tool:"TEXT",icon:jsxRuntime.jsx(FreeTextIcon,{}),label:"Free Text"},{tool:"SQUIGGLY",icon:jsxRuntime.jsx(SquigglyIcon,{}),label:"Squiggly"}];return jsxRuntime.jsxs("header",{className:"bg-gray-50 shadow-md p-2 flex flex-col gap-2 z-10",children:[jsxRuntime.jsxs("div",{className:"flex items-center justify-between",children:[jsxRuntime.jsx("span",{className:"font-semibold text-lg truncate max-w-xs text-gray-800",title:e,children:e}),jsxRuntime.jsxs("div",{className:"flex items-center gap-4",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx("button",{onClick:()=>o(r-1),disabled:r<=1,className:"p-2 rounded-md hover:bg-gray-200 disabled:opacity-50 text-gray-800 transition-colors",children:"‹"}),jsxRuntime.jsxs("div",{className:"flex items-center text-gray-800",children:[jsxRuntime.jsx("input",{type:"number",value:r,onChange:B,className:"w-12 text-center bg-white rounded-md border border-gray-300 text-gray-800"}),jsxRuntime.jsx("span",{className:"mx-2",children:"/"}),jsxRuntime.jsx("span",{children:n})]}),jsxRuntime.jsx("button",{onClick:()=>o(r+1),disabled:r>=n,className:"p-2 rounded-md hover:bg-gray-200 disabled:opacity-50 text-gray-800 transition-colors",children:"›"})]}),jsxRuntime.jsx("div",{className:"w-px h-6 bg-gray-300"}),jsxRuntime.jsx("div",{className:"flex items-center gap-1",children:jsxRuntime.jsx(ToolButton,{label:"Rotate Page",onClick:k,children:jsxRuntime.jsx(RotateIcon,{})})}),jsxRuntime.jsx("div",{className:"w-px h-6 bg-gray-300"}),jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(ToolButton,{label:"Zoom Out",onClick:()=>s(Math.max(.25,a-.25)),children:jsxRuntime.jsx(ZoomOutIcon,{})}),jsxRuntime.jsxs("span",{className:"w-16 text-center bg-white rounded-md border border-gray-300 cursor-pointer text-gray-800 py-1",onClick:()=>s(1),children:[Math.round(a*100),"%"]}),jsxRuntime.jsx(ToolButton,{label:"Zoom In",onClick:()=>s(Math.min(4,a+.25)),children:jsxRuntime.jsx(ZoomInIcon,{})})]})]}),jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[!O&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(ToolButton,{label:"Undo",onClick:_,disabled:!F,children:jsxRuntime.jsx(UndoIcon,{})}),jsxRuntime.jsx(ToolButton,{label:"Redo",onClick:S,disabled:!A,children:jsxRuntime.jsx(RedoIcon,{})}),jsxRuntime.jsx("div",{className:"w-px h-6 bg-gray-300"})]}),jsxRuntime.jsxs("div",{className:"relative",ref:se,children:[jsxRuntime.jsx(ToolButton,{label:"More options",onClick:()=>K(!$),children:jsxRuntime.jsx(MoreIcon,{})}),$&&jsxRuntime.jsx("div",{className:"absolute right-0 mt-2 w-56 bg-white rounded-md shadow-lg border border-gray-200 z-50",children:jsxRuntime.jsxs("div",{className:"py-1",children:[jsxRuntime.jsxs("button",{onClick:()=>{x(),K(!1)},disabled:m,className:"w-full text-left px-4 py-2 text-sm text-gray-800 hover:bg-gray-100 disabled:opacity-50 disabled:cursor-not-allowed flex items-center gap-3",children:[jsxRuntime.jsx(PrintIcon,{}),jsxRuntime.jsx("span",{children:"Print"})]}),jsxRuntime.jsxs("button",{onClick:()=>{y(),K(!1)},disabled:m,className:"w-full text-left px-4 py-2 text-sm text-gray-800 hover:bg-gray-100 disabled:opacity-50 disabled:cursor-not-allowed flex items-center gap-3",children:[jsxRuntime.jsx(DownloadIcon,{}),jsxRuntime.jsx("span",{children:"Download"})]}),!O&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:"border-t border-gray-200 my-1"}),jsxRuntime.jsxs("button",{onClick:()=>{Y(!J),K(!1)},className:"w-full text-left px-4 py-2 text-sm text-gray-800 hover:bg-gray-100 flex items-center gap-3",children:[jsxRuntime.jsx("span",{className:"w-5 h-5 flex items-center justify-center",children:J?"✓":""}),jsxRuntime.jsx("span",{children:"Show Annotation Tools"})]})]})]})})]})]})]}),!O&&J&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:"w-full h-px bg-gray-300"}),jsxRuntime.jsxs("div",{className:"flex items-center justify-center gap-4 flex-wrap",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-1 bg-white border border-gray-300 p-1 rounded-lg",children:[V.map(P=>jsxRuntime.jsx(ToolButton,{label:P.label,isActive:h===P.tool,onClick:()=>d(P.tool),children:P.icon},P.tool)),jsxRuntime.jsx("div",{className:"w-px h-6 bg-gray-300 mx-1"}),jsxRuntime.jsx(ToolButton,{label:"Delete",onClick:w,disabled:!R,children:jsxRuntime.jsx(TrashIcon,{})})]}),jsxRuntime.jsx("div",{className:"flex items-center gap-1 bg-white border border-gray-300 p-1 rounded-lg",children:Q.map(P=>jsxRuntime.jsx(ToolButton,{label:P.label,isActive:h===P.tool,onClick:()=>d(P.tool),children:P.icon},P.tool))}),jsxRuntime.jsx("div",{className:"flex items-center gap-1 bg-white border border-gray-300 p-1 rounded-lg",children:N.map(P=>jsxRuntime.jsx(ToolButton,{label:P.label,isActive:h===P.tool,onClick:()=>d(P.tool),children:P.icon},P.tool))}),jsxRuntime.jsxs("div",{className:"flex items-center gap-1 bg-white border border-gray-300 p-1 rounded-lg",children:[jsxRuntime.jsx(ToolButton,{label:"Stamp",isActive:h==="STAMP",onClick:()=>d("STAMP"),children:jsxRuntime.jsx(StampIcon,{})}),jsxRuntime.jsx("select",{value:M,onChange:P=>C(P.target.value),className:"bg-white border border-gray-300 rounded-md px-2 py-1 text-sm text-gray-800 focus:outline-none focus:ring-2 focus:ring-indigo-500",children:STAMPS.map(P=>jsxRuntime.jsx("option",{value:P,children:P},P))})]}),jsxRuntime.jsxs("div",{className:"flex items-center gap-2 bg-white border border-gray-300 p-1 rounded-lg",children:[jsxRuntime.jsx("input",{type:"color",value:l,onChange:P=>u(P.target.value),className:"w-8 h-8 p-0 border-none rounded-md cursor-pointer bg-transparent",title:"Select color"}),jsxRuntime.jsx("select",{value:p,onChange:P=>g(Number(P.target.value)),className:"bg-white border border-gray-300 rounded-md px-2 py-1 text-sm text-gray-800 focus:outline-none focus:ring-2 focus:ring-indigo-500",title:"Stroke Width",children:STROKE_WIDTHS.map(P=>jsxRuntime.jsxs("option",{value:P,children:[P,"px"]},P))}),jsxRuntime.jsx("select",{value:f,onChange:P=>v(Number(P.target.value)),className:"bg-white border border-gray-300 rounded-md px-2 py-1 text-sm text-gray-800 focus:outline-none focus:ring-2 focus:ring-indigo-500",title:"Font Size",children:FONT_SIZES.map(P=>jsxRuntime.jsxs("option",{value:P,children:[P,"pt"]},P))})]})]})]})]})},AnnotationLayer=t=>{const{width:e,height:r,zoom:n,activeTool:a,toolColor:s,strokeWidth:o,fontSize:h,addAnnotation:d,annotations:l,deleteAnnotation:u,updateAnnotation:p,selectedAnnotationId:g,setSelectedAnnotationId:f,signatureData:v,initialsData:y,activeStamp:x,readonly:m=!1}=t,[w,R]=react.useState({mode:"none",startPos:{x:0,y:0}}),[_,S]=react.useState(null),F=react.useRef(null),[A,D]=react.useState(null),[T,M]=react.useState(null),C=B=>{const V=B.currentTarget,Q=V.getScreenCTM();if(Q){const E=new DOMPoint(B.clientX,B.clientY).matrixTransform(Q.inverse());return{x:E.x/n,y:E.y/n}}const N=V.getBoundingClientRect();return{x:(B.clientX-N.left)/n,y:(B.clientY-N.top)/n}},k=B=>{if(m)return;const V=C(B);if(a!=="PAN"){if(a==="SELECT"){const Q=l.find(P=>P.id===g);if(Q){const P=getAnnotationBoundingBox(Q);if(P){const E=getResizeHandles(P);for(const I in E){const z=E[I],G=8/n;if(V.x>=z.x-G/2&&V.x<=z.x+G/2&&V.y>=z.y-G/2&&V.y<=z.y+G/2){R({mode:"resizing",handle:I,startPos:V,originalAnnotation:Q});return}}}if(isPointInAnnotation(V,Q,n)){R({mode:"moving",startPos:V,originalAnnotation:Q});return}}const N=l.slice().reverse().find(P=>isPointInAnnotation(V,P,n));f(N?N.id:null),N&&R({mode:"moving",startPos:V,originalAnnotation:N});return}["TEXT","STAMP","SIGNATURE","INITIALS"].includes(a)||(R({mode:"drawing",startPos:V}),["PEN","HIGHLIGHTER","UNDERLINE","STRIKETHROUGH","SQUIGGLY"].includes(a)&&S({type:a,points:[V],color:s,strokeWidth:o,id:"temp",page:0}))}},O=B=>{if(m)return;const V=C(B);if(a==="SELECT"&&w.mode==="none"&&g){const Q=l.find(N=>N.id===g);if(Q){const N=getAnnotationBoundingBox(Q);if(N){const P=getResizeHandles(N);let E=null;for(const I in P){const z=P[I],G=8/n;if(V.x>=z.x-G/2&&V.x<=z.x+G/2&&V.y>=z.y-G/2&&V.y<=z.y+G/2){E=I;break}}M(E)}else M(null)}else M(null)}else w.mode==="none"&&M(null);if(w.mode==="moving"&&w.originalAnnotation){const Q=V.x-w.startPos.x,N=V.y-w.startPos.y;S(moveAnnotation(w.originalAnnotation,Q,N))}else if(w.mode==="resizing"&&w.originalAnnotation&&w.handle){const Q=V.x-w.startPos.x,N=V.y-w.startPos.y;S(resizeAnnotation(w.originalAnnotation,w.handle,Q,N))}else if(w.mode==="drawing"){const{startPos:Q}=w;let N=null;switch(a){case"PEN":case"HIGHLIGHTER":case"UNDERLINE":case"STRIKETHROUGH":case"SQUIGGLY":N={..._,points:[..._.points,V]};break;case"RECTANGLE":N={type:"RECTANGLE",x:Math.min(Q.x,V.x),y:Math.min(Q.y,V.y),width:Math.abs(Q.x-V.x),height:Math.abs(Q.y-V.y),color:s,strokeWidth:o,id:"temp",page:0};break;case"CIRCLE":N={type:"CIRCLE",cx:(Q.x+V.x)/2,cy:(Q.y+V.y)/2,rx:Math.abs(Q.x-V.x)/2,ry:Math.abs(Q.y-V.y)/2,color:s,strokeWidth:o,id:"temp",page:0};break}N&&S(N)}},$=()=>{if(!m){if(w.mode==="moving"||w.mode==="resizing")_&&p(_);else if(w.mode==="drawing"&&_){const{id:B,page:V,...Q}=_;d(Q)}R({mode:"none",startPos:{x:0,y:0}}),S(null)}},K=B=>{if(m||w.mode!=="none")return;const V=C(B);if(a==="TEXT"&&(D(V),setTimeout(()=>{var Q;return(Q=F.current)==null?void 0:Q.focus()},0)),a==="STAMP"){const N=new Date().toLocaleString();d({type:"STAMP",x:V.x-70,y:V.y-25,width:140,height:55,text:x,fontSize:18,color:s,strokeWidth:2,timestamp:N})}a==="SIGNATURE"&&v&&d({type:"SIGNATURE",x:V.x-75,y:V.y-37.5,width:150,height:75,imageData:v,color:s,strokeWidth:0}),a==="INITIALS"&&y&&d({type:"INITIALS",x:V.x-40,y:V.y-20,width:80,height:40,imageData:y,color:s,strokeWidth:0})},J=()=>{if(m||!A||!F.current)return;const B=F.current.value.trim();B&&d({type:"TEXT",x:A.x,y:A.y,width:F.current.offsetWidth/n,height:F.current.offsetHeight/n,content:B,fontSize:h,color:s,strokeWidth:1}),D(null)},Y=_?l.map(B=>B.id===_.id?_:B):l;w.mode==="drawing"&&_&&!l.find(B=>B.id===_.id)&&Y.push(_);const se=getCursor(a,g,T,w.mode);return jsxRuntime.jsxs("div",{className:"absolute top-0 left-0",style:{cursor:se,pointerEvents:a==="PAN"?"none":"auto"},children:[jsxRuntime.jsx("svg",{width:e,height:r,onMouseDown:k,onMouseMove:O,onMouseUp:$,onMouseLeave:$,onClick:K,style:{pointerEvents:a==="PAN"?"none":"auto"},children:Y.map(B=>renderAnnotation(B,g,n))}),A&&jsxRuntime.jsx("textarea",{ref:F,onBlur:J,style:{position:"absolute",left:A.x*n,top:A.y*n,border:`1px dashed ${s}`,color:s,background:"rgba(255,255,255,0.9)",fontSize:`${h}px`,lineHeight:1.2,width:"auto",minWidth:"150px",height:"auto",minHeight:`${h*1.5}px`,resize:"both",outline:"none",overflow:"auto",zIndex:100,fontFamily:"sans-serif"}})]})};function renderAnnotation(t,e,r){const n=t.id===e,a={stroke:t.color,strokeWidth:t.strokeWidth};let s=null;switch(t.type){case"PEN":const h=t.points.map(f=>`${f.x*r},${f.y*r}`).join(" ");s=jsxRuntime.jsx("polyline",{points:h,fill:"none",...a,strokeLinecap:"round",strokeLinejoin:"round"});break;case"UNDERLINE":const d=t.points.map(f=>`${f.x*r},${f.y*r}`).join(" ");s=jsxRuntime.jsx("polyline",{points:d,fill:"none",...a,strokeLinecap:"round"});break;case"STRIKETHROUGH":const l=t.points.map(f=>`${f.x*r},${f.y*r}`).join(" ");s=jsxRuntime.jsx("polyline",{points:l,fill:"none",...a,strokeLinecap:"round"});break;case"SQUIGGLY":const u=t.points.map(f=>`${f.x*r},${f.y*r}`).join(" ");s=jsxRuntime.jsx("polyline",{points:u,fill:"none",...a});break;case"HIGHLIGHTER":const p=t.points.map(f=>`${f.x*r},${f.y*r}`).join(" ");s=jsxRuntime.jsx("polyline",{points:p,fill:"none",...a,strokeOpacity:.3,strokeWidth:t.strokeWidth*5,strokeLinecap:"round"});break;case"RECTANGLE":s=jsxRuntime.jsx("rect",{x:t.x*r,y:t.y*r,width:t.width*r,height:t.height*r,fill:"none",...a});break;case"CIRCLE":s=jsxRuntime.jsx("ellipse",{cx:t.cx*r,cy:t.cy*r,rx:t.rx*r,ry:t.ry*r,fill:"none",...a});break;case"TEXT":const g=t.content.split(`
|
|
7
|
+
`)){const O=document.createElement("div");O.append(k?document.createTextNode(k):document.createElement("br")),this.editorDiv.append(O)}},kr=function(k){const{value:O,fontSize:$,color:K,rect:J,pageIndex:Y}=b(this,S);return k.value!==O||k.fontSize!==$||k.rect.some((se,B)=>Math.abs(se-J[B])>=1)||k.color.some((se,B)=>se!==K[B])||k.pageIndex!==Y},nr=function(k=!1){if(!this.annotationElementId)return;if(te(this,m,yt).call(this),!k&&(this.width===0||this.height===0)){setTimeout(()=>te(this,m,nr).call(this,!0),0);return}const O=T._internalPadding*this.parentScale;b(this,S).rect=this.getRect(O,O)},$e(T,"_freeTextDefaultContent",""),$e(T,"_internalPadding",0),$e(T,"_defaultColor",null),$e(T,"_defaultFontSize",10),$e(T,"_type","freetext");let h=T;e.FreeTextEditor=h},(t,e,r)=>{var I,G,ot,Ir,ce,ve,me,xe,Se,Ce,ne,le,L,Z,re,he,ye,Fe,Pe,ie,_e,Te,Or,Et,ir,ar,Ee,Ie,ze,be,oe,ae,Re,sr,Ve,X,ge,ke,Nr,or;Object.defineProperty(e,"__esModule",{value:!0}),e.StampAnnotationElement=e.InkAnnotationElement=e.FreeTextAnnotationElement=e.AnnotationLayer=void 0;var n=r(1),a=r(6),s=r(3),o=r(30),h=r(31),d=r(32);const l=1e3,u=9,p=new WeakSet;function g(Ne){return{width:Ne[2]-Ne[0],height:Ne[3]-Ne[1]}}class f{static create(U){switch(U.data.annotationType){case n.AnnotationType.LINK:return new y(U);case n.AnnotationType.TEXT:return new S(U);case n.AnnotationType.WIDGET:switch(U.data.fieldType){case"Tx":return new w(U);case"Btn":return U.data.radioButton?new x(U):U.data.checkBox?new _(U):new F(U);case"Ch":return new A(U);case"Sig":return new R(U)}return new m(U);case n.AnnotationType.POPUP:return new D(U);case n.AnnotationType.FREETEXT:return new M(U);case n.AnnotationType.LINE:return new C(U);case n.AnnotationType.SQUARE:return new k(U);case n.AnnotationType.CIRCLE:return new O(U);case n.AnnotationType.POLYLINE:return new $(U);case n.AnnotationType.CARET:return new J(U);case n.AnnotationType.INK:return new Y(U);case n.AnnotationType.POLYGON:return new K(U);case n.AnnotationType.HIGHLIGHT:return new se(U);case n.AnnotationType.UNDERLINE:return new B(U);case n.AnnotationType.SQUIGGLY:return new V(U);case n.AnnotationType.STRIKEOUT:return new Q(U);case n.AnnotationType.STAMP:return new N(U);case n.AnnotationType.FILEATTACHMENT:return new P(U);default:return new v(U)}}}const z=class z{constructor(U,{isRenderable:j=!1,ignoreBorder:W=!1,createQuadrilaterals:fe=!1}={}){de(this,I,!1);this.isRenderable=j,this.data=U.data,this.layer=U.layer,this.linkService=U.linkService,this.downloadManager=U.downloadManager,this.imageResourcesPath=U.imageResourcesPath,this.renderForms=U.renderForms,this.svgFactory=U.svgFactory,this.annotationStorage=U.annotationStorage,this.enableScripting=U.enableScripting,this.hasJSActions=U.hasJSActions,this._fieldObjects=U.fieldObjects,this.parent=U.parent,j&&(this.container=this._createContainer(W)),fe&&this._createQuadrilaterals()}static _hasPopupData({titleObj:U,contentsObj:j,richText:W}){return!!(U!=null&&U.str||j!=null&&j.str||W!=null&&W.str)}get hasPopupData(){return z._hasPopupData(this.data)}_createContainer(U){const{data:j,parent:{page:W,viewport:fe}}=this,pe=document.createElement("section");pe.setAttribute("data-annotation-id",j.id),this instanceof m||(pe.tabIndex=l),pe.style.zIndex=this.parent.zIndex++,this.data.popupRef&&pe.setAttribute("aria-haspopup","dialog"),j.noRotate&&pe.classList.add("norotate");const{pageWidth:Ae,pageHeight:we,pageX:je,pageY:Le}=fe.rawDims;if(!j.rect||this instanceof D){const{rotation:Xe}=j;return!j.hasOwnCanvas&&Xe!==0&&this.setRotation(Xe,pe),pe}const{width:De,height:Ge}=g(j.rect),Oe=n.Util.normalizeRect([j.rect[0],W.view[3]-j.rect[1]+W.view[1],j.rect[2],W.view[3]-j.rect[3]+W.view[1]]);if(!U&&j.borderStyle.width>0){pe.style.borderWidth=`${j.borderStyle.width}px`;const Xe=j.borderStyle.horizontalCornerRadius,Ze=j.borderStyle.verticalCornerRadius;if(Xe>0||Ze>0){const Qe=`calc(${Xe}px * var(--scale-factor)) / calc(${Ze}px * var(--scale-factor))`;pe.style.borderRadius=Qe}else if(this instanceof x){const Qe=`calc(${De}px * var(--scale-factor)) / calc(${Ge}px * var(--scale-factor))`;pe.style.borderRadius=Qe}switch(j.borderStyle.style){case n.AnnotationBorderStyleType.SOLID:pe.style.borderStyle="solid";break;case n.AnnotationBorderStyleType.DASHED:pe.style.borderStyle="dashed";break;case n.AnnotationBorderStyleType.BEVELED:(0,n.warn)("Unimplemented border style: beveled");break;case n.AnnotationBorderStyleType.INSET:(0,n.warn)("Unimplemented border style: inset");break;case n.AnnotationBorderStyleType.UNDERLINE:pe.style.borderBottomStyle="solid";break}const Je=j.borderColor||null;Je?(ue(this,I,!0),pe.style.borderColor=n.Util.makeHexColor(Je[0]|0,Je[1]|0,Je[2]|0)):pe.style.borderWidth=0}pe.style.left=`${100*(Oe[0]-je)/Ae}%`,pe.style.top=`${100*(Oe[1]-Le)/we}%`;const{rotation:Ue}=j;return j.hasOwnCanvas||Ue===0?(pe.style.width=`${100*De/Ae}%`,pe.style.height=`${100*Ge/we}%`):this.setRotation(Ue,pe),pe}setRotation(U,j=this.container){if(!this.data.rect)return;const{pageWidth:W,pageHeight:fe}=this.parent.viewport.rawDims,{width:pe,height:Ae}=g(this.data.rect);let we,je;U%180===0?(we=100*pe/W,je=100*Ae/fe):(we=100*Ae/W,je=100*pe/fe),j.style.width=`${we}%`,j.style.height=`${je}%`,j.setAttribute("data-main-rotation",(360-U)%360)}get _commonActions(){const U=(j,W,fe)=>{const pe=fe.detail[j],Ae=pe[0],we=pe.slice(1);fe.target.style[W]=o.ColorConverters[`${Ae}_HTML`](we),this.annotationStorage.setValue(this.data.id,{[W]:o.ColorConverters[`${Ae}_rgb`](we)})};return(0,n.shadow)(this,"_commonActions",{display:j=>{const{display:W}=j.detail,fe=W%2===1;this.container.style.visibility=fe?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noView:fe,noPrint:W===1||W===2})},print:j=>{this.annotationStorage.setValue(this.data.id,{noPrint:!j.detail.print})},hidden:j=>{const{hidden:W}=j.detail;this.container.style.visibility=W?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noPrint:W,noView:W})},focus:j=>{setTimeout(()=>j.target.focus({preventScroll:!1}),0)},userName:j=>{j.target.title=j.detail.userName},readonly:j=>{j.target.disabled=j.detail.readonly},required:j=>{this._setRequired(j.target,j.detail.required)},bgColor:j=>{U("bgColor","backgroundColor",j)},fillColor:j=>{U("fillColor","backgroundColor",j)},fgColor:j=>{U("fgColor","color",j)},textColor:j=>{U("textColor","color",j)},borderColor:j=>{U("borderColor","borderColor",j)},strokeColor:j=>{U("strokeColor","borderColor",j)},rotation:j=>{const W=j.detail.rotation;this.setRotation(W),this.annotationStorage.setValue(this.data.id,{rotation:W})}})}_dispatchEventFromSandbox(U,j){const W=this._commonActions;for(const fe of Object.keys(j.detail)){const pe=U[fe]||W[fe];pe==null||pe(j)}}_setDefaultPropertiesFromJS(U){if(!this.enableScripting)return;const j=this.annotationStorage.getRawValue(this.data.id);if(!j)return;const W=this._commonActions;for(const[fe,pe]of Object.entries(j)){const Ae=W[fe];if(Ae){const we={detail:{[fe]:pe},target:U};Ae(we),delete j[fe]}}}_createQuadrilaterals(){if(!this.container)return;const{quadPoints:U}=this.data;if(!U)return;const[j,W,fe,pe]=this.data.rect;if(U.length===1){const[,{x:Ze,y:Je},{x:Qe,y:tt}]=U[0];if(fe===Ze&&pe===Je&&j===Qe&&W===tt)return}const{style:Ae}=this.container;let we;if(b(this,I)){const{borderColor:Ze,borderWidth:Je}=Ae;Ae.borderWidth=0,we=["url('data:image/svg+xml;utf8,",'<svg xmlns="http://www.w3.org/2000/svg"',' preserveAspectRatio="none" viewBox="0 0 1 1">',`<g fill="transparent" stroke="${Ze}" stroke-width="${Je}">`],this.container.classList.add("hasBorder")}const je=fe-j,Le=pe-W,{svgFactory:De}=this,Ge=De.createElement("svg");Ge.classList.add("quadrilateralsContainer"),Ge.setAttribute("width",0),Ge.setAttribute("height",0);const Oe=De.createElement("defs");Ge.append(Oe);const Ue=De.createElement("clipPath"),Xe=`clippath_${this.data.id}`;Ue.setAttribute("id",Xe),Ue.setAttribute("clipPathUnits","objectBoundingBox"),Oe.append(Ue);for(const[,{x:Ze,y:Je},{x:Qe,y:tt}]of U){const et=De.createElement("rect"),nt=(Qe-j)/je,at=(pe-Je)/Le,st=(Ze-Qe)/je,vr=(Je-tt)/Le;et.setAttribute("x",nt),et.setAttribute("y",at),et.setAttribute("width",st),et.setAttribute("height",vr),Ue.append(et),we==null||we.push(`<rect vector-effect="non-scaling-stroke" x="${nt}" y="${at}" width="${st}" height="${vr}"/>`)}b(this,I)&&(we.push("</g></svg>')"),Ae.backgroundImage=we.join("")),this.container.append(Ge),this.container.style.clipPath=`url(#${Xe})`}_createPopup(){const{container:U,data:j}=this;U.setAttribute("aria-haspopup","dialog");const W=new D({data:{color:j.color,titleObj:j.titleObj,modificationDate:j.modificationDate,contentsObj:j.contentsObj,richText:j.richText,parentRect:j.rect,borderStyle:0,id:`popup_${j.id}`,rotation:j.rotation},parent:this.parent,elements:[this]});this.parent.div.append(W.render())}render(){(0,n.unreachable)("Abstract method `AnnotationElement.render` called")}_getElementsByName(U,j=null){const W=[];if(this._fieldObjects){const fe=this._fieldObjects[U];if(fe)for(const{page:pe,id:Ae,exportValues:we}of fe){if(pe===-1||Ae===j)continue;const je=typeof we=="string"?we:null,Le=document.querySelector(`[data-element-id="${Ae}"]`);if(Le&&!p.has(Le)){(0,n.warn)(`_getElementsByName - element not allowed: ${Ae}`);continue}W.push({id:Ae,exportValue:je,domElement:Le})}return W}for(const fe of document.getElementsByName(U)){const{exportValue:pe}=fe,Ae=fe.getAttribute("data-element-id");Ae!==j&&p.has(fe)&&W.push({id:Ae,exportValue:pe,domElement:fe})}return W}show(){var U;this.container&&(this.container.hidden=!1),(U=this.popup)==null||U.maybeShow()}hide(){var U;this.container&&(this.container.hidden=!0),(U=this.popup)==null||U.forceHide()}getElementsToTriggerPopup(){return this.container}addHighlightArea(){const U=this.getElementsToTriggerPopup();if(Array.isArray(U))for(const j of U)j.classList.add("highlightArea");else U.classList.add("highlightArea")}_editOnDoubleClick(){const{annotationEditorType:U,data:{id:j}}=this;this.container.addEventListener("dblclick",()=>{var W;(W=this.linkService.eventBus)==null||W.dispatch("switchannotationeditormode",{source:this,mode:U,editId:j})})}};I=new WeakMap;let v=z;class y extends v{constructor(j,W=null){super(j,{isRenderable:!0,ignoreBorder:!!(W!=null&&W.ignoreBorder),createQuadrilaterals:!0});de(this,G);this.isTooltipOnly=j.data.isTooltipOnly}render(){const{data:j,linkService:W}=this,fe=document.createElement("a");fe.setAttribute("data-element-id",j.id);let pe=!1;return j.url?(W.addLinkAttributes(fe,j.url,j.newWindow),pe=!0):j.action?(this._bindNamedAction(fe,j.action),pe=!0):j.attachment?(this._bindAttachment(fe,j.attachment),pe=!0):j.setOCGState?(te(this,G,Ir).call(this,fe,j.setOCGState),pe=!0):j.dest?(this._bindLink(fe,j.dest),pe=!0):(j.actions&&(j.actions.Action||j.actions["Mouse Up"]||j.actions["Mouse Down"])&&this.enableScripting&&this.hasJSActions&&(this._bindJSAction(fe,j),pe=!0),j.resetForm?(this._bindResetFormAction(fe,j.resetForm),pe=!0):this.isTooltipOnly&&!pe&&(this._bindLink(fe,""),pe=!0)),this.container.classList.add("linkAnnotation"),pe&&this.container.append(fe),this.container}_bindLink(j,W){j.href=this.linkService.getDestinationHash(W),j.onclick=()=>(W&&this.linkService.goToDestination(W),!1),(W||W==="")&&te(this,G,ot).call(this)}_bindNamedAction(j,W){j.href=this.linkService.getAnchorUrl(""),j.onclick=()=>(this.linkService.executeNamedAction(W),!1),te(this,G,ot).call(this)}_bindAttachment(j,W){j.href=this.linkService.getAnchorUrl(""),j.onclick=()=>{var fe;return(fe=this.downloadManager)==null||fe.openOrDownloadData(this.container,W.content,W.filename),!1},te(this,G,ot).call(this)}_bindJSAction(j,W){j.href=this.linkService.getAnchorUrl("");const fe=new Map([["Action","onclick"],["Mouse Up","onmouseup"],["Mouse Down","onmousedown"]]);for(const pe of Object.keys(W.actions)){const Ae=fe.get(pe);Ae&&(j[Ae]=()=>{var we;return(we=this.linkService.eventBus)==null||we.dispatch("dispatcheventinsandbox",{source:this,detail:{id:W.id,name:pe}}),!1})}j.onclick||(j.onclick=()=>!1),te(this,G,ot).call(this)}_bindResetFormAction(j,W){const fe=j.onclick;if(fe||(j.href=this.linkService.getAnchorUrl("")),te(this,G,ot).call(this),!this._fieldObjects){(0,n.warn)('_bindResetFormAction - "resetForm" action not supported, ensure that the `fieldObjects` parameter is provided.'),fe||(j.onclick=()=>!1);return}j.onclick=()=>{var Ge;fe==null||fe();const{fields:pe,refs:Ae,include:we}=W,je=[];if(pe.length!==0||Ae.length!==0){const Oe=new Set(Ae);for(const Ue of pe){const Xe=this._fieldObjects[Ue]||[];for(const{id:Ze}of Xe)Oe.add(Ze)}for(const Ue of Object.values(this._fieldObjects))for(const Xe of Ue)Oe.has(Xe.id)===we&&je.push(Xe)}else for(const Oe of Object.values(this._fieldObjects))je.push(...Oe);const Le=this.annotationStorage,De=[];for(const Oe of je){const{id:Ue}=Oe;switch(De.push(Ue),Oe.type){case"text":{const Ze=Oe.defaultValue||"";Le.setValue(Ue,{value:Ze});break}case"checkbox":case"radiobutton":{const Ze=Oe.defaultValue===Oe.exportValues;Le.setValue(Ue,{value:Ze});break}case"combobox":case"listbox":{const Ze=Oe.defaultValue||"";Le.setValue(Ue,{value:Ze});break}default:continue}const Xe=document.querySelector(`[data-element-id="${Ue}"]`);if(Xe){if(!p.has(Xe)){(0,n.warn)(`_bindResetFormAction - element not allowed: ${Ue}`);continue}}else continue;Xe.dispatchEvent(new Event("resetform"))}return this.enableScripting&&((Ge=this.linkService.eventBus)==null||Ge.dispatch("dispatcheventinsandbox",{source:this,detail:{id:"app",ids:De,name:"ResetForm"}})),!1}}}G=new WeakSet,ot=function(){this.container.setAttribute("data-internal-link","")},Ir=function(j,W){j.href=this.linkService.getAnchorUrl(""),j.onclick=()=>(this.linkService.executeSetOCGState(W),!1),te(this,G,ot).call(this)};class S extends v{constructor(U){super(U,{isRenderable:!0})}render(){this.container.classList.add("textAnnotation");const U=document.createElement("img");return U.src=this.imageResourcesPath+"annotation-"+this.data.name.toLowerCase()+".svg",U.alt="[{{type}} Annotation]",U.dataset.l10nId="text_annotation_type",U.dataset.l10nArgs=JSON.stringify({type:this.data.name}),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.append(U),this.container}}class m extends v{render(){return this.data.alternativeText&&(this.container.title=this.data.alternativeText),this.container}showElementAndHideCanvas(U){var j;this.data.hasOwnCanvas&&(((j=U.previousSibling)==null?void 0:j.nodeName)==="CANVAS"&&(U.previousSibling.hidden=!0),U.hidden=!1)}_getKeyModifier(U){const{isWin:j,isMac:W}=n.FeatureTest.platform;return j&&U.ctrlKey||W&&U.metaKey}_setEventListener(U,j,W,fe,pe){W.includes("mouse")?U.addEventListener(W,Ae=>{var we;(we=this.linkService.eventBus)==null||we.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:fe,value:pe(Ae),shift:Ae.shiftKey,modifier:this._getKeyModifier(Ae)}})}):U.addEventListener(W,Ae=>{var we;if(W==="blur"){if(!j.focused||!Ae.relatedTarget)return;j.focused=!1}else if(W==="focus"){if(j.focused)return;j.focused=!0}pe&&((we=this.linkService.eventBus)==null||we.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:fe,value:pe(Ae)}}))})}_setEventListeners(U,j,W,fe){var pe,Ae,we;for(const[je,Le]of W)(Le==="Action"||(pe=this.data.actions)!=null&&pe[Le])&&((Le==="Focus"||Le==="Blur")&&(j||(j={focused:!1})),this._setEventListener(U,j,je,Le,fe),Le==="Focus"&&!((Ae=this.data.actions)!=null&&Ae.Blur)?this._setEventListener(U,j,"blur","Blur",null):Le==="Blur"&&!((we=this.data.actions)!=null&&we.Focus)&&this._setEventListener(U,j,"focus","Focus",null))}_setBackgroundColor(U){const j=this.data.backgroundColor||null;U.style.backgroundColor=j===null?"transparent":n.Util.makeHexColor(j[0],j[1],j[2])}_setTextStyle(U){const j=["left","center","right"],{fontColor:W}=this.data.defaultAppearanceData,fe=this.data.defaultAppearanceData.fontSize||u,pe=U.style;let Ae;const we=2,je=Le=>Math.round(10*Le)/10;if(this.data.multiLine){const Le=Math.abs(this.data.rect[3]-this.data.rect[1]-we),De=Math.round(Le/(n.LINE_FACTOR*fe))||1,Ge=Le/De;Ae=Math.min(fe,je(Ge/n.LINE_FACTOR))}else{const Le=Math.abs(this.data.rect[3]-this.data.rect[1]-we);Ae=Math.min(fe,je(Le/n.LINE_FACTOR))}pe.fontSize=`calc(${Ae}px * var(--scale-factor))`,pe.color=n.Util.makeHexColor(W[0],W[1],W[2]),this.data.textAlignment!==null&&(pe.textAlign=j[this.data.textAlignment])}_setRequired(U,j){j?U.setAttribute("required",!0):U.removeAttribute("required"),U.setAttribute("aria-required",j)}}class w extends m{constructor(U){const j=U.renderForms||!U.data.hasAppearance&&!!U.data.fieldValue;super(U,{isRenderable:j})}setPropertyOnSiblings(U,j,W,fe){const pe=this.annotationStorage;for(const Ae of this._getElementsByName(U.name,U.id))Ae.domElement&&(Ae.domElement[j]=W),pe.setValue(Ae.id,{[fe]:W})}render(){var fe,pe;const U=this.annotationStorage,j=this.data.id;this.container.classList.add("textWidgetAnnotation");let W=null;if(this.renderForms){const Ae=U.getValue(j,{value:this.data.fieldValue});let we=Ae.value||"";const je=U.getValue(j,{charLimit:this.data.maxLen}).charLimit;je&&we.length>je&&(we=we.slice(0,je));let Le=Ae.formattedValue||((fe=this.data.textContent)==null?void 0:fe.join(`
|
|
8
|
+
`))||null;Le&&this.data.comb&&(Le=Le.replaceAll(/\s+/g,""));const De={userValue:we,formattedValue:Le,lastCommittedValue:null,commitKey:1,focused:!1};this.data.multiLine?(W=document.createElement("textarea"),W.textContent=Le??we,this.data.doNotScroll&&(W.style.overflowY="hidden")):(W=document.createElement("input"),W.type="text",W.setAttribute("value",Le??we),this.data.doNotScroll&&(W.style.overflowX="hidden")),this.data.hasOwnCanvas&&(W.hidden=!0),p.add(W),W.setAttribute("data-element-id",j),W.disabled=this.data.readOnly,W.name=this.data.fieldName,W.tabIndex=l,this._setRequired(W,this.data.required),je&&(W.maxLength=je),W.addEventListener("input",Oe=>{U.setValue(j,{value:Oe.target.value}),this.setPropertyOnSiblings(W,"value",Oe.target.value,"value"),De.formattedValue=null}),W.addEventListener("resetform",Oe=>{const Ue=this.data.defaultFieldValue??"";W.value=De.userValue=Ue,De.formattedValue=null});let Ge=Oe=>{const{formattedValue:Ue}=De;Ue!=null&&(Oe.target.value=Ue),Oe.target.scrollLeft=0};if(this.enableScripting&&this.hasJSActions){W.addEventListener("focus",Ue=>{if(De.focused)return;const{target:Xe}=Ue;De.userValue&&(Xe.value=De.userValue),De.lastCommittedValue=Xe.value,De.commitKey=1,De.focused=!0}),W.addEventListener("updatefromsandbox",Ue=>{this.showElementAndHideCanvas(Ue.target);const Xe={value(Ze){De.userValue=Ze.detail.value??"",U.setValue(j,{value:De.userValue.toString()}),Ze.target.value=De.userValue},formattedValue(Ze){const{formattedValue:Je}=Ze.detail;De.formattedValue=Je,Je!=null&&Ze.target!==document.activeElement&&(Ze.target.value=Je),U.setValue(j,{formattedValue:Je})},selRange(Ze){Ze.target.setSelectionRange(...Ze.detail.selRange)},charLimit:Ze=>{var et;const{charLimit:Je}=Ze.detail,{target:Qe}=Ze;if(Je===0){Qe.removeAttribute("maxLength");return}Qe.setAttribute("maxLength",Je);let tt=De.userValue;!tt||tt.length<=Je||(tt=tt.slice(0,Je),Qe.value=De.userValue=tt,U.setValue(j,{value:tt}),(et=this.linkService.eventBus)==null||et.dispatch("dispatcheventinsandbox",{source:this,detail:{id:j,name:"Keystroke",value:tt,willCommit:!0,commitKey:1,selStart:Qe.selectionStart,selEnd:Qe.selectionEnd}}))}};this._dispatchEventFromSandbox(Xe,Ue)}),W.addEventListener("keydown",Ue=>{var Je;De.commitKey=1;let Xe=-1;if(Ue.key==="Escape"?Xe=0:Ue.key==="Enter"&&!this.data.multiLine?Xe=2:Ue.key==="Tab"&&(De.commitKey=3),Xe===-1)return;const{value:Ze}=Ue.target;De.lastCommittedValue!==Ze&&(De.lastCommittedValue=Ze,De.userValue=Ze,(Je=this.linkService.eventBus)==null||Je.dispatch("dispatcheventinsandbox",{source:this,detail:{id:j,name:"Keystroke",value:Ze,willCommit:!0,commitKey:Xe,selStart:Ue.target.selectionStart,selEnd:Ue.target.selectionEnd}}))});const Oe=Ge;Ge=null,W.addEventListener("blur",Ue=>{var Ze;if(!De.focused||!Ue.relatedTarget)return;De.focused=!1;const{value:Xe}=Ue.target;De.userValue=Xe,De.lastCommittedValue!==Xe&&((Ze=this.linkService.eventBus)==null||Ze.dispatch("dispatcheventinsandbox",{source:this,detail:{id:j,name:"Keystroke",value:Xe,willCommit:!0,commitKey:De.commitKey,selStart:Ue.target.selectionStart,selEnd:Ue.target.selectionEnd}})),Oe(Ue)}),(pe=this.data.actions)!=null&&pe.Keystroke&&W.addEventListener("beforeinput",Ue=>{var at;De.lastCommittedValue=null;const{data:Xe,target:Ze}=Ue,{value:Je,selectionStart:Qe,selectionEnd:tt}=Ze;let et=Qe,nt=tt;switch(Ue.inputType){case"deleteWordBackward":{const st=Je.substring(0,Qe).match(/\w*[^\w]*$/);st&&(et-=st[0].length);break}case"deleteWordForward":{const st=Je.substring(Qe).match(/^[^\w]*\w*/);st&&(nt+=st[0].length);break}case"deleteContentBackward":Qe===tt&&(et-=1);break;case"deleteContentForward":Qe===tt&&(nt+=1);break}Ue.preventDefault(),(at=this.linkService.eventBus)==null||at.dispatch("dispatcheventinsandbox",{source:this,detail:{id:j,name:"Keystroke",value:Je,change:Xe||"",willCommit:!1,selStart:et,selEnd:nt}})}),this._setEventListeners(W,De,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],Ue=>Ue.target.value)}if(Ge&&W.addEventListener("blur",Ge),this.data.comb){const Ue=(this.data.rect[2]-this.data.rect[0])/je;W.classList.add("comb"),W.style.letterSpacing=`calc(${Ue}px * var(--scale-factor) - 1ch)`}}else W=document.createElement("div"),W.textContent=this.data.fieldValue,W.style.verticalAlign="middle",W.style.display="table-cell";return this._setTextStyle(W),this._setBackgroundColor(W),this._setDefaultPropertiesFromJS(W),this.container.append(W),this.container}}class R extends m{constructor(U){super(U,{isRenderable:!!U.data.hasOwnCanvas})}}class _ extends m{constructor(U){super(U,{isRenderable:U.renderForms})}render(){const U=this.annotationStorage,j=this.data,W=j.id;let fe=U.getValue(W,{value:j.exportValue===j.fieldValue}).value;typeof fe=="string"&&(fe=fe!=="Off",U.setValue(W,{value:fe})),this.container.classList.add("buttonWidgetAnnotation","checkBox");const pe=document.createElement("input");return p.add(pe),pe.setAttribute("data-element-id",W),pe.disabled=j.readOnly,this._setRequired(pe,this.data.required),pe.type="checkbox",pe.name=j.fieldName,fe&&pe.setAttribute("checked",!0),pe.setAttribute("exportValue",j.exportValue),pe.tabIndex=l,pe.addEventListener("change",Ae=>{const{name:we,checked:je}=Ae.target;for(const Le of this._getElementsByName(we,W)){const De=je&&Le.exportValue===j.exportValue;Le.domElement&&(Le.domElement.checked=De),U.setValue(Le.id,{value:De})}U.setValue(W,{value:je})}),pe.addEventListener("resetform",Ae=>{const we=j.defaultFieldValue||"Off";Ae.target.checked=we===j.exportValue}),this.enableScripting&&this.hasJSActions&&(pe.addEventListener("updatefromsandbox",Ae=>{const we={value(je){je.target.checked=je.detail.value!=="Off",U.setValue(W,{value:je.target.checked})}};this._dispatchEventFromSandbox(we,Ae)}),this._setEventListeners(pe,null,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],Ae=>Ae.target.checked)),this._setBackgroundColor(pe),this._setDefaultPropertiesFromJS(pe),this.container.append(pe),this.container}}class x extends m{constructor(U){super(U,{isRenderable:U.renderForms})}render(){this.container.classList.add("buttonWidgetAnnotation","radioButton");const U=this.annotationStorage,j=this.data,W=j.id;let fe=U.getValue(W,{value:j.fieldValue===j.buttonValue}).value;typeof fe=="string"&&(fe=fe!==j.buttonValue,U.setValue(W,{value:fe}));const pe=document.createElement("input");if(p.add(pe),pe.setAttribute("data-element-id",W),pe.disabled=j.readOnly,this._setRequired(pe,this.data.required),pe.type="radio",pe.name=j.fieldName,fe&&pe.setAttribute("checked",!0),pe.tabIndex=l,pe.addEventListener("change",Ae=>{const{name:we,checked:je}=Ae.target;for(const Le of this._getElementsByName(we,W))U.setValue(Le.id,{value:!1});U.setValue(W,{value:je})}),pe.addEventListener("resetform",Ae=>{const we=j.defaultFieldValue;Ae.target.checked=we!=null&&we===j.buttonValue}),this.enableScripting&&this.hasJSActions){const Ae=j.buttonValue;pe.addEventListener("updatefromsandbox",we=>{const je={value:Le=>{const De=Ae===Le.detail.value;for(const Ge of this._getElementsByName(Le.target.name)){const Oe=De&&Ge.id===W;Ge.domElement&&(Ge.domElement.checked=Oe),U.setValue(Ge.id,{value:Oe})}}};this._dispatchEventFromSandbox(je,we)}),this._setEventListeners(pe,null,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],we=>we.target.checked)}return this._setBackgroundColor(pe),this._setDefaultPropertiesFromJS(pe),this.container.append(pe),this.container}}class F extends y{constructor(U){super(U,{ignoreBorder:U.data.hasAppearance})}render(){const U=super.render();U.classList.add("buttonWidgetAnnotation","pushButton"),this.data.alternativeText&&(U.title=this.data.alternativeText);const j=U.lastChild;return this.enableScripting&&this.hasJSActions&&j&&(this._setDefaultPropertiesFromJS(j),j.addEventListener("updatefromsandbox",W=>{this._dispatchEventFromSandbox({},W)})),U}}class A extends m{constructor(U){super(U,{isRenderable:U.renderForms})}render(){this.container.classList.add("choiceWidgetAnnotation");const U=this.annotationStorage,j=this.data.id,W=U.getValue(j,{value:this.data.fieldValue}),fe=document.createElement("select");p.add(fe),fe.setAttribute("data-element-id",j),fe.disabled=this.data.readOnly,this._setRequired(fe,this.data.required),fe.name=this.data.fieldName,fe.tabIndex=l;let pe=this.data.combo&&this.data.options.length>0;this.data.combo||(fe.size=this.data.options.length,this.data.multiSelect&&(fe.multiple=!0)),fe.addEventListener("resetform",De=>{const Ge=this.data.defaultFieldValue;for(const Oe of fe.options)Oe.selected=Oe.value===Ge});for(const De of this.data.options){const Ge=document.createElement("option");Ge.textContent=De.displayValue,Ge.value=De.exportValue,W.value.includes(De.exportValue)&&(Ge.setAttribute("selected",!0),pe=!1),fe.append(Ge)}let Ae=null;if(pe){const De=document.createElement("option");De.value=" ",De.setAttribute("hidden",!0),De.setAttribute("selected",!0),fe.prepend(De),Ae=()=>{De.remove(),fe.removeEventListener("input",Ae),Ae=null},fe.addEventListener("input",Ae)}const we=De=>{const Ge=De?"value":"textContent",{options:Oe,multiple:Ue}=fe;return Ue?Array.prototype.filter.call(Oe,Xe=>Xe.selected).map(Xe=>Xe[Ge]):Oe.selectedIndex===-1?null:Oe[Oe.selectedIndex][Ge]};let je=we(!1);const Le=De=>{const Ge=De.target.options;return Array.prototype.map.call(Ge,Oe=>({displayValue:Oe.textContent,exportValue:Oe.value}))};return this.enableScripting&&this.hasJSActions?(fe.addEventListener("updatefromsandbox",De=>{const Ge={value(Oe){Ae==null||Ae();const Ue=Oe.detail.value,Xe=new Set(Array.isArray(Ue)?Ue:[Ue]);for(const Ze of fe.options)Ze.selected=Xe.has(Ze.value);U.setValue(j,{value:we(!0)}),je=we(!1)},multipleSelection(Oe){fe.multiple=!0},remove(Oe){const Ue=fe.options,Xe=Oe.detail.remove;Ue[Xe].selected=!1,fe.remove(Xe),Ue.length>0&&Array.prototype.findIndex.call(Ue,Je=>Je.selected)===-1&&(Ue[0].selected=!0),U.setValue(j,{value:we(!0),items:Le(Oe)}),je=we(!1)},clear(Oe){for(;fe.length!==0;)fe.remove(0);U.setValue(j,{value:null,items:[]}),je=we(!1)},insert(Oe){const{index:Ue,displayValue:Xe,exportValue:Ze}=Oe.detail.insert,Je=fe.children[Ue],Qe=document.createElement("option");Qe.textContent=Xe,Qe.value=Ze,Je?Je.before(Qe):fe.append(Qe),U.setValue(j,{value:we(!0),items:Le(Oe)}),je=we(!1)},items(Oe){const{items:Ue}=Oe.detail;for(;fe.length!==0;)fe.remove(0);for(const Xe of Ue){const{displayValue:Ze,exportValue:Je}=Xe,Qe=document.createElement("option");Qe.textContent=Ze,Qe.value=Je,fe.append(Qe)}fe.options.length>0&&(fe.options[0].selected=!0),U.setValue(j,{value:we(!0),items:Le(Oe)}),je=we(!1)},indices(Oe){const Ue=new Set(Oe.detail.indices);for(const Xe of Oe.target.options)Xe.selected=Ue.has(Xe.index);U.setValue(j,{value:we(!0)}),je=we(!1)},editable(Oe){Oe.target.disabled=!Oe.detail.editable}};this._dispatchEventFromSandbox(Ge,De)}),fe.addEventListener("input",De=>{var Oe;const Ge=we(!0);U.setValue(j,{value:Ge}),De.preventDefault(),(Oe=this.linkService.eventBus)==null||Oe.dispatch("dispatcheventinsandbox",{source:this,detail:{id:j,name:"Keystroke",value:je,changeEx:Ge,willCommit:!1,commitKey:1,keyDown:!1}})}),this._setEventListeners(fe,null,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"],["input","Action"],["input","Validate"]],De=>De.target.value)):fe.addEventListener("input",function(De){U.setValue(j,{value:we(!0)})}),this.data.combo&&this._setTextStyle(fe),this._setBackgroundColor(fe),this._setDefaultPropertiesFromJS(fe),this.container.append(fe),this.container}}class D extends v{constructor(U){const{data:j,elements:W}=U;super(U,{isRenderable:v._hasPopupData(j)}),this.elements=W}render(){this.container.classList.add("popupAnnotation");const U=new T({container:this.container,color:this.data.color,titleObj:this.data.titleObj,modificationDate:this.data.modificationDate,contentsObj:this.data.contentsObj,richText:this.data.richText,rect:this.data.rect,parentRect:this.data.parentRect||null,parent:this.parent,elements:this.elements,open:this.data.open}),j=[];for(const W of this.elements)W.popup=U,j.push(W.data.id),W.addHighlightArea();return this.container.setAttribute("aria-controls",j.map(W=>`${n.AnnotationPrefix}${W}`).join(",")),this.container}}class T{constructor({container:U,color:j,elements:W,titleObj:fe,modificationDate:pe,contentsObj:Ae,richText:we,parent:je,rect:Le,parentRect:De,open:Ge}){de(this,Te);de(this,ce,null);de(this,ve,te(this,Te,Or).bind(this));de(this,me,te(this,Te,ar).bind(this));de(this,xe,te(this,Te,ir).bind(this));de(this,Se,te(this,Te,Et).bind(this));de(this,Ce,null);de(this,ne,null);de(this,le,null);de(this,L,null);de(this,Z,null);de(this,re,null);de(this,he,!1);de(this,ye,null);de(this,Fe,null);de(this,Pe,null);de(this,ie,null);de(this,_e,!1);var Ue;ue(this,ne,U),ue(this,ie,fe),ue(this,le,Ae),ue(this,Pe,we),ue(this,Z,je),ue(this,Ce,j),ue(this,Fe,Le),ue(this,re,De),ue(this,L,W);const Oe=a.PDFDateString.toDateObject(pe);Oe&&ue(this,ce,je.l10n.get("annotation_date_string",{date:Oe.toLocaleDateString(),time:Oe.toLocaleTimeString()})),this.trigger=W.flatMap(Xe=>Xe.getElementsToTriggerPopup());for(const Xe of this.trigger)Xe.addEventListener("click",b(this,Se)),Xe.addEventListener("mouseenter",b(this,xe)),Xe.addEventListener("mouseleave",b(this,me)),Xe.classList.add("popupTriggerArea");for(const Xe of W)(Ue=Xe.container)==null||Ue.addEventListener("keydown",b(this,ve));b(this,ne).hidden=!0,Ge&&te(this,Te,Et).call(this)}render(){if(b(this,ye))return;const{page:{view:U},viewport:{rawDims:{pageWidth:j,pageHeight:W,pageX:fe,pageY:pe}}}=b(this,Z),Ae=ue(this,ye,document.createElement("div"));if(Ae.className="popup",b(this,Ce)){const et=Ae.style.outlineColor=n.Util.makeHexColor(...b(this,Ce));CSS.supports("background-color","color-mix(in srgb, red 30%, white)")?Ae.style.backgroundColor=`color-mix(in srgb, ${et} 30%, white)`:Ae.style.backgroundColor=n.Util.makeHexColor(...b(this,Ce).map(at=>Math.floor(.7*(255-at)+at)))}const we=document.createElement("span");we.className="header";const je=document.createElement("h1");if(we.append(je),{dir:je.dir,str:je.textContent}=b(this,ie),Ae.append(we),b(this,ce)){const et=document.createElement("span");et.classList.add("popupDate"),b(this,ce).then(nt=>{et.textContent=nt}),we.append(et)}const Le=b(this,le),De=b(this,Pe);if(De!=null&&De.str&&(!(Le!=null&&Le.str)||Le.str===De.str))d.XfaLayer.render({xfaHtml:De.html,intent:"richText",div:Ae}),Ae.lastChild.classList.add("richText","popupContent");else{const et=this._formatContents(Le);Ae.append(et)}let Ge=!!b(this,re),Oe=Ge?b(this,re):b(this,Fe);for(const et of b(this,L))if(!Oe||n.Util.intersect(et.data.rect,Oe)!==null){Oe=et.data.rect,Ge=!0;break}const Ue=n.Util.normalizeRect([Oe[0],U[3]-Oe[1]+U[1],Oe[2],U[3]-Oe[3]+U[1]]),Ze=Ge?Oe[2]-Oe[0]+5:0,Je=Ue[0]+Ze,Qe=Ue[1],{style:tt}=b(this,ne);tt.left=`${100*(Je-fe)/j}%`,tt.top=`${100*(Qe-pe)/W}%`,b(this,ne).append(Ae)}_formatContents({str:U,dir:j}){const W=document.createElement("p");W.classList.add("popupContent"),W.dir=j;const fe=U.split(/(?:\r\n?|\n)/);for(let pe=0,Ae=fe.length;pe<Ae;++pe){const we=fe[pe];W.append(document.createTextNode(we)),pe<Ae-1&&W.append(document.createElement("br"))}return W}forceHide(){ue(this,_e,this.isVisible),b(this,_e)&&(b(this,ne).hidden=!0)}maybeShow(){b(this,_e)&&(ue(this,_e,!1),b(this,ne).hidden=!1)}get isVisible(){return b(this,ne).hidden===!1}}ce=new WeakMap,ve=new WeakMap,me=new WeakMap,xe=new WeakMap,Se=new WeakMap,Ce=new WeakMap,ne=new WeakMap,le=new WeakMap,L=new WeakMap,Z=new WeakMap,re=new WeakMap,he=new WeakMap,ye=new WeakMap,Fe=new WeakMap,Pe=new WeakMap,ie=new WeakMap,_e=new WeakMap,Te=new WeakSet,Or=function(U){U.altKey||U.shiftKey||U.ctrlKey||U.metaKey||(U.key==="Enter"||U.key==="Escape"&&b(this,he))&&te(this,Te,Et).call(this)},Et=function(){ue(this,he,!b(this,he)),b(this,he)?(te(this,Te,ir).call(this),b(this,ne).addEventListener("click",b(this,Se)),b(this,ne).addEventListener("keydown",b(this,ve))):(te(this,Te,ar).call(this),b(this,ne).removeEventListener("click",b(this,Se)),b(this,ne).removeEventListener("keydown",b(this,ve)))},ir=function(){b(this,ye)||this.render(),this.isVisible?b(this,he)&&b(this,ne).classList.add("focused"):(b(this,ne).hidden=!1,b(this,ne).style.zIndex=parseInt(b(this,ne).style.zIndex)+1e3)},ar=function(){b(this,ne).classList.remove("focused"),!(b(this,he)||!this.isVisible)&&(b(this,ne).hidden=!0,b(this,ne).style.zIndex=parseInt(b(this,ne).style.zIndex)-1e3)};class M extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0}),this.textContent=U.data.textContent,this.textPosition=U.data.textPosition,this.annotationEditorType=n.AnnotationEditorType.FREETEXT}render(){if(this.container.classList.add("freeTextAnnotation"),this.textContent){const U=document.createElement("div");U.classList.add("annotationTextContent"),U.setAttribute("role","comment");for(const j of this.textContent){const W=document.createElement("span");W.textContent=j,U.append(W)}this.container.append(U)}return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this._editOnDoubleClick(),this.container}}e.FreeTextAnnotationElement=M;class C extends v{constructor(j){super(j,{isRenderable:!0,ignoreBorder:!0});de(this,Ee,null)}render(){this.container.classList.add("lineAnnotation");const j=this.data,{width:W,height:fe}=g(j.rect),pe=this.svgFactory.create(W,fe,!0),Ae=ue(this,Ee,this.svgFactory.createElement("svg:line"));return Ae.setAttribute("x1",j.rect[2]-j.lineCoordinates[0]),Ae.setAttribute("y1",j.rect[3]-j.lineCoordinates[1]),Ae.setAttribute("x2",j.rect[2]-j.lineCoordinates[2]),Ae.setAttribute("y2",j.rect[3]-j.lineCoordinates[3]),Ae.setAttribute("stroke-width",j.borderStyle.width||1),Ae.setAttribute("stroke","transparent"),Ae.setAttribute("fill","transparent"),pe.append(Ae),this.container.append(pe),!j.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return b(this,Ee)}addHighlightArea(){this.container.classList.add("highlightArea")}}Ee=new WeakMap;class k extends v{constructor(j){super(j,{isRenderable:!0,ignoreBorder:!0});de(this,Ie,null)}render(){this.container.classList.add("squareAnnotation");const j=this.data,{width:W,height:fe}=g(j.rect),pe=this.svgFactory.create(W,fe,!0),Ae=j.borderStyle.width,we=ue(this,Ie,this.svgFactory.createElement("svg:rect"));return we.setAttribute("x",Ae/2),we.setAttribute("y",Ae/2),we.setAttribute("width",W-Ae),we.setAttribute("height",fe-Ae),we.setAttribute("stroke-width",Ae||1),we.setAttribute("stroke","transparent"),we.setAttribute("fill","transparent"),pe.append(we),this.container.append(pe),!j.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return b(this,Ie)}addHighlightArea(){this.container.classList.add("highlightArea")}}Ie=new WeakMap;class O extends v{constructor(j){super(j,{isRenderable:!0,ignoreBorder:!0});de(this,ze,null)}render(){this.container.classList.add("circleAnnotation");const j=this.data,{width:W,height:fe}=g(j.rect),pe=this.svgFactory.create(W,fe,!0),Ae=j.borderStyle.width,we=ue(this,ze,this.svgFactory.createElement("svg:ellipse"));return we.setAttribute("cx",W/2),we.setAttribute("cy",fe/2),we.setAttribute("rx",W/2-Ae/2),we.setAttribute("ry",fe/2-Ae/2),we.setAttribute("stroke-width",Ae||1),we.setAttribute("stroke","transparent"),we.setAttribute("fill","transparent"),pe.append(we),this.container.append(pe),!j.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return b(this,ze)}addHighlightArea(){this.container.classList.add("highlightArea")}}ze=new WeakMap;class $ extends v{constructor(j){super(j,{isRenderable:!0,ignoreBorder:!0});de(this,be,null);this.containerClassName="polylineAnnotation",this.svgElementName="svg:polyline"}render(){this.container.classList.add(this.containerClassName);const j=this.data,{width:W,height:fe}=g(j.rect),pe=this.svgFactory.create(W,fe,!0);let Ae=[];for(const je of j.vertices){const Le=je.x-j.rect[0],De=j.rect[3]-je.y;Ae.push(Le+","+De)}Ae=Ae.join(" ");const we=ue(this,be,this.svgFactory.createElement(this.svgElementName));return we.setAttribute("points",Ae),we.setAttribute("stroke-width",j.borderStyle.width||1),we.setAttribute("stroke","transparent"),we.setAttribute("fill","transparent"),pe.append(we),this.container.append(pe),!j.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return b(this,be)}addHighlightArea(){this.container.classList.add("highlightArea")}}be=new WeakMap;class K extends ${constructor(U){super(U),this.containerClassName="polygonAnnotation",this.svgElementName="svg:polygon"}}class J extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0})}render(){return this.container.classList.add("caretAnnotation"),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container}}class Y extends v{constructor(j){super(j,{isRenderable:!0,ignoreBorder:!0});de(this,oe,[]);this.containerClassName="inkAnnotation",this.svgElementName="svg:polyline",this.annotationEditorType=n.AnnotationEditorType.INK}render(){this.container.classList.add(this.containerClassName);const j=this.data,{width:W,height:fe}=g(j.rect),pe=this.svgFactory.create(W,fe,!0);for(const Ae of j.inkLists){let we=[];for(const Le of Ae){const De=Le.x-j.rect[0],Ge=j.rect[3]-Le.y;we.push(`${De},${Ge}`)}we=we.join(" ");const je=this.svgFactory.createElement(this.svgElementName);b(this,oe).push(je),je.setAttribute("points",we),je.setAttribute("stroke-width",j.borderStyle.width||1),je.setAttribute("stroke","transparent"),je.setAttribute("fill","transparent"),!j.popupRef&&this.hasPopupData&&this._createPopup(),pe.append(je)}return this.container.append(pe),this.container}getElementsToTriggerPopup(){return b(this,oe)}addHighlightArea(){this.container.classList.add("highlightArea")}}oe=new WeakMap,e.InkAnnotationElement=Y;class se extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("highlightAnnotation"),this.container}}class B extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("underlineAnnotation"),this.container}}class V extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("squigglyAnnotation"),this.container}}class Q extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("strikeoutAnnotation"),this.container}}class N extends v{constructor(U){super(U,{isRenderable:!0,ignoreBorder:!0})}render(){return this.container.classList.add("stampAnnotation"),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container}}e.StampAnnotationElement=N;class P extends v{constructor(j){var pe;super(j,{isRenderable:!0});de(this,Re);de(this,ae,null);const{filename:W,content:fe}=this.data.file;this.filename=(0,a.getFilenameFromUrl)(W,!0),this.content=fe,(pe=this.linkService.eventBus)==null||pe.dispatch("fileattachmentannotation",{source:this,filename:W,content:fe})}render(){this.container.classList.add("fileAttachmentAnnotation");const{container:j,data:W}=this;let fe;W.hasAppearance||W.fillAlpha===0?fe=document.createElement("div"):(fe=document.createElement("img"),fe.src=`${this.imageResourcesPath}annotation-${/paperclip/i.test(W.name)?"paperclip":"pushpin"}.svg`,W.fillAlpha&&W.fillAlpha<1&&(fe.style=`filter: opacity(${Math.round(W.fillAlpha*100)}%);`)),fe.addEventListener("dblclick",te(this,Re,sr).bind(this)),ue(this,ae,fe);const{isMac:pe}=n.FeatureTest.platform;return j.addEventListener("keydown",Ae=>{Ae.key==="Enter"&&(pe?Ae.metaKey:Ae.ctrlKey)&&te(this,Re,sr).call(this)}),!W.popupRef&&this.hasPopupData?this._createPopup():fe.classList.add("popupTriggerArea"),j.append(fe),j}getElementsToTriggerPopup(){return b(this,ae)}addHighlightArea(){this.container.classList.add("highlightArea")}}ae=new WeakMap,Re=new WeakSet,sr=function(){var j;(j=this.downloadManager)==null||j.openOrDownloadData(this.container,this.content,this.filename)};class E{constructor({div:U,accessibilityManager:j,annotationCanvasMap:W,l10n:fe,page:pe,viewport:Ae}){de(this,ke);de(this,Ve,null);de(this,X,null);de(this,ge,new Map);this.div=U,ue(this,Ve,j),ue(this,X,W),this.l10n=fe,this.page=pe,this.viewport=Ae,this.zIndex=0,this.l10n||(this.l10n=h.NullL10n)}async render(U){const{annotations:j}=U,W=this.div;(0,a.setLayerDimensions)(W,this.viewport);const fe=new Map,pe={data:null,layer:W,linkService:U.linkService,downloadManager:U.downloadManager,imageResourcesPath:U.imageResourcesPath||"",renderForms:U.renderForms!==!1,svgFactory:new a.DOMSVGFactory,annotationStorage:U.annotationStorage||new s.AnnotationStorage,enableScripting:U.enableScripting===!0,hasJSActions:U.hasJSActions,fieldObjects:U.fieldObjects,parent:this,elements:null};for(const Ae of j){if(Ae.noHTML)continue;const we=Ae.annotationType===n.AnnotationType.POPUP;if(we){const De=fe.get(Ae.id);if(!De)continue;pe.elements=De}else{const{width:De,height:Ge}=g(Ae.rect);if(De<=0||Ge<=0)continue}pe.data=Ae;const je=f.create(pe);if(!je.isRenderable)continue;if(!we&&Ae.popupRef){const De=fe.get(Ae.popupRef);De?De.push(je):fe.set(Ae.popupRef,[je])}je.annotationEditorType>0&&b(this,ge).set(je.data.id,je);const Le=je.render();Ae.hidden&&(Le.style.visibility="hidden"),te(this,ke,Nr).call(this,Le,Ae.id)}te(this,ke,or).call(this),await this.l10n.translate(W)}update({viewport:U}){const j=this.div;this.viewport=U,(0,a.setLayerDimensions)(j,{rotation:U.rotation}),te(this,ke,or).call(this),j.hidden=!1}getEditableAnnotations(){return Array.from(b(this,ge).values())}getEditableAnnotation(U){return b(this,ge).get(U)}}Ve=new WeakMap,X=new WeakMap,ge=new WeakMap,ke=new WeakSet,Nr=function(U,j){var fe;const W=U.firstChild||U;W.id=`${n.AnnotationPrefix}${j}`,this.div.append(U),(fe=b(this,Ve))==null||fe.moveElementInDOM(this.div,U,W,!1)},or=function(){if(!b(this,X))return;const U=this.div;for(const[j,W]of b(this,X)){const fe=U.querySelector(`[data-annotation-id="${j}"]`);if(!fe)continue;const{firstChild:pe}=fe;pe?pe.nodeName==="CANVAS"?pe.replaceWith(W):pe.before(W):fe.append(W)}b(this,X).clear()},e.AnnotationLayer=E},(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.ColorConverters=void 0;function r(s){return Math.floor(Math.max(0,Math.min(1,s))*255).toString(16).padStart(2,"0")}function n(s){return Math.max(0,Math.min(255,255*s))}class a{static CMYK_G([o,h,d,l]){return["G",1-Math.min(1,.3*o+.59*d+.11*h+l)]}static G_CMYK([o]){return["CMYK",0,0,0,1-o]}static G_RGB([o]){return["RGB",o,o,o]}static G_rgb([o]){return o=n(o),[o,o,o]}static G_HTML([o]){const h=r(o);return`#${h}${h}${h}`}static RGB_G([o,h,d]){return["G",.3*o+.59*h+.11*d]}static RGB_rgb(o){return o.map(n)}static RGB_HTML(o){return`#${o.map(r).join("")}`}static T_HTML(){return"#00000000"}static T_rgb(){return[null]}static CMYK_RGB([o,h,d,l]){return["RGB",1-Math.min(1,o+l),1-Math.min(1,d+l),1-Math.min(1,h+l)]}static CMYK_rgb([o,h,d,l]){return[n(1-Math.min(1,o+l)),n(1-Math.min(1,d+l)),n(1-Math.min(1,h+l))]}static CMYK_HTML(o){const h=this.CMYK_RGB(o).slice(1);return this.RGB_HTML(h)}static RGB_CMYK([o,h,d]){const l=1-o,u=1-h,p=1-d,g=Math.min(l,u,p);return["CMYK",l,u,p,g]}}e.ColorConverters=a},(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.NullL10n=void 0,e.getL10nFallback=n;const r={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}} × {{height}} {{unit}} ({{orientation}})",document_properties_page_size_dimension_name_string:"{{width}} × {{height}} {{unit}} ({{name}}, {{orientation}})",document_properties_linearized_yes:"Yes",document_properties_linearized_no:"No",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",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_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.",rendering_error:"An error occurred while rendering the page.",annotation_date_string:"{{date}}, {{time}}",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.",free_text2_default_content:"Start typing…",editor_free_text2_aria_label:"Text Editor",editor_ink2_aria_label:"Draw Editor",editor_ink_canvas_aria_label:"User-created image",editor_alt_text_button_label:"Alt text",editor_alt_text_edit_button_label:"Edit alt text",editor_alt_text_decorative_tooltip:"Marked as decorative"};r.print_progress_percent="{{progress}}%";function n(o,h){switch(o){case"find_match_count":o=`find_match_count[${h.total===1?"one":"other"}]`;break;case"find_match_count_limit":o=`find_match_count_limit[${h.limit===1?"one":"other"}]`;break}return r[o]||""}function a(o,h){return h?o.replaceAll(/\{\{\s*(\w+)\s*\}\}/g,(d,l)=>l in h?h[l]:"{{"+l+"}}"):o}const s={async getLanguage(){return"en-us"},async getDirection(){return"ltr"},async get(o,h=null,d=n(o,h)){return a(d,h)},async translate(o){}};e.NullL10n=s},(t,e,r)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.XfaLayer=void 0;var n=r(25);class a{static setupStorage(o,h,d,l,u){const p=l.getValue(h,{value:null});switch(d.name){case"textarea":if(p.value!==null&&(o.textContent=p.value),u==="print")break;o.addEventListener("input",g=>{l.setValue(h,{value:g.target.value})});break;case"input":if(d.attributes.type==="radio"||d.attributes.type==="checkbox"){if(p.value===d.attributes.xfaOn?o.setAttribute("checked",!0):p.value===d.attributes.xfaOff&&o.removeAttribute("checked"),u==="print")break;o.addEventListener("change",g=>{l.setValue(h,{value:g.target.checked?g.target.getAttribute("xfaOn"):g.target.getAttribute("xfaOff")})})}else{if(p.value!==null&&o.setAttribute("value",p.value),u==="print")break;o.addEventListener("input",g=>{l.setValue(h,{value:g.target.value})})}break;case"select":if(p.value!==null){o.setAttribute("value",p.value);for(const g of d.children)g.attributes.value===p.value?g.attributes.selected=!0:g.attributes.hasOwnProperty("selected")&&delete g.attributes.selected}o.addEventListener("input",g=>{const f=g.target.options,v=f.selectedIndex===-1?"":f[f.selectedIndex].value;l.setValue(h,{value:v})});break}}static setAttributes({html:o,element:h,storage:d=null,intent:l,linkService:u}){const{attributes:p}=h,g=o instanceof HTMLAnchorElement;p.type==="radio"&&(p.name=`${p.name}-${l}`);for(const[f,v]of Object.entries(p))if(v!=null)switch(f){case"class":v.length&&o.setAttribute(f,v.join(" "));break;case"dataId":break;case"id":o.setAttribute("data-element-id",v);break;case"style":Object.assign(o.style,v);break;case"textContent":o.textContent=v;break;default:(!g||f!=="href"&&f!=="newWindow")&&o.setAttribute(f,v)}g&&u.addLinkAttributes(o,p.href,p.newWindow),d&&p.dataId&&this.setupStorage(o,p.dataId,h,d)}static render(o){var y;const h=o.annotationStorage,d=o.linkService,l=o.xfaHtml,u=o.intent||"display",p=document.createElement(l.name);l.attributes&&this.setAttributes({html:p,element:l,intent:u,linkService:d});const g=[[l,-1,p]],f=o.div;if(f.append(p),o.viewport){const S=`matrix(${o.viewport.transform.join(",")})`;f.style.transform=S}u!=="richText"&&f.setAttribute("class","xfaLayer xfaFont");const v=[];for(;g.length>0;){const[S,m,w]=g.at(-1);if(m+1===S.children.length){g.pop();continue}const R=S.children[++g.at(-1)[1]];if(R===null)continue;const{name:_}=R;if(_==="#text"){const F=document.createTextNode(R.value);v.push(F),w.append(F);continue}const x=(y=R==null?void 0:R.attributes)!=null&&y.xmlns?document.createElementNS(R.attributes.xmlns,_):document.createElement(_);if(w.append(x),R.attributes&&this.setAttributes({html:x,element:R,storage:h,intent:u,linkService:d}),R.children&&R.children.length>0)g.push([R,-1,x]);else if(R.value){const F=document.createTextNode(R.value);n.XfaText.shouldBuildText(_)&&v.push(F),x.append(F)}}for(const S of f.querySelectorAll(".xfaNonInteractive input, .xfaNonInteractive textarea"))S.setAttribute("readOnly",!0);return{textDivs:v}}static update(o){const h=`matrix(${o.viewport.transform.join(",")})`;o.div.style.transform=h,o.div.hidden=!1}}e.XfaLayer=a},(t,e,r)=>{var l,u,p,g,f,v,y,S,m,w,R,_,x,F,A,Mr,Lr,Br,jr,lr,Ur,cr,zr,Hr,Gr,Wr,Vr,it,hr,Tt,_t,dt,dr,Rt,G,qr,ur,Xr,Kr,fr,kt,ut;Object.defineProperty(e,"__esModule",{value:!0}),e.InkEditor=void 0;var n=r(1),a=r(4),s=r(29),o=r(6),h=r(5);const Ce=class Ce extends a.AnnotationEditor{constructor(L){super({...L,name:"inkEditor"});de(this,A);de(this,l,0);de(this,u,0);de(this,p,this.canvasPointermove.bind(this));de(this,g,this.canvasPointerleave.bind(this));de(this,f,this.canvasPointerup.bind(this));de(this,v,this.canvasPointerdown.bind(this));de(this,y,new Path2D);de(this,S,!1);de(this,m,!1);de(this,w,!1);de(this,R,null);de(this,_,0);de(this,x,0);de(this,F,null);this.color=L.color||null,this.thickness=L.thickness||null,this.opacity=L.opacity||null,this.paths=[],this.bezierPath2D=[],this.allRawPaths=[],this.currentPath=[],this.scaleFactor=1,this.translationX=this.translationY=0,this.x=0,this.y=0,this._willKeepAspectRatio=!0}static initialize(L){a.AnnotationEditor.initialize(L,{strings:["editor_ink_canvas_aria_label","editor_ink2_aria_label"]})}static updateDefaultParams(L,Z){switch(L){case n.AnnotationEditorParamsType.INK_THICKNESS:Ce._defaultThickness=Z;break;case n.AnnotationEditorParamsType.INK_COLOR:Ce._defaultColor=Z;break;case n.AnnotationEditorParamsType.INK_OPACITY:Ce._defaultOpacity=Z/100;break}}updateParams(L,Z){switch(L){case n.AnnotationEditorParamsType.INK_THICKNESS:te(this,A,Mr).call(this,Z);break;case n.AnnotationEditorParamsType.INK_COLOR:te(this,A,Lr).call(this,Z);break;case n.AnnotationEditorParamsType.INK_OPACITY:te(this,A,Br).call(this,Z);break}}static get defaultPropertiesToUpdate(){return[[n.AnnotationEditorParamsType.INK_THICKNESS,Ce._defaultThickness],[n.AnnotationEditorParamsType.INK_COLOR,Ce._defaultColor||a.AnnotationEditor._defaultLineColor],[n.AnnotationEditorParamsType.INK_OPACITY,Math.round(Ce._defaultOpacity*100)]]}get propertiesToUpdate(){return[[n.AnnotationEditorParamsType.INK_THICKNESS,this.thickness||Ce._defaultThickness],[n.AnnotationEditorParamsType.INK_COLOR,this.color||Ce._defaultColor||a.AnnotationEditor._defaultLineColor],[n.AnnotationEditorParamsType.INK_OPACITY,Math.round(100*(this.opacity??Ce._defaultOpacity))]]}rebuild(){this.parent&&(super.rebuild(),this.div!==null&&(this.canvas||(te(this,A,Tt).call(this),te(this,A,_t).call(this)),this.isAttachedToDOM||(this.parent.add(this),te(this,A,dt).call(this)),te(this,A,ut).call(this)))}remove(){this.canvas!==null&&(this.isEmpty()||this.commit(),this.canvas.width=this.canvas.height=0,this.canvas.remove(),this.canvas=null,b(this,R).disconnect(),ue(this,R,null),super.remove())}setParent(L){!this.parent&&L?this._uiManager.removeShouldRescale(this):this.parent&&L===null&&this._uiManager.addShouldRescale(this),super.setParent(L)}onScaleChanging(){const[L,Z]=this.parentDimensions,re=this.width*L,he=this.height*Z;this.setDimensions(re,he)}enableEditMode(){b(this,S)||this.canvas===null||(super.enableEditMode(),this._isDraggable=!1,this.canvas.addEventListener("pointerdown",b(this,v)))}disableEditMode(){!this.isInEditMode()||this.canvas===null||(super.disableEditMode(),this._isDraggable=!this.isEmpty(),this.div.classList.remove("editing"),this.canvas.removeEventListener("pointerdown",b(this,v)))}onceAdded(){this._isDraggable=!this.isEmpty()}isEmpty(){return this.paths.length===0||this.paths.length===1&&this.paths[0].length===0}commit(){b(this,S)||(super.commit(),this.isEditing=!1,this.disableEditMode(),this.setInForeground(),ue(this,S,!0),this.div.classList.add("disabled"),te(this,A,ut).call(this,!0),this.makeResizable(),this.parent.addInkEditorIfNeeded(!0),this.moveInDOM(),this.div.focus({preventScroll:!0}))}focusin(L){this._focusEventsAllowed&&(super.focusin(L),this.enableEditMode())}canvasPointerdown(L){L.button!==0||!this.isInEditMode()||b(this,S)||(this.setInForeground(),L.preventDefault(),L.type!=="mouse"&&this.div.focus(),te(this,A,Ur).call(this,L.offsetX,L.offsetY))}canvasPointermove(L){L.preventDefault(),te(this,A,cr).call(this,L.offsetX,L.offsetY)}canvasPointerup(L){L.preventDefault(),te(this,A,hr).call(this,L)}canvasPointerleave(L){te(this,A,hr).call(this,L)}get isResizable(){return!this.isEmpty()&&b(this,S)}render(){if(this.div)return this.div;let L,Z;this.width&&(L=this.x,Z=this.y),super.render(),a.AnnotationEditor._l10nPromise.get("editor_ink2_aria_label").then(Pe=>{var ie;return(ie=this.div)==null?void 0:ie.setAttribute("aria-label",Pe)});const[re,he,ye,Fe]=te(this,A,jr).call(this);if(this.setAt(re,he,0,0),this.setDims(ye,Fe),te(this,A,Tt).call(this),this.width){const[Pe,ie]=this.parentDimensions;this.setAspectRatio(this.width*Pe,this.height*ie),this.setAt(L*Pe,Z*ie,this.width*Pe,this.height*ie),ue(this,w,!0),te(this,A,dt).call(this),this.setDims(this.width*Pe,this.height*ie),te(this,A,it).call(this),this.div.classList.add("disabled")}else this.div.classList.add("editing"),this.enableEditMode();return te(this,A,_t).call(this),this.div}setDimensions(L,Z){const re=Math.round(L),he=Math.round(Z);if(b(this,_)===re&&b(this,x)===he)return;ue(this,_,re),ue(this,x,he),this.canvas.style.visibility="hidden";const[ye,Fe]=this.parentDimensions;this.width=L/ye,this.height=Z/Fe,this.fixAndSetPosition(),b(this,S)&&te(this,A,dr).call(this,L,Z),te(this,A,dt).call(this),te(this,A,it).call(this),this.canvas.style.visibility="visible",this.fixDims()}static deserialize(L,Z,re){var Ee,Ie,ze;if(L instanceof s.InkAnnotationElement)return null;const he=super.deserialize(L,Z,re);he.thickness=L.thickness,he.color=n.Util.makeHexColor(...L.color),he.opacity=L.opacity;const[ye,Fe]=he.pageDimensions,Pe=he.width*ye,ie=he.height*Fe,_e=he.parentScale,Te=L.thickness/2;ue(he,S,!0),ue(he,_,Math.round(Pe)),ue(he,x,Math.round(ie));const{paths:Ke,rect:qe,rotation:Ye}=L;for(let{bezier:be}of Ke){be=te(Ee=Ce,G,Xr).call(Ee,be,qe,Ye);const oe=[];he.paths.push(oe);let ae=_e*(be[0]-Te),Re=_e*(be[1]-Te);for(let Ve=2,X=be.length;Ve<X;Ve+=6){const ge=_e*(be[Ve]-Te),ke=_e*(be[Ve+1]-Te),Be=_e*(be[Ve+2]-Te),He=_e*(be[Ve+3]-Te),Ne=_e*(be[Ve+4]-Te),U=_e*(be[Ve+5]-Te);oe.push([[ae,Re],[ge,ke],[Be,He],[Ne,U]]),ae=Ne,Re=U}const We=te(this,G,qr).call(this,oe);he.bezierPath2D.push(We)}const Me=te(Ie=he,A,fr).call(Ie);return ue(he,u,Math.max(a.AnnotationEditor.MIN_SIZE,Me[2]-Me[0])),ue(he,l,Math.max(a.AnnotationEditor.MIN_SIZE,Me[3]-Me[1])),te(ze=he,A,dr).call(ze,Pe,ie),he}serialize(){if(this.isEmpty())return null;const L=this.getRect(0,0),Z=a.AnnotationEditor._colorManager.convert(this.ctx.strokeStyle);return{annotationType:n.AnnotationEditorType.INK,color:Z,thickness:this.thickness,opacity:this.opacity,paths:te(this,A,Kr).call(this,this.scaleFactor/this.parentScale,this.translationX,this.translationY,L),pageIndex:this.pageIndex,rect:L,rotation:this.rotation,structTreeParentId:this._structTreeParentId}}};l=new WeakMap,u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakMap,S=new WeakMap,m=new WeakMap,w=new WeakMap,R=new WeakMap,_=new WeakMap,x=new WeakMap,F=new WeakMap,A=new WeakSet,Mr=function(L){const Z=this.thickness;this.addCommands({cmd:()=>{this.thickness=L,te(this,A,ut).call(this)},undo:()=>{this.thickness=Z,te(this,A,ut).call(this)},mustExec:!0,type:n.AnnotationEditorParamsType.INK_THICKNESS,overwriteIfSameType:!0,keepUndo:!0})},Lr=function(L){const Z=this.color;this.addCommands({cmd:()=>{this.color=L,te(this,A,it).call(this)},undo:()=>{this.color=Z,te(this,A,it).call(this)},mustExec:!0,type:n.AnnotationEditorParamsType.INK_COLOR,overwriteIfSameType:!0,keepUndo:!0})},Br=function(L){L/=100;const Z=this.opacity;this.addCommands({cmd:()=>{this.opacity=L,te(this,A,it).call(this)},undo:()=>{this.opacity=Z,te(this,A,it).call(this)},mustExec:!0,type:n.AnnotationEditorParamsType.INK_OPACITY,overwriteIfSameType:!0,keepUndo:!0})},jr=function(){const{parentRotation:L,parentDimensions:[Z,re]}=this;switch(L){case 90:return[0,re,re,Z];case 180:return[Z,re,Z,re];case 270:return[Z,0,re,Z];default:return[0,0,Z,re]}},lr=function(){const{ctx:L,color:Z,opacity:re,thickness:he,parentScale:ye,scaleFactor:Fe}=this;L.lineWidth=he*ye/Fe,L.lineCap="round",L.lineJoin="round",L.miterLimit=10,L.strokeStyle=`${Z}${(0,h.opacityToHex)(re)}`},Ur=function(L,Z){this.canvas.addEventListener("contextmenu",o.noContextMenu),this.canvas.addEventListener("pointerleave",b(this,g)),this.canvas.addEventListener("pointermove",b(this,p)),this.canvas.addEventListener("pointerup",b(this,f)),this.canvas.removeEventListener("pointerdown",b(this,v)),this.isEditing=!0,b(this,w)||(ue(this,w,!0),te(this,A,dt).call(this),this.thickness||(this.thickness=Ce._defaultThickness),this.color||(this.color=Ce._defaultColor||a.AnnotationEditor._defaultLineColor),this.opacity??(this.opacity=Ce._defaultOpacity)),this.currentPath.push([L,Z]),ue(this,m,!1),te(this,A,lr).call(this),ue(this,F,()=>{te(this,A,Gr).call(this),b(this,F)&&window.requestAnimationFrame(b(this,F))}),window.requestAnimationFrame(b(this,F))},cr=function(L,Z){const[re,he]=this.currentPath.at(-1);if(this.currentPath.length>1&&L===re&&Z===he)return;const ye=this.currentPath;let Fe=b(this,y);if(ye.push([L,Z]),ue(this,m,!0),ye.length<=2){Fe.moveTo(...ye[0]),Fe.lineTo(L,Z);return}ye.length===3&&(ue(this,y,Fe=new Path2D),Fe.moveTo(...ye[0])),te(this,A,Wr).call(this,Fe,...ye.at(-3),...ye.at(-2),L,Z)},zr=function(){if(this.currentPath.length===0)return;const L=this.currentPath.at(-1);b(this,y).lineTo(...L)},Hr=function(L,Z){ue(this,F,null),L=Math.min(Math.max(L,0),this.canvas.width),Z=Math.min(Math.max(Z,0),this.canvas.height),te(this,A,cr).call(this,L,Z),te(this,A,zr).call(this);let re;if(this.currentPath.length!==1)re=te(this,A,Vr).call(this);else{const ie=[L,Z];re=[[ie,ie.slice(),ie.slice(),ie]]}const he=b(this,y),ye=this.currentPath;this.currentPath=[],ue(this,y,new Path2D);const Fe=()=>{this.allRawPaths.push(ye),this.paths.push(re),this.bezierPath2D.push(he),this.rebuild()},Pe=()=>{this.allRawPaths.pop(),this.paths.pop(),this.bezierPath2D.pop(),this.paths.length===0?this.remove():(this.canvas||(te(this,A,Tt).call(this),te(this,A,_t).call(this)),te(this,A,ut).call(this))};this.addCommands({cmd:Fe,undo:Pe,mustExec:!0})},Gr=function(){if(!b(this,m))return;ue(this,m,!1);const L=Math.ceil(this.thickness*this.parentScale),Z=this.currentPath.slice(-3),re=Z.map(Fe=>Fe[0]),he=Z.map(Fe=>Fe[1]);Math.min(...re)-L,Math.max(...re)+L,Math.min(...he)-L,Math.max(...he)+L;const{ctx:ye}=this;ye.save(),ye.clearRect(0,0,this.canvas.width,this.canvas.height);for(const Fe of this.bezierPath2D)ye.stroke(Fe);ye.stroke(b(this,y)),ye.restore()},Wr=function(L,Z,re,he,ye,Fe,Pe){const ie=(Z+he)/2,_e=(re+ye)/2,Te=(he+Fe)/2,Ke=(ye+Pe)/2;L.bezierCurveTo(ie+2*(he-ie)/3,_e+2*(ye-_e)/3,Te+2*(he-Te)/3,Ke+2*(ye-Ke)/3,Te,Ke)},Vr=function(){const L=this.currentPath;if(L.length<=2)return[[L[0],L[0],L.at(-1),L.at(-1)]];const Z=[];let re,[he,ye]=L[0];for(re=1;re<L.length-2;re++){const[qe,Ye]=L[re],[Me,Ee]=L[re+1],Ie=(qe+Me)/2,ze=(Ye+Ee)/2,be=[he+2*(qe-he)/3,ye+2*(Ye-ye)/3],oe=[Ie+2*(qe-Ie)/3,ze+2*(Ye-ze)/3];Z.push([[he,ye],be,oe,[Ie,ze]]),[he,ye]=[Ie,ze]}const[Fe,Pe]=L[re],[ie,_e]=L[re+1],Te=[he+2*(Fe-he)/3,ye+2*(Pe-ye)/3],Ke=[ie+2*(Fe-ie)/3,_e+2*(Pe-_e)/3];return Z.push([[he,ye],Te,Ke,[ie,_e]]),Z},it=function(){if(this.isEmpty()){te(this,A,Rt).call(this);return}te(this,A,lr).call(this);const{canvas:L,ctx:Z}=this;Z.setTransform(1,0,0,1,0,0),Z.clearRect(0,0,L.width,L.height),te(this,A,Rt).call(this);for(const re of this.bezierPath2D)Z.stroke(re)},hr=function(L){this.canvas.removeEventListener("pointerleave",b(this,g)),this.canvas.removeEventListener("pointermove",b(this,p)),this.canvas.removeEventListener("pointerup",b(this,f)),this.canvas.addEventListener("pointerdown",b(this,v)),setTimeout(()=>{this.canvas.removeEventListener("contextmenu",o.noContextMenu)},10),te(this,A,Hr).call(this,L.offsetX,L.offsetY),this.addToAnnotationStorage(),this.setInBackground()},Tt=function(){this.canvas=document.createElement("canvas"),this.canvas.width=this.canvas.height=0,this.canvas.className="inkEditorCanvas",a.AnnotationEditor._l10nPromise.get("editor_ink_canvas_aria_label").then(L=>{var Z;return(Z=this.canvas)==null?void 0:Z.setAttribute("aria-label",L)}),this.div.append(this.canvas),this.ctx=this.canvas.getContext("2d")},_t=function(){ue(this,R,new ResizeObserver(L=>{const Z=L[0].contentRect;Z.width&&Z.height&&this.setDimensions(Z.width,Z.height)})),b(this,R).observe(this.div)},dt=function(){if(!b(this,w))return;const[L,Z]=this.parentDimensions;this.canvas.width=Math.ceil(this.width*L),this.canvas.height=Math.ceil(this.height*Z),te(this,A,Rt).call(this)},dr=function(L,Z){const re=te(this,A,kt).call(this),he=(L-re)/b(this,u),ye=(Z-re)/b(this,l);this.scaleFactor=Math.min(he,ye)},Rt=function(){const L=te(this,A,kt).call(this)/2;this.ctx.setTransform(this.scaleFactor,0,0,this.scaleFactor,this.translationX*this.scaleFactor+L,this.translationY*this.scaleFactor+L)},G=new WeakSet,qr=function(L){const Z=new Path2D;for(let re=0,he=L.length;re<he;re++){const[ye,Fe,Pe,ie]=L[re];re===0&&Z.moveTo(...ye),Z.bezierCurveTo(Fe[0],Fe[1],Pe[0],Pe[1],ie[0],ie[1])}return Z},ur=function(L,Z,re){const[he,ye,Fe,Pe]=Z;switch(re){case 0:for(let ie=0,_e=L.length;ie<_e;ie+=2)L[ie]+=he,L[ie+1]=Pe-L[ie+1];break;case 90:for(let ie=0,_e=L.length;ie<_e;ie+=2){const Te=L[ie];L[ie]=L[ie+1]+he,L[ie+1]=Te+ye}break;case 180:for(let ie=0,_e=L.length;ie<_e;ie+=2)L[ie]=Fe-L[ie],L[ie+1]+=ye;break;case 270:for(let ie=0,_e=L.length;ie<_e;ie+=2){const Te=L[ie];L[ie]=Fe-L[ie+1],L[ie+1]=Pe-Te}break;default:throw new Error("Invalid rotation")}return L},Xr=function(L,Z,re){const[he,ye,Fe,Pe]=Z;switch(re){case 0:for(let ie=0,_e=L.length;ie<_e;ie+=2)L[ie]-=he,L[ie+1]=Pe-L[ie+1];break;case 90:for(let ie=0,_e=L.length;ie<_e;ie+=2){const Te=L[ie];L[ie]=L[ie+1]-ye,L[ie+1]=Te-he}break;case 180:for(let ie=0,_e=L.length;ie<_e;ie+=2)L[ie]=Fe-L[ie],L[ie+1]-=ye;break;case 270:for(let ie=0,_e=L.length;ie<_e;ie+=2){const Te=L[ie];L[ie]=Pe-L[ie+1],L[ie+1]=Fe-Te}break;default:throw new Error("Invalid rotation")}return L},Kr=function(L,Z,re,he){var _e,Te;const ye=[],Fe=this.thickness/2,Pe=L*Z+Fe,ie=L*re+Fe;for(const Ke of this.paths){const qe=[],Ye=[];for(let Me=0,Ee=Ke.length;Me<Ee;Me++){const[Ie,ze,be,oe]=Ke[Me],ae=L*Ie[0]+Pe,Re=L*Ie[1]+ie,We=L*ze[0]+Pe,Ve=L*ze[1]+ie,X=L*be[0]+Pe,ge=L*be[1]+ie,ke=L*oe[0]+Pe,Be=L*oe[1]+ie;Me===0&&(qe.push(ae,Re),Ye.push(ae,Re)),qe.push(We,Ve,X,ge,ke,Be),Ye.push(We,Ve),Me===Ee-1&&Ye.push(ke,Be)}ye.push({bezier:te(_e=Ce,G,ur).call(_e,qe,he,this.rotation),points:te(Te=Ce,G,ur).call(Te,Ye,he,this.rotation)})}return ye},fr=function(){let L=1/0,Z=-1/0,re=1/0,he=-1/0;for(const ye of this.paths)for(const[Fe,Pe,ie,_e]of ye){const Te=n.Util.bezierBoundingBox(...Fe,...Pe,...ie,..._e);L=Math.min(L,Te[0]),re=Math.min(re,Te[1]),Z=Math.max(Z,Te[2]),he=Math.max(he,Te[3])}return[L,re,Z,he]},kt=function(){return b(this,S)?Math.ceil(this.thickness*this.parentScale):0},ut=function(L=!1){if(this.isEmpty())return;if(!b(this,S)){te(this,A,it).call(this);return}const Z=te(this,A,fr).call(this),re=te(this,A,kt).call(this);ue(this,u,Math.max(a.AnnotationEditor.MIN_SIZE,Z[2]-Z[0])),ue(this,l,Math.max(a.AnnotationEditor.MIN_SIZE,Z[3]-Z[1]));const he=Math.ceil(re+b(this,u)*this.scaleFactor),ye=Math.ceil(re+b(this,l)*this.scaleFactor),[Fe,Pe]=this.parentDimensions;this.width=he/Fe,this.height=ye/Pe,this.setAspectRatio(he,ye);const ie=this.translationX,_e=this.translationY;this.translationX=-Z[0],this.translationY=-Z[1],te(this,A,dt).call(this),te(this,A,it).call(this),ue(this,_,he),ue(this,x,ye),this.setDims(he,ye);const Te=L?re/this.scaleFactor/2:0;this.translate(ie-this.translationX-Te,_e-this.translationY-Te)},de(Ce,G),$e(Ce,"_defaultColor",null),$e(Ce,"_defaultOpacity",1),$e(Ce,"_defaultThickness",1),$e(Ce,"_type","ink");let d=Ce;e.InkEditor=d},(t,e,r)=>{var d,l,u,p,g,f,v,y,S,m,w,bt,xt,It,pr,Zr,Yr,gr,Ot,Jr;Object.defineProperty(e,"__esModule",{value:!0}),e.StampEditor=void 0;var n=r(1),a=r(4),s=r(6),o=r(29);const k=class k extends a.AnnotationEditor{constructor(K){super({...K,name:"stampEditor"});de(this,w);de(this,d,null);de(this,l,null);de(this,u,null);de(this,p,null);de(this,g,null);de(this,f,null);de(this,v,null);de(this,y,null);de(this,S,!1);de(this,m,!1);ue(this,p,K.bitmapUrl),ue(this,g,K.bitmapFile)}static initialize(K){a.AnnotationEditor.initialize(K)}static get supportedTypes(){const K=["apng","avif","bmp","gif","jpeg","png","svg+xml","webp","x-icon"];return(0,n.shadow)(this,"supportedTypes",K.map(J=>`image/${J}`))}static get supportedTypesStr(){return(0,n.shadow)(this,"supportedTypesStr",this.supportedTypes.join(","))}static isHandlingMimeForPasting(K){return this.supportedTypes.includes(K)}static paste(K,J){J.pasteEditor(n.AnnotationEditorType.STAMP,{bitmapFile:K.getAsFile()})}remove(){var K,J;b(this,l)&&(ue(this,d,null),this._uiManager.imageManager.deleteId(b(this,l)),(K=b(this,f))==null||K.remove(),ue(this,f,null),(J=b(this,v))==null||J.disconnect(),ue(this,v,null)),super.remove()}rebuild(){if(!this.parent){b(this,l)&&te(this,w,It).call(this);return}super.rebuild(),this.div!==null&&(b(this,l)&&te(this,w,It).call(this),this.isAttachedToDOM||this.parent.add(this))}onceAdded(){this._isDraggable=!0,this.div.focus()}isEmpty(){return!(b(this,u)||b(this,d)||b(this,p)||b(this,g))}get isResizable(){return!0}render(){if(this.div)return this.div;let K,J;if(this.width&&(K=this.x,J=this.y),super.render(),this.div.hidden=!0,b(this,d)?te(this,w,pr).call(this):te(this,w,It).call(this),this.width){const[Y,se]=this.parentDimensions;this.setAt(K*Y,J*se,this.width*Y,this.height*se)}return this.div}static deserialize(K,J,Y){if(K instanceof o.StampAnnotationElement)return null;const se=super.deserialize(K,J,Y),{rect:B,bitmapUrl:V,bitmapId:Q,isSvg:N,accessibilityData:P}=K;Q&&Y.imageManager.isValidId(Q)?ue(se,l,Q):ue(se,p,V),ue(se,S,N);const[E,I]=se.pageDimensions;return se.width=(B[2]-B[0])/E,se.height=(B[3]-B[1])/I,P&&(se.altTextData=P),se}serialize(K=!1,J=null){if(this.isEmpty())return null;const Y={annotationType:n.AnnotationEditorType.STAMP,bitmapId:b(this,l),pageIndex:this.pageIndex,rect:this.getRect(0,0),rotation:this.rotation,isSvg:b(this,S),structTreeParentId:this._structTreeParentId};if(K)return Y.bitmapUrl=te(this,w,Ot).call(this,!0),Y.accessibilityData=this.altTextData,Y;const{decorative:se,altText:B}=this.altTextData;if(!se&&B&&(Y.accessibilityData={type:"Figure",alt:B}),J===null)return Y;J.stamps||(J.stamps=new Map);const V=b(this,S)?(Y.rect[2]-Y.rect[0])*(Y.rect[3]-Y.rect[1]):null;if(!J.stamps.has(b(this,l)))J.stamps.set(b(this,l),{area:V,serialized:Y}),Y.bitmap=te(this,w,Ot).call(this,!1);else if(b(this,S)){const Q=J.stamps.get(b(this,l));V>Q.area&&(Q.area=V,Q.serialized.bitmap.close(),Q.serialized.bitmap=te(this,w,Ot).call(this,!1))}return Y}};d=new WeakMap,l=new WeakMap,u=new WeakMap,p=new WeakMap,g=new WeakMap,f=new WeakMap,v=new WeakMap,y=new WeakMap,S=new WeakMap,m=new WeakMap,w=new WeakSet,bt=function(K,J=!1){if(!K){this.remove();return}ue(this,d,K.bitmap),J||(ue(this,l,K.id),ue(this,S,K.isSvg)),te(this,w,pr).call(this)},xt=function(){ue(this,u,null),this._uiManager.enableWaiting(!1),b(this,f)&&this.div.focus()},It=function(){if(b(this,l)){this._uiManager.enableWaiting(!0),this._uiManager.imageManager.getFromId(b(this,l)).then(J=>te(this,w,bt).call(this,J,!0)).finally(()=>te(this,w,xt).call(this));return}if(b(this,p)){const J=b(this,p);ue(this,p,null),this._uiManager.enableWaiting(!0),ue(this,u,this._uiManager.imageManager.getFromUrl(J).then(Y=>te(this,w,bt).call(this,Y)).finally(()=>te(this,w,xt).call(this)));return}if(b(this,g)){const J=b(this,g);ue(this,g,null),this._uiManager.enableWaiting(!0),ue(this,u,this._uiManager.imageManager.getFromFile(J).then(Y=>te(this,w,bt).call(this,Y)).finally(()=>te(this,w,xt).call(this)));return}const K=document.createElement("input");K.type="file",K.accept=k.supportedTypesStr,ue(this,u,new Promise(J=>{K.addEventListener("change",async()=>{if(!K.files||K.files.length===0)this.remove();else{this._uiManager.enableWaiting(!0);const Y=await this._uiManager.imageManager.getFromFile(K.files[0]);te(this,w,bt).call(this,Y)}J()}),K.addEventListener("cancel",()=>{this.remove(),J()})}).finally(()=>te(this,w,xt).call(this))),K.click()},pr=function(){const{div:K}=this;let{width:J,height:Y}=b(this,d);const[se,B]=this.pageDimensions,V=.75;if(this.width)J=this.width*se,Y=this.height*B;else if(J>V*se||Y>V*B){const E=Math.min(V*se/J,V*B/Y);J*=E,Y*=E}const[Q,N]=this.parentDimensions;this.setDims(J*Q/se,Y*N/B),this._uiManager.enableWaiting(!1);const P=ue(this,f,document.createElement("canvas"));K.append(P),K.hidden=!1,te(this,w,gr).call(this,J,Y),te(this,w,Jr).call(this),b(this,m)||(this.parent.addUndoableEditor(this),ue(this,m,!0)),this._uiManager._eventBus.dispatch("reporttelemetry",{source:this,details:{type:"editing",subtype:this.editorType,data:{action:"inserted_image"}}}),this.addAltTextButton()},Zr=function(K,J){var V;const[Y,se]=this.parentDimensions;this.width=K/Y,this.height=J/se,this.setDims(K,J),(V=this._initialOptions)!=null&&V.isCentered?this.center():this.fixAndSetPosition(),this._initialOptions=null,b(this,y)!==null&&clearTimeout(b(this,y)),ue(this,y,setTimeout(()=>{ue(this,y,null),te(this,w,gr).call(this,K,J)},200))},Yr=function(K,J){const{width:Y,height:se}=b(this,d);let B=Y,V=se,Q=b(this,d);for(;B>2*K||V>2*J;){const N=B,P=V;B>2*K&&(B=B>=16384?Math.floor(B/2)-1:Math.ceil(B/2)),V>2*J&&(V=V>=16384?Math.floor(V/2)-1:Math.ceil(V/2));const E=new OffscreenCanvas(B,V);E.getContext("2d").drawImage(Q,0,0,N,P,0,0,B,V),Q=E.transferToImageBitmap()}return Q},gr=function(K,J){K=Math.ceil(K),J=Math.ceil(J);const Y=b(this,f);if(!Y||Y.width===K&&Y.height===J)return;Y.width=K,Y.height=J;const se=b(this,S)?b(this,d):te(this,w,Yr).call(this,K,J),B=Y.getContext("2d");B.filter=this._uiManager.hcmFilter,B.drawImage(se,0,0,se.width,se.height,0,0,K,J)},Ot=function(K){if(K){if(b(this,S)){const se=this._uiManager.imageManager.getSvgUrl(b(this,l));if(se)return se}const J=document.createElement("canvas");return{width:J.width,height:J.height}=b(this,d),J.getContext("2d").drawImage(b(this,d),0,0),J.toDataURL()}if(b(this,S)){const[J,Y]=this.pageDimensions,se=Math.round(this.width*J*s.PixelsPerInch.PDF_TO_CSS_UNITS),B=Math.round(this.height*Y*s.PixelsPerInch.PDF_TO_CSS_UNITS),V=new OffscreenCanvas(se,B);return V.getContext("2d").drawImage(b(this,d),0,0,b(this,d).width,b(this,d).height,0,0,se,B),V.transferToImageBitmap()}return structuredClone(b(this,d))},Jr=function(){ue(this,v,new ResizeObserver(K=>{const J=K[0].contentRect;J.width&&J.height&&te(this,w,Zr).call(this,J.width,J.height)})),b(this,v).observe(this.div)},$e(k,"_type","stamp");let h=k;e.StampEditor=h}],__webpack_module_cache__={};function __w_pdfjs_require__(t){var e=__webpack_module_cache__[t];if(e!==void 0)return e.exports;var r=__webpack_module_cache__[t]={exports:{}};return __webpack_modules__[t](r,r.exports,__w_pdfjs_require__),r.exports}var __webpack_exports__={};return(()=>{var t=__webpack_exports__;Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"AbortException",{enumerable:!0,get:function(){return e.AbortException}}),Object.defineProperty(t,"AnnotationEditorLayer",{enumerable:!0,get:function(){return s.AnnotationEditorLayer}}),Object.defineProperty(t,"AnnotationEditorParamsType",{enumerable:!0,get:function(){return e.AnnotationEditorParamsType}}),Object.defineProperty(t,"AnnotationEditorType",{enumerable:!0,get:function(){return e.AnnotationEditorType}}),Object.defineProperty(t,"AnnotationEditorUIManager",{enumerable:!0,get:function(){return o.AnnotationEditorUIManager}}),Object.defineProperty(t,"AnnotationLayer",{enumerable:!0,get:function(){return h.AnnotationLayer}}),Object.defineProperty(t,"AnnotationMode",{enumerable:!0,get:function(){return e.AnnotationMode}}),Object.defineProperty(t,"CMapCompressionType",{enumerable:!0,get:function(){return e.CMapCompressionType}}),Object.defineProperty(t,"DOMSVGFactory",{enumerable:!0,get:function(){return n.DOMSVGFactory}}),Object.defineProperty(t,"FeatureTest",{enumerable:!0,get:function(){return e.FeatureTest}}),Object.defineProperty(t,"GlobalWorkerOptions",{enumerable:!0,get:function(){return d.GlobalWorkerOptions}}),Object.defineProperty(t,"ImageKind",{enumerable:!0,get:function(){return e.ImageKind}}),Object.defineProperty(t,"InvalidPDFException",{enumerable:!0,get:function(){return e.InvalidPDFException}}),Object.defineProperty(t,"MissingPDFException",{enumerable:!0,get:function(){return e.MissingPDFException}}),Object.defineProperty(t,"OPS",{enumerable:!0,get:function(){return e.OPS}}),Object.defineProperty(t,"PDFDataRangeTransport",{enumerable:!0,get:function(){return r.PDFDataRangeTransport}}),Object.defineProperty(t,"PDFDateString",{enumerable:!0,get:function(){return n.PDFDateString}}),Object.defineProperty(t,"PDFWorker",{enumerable:!0,get:function(){return r.PDFWorker}}),Object.defineProperty(t,"PasswordResponses",{enumerable:!0,get:function(){return e.PasswordResponses}}),Object.defineProperty(t,"PermissionFlag",{enumerable:!0,get:function(){return e.PermissionFlag}}),Object.defineProperty(t,"PixelsPerInch",{enumerable:!0,get:function(){return n.PixelsPerInch}}),Object.defineProperty(t,"PromiseCapability",{enumerable:!0,get:function(){return e.PromiseCapability}}),Object.defineProperty(t,"RenderingCancelledException",{enumerable:!0,get:function(){return n.RenderingCancelledException}}),Object.defineProperty(t,"SVGGraphics",{enumerable:!0,get:function(){return r.SVGGraphics}}),Object.defineProperty(t,"UnexpectedResponseException",{enumerable:!0,get:function(){return e.UnexpectedResponseException}}),Object.defineProperty(t,"Util",{enumerable:!0,get:function(){return e.Util}}),Object.defineProperty(t,"VerbosityLevel",{enumerable:!0,get:function(){return e.VerbosityLevel}}),Object.defineProperty(t,"XfaLayer",{enumerable:!0,get:function(){return l.XfaLayer}}),Object.defineProperty(t,"build",{enumerable:!0,get:function(){return r.build}}),Object.defineProperty(t,"createValidAbsoluteUrl",{enumerable:!0,get:function(){return e.createValidAbsoluteUrl}}),Object.defineProperty(t,"getDocument",{enumerable:!0,get:function(){return r.getDocument}}),Object.defineProperty(t,"getFilenameFromUrl",{enumerable:!0,get:function(){return n.getFilenameFromUrl}}),Object.defineProperty(t,"getPdfFilenameFromUrl",{enumerable:!0,get:function(){return n.getPdfFilenameFromUrl}}),Object.defineProperty(t,"getXfaPageViewport",{enumerable:!0,get:function(){return n.getXfaPageViewport}}),Object.defineProperty(t,"isDataScheme",{enumerable:!0,get:function(){return n.isDataScheme}}),Object.defineProperty(t,"isPdfFile",{enumerable:!0,get:function(){return n.isPdfFile}}),Object.defineProperty(t,"loadScript",{enumerable:!0,get:function(){return n.loadScript}}),Object.defineProperty(t,"noContextMenu",{enumerable:!0,get:function(){return n.noContextMenu}}),Object.defineProperty(t,"normalizeUnicode",{enumerable:!0,get:function(){return e.normalizeUnicode}}),Object.defineProperty(t,"renderTextLayer",{enumerable:!0,get:function(){return a.renderTextLayer}}),Object.defineProperty(t,"setLayerDimensions",{enumerable:!0,get:function(){return n.setLayerDimensions}}),Object.defineProperty(t,"shadow",{enumerable:!0,get:function(){return e.shadow}}),Object.defineProperty(t,"updateTextLayer",{enumerable:!0,get:function(){return a.updateTextLayer}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return r.version}});var e=__w_pdfjs_require__(1),r=__w_pdfjs_require__(2),n=__w_pdfjs_require__(6),a=__w_pdfjs_require__(26),s=__w_pdfjs_require__(27),o=__w_pdfjs_require__(5),h=__w_pdfjs_require__(29),d=__w_pdfjs_require__(14),l=__w_pdfjs_require__(32)})(),__webpack_exports__})())})(pdf);var pdfExports=pdf.exports;const FONT_SIZES=[8,10,12,14,16,20,24,32,48,64],STROKE_WIDTHS=[1,2,4,8,12],DEFAULT_COLOR="#ef4444",DEFAULT_FONT_SIZE=16,DEFAULT_STROKE_WIDTH=2,STAMPS=["APPROVED","CONFIDENTIAL","DRAFT","FINAL","FOR REVIEW","REVISED","ASAP","VOID"],iconProps={className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor"},SelectIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 3l7.07 16.97 2.51-7.39 7.39-2.51L3 3z",fill:"currentColor"})}),PanIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M10.05 4.575a1.575 1.575 0 10-3.15 0v3m3.15-3v-1.5a1.575 1.575 0 013.15 0v1.5m-3.15 0l.075 5.925m3.075.75V4.575m0 0a1.575 1.575 0 013.15 0V15M6.9 7.575a1.575 1.575 0 10-3.15 0v8.175a6.75 6.75 0 006.75 6.75h2.018a5.25 5.25 0 003.712-1.538l1.732-1.732a5.25 5.25 0 001.538-3.712l.003-2.024a.668.668 0 01.198-.471 1.575 1.575 0 10-2.228-2.228 3.818 3.818 0 00-1.12 2.687M6.9 7.575V12m6.27 4.318A4.49 4.49 0 0116.35 15m.002 0h-.002"})}),PenIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M16.862 4.487l1.687-1.688a1.875 1.875 0 112.652 2.652L6.832 19.82a4.5 4.5 0 01-1.897 1.13l-2.685.8.8-2.685a4.5 4.5 0 011.13-1.897L16.863 4.487zm0 0L19.5 7.125"})}),HighlighterIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9.53 16.122a3 3 0 00-5.78 1.128 2.25 2.25 0 01-2.4 2.245 4.5 4.5 0 008.4-2.245c0-.399-.078-.78-.22-1.128zm0 0a15.998 15.998 0 003.388-1.62m-5.043-.025a15.994 15.994 0 011.622-3.395m3.42 3.42a15.995 15.995 0 004.764-4.648l3.876-5.814a1.151 1.151 0 00-1.597-1.597L14.146 6.32a15.996 15.996 0 00-4.649 4.763m3.42 3.42a6.776 6.776 0 00-3.42-3.42"})}),FreeTextIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("text",{x:"12",y:"17",fontSize:"16",fontWeight:"bold",textAnchor:"middle",fill:"currentColor",stroke:"none",children:"T"})}),RectangleIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5.25 7.5A2.25 2.25 0 017.5 5.25h9a2.25 2.25 0 012.25 2.25v9a2.25 2.25 0 01-2.25-2.25h-9a2.25 2.25 0 01-2.25-2.25v-9z"})}),CircleIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 21a9 9 0 110-18 9 9 0 010 18z"})}),EraserIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M11.412 15.655L7.797 12.04m3.615 3.615L15.655 11.412m-4.243 4.243L12 12m0 0L8.345 8.345m3.655 3.655L15.655 8.345m-7.31 7.31L12 12m-3.655-3.655L12 12m0 0l3.655 3.655m-3.655-3.655L8.345 8.345m-2.299 6.501a.75.75 0 01-1.06 0l-2.122-2.121a.75.75 0 010-1.061l3.182-3.182a.75.75 0 011.06 0l2.122 2.121a.75.75 0 010 1.061l-3.182 3.182zM18.97 5.03a.75.75 0 010 1.06l-2.121 2.122a.75.75 0 01-1.06 0l-2.122-2.122a.75.75 0 010-1.06l2.122-2.122a.75.75 0 011.06 0l2.121 2.122z"})}),TrashIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M14.74 9l-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 01-2.244 2.077H8.084a2.25 2.25 0 01-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 00-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 013.478-.397m7.5 0v-.916c0-1.18-.91-2.134-2.09-2.134H8.09c-1.18 0-2.09.954-2.09 2.134v.916m7.5 0a48.667 48.667 0 00-7.5 0"})}),ZoomInIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 21l-5.197-5.197m0 0A7.5 7.5 0 105.196 5.196a7.5 7.5 0 0010.607 10.607zM10.5 7.5v6m3-3h-6"})}),ZoomOutIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 21l-5.197-5.197m0 0A7.5 7.5 0 105.196 5.196a7.5 7.5 0 0010.607 10.607zM13.5 10.5h-6"})}),DownloadIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 16.5v2.25A2.25 2.25 0 005.25 21h13.5A2.25 2.25 0 0021 18.75V16.5M16.5 12L12 16.5m0 0L7.5 12m4.5 4.5V3"})}),PrintIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6.72 13.829c-.24.03-.48.062-.72.096m.72-.096a42.415 42.415 0 0110.56 0m-10.56 0L6.34 18m10.94-4.171c.24.03.48.062.72.096m-.72-.096L17.66 18m0 0l.229 2.523a1.125 1.125 0 01-1.12 1.227H7.231c-.662 0-1.18-.568-1.12-1.227L6.34 18m11.32 0c0-1.24-.98-2.25-2.21-2.25H8.552c-1.23 0-2.21 1.01-2.21 2.25m11.32 0-2.21 2.25m-8.9-2.25L7.45 15.456a1.125 1.125 0 011.591 0l.022.022a1.125 1.125 0 010 1.591l-1.18 1.18m0-1.18a9 9 0 009.536 2.343M3.75 21a3.375 3.375 0 01-3.375-3.375V10.312c0-.178.051-.35.146-.5l2.351-4.006a1.125 1.125 0 01.97-.566h12.556c.376 0 .723.158.97.43l2.351 4.006c.095.15.146.322.146.5v7.312a3.375 3.375 0 01-3.375 3.375H3.75z"})}),UploadIcon=()=>jsxRuntime.jsx("svg",{className:"mx-auto h-12 w-12 text-gray-400",stroke:"currentColor",fill:"none",viewBox:"0 0 48 48","aria-hidden":"true",children:jsxRuntime.jsx("path",{d:"M28 8H12a4 4 0 00-4 4v20m32-12v8m0 0v8a4 4 0 01-4 4H12a4 4 0 01-4-4v-4m32-4l-3.172-3.172a4 4 0 00-5.656 0L28 28M8 32l9.172-9.172a4 4 0 015.656 0L28 28",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})}),UnderlineIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 4.5v15m-6.75-3.75h13.5"})}),StrikeoutIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 4.5v15m-6.75-7.5h13.5"})}),SquigglyIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 12c3-3 6 3 9 0s6 3 9 0"})}),StampIcon=()=>jsxRuntime.jsxs("svg",{...iconProps,children:[jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 6v6m-6 4h12m-6-8a2 2 0 100-4 2 2 0 000 4z"}),jsxRuntime.jsx("rect",{x:"6",y:"16",width:"12",height:"4",stroke:"currentColor",strokeWidth:"1.5",fill:"none",rx:"1"}),jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 20h12"})]}),SignatureIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M10.5 6h9.75M10.5 6a1.5 1.5 0 11-3 0m3 0a1.5 1.5 0 10-3 0M3.75 6H7.5m3 12h9.75m-9.75 0a1.5 1.5 0 01-3 0m3 0a1.5 1.5 0 00-3 0m-3.75 0H7.5m9-6h3.75m-3.75 0a1.5 1.5 0 01-3 0m3 0a1.5 1.5 0 00-3 0m-9.75 0h9.75"})}),InitialsIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15.75 6a3.75 3.75 0 11-7.5 0 3.75 3.75 0 017.5 0zM4.501 20.118a7.5 7.5 0 0114.998 0A17.933 17.933 0 0112 21.75c-2.676 0-5.216-.584-7.499-1.632z"})}),UndoIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9 15L3 9m0 0l6-6M3 9h12a6 6 0 010 12h-3"})}),RedoIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 15l6-6m0 0l-6-6m6 6H9a6 6 0 000 12h3"})}),MoreIcon=()=>jsxRuntime.jsx("svg",{...iconProps,children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 6.75a.75.75 0 110-1.5.75.75 0 010 1.5zM12 12.75a.75.75 0 110-1.5.75.75 0 010 1.5zM12 18.75a.75.75 0 110-1.5.75.75 0 010 1.5z"})}),RotateIcon=()=>jsxRuntime.jsxs("svg",{...iconProps,children:[jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M20.25 12A8.25 8.25 0 0012 3.75c-2.23 0-4.25.88-5.74 2.31M3.75 3.75v4.5h4.5"}),jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3.75 12A8.25 8.25 0 0012 20.25c2.23 0 4.25-.88 5.74-2.31"})]}),ToolButton=({label:t,isActive:e=!1,onClick:r,children:n,disabled:a=!1})=>jsxRuntime.jsx("button",{title:t,"aria-label":t,onClick:r,disabled:a,className:`p-2 rounded-md transition-colors ${e?"bg-indigo-500 text-white":"hover:bg-gray-200 text-gray-800"} disabled:opacity-50 disabled:cursor-not-allowed`,children:n}),Toolbar=t=>{const{fileName:e,currentPage:r,totalPages:n,zoom:a,setZoom:s,setCurrentPage:o,activeTool:h,setActiveTool:d,toolColor:l,setToolColor:u,strokeWidth:p,setStrokeWidth:g,fontSize:f,setFontSize:v,onDownload:y,onPrint:S,isProcessing:m,onDelete:w,selectedAnnotationId:R,undo:_,redo:x,canUndo:F,canRedo:A,onSignatureClick:D,onInitialsClick:T,activeStamp:M,setActiveStamp:C,onRotate:k,readonly:O=!1}=t,[$,K]=react.useState(!1),[J,Y]=react.useState(!1),se=react.useRef(null);react.useEffect(()=>{const P=E=>{se.current&&!se.current.contains(E.target)&&K(!1)};return $&&document.addEventListener("mousedown",P),()=>{document.removeEventListener("mousedown",P)}},[$]);const B=P=>{const E=parseInt(P.target.value,10);E>0&&E<=n&&o(E)},V=[{tool:"SELECT",icon:jsxRuntime.jsx(SelectIcon,{}),label:"Select"},{tool:"PAN",icon:jsxRuntime.jsx(PanIcon,{}),label:"Pan"},{tool:"PEN",icon:jsxRuntime.jsx(PenIcon,{}),label:"Pen"},{tool:"HIGHLIGHTER",icon:jsxRuntime.jsx(HighlighterIcon,{}),label:"Highlighter"}],Q=[{tool:"RECTANGLE",icon:jsxRuntime.jsx(RectangleIcon,{}),label:"Rectangle"},{tool:"CIRCLE",icon:jsxRuntime.jsx(CircleIcon,{}),label:"Circle"}],N=[{tool:"TEXT",icon:jsxRuntime.jsx(FreeTextIcon,{}),label:"Free Text"},{tool:"SQUIGGLY",icon:jsxRuntime.jsx(SquigglyIcon,{}),label:"Squiggly"}];return jsxRuntime.jsxs("header",{className:"bg-gray-50 shadow-md p-2 flex flex-col gap-2 z-10",children:[jsxRuntime.jsxs("div",{className:"flex items-center justify-between",children:[jsxRuntime.jsx("span",{className:"font-semibold text-lg truncate max-w-xs text-gray-800",title:e,children:e}),jsxRuntime.jsxs("div",{className:"flex items-center gap-4",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx("button",{onClick:()=>o(r-1),disabled:r<=1,className:"p-2 rounded-md hover:bg-gray-200 disabled:opacity-50 text-gray-800 transition-colors",children:"‹"}),jsxRuntime.jsxs("div",{className:"flex items-center text-gray-800",children:[jsxRuntime.jsx("input",{type:"number",value:r,onChange:B,className:"w-12 text-center bg-white rounded-md border border-gray-300 text-gray-800"}),jsxRuntime.jsx("span",{className:"mx-2",children:"/"}),jsxRuntime.jsx("span",{children:n})]}),jsxRuntime.jsx("button",{onClick:()=>o(r+1),disabled:r>=n,className:"p-2 rounded-md hover:bg-gray-200 disabled:opacity-50 text-gray-800 transition-colors",children:"›"})]}),jsxRuntime.jsx("div",{className:"w-px h-6 bg-gray-300"}),jsxRuntime.jsx("div",{className:"flex items-center gap-1",children:jsxRuntime.jsx(ToolButton,{label:"Rotate Page",onClick:k,children:jsxRuntime.jsx(RotateIcon,{})})}),jsxRuntime.jsx("div",{className:"w-px h-6 bg-gray-300"}),jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(ToolButton,{label:"Zoom Out",onClick:()=>s(Math.max(.25,a-.25)),children:jsxRuntime.jsx(ZoomOutIcon,{})}),jsxRuntime.jsxs("span",{className:"w-16 text-center bg-white rounded-md border border-gray-300 cursor-pointer text-gray-800 py-1",onClick:()=>s(1),children:[Math.round(a*100),"%"]}),jsxRuntime.jsx(ToolButton,{label:"Zoom In",onClick:()=>s(Math.min(4,a+.25)),children:jsxRuntime.jsx(ZoomInIcon,{})})]})]}),jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[!O&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(ToolButton,{label:"Undo",onClick:_,disabled:!F,children:jsxRuntime.jsx(UndoIcon,{})}),jsxRuntime.jsx(ToolButton,{label:"Redo",onClick:x,disabled:!A,children:jsxRuntime.jsx(RedoIcon,{})}),jsxRuntime.jsx("div",{className:"w-px h-6 bg-gray-300"})]}),jsxRuntime.jsxs("div",{className:"relative",ref:se,children:[jsxRuntime.jsx(ToolButton,{label:"More options",onClick:()=>K(!$),children:jsxRuntime.jsx(MoreIcon,{})}),$&&jsxRuntime.jsx("div",{className:"absolute right-0 mt-2 w-56 bg-white rounded-md shadow-lg border border-gray-200 z-50",children:jsxRuntime.jsxs("div",{className:"py-1",children:[jsxRuntime.jsxs("button",{onClick:()=>{S(),K(!1)},disabled:m,className:"w-full text-left px-4 py-2 text-sm text-gray-800 hover:bg-gray-100 disabled:opacity-50 disabled:cursor-not-allowed flex items-center gap-3",children:[jsxRuntime.jsx(PrintIcon,{}),jsxRuntime.jsx("span",{children:"Print"})]}),jsxRuntime.jsxs("button",{onClick:()=>{y(),K(!1)},disabled:m,className:"w-full text-left px-4 py-2 text-sm text-gray-800 hover:bg-gray-100 disabled:opacity-50 disabled:cursor-not-allowed flex items-center gap-3",children:[jsxRuntime.jsx(DownloadIcon,{}),jsxRuntime.jsx("span",{children:"Download"})]}),!O&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:"border-t border-gray-200 my-1"}),jsxRuntime.jsxs("button",{onClick:()=>{Y(!J),K(!1)},className:"w-full text-left px-4 py-2 text-sm text-gray-800 hover:bg-gray-100 flex items-center gap-3",children:[jsxRuntime.jsx("span",{className:"w-5 h-5 flex items-center justify-center",children:J?"✓":""}),jsxRuntime.jsx("span",{children:"Show Annotation Tools"})]})]})]})})]})]})]}),!O&&J&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:"w-full h-px bg-gray-300"}),jsxRuntime.jsxs("div",{className:"flex items-center justify-center gap-4 flex-wrap",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-1 bg-white border border-gray-300 p-1 rounded-lg",children:[V.map(P=>jsxRuntime.jsx(ToolButton,{label:P.label,isActive:h===P.tool,onClick:()=>d(P.tool),children:P.icon},P.tool)),jsxRuntime.jsx("div",{className:"w-px h-6 bg-gray-300 mx-1"}),jsxRuntime.jsx(ToolButton,{label:"Delete",onClick:w,disabled:!R,children:jsxRuntime.jsx(TrashIcon,{})})]}),jsxRuntime.jsx("div",{className:"flex items-center gap-1 bg-white border border-gray-300 p-1 rounded-lg",children:Q.map(P=>jsxRuntime.jsx(ToolButton,{label:P.label,isActive:h===P.tool,onClick:()=>d(P.tool),children:P.icon},P.tool))}),jsxRuntime.jsx("div",{className:"flex items-center gap-1 bg-white border border-gray-300 p-1 rounded-lg",children:N.map(P=>jsxRuntime.jsx(ToolButton,{label:P.label,isActive:h===P.tool,onClick:()=>d(P.tool),children:P.icon},P.tool))}),jsxRuntime.jsxs("div",{className:"flex items-center gap-1 bg-white border border-gray-300 p-1 rounded-lg",children:[jsxRuntime.jsx(ToolButton,{label:"Stamp",isActive:h==="STAMP",onClick:()=>d("STAMP"),children:jsxRuntime.jsx(StampIcon,{})}),jsxRuntime.jsx("select",{value:M,onChange:P=>C(P.target.value),className:"bg-white border border-gray-300 rounded-md px-2 py-1 text-sm text-gray-800 focus:outline-none focus:ring-2 focus:ring-indigo-500",children:STAMPS.map(P=>jsxRuntime.jsx("option",{value:P,children:P},P))})]}),jsxRuntime.jsxs("div",{className:"flex items-center gap-2 bg-white border border-gray-300 p-1 rounded-lg",children:[jsxRuntime.jsx("input",{type:"color",value:l,onChange:P=>u(P.target.value),className:"w-8 h-8 p-0 border-none rounded-md cursor-pointer bg-transparent",title:"Select color"}),jsxRuntime.jsx("select",{value:p,onChange:P=>g(Number(P.target.value)),className:"bg-white border border-gray-300 rounded-md px-2 py-1 text-sm text-gray-800 focus:outline-none focus:ring-2 focus:ring-indigo-500",title:"Stroke Width",children:STROKE_WIDTHS.map(P=>jsxRuntime.jsxs("option",{value:P,children:[P,"px"]},P))}),jsxRuntime.jsx("select",{value:f,onChange:P=>v(Number(P.target.value)),className:"bg-white border border-gray-300 rounded-md px-2 py-1 text-sm text-gray-800 focus:outline-none focus:ring-2 focus:ring-indigo-500",title:"Font Size",children:FONT_SIZES.map(P=>jsxRuntime.jsxs("option",{value:P,children:[P,"pt"]},P))})]})]})]})]})},AnnotationLayer=t=>{const{width:e,height:r,zoom:n,activeTool:a,toolColor:s,strokeWidth:o,fontSize:h,addAnnotation:d,annotations:l,deleteAnnotation:u,updateAnnotation:p,selectedAnnotationId:g,setSelectedAnnotationId:f,signatureData:v,initialsData:y,activeStamp:S,readonly:m=!1}=t,[w,R]=react.useState({mode:"none",startPos:{x:0,y:0}}),[_,x]=react.useState(null),F=react.useRef(null),[A,D]=react.useState(null),[T,M]=react.useState(null),C=B=>{const V=B.currentTarget,Q=V.getScreenCTM();if(Q){const E=new DOMPoint(B.clientX,B.clientY).matrixTransform(Q.inverse());return{x:E.x/n,y:E.y/n}}const N=V.getBoundingClientRect();return{x:(B.clientX-N.left)/n,y:(B.clientY-N.top)/n}},k=B=>{if(m)return;const V=C(B);if(a!=="PAN"){if(a==="SELECT"){const Q=l.find(P=>P.id===g);if(Q){const P=getAnnotationBoundingBox(Q);if(P){const E=getResizeHandles(P);for(const I in E){const z=E[I],G=8/n;if(V.x>=z.x-G/2&&V.x<=z.x+G/2&&V.y>=z.y-G/2&&V.y<=z.y+G/2){R({mode:"resizing",handle:I,startPos:V,originalAnnotation:Q});return}}}if(isPointInAnnotation(V,Q,n)){R({mode:"moving",startPos:V,originalAnnotation:Q});return}}const N=l.slice().reverse().find(P=>isPointInAnnotation(V,P,n));f(N?N.id:null),N&&R({mode:"moving",startPos:V,originalAnnotation:N});return}["TEXT","STAMP","SIGNATURE","INITIALS"].includes(a)||(R({mode:"drawing",startPos:V}),["PEN","HIGHLIGHTER","UNDERLINE","STRIKETHROUGH","SQUIGGLY"].includes(a)&&x({type:a,points:[V],color:s,strokeWidth:o,id:"temp",page:0}))}},O=B=>{if(m)return;const V=C(B);if(a==="SELECT"&&w.mode==="none"&&g){const Q=l.find(N=>N.id===g);if(Q){const N=getAnnotationBoundingBox(Q);if(N){const P=getResizeHandles(N);let E=null;for(const I in P){const z=P[I],G=8/n;if(V.x>=z.x-G/2&&V.x<=z.x+G/2&&V.y>=z.y-G/2&&V.y<=z.y+G/2){E=I;break}}M(E)}else M(null)}else M(null)}else w.mode==="none"&&M(null);if(w.mode==="moving"&&w.originalAnnotation){const Q=V.x-w.startPos.x,N=V.y-w.startPos.y;x(moveAnnotation(w.originalAnnotation,Q,N))}else if(w.mode==="resizing"&&w.originalAnnotation&&w.handle){const Q=V.x-w.startPos.x,N=V.y-w.startPos.y;x(resizeAnnotation(w.originalAnnotation,w.handle,Q,N))}else if(w.mode==="drawing"){const{startPos:Q}=w;let N=null;switch(a){case"PEN":case"HIGHLIGHTER":case"UNDERLINE":case"STRIKETHROUGH":case"SQUIGGLY":N={..._,points:[..._.points,V]};break;case"RECTANGLE":N={type:"RECTANGLE",x:Math.min(Q.x,V.x),y:Math.min(Q.y,V.y),width:Math.abs(Q.x-V.x),height:Math.abs(Q.y-V.y),color:s,strokeWidth:o,id:"temp",page:0};break;case"CIRCLE":N={type:"CIRCLE",cx:(Q.x+V.x)/2,cy:(Q.y+V.y)/2,rx:Math.abs(Q.x-V.x)/2,ry:Math.abs(Q.y-V.y)/2,color:s,strokeWidth:o,id:"temp",page:0};break}N&&x(N)}},$=()=>{if(!m){if(w.mode==="moving"||w.mode==="resizing")_&&p(_);else if(w.mode==="drawing"&&_){const{id:B,page:V,...Q}=_;d(Q)}R({mode:"none",startPos:{x:0,y:0}}),x(null)}},K=B=>{if(m||w.mode!=="none")return;const V=C(B);if(a==="TEXT"&&(D(V),setTimeout(()=>{var Q;return(Q=F.current)==null?void 0:Q.focus()},0)),a==="STAMP"){const N=new Date().toLocaleString();d({type:"STAMP",x:V.x-70,y:V.y-25,width:140,height:55,text:S,fontSize:18,color:s,strokeWidth:2,timestamp:N})}a==="SIGNATURE"&&v&&d({type:"SIGNATURE",x:V.x-75,y:V.y-37.5,width:150,height:75,imageData:v,color:s,strokeWidth:0}),a==="INITIALS"&&y&&d({type:"INITIALS",x:V.x-40,y:V.y-20,width:80,height:40,imageData:y,color:s,strokeWidth:0})},J=()=>{if(m||!A||!F.current)return;const B=F.current.value.trim();B&&d({type:"TEXT",x:A.x,y:A.y,width:F.current.offsetWidth/n,height:F.current.offsetHeight/n,content:B,fontSize:h,color:s,strokeWidth:1}),D(null)},Y=_?l.map(B=>B.id===_.id?_:B):l;w.mode==="drawing"&&_&&!l.find(B=>B.id===_.id)&&Y.push(_);const se=getCursor(a,g,T,w.mode);return jsxRuntime.jsxs("div",{className:"absolute top-0 left-0",style:{cursor:se,pointerEvents:a==="PAN"?"none":"auto"},children:[jsxRuntime.jsx("svg",{width:e,height:r,onMouseDown:k,onMouseMove:O,onMouseUp:$,onMouseLeave:$,onClick:K,style:{pointerEvents:a==="PAN"?"none":"auto"},children:Y.map(B=>renderAnnotation(B,g,n))}),A&&jsxRuntime.jsx("textarea",{ref:F,onBlur:J,style:{position:"absolute",left:A.x*n,top:A.y*n,border:`1px dashed ${s}`,color:s,background:"rgba(255,255,255,0.9)",fontSize:`${h}px`,lineHeight:1.2,width:"auto",minWidth:"150px",height:"auto",minHeight:`${h*1.5}px`,resize:"both",outline:"none",overflow:"auto",zIndex:100,fontFamily:"sans-serif"}})]})};function renderAnnotation(t,e,r){const n=t.id===e,a={stroke:t.color,strokeWidth:t.strokeWidth};let s=null;switch(t.type){case"PEN":const h=t.points.map(f=>`${f.x*r},${f.y*r}`).join(" ");s=jsxRuntime.jsx("polyline",{points:h,fill:"none",...a,strokeLinecap:"round",strokeLinejoin:"round"});break;case"UNDERLINE":const d=t.points.map(f=>`${f.x*r},${f.y*r}`).join(" ");s=jsxRuntime.jsx("polyline",{points:d,fill:"none",...a,strokeLinecap:"round"});break;case"STRIKETHROUGH":const l=t.points.map(f=>`${f.x*r},${f.y*r}`).join(" ");s=jsxRuntime.jsx("polyline",{points:l,fill:"none",...a,strokeLinecap:"round"});break;case"SQUIGGLY":const u=t.points.map(f=>`${f.x*r},${f.y*r}`).join(" ");s=jsxRuntime.jsx("polyline",{points:u,fill:"none",...a});break;case"HIGHLIGHTER":const p=t.points.map(f=>`${f.x*r},${f.y*r}`).join(" ");s=jsxRuntime.jsx("polyline",{points:p,fill:"none",...a,strokeOpacity:.3,strokeWidth:t.strokeWidth*5,strokeLinecap:"round"});break;case"RECTANGLE":s=jsxRuntime.jsx("rect",{x:t.x*r,y:t.y*r,width:t.width*r,height:t.height*r,fill:"none",...a});break;case"CIRCLE":s=jsxRuntime.jsx("ellipse",{cx:t.cx*r,cy:t.cy*r,rx:t.rx*r,ry:t.ry*r,fill:"none",...a});break;case"TEXT":const g=t.content.split(`
|
|
9
9
|
`);s=jsxRuntime.jsxs("g",{children:[n&&jsxRuntime.jsx("rect",{x:t.x*r,y:t.y*r,width:t.width*r,height:(t.height||g.length*t.fontSize*1.2)*r,fill:"rgba(255,255,255,0.1)",stroke:t.color,strokeWidth:"0.5",strokeDasharray:"2,2"}),jsxRuntime.jsx("text",{x:t.x*r,y:t.y*r+t.fontSize*r,fill:t.color,fontSize:t.fontSize*r,children:g.map((f,v)=>jsxRuntime.jsx("tspan",{x:t.x*r,dy:v===0?0:t.fontSize*r*1.2,children:f},v))})]});break;case"STAMP":s=jsxRuntime.jsxs("g",{children:[jsxRuntime.jsx("rect",{x:t.x*r,y:t.y*r,width:t.width*r,height:t.height*r,fill:"none",stroke:t.color,strokeWidth:"2",opacity:"0.8"}),jsxRuntime.jsx("text",{x:(t.x+t.width/2)*r,y:(t.y+t.height*.35)*r,fill:t.color,fontSize:t.fontSize*r,textAnchor:"middle",alignmentBaseline:"middle",fontWeight:"bold",opacity:"0.8",children:t.text}),t.timestamp&&jsxRuntime.jsx("text",{x:(t.x+t.width/2)*r,y:(t.y+t.height*.7)*r,fill:t.color,fontSize:t.fontSize*.45*r,textAnchor:"middle",alignmentBaseline:"middle",opacity:"0.7",children:t.timestamp})]});break;case"SIGNATURE":case"INITIALS":s=jsxRuntime.jsx("image",{href:t.imageData,x:t.x*r,y:t.y*r,width:t.width*r,height:t.height*r});break}const o=getAnnotationBoundingBox(t);return jsxRuntime.jsxs("g",{children:[s,n&&o&&renderSelectionBox(o,r)]},t.id)}function getAnnotationBoundingBox(t){let e=1/0,r=1/0,n=-1/0,a=-1/0;switch(t.type){case"RECTANGLE":case"STAMP":case"SIGNATURE":case"INITIALS":return{minX:t.x,minY:t.y,maxX:t.x+t.width,maxY:t.y+t.height};case"TEXT":const s=t.height||t.content.split(`
|
|
10
|
-
`).length*t.fontSize*1.2;return{minX:t.x,minY:t.y,maxX:t.x+t.width,maxY:t.y+s};case"CIRCLE":return{minX:t.cx-t.rx,minY:t.cy-t.ry,maxX:t.cx+t.rx,maxY:t.cy+t.ry};case"PEN":case"HIGHLIGHTER":case"UNDERLINE":case"STRIKETHROUGH":case"SQUIGGLY":return t.points.forEach(o=>{e=Math.min(e,o.x),r=Math.min(r,o.y),n=Math.max(n,o.x),a=Math.max(a,o.y)}),{minX:e,minY:r,maxX:n,maxY:a}}return null}function renderSelectionBox(t,e){const r=4/e,n={x:(t.minX-r)*e,y:(t.minY-r)*e,width:(t.maxX-t.minX+r*2)*e,height:(t.maxY-t.minY+r*2)*e},a=getResizeHandles(t),s=8;return jsxRuntime.jsxs("g",{children:[jsxRuntime.jsx("rect",{...n,fill:"none",stroke:"#ffffff",strokeWidth:"3",strokeDasharray:"5 5"}),jsxRuntime.jsx("rect",{...n,fill:"none",stroke:"#0ea5e9",strokeWidth:"2",strokeDasharray:"5 5"}),Object.values(a).map((o,h)=>jsxRuntime.jsx("rect",{x:o.x*e-s/2,y:o.y*e-s/2,width:s,height:s,fill:"#0ea5e9",stroke:"#ffffff",strokeWidth:"2"},h))]})}function getResizeHandles(t){return{tl:{x:t.minX,y:t.minY},t:{x:(t.minX+t.maxX)/2,y:t.minY},tr:{x:t.maxX,y:t.minY},l:{x:t.minX,y:(t.minY+t.maxY)/2},r:{x:t.maxX,y:(t.minY+t.maxY)/2},bl:{x:t.minX,y:t.maxY},b:{x:(t.minX+t.maxX)/2,y:t.maxY},br:{x:t.maxX,y:t.maxY}}}function isPointInAnnotation(t,e,r){const n=getAnnotationBoundingBox(e);if(!n)return!1;const a=5/r;return t.x>=n.minX-a&&t.x<=n.maxX+a&&t.y>=n.minY-a&&t.y<=n.maxY+a}function moveAnnotation(t,e,r){const n=JSON.parse(JSON.stringify(t));switch(n.type){case"RECTANGLE":case"TEXT":case"STAMP":case"SIGNATURE":case"INITIALS":n.x+=e,n.y+=r;break;case"CIRCLE":n.cx+=e,n.cy+=r;break;case"PEN":case"HIGHLIGHTER":case"UNDERLINE":case"STRIKETHROUGH":case"SQUIGGLY":n.points=n.points.map(a=>({x:a.x+e,y:a.y+r}));break}return n}function resizeAnnotation(t,e,r,n){const a=JSON.parse(JSON.stringify(t));return a.type==="CIRCLE"?(e.includes("l")&&(a.cx+=r/2,a.rx-=r/2),e.includes("r")&&(a.cx+=r/2,a.rx+=r/2),e.includes("t")&&(a.cy+=n/2,a.ry-=n/2),e.includes("b")&&(a.cy+=n/2,a.ry+=n/2),a.rx<10&&(a.rx=10),a.ry<10&&(a.ry=10),a.rx<0&&(a.rx*=-1),a.ry<0&&(a.ry*=-1)):(a.type==="RECTANGLE"||a.type==="SIGNATURE"||a.type==="INITIALS"||a.type==="STAMP"||a.type==="TEXT")&&(e.includes("l")&&(a.x+=r,a.width-=r),e.includes("r")&&(a.width+=r),e.includes("t")&&(a.y+=n,a.height-=n),e.includes("b")&&(a.height+=n),a.width<0&&(a.x+=a.width,a.width*=-1),a.height<0&&(a.y+=a.height,a.height*=-1),a.type==="TEXT"&&(a.width<50&&(a.width=50),a.height||(a.height=a.fontSize*1.5),a.height<a.fontSize*1.2&&(a.height=a.fontSize*1.2))),a}function getCursor(t,e,r,n){if(t==="PAN")return"grab";if(t==="SELECT"&&r&&n==="none")switch(r){case"tl":case"br":return"nwse-resize";case"tr":case"bl":return"nesw-resize";case"t":case"b":return"ns-resize";case"l":case"r":return"ew-resize"}return n==="resizing"||n==="moving"?"grabbing":t==="SELECT"?e?"move":"default":["PEN","RECTANGLE","CIRCLE","HIGHLIGHTER","UNDERLINE","STRIKETHROUGH","SQUIGGLY"].includes(t)?"crosshair":t==="TEXT"?"text":["STAMP","SIGNATURE","INITIALS"].includes(t)?"crosshair":"default"}const PdfPage=t=>{const{pdf:e,pageNumber:r,zoom:n,rotation:a}=t,s=react.useRef(null),o=react.useRef(null),[h,d]=react.useState(null),[l,u]=react.useState({width:0,height:0}),p=react.useRef(null);react.useEffect(()=>{e.getPage(r).then(d)},[e,r]),react.useEffect(()=>{if(h&&s.current){const y=s.current,
|
|
10
|
+
`).length*t.fontSize*1.2;return{minX:t.x,minY:t.y,maxX:t.x+t.width,maxY:t.y+s};case"CIRCLE":return{minX:t.cx-t.rx,minY:t.cy-t.ry,maxX:t.cx+t.rx,maxY:t.cy+t.ry};case"PEN":case"HIGHLIGHTER":case"UNDERLINE":case"STRIKETHROUGH":case"SQUIGGLY":return t.points.forEach(o=>{e=Math.min(e,o.x),r=Math.min(r,o.y),n=Math.max(n,o.x),a=Math.max(a,o.y)}),{minX:e,minY:r,maxX:n,maxY:a}}return null}function renderSelectionBox(t,e){const r=4/e,n={x:(t.minX-r)*e,y:(t.minY-r)*e,width:(t.maxX-t.minX+r*2)*e,height:(t.maxY-t.minY+r*2)*e},a=getResizeHandles(t),s=8;return jsxRuntime.jsxs("g",{children:[jsxRuntime.jsx("rect",{...n,fill:"none",stroke:"#ffffff",strokeWidth:"3",strokeDasharray:"5 5"}),jsxRuntime.jsx("rect",{...n,fill:"none",stroke:"#0ea5e9",strokeWidth:"2",strokeDasharray:"5 5"}),Object.values(a).map((o,h)=>jsxRuntime.jsx("rect",{x:o.x*e-s/2,y:o.y*e-s/2,width:s,height:s,fill:"#0ea5e9",stroke:"#ffffff",strokeWidth:"2"},h))]})}function getResizeHandles(t){return{tl:{x:t.minX,y:t.minY},t:{x:(t.minX+t.maxX)/2,y:t.minY},tr:{x:t.maxX,y:t.minY},l:{x:t.minX,y:(t.minY+t.maxY)/2},r:{x:t.maxX,y:(t.minY+t.maxY)/2},bl:{x:t.minX,y:t.maxY},b:{x:(t.minX+t.maxX)/2,y:t.maxY},br:{x:t.maxX,y:t.maxY}}}function isPointInAnnotation(t,e,r){const n=getAnnotationBoundingBox(e);if(!n)return!1;const a=5/r;return t.x>=n.minX-a&&t.x<=n.maxX+a&&t.y>=n.minY-a&&t.y<=n.maxY+a}function moveAnnotation(t,e,r){const n=JSON.parse(JSON.stringify(t));switch(n.type){case"RECTANGLE":case"TEXT":case"STAMP":case"SIGNATURE":case"INITIALS":n.x+=e,n.y+=r;break;case"CIRCLE":n.cx+=e,n.cy+=r;break;case"PEN":case"HIGHLIGHTER":case"UNDERLINE":case"STRIKETHROUGH":case"SQUIGGLY":n.points=n.points.map(a=>({x:a.x+e,y:a.y+r}));break}return n}function resizeAnnotation(t,e,r,n){const a=JSON.parse(JSON.stringify(t));return a.type==="CIRCLE"?(e.includes("l")&&(a.cx+=r/2,a.rx-=r/2),e.includes("r")&&(a.cx+=r/2,a.rx+=r/2),e.includes("t")&&(a.cy+=n/2,a.ry-=n/2),e.includes("b")&&(a.cy+=n/2,a.ry+=n/2),a.rx<10&&(a.rx=10),a.ry<10&&(a.ry=10),a.rx<0&&(a.rx*=-1),a.ry<0&&(a.ry*=-1)):(a.type==="RECTANGLE"||a.type==="SIGNATURE"||a.type==="INITIALS"||a.type==="STAMP"||a.type==="TEXT")&&(e.includes("l")&&(a.x+=r,a.width-=r),e.includes("r")&&(a.width+=r),e.includes("t")&&(a.y+=n,a.height-=n),e.includes("b")&&(a.height+=n),a.width<0&&(a.x+=a.width,a.width*=-1),a.height<0&&(a.y+=a.height,a.height*=-1),a.type==="TEXT"&&(a.width<50&&(a.width=50),a.height||(a.height=a.fontSize*1.5),a.height<a.fontSize*1.2&&(a.height=a.fontSize*1.2))),a}function getCursor(t,e,r,n){if(t==="PAN")return"grab";if(t==="SELECT"&&r&&n==="none")switch(r){case"tl":case"br":return"nwse-resize";case"tr":case"bl":return"nesw-resize";case"t":case"b":return"ns-resize";case"l":case"r":return"ew-resize"}return n==="resizing"||n==="moving"?"grabbing":t==="SELECT"?e?"move":"default":["PEN","RECTANGLE","CIRCLE","HIGHLIGHTER","UNDERLINE","STRIKETHROUGH","SQUIGGLY"].includes(t)?"crosshair":t==="TEXT"?"text":["STAMP","SIGNATURE","INITIALS"].includes(t)?"crosshair":"default"}const PdfPage=t=>{const{pdf:e,pageNumber:r,zoom:n,rotation:a}=t,s=react.useRef(null),o=react.useRef(null),[h,d]=react.useState(null),[l,u]=react.useState({width:0,height:0}),p=react.useRef(null);react.useEffect(()=>{e.getPage(r).then(d)},[e,r]),react.useEffect(()=>{if(h&&s.current){const y=s.current,S=y.getContext("2d");if(!S)return;p.current&&(p.current.cancel(),p.current=null);const m=h.getViewport({scale:n}),w=window.devicePixelRatio||1;y.width=Math.floor(m.width*w),y.height=Math.floor(m.height*w),y.style.width=`${m.width}px`,y.style.height=`${m.height}px`,S.setTransform(w,0,0,w,0,0),u({width:m.width,height:m.height});const R={canvasContext:S,viewport:m},_=h.render(R);p.current=_,_.promise.then(async()=>{if(p.current=null,o.current){o.current.innerHTML="";const x=await h.getTextContent();await pdfExports.renderTextLayer({textContentSource:x,container:o.current,viewport:m}).promise}}).catch(x=>{x.name!=="RenderingCancelledException"&&console.error("Error rendering page:",x),p.current=null})}return()=>{p.current&&(p.current.cancel(),p.current=null)}},[h,n]);const g=a===90||a===270,f=g?l.height:l.width,v=g?l.width:l.height;return jsxRuntime.jsx("div",{className:"relative my-4 shadow-lg mx-auto print-page",style:{width:f,height:v,overflow:"hidden"},children:jsxRuntime.jsxs("div",{style:{width:l.width,height:l.height,transform:a?`rotate(${a}deg)`:void 0,transformOrigin:"center center",position:"absolute",left:(f-l.width)/2,top:(v-l.height)/2,userSelect:"text"},children:[jsxRuntime.jsx("canvas",{ref:s,style:{userSelect:"none"}}),jsxRuntime.jsx("div",{ref:o,className:"textLayer",style:{width:l.width,height:l.height}}),l.width>0&&jsxRuntime.jsx(AnnotationLayer,{...t,width:l.width,height:l.height})]})})},SignatureModal=({onClose:t,onSave:e,title:r})=>{const n=react.useRef(null),[a,s]=react.useState(!1),o=()=>{const g=n.current;if(!g)return null;const f=g.getContext("2d");return f&&(f.strokeStyle="#000000",f.lineWidth=2,f.lineCap="round",f.lineJoin="round"),f};react.useEffect(()=>{o()},[]);const h=g=>{const f=o();f&&(s(!0),f.beginPath(),f.moveTo(g.nativeEvent.offsetX,g.nativeEvent.offsetY))},d=g=>{if(!a)return;const f=o();f&&(f.lineTo(g.nativeEvent.offsetX,g.nativeEvent.offsetY),f.stroke())},l=()=>{const g=o();g&&(g.closePath(),s(!1))},u=()=>{const g=n.current,f=o();!g||!f||f.clearRect(0,0,g.width,g.height)},p=()=>{const g=n.current;if(!g)return;const f=document.createElement("canvas");if(f.width=g.width,f.height=g.height,g.toDataURL()===f.toDataURL()){alert("Please provide a signature before saving.");return}e(g.toDataURL("image/png")),t()};return jsxRuntime.jsx("div",{className:"fixed inset-0 bg-black bg-opacity-60 flex items-center justify-center z-50",onClick:t,children:jsxRuntime.jsxs("div",{className:"bg-gray-800 rounded-lg shadow-xl p-6 w-full max-w-lg",onClick:g=>g.stopPropagation(),children:[jsxRuntime.jsx("h3",{className:"text-xl font-semibold mb-4",children:r}),jsxRuntime.jsx("canvas",{ref:n,width:"460",height:"200",className:"bg-white rounded-md cursor-crosshair",onMouseDown:h,onMouseMove:d,onMouseUp:l,onMouseLeave:l}),jsxRuntime.jsxs("div",{className:"flex justify-end gap-4 mt-4",children:[jsxRuntime.jsx("button",{onClick:u,className:"px-4 py-2 rounded-md bg-gray-600 hover:bg-gray-500 transition-colors",children:"Clear"}),jsxRuntime.jsx("button",{onClick:t,className:"px-4 py-2 rounded-md bg-gray-600 hover:bg-gray-500 transition-colors",children:"Cancel"}),jsxRuntime.jsx("button",{onClick:p,className:"px-4 py-2 rounded-md bg-indigo-600 hover:bg-indigo-500 transition-colors",children:"Save"})]})]})})},useAnnotationHistory=()=>{var f,v;const[t,e]=react.useState({history:[{}],index:0}),r=((f=t==null?void 0:t.history)==null?void 0:f[(t==null?void 0:t.index)??0])??{},n=react.useCallback(y=>{e(S=>{var _;const m=((_=S==null?void 0:S.history)==null?void 0:_[(S==null?void 0:S.index)??0])??{},w=y(m);if(JSON.stringify(m)===JSON.stringify(w))return S;const R=((S==null?void 0:S.history)??[{}]).slice(0,((S==null?void 0:S.index)??0)+1);return R.push(w),{history:R,index:R.length-1}})},[]),a=react.useCallback((y,S)=>{n(m=>{const w=JSON.parse(JSON.stringify(m)),R={...S,page:y,id:`${Date.now()}-${Math.random()}`},_=w[y]?[...w[y],R]:[R];return w[y]=_,w})},[n]),s=react.useCallback((y,S)=>{n(m=>{const w=JSON.parse(JSON.stringify(m));return w[y]?(w[y]=w[y].filter(R=>R.id!==S),w):m})},[n]),o=react.useCallback(y=>{n(S=>{const m=JSON.parse(JSON.stringify(S)),w=y.page;if(!m[w])return S;const R=m[w].findIndex(_=>_.id===y.id);return R===-1?S:(m[w][R]=y,m)})},[n]),h=react.useCallback(()=>{n(()=>({}))},[n]),d=react.useCallback(y=>{e({history:[y],index:0})},[]),l=react.useCallback(()=>{e(y=>({...y,index:Math.max(0,((y==null?void 0:y.index)??0)-1)}))},[]),u=react.useCallback(()=>{e(y=>{var S;return{...y,index:Math.min((((S=y==null?void 0:y.history)==null?void 0:S.length)??1)-1,((y==null?void 0:y.index)??0)+1)}})},[]),p=((t==null?void 0:t.index)??0)>0,g=((t==null?void 0:t.index)??0)<(((v=t==null?void 0:t.history)==null?void 0:v.length)??1)-1;return{annotations:r,addAnnotation:a,deleteAnnotation:s,updateAnnotation:o,clearAnnotations:h,setAnnotations:d,undo:l,redo:u,canUndo:p,canRedo:g,historyState:t,setHistoryState:e}};/*! *****************************************************************************
|
|
11
11
|
Copyright (c) Microsoft Corporation.
|
|
12
12
|
|
|
13
13
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
21
21
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
22
22
|
PERFORMANCE OF THIS SOFTWARE.
|
|
23
|
-
***************************************************************************** */var extendStatics=function(t,e){return extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,n){r.__proto__=n}||function(r,n){for(var a in n)n.hasOwnProperty(a)&&(r[a]=n[a])},extendStatics(t,e)};function __extends(t,e){extendStatics(t,e);function r(){this.constructor=t}t.prototype=e===null?Object.create(e):(r.prototype=e.prototype,new r)}var __assign=function(){return __assign=Object.assign||function(e){for(var r,n=1,a=arguments.length;n<a;n++){r=arguments[n];for(var s in r)Object.prototype.hasOwnProperty.call(r,s)&&(e[s]=r[s])}return e},__assign.apply(this,arguments)};function __rest(t,e){var r={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(t);a<n.length;a++)e.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(t,n[a])&&(r[n[a]]=t[n[a]]);return r}function __awaiter(t,e,r,n){function a(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function h(u){try{l(n.next(u))}catch(p){o(p)}}function d(u){try{l(n.throw(u))}catch(p){o(p)}}function l(u){u.done?s(u.value):a(u.value).then(h,d)}l((n=n.apply(t,[])).next())})}function __generator(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},n,a,s,o;return o={next:h(0),throw:h(1),return:h(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function h(l){return function(u){return d([l,u])}}function d(l){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,a&&(s=l[0]&2?a.return:l[0]?a.throw||((s=a.return)&&s.call(a),0):a.next)&&!(s=s.call(a,l[1])).done)return s;switch(a=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,a=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(u){l=[6,u],a=0}finally{n=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}function __spreadArrays(){for(var t=0,e=0,r=arguments.length;e<r;e++)t+=arguments[e].length;for(var n=Array(t),a=0,e=0;e<r;e++)for(var s=arguments[e],o=0,h=s.length;o<h;o++,a++)n[a]=s[o];return n}for(var chars$1="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",lookup$1=new Uint8Array(256),i$1=0;i$1<chars$1.length;i$1++)lookup$1[chars$1.charCodeAt(i$1)]=i$1;var encodeToBase64=function(t){for(var e="",r=t.length,n=0;n<r;n+=3)e+=chars$1[t[n]>>2],e+=chars$1[(t[n]&3)<<4|t[n+1]>>4],e+=chars$1[(t[n+1]&15)<<2|t[n+2]>>6],e+=chars$1[t[n+2]&63];return r%3===2?e=e.substring(0,e.length-1)+"=":r%3===1&&(e=e.substring(0,e.length-2)+"=="),e},decodeFromBase64$1=function(t){var e=t.length*.75,r=t.length,n,a=0,s,o,h,d;t[t.length-1]==="="&&(e--,t[t.length-2]==="="&&e--);var l=new Uint8Array(e);for(n=0;n<r;n+=4)s=lookup$1[t.charCodeAt(n)],o=lookup$1[t.charCodeAt(n+1)],h=lookup$1[t.charCodeAt(n+2)],d=lookup$1[t.charCodeAt(n+3)],l[a++]=s<<2|o>>4,l[a++]=(o&15)<<4|h>>2,l[a++]=(h&3)<<6|d&63;return l},DATA_URI_PREFIX_REGEX=/^(data)?:?([\w\/\+]+)?;?(charset=[\w-]+|base64)?.*,/i,decodeFromBase64DataUri=function(t){var e=t.trim(),r=e.substring(0,100),n=r.match(DATA_URI_PREFIX_REGEX);if(!n)return decodeFromBase64$1(e);var a=n[0],s=e.substring(a.length);return decodeFromBase64$1(s)},toCharCode=function(t){return t.charCodeAt(0)},toCodePoint=function(t){return t.codePointAt(0)},toHexStringOfMinLength=function(t,e){return padStart$1(t.toString(16),e,"0").toUpperCase()},toHexString=function(t){return toHexStringOfMinLength(t,2)},charFromCode=function(t){return String.fromCharCode(t)},charFromHexCode=function(t){return charFromCode(parseInt(t,16))},padStart$1=function(t,e,r){for(var n="",a=0,s=e-t.length;a<s;a++)n+=r;return n+t},copyStringIntoBuffer=function(t,e,r){for(var n=t.length,a=0;a<n;a++)e[r++]=t.charCodeAt(a);return n},escapeRegExp=function(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")},cleanText=function(t){return t.replace(/\t|\u0085|\u2028|\u2029/g," ").replace(/[\b\v]/g,"")},escapedNewlineChars=["\\n","\\f","\\r","\\u000B"],isNewlineChar=function(t){return/^[\n\f\r\u000B]$/.test(t)},lineSplit=function(t){return t.split(/[\n\f\r\u000B]/)},mergeLines=function(t){return t.replace(/[\n\f\r\u000B]/g," ")},charAtIndex=function(t,e){var r=t.charCodeAt(e),n,a=e+1,s=1;return r>=55296&&r<=56319&&t.length>a&&(n=t.charCodeAt(a),n>=56320&&n<=57343&&(s=2)),[t.slice(e,e+s),s]},charSplit=function(t){for(var e=[],r=0,n=t.length;r<n;){var a=charAtIndex(t,r),s=a[0],o=a[1];e.push(s),r+=o}return e},buildWordBreakRegex=function(t){for(var e=escapedNewlineChars.join("|"),r=["$"],n=0,a=t.length;n<a;n++){var s=t[n];if(isNewlineChar(s))throw new TypeError("`wordBreak` must not include "+e);r.push(s===""?".":escapeRegExp(s))}var o=r.join("|");return new RegExp("("+e+")|((.*?)("+o+"))","gm")},breakTextIntoLines=function(t,e,r,n){for(var a=buildWordBreakRegex(e),s=cleanText(t).match(a),o="",h=0,d=[],l=function(){o!==""&&d.push(o),o="",h=0},u=0,p=s.length;u<p;u++){var g=s[u];if(isNewlineChar(g))l();else{var f=n(g);h+f>r&&l(),o+=g,h+=f}}return l(),d},dateRegex=/^D:(\d\d\d\d)(\d\d)?(\d\d)?(\d\d)?(\d\d)?(\d\d)?([+\-Z])?(\d\d)?'?(\d\d)?'?$/,parseDate=function(t){var e=t.match(dateRegex);if(e){var r=e[1],n=e[2],a=n===void 0?"01":n,s=e[3],o=s===void 0?"01":s,h=e[4],d=h===void 0?"00":h,l=e[5],u=l===void 0?"00":l,p=e[6],g=p===void 0?"00":p,f=e[7],v=f===void 0?"Z":f,y=e[8],x=y===void 0?"00":y,m=e[9],w=m===void 0?"00":m,R=v==="Z"?"Z":""+v+x+":"+w,_=new Date(r+"-"+a+"-"+o+"T"+d+":"+u+":"+g+R);return _}},findLastMatch=function(t,e){for(var r,n=0,a;n<t.length;){var s=t.substring(n).match(e);if(!s)return{match:a,pos:n};a=s,n+=((r=s.index)!==null&&r!==void 0?r:0)+s[0].length}return{match:a,pos:n}},last=function(t){return t[t.length-1]},typedArrayFor=function(t){if(t instanceof Uint8Array)return t;for(var e=t.length,r=new Uint8Array(e),n=0;n<e;n++)r[n]=t.charCodeAt(n);return r},mergeIntoTypedArray=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];for(var r=t.length,n=[],a=0;a<r;a++){var s=t[a];n[a]=s instanceof Uint8Array?s:typedArrayFor(s)}for(var o=0,a=0;a<r;a++)o+=t[a].length;for(var h=new Uint8Array(o),d=0,l=0;l<r;l++)for(var u=n[l],p=0,g=u.length;p<g;p++)h[d++]=u[p];return h},mergeUint8Arrays=function(t){for(var e=0,r=0,n=t.length;r<n;r++)e+=t[r].length;for(var a=new Uint8Array(e),s=0,r=0,n=t.length;r<n;r++){var o=t[r];a.set(o,s),s+=o.length}return a},arrayAsString=function(t){for(var e="",r=0,n=t.length;r<n;r++)e+=charFromCode(t[r]);return e},byAscendingId=function(t,e){return t.id-e.id},sortedUniq=function(t,e){for(var r=[],n=0,a=t.length;n<a;n++){var s=t[n],o=t[n-1];(n===0||e(s)!==e(o))&&r.push(s)}return r},reverseArray=function(t){for(var e=t.length,r=0,n=Math.floor(e/2);r<n;r++){var a=r,s=e-r-1,o=t[r];t[a]=t[s],t[s]=o}return t},sum=function(t){for(var e=0,r=0,n=t.length;r<n;r++)e+=t[r];return e},range=function(t,e){for(var r=new Array(e-t),n=0,a=r.length;n<a;n++)r[n]=t+n;return r},pluckIndices=function(t,e){for(var r=new Array(e.length),n=0,a=e.length;n<a;n++)r[n]=t[e[n]];return r},canBeConvertedToUint8Array=function(t){return t instanceof Uint8Array||t instanceof ArrayBuffer||typeof t=="string"},toUint8Array=function(t){if(typeof t=="string")return decodeFromBase64DataUri(t);if(t instanceof ArrayBuffer)return new Uint8Array(t);if(t instanceof Uint8Array)return t;throw new TypeError("`input` must be one of `string | ArrayBuffer | Uint8Array`")},waitForTick=function(){return new Promise(function(t){setTimeout(function(){return t()},0)})},utf16Encode=function(t,e){e===void 0&&(e=!0);var r=[];e&&r.push(65279);for(var n=0,a=t.length;n<a;){var s=t.codePointAt(n);if(s<65536)r.push(s),n+=1;else if(s<1114112)r.push(highSurrogate(s),lowSurrogate(s)),n+=2;else throw new Error("Invalid code point: 0x"+toHexString(s))}return new Uint16Array(r)},isWithinBMP=function(t){return t>=0&&t<=65535},hasSurrogates=function(t){return t>=65536&&t<=1114111},highSurrogate=function(t){return Math.floor((t-65536)/1024)+55296},lowSurrogate=function(t){return(t-65536)%1024+56320},ByteOrder;(function(t){t.BigEndian="BigEndian",t.LittleEndian="LittleEndian"})(ByteOrder||(ByteOrder={}));var REPLACEMENT="�".codePointAt(0),utf16Decode=function(t,e){if(e===void 0&&(e=!0),t.length<=1)return String.fromCodePoint(REPLACEMENT);for(var r=e?readBOM(t):ByteOrder.BigEndian,n=e?2:0,a=[];t.length-n>=2;){var s=decodeValues(t[n++],t[n++],r);if(isHighSurrogate(s))if(t.length-n<2)a.push(REPLACEMENT);else{var o=decodeValues(t[n++],t[n++],r);isLowSurrogate(o)?a.push(s,o):a.push(REPLACEMENT)}else isLowSurrogate(s)?(n+=2,a.push(REPLACEMENT)):a.push(s)}return n<t.length&&a.push(REPLACEMENT),String.fromCodePoint.apply(String,a)},isHighSurrogate=function(t){return t>=55296&&t<=56319},isLowSurrogate=function(t){return t>=56320&&t<=57343},decodeValues=function(t,e,r){if(r===ByteOrder.LittleEndian)return e<<8|t;if(r===ByteOrder.BigEndian)return t<<8|e;throw new Error("Invalid byteOrder: "+r)},readBOM=function(t){return hasUtf16BigEndianBOM(t)?ByteOrder.BigEndian:hasUtf16LittleEndianBOM(t)?ByteOrder.LittleEndian:ByteOrder.BigEndian},hasUtf16BigEndianBOM=function(t){return t[0]===254&&t[1]===255},hasUtf16LittleEndianBOM=function(t){return t[0]===255&&t[1]===254},hasUtf16BOM=function(t){return hasUtf16BigEndianBOM(t)||hasUtf16LittleEndianBOM(t)},numberToString=function(t){var e=String(t);if(Math.abs(t)<1){var r=parseInt(t.toString().split("e-")[1]);if(r){var n=t<0;n&&(t*=-1),t*=Math.pow(10,r-1),e="0."+new Array(r).join("0")+t.toString().substring(2),n&&(e="-"+e)}}else{var r=parseInt(t.toString().split("+")[1]);r>20&&(r-=20,t/=Math.pow(10,r),e=t.toString()+new Array(r+1).join("0"))}return e},sizeInBytes=function(t){return Math.ceil(t.toString(2).length/8)},bytesFor=function(t){for(var e=new Uint8Array(sizeInBytes(t)),r=1;r<=e.length;r++)e[r-1]=t>>(e.length-r)*8;return e},error=function(t){throw new Error(t)},common={};(function(t){var e=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";function r(s,o){return Object.prototype.hasOwnProperty.call(s,o)}t.assign=function(s){for(var o=Array.prototype.slice.call(arguments,1);o.length;){var h=o.shift();if(h){if(typeof h!="object")throw new TypeError(h+"must be non-object");for(var d in h)r(h,d)&&(s[d]=h[d])}}return s},t.shrinkBuf=function(s,o){return s.length===o?s:s.subarray?s.subarray(0,o):(s.length=o,s)};var n={arraySet:function(s,o,h,d,l){if(o.subarray&&s.subarray){s.set(o.subarray(h,h+d),l);return}for(var u=0;u<d;u++)s[l+u]=o[h+u]},flattenChunks:function(s){var o,h,d,l,u,p;for(d=0,o=0,h=s.length;o<h;o++)d+=s[o].length;for(p=new Uint8Array(d),l=0,o=0,h=s.length;o<h;o++)u=s[o],p.set(u,l),l+=u.length;return p}},a={arraySet:function(s,o,h,d,l){for(var u=0;u<d;u++)s[l+u]=o[h+u]},flattenChunks:function(s){return[].concat.apply([],s)}};t.setTyped=function(s){s?(t.Buf8=Uint8Array,t.Buf16=Uint16Array,t.Buf32=Int32Array,t.assign(t,n)):(t.Buf8=Array,t.Buf16=Array,t.Buf32=Array,t.assign(t,a))},t.setTyped(e)})(common);var deflate$4={},deflate$3={},trees$1={},utils$6=common,Z_FIXED$1=4,Z_BINARY=0,Z_TEXT=1,Z_UNKNOWN$1=2;function zero$1(t){for(var e=t.length;--e>=0;)t[e]=0}var STORED_BLOCK=0,STATIC_TREES=1,DYN_TREES=2,MIN_MATCH$1=3,MAX_MATCH$1=258,LENGTH_CODES$1=29,LITERALS$1=256,L_CODES$1=LITERALS$1+1+LENGTH_CODES$1,D_CODES$1=30,BL_CODES$1=19,HEAP_SIZE$1=2*L_CODES$1+1,MAX_BITS$1=15,Buf_size=16,MAX_BL_BITS=7,END_BLOCK=256,REP_3_6=16,REPZ_3_10=17,REPZ_11_138=18,extra_lbits=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],extra_dbits=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],extra_blbits=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],bl_order=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],DIST_CODE_LEN=512,static_ltree=new Array((L_CODES$1+2)*2);zero$1(static_ltree);var static_dtree=new Array(D_CODES$1*2);zero$1(static_dtree);var _dist_code=new Array(DIST_CODE_LEN);zero$1(_dist_code);var _length_code=new Array(MAX_MATCH$1-MIN_MATCH$1+1);zero$1(_length_code);var base_length=new Array(LENGTH_CODES$1);zero$1(base_length);var base_dist=new Array(D_CODES$1);zero$1(base_dist);function StaticTreeDesc(t,e,r,n,a){this.static_tree=t,this.extra_bits=e,this.extra_base=r,this.elems=n,this.max_length=a,this.has_stree=t&&t.length}var static_l_desc,static_d_desc,static_bl_desc;function TreeDesc(t,e){this.dyn_tree=t,this.max_code=0,this.stat_desc=e}function d_code(t){return t<256?_dist_code[t]:_dist_code[256+(t>>>7)]}function put_short(t,e){t.pending_buf[t.pending++]=e&255,t.pending_buf[t.pending++]=e>>>8&255}function send_bits(t,e,r){t.bi_valid>Buf_size-r?(t.bi_buf|=e<<t.bi_valid&65535,put_short(t,t.bi_buf),t.bi_buf=e>>Buf_size-t.bi_valid,t.bi_valid+=r-Buf_size):(t.bi_buf|=e<<t.bi_valid&65535,t.bi_valid+=r)}function send_code(t,e,r){send_bits(t,r[e*2],r[e*2+1])}function bi_reverse(t,e){var r=0;do r|=t&1,t>>>=1,r<<=1;while(--e>0);return r>>>1}function bi_flush(t){t.bi_valid===16?(put_short(t,t.bi_buf),t.bi_buf=0,t.bi_valid=0):t.bi_valid>=8&&(t.pending_buf[t.pending++]=t.bi_buf&255,t.bi_buf>>=8,t.bi_valid-=8)}function gen_bitlen(t,e){var r=e.dyn_tree,n=e.max_code,a=e.stat_desc.static_tree,s=e.stat_desc.has_stree,o=e.stat_desc.extra_bits,h=e.stat_desc.extra_base,d=e.stat_desc.max_length,l,u,p,g,f,v,y=0;for(g=0;g<=MAX_BITS$1;g++)t.bl_count[g]=0;for(r[t.heap[t.heap_max]*2+1]=0,l=t.heap_max+1;l<HEAP_SIZE$1;l++)u=t.heap[l],g=r[r[u*2+1]*2+1]+1,g>d&&(g=d,y++),r[u*2+1]=g,!(u>n)&&(t.bl_count[g]++,f=0,u>=h&&(f=o[u-h]),v=r[u*2],t.opt_len+=v*(g+f),s&&(t.static_len+=v*(a[u*2+1]+f)));if(y!==0){do{for(g=d-1;t.bl_count[g]===0;)g--;t.bl_count[g]--,t.bl_count[g+1]+=2,t.bl_count[d]--,y-=2}while(y>0);for(g=d;g!==0;g--)for(u=t.bl_count[g];u!==0;)p=t.heap[--l],!(p>n)&&(r[p*2+1]!==g&&(t.opt_len+=(g-r[p*2+1])*r[p*2],r[p*2+1]=g),u--)}}function gen_codes(t,e,r){var n=new Array(MAX_BITS$1+1),a=0,s,o;for(s=1;s<=MAX_BITS$1;s++)n[s]=a=a+r[s-1]<<1;for(o=0;o<=e;o++){var h=t[o*2+1];h!==0&&(t[o*2]=bi_reverse(n[h]++,h))}}function tr_static_init(){var t,e,r,n,a,s=new Array(MAX_BITS$1+1);for(r=0,n=0;n<LENGTH_CODES$1-1;n++)for(base_length[n]=r,t=0;t<1<<extra_lbits[n];t++)_length_code[r++]=n;for(_length_code[r-1]=n,a=0,n=0;n<16;n++)for(base_dist[n]=a,t=0;t<1<<extra_dbits[n];t++)_dist_code[a++]=n;for(a>>=7;n<D_CODES$1;n++)for(base_dist[n]=a<<7,t=0;t<1<<extra_dbits[n]-7;t++)_dist_code[256+a++]=n;for(e=0;e<=MAX_BITS$1;e++)s[e]=0;for(t=0;t<=143;)static_ltree[t*2+1]=8,t++,s[8]++;for(;t<=255;)static_ltree[t*2+1]=9,t++,s[9]++;for(;t<=279;)static_ltree[t*2+1]=7,t++,s[7]++;for(;t<=287;)static_ltree[t*2+1]=8,t++,s[8]++;for(gen_codes(static_ltree,L_CODES$1+1,s),t=0;t<D_CODES$1;t++)static_dtree[t*2+1]=5,static_dtree[t*2]=bi_reverse(t,5);static_l_desc=new StaticTreeDesc(static_ltree,extra_lbits,LITERALS$1+1,L_CODES$1,MAX_BITS$1),static_d_desc=new StaticTreeDesc(static_dtree,extra_dbits,0,D_CODES$1,MAX_BITS$1),static_bl_desc=new StaticTreeDesc(new Array(0),extra_blbits,0,BL_CODES$1,MAX_BL_BITS)}function init_block(t){var e;for(e=0;e<L_CODES$1;e++)t.dyn_ltree[e*2]=0;for(e=0;e<D_CODES$1;e++)t.dyn_dtree[e*2]=0;for(e=0;e<BL_CODES$1;e++)t.bl_tree[e*2]=0;t.dyn_ltree[END_BLOCK*2]=1,t.opt_len=t.static_len=0,t.last_lit=t.matches=0}function bi_windup(t){t.bi_valid>8?put_short(t,t.bi_buf):t.bi_valid>0&&(t.pending_buf[t.pending++]=t.bi_buf),t.bi_buf=0,t.bi_valid=0}function copy_block(t,e,r,n){bi_windup(t),put_short(t,r),put_short(t,~r),utils$6.arraySet(t.pending_buf,t.window,e,r,t.pending),t.pending+=r}function smaller(t,e,r,n){var a=e*2,s=r*2;return t[a]<t[s]||t[a]===t[s]&&n[e]<=n[r]}function pqdownheap(t,e,r){for(var n=t.heap[r],a=r<<1;a<=t.heap_len&&(a<t.heap_len&&smaller(e,t.heap[a+1],t.heap[a],t.depth)&&a++,!smaller(e,n,t.heap[a],t.depth));)t.heap[r]=t.heap[a],r=a,a<<=1;t.heap[r]=n}function compress_block(t,e,r){var n,a,s=0,o,h;if(t.last_lit!==0)do n=t.pending_buf[t.d_buf+s*2]<<8|t.pending_buf[t.d_buf+s*2+1],a=t.pending_buf[t.l_buf+s],s++,n===0?send_code(t,a,e):(o=_length_code[a],send_code(t,o+LITERALS$1+1,e),h=extra_lbits[o],h!==0&&(a-=base_length[o],send_bits(t,a,h)),n--,o=d_code(n),send_code(t,o,r),h=extra_dbits[o],h!==0&&(n-=base_dist[o],send_bits(t,n,h)));while(s<t.last_lit);send_code(t,END_BLOCK,e)}function build_tree(t,e){var r=e.dyn_tree,n=e.stat_desc.static_tree,a=e.stat_desc.has_stree,s=e.stat_desc.elems,o,h,d=-1,l;for(t.heap_len=0,t.heap_max=HEAP_SIZE$1,o=0;o<s;o++)r[o*2]!==0?(t.heap[++t.heap_len]=d=o,t.depth[o]=0):r[o*2+1]=0;for(;t.heap_len<2;)l=t.heap[++t.heap_len]=d<2?++d:0,r[l*2]=1,t.depth[l]=0,t.opt_len--,a&&(t.static_len-=n[l*2+1]);for(e.max_code=d,o=t.heap_len>>1;o>=1;o--)pqdownheap(t,r,o);l=s;do o=t.heap[1],t.heap[1]=t.heap[t.heap_len--],pqdownheap(t,r,1),h=t.heap[1],t.heap[--t.heap_max]=o,t.heap[--t.heap_max]=h,r[l*2]=r[o*2]+r[h*2],t.depth[l]=(t.depth[o]>=t.depth[h]?t.depth[o]:t.depth[h])+1,r[o*2+1]=r[h*2+1]=l,t.heap[1]=l++,pqdownheap(t,r,1);while(t.heap_len>=2);t.heap[--t.heap_max]=t.heap[1],gen_bitlen(t,e),gen_codes(r,d,t.bl_count)}function scan_tree(t,e,r){var n,a=-1,s,o=e[0*2+1],h=0,d=7,l=4;for(o===0&&(d=138,l=3),e[(r+1)*2+1]=65535,n=0;n<=r;n++)s=o,o=e[(n+1)*2+1],!(++h<d&&s===o)&&(h<l?t.bl_tree[s*2]+=h:s!==0?(s!==a&&t.bl_tree[s*2]++,t.bl_tree[REP_3_6*2]++):h<=10?t.bl_tree[REPZ_3_10*2]++:t.bl_tree[REPZ_11_138*2]++,h=0,a=s,o===0?(d=138,l=3):s===o?(d=6,l=3):(d=7,l=4))}function send_tree(t,e,r){var n,a=-1,s,o=e[0*2+1],h=0,d=7,l=4;for(o===0&&(d=138,l=3),n=0;n<=r;n++)if(s=o,o=e[(n+1)*2+1],!(++h<d&&s===o)){if(h<l)do send_code(t,s,t.bl_tree);while(--h!==0);else s!==0?(s!==a&&(send_code(t,s,t.bl_tree),h--),send_code(t,REP_3_6,t.bl_tree),send_bits(t,h-3,2)):h<=10?(send_code(t,REPZ_3_10,t.bl_tree),send_bits(t,h-3,3)):(send_code(t,REPZ_11_138,t.bl_tree),send_bits(t,h-11,7));h=0,a=s,o===0?(d=138,l=3):s===o?(d=6,l=3):(d=7,l=4)}}function build_bl_tree(t){var e;for(scan_tree(t,t.dyn_ltree,t.l_desc.max_code),scan_tree(t,t.dyn_dtree,t.d_desc.max_code),build_tree(t,t.bl_desc),e=BL_CODES$1-1;e>=3&&t.bl_tree[bl_order[e]*2+1]===0;e--);return t.opt_len+=3*(e+1)+5+5+4,e}function send_all_trees(t,e,r,n){var a;for(send_bits(t,e-257,5),send_bits(t,r-1,5),send_bits(t,n-4,4),a=0;a<n;a++)send_bits(t,t.bl_tree[bl_order[a]*2+1],3);send_tree(t,t.dyn_ltree,e-1),send_tree(t,t.dyn_dtree,r-1)}function detect_data_type(t){var e=4093624447,r;for(r=0;r<=31;r++,e>>>=1)if(e&1&&t.dyn_ltree[r*2]!==0)return Z_BINARY;if(t.dyn_ltree[9*2]!==0||t.dyn_ltree[10*2]!==0||t.dyn_ltree[13*2]!==0)return Z_TEXT;for(r=32;r<LITERALS$1;r++)if(t.dyn_ltree[r*2]!==0)return Z_TEXT;return Z_BINARY}var static_init_done=!1;function _tr_init(t){static_init_done||(tr_static_init(),static_init_done=!0),t.l_desc=new TreeDesc(t.dyn_ltree,static_l_desc),t.d_desc=new TreeDesc(t.dyn_dtree,static_d_desc),t.bl_desc=new TreeDesc(t.bl_tree,static_bl_desc),t.bi_buf=0,t.bi_valid=0,init_block(t)}function _tr_stored_block(t,e,r,n){send_bits(t,(STORED_BLOCK<<1)+(n?1:0),3),copy_block(t,e,r)}function _tr_align(t){send_bits(t,STATIC_TREES<<1,3),send_code(t,END_BLOCK,static_ltree),bi_flush(t)}function _tr_flush_block(t,e,r,n){var a,s,o=0;t.level>0?(t.strm.data_type===Z_UNKNOWN$1&&(t.strm.data_type=detect_data_type(t)),build_tree(t,t.l_desc),build_tree(t,t.d_desc),o=build_bl_tree(t),a=t.opt_len+3+7>>>3,s=t.static_len+3+7>>>3,s<=a&&(a=s)):a=s=r+5,r+4<=a&&e!==-1?_tr_stored_block(t,e,r,n):t.strategy===Z_FIXED$1||s===a?(send_bits(t,(STATIC_TREES<<1)+(n?1:0),3),compress_block(t,static_ltree,static_dtree)):(send_bits(t,(DYN_TREES<<1)+(n?1:0),3),send_all_trees(t,t.l_desc.max_code+1,t.d_desc.max_code+1,o+1),compress_block(t,t.dyn_ltree,t.dyn_dtree)),init_block(t),n&&bi_windup(t)}function _tr_tally(t,e,r){return t.pending_buf[t.d_buf+t.last_lit*2]=e>>>8&255,t.pending_buf[t.d_buf+t.last_lit*2+1]=e&255,t.pending_buf[t.l_buf+t.last_lit]=r&255,t.last_lit++,e===0?t.dyn_ltree[r*2]++:(t.matches++,e--,t.dyn_ltree[(_length_code[r]+LITERALS$1+1)*2]++,t.dyn_dtree[d_code(e)*2]++),t.last_lit===t.lit_bufsize-1}trees$1._tr_init=_tr_init,trees$1._tr_stored_block=_tr_stored_block,trees$1._tr_flush_block=_tr_flush_block,trees$1._tr_tally=_tr_tally,trees$1._tr_align=_tr_align;function adler32$2(t,e,r,n){for(var a=t&65535|0,s=t>>>16&65535|0,o=0;r!==0;){o=r>2e3?2e3:r,r-=o;do a=a+e[n++]|0,s=s+a|0;while(--o);a%=65521,s%=65521}return a|s<<16|0}var adler32_1=adler32$2;function makeTable(){for(var t,e=[],r=0;r<256;r++){t=r;for(var n=0;n<8;n++)t=t&1?3988292384^t>>>1:t>>>1;e[r]=t}return e}var crcTable=makeTable();function crc32$2(t,e,r,n){var a=crcTable,s=n+r;t^=-1;for(var o=n;o<s;o++)t=t>>>8^a[(t^e[o])&255];return t^-1}var crc32_1=crc32$2,messages={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},utils$5=common,trees=trees$1,adler32$1=adler32_1,crc32$1=crc32_1,msg$2=messages,Z_NO_FLUSH$1=0,Z_PARTIAL_FLUSH=1,Z_FULL_FLUSH=3,Z_FINISH$2=4,Z_BLOCK$1=5,Z_OK$2=0,Z_STREAM_END$2=1,Z_STREAM_ERROR$1=-2,Z_DATA_ERROR$1=-3,Z_BUF_ERROR$1=-5,Z_DEFAULT_COMPRESSION$1=-1,Z_FILTERED=1,Z_HUFFMAN_ONLY=2,Z_RLE=3,Z_FIXED=4,Z_DEFAULT_STRATEGY$1=0,Z_UNKNOWN=2,Z_DEFLATED$2=8,MAX_MEM_LEVEL=9,MAX_WBITS$1=15,DEF_MEM_LEVEL=8,LENGTH_CODES=29,LITERALS=256,L_CODES=LITERALS+1+LENGTH_CODES,D_CODES=30,BL_CODES=19,HEAP_SIZE=2*L_CODES+1,MAX_BITS=15,MIN_MATCH=3,MAX_MATCH=258,MIN_LOOKAHEAD=MAX_MATCH+MIN_MATCH+1,PRESET_DICT=32,INIT_STATE=42,EXTRA_STATE=69,NAME_STATE=73,COMMENT_STATE=91,HCRC_STATE=103,BUSY_STATE=113,FINISH_STATE=666,BS_NEED_MORE=1,BS_BLOCK_DONE=2,BS_FINISH_STARTED=3,BS_FINISH_DONE=4,OS_CODE=3;function err(t,e){return t.msg=msg$2[e],e}function rank(t){return(t<<1)-(t>4?9:0)}function zero(t){for(var e=t.length;--e>=0;)t[e]=0}function flush_pending(t){var e=t.state,r=e.pending;r>t.avail_out&&(r=t.avail_out),r!==0&&(utils$5.arraySet(t.output,e.pending_buf,e.pending_out,r,t.next_out),t.next_out+=r,e.pending_out+=r,t.total_out+=r,t.avail_out-=r,e.pending-=r,e.pending===0&&(e.pending_out=0))}function flush_block_only(t,e){trees._tr_flush_block(t,t.block_start>=0?t.block_start:-1,t.strstart-t.block_start,e),t.block_start=t.strstart,flush_pending(t.strm)}function put_byte(t,e){t.pending_buf[t.pending++]=e}function putShortMSB(t,e){t.pending_buf[t.pending++]=e>>>8&255,t.pending_buf[t.pending++]=e&255}function read_buf(t,e,r,n){var a=t.avail_in;return a>n&&(a=n),a===0?0:(t.avail_in-=a,utils$5.arraySet(e,t.input,t.next_in,a,r),t.state.wrap===1?t.adler=adler32$1(t.adler,e,a,r):t.state.wrap===2&&(t.adler=crc32$1(t.adler,e,a,r)),t.next_in+=a,t.total_in+=a,a)}function longest_match(t,e){var r=t.max_chain_length,n=t.strstart,a,s,o=t.prev_length,h=t.nice_match,d=t.strstart>t.w_size-MIN_LOOKAHEAD?t.strstart-(t.w_size-MIN_LOOKAHEAD):0,l=t.window,u=t.w_mask,p=t.prev,g=t.strstart+MAX_MATCH,f=l[n+o-1],v=l[n+o];t.prev_length>=t.good_match&&(r>>=2),h>t.lookahead&&(h=t.lookahead);do if(a=e,!(l[a+o]!==v||l[a+o-1]!==f||l[a]!==l[n]||l[++a]!==l[n+1])){n+=2,a++;do;while(l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&n<g);if(s=MAX_MATCH-(g-n),n=g-MAX_MATCH,s>o){if(t.match_start=e,o=s,s>=h)break;f=l[n+o-1],v=l[n+o]}}while((e=p[e&u])>d&&--r!==0);return o<=t.lookahead?o:t.lookahead}function fill_window(t){var e=t.w_size,r,n,a,s,o;do{if(s=t.window_size-t.lookahead-t.strstart,t.strstart>=e+(e-MIN_LOOKAHEAD)){utils$5.arraySet(t.window,t.window,e,e,0),t.match_start-=e,t.strstart-=e,t.block_start-=e,n=t.hash_size,r=n;do a=t.head[--r],t.head[r]=a>=e?a-e:0;while(--n);n=e,r=n;do a=t.prev[--r],t.prev[r]=a>=e?a-e:0;while(--n);s+=e}if(t.strm.avail_in===0)break;if(n=read_buf(t.strm,t.window,t.strstart+t.lookahead,s),t.lookahead+=n,t.lookahead+t.insert>=MIN_MATCH)for(o=t.strstart-t.insert,t.ins_h=t.window[o],t.ins_h=(t.ins_h<<t.hash_shift^t.window[o+1])&t.hash_mask;t.insert&&(t.ins_h=(t.ins_h<<t.hash_shift^t.window[o+MIN_MATCH-1])&t.hash_mask,t.prev[o&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=o,o++,t.insert--,!(t.lookahead+t.insert<MIN_MATCH)););}while(t.lookahead<MIN_LOOKAHEAD&&t.strm.avail_in!==0)}function deflate_stored(t,e){var r=65535;for(r>t.pending_buf_size-5&&(r=t.pending_buf_size-5);;){if(t.lookahead<=1){if(fill_window(t),t.lookahead===0&&e===Z_NO_FLUSH$1)return BS_NEED_MORE;if(t.lookahead===0)break}t.strstart+=t.lookahead,t.lookahead=0;var n=t.block_start+r;if((t.strstart===0||t.strstart>=n)&&(t.lookahead=t.strstart-n,t.strstart=n,flush_block_only(t,!1),t.strm.avail_out===0)||t.strstart-t.block_start>=t.w_size-MIN_LOOKAHEAD&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=0,e===Z_FINISH$2?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):(t.strstart>t.block_start&&(flush_block_only(t,!1),t.strm.avail_out===0),BS_NEED_MORE)}function deflate_fast(t,e){for(var r,n;;){if(t.lookahead<MIN_LOOKAHEAD){if(fill_window(t),t.lookahead<MIN_LOOKAHEAD&&e===Z_NO_FLUSH$1)return BS_NEED_MORE;if(t.lookahead===0)break}if(r=0,t.lookahead>=MIN_MATCH&&(t.ins_h=(t.ins_h<<t.hash_shift^t.window[t.strstart+MIN_MATCH-1])&t.hash_mask,r=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart),r!==0&&t.strstart-r<=t.w_size-MIN_LOOKAHEAD&&(t.match_length=longest_match(t,r)),t.match_length>=MIN_MATCH)if(n=trees._tr_tally(t,t.strstart-t.match_start,t.match_length-MIN_MATCH),t.lookahead-=t.match_length,t.match_length<=t.max_lazy_match&&t.lookahead>=MIN_MATCH){t.match_length--;do t.strstart++,t.ins_h=(t.ins_h<<t.hash_shift^t.window[t.strstart+MIN_MATCH-1])&t.hash_mask,r=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart;while(--t.match_length!==0);t.strstart++}else t.strstart+=t.match_length,t.match_length=0,t.ins_h=t.window[t.strstart],t.ins_h=(t.ins_h<<t.hash_shift^t.window[t.strstart+1])&t.hash_mask;else n=trees._tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++;if(n&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=t.strstart<MIN_MATCH-1?t.strstart:MIN_MATCH-1,e===Z_FINISH$2?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE}function deflate_slow(t,e){for(var r,n,a;;){if(t.lookahead<MIN_LOOKAHEAD){if(fill_window(t),t.lookahead<MIN_LOOKAHEAD&&e===Z_NO_FLUSH$1)return BS_NEED_MORE;if(t.lookahead===0)break}if(r=0,t.lookahead>=MIN_MATCH&&(t.ins_h=(t.ins_h<<t.hash_shift^t.window[t.strstart+MIN_MATCH-1])&t.hash_mask,r=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart),t.prev_length=t.match_length,t.prev_match=t.match_start,t.match_length=MIN_MATCH-1,r!==0&&t.prev_length<t.max_lazy_match&&t.strstart-r<=t.w_size-MIN_LOOKAHEAD&&(t.match_length=longest_match(t,r),t.match_length<=5&&(t.strategy===Z_FILTERED||t.match_length===MIN_MATCH&&t.strstart-t.match_start>4096)&&(t.match_length=MIN_MATCH-1)),t.prev_length>=MIN_MATCH&&t.match_length<=t.prev_length){a=t.strstart+t.lookahead-MIN_MATCH,n=trees._tr_tally(t,t.strstart-1-t.prev_match,t.prev_length-MIN_MATCH),t.lookahead-=t.prev_length-1,t.prev_length-=2;do++t.strstart<=a&&(t.ins_h=(t.ins_h<<t.hash_shift^t.window[t.strstart+MIN_MATCH-1])&t.hash_mask,r=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart);while(--t.prev_length!==0);if(t.match_available=0,t.match_length=MIN_MATCH-1,t.strstart++,n&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}else if(t.match_available){if(n=trees._tr_tally(t,0,t.window[t.strstart-1]),n&&flush_block_only(t,!1),t.strstart++,t.lookahead--,t.strm.avail_out===0)return BS_NEED_MORE}else t.match_available=1,t.strstart++,t.lookahead--}return t.match_available&&(n=trees._tr_tally(t,0,t.window[t.strstart-1]),t.match_available=0),t.insert=t.strstart<MIN_MATCH-1?t.strstart:MIN_MATCH-1,e===Z_FINISH$2?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE}function deflate_rle(t,e){for(var r,n,a,s,o=t.window;;){if(t.lookahead<=MAX_MATCH){if(fill_window(t),t.lookahead<=MAX_MATCH&&e===Z_NO_FLUSH$1)return BS_NEED_MORE;if(t.lookahead===0)break}if(t.match_length=0,t.lookahead>=MIN_MATCH&&t.strstart>0&&(a=t.strstart-1,n=o[a],n===o[++a]&&n===o[++a]&&n===o[++a])){s=t.strstart+MAX_MATCH;do;while(n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&a<s);t.match_length=MAX_MATCH-(s-a),t.match_length>t.lookahead&&(t.match_length=t.lookahead)}if(t.match_length>=MIN_MATCH?(r=trees._tr_tally(t,1,t.match_length-MIN_MATCH),t.lookahead-=t.match_length,t.strstart+=t.match_length,t.match_length=0):(r=trees._tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++),r&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=0,e===Z_FINISH$2?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE}function deflate_huff(t,e){for(var r;;){if(t.lookahead===0&&(fill_window(t),t.lookahead===0)){if(e===Z_NO_FLUSH$1)return BS_NEED_MORE;break}if(t.match_length=0,r=trees._tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++,r&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=0,e===Z_FINISH$2?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE}function Config(t,e,r,n,a){this.good_length=t,this.max_lazy=e,this.nice_length=r,this.max_chain=n,this.func=a}var configuration_table;configuration_table=[new Config(0,0,0,0,deflate_stored),new Config(4,4,8,4,deflate_fast),new Config(4,5,16,8,deflate_fast),new Config(4,6,32,32,deflate_fast),new Config(4,4,16,16,deflate_slow),new Config(8,16,32,32,deflate_slow),new Config(8,16,128,128,deflate_slow),new Config(8,32,128,256,deflate_slow),new Config(32,128,258,1024,deflate_slow),new Config(32,258,258,4096,deflate_slow)];function lm_init(t){t.window_size=2*t.w_size,zero(t.head),t.max_lazy_match=configuration_table[t.level].max_lazy,t.good_match=configuration_table[t.level].good_length,t.nice_match=configuration_table[t.level].nice_length,t.max_chain_length=configuration_table[t.level].max_chain,t.strstart=0,t.block_start=0,t.lookahead=0,t.insert=0,t.match_length=t.prev_length=MIN_MATCH-1,t.match_available=0,t.ins_h=0}function DeflateState(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Z_DEFLATED$2,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new utils$5.Buf16(HEAP_SIZE*2),this.dyn_dtree=new utils$5.Buf16((2*D_CODES+1)*2),this.bl_tree=new utils$5.Buf16((2*BL_CODES+1)*2),zero(this.dyn_ltree),zero(this.dyn_dtree),zero(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new utils$5.Buf16(MAX_BITS+1),this.heap=new utils$5.Buf16(2*L_CODES+1),zero(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new utils$5.Buf16(2*L_CODES+1),zero(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function deflateResetKeep(t){var e;return!t||!t.state?err(t,Z_STREAM_ERROR$1):(t.total_in=t.total_out=0,t.data_type=Z_UNKNOWN,e=t.state,e.pending=0,e.pending_out=0,e.wrap<0&&(e.wrap=-e.wrap),e.status=e.wrap?INIT_STATE:BUSY_STATE,t.adler=e.wrap===2?0:1,e.last_flush=Z_NO_FLUSH$1,trees._tr_init(e),Z_OK$2)}function deflateReset(t){var e=deflateResetKeep(t);return e===Z_OK$2&&lm_init(t.state),e}function deflateSetHeader(t,e){return!t||!t.state||t.state.wrap!==2?Z_STREAM_ERROR$1:(t.state.gzhead=e,Z_OK$2)}function deflateInit2(t,e,r,n,a,s){if(!t)return Z_STREAM_ERROR$1;var o=1;if(e===Z_DEFAULT_COMPRESSION$1&&(e=6),n<0?(o=0,n=-n):n>15&&(o=2,n-=16),a<1||a>MAX_MEM_LEVEL||r!==Z_DEFLATED$2||n<8||n>15||e<0||e>9||s<0||s>Z_FIXED)return err(t,Z_STREAM_ERROR$1);n===8&&(n=9);var h=new DeflateState;return t.state=h,h.strm=t,h.wrap=o,h.gzhead=null,h.w_bits=n,h.w_size=1<<h.w_bits,h.w_mask=h.w_size-1,h.hash_bits=a+7,h.hash_size=1<<h.hash_bits,h.hash_mask=h.hash_size-1,h.hash_shift=~~((h.hash_bits+MIN_MATCH-1)/MIN_MATCH),h.window=new utils$5.Buf8(h.w_size*2),h.head=new utils$5.Buf16(h.hash_size),h.prev=new utils$5.Buf16(h.w_size),h.lit_bufsize=1<<a+6,h.pending_buf_size=h.lit_bufsize*4,h.pending_buf=new utils$5.Buf8(h.pending_buf_size),h.d_buf=1*h.lit_bufsize,h.l_buf=3*h.lit_bufsize,h.level=e,h.strategy=s,h.method=r,deflateReset(t)}function deflateInit(t,e){return deflateInit2(t,e,Z_DEFLATED$2,MAX_WBITS$1,DEF_MEM_LEVEL,Z_DEFAULT_STRATEGY$1)}function deflate$2(t,e){var r,n,a,s;if(!t||!t.state||e>Z_BLOCK$1||e<0)return t?err(t,Z_STREAM_ERROR$1):Z_STREAM_ERROR$1;if(n=t.state,!t.output||!t.input&&t.avail_in!==0||n.status===FINISH_STATE&&e!==Z_FINISH$2)return err(t,t.avail_out===0?Z_BUF_ERROR$1:Z_STREAM_ERROR$1);if(n.strm=t,r=n.last_flush,n.last_flush=e,n.status===INIT_STATE)if(n.wrap===2)t.adler=0,put_byte(n,31),put_byte(n,139),put_byte(n,8),n.gzhead?(put_byte(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),put_byte(n,n.gzhead.time&255),put_byte(n,n.gzhead.time>>8&255),put_byte(n,n.gzhead.time>>16&255),put_byte(n,n.gzhead.time>>24&255),put_byte(n,n.level===9?2:n.strategy>=Z_HUFFMAN_ONLY||n.level<2?4:0),put_byte(n,n.gzhead.os&255),n.gzhead.extra&&n.gzhead.extra.length&&(put_byte(n,n.gzhead.extra.length&255),put_byte(n,n.gzhead.extra.length>>8&255)),n.gzhead.hcrc&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=EXTRA_STATE):(put_byte(n,0),put_byte(n,0),put_byte(n,0),put_byte(n,0),put_byte(n,0),put_byte(n,n.level===9?2:n.strategy>=Z_HUFFMAN_ONLY||n.level<2?4:0),put_byte(n,OS_CODE),n.status=BUSY_STATE);else{var o=Z_DEFLATED$2+(n.w_bits-8<<4)<<8,h=-1;n.strategy>=Z_HUFFMAN_ONLY||n.level<2?h=0:n.level<6?h=1:n.level===6?h=2:h=3,o|=h<<6,n.strstart!==0&&(o|=PRESET_DICT),o+=31-o%31,n.status=BUSY_STATE,putShortMSB(n,o),n.strstart!==0&&(putShortMSB(n,t.adler>>>16),putShortMSB(n,t.adler&65535)),t.adler=1}if(n.status===EXTRA_STATE)if(n.gzhead.extra){for(a=n.pending;n.gzindex<(n.gzhead.extra.length&65535)&&!(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),flush_pending(t),a=n.pending,n.pending===n.pending_buf_size));)put_byte(n,n.gzhead.extra[n.gzindex]&255),n.gzindex++;n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),n.gzindex===n.gzhead.extra.length&&(n.gzindex=0,n.status=NAME_STATE)}else n.status=NAME_STATE;if(n.status===NAME_STATE)if(n.gzhead.name){a=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),flush_pending(t),a=n.pending,n.pending===n.pending_buf_size)){s=1;break}n.gzindex<n.gzhead.name.length?s=n.gzhead.name.charCodeAt(n.gzindex++)&255:s=0,put_byte(n,s)}while(s!==0);n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),s===0&&(n.gzindex=0,n.status=COMMENT_STATE)}else n.status=COMMENT_STATE;if(n.status===COMMENT_STATE)if(n.gzhead.comment){a=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),flush_pending(t),a=n.pending,n.pending===n.pending_buf_size)){s=1;break}n.gzindex<n.gzhead.comment.length?s=n.gzhead.comment.charCodeAt(n.gzindex++)&255:s=0,put_byte(n,s)}while(s!==0);n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),s===0&&(n.status=HCRC_STATE)}else n.status=HCRC_STATE;if(n.status===HCRC_STATE&&(n.gzhead.hcrc?(n.pending+2>n.pending_buf_size&&flush_pending(t),n.pending+2<=n.pending_buf_size&&(put_byte(n,t.adler&255),put_byte(n,t.adler>>8&255),t.adler=0,n.status=BUSY_STATE)):n.status=BUSY_STATE),n.pending!==0){if(flush_pending(t),t.avail_out===0)return n.last_flush=-1,Z_OK$2}else if(t.avail_in===0&&rank(e)<=rank(r)&&e!==Z_FINISH$2)return err(t,Z_BUF_ERROR$1);if(n.status===FINISH_STATE&&t.avail_in!==0)return err(t,Z_BUF_ERROR$1);if(t.avail_in!==0||n.lookahead!==0||e!==Z_NO_FLUSH$1&&n.status!==FINISH_STATE){var d=n.strategy===Z_HUFFMAN_ONLY?deflate_huff(n,e):n.strategy===Z_RLE?deflate_rle(n,e):configuration_table[n.level].func(n,e);if((d===BS_FINISH_STARTED||d===BS_FINISH_DONE)&&(n.status=FINISH_STATE),d===BS_NEED_MORE||d===BS_FINISH_STARTED)return t.avail_out===0&&(n.last_flush=-1),Z_OK$2;if(d===BS_BLOCK_DONE&&(e===Z_PARTIAL_FLUSH?trees._tr_align(n):e!==Z_BLOCK$1&&(trees._tr_stored_block(n,0,0,!1),e===Z_FULL_FLUSH&&(zero(n.head),n.lookahead===0&&(n.strstart=0,n.block_start=0,n.insert=0))),flush_pending(t),t.avail_out===0))return n.last_flush=-1,Z_OK$2}return e!==Z_FINISH$2?Z_OK$2:n.wrap<=0?Z_STREAM_END$2:(n.wrap===2?(put_byte(n,t.adler&255),put_byte(n,t.adler>>8&255),put_byte(n,t.adler>>16&255),put_byte(n,t.adler>>24&255),put_byte(n,t.total_in&255),put_byte(n,t.total_in>>8&255),put_byte(n,t.total_in>>16&255),put_byte(n,t.total_in>>24&255)):(putShortMSB(n,t.adler>>>16),putShortMSB(n,t.adler&65535)),flush_pending(t),n.wrap>0&&(n.wrap=-n.wrap),n.pending!==0?Z_OK$2:Z_STREAM_END$2)}function deflateEnd(t){var e;return!t||!t.state?Z_STREAM_ERROR$1:(e=t.state.status,e!==INIT_STATE&&e!==EXTRA_STATE&&e!==NAME_STATE&&e!==COMMENT_STATE&&e!==HCRC_STATE&&e!==BUSY_STATE&&e!==FINISH_STATE?err(t,Z_STREAM_ERROR$1):(t.state=null,e===BUSY_STATE?err(t,Z_DATA_ERROR$1):Z_OK$2))}function deflateSetDictionary(t,e){var r=e.length,n,a,s,o,h,d,l,u;if(!t||!t.state||(n=t.state,o=n.wrap,o===2||o===1&&n.status!==INIT_STATE||n.lookahead))return Z_STREAM_ERROR$1;for(o===1&&(t.adler=adler32$1(t.adler,e,r,0)),n.wrap=0,r>=n.w_size&&(o===0&&(zero(n.head),n.strstart=0,n.block_start=0,n.insert=0),u=new utils$5.Buf8(n.w_size),utils$5.arraySet(u,e,r-n.w_size,n.w_size,0),e=u,r=n.w_size),h=t.avail_in,d=t.next_in,l=t.input,t.avail_in=r,t.next_in=0,t.input=e,fill_window(n);n.lookahead>=MIN_MATCH;){a=n.strstart,s=n.lookahead-(MIN_MATCH-1);do n.ins_h=(n.ins_h<<n.hash_shift^n.window[a+MIN_MATCH-1])&n.hash_mask,n.prev[a&n.w_mask]=n.head[n.ins_h],n.head[n.ins_h]=a,a++;while(--s);n.strstart=a,n.lookahead=MIN_MATCH-1,fill_window(n)}return n.strstart+=n.lookahead,n.block_start=n.strstart,n.insert=n.lookahead,n.lookahead=0,n.match_length=n.prev_length=MIN_MATCH-1,n.match_available=0,t.next_in=d,t.input=l,t.avail_in=h,n.wrap=o,Z_OK$2}deflate$3.deflateInit=deflateInit,deflate$3.deflateInit2=deflateInit2,deflate$3.deflateReset=deflateReset,deflate$3.deflateResetKeep=deflateResetKeep,deflate$3.deflateSetHeader=deflateSetHeader,deflate$3.deflate=deflate$2,deflate$3.deflateEnd=deflateEnd,deflate$3.deflateSetDictionary=deflateSetDictionary,deflate$3.deflateInfo="pako deflate (from Nodeca project)";var strings$2={},utils$4=common,STR_APPLY_OK=!0,STR_APPLY_UIA_OK=!0;try{String.fromCharCode.apply(null,[0])}catch(t){STR_APPLY_OK=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(t){STR_APPLY_UIA_OK=!1}for(var _utf8len=new utils$4.Buf8(256),q=0;q<256;q++)_utf8len[q]=q>=252?6:q>=248?5:q>=240?4:q>=224?3:q>=192?2:1;_utf8len[254]=_utf8len[254]=1,strings$2.string2buf=function(t){var e,r,n,a,s,o=t.length,h=0;for(a=0;a<o;a++)r=t.charCodeAt(a),(r&64512)===55296&&a+1<o&&(n=t.charCodeAt(a+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),a++)),h+=r<128?1:r<2048?2:r<65536?3:4;for(e=new utils$4.Buf8(h),s=0,a=0;s<h;a++)r=t.charCodeAt(a),(r&64512)===55296&&a+1<o&&(n=t.charCodeAt(a+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),a++)),r<128?e[s++]=r:r<2048?(e[s++]=192|r>>>6,e[s++]=128|r&63):r<65536?(e[s++]=224|r>>>12,e[s++]=128|r>>>6&63,e[s++]=128|r&63):(e[s++]=240|r>>>18,e[s++]=128|r>>>12&63,e[s++]=128|r>>>6&63,e[s++]=128|r&63);return e};function buf2binstring(t,e){if(e<65534&&(t.subarray&&STR_APPLY_UIA_OK||!t.subarray&&STR_APPLY_OK))return String.fromCharCode.apply(null,utils$4.shrinkBuf(t,e));for(var r="",n=0;n<e;n++)r+=String.fromCharCode(t[n]);return r}strings$2.buf2binstring=function(t){return buf2binstring(t,t.length)},strings$2.binstring2buf=function(t){for(var e=new utils$4.Buf8(t.length),r=0,n=e.length;r<n;r++)e[r]=t.charCodeAt(r);return e},strings$2.buf2string=function(t,e){var r,n,a,s,o=e||t.length,h=new Array(o*2);for(n=0,r=0;r<o;){if(a=t[r++],a<128){h[n++]=a;continue}if(s=_utf8len[a],s>4){h[n++]=65533,r+=s-1;continue}for(a&=s===2?31:s===3?15:7;s>1&&r<o;)a=a<<6|t[r++]&63,s--;if(s>1){h[n++]=65533;continue}a<65536?h[n++]=a:(a-=65536,h[n++]=55296|a>>10&1023,h[n++]=56320|a&1023)}return buf2binstring(h,n)},strings$2.utf8border=function(t,e){var r;for(e=e||t.length,e>t.length&&(e=t.length),r=e-1;r>=0&&(t[r]&192)===128;)r--;return r<0||r===0?e:r+_utf8len[t[r]]>e?r:e};function ZStream$2(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}var zstream=ZStream$2,zlib_deflate=deflate$3,utils$3=common,strings$1=strings$2,msg$1=messages,ZStream$1=zstream,toString$1=Object.prototype.toString,Z_NO_FLUSH=0,Z_FINISH$1=4,Z_OK$1=0,Z_STREAM_END$1=1,Z_SYNC_FLUSH=2,Z_DEFAULT_COMPRESSION=-1,Z_DEFAULT_STRATEGY=0,Z_DEFLATED$1=8;function Deflate(t){if(!(this instanceof Deflate))return new Deflate(t);this.options=utils$3.assign({level:Z_DEFAULT_COMPRESSION,method:Z_DEFLATED$1,chunkSize:16384,windowBits:15,memLevel:8,strategy:Z_DEFAULT_STRATEGY,to:""},t||{});var e=this.options;e.raw&&e.windowBits>0?e.windowBits=-e.windowBits:e.gzip&&e.windowBits>0&&e.windowBits<16&&(e.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new ZStream$1,this.strm.avail_out=0;var r=zlib_deflate.deflateInit2(this.strm,e.level,e.method,e.windowBits,e.memLevel,e.strategy);if(r!==Z_OK$1)throw new Error(msg$1[r]);if(e.header&&zlib_deflate.deflateSetHeader(this.strm,e.header),e.dictionary){var n;if(typeof e.dictionary=="string"?n=strings$1.string2buf(e.dictionary):toString$1.call(e.dictionary)==="[object ArrayBuffer]"?n=new Uint8Array(e.dictionary):n=e.dictionary,r=zlib_deflate.deflateSetDictionary(this.strm,n),r!==Z_OK$1)throw new Error(msg$1[r]);this._dict_set=!0}}Deflate.prototype.push=function(t,e){var r=this.strm,n=this.options.chunkSize,a,s;if(this.ended)return!1;s=e===~~e?e:e===!0?Z_FINISH$1:Z_NO_FLUSH,typeof t=="string"?r.input=strings$1.string2buf(t):toString$1.call(t)==="[object ArrayBuffer]"?r.input=new Uint8Array(t):r.input=t,r.next_in=0,r.avail_in=r.input.length;do{if(r.avail_out===0&&(r.output=new utils$3.Buf8(n),r.next_out=0,r.avail_out=n),a=zlib_deflate.deflate(r,s),a!==Z_STREAM_END$1&&a!==Z_OK$1)return this.onEnd(a),this.ended=!0,!1;(r.avail_out===0||r.avail_in===0&&(s===Z_FINISH$1||s===Z_SYNC_FLUSH))&&(this.options.to==="string"?this.onData(strings$1.buf2binstring(utils$3.shrinkBuf(r.output,r.next_out))):this.onData(utils$3.shrinkBuf(r.output,r.next_out)))}while((r.avail_in>0||r.avail_out===0)&&a!==Z_STREAM_END$1);return s===Z_FINISH$1?(a=zlib_deflate.deflateEnd(this.strm),this.onEnd(a),this.ended=!0,a===Z_OK$1):(s===Z_SYNC_FLUSH&&(this.onEnd(Z_OK$1),r.avail_out=0),!0)},Deflate.prototype.onData=function(t){this.chunks.push(t)},Deflate.prototype.onEnd=function(t){t===Z_OK$1&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=utils$3.flattenChunks(this.chunks)),this.chunks=[],this.err=t,this.msg=this.strm.msg};function deflate$1(t,e){var r=new Deflate(e);if(r.push(t,!0),r.err)throw r.msg||msg$1[r.err];return r.result}function deflateRaw(t,e){return e=e||{},e.raw=!0,deflate$1(t,e)}function gzip(t,e){return e=e||{},e.gzip=!0,deflate$1(t,e)}deflate$4.Deflate=Deflate,deflate$4.deflate=deflate$1,deflate$4.deflateRaw=deflateRaw,deflate$4.gzip=gzip;var inflate$4={},inflate$3={},BAD$1=30,TYPE$1=12,inffast=function t(e,r){var n,a,s,o,h,d,l,u,p,g,f,v,y,x,m,w,R,_,S,F,A,D,T,M,C;n=e.state,a=e.next_in,M=e.input,s=a+(e.avail_in-5),o=e.next_out,C=e.output,h=o-(r-e.avail_out),d=o+(e.avail_out-257),l=n.dmax,u=n.wsize,p=n.whave,g=n.wnext,f=n.window,v=n.hold,y=n.bits,x=n.lencode,m=n.distcode,w=(1<<n.lenbits)-1,R=(1<<n.distbits)-1;e:do{y<15&&(v+=M[a++]<<y,y+=8,v+=M[a++]<<y,y+=8),_=x[v&w];t:for(;;){if(S=_>>>24,v>>>=S,y-=S,S=_>>>16&255,S===0)C[o++]=_&65535;else if(S&16){F=_&65535,S&=15,S&&(y<S&&(v+=M[a++]<<y,y+=8),F+=v&(1<<S)-1,v>>>=S,y-=S),y<15&&(v+=M[a++]<<y,y+=8,v+=M[a++]<<y,y+=8),_=m[v&R];r:for(;;){if(S=_>>>24,v>>>=S,y-=S,S=_>>>16&255,S&16){if(A=_&65535,S&=15,y<S&&(v+=M[a++]<<y,y+=8,y<S&&(v+=M[a++]<<y,y+=8)),A+=v&(1<<S)-1,A>l){e.msg="invalid distance too far back",n.mode=BAD$1;break e}if(v>>>=S,y-=S,S=o-h,A>S){if(S=A-S,S>p&&n.sane){e.msg="invalid distance too far back",n.mode=BAD$1;break e}if(D=0,T=f,g===0){if(D+=u-S,S<F){F-=S;do C[o++]=f[D++];while(--S);D=o-A,T=C}}else if(g<S){if(D+=u+g-S,S-=g,S<F){F-=S;do C[o++]=f[D++];while(--S);if(D=0,g<F){S=g,F-=S;do C[o++]=f[D++];while(--S);D=o-A,T=C}}}else if(D+=g-S,S<F){F-=S;do C[o++]=f[D++];while(--S);D=o-A,T=C}for(;F>2;)C[o++]=T[D++],C[o++]=T[D++],C[o++]=T[D++],F-=3;F&&(C[o++]=T[D++],F>1&&(C[o++]=T[D++]))}else{D=o-A;do C[o++]=C[D++],C[o++]=C[D++],C[o++]=C[D++],F-=3;while(F>2);F&&(C[o++]=C[D++],F>1&&(C[o++]=C[D++]))}}else if(S&64){e.msg="invalid distance code",n.mode=BAD$1;break e}else{_=m[(_&65535)+(v&(1<<S)-1)];continue r}break}}else if(S&64)if(S&32){n.mode=TYPE$1;break e}else{e.msg="invalid literal/length code",n.mode=BAD$1;break e}else{_=x[(_&65535)+(v&(1<<S)-1)];continue t}break}}while(a<s&&o<d);F=y>>3,a-=F,y-=F<<3,v&=(1<<y)-1,e.next_in=a,e.next_out=o,e.avail_in=a<s?5+(s-a):5-(a-s),e.avail_out=o<d?257+(d-o):257-(o-d),n.hold=v,n.bits=y},utils$2=common,MAXBITS=15,ENOUGH_LENS$1=852,ENOUGH_DISTS$1=592,CODES$1=0,LENS$1=1,DISTS$1=2,lbase=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],lext=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],dbase=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],dext=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64],inftrees=function t(e,r,n,a,s,o,h,d){var l=d.bits,u=0,p=0,g=0,f=0,v=0,y=0,x=0,m=0,w=0,R=0,_,S,F,A,D,T=null,M=0,C,k=new utils$2.Buf16(MAXBITS+1),O=new utils$2.Buf16(MAXBITS+1),$=null,K=0,J,Y,se;for(u=0;u<=MAXBITS;u++)k[u]=0;for(p=0;p<a;p++)k[r[n+p]]++;for(v=l,f=MAXBITS;f>=1&&k[f]===0;f--);if(v>f&&(v=f),f===0)return s[o++]=1<<24|64<<16|0,s[o++]=1<<24|64<<16|0,d.bits=1,0;for(g=1;g<f&&k[g]===0;g++);for(v<g&&(v=g),m=1,u=1;u<=MAXBITS;u++)if(m<<=1,m-=k[u],m<0)return-1;if(m>0&&(e===CODES$1||f!==1))return-1;for(O[1]=0,u=1;u<MAXBITS;u++)O[u+1]=O[u]+k[u];for(p=0;p<a;p++)r[n+p]!==0&&(h[O[r[n+p]]++]=p);if(e===CODES$1?(T=$=h,C=19):e===LENS$1?(T=lbase,M-=257,$=lext,K-=257,C=256):(T=dbase,$=dext,C=-1),R=0,p=0,u=g,D=o,y=v,x=0,F=-1,w=1<<v,A=w-1,e===LENS$1&&w>ENOUGH_LENS$1||e===DISTS$1&&w>ENOUGH_DISTS$1)return 1;for(;;){J=u-x,h[p]<C?(Y=0,se=h[p]):h[p]>C?(Y=$[K+h[p]],se=T[M+h[p]]):(Y=96,se=0),_=1<<u-x,S=1<<y,g=S;do S-=_,s[D+(R>>x)+S]=J<<24|Y<<16|se|0;while(S!==0);for(_=1<<u-1;R&_;)_>>=1;if(_!==0?(R&=_-1,R+=_):R=0,p++,--k[u]===0){if(u===f)break;u=r[n+h[p]]}if(u>v&&(R&A)!==F){for(x===0&&(x=v),D+=g,y=u-x,m=1<<y;y+x<f&&(m-=k[y+x],!(m<=0));)y++,m<<=1;if(w+=1<<y,e===LENS$1&&w>ENOUGH_LENS$1||e===DISTS$1&&w>ENOUGH_DISTS$1)return 1;F=R&A,s[F]=v<<24|y<<16|D-o|0}}return R!==0&&(s[D+R]=u-x<<24|64<<16|0),d.bits=v,0},utils$1=common,adler32=adler32_1,crc32=crc32_1,inflate_fast=inffast,inflate_table=inftrees,CODES=0,LENS=1,DISTS=2,Z_FINISH=4,Z_BLOCK=5,Z_TREES=6,Z_OK=0,Z_STREAM_END=1,Z_NEED_DICT=2,Z_STREAM_ERROR=-2,Z_DATA_ERROR=-3,Z_MEM_ERROR=-4,Z_BUF_ERROR=-5,Z_DEFLATED=8,HEAD=1,FLAGS=2,TIME=3,OS=4,EXLEN=5,EXTRA=6,NAME=7,COMMENT=8,HCRC=9,DICTID=10,DICT=11,TYPE=12,TYPEDO=13,STORED=14,COPY_=15,COPY=16,TABLE=17,LENLENS=18,CODELENS=19,LEN_=20,LEN=21,LENEXT=22,DIST=23,DISTEXT=24,MATCH=25,LIT=26,CHECK=27,LENGTH=28,DONE=29,BAD=30,MEM=31,SYNC=32,ENOUGH_LENS=852,ENOUGH_DISTS=592,MAX_WBITS=15,DEF_WBITS=MAX_WBITS;function zswap32(t){return(t>>>24&255)+(t>>>8&65280)+((t&65280)<<8)+((t&255)<<24)}function InflateState(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new utils$1.Buf16(320),this.work=new utils$1.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function inflateResetKeep(t){var e;return!t||!t.state?Z_STREAM_ERROR:(e=t.state,t.total_in=t.total_out=e.total=0,t.msg="",e.wrap&&(t.adler=e.wrap&1),e.mode=HEAD,e.last=0,e.havedict=0,e.dmax=32768,e.head=null,e.hold=0,e.bits=0,e.lencode=e.lendyn=new utils$1.Buf32(ENOUGH_LENS),e.distcode=e.distdyn=new utils$1.Buf32(ENOUGH_DISTS),e.sane=1,e.back=-1,Z_OK)}function inflateReset(t){var e;return!t||!t.state?Z_STREAM_ERROR:(e=t.state,e.wsize=0,e.whave=0,e.wnext=0,inflateResetKeep(t))}function inflateReset2(t,e){var r,n;return!t||!t.state||(n=t.state,e<0?(r=0,e=-e):(r=(e>>4)+1,e<48&&(e&=15)),e&&(e<8||e>15))?Z_STREAM_ERROR:(n.window!==null&&n.wbits!==e&&(n.window=null),n.wrap=r,n.wbits=e,inflateReset(t))}function inflateInit2(t,e){var r,n;return t?(n=new InflateState,t.state=n,n.window=null,r=inflateReset2(t,e),r!==Z_OK&&(t.state=null),r):Z_STREAM_ERROR}function inflateInit(t){return inflateInit2(t,DEF_WBITS)}var virgin=!0,lenfix,distfix;function fixedtables(t){if(virgin){var e;for(lenfix=new utils$1.Buf32(512),distfix=new utils$1.Buf32(32),e=0;e<144;)t.lens[e++]=8;for(;e<256;)t.lens[e++]=9;for(;e<280;)t.lens[e++]=7;for(;e<288;)t.lens[e++]=8;for(inflate_table(LENS,t.lens,0,288,lenfix,0,t.work,{bits:9}),e=0;e<32;)t.lens[e++]=5;inflate_table(DISTS,t.lens,0,32,distfix,0,t.work,{bits:5}),virgin=!1}t.lencode=lenfix,t.lenbits=9,t.distcode=distfix,t.distbits=5}function updatewindow(t,e,r,n){var a,s=t.state;return s.window===null&&(s.wsize=1<<s.wbits,s.wnext=0,s.whave=0,s.window=new utils$1.Buf8(s.wsize)),n>=s.wsize?(utils$1.arraySet(s.window,e,r-s.wsize,s.wsize,0),s.wnext=0,s.whave=s.wsize):(a=s.wsize-s.wnext,a>n&&(a=n),utils$1.arraySet(s.window,e,r-n,a,s.wnext),n-=a,n?(utils$1.arraySet(s.window,e,r-n,n,0),s.wnext=n,s.whave=s.wsize):(s.wnext+=a,s.wnext===s.wsize&&(s.wnext=0),s.whave<s.wsize&&(s.whave+=a))),0}function inflate$2(t,e){var r,n,a,s,o,h,d,l,u,p,g,f,v,y,x=0,m,w,R,_,S,F,A,D,T=new utils$1.Buf8(4),M,C,k=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!t||!t.state||!t.output||!t.input&&t.avail_in!==0)return Z_STREAM_ERROR;r=t.state,r.mode===TYPE&&(r.mode=TYPEDO),o=t.next_out,a=t.output,d=t.avail_out,s=t.next_in,n=t.input,h=t.avail_in,l=r.hold,u=r.bits,p=h,g=d,D=Z_OK;e:for(;;)switch(r.mode){case HEAD:if(r.wrap===0){r.mode=TYPEDO;break}for(;u<16;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(r.wrap&2&&l===35615){r.check=0,T[0]=l&255,T[1]=l>>>8&255,r.check=crc32(r.check,T,2,0),l=0,u=0,r.mode=FLAGS;break}if(r.flags=0,r.head&&(r.head.done=!1),!(r.wrap&1)||(((l&255)<<8)+(l>>8))%31){t.msg="incorrect header check",r.mode=BAD;break}if((l&15)!==Z_DEFLATED){t.msg="unknown compression method",r.mode=BAD;break}if(l>>>=4,u-=4,A=(l&15)+8,r.wbits===0)r.wbits=A;else if(A>r.wbits){t.msg="invalid window size",r.mode=BAD;break}r.dmax=1<<A,t.adler=r.check=1,r.mode=l&512?DICTID:TYPE,l=0,u=0;break;case FLAGS:for(;u<16;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(r.flags=l,(r.flags&255)!==Z_DEFLATED){t.msg="unknown compression method",r.mode=BAD;break}if(r.flags&57344){t.msg="unknown header flags set",r.mode=BAD;break}r.head&&(r.head.text=l>>8&1),r.flags&512&&(T[0]=l&255,T[1]=l>>>8&255,r.check=crc32(r.check,T,2,0)),l=0,u=0,r.mode=TIME;case TIME:for(;u<32;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.head&&(r.head.time=l),r.flags&512&&(T[0]=l&255,T[1]=l>>>8&255,T[2]=l>>>16&255,T[3]=l>>>24&255,r.check=crc32(r.check,T,4,0)),l=0,u=0,r.mode=OS;case OS:for(;u<16;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.head&&(r.head.xflags=l&255,r.head.os=l>>8),r.flags&512&&(T[0]=l&255,T[1]=l>>>8&255,r.check=crc32(r.check,T,2,0)),l=0,u=0,r.mode=EXLEN;case EXLEN:if(r.flags&1024){for(;u<16;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.length=l,r.head&&(r.head.extra_len=l),r.flags&512&&(T[0]=l&255,T[1]=l>>>8&255,r.check=crc32(r.check,T,2,0)),l=0,u=0}else r.head&&(r.head.extra=null);r.mode=EXTRA;case EXTRA:if(r.flags&1024&&(f=r.length,f>h&&(f=h),f&&(r.head&&(A=r.head.extra_len-r.length,r.head.extra||(r.head.extra=new Array(r.head.extra_len)),utils$1.arraySet(r.head.extra,n,s,f,A)),r.flags&512&&(r.check=crc32(r.check,n,f,s)),h-=f,s+=f,r.length-=f),r.length))break e;r.length=0,r.mode=NAME;case NAME:if(r.flags&2048){if(h===0)break e;f=0;do A=n[s+f++],r.head&&A&&r.length<65536&&(r.head.name+=String.fromCharCode(A));while(A&&f<h);if(r.flags&512&&(r.check=crc32(r.check,n,f,s)),h-=f,s+=f,A)break e}else r.head&&(r.head.name=null);r.length=0,r.mode=COMMENT;case COMMENT:if(r.flags&4096){if(h===0)break e;f=0;do A=n[s+f++],r.head&&A&&r.length<65536&&(r.head.comment+=String.fromCharCode(A));while(A&&f<h);if(r.flags&512&&(r.check=crc32(r.check,n,f,s)),h-=f,s+=f,A)break e}else r.head&&(r.head.comment=null);r.mode=HCRC;case HCRC:if(r.flags&512){for(;u<16;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(l!==(r.check&65535)){t.msg="header crc mismatch",r.mode=BAD;break}l=0,u=0}r.head&&(r.head.hcrc=r.flags>>9&1,r.head.done=!0),t.adler=r.check=0,r.mode=TYPE;break;case DICTID:for(;u<32;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}t.adler=r.check=zswap32(l),l=0,u=0,r.mode=DICT;case DICT:if(r.havedict===0)return t.next_out=o,t.avail_out=d,t.next_in=s,t.avail_in=h,r.hold=l,r.bits=u,Z_NEED_DICT;t.adler=r.check=1,r.mode=TYPE;case TYPE:if(e===Z_BLOCK||e===Z_TREES)break e;case TYPEDO:if(r.last){l>>>=u&7,u-=u&7,r.mode=CHECK;break}for(;u<3;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}switch(r.last=l&1,l>>>=1,u-=1,l&3){case 0:r.mode=STORED;break;case 1:if(fixedtables(r),r.mode=LEN_,e===Z_TREES){l>>>=2,u-=2;break e}break;case 2:r.mode=TABLE;break;case 3:t.msg="invalid block type",r.mode=BAD}l>>>=2,u-=2;break;case STORED:for(l>>>=u&7,u-=u&7;u<32;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if((l&65535)!==(l>>>16^65535)){t.msg="invalid stored block lengths",r.mode=BAD;break}if(r.length=l&65535,l=0,u=0,r.mode=COPY_,e===Z_TREES)break e;case COPY_:r.mode=COPY;case COPY:if(f=r.length,f){if(f>h&&(f=h),f>d&&(f=d),f===0)break e;utils$1.arraySet(a,n,s,f,o),h-=f,s+=f,d-=f,o+=f,r.length-=f;break}r.mode=TYPE;break;case TABLE:for(;u<14;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(r.nlen=(l&31)+257,l>>>=5,u-=5,r.ndist=(l&31)+1,l>>>=5,u-=5,r.ncode=(l&15)+4,l>>>=4,u-=4,r.nlen>286||r.ndist>30){t.msg="too many length or distance symbols",r.mode=BAD;break}r.have=0,r.mode=LENLENS;case LENLENS:for(;r.have<r.ncode;){for(;u<3;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.lens[k[r.have++]]=l&7,l>>>=3,u-=3}for(;r.have<19;)r.lens[k[r.have++]]=0;if(r.lencode=r.lendyn,r.lenbits=7,M={bits:r.lenbits},D=inflate_table(CODES,r.lens,0,19,r.lencode,0,r.work,M),r.lenbits=M.bits,D){t.msg="invalid code lengths set",r.mode=BAD;break}r.have=0,r.mode=CODELENS;case CODELENS:for(;r.have<r.nlen+r.ndist;){for(;x=r.lencode[l&(1<<r.lenbits)-1],m=x>>>24,w=x>>>16&255,R=x&65535,!(m<=u);){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(R<16)l>>>=m,u-=m,r.lens[r.have++]=R;else{if(R===16){for(C=m+2;u<C;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(l>>>=m,u-=m,r.have===0){t.msg="invalid bit length repeat",r.mode=BAD;break}A=r.lens[r.have-1],f=3+(l&3),l>>>=2,u-=2}else if(R===17){for(C=m+3;u<C;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}l>>>=m,u-=m,A=0,f=3+(l&7),l>>>=3,u-=3}else{for(C=m+7;u<C;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}l>>>=m,u-=m,A=0,f=11+(l&127),l>>>=7,u-=7}if(r.have+f>r.nlen+r.ndist){t.msg="invalid bit length repeat",r.mode=BAD;break}for(;f--;)r.lens[r.have++]=A}}if(r.mode===BAD)break;if(r.lens[256]===0){t.msg="invalid code -- missing end-of-block",r.mode=BAD;break}if(r.lenbits=9,M={bits:r.lenbits},D=inflate_table(LENS,r.lens,0,r.nlen,r.lencode,0,r.work,M),r.lenbits=M.bits,D){t.msg="invalid literal/lengths set",r.mode=BAD;break}if(r.distbits=6,r.distcode=r.distdyn,M={bits:r.distbits},D=inflate_table(DISTS,r.lens,r.nlen,r.ndist,r.distcode,0,r.work,M),r.distbits=M.bits,D){t.msg="invalid distances set",r.mode=BAD;break}if(r.mode=LEN_,e===Z_TREES)break e;case LEN_:r.mode=LEN;case LEN:if(h>=6&&d>=258){t.next_out=o,t.avail_out=d,t.next_in=s,t.avail_in=h,r.hold=l,r.bits=u,inflate_fast(t,g),o=t.next_out,a=t.output,d=t.avail_out,s=t.next_in,n=t.input,h=t.avail_in,l=r.hold,u=r.bits,r.mode===TYPE&&(r.back=-1);break}for(r.back=0;x=r.lencode[l&(1<<r.lenbits)-1],m=x>>>24,w=x>>>16&255,R=x&65535,!(m<=u);){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(w&&!(w&240)){for(_=m,S=w,F=R;x=r.lencode[F+((l&(1<<_+S)-1)>>_)],m=x>>>24,w=x>>>16&255,R=x&65535,!(_+m<=u);){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}l>>>=_,u-=_,r.back+=_}if(l>>>=m,u-=m,r.back+=m,r.length=R,w===0){r.mode=LIT;break}if(w&32){r.back=-1,r.mode=TYPE;break}if(w&64){t.msg="invalid literal/length code",r.mode=BAD;break}r.extra=w&15,r.mode=LENEXT;case LENEXT:if(r.extra){for(C=r.extra;u<C;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.length+=l&(1<<r.extra)-1,l>>>=r.extra,u-=r.extra,r.back+=r.extra}r.was=r.length,r.mode=DIST;case DIST:for(;x=r.distcode[l&(1<<r.distbits)-1],m=x>>>24,w=x>>>16&255,R=x&65535,!(m<=u);){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(!(w&240)){for(_=m,S=w,F=R;x=r.distcode[F+((l&(1<<_+S)-1)>>_)],m=x>>>24,w=x>>>16&255,R=x&65535,!(_+m<=u);){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}l>>>=_,u-=_,r.back+=_}if(l>>>=m,u-=m,r.back+=m,w&64){t.msg="invalid distance code",r.mode=BAD;break}r.offset=R,r.extra=w&15,r.mode=DISTEXT;case DISTEXT:if(r.extra){for(C=r.extra;u<C;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.offset+=l&(1<<r.extra)-1,l>>>=r.extra,u-=r.extra,r.back+=r.extra}if(r.offset>r.dmax){t.msg="invalid distance too far back",r.mode=BAD;break}r.mode=MATCH;case MATCH:if(d===0)break e;if(f=g-d,r.offset>f){if(f=r.offset-f,f>r.whave&&r.sane){t.msg="invalid distance too far back",r.mode=BAD;break}f>r.wnext?(f-=r.wnext,v=r.wsize-f):v=r.wnext-f,f>r.length&&(f=r.length),y=r.window}else y=a,v=o-r.offset,f=r.length;f>d&&(f=d),d-=f,r.length-=f;do a[o++]=y[v++];while(--f);r.length===0&&(r.mode=LEN);break;case LIT:if(d===0)break e;a[o++]=r.length,d--,r.mode=LEN;break;case CHECK:if(r.wrap){for(;u<32;){if(h===0)break e;h--,l|=n[s++]<<u,u+=8}if(g-=d,t.total_out+=g,r.total+=g,g&&(t.adler=r.check=r.flags?crc32(r.check,a,g,o-g):adler32(r.check,a,g,o-g)),g=d,(r.flags?l:zswap32(l))!==r.check){t.msg="incorrect data check",r.mode=BAD;break}l=0,u=0}r.mode=LENGTH;case LENGTH:if(r.wrap&&r.flags){for(;u<32;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(l!==(r.total&4294967295)){t.msg="incorrect length check",r.mode=BAD;break}l=0,u=0}r.mode=DONE;case DONE:D=Z_STREAM_END;break e;case BAD:D=Z_DATA_ERROR;break e;case MEM:return Z_MEM_ERROR;case SYNC:default:return Z_STREAM_ERROR}return t.next_out=o,t.avail_out=d,t.next_in=s,t.avail_in=h,r.hold=l,r.bits=u,(r.wsize||g!==t.avail_out&&r.mode<BAD&&(r.mode<CHECK||e!==Z_FINISH))&&updatewindow(t,t.output,t.next_out,g-t.avail_out),p-=t.avail_in,g-=t.avail_out,t.total_in+=p,t.total_out+=g,r.total+=g,r.wrap&&g&&(t.adler=r.check=r.flags?crc32(r.check,a,g,t.next_out-g):adler32(r.check,a,g,t.next_out-g)),t.data_type=r.bits+(r.last?64:0)+(r.mode===TYPE?128:0)+(r.mode===LEN_||r.mode===COPY_?256:0),(p===0&&g===0||e===Z_FINISH)&&D===Z_OK&&(D=Z_BUF_ERROR),D}function inflateEnd(t){if(!t||!t.state)return Z_STREAM_ERROR;var e=t.state;return e.window&&(e.window=null),t.state=null,Z_OK}function inflateGetHeader(t,e){var r;return!t||!t.state||(r=t.state,!(r.wrap&2))?Z_STREAM_ERROR:(r.head=e,e.done=!1,Z_OK)}function inflateSetDictionary(t,e){var r=e.length,n,a,s;return!t||!t.state||(n=t.state,n.wrap!==0&&n.mode!==DICT)?Z_STREAM_ERROR:n.mode===DICT&&(a=1,a=adler32(a,e,r,0),a!==n.check)?Z_DATA_ERROR:(s=updatewindow(t,e,r,r),s?(n.mode=MEM,Z_MEM_ERROR):(n.havedict=1,Z_OK))}inflate$3.inflateReset=inflateReset,inflate$3.inflateReset2=inflateReset2,inflate$3.inflateResetKeep=inflateResetKeep,inflate$3.inflateInit=inflateInit,inflate$3.inflateInit2=inflateInit2,inflate$3.inflate=inflate$2,inflate$3.inflateEnd=inflateEnd,inflate$3.inflateGetHeader=inflateGetHeader,inflate$3.inflateSetDictionary=inflateSetDictionary,inflate$3.inflateInfo="pako inflate (from Nodeca project)";var constants$1={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8};function GZheader$1(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}var gzheader=GZheader$1,zlib_inflate=inflate$3,utils=common,strings=strings$2,c=constants$1,msg=messages,ZStream=zstream,GZheader=gzheader,toString=Object.prototype.toString;function Inflate(t){if(!(this instanceof Inflate))return new Inflate(t);this.options=utils.assign({chunkSize:16384,windowBits:0,to:""},t||{});var e=this.options;e.raw&&e.windowBits>=0&&e.windowBits<16&&(e.windowBits=-e.windowBits,e.windowBits===0&&(e.windowBits=-15)),e.windowBits>=0&&e.windowBits<16&&!(t&&t.windowBits)&&(e.windowBits+=32),e.windowBits>15&&e.windowBits<48&&(e.windowBits&15||(e.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new ZStream,this.strm.avail_out=0;var r=zlib_inflate.inflateInit2(this.strm,e.windowBits);if(r!==c.Z_OK)throw new Error(msg[r]);if(this.header=new GZheader,zlib_inflate.inflateGetHeader(this.strm,this.header),e.dictionary&&(typeof e.dictionary=="string"?e.dictionary=strings.string2buf(e.dictionary):toString.call(e.dictionary)==="[object ArrayBuffer]"&&(e.dictionary=new Uint8Array(e.dictionary)),e.raw&&(r=zlib_inflate.inflateSetDictionary(this.strm,e.dictionary),r!==c.Z_OK)))throw new Error(msg[r])}Inflate.prototype.push=function(t,e){var r=this.strm,n=this.options.chunkSize,a=this.options.dictionary,s,o,h,d,l,u=!1;if(this.ended)return!1;o=e===~~e?e:e===!0?c.Z_FINISH:c.Z_NO_FLUSH,typeof t=="string"?r.input=strings.binstring2buf(t):toString.call(t)==="[object ArrayBuffer]"?r.input=new Uint8Array(t):r.input=t,r.next_in=0,r.avail_in=r.input.length;do{if(r.avail_out===0&&(r.output=new utils.Buf8(n),r.next_out=0,r.avail_out=n),s=zlib_inflate.inflate(r,c.Z_NO_FLUSH),s===c.Z_NEED_DICT&&a&&(s=zlib_inflate.inflateSetDictionary(this.strm,a)),s===c.Z_BUF_ERROR&&u===!0&&(s=c.Z_OK,u=!1),s!==c.Z_STREAM_END&&s!==c.Z_OK)return this.onEnd(s),this.ended=!0,!1;r.next_out&&(r.avail_out===0||s===c.Z_STREAM_END||r.avail_in===0&&(o===c.Z_FINISH||o===c.Z_SYNC_FLUSH))&&(this.options.to==="string"?(h=strings.utf8border(r.output,r.next_out),d=r.next_out-h,l=strings.buf2string(r.output,h),r.next_out=d,r.avail_out=n-d,d&&utils.arraySet(r.output,r.output,h,d,0),this.onData(l)):this.onData(utils.shrinkBuf(r.output,r.next_out))),r.avail_in===0&&r.avail_out===0&&(u=!0)}while((r.avail_in>0||r.avail_out===0)&&s!==c.Z_STREAM_END);return s===c.Z_STREAM_END&&(o=c.Z_FINISH),o===c.Z_FINISH?(s=zlib_inflate.inflateEnd(this.strm),this.onEnd(s),this.ended=!0,s===c.Z_OK):(o===c.Z_SYNC_FLUSH&&(this.onEnd(c.Z_OK),r.avail_out=0),!0)},Inflate.prototype.onData=function(t){this.chunks.push(t)},Inflate.prototype.onEnd=function(t){t===c.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=utils.flattenChunks(this.chunks)),this.chunks=[],this.err=t,this.msg=this.strm.msg};function inflate$1(t,e){var r=new Inflate(e);if(r.push(t,!0),r.err)throw r.msg||msg[r.err];return r.result}function inflateRaw(t,e){return e=e||{},e.raw=!0,inflate$1(t,e)}inflate$4.Inflate=Inflate,inflate$4.inflate=inflate$1,inflate$4.inflateRaw=inflateRaw,inflate$4.ungzip=inflate$1;var assign=common.assign,deflate=deflate$4,inflate=inflate$4,constants=constants$1,pako$1={};assign(pako$1,deflate,inflate,constants);var pako_1=pako$1;const pako=getDefaultExportFromCjs(pako_1);for(var chars="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",lookup=new Uint8Array(256),i=0;i<chars.length;i++)lookup[chars.charCodeAt(i)]=i;var decodeFromBase64=function(t){var e=t.length*.75,r=t.length,n,a=0,s,o,h,d;t[t.length-1]==="="&&(e--,t[t.length-2]==="="&&e--);var l=new Uint8Array(e);for(n=0;n<r;n+=4)s=lookup[t.charCodeAt(n)],o=lookup[t.charCodeAt(n+1)],h=lookup[t.charCodeAt(n+2)],d=lookup[t.charCodeAt(n+3)],l[a++]=s<<2|o>>4,l[a++]=(o&15)<<4|h>>2,l[a++]=(h&3)<<6|d&63;return l},arrayToString=function(t){for(var e="",r=0;r<t.length;r++)e+=String.fromCharCode(t[r]);return e},decompressJson=function(t){return arrayToString(pako.inflate(decodeFromBase64(t)))},padStart=function(t,e,r){for(var n="",a=0,s=e-t.length;a<s;a++)n+=r;return n+t};const CourierBoldCompressed="eJyFWdtyGjkQ/RVqnnar8Bb4lpg3jEnCxgEvGDtxKg9iphm01oyILrZxKv++mrGd3az6KC8UnNa0+nrUGr5lI11VVLtskF198FaU1Dns9w9OOkf7/ePDrJu90bWbiorCgpH2RpLZO9WqaCReqZ8lnReJqKTa/SwL8DXJctPs9Lxs4oSS+bAuVVjXC7/tG/lAxYV0+SYbOOOpm402wojckVlQ8+T4wVFdUDHXlaifrTs91Q/Z4PNeMLu7t3/U6746POm+7vW/dLNlWGuUrOlCW+mkrrPBXr/X+4/gciPz25qszQbhyeyKjG2XZb3ewR+9Xi/sMdVO5k+ebHemcaHzW/57p3/y+qQbPk967We//TxoP191hoVeUWexs44q25nUuTZbbYSj4o9OZ6hUZ97osZ05WTJ3AQ37jMOqQtblIt9QG7lWycKJuhCmeJGGhSOxffccyqPj/W728eXX4cFJNxvavAmRyQbH++HnGf34vdc/etXNFq54d50NXh+2X6/C137v+CnQH8gZmYdQfP6WXX8MCppQTYMlditCBL53/wfTQ65EFeNfvQ6erlQsqX21akJc1rGs0EoJE+NbMnlToZFAVEFkQ3iABW2uGH3CUK1ojUTgMWEbjfaWeUp5G6N5aCwRw5vddkOM98EVqRlPrBJ2E8OPZHSM6prJkrtnVrqNIWbtOjQrg8o7Zq2VDwxId5x3xMe0lpzBuVaa0WGpkkCkmgaON/3qBVODpaHQiIybXz3ZliTi3DO2D2PoNIZGMXQWQ+MYehNDb2PoXQxNYujPGHofQ+cx9CGGpjE0i6GLGPorhuYxtIihyxhaxtBVDF3H0McY+hRDNzG0CqfQLTmeNlZBBvr0+TnIKbmUuTS5Z1jUN6xtw8nBtEjLb7wxDOesmB5j+JfpIIYLmIZiWC6GZAz9HUMMvTItzESL6VqG9rZMKGOI4QaGXpjY+xi6i6H7GGKYdMeQPl9foBBW3GHark9Vo5OqgEd9oe+ZOPOnc3NcqmZgiUuomehYnt1xZ8daaSPZ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Cuwil4m5CiRMEUMVSzVLDUstSx1Juc0oVWMpqY295qVltmtWmWW2a1aZZbZrVplltmtWmWW2G1WZYbYbVZlhthtVmWG2G1WZYbYbVZlhtltVmWW2W1WZZbZbVZlltltVmWW2W1QYjQCh7E2aAQHeGhCFgPoNoy8KNb2wxBhmGKBxoUZXlLGsLI6AsftEDHV0wIURVbANLcTKlGGBIKPOAxCmhePCKUwFzAmpDFRQvjA9R06Hq8TONvshgKDCuRAZTXigUxjxNFfKRo3CLhnIJBMFRvMZpqpNBMlQJzGT5WFQMVQI/AikPMIhEU1aDjqJvQwmjSHB05cC9jbYwc5UtAHNLhDw41ha+lEqF4JaH3gmB61SYcqInxTDmQK8v08vjqv4zDf1N0w3Lf4A8/vwPpfK11w==";var compressedJsonForFontName={Courier:CourierCompressed,"Courier-Bold":CourierBoldCompressed,"Courier-Oblique":CourierObliqueCompressed,"Courier-BoldOblique":CourierBoldObliqueCompressed,Helvetica:HelveticaCompressed,"Helvetica-Bold":HelveticaBoldCompressed,"Helvetica-Oblique":HelveticaObliqueCompressed,"Helvetica-BoldOblique":HelveticaBoldObliqueCompressed,"Times-Roman":TimesRomanCompressed,"Times-Bold":TimesBoldCompressed,"Times-Italic":TimesItalicCompressed,"Times-BoldItalic":TimesBoldItalicCompressed,Symbol:SymbolCompressed,ZapfDingbats:ZapfDingbatsCompressed},FontNames;(function(t){t.Courier="Courier",t.CourierBold="Courier-Bold",t.CourierOblique="Courier-Oblique",t.CourierBoldOblique="Courier-BoldOblique",t.Helvetica="Helvetica",t.HelveticaBold="Helvetica-Bold",t.HelveticaOblique="Helvetica-Oblique",t.HelveticaBoldOblique="Helvetica-BoldOblique",t.TimesRoman="Times-Roman",t.TimesRomanBold="Times-Bold",t.TimesRomanItalic="Times-Italic",t.TimesRomanBoldItalic="Times-BoldItalic",t.Symbol="Symbol",t.ZapfDingbats="ZapfDingbats"})(FontNames||(FontNames={}));var fontCache={},Font=function(){function t(){var e=this;this.getWidthOfGlyph=function(r){return e.CharWidths[r]},this.getXAxisKerningForPair=function(r,n){return(e.KernPairXAmounts[r]||{})[n]}}return t.load=function(e){var r=fontCache[e];if(r)return r;var n=decompressJson(compressedJsonForFontName[e]),a=Object.assign(new t,JSON.parse(n));return a.CharWidths=a.CharMetrics.reduce(function(s,o){return s[o.N]=o.WX,s},{}),a.KernPairXAmounts=a.KernPairs.reduce(function(s,o){var h=o[0],d=o[1],l=o[2];return s[h]||(s[h]={}),s[h][d]=l,s},{}),fontCache[e]=a,a},t}();const AllEncodingsCompressed="eJztWsuy48iN/Ret74KZfHtX47meqfGjPHaXx4/wgpJ4JbooUU1JVXXb0f9u4JwESF13R7TD29koIpFi8gCJBHDA/Pvm+nraTuPmZ3/f5HHzs7/k8WlzvXS7fvPXp02eqyR/2vRfd2N3gqhUUfm0Od9P236+DoczxLWK66fNpZ93/fkGWaOy5mnTnUR67c57lRaZSItM/tnN/XnsX/DfIqg0JOk8HI4UK4BCAFzG+xWCQgXF02Y3nU4dJJVKKrx5mPgKBVMImOvYXY+QKJRCoHzXzxMErQrap810hqaloioF1e0L5kvFUwqe23Hu+Q+1TinWeZnuMwSKrRRsL8Nn/kOxlYLtOnzFWE1Viqmu/eceVioVaylYe1OwVKilQD0PCYgiLRtVcJz4kEItW13mNLi0UsCVAB77KyxTKeJKEPff3rsREkVcCeLD3He3HqArBV0J6G/v/fU2cK1WH23l0e3c7T71N9uUVv/c5i73bWlVs1Y0u5/3srO7aQb2EPUB+eUTva0TYgG5mGbbzZSUkJTpn75ygF4PThhq1SMGMds4HYZdN54n/rdWc8rv02bfH9I2hbqGsKbPnIYzHSc0qmTIxI6nuwpiAIQmU8F4Gy7jK8RwntAI1v3wedj39FmFECp508s4zUOyGmwpKrwbL8eOIlVU//Yf/S1J9C212Pa/uuSwbVDYlWzxf/aj/UtfWgm258t1GG1X1BVawfdnX0xdoRbjPCdBVGs1svo3R/tPVD1r2YL3k0kUfC04f9ldLkmk0NVwv+pO232SKXa126/vHAO5wPxNGivsRsZ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rlhb4Ll0HSRfRNOLxqk5onB1LWu4kCPAGRmicIDOZ6j67Ro0T5V2/F6t1lDpTlkz6iMTpspj/JI53H83+jZNmt/+ybY2TZ1lRctmcUldonEDLxLEbGV5aZ9AwRnqAJmydSFu6c2dunU6/8yDIL5Og0+8W67VOp98xsL6kr1H8FglO/W45Uq1z6ncPXto6rX432zlpnVW/e6bAGfXPV0aOmXPqZwcbM+fUzw42Zs6pnx/BxsyJ9fMaV8ycW79fre3c+v1qbefW79+u7QT7/ePazrGf+UE7Zk6wf+Mmi8EJ9ocFQnCC/WGBEJxgf3gDgddNNIp/WC3Mb12i24cHXIEfkcs3FzGDM/UPnnJjcKb+cQXOmfrHFThn6h/fgItO1z8+4IjO2P+0LBOdsX9znHgBKUYn7Id+Pkklvh3TCgtpX9DFhbSvll1I+1t0C3NfTBcX5v4IeSHv5sYxX7g7H86dt+/Wbpw7c+8XsLkz934Bmztz79+AzZ2+9w+4cmfww2ptZ/DDam1n8MPbtZ3GDw9rs9ui3KZPblw4tz8vJiuc208LhMK5/bRAKJzbT28gFE7wp9XCTvCnR1zO8ZeLw7Fwjj8tTlw4x78v0Ern+PcFWukc//4GWulE//6AonSu/7paxrn+zZ2YnRclRK/rBXJsCAjxh2cKEAWVJ02ku/wOoFv2+12XkmnODwHgW4uQGVbZ0uM7mAJ1b/68/JlpUMnWdy5MF6/Vd5eL19YYSPd6FqPwBkNQo/h2NQxdQQ3bn/dpCxrGrqCW7U8rKZl/mfi0Xytk3Am66ZhYbg4y+KAVslDwbXdNL2d5qU5hnYBlTZaa6hs2t1qWdaeeTptcLco+hl5R7w4H5uOGcQbtEkpT18GusOI2xT9dYcVJf7zCSjmbD+Iud2s1NPRb9E+0UICmizb8ZK/+5JOLOulSqwaw5VJr2vB8dSFn89fvv/8H0oq1dA==";for(var decompressedEncodings=decompressJson(AllEncodingsCompressed),allUnicodeMappings=JSON.parse(decompressedEncodings),Encoding=function(){function t(e,r){var n=this;this.canEncodeUnicodeCodePoint=function(a){return a in n.unicodeMappings},this.encodeUnicodeCodePoint=function(a){var s=n.unicodeMappings[a];if(!s){var o=String.fromCharCode(a),h="0x"+padStart(a.toString(16),4,"0"),d=n.name+' cannot encode "'+o+'" ('+h+")";throw new Error(d)}return{code:s[0],name:s[1]}},this.name=e,this.supportedCodePoints=Object.keys(r).map(Number).sort(function(a,s){return a-s}),this.unicodeMappings=r}return t}(),Encodings={Symbol:new Encoding("Symbol",allUnicodeMappings.symbol),ZapfDingbats:new Encoding("ZapfDingbats",allUnicodeMappings.zapfdingbats),WinAnsi:new Encoding("WinAnsi",allUnicodeMappings.win1252)},values=function(t){return Object.keys(t).map(function(e){return t[e]})},StandardFontValues=values(FontNames),isStandardFont=function(t){return StandardFontValues.includes(t)},rectanglesAreEqual=function(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height},backtick=function(t){return"`"+t+"`"},singleQuote=function(t){return"'"+t+"'"},formatValue=function(t){var e=typeof t;return e==="string"?singleQuote(t):e==="undefined"?backtick(t):t},createValueErrorMsg=function(t,e,r){for(var n=new Array(r.length),a=0,s=r.length;a<s;a++){var o=r[a];n[a]=formatValue(o)}var h=n.join(" or ");return backtick(e)+" must be one of "+h+", but was actually "+formatValue(t)},assertIsOneOf=function(t,e,r){Array.isArray(r)||(r=values(r));for(var n=0,a=r.length;n<a;n++)if(t===r[n])return;throw new TypeError(createValueErrorMsg(t,e,r))},assertIsOneOfOrUndefined=function(t,e,r){Array.isArray(r)||(r=values(r)),assertIsOneOf(t,e,r.concat(void 0))},assertIsSubset=function(t,e,r){Array.isArray(r)||(r=values(r));for(var n=0,a=t.length;n<a;n++)assertIsOneOf(t[n],e,r)},getType=function(t){return t===null?"null":t===void 0?"undefined":typeof t=="string"?"string":isNaN(t)?"NaN":typeof t=="number"?"number":typeof t=="boolean"?"boolean":typeof t=="symbol"?"symbol":typeof t=="bigint"?"bigint":t.constructor&&t.constructor.name?t.constructor.name:t.name?t.name:t.constructor?String(t.constructor):String(t)},isType=function(t,e){return e==="null"?t===null:e==="undefined"?t===void 0:e==="string"?typeof t=="string":e==="number"?typeof t=="number"&&!isNaN(t):e==="boolean"?typeof t=="boolean":e==="symbol"?typeof t=="symbol":e==="bigint"?typeof t=="bigint":e===Date?t instanceof Date:e===Array?t instanceof Array:e===Uint8Array?t instanceof Uint8Array:e===ArrayBuffer?t instanceof ArrayBuffer:e===Function?t instanceof Function:t instanceof e[0]},createTypeErrorMsg=function(t,e,r){for(var n=new Array(r.length),a=0,s=r.length;a<s;a++){var o=r[a];o==="null"&&(n[a]=backtick("null")),o==="undefined"&&(n[a]=backtick("undefined")),o==="string"?n[a]=backtick("string"):o==="number"?n[a]=backtick("number"):o==="boolean"?n[a]=backtick("boolean"):o==="symbol"?n[a]=backtick("symbol"):o==="bigint"?n[a]=backtick("bigint"):o===Array?n[a]=backtick("Array"):o===Uint8Array?n[a]=backtick("Uint8Array"):o===ArrayBuffer?n[a]=backtick("ArrayBuffer"):n[a]=backtick(o[1])}var h=n.join(" or ");return backtick(e)+" must be of type "+h+", but was actually of type "+backtick(getType(t))},assertIs=function(t,e,r){for(var n=0,a=r.length;n<a;n++)if(isType(t,r[n]))return;throw new TypeError(createTypeErrorMsg(t,e,r))},assertOrUndefined=function(t,e,r){assertIs(t,e,r.concat("undefined"))},assertEachIs=function(t,e,r){for(var n=0,a=t.length;n<a;n++)assertIs(t[n],e,r)},assertRange=function(t,e,r,n){if(assertIs(t,e,["number"]),assertIs(r,"min",["number"]),assertIs(n,"max",["number"]),n=Math.max(r,n),t<r||t>n)throw new Error(backtick(e)+" must be at least "+r+" and at most "+n+", but was actually "+t)},assertRangeOrUndefined=function(t,e,r,n){assertIs(t,e,["number","undefined"]),typeof t=="number"&&assertRange(t,e,r,n)},assertMultiple=function(t,e,r){if(assertIs(t,e,["number"]),t%r!==0)throw new Error(backtick(e)+" must be a multiple of "+r+", but was actually "+t)},assertInteger=function(t,e){if(!Number.isInteger(t))throw new Error(backtick(e)+" must be an integer, but was actually "+t)},assertPositive=function(t,e){if(![1,0].includes(Math.sign(t)))throw new Error(backtick(e)+" must be a positive number or 0, but was actually "+t)},pdfDocEncodingToUnicode=new Uint16Array(256),idx$2=0;idx$2<256;idx$2++)pdfDocEncodingToUnicode[idx$2]=idx$2;pdfDocEncodingToUnicode[22]=toCharCode(""),pdfDocEncodingToUnicode[24]=toCharCode("˘"),pdfDocEncodingToUnicode[25]=toCharCode("ˇ"),pdfDocEncodingToUnicode[26]=toCharCode("ˆ"),pdfDocEncodingToUnicode[27]=toCharCode("˙"),pdfDocEncodingToUnicode[28]=toCharCode("˝"),pdfDocEncodingToUnicode[29]=toCharCode("˛"),pdfDocEncodingToUnicode[30]=toCharCode("˚"),pdfDocEncodingToUnicode[31]=toCharCode("˜"),pdfDocEncodingToUnicode[127]=toCharCode("�"),pdfDocEncodingToUnicode[128]=toCharCode("•"),pdfDocEncodingToUnicode[129]=toCharCode("†"),pdfDocEncodingToUnicode[130]=toCharCode("‡"),pdfDocEncodingToUnicode[131]=toCharCode("…"),pdfDocEncodingToUnicode[132]=toCharCode("—"),pdfDocEncodingToUnicode[133]=toCharCode("–"),pdfDocEncodingToUnicode[134]=toCharCode("ƒ"),pdfDocEncodingToUnicode[135]=toCharCode("⁄"),pdfDocEncodingToUnicode[136]=toCharCode("‹"),pdfDocEncodingToUnicode[137]=toCharCode("›"),pdfDocEncodingToUnicode[138]=toCharCode("−"),pdfDocEncodingToUnicode[139]=toCharCode("‰"),pdfDocEncodingToUnicode[140]=toCharCode("„"),pdfDocEncodingToUnicode[141]=toCharCode("“"),pdfDocEncodingToUnicode[142]=toCharCode("”"),pdfDocEncodingToUnicode[143]=toCharCode("‘"),pdfDocEncodingToUnicode[144]=toCharCode("’"),pdfDocEncodingToUnicode[145]=toCharCode("‚"),pdfDocEncodingToUnicode[146]=toCharCode("™"),pdfDocEncodingToUnicode[147]=toCharCode("fi"),pdfDocEncodingToUnicode[148]=toCharCode("fl"),pdfDocEncodingToUnicode[149]=toCharCode("Ł"),pdfDocEncodingToUnicode[150]=toCharCode("Œ"),pdfDocEncodingToUnicode[151]=toCharCode("Š"),pdfDocEncodingToUnicode[152]=toCharCode("Ÿ"),pdfDocEncodingToUnicode[153]=toCharCode("Ž"),pdfDocEncodingToUnicode[154]=toCharCode("ı"),pdfDocEncodingToUnicode[155]=toCharCode("ł"),pdfDocEncodingToUnicode[156]=toCharCode("œ"),pdfDocEncodingToUnicode[157]=toCharCode("š"),pdfDocEncodingToUnicode[158]=toCharCode("ž"),pdfDocEncodingToUnicode[159]=toCharCode("�"),pdfDocEncodingToUnicode[160]=toCharCode("€"),pdfDocEncodingToUnicode[173]=toCharCode("�");var pdfDocEncodingDecode=function(t){for(var e=new Array(t.length),r=0,n=t.length;r<n;r++)e[r]=pdfDocEncodingToUnicode[t[r]];return String.fromCodePoint.apply(String,e)},Cache=function(){function t(e){this.populate=e,this.value=void 0}return t.prototype.getValue=function(){return this.value},t.prototype.access=function(){return this.value||(this.value=this.populate()),this.value},t.prototype.invalidate=function(){this.value=void 0},t.populatedBy=function(e){return new t(e)},t}(),MethodNotImplementedError=function(t){__extends(e,t);function e(r,n){var a=this,s="Method "+r+"."+n+"() not implemented";return a=t.call(this,s)||this,a}return e}(Error),PrivateConstructorError=function(t){__extends(e,t);function e(r){var n=this,a="Cannot construct "+r+" - it has a private constructor";return n=t.call(this,a)||this,n}return e}(Error),UnexpectedObjectTypeError=function(t){__extends(e,t);function e(r,n){var a=this,s=function(d){var l,u;return(l=d==null?void 0:d.name)!==null&&l!==void 0?l:(u=d==null?void 0:d.constructor)===null||u===void 0?void 0:u.name},o=Array.isArray(r)?r.map(s):[s(r)],h="Expected instance of "+o.join(" or ")+", "+("but got instance of "+(n&&s(n)));return a=t.call(this,h)||this,a}return e}(Error),UnsupportedEncodingError=function(t){__extends(e,t);function e(r){var n=this,a=r+" stream encoding not supported";return n=t.call(this,a)||this,n}return e}(Error),ReparseError=function(t){__extends(e,t);function e(r,n){var a=this,s="Cannot call "+r+"."+n+"() more than once";return a=t.call(this,s)||this,a}return e}(Error);(function(t){__extends(e,t);function e(r){var n=this,a="Missing catalog (ref="+r+")";return n=t.call(this,a)||this,n}return e})(Error);var MissingPageContentsEmbeddingError=function(t){__extends(e,t);function e(){var r=this,n="Can't embed page with missing Contents";return r=t.call(this,n)||this,r}return e}(Error),UnrecognizedStreamTypeError=function(t){__extends(e,t);function e(r){var n,a,s,o=this,h=(s=(a=(n=r==null?void 0:r.contructor)===null||n===void 0?void 0:n.name)!==null&&a!==void 0?a:r==null?void 0:r.name)!==null&&s!==void 0?s:r,d="Unrecognized stream type: "+h;return o=t.call(this,d)||this,o}return e}(Error),PageEmbeddingMismatchedContextError=function(t){__extends(e,t);function e(){var r=this,n="Found mismatched contexts while embedding pages. All pages in the array passed to `PDFDocument.embedPages()` must be from the same document.";return r=t.call(this,n)||this,r}return e}(Error),PDFArrayIsNotRectangleError=function(t){__extends(e,t);function e(r){var n=this,a="Attempted to convert PDFArray with "+r+" elements to rectangle, but must have exactly 4 elements.";return n=t.call(this,a)||this,n}return e}(Error),InvalidPDFDateStringError=function(t){__extends(e,t);function e(r){var n=this,a='Attempted to convert "'+r+'" to a date, but it does not match the PDF date string format.';return n=t.call(this,a)||this,n}return e}(Error),InvalidTargetIndexError=function(t){__extends(e,t);function e(r,n){var a=this,s="Invalid targetIndex specified: targetIndex="+r+" must be less than Count="+n;return a=t.call(this,s)||this,a}return e}(Error),CorruptPageTreeError=function(t){__extends(e,t);function e(r,n){var a=this,s="Failed to "+n+" at targetIndex="+r+" due to corrupt page tree: It is likely that one or more 'Count' entries are invalid";return a=t.call(this,s)||this,a}return e}(Error),IndexOutOfBoundsError=function(t){__extends(e,t);function e(r,n,a){var s=this,o="index should be at least "+n+" and at most "+a+", but was actually "+r;return s=t.call(this,o)||this,s}return e}(Error),InvalidAcroFieldValueError=function(t){__extends(e,t);function e(){var r=this,n="Attempted to set invalid field value";return r=t.call(this,n)||this,r}return e}(Error),MultiSelectValueError=function(t){__extends(e,t);function e(){var r=this,n="Attempted to select multiple values for single-select field";return r=t.call(this,n)||this,r}return e}(Error),MissingDAEntryError=function(t){__extends(e,t);function e(r){var n=this,a="No /DA (default appearance) entry found for field: "+r;return n=t.call(this,a)||this,n}return e}(Error),MissingTfOperatorError=function(t){__extends(e,t);function e(r){var n=this,a="No Tf operator found for DA of field: "+r;return n=t.call(this,a)||this,n}return e}(Error),NumberParsingError=function(t){__extends(e,t);function e(r,n){var a=this,s="Failed to parse number "+("(line:"+r.line+" col:"+r.column+" offset="+r.offset+'): "'+n+'"');return a=t.call(this,s)||this,a}return e}(Error),PDFParsingError=function(t){__extends(e,t);function e(r,n){var a=this,s="Failed to parse PDF document "+("(line:"+r.line+" col:"+r.column+" offset="+r.offset+"): "+n);return a=t.call(this,s)||this,a}return e}(Error),NextByteAssertionError=function(t){__extends(e,t);function e(r,n,a){var s=this,o="Expected next byte to be "+n+" but it was actually "+a;return s=t.call(this,r,o)||this,s}return e}(PDFParsingError),PDFObjectParsingError=function(t){__extends(e,t);function e(r,n){var a=this,s="Failed to parse PDF object starting with the following byte: "+n;return a=t.call(this,r,s)||this,a}return e}(PDFParsingError),PDFInvalidObjectParsingError=function(t){__extends(e,t);function e(r){var n=this,a="Failed to parse invalid PDF object";return n=t.call(this,r,a)||this,n}return e}(PDFParsingError),PDFStreamParsingError=function(t){__extends(e,t);function e(r){var n=this,a="Failed to parse PDF stream";return n=t.call(this,r,a)||this,n}return e}(PDFParsingError),UnbalancedParenthesisError=function(t){__extends(e,t);function e(r){var n=this,a="Failed to parse PDF literal string due to unbalanced parenthesis";return n=t.call(this,r,a)||this,n}return e}(PDFParsingError),StalledParserError=function(t){__extends(e,t);function e(r){var n=this,a="Parser stalled";return n=t.call(this,r,a)||this,n}return e}(PDFParsingError),MissingPDFHeaderError=function(t){__extends(e,t);function e(r){var n=this,a="No PDF header found";return n=t.call(this,r,a)||this,n}return e}(PDFParsingError),MissingKeywordError=function(t){__extends(e,t);function e(r,n){var a=this,s="Did not find expected keyword '"+arrayAsString(n)+"'";return a=t.call(this,r,s)||this,a}return e}(PDFParsingError),CharCodes$1;(function(t){t[t.Null=0]="Null",t[t.Backspace=8]="Backspace",t[t.Tab=9]="Tab",t[t.Newline=10]="Newline",t[t.FormFeed=12]="FormFeed",t[t.CarriageReturn=13]="CarriageReturn",t[t.Space=32]="Space",t[t.ExclamationPoint=33]="ExclamationPoint",t[t.Hash=35]="Hash",t[t.Percent=37]="Percent",t[t.LeftParen=40]="LeftParen",t[t.RightParen=41]="RightParen",t[t.Plus=43]="Plus",t[t.Minus=45]="Minus",t[t.Dash=45]="Dash",t[t.Period=46]="Period",t[t.ForwardSlash=47]="ForwardSlash",t[t.Zero=48]="Zero",t[t.One=49]="One",t[t.Two=50]="Two",t[t.Three=51]="Three",t[t.Four=52]="Four",t[t.Five=53]="Five",t[t.Six=54]="Six",t[t.Seven=55]="Seven",t[t.Eight=56]="Eight",t[t.Nine=57]="Nine",t[t.LessThan=60]="LessThan",t[t.GreaterThan=62]="GreaterThan",t[t.A=65]="A",t[t.D=68]="D",t[t.E=69]="E",t[t.F=70]="F",t[t.O=79]="O",t[t.P=80]="P",t[t.R=82]="R",t[t.LeftSquareBracket=91]="LeftSquareBracket",t[t.BackSlash=92]="BackSlash",t[t.RightSquareBracket=93]="RightSquareBracket",t[t.a=97]="a",t[t.b=98]="b",t[t.d=100]="d",t[t.e=101]="e",t[t.f=102]="f",t[t.i=105]="i",t[t.j=106]="j",t[t.l=108]="l",t[t.m=109]="m",t[t.n=110]="n",t[t.o=111]="o",t[t.r=114]="r",t[t.s=115]="s",t[t.t=116]="t",t[t.u=117]="u",t[t.x=120]="x",t[t.LeftCurly=123]="LeftCurly",t[t.RightCurly=125]="RightCurly",t[t.Tilde=126]="Tilde"})(CharCodes$1||(CharCodes$1={}));const CharCodes=CharCodes$1;var PDFHeader=function(){function t(e,r){this.major=String(e),this.minor=String(r)}return t.prototype.toString=function(){var e=charFromCode(129);return"%PDF-"+this.major+"."+this.minor+`
|
|
23
|
+
***************************************************************************** */var extendStatics=function(t,e){return extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,n){r.__proto__=n}||function(r,n){for(var a in n)n.hasOwnProperty(a)&&(r[a]=n[a])},extendStatics(t,e)};function __extends(t,e){extendStatics(t,e);function r(){this.constructor=t}t.prototype=e===null?Object.create(e):(r.prototype=e.prototype,new r)}var __assign=function(){return __assign=Object.assign||function(e){for(var r,n=1,a=arguments.length;n<a;n++){r=arguments[n];for(var s in r)Object.prototype.hasOwnProperty.call(r,s)&&(e[s]=r[s])}return e},__assign.apply(this,arguments)};function __rest(t,e){var r={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(t);a<n.length;a++)e.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(t,n[a])&&(r[n[a]]=t[n[a]]);return r}function __awaiter(t,e,r,n){function a(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function h(u){try{l(n.next(u))}catch(p){o(p)}}function d(u){try{l(n.throw(u))}catch(p){o(p)}}function l(u){u.done?s(u.value):a(u.value).then(h,d)}l((n=n.apply(t,[])).next())})}function __generator(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},n,a,s,o;return o={next:h(0),throw:h(1),return:h(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function h(l){return function(u){return d([l,u])}}function d(l){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,a&&(s=l[0]&2?a.return:l[0]?a.throw||((s=a.return)&&s.call(a),0):a.next)&&!(s=s.call(a,l[1])).done)return s;switch(a=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,a=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(u){l=[6,u],a=0}finally{n=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}function __spreadArrays(){for(var t=0,e=0,r=arguments.length;e<r;e++)t+=arguments[e].length;for(var n=Array(t),a=0,e=0;e<r;e++)for(var s=arguments[e],o=0,h=s.length;o<h;o++,a++)n[a]=s[o];return n}for(var chars$1="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",lookup$1=new Uint8Array(256),i$1=0;i$1<chars$1.length;i$1++)lookup$1[chars$1.charCodeAt(i$1)]=i$1;var encodeToBase64=function(t){for(var e="",r=t.length,n=0;n<r;n+=3)e+=chars$1[t[n]>>2],e+=chars$1[(t[n]&3)<<4|t[n+1]>>4],e+=chars$1[(t[n+1]&15)<<2|t[n+2]>>6],e+=chars$1[t[n+2]&63];return r%3===2?e=e.substring(0,e.length-1)+"=":r%3===1&&(e=e.substring(0,e.length-2)+"=="),e},decodeFromBase64$1=function(t){var e=t.length*.75,r=t.length,n,a=0,s,o,h,d;t[t.length-1]==="="&&(e--,t[t.length-2]==="="&&e--);var l=new Uint8Array(e);for(n=0;n<r;n+=4)s=lookup$1[t.charCodeAt(n)],o=lookup$1[t.charCodeAt(n+1)],h=lookup$1[t.charCodeAt(n+2)],d=lookup$1[t.charCodeAt(n+3)],l[a++]=s<<2|o>>4,l[a++]=(o&15)<<4|h>>2,l[a++]=(h&3)<<6|d&63;return l},DATA_URI_PREFIX_REGEX=/^(data)?:?([\w\/\+]+)?;?(charset=[\w-]+|base64)?.*,/i,decodeFromBase64DataUri=function(t){var e=t.trim(),r=e.substring(0,100),n=r.match(DATA_URI_PREFIX_REGEX);if(!n)return decodeFromBase64$1(e);var a=n[0],s=e.substring(a.length);return decodeFromBase64$1(s)},toCharCode=function(t){return t.charCodeAt(0)},toCodePoint=function(t){return t.codePointAt(0)},toHexStringOfMinLength=function(t,e){return padStart$1(t.toString(16),e,"0").toUpperCase()},toHexString=function(t){return toHexStringOfMinLength(t,2)},charFromCode=function(t){return String.fromCharCode(t)},charFromHexCode=function(t){return charFromCode(parseInt(t,16))},padStart$1=function(t,e,r){for(var n="",a=0,s=e-t.length;a<s;a++)n+=r;return n+t},copyStringIntoBuffer=function(t,e,r){for(var n=t.length,a=0;a<n;a++)e[r++]=t.charCodeAt(a);return n},escapeRegExp=function(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")},cleanText=function(t){return t.replace(/\t|\u0085|\u2028|\u2029/g," ").replace(/[\b\v]/g,"")},escapedNewlineChars=["\\n","\\f","\\r","\\u000B"],isNewlineChar=function(t){return/^[\n\f\r\u000B]$/.test(t)},lineSplit=function(t){return t.split(/[\n\f\r\u000B]/)},mergeLines=function(t){return t.replace(/[\n\f\r\u000B]/g," ")},charAtIndex=function(t,e){var r=t.charCodeAt(e),n,a=e+1,s=1;return r>=55296&&r<=56319&&t.length>a&&(n=t.charCodeAt(a),n>=56320&&n<=57343&&(s=2)),[t.slice(e,e+s),s]},charSplit=function(t){for(var e=[],r=0,n=t.length;r<n;){var a=charAtIndex(t,r),s=a[0],o=a[1];e.push(s),r+=o}return e},buildWordBreakRegex=function(t){for(var e=escapedNewlineChars.join("|"),r=["$"],n=0,a=t.length;n<a;n++){var s=t[n];if(isNewlineChar(s))throw new TypeError("`wordBreak` must not include "+e);r.push(s===""?".":escapeRegExp(s))}var o=r.join("|");return new RegExp("("+e+")|((.*?)("+o+"))","gm")},breakTextIntoLines=function(t,e,r,n){for(var a=buildWordBreakRegex(e),s=cleanText(t).match(a),o="",h=0,d=[],l=function(){o!==""&&d.push(o),o="",h=0},u=0,p=s.length;u<p;u++){var g=s[u];if(isNewlineChar(g))l();else{var f=n(g);h+f>r&&l(),o+=g,h+=f}}return l(),d},dateRegex=/^D:(\d\d\d\d)(\d\d)?(\d\d)?(\d\d)?(\d\d)?(\d\d)?([+\-Z])?(\d\d)?'?(\d\d)?'?$/,parseDate=function(t){var e=t.match(dateRegex);if(e){var r=e[1],n=e[2],a=n===void 0?"01":n,s=e[3],o=s===void 0?"01":s,h=e[4],d=h===void 0?"00":h,l=e[5],u=l===void 0?"00":l,p=e[6],g=p===void 0?"00":p,f=e[7],v=f===void 0?"Z":f,y=e[8],S=y===void 0?"00":y,m=e[9],w=m===void 0?"00":m,R=v==="Z"?"Z":""+v+S+":"+w,_=new Date(r+"-"+a+"-"+o+"T"+d+":"+u+":"+g+R);return _}},findLastMatch=function(t,e){for(var r,n=0,a;n<t.length;){var s=t.substring(n).match(e);if(!s)return{match:a,pos:n};a=s,n+=((r=s.index)!==null&&r!==void 0?r:0)+s[0].length}return{match:a,pos:n}},last=function(t){return t[t.length-1]},typedArrayFor=function(t){if(t instanceof Uint8Array)return t;for(var e=t.length,r=new Uint8Array(e),n=0;n<e;n++)r[n]=t.charCodeAt(n);return r},mergeIntoTypedArray=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];for(var r=t.length,n=[],a=0;a<r;a++){var s=t[a];n[a]=s instanceof Uint8Array?s:typedArrayFor(s)}for(var o=0,a=0;a<r;a++)o+=t[a].length;for(var h=new Uint8Array(o),d=0,l=0;l<r;l++)for(var u=n[l],p=0,g=u.length;p<g;p++)h[d++]=u[p];return h},mergeUint8Arrays=function(t){for(var e=0,r=0,n=t.length;r<n;r++)e+=t[r].length;for(var a=new Uint8Array(e),s=0,r=0,n=t.length;r<n;r++){var o=t[r];a.set(o,s),s+=o.length}return a},arrayAsString=function(t){for(var e="",r=0,n=t.length;r<n;r++)e+=charFromCode(t[r]);return e},byAscendingId=function(t,e){return t.id-e.id},sortedUniq=function(t,e){for(var r=[],n=0,a=t.length;n<a;n++){var s=t[n],o=t[n-1];(n===0||e(s)!==e(o))&&r.push(s)}return r},reverseArray=function(t){for(var e=t.length,r=0,n=Math.floor(e/2);r<n;r++){var a=r,s=e-r-1,o=t[r];t[a]=t[s],t[s]=o}return t},sum=function(t){for(var e=0,r=0,n=t.length;r<n;r++)e+=t[r];return e},range=function(t,e){for(var r=new Array(e-t),n=0,a=r.length;n<a;n++)r[n]=t+n;return r},pluckIndices=function(t,e){for(var r=new Array(e.length),n=0,a=e.length;n<a;n++)r[n]=t[e[n]];return r},canBeConvertedToUint8Array=function(t){return t instanceof Uint8Array||t instanceof ArrayBuffer||typeof t=="string"},toUint8Array=function(t){if(typeof t=="string")return decodeFromBase64DataUri(t);if(t instanceof ArrayBuffer)return new Uint8Array(t);if(t instanceof Uint8Array)return t;throw new TypeError("`input` must be one of `string | ArrayBuffer | Uint8Array`")},waitForTick=function(){return new Promise(function(t){setTimeout(function(){return t()},0)})},utf16Encode=function(t,e){e===void 0&&(e=!0);var r=[];e&&r.push(65279);for(var n=0,a=t.length;n<a;){var s=t.codePointAt(n);if(s<65536)r.push(s),n+=1;else if(s<1114112)r.push(highSurrogate(s),lowSurrogate(s)),n+=2;else throw new Error("Invalid code point: 0x"+toHexString(s))}return new Uint16Array(r)},isWithinBMP=function(t){return t>=0&&t<=65535},hasSurrogates=function(t){return t>=65536&&t<=1114111},highSurrogate=function(t){return Math.floor((t-65536)/1024)+55296},lowSurrogate=function(t){return(t-65536)%1024+56320},ByteOrder;(function(t){t.BigEndian="BigEndian",t.LittleEndian="LittleEndian"})(ByteOrder||(ByteOrder={}));var REPLACEMENT="�".codePointAt(0),utf16Decode=function(t,e){if(e===void 0&&(e=!0),t.length<=1)return String.fromCodePoint(REPLACEMENT);for(var r=e?readBOM(t):ByteOrder.BigEndian,n=e?2:0,a=[];t.length-n>=2;){var s=decodeValues(t[n++],t[n++],r);if(isHighSurrogate(s))if(t.length-n<2)a.push(REPLACEMENT);else{var o=decodeValues(t[n++],t[n++],r);isLowSurrogate(o)?a.push(s,o):a.push(REPLACEMENT)}else isLowSurrogate(s)?(n+=2,a.push(REPLACEMENT)):a.push(s)}return n<t.length&&a.push(REPLACEMENT),String.fromCodePoint.apply(String,a)},isHighSurrogate=function(t){return t>=55296&&t<=56319},isLowSurrogate=function(t){return t>=56320&&t<=57343},decodeValues=function(t,e,r){if(r===ByteOrder.LittleEndian)return e<<8|t;if(r===ByteOrder.BigEndian)return t<<8|e;throw new Error("Invalid byteOrder: "+r)},readBOM=function(t){return hasUtf16BigEndianBOM(t)?ByteOrder.BigEndian:hasUtf16LittleEndianBOM(t)?ByteOrder.LittleEndian:ByteOrder.BigEndian},hasUtf16BigEndianBOM=function(t){return t[0]===254&&t[1]===255},hasUtf16LittleEndianBOM=function(t){return t[0]===255&&t[1]===254},hasUtf16BOM=function(t){return hasUtf16BigEndianBOM(t)||hasUtf16LittleEndianBOM(t)},numberToString=function(t){var e=String(t);if(Math.abs(t)<1){var r=parseInt(t.toString().split("e-")[1]);if(r){var n=t<0;n&&(t*=-1),t*=Math.pow(10,r-1),e="0."+new Array(r).join("0")+t.toString().substring(2),n&&(e="-"+e)}}else{var r=parseInt(t.toString().split("+")[1]);r>20&&(r-=20,t/=Math.pow(10,r),e=t.toString()+new Array(r+1).join("0"))}return e},sizeInBytes=function(t){return Math.ceil(t.toString(2).length/8)},bytesFor=function(t){for(var e=new Uint8Array(sizeInBytes(t)),r=1;r<=e.length;r++)e[r-1]=t>>(e.length-r)*8;return e},error=function(t){throw new Error(t)},common={};(function(t){var e=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";function r(s,o){return Object.prototype.hasOwnProperty.call(s,o)}t.assign=function(s){for(var o=Array.prototype.slice.call(arguments,1);o.length;){var h=o.shift();if(h){if(typeof h!="object")throw new TypeError(h+"must be non-object");for(var d in h)r(h,d)&&(s[d]=h[d])}}return s},t.shrinkBuf=function(s,o){return s.length===o?s:s.subarray?s.subarray(0,o):(s.length=o,s)};var n={arraySet:function(s,o,h,d,l){if(o.subarray&&s.subarray){s.set(o.subarray(h,h+d),l);return}for(var u=0;u<d;u++)s[l+u]=o[h+u]},flattenChunks:function(s){var o,h,d,l,u,p;for(d=0,o=0,h=s.length;o<h;o++)d+=s[o].length;for(p=new Uint8Array(d),l=0,o=0,h=s.length;o<h;o++)u=s[o],p.set(u,l),l+=u.length;return p}},a={arraySet:function(s,o,h,d,l){for(var u=0;u<d;u++)s[l+u]=o[h+u]},flattenChunks:function(s){return[].concat.apply([],s)}};t.setTyped=function(s){s?(t.Buf8=Uint8Array,t.Buf16=Uint16Array,t.Buf32=Int32Array,t.assign(t,n)):(t.Buf8=Array,t.Buf16=Array,t.Buf32=Array,t.assign(t,a))},t.setTyped(e)})(common);var deflate$4={},deflate$3={},trees$1={},utils$6=common,Z_FIXED$1=4,Z_BINARY=0,Z_TEXT=1,Z_UNKNOWN$1=2;function zero$1(t){for(var e=t.length;--e>=0;)t[e]=0}var STORED_BLOCK=0,STATIC_TREES=1,DYN_TREES=2,MIN_MATCH$1=3,MAX_MATCH$1=258,LENGTH_CODES$1=29,LITERALS$1=256,L_CODES$1=LITERALS$1+1+LENGTH_CODES$1,D_CODES$1=30,BL_CODES$1=19,HEAP_SIZE$1=2*L_CODES$1+1,MAX_BITS$1=15,Buf_size=16,MAX_BL_BITS=7,END_BLOCK=256,REP_3_6=16,REPZ_3_10=17,REPZ_11_138=18,extra_lbits=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],extra_dbits=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],extra_blbits=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],bl_order=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],DIST_CODE_LEN=512,static_ltree=new Array((L_CODES$1+2)*2);zero$1(static_ltree);var static_dtree=new Array(D_CODES$1*2);zero$1(static_dtree);var _dist_code=new Array(DIST_CODE_LEN);zero$1(_dist_code);var _length_code=new Array(MAX_MATCH$1-MIN_MATCH$1+1);zero$1(_length_code);var base_length=new Array(LENGTH_CODES$1);zero$1(base_length);var base_dist=new Array(D_CODES$1);zero$1(base_dist);function StaticTreeDesc(t,e,r,n,a){this.static_tree=t,this.extra_bits=e,this.extra_base=r,this.elems=n,this.max_length=a,this.has_stree=t&&t.length}var static_l_desc,static_d_desc,static_bl_desc;function TreeDesc(t,e){this.dyn_tree=t,this.max_code=0,this.stat_desc=e}function d_code(t){return t<256?_dist_code[t]:_dist_code[256+(t>>>7)]}function put_short(t,e){t.pending_buf[t.pending++]=e&255,t.pending_buf[t.pending++]=e>>>8&255}function send_bits(t,e,r){t.bi_valid>Buf_size-r?(t.bi_buf|=e<<t.bi_valid&65535,put_short(t,t.bi_buf),t.bi_buf=e>>Buf_size-t.bi_valid,t.bi_valid+=r-Buf_size):(t.bi_buf|=e<<t.bi_valid&65535,t.bi_valid+=r)}function send_code(t,e,r){send_bits(t,r[e*2],r[e*2+1])}function bi_reverse(t,e){var r=0;do r|=t&1,t>>>=1,r<<=1;while(--e>0);return r>>>1}function bi_flush(t){t.bi_valid===16?(put_short(t,t.bi_buf),t.bi_buf=0,t.bi_valid=0):t.bi_valid>=8&&(t.pending_buf[t.pending++]=t.bi_buf&255,t.bi_buf>>=8,t.bi_valid-=8)}function gen_bitlen(t,e){var r=e.dyn_tree,n=e.max_code,a=e.stat_desc.static_tree,s=e.stat_desc.has_stree,o=e.stat_desc.extra_bits,h=e.stat_desc.extra_base,d=e.stat_desc.max_length,l,u,p,g,f,v,y=0;for(g=0;g<=MAX_BITS$1;g++)t.bl_count[g]=0;for(r[t.heap[t.heap_max]*2+1]=0,l=t.heap_max+1;l<HEAP_SIZE$1;l++)u=t.heap[l],g=r[r[u*2+1]*2+1]+1,g>d&&(g=d,y++),r[u*2+1]=g,!(u>n)&&(t.bl_count[g]++,f=0,u>=h&&(f=o[u-h]),v=r[u*2],t.opt_len+=v*(g+f),s&&(t.static_len+=v*(a[u*2+1]+f)));if(y!==0){do{for(g=d-1;t.bl_count[g]===0;)g--;t.bl_count[g]--,t.bl_count[g+1]+=2,t.bl_count[d]--,y-=2}while(y>0);for(g=d;g!==0;g--)for(u=t.bl_count[g];u!==0;)p=t.heap[--l],!(p>n)&&(r[p*2+1]!==g&&(t.opt_len+=(g-r[p*2+1])*r[p*2],r[p*2+1]=g),u--)}}function gen_codes(t,e,r){var n=new Array(MAX_BITS$1+1),a=0,s,o;for(s=1;s<=MAX_BITS$1;s++)n[s]=a=a+r[s-1]<<1;for(o=0;o<=e;o++){var h=t[o*2+1];h!==0&&(t[o*2]=bi_reverse(n[h]++,h))}}function tr_static_init(){var t,e,r,n,a,s=new Array(MAX_BITS$1+1);for(r=0,n=0;n<LENGTH_CODES$1-1;n++)for(base_length[n]=r,t=0;t<1<<extra_lbits[n];t++)_length_code[r++]=n;for(_length_code[r-1]=n,a=0,n=0;n<16;n++)for(base_dist[n]=a,t=0;t<1<<extra_dbits[n];t++)_dist_code[a++]=n;for(a>>=7;n<D_CODES$1;n++)for(base_dist[n]=a<<7,t=0;t<1<<extra_dbits[n]-7;t++)_dist_code[256+a++]=n;for(e=0;e<=MAX_BITS$1;e++)s[e]=0;for(t=0;t<=143;)static_ltree[t*2+1]=8,t++,s[8]++;for(;t<=255;)static_ltree[t*2+1]=9,t++,s[9]++;for(;t<=279;)static_ltree[t*2+1]=7,t++,s[7]++;for(;t<=287;)static_ltree[t*2+1]=8,t++,s[8]++;for(gen_codes(static_ltree,L_CODES$1+1,s),t=0;t<D_CODES$1;t++)static_dtree[t*2+1]=5,static_dtree[t*2]=bi_reverse(t,5);static_l_desc=new StaticTreeDesc(static_ltree,extra_lbits,LITERALS$1+1,L_CODES$1,MAX_BITS$1),static_d_desc=new StaticTreeDesc(static_dtree,extra_dbits,0,D_CODES$1,MAX_BITS$1),static_bl_desc=new StaticTreeDesc(new Array(0),extra_blbits,0,BL_CODES$1,MAX_BL_BITS)}function init_block(t){var e;for(e=0;e<L_CODES$1;e++)t.dyn_ltree[e*2]=0;for(e=0;e<D_CODES$1;e++)t.dyn_dtree[e*2]=0;for(e=0;e<BL_CODES$1;e++)t.bl_tree[e*2]=0;t.dyn_ltree[END_BLOCK*2]=1,t.opt_len=t.static_len=0,t.last_lit=t.matches=0}function bi_windup(t){t.bi_valid>8?put_short(t,t.bi_buf):t.bi_valid>0&&(t.pending_buf[t.pending++]=t.bi_buf),t.bi_buf=0,t.bi_valid=0}function copy_block(t,e,r,n){bi_windup(t),put_short(t,r),put_short(t,~r),utils$6.arraySet(t.pending_buf,t.window,e,r,t.pending),t.pending+=r}function smaller(t,e,r,n){var a=e*2,s=r*2;return t[a]<t[s]||t[a]===t[s]&&n[e]<=n[r]}function pqdownheap(t,e,r){for(var n=t.heap[r],a=r<<1;a<=t.heap_len&&(a<t.heap_len&&smaller(e,t.heap[a+1],t.heap[a],t.depth)&&a++,!smaller(e,n,t.heap[a],t.depth));)t.heap[r]=t.heap[a],r=a,a<<=1;t.heap[r]=n}function compress_block(t,e,r){var n,a,s=0,o,h;if(t.last_lit!==0)do n=t.pending_buf[t.d_buf+s*2]<<8|t.pending_buf[t.d_buf+s*2+1],a=t.pending_buf[t.l_buf+s],s++,n===0?send_code(t,a,e):(o=_length_code[a],send_code(t,o+LITERALS$1+1,e),h=extra_lbits[o],h!==0&&(a-=base_length[o],send_bits(t,a,h)),n--,o=d_code(n),send_code(t,o,r),h=extra_dbits[o],h!==0&&(n-=base_dist[o],send_bits(t,n,h)));while(s<t.last_lit);send_code(t,END_BLOCK,e)}function build_tree(t,e){var r=e.dyn_tree,n=e.stat_desc.static_tree,a=e.stat_desc.has_stree,s=e.stat_desc.elems,o,h,d=-1,l;for(t.heap_len=0,t.heap_max=HEAP_SIZE$1,o=0;o<s;o++)r[o*2]!==0?(t.heap[++t.heap_len]=d=o,t.depth[o]=0):r[o*2+1]=0;for(;t.heap_len<2;)l=t.heap[++t.heap_len]=d<2?++d:0,r[l*2]=1,t.depth[l]=0,t.opt_len--,a&&(t.static_len-=n[l*2+1]);for(e.max_code=d,o=t.heap_len>>1;o>=1;o--)pqdownheap(t,r,o);l=s;do o=t.heap[1],t.heap[1]=t.heap[t.heap_len--],pqdownheap(t,r,1),h=t.heap[1],t.heap[--t.heap_max]=o,t.heap[--t.heap_max]=h,r[l*2]=r[o*2]+r[h*2],t.depth[l]=(t.depth[o]>=t.depth[h]?t.depth[o]:t.depth[h])+1,r[o*2+1]=r[h*2+1]=l,t.heap[1]=l++,pqdownheap(t,r,1);while(t.heap_len>=2);t.heap[--t.heap_max]=t.heap[1],gen_bitlen(t,e),gen_codes(r,d,t.bl_count)}function scan_tree(t,e,r){var n,a=-1,s,o=e[0*2+1],h=0,d=7,l=4;for(o===0&&(d=138,l=3),e[(r+1)*2+1]=65535,n=0;n<=r;n++)s=o,o=e[(n+1)*2+1],!(++h<d&&s===o)&&(h<l?t.bl_tree[s*2]+=h:s!==0?(s!==a&&t.bl_tree[s*2]++,t.bl_tree[REP_3_6*2]++):h<=10?t.bl_tree[REPZ_3_10*2]++:t.bl_tree[REPZ_11_138*2]++,h=0,a=s,o===0?(d=138,l=3):s===o?(d=6,l=3):(d=7,l=4))}function send_tree(t,e,r){var n,a=-1,s,o=e[0*2+1],h=0,d=7,l=4;for(o===0&&(d=138,l=3),n=0;n<=r;n++)if(s=o,o=e[(n+1)*2+1],!(++h<d&&s===o)){if(h<l)do send_code(t,s,t.bl_tree);while(--h!==0);else s!==0?(s!==a&&(send_code(t,s,t.bl_tree),h--),send_code(t,REP_3_6,t.bl_tree),send_bits(t,h-3,2)):h<=10?(send_code(t,REPZ_3_10,t.bl_tree),send_bits(t,h-3,3)):(send_code(t,REPZ_11_138,t.bl_tree),send_bits(t,h-11,7));h=0,a=s,o===0?(d=138,l=3):s===o?(d=6,l=3):(d=7,l=4)}}function build_bl_tree(t){var e;for(scan_tree(t,t.dyn_ltree,t.l_desc.max_code),scan_tree(t,t.dyn_dtree,t.d_desc.max_code),build_tree(t,t.bl_desc),e=BL_CODES$1-1;e>=3&&t.bl_tree[bl_order[e]*2+1]===0;e--);return t.opt_len+=3*(e+1)+5+5+4,e}function send_all_trees(t,e,r,n){var a;for(send_bits(t,e-257,5),send_bits(t,r-1,5),send_bits(t,n-4,4),a=0;a<n;a++)send_bits(t,t.bl_tree[bl_order[a]*2+1],3);send_tree(t,t.dyn_ltree,e-1),send_tree(t,t.dyn_dtree,r-1)}function detect_data_type(t){var e=4093624447,r;for(r=0;r<=31;r++,e>>>=1)if(e&1&&t.dyn_ltree[r*2]!==0)return Z_BINARY;if(t.dyn_ltree[9*2]!==0||t.dyn_ltree[10*2]!==0||t.dyn_ltree[13*2]!==0)return Z_TEXT;for(r=32;r<LITERALS$1;r++)if(t.dyn_ltree[r*2]!==0)return Z_TEXT;return Z_BINARY}var static_init_done=!1;function _tr_init(t){static_init_done||(tr_static_init(),static_init_done=!0),t.l_desc=new TreeDesc(t.dyn_ltree,static_l_desc),t.d_desc=new TreeDesc(t.dyn_dtree,static_d_desc),t.bl_desc=new TreeDesc(t.bl_tree,static_bl_desc),t.bi_buf=0,t.bi_valid=0,init_block(t)}function _tr_stored_block(t,e,r,n){send_bits(t,(STORED_BLOCK<<1)+(n?1:0),3),copy_block(t,e,r)}function _tr_align(t){send_bits(t,STATIC_TREES<<1,3),send_code(t,END_BLOCK,static_ltree),bi_flush(t)}function _tr_flush_block(t,e,r,n){var a,s,o=0;t.level>0?(t.strm.data_type===Z_UNKNOWN$1&&(t.strm.data_type=detect_data_type(t)),build_tree(t,t.l_desc),build_tree(t,t.d_desc),o=build_bl_tree(t),a=t.opt_len+3+7>>>3,s=t.static_len+3+7>>>3,s<=a&&(a=s)):a=s=r+5,r+4<=a&&e!==-1?_tr_stored_block(t,e,r,n):t.strategy===Z_FIXED$1||s===a?(send_bits(t,(STATIC_TREES<<1)+(n?1:0),3),compress_block(t,static_ltree,static_dtree)):(send_bits(t,(DYN_TREES<<1)+(n?1:0),3),send_all_trees(t,t.l_desc.max_code+1,t.d_desc.max_code+1,o+1),compress_block(t,t.dyn_ltree,t.dyn_dtree)),init_block(t),n&&bi_windup(t)}function _tr_tally(t,e,r){return t.pending_buf[t.d_buf+t.last_lit*2]=e>>>8&255,t.pending_buf[t.d_buf+t.last_lit*2+1]=e&255,t.pending_buf[t.l_buf+t.last_lit]=r&255,t.last_lit++,e===0?t.dyn_ltree[r*2]++:(t.matches++,e--,t.dyn_ltree[(_length_code[r]+LITERALS$1+1)*2]++,t.dyn_dtree[d_code(e)*2]++),t.last_lit===t.lit_bufsize-1}trees$1._tr_init=_tr_init,trees$1._tr_stored_block=_tr_stored_block,trees$1._tr_flush_block=_tr_flush_block,trees$1._tr_tally=_tr_tally,trees$1._tr_align=_tr_align;function adler32$2(t,e,r,n){for(var a=t&65535|0,s=t>>>16&65535|0,o=0;r!==0;){o=r>2e3?2e3:r,r-=o;do a=a+e[n++]|0,s=s+a|0;while(--o);a%=65521,s%=65521}return a|s<<16|0}var adler32_1=adler32$2;function makeTable(){for(var t,e=[],r=0;r<256;r++){t=r;for(var n=0;n<8;n++)t=t&1?3988292384^t>>>1:t>>>1;e[r]=t}return e}var crcTable=makeTable();function crc32$2(t,e,r,n){var a=crcTable,s=n+r;t^=-1;for(var o=n;o<s;o++)t=t>>>8^a[(t^e[o])&255];return t^-1}var crc32_1=crc32$2,messages={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},utils$5=common,trees=trees$1,adler32$1=adler32_1,crc32$1=crc32_1,msg$2=messages,Z_NO_FLUSH$1=0,Z_PARTIAL_FLUSH=1,Z_FULL_FLUSH=3,Z_FINISH$2=4,Z_BLOCK$1=5,Z_OK$2=0,Z_STREAM_END$2=1,Z_STREAM_ERROR$1=-2,Z_DATA_ERROR$1=-3,Z_BUF_ERROR$1=-5,Z_DEFAULT_COMPRESSION$1=-1,Z_FILTERED=1,Z_HUFFMAN_ONLY=2,Z_RLE=3,Z_FIXED=4,Z_DEFAULT_STRATEGY$1=0,Z_UNKNOWN=2,Z_DEFLATED$2=8,MAX_MEM_LEVEL=9,MAX_WBITS$1=15,DEF_MEM_LEVEL=8,LENGTH_CODES=29,LITERALS=256,L_CODES=LITERALS+1+LENGTH_CODES,D_CODES=30,BL_CODES=19,HEAP_SIZE=2*L_CODES+1,MAX_BITS=15,MIN_MATCH=3,MAX_MATCH=258,MIN_LOOKAHEAD=MAX_MATCH+MIN_MATCH+1,PRESET_DICT=32,INIT_STATE=42,EXTRA_STATE=69,NAME_STATE=73,COMMENT_STATE=91,HCRC_STATE=103,BUSY_STATE=113,FINISH_STATE=666,BS_NEED_MORE=1,BS_BLOCK_DONE=2,BS_FINISH_STARTED=3,BS_FINISH_DONE=4,OS_CODE=3;function err(t,e){return t.msg=msg$2[e],e}function rank(t){return(t<<1)-(t>4?9:0)}function zero(t){for(var e=t.length;--e>=0;)t[e]=0}function flush_pending(t){var e=t.state,r=e.pending;r>t.avail_out&&(r=t.avail_out),r!==0&&(utils$5.arraySet(t.output,e.pending_buf,e.pending_out,r,t.next_out),t.next_out+=r,e.pending_out+=r,t.total_out+=r,t.avail_out-=r,e.pending-=r,e.pending===0&&(e.pending_out=0))}function flush_block_only(t,e){trees._tr_flush_block(t,t.block_start>=0?t.block_start:-1,t.strstart-t.block_start,e),t.block_start=t.strstart,flush_pending(t.strm)}function put_byte(t,e){t.pending_buf[t.pending++]=e}function putShortMSB(t,e){t.pending_buf[t.pending++]=e>>>8&255,t.pending_buf[t.pending++]=e&255}function read_buf(t,e,r,n){var a=t.avail_in;return a>n&&(a=n),a===0?0:(t.avail_in-=a,utils$5.arraySet(e,t.input,t.next_in,a,r),t.state.wrap===1?t.adler=adler32$1(t.adler,e,a,r):t.state.wrap===2&&(t.adler=crc32$1(t.adler,e,a,r)),t.next_in+=a,t.total_in+=a,a)}function longest_match(t,e){var r=t.max_chain_length,n=t.strstart,a,s,o=t.prev_length,h=t.nice_match,d=t.strstart>t.w_size-MIN_LOOKAHEAD?t.strstart-(t.w_size-MIN_LOOKAHEAD):0,l=t.window,u=t.w_mask,p=t.prev,g=t.strstart+MAX_MATCH,f=l[n+o-1],v=l[n+o];t.prev_length>=t.good_match&&(r>>=2),h>t.lookahead&&(h=t.lookahead);do if(a=e,!(l[a+o]!==v||l[a+o-1]!==f||l[a]!==l[n]||l[++a]!==l[n+1])){n+=2,a++;do;while(l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&l[++n]===l[++a]&&n<g);if(s=MAX_MATCH-(g-n),n=g-MAX_MATCH,s>o){if(t.match_start=e,o=s,s>=h)break;f=l[n+o-1],v=l[n+o]}}while((e=p[e&u])>d&&--r!==0);return o<=t.lookahead?o:t.lookahead}function fill_window(t){var e=t.w_size,r,n,a,s,o;do{if(s=t.window_size-t.lookahead-t.strstart,t.strstart>=e+(e-MIN_LOOKAHEAD)){utils$5.arraySet(t.window,t.window,e,e,0),t.match_start-=e,t.strstart-=e,t.block_start-=e,n=t.hash_size,r=n;do a=t.head[--r],t.head[r]=a>=e?a-e:0;while(--n);n=e,r=n;do a=t.prev[--r],t.prev[r]=a>=e?a-e:0;while(--n);s+=e}if(t.strm.avail_in===0)break;if(n=read_buf(t.strm,t.window,t.strstart+t.lookahead,s),t.lookahead+=n,t.lookahead+t.insert>=MIN_MATCH)for(o=t.strstart-t.insert,t.ins_h=t.window[o],t.ins_h=(t.ins_h<<t.hash_shift^t.window[o+1])&t.hash_mask;t.insert&&(t.ins_h=(t.ins_h<<t.hash_shift^t.window[o+MIN_MATCH-1])&t.hash_mask,t.prev[o&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=o,o++,t.insert--,!(t.lookahead+t.insert<MIN_MATCH)););}while(t.lookahead<MIN_LOOKAHEAD&&t.strm.avail_in!==0)}function deflate_stored(t,e){var r=65535;for(r>t.pending_buf_size-5&&(r=t.pending_buf_size-5);;){if(t.lookahead<=1){if(fill_window(t),t.lookahead===0&&e===Z_NO_FLUSH$1)return BS_NEED_MORE;if(t.lookahead===0)break}t.strstart+=t.lookahead,t.lookahead=0;var n=t.block_start+r;if((t.strstart===0||t.strstart>=n)&&(t.lookahead=t.strstart-n,t.strstart=n,flush_block_only(t,!1),t.strm.avail_out===0)||t.strstart-t.block_start>=t.w_size-MIN_LOOKAHEAD&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=0,e===Z_FINISH$2?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):(t.strstart>t.block_start&&(flush_block_only(t,!1),t.strm.avail_out===0),BS_NEED_MORE)}function deflate_fast(t,e){for(var r,n;;){if(t.lookahead<MIN_LOOKAHEAD){if(fill_window(t),t.lookahead<MIN_LOOKAHEAD&&e===Z_NO_FLUSH$1)return BS_NEED_MORE;if(t.lookahead===0)break}if(r=0,t.lookahead>=MIN_MATCH&&(t.ins_h=(t.ins_h<<t.hash_shift^t.window[t.strstart+MIN_MATCH-1])&t.hash_mask,r=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart),r!==0&&t.strstart-r<=t.w_size-MIN_LOOKAHEAD&&(t.match_length=longest_match(t,r)),t.match_length>=MIN_MATCH)if(n=trees._tr_tally(t,t.strstart-t.match_start,t.match_length-MIN_MATCH),t.lookahead-=t.match_length,t.match_length<=t.max_lazy_match&&t.lookahead>=MIN_MATCH){t.match_length--;do t.strstart++,t.ins_h=(t.ins_h<<t.hash_shift^t.window[t.strstart+MIN_MATCH-1])&t.hash_mask,r=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart;while(--t.match_length!==0);t.strstart++}else t.strstart+=t.match_length,t.match_length=0,t.ins_h=t.window[t.strstart],t.ins_h=(t.ins_h<<t.hash_shift^t.window[t.strstart+1])&t.hash_mask;else n=trees._tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++;if(n&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=t.strstart<MIN_MATCH-1?t.strstart:MIN_MATCH-1,e===Z_FINISH$2?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE}function deflate_slow(t,e){for(var r,n,a;;){if(t.lookahead<MIN_LOOKAHEAD){if(fill_window(t),t.lookahead<MIN_LOOKAHEAD&&e===Z_NO_FLUSH$1)return BS_NEED_MORE;if(t.lookahead===0)break}if(r=0,t.lookahead>=MIN_MATCH&&(t.ins_h=(t.ins_h<<t.hash_shift^t.window[t.strstart+MIN_MATCH-1])&t.hash_mask,r=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart),t.prev_length=t.match_length,t.prev_match=t.match_start,t.match_length=MIN_MATCH-1,r!==0&&t.prev_length<t.max_lazy_match&&t.strstart-r<=t.w_size-MIN_LOOKAHEAD&&(t.match_length=longest_match(t,r),t.match_length<=5&&(t.strategy===Z_FILTERED||t.match_length===MIN_MATCH&&t.strstart-t.match_start>4096)&&(t.match_length=MIN_MATCH-1)),t.prev_length>=MIN_MATCH&&t.match_length<=t.prev_length){a=t.strstart+t.lookahead-MIN_MATCH,n=trees._tr_tally(t,t.strstart-1-t.prev_match,t.prev_length-MIN_MATCH),t.lookahead-=t.prev_length-1,t.prev_length-=2;do++t.strstart<=a&&(t.ins_h=(t.ins_h<<t.hash_shift^t.window[t.strstart+MIN_MATCH-1])&t.hash_mask,r=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart);while(--t.prev_length!==0);if(t.match_available=0,t.match_length=MIN_MATCH-1,t.strstart++,n&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}else if(t.match_available){if(n=trees._tr_tally(t,0,t.window[t.strstart-1]),n&&flush_block_only(t,!1),t.strstart++,t.lookahead--,t.strm.avail_out===0)return BS_NEED_MORE}else t.match_available=1,t.strstart++,t.lookahead--}return t.match_available&&(n=trees._tr_tally(t,0,t.window[t.strstart-1]),t.match_available=0),t.insert=t.strstart<MIN_MATCH-1?t.strstart:MIN_MATCH-1,e===Z_FINISH$2?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE}function deflate_rle(t,e){for(var r,n,a,s,o=t.window;;){if(t.lookahead<=MAX_MATCH){if(fill_window(t),t.lookahead<=MAX_MATCH&&e===Z_NO_FLUSH$1)return BS_NEED_MORE;if(t.lookahead===0)break}if(t.match_length=0,t.lookahead>=MIN_MATCH&&t.strstart>0&&(a=t.strstart-1,n=o[a],n===o[++a]&&n===o[++a]&&n===o[++a])){s=t.strstart+MAX_MATCH;do;while(n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&n===o[++a]&&a<s);t.match_length=MAX_MATCH-(s-a),t.match_length>t.lookahead&&(t.match_length=t.lookahead)}if(t.match_length>=MIN_MATCH?(r=trees._tr_tally(t,1,t.match_length-MIN_MATCH),t.lookahead-=t.match_length,t.strstart+=t.match_length,t.match_length=0):(r=trees._tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++),r&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=0,e===Z_FINISH$2?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE}function deflate_huff(t,e){for(var r;;){if(t.lookahead===0&&(fill_window(t),t.lookahead===0)){if(e===Z_NO_FLUSH$1)return BS_NEED_MORE;break}if(t.match_length=0,r=trees._tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++,r&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=0,e===Z_FINISH$2?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE}function Config(t,e,r,n,a){this.good_length=t,this.max_lazy=e,this.nice_length=r,this.max_chain=n,this.func=a}var configuration_table;configuration_table=[new Config(0,0,0,0,deflate_stored),new Config(4,4,8,4,deflate_fast),new Config(4,5,16,8,deflate_fast),new Config(4,6,32,32,deflate_fast),new Config(4,4,16,16,deflate_slow),new Config(8,16,32,32,deflate_slow),new Config(8,16,128,128,deflate_slow),new Config(8,32,128,256,deflate_slow),new Config(32,128,258,1024,deflate_slow),new Config(32,258,258,4096,deflate_slow)];function lm_init(t){t.window_size=2*t.w_size,zero(t.head),t.max_lazy_match=configuration_table[t.level].max_lazy,t.good_match=configuration_table[t.level].good_length,t.nice_match=configuration_table[t.level].nice_length,t.max_chain_length=configuration_table[t.level].max_chain,t.strstart=0,t.block_start=0,t.lookahead=0,t.insert=0,t.match_length=t.prev_length=MIN_MATCH-1,t.match_available=0,t.ins_h=0}function DeflateState(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Z_DEFLATED$2,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new utils$5.Buf16(HEAP_SIZE*2),this.dyn_dtree=new utils$5.Buf16((2*D_CODES+1)*2),this.bl_tree=new utils$5.Buf16((2*BL_CODES+1)*2),zero(this.dyn_ltree),zero(this.dyn_dtree),zero(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new utils$5.Buf16(MAX_BITS+1),this.heap=new utils$5.Buf16(2*L_CODES+1),zero(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new utils$5.Buf16(2*L_CODES+1),zero(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function deflateResetKeep(t){var e;return!t||!t.state?err(t,Z_STREAM_ERROR$1):(t.total_in=t.total_out=0,t.data_type=Z_UNKNOWN,e=t.state,e.pending=0,e.pending_out=0,e.wrap<0&&(e.wrap=-e.wrap),e.status=e.wrap?INIT_STATE:BUSY_STATE,t.adler=e.wrap===2?0:1,e.last_flush=Z_NO_FLUSH$1,trees._tr_init(e),Z_OK$2)}function deflateReset(t){var e=deflateResetKeep(t);return e===Z_OK$2&&lm_init(t.state),e}function deflateSetHeader(t,e){return!t||!t.state||t.state.wrap!==2?Z_STREAM_ERROR$1:(t.state.gzhead=e,Z_OK$2)}function deflateInit2(t,e,r,n,a,s){if(!t)return Z_STREAM_ERROR$1;var o=1;if(e===Z_DEFAULT_COMPRESSION$1&&(e=6),n<0?(o=0,n=-n):n>15&&(o=2,n-=16),a<1||a>MAX_MEM_LEVEL||r!==Z_DEFLATED$2||n<8||n>15||e<0||e>9||s<0||s>Z_FIXED)return err(t,Z_STREAM_ERROR$1);n===8&&(n=9);var h=new DeflateState;return t.state=h,h.strm=t,h.wrap=o,h.gzhead=null,h.w_bits=n,h.w_size=1<<h.w_bits,h.w_mask=h.w_size-1,h.hash_bits=a+7,h.hash_size=1<<h.hash_bits,h.hash_mask=h.hash_size-1,h.hash_shift=~~((h.hash_bits+MIN_MATCH-1)/MIN_MATCH),h.window=new utils$5.Buf8(h.w_size*2),h.head=new utils$5.Buf16(h.hash_size),h.prev=new utils$5.Buf16(h.w_size),h.lit_bufsize=1<<a+6,h.pending_buf_size=h.lit_bufsize*4,h.pending_buf=new utils$5.Buf8(h.pending_buf_size),h.d_buf=1*h.lit_bufsize,h.l_buf=3*h.lit_bufsize,h.level=e,h.strategy=s,h.method=r,deflateReset(t)}function deflateInit(t,e){return deflateInit2(t,e,Z_DEFLATED$2,MAX_WBITS$1,DEF_MEM_LEVEL,Z_DEFAULT_STRATEGY$1)}function deflate$2(t,e){var r,n,a,s;if(!t||!t.state||e>Z_BLOCK$1||e<0)return t?err(t,Z_STREAM_ERROR$1):Z_STREAM_ERROR$1;if(n=t.state,!t.output||!t.input&&t.avail_in!==0||n.status===FINISH_STATE&&e!==Z_FINISH$2)return err(t,t.avail_out===0?Z_BUF_ERROR$1:Z_STREAM_ERROR$1);if(n.strm=t,r=n.last_flush,n.last_flush=e,n.status===INIT_STATE)if(n.wrap===2)t.adler=0,put_byte(n,31),put_byte(n,139),put_byte(n,8),n.gzhead?(put_byte(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),put_byte(n,n.gzhead.time&255),put_byte(n,n.gzhead.time>>8&255),put_byte(n,n.gzhead.time>>16&255),put_byte(n,n.gzhead.time>>24&255),put_byte(n,n.level===9?2:n.strategy>=Z_HUFFMAN_ONLY||n.level<2?4:0),put_byte(n,n.gzhead.os&255),n.gzhead.extra&&n.gzhead.extra.length&&(put_byte(n,n.gzhead.extra.length&255),put_byte(n,n.gzhead.extra.length>>8&255)),n.gzhead.hcrc&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=EXTRA_STATE):(put_byte(n,0),put_byte(n,0),put_byte(n,0),put_byte(n,0),put_byte(n,0),put_byte(n,n.level===9?2:n.strategy>=Z_HUFFMAN_ONLY||n.level<2?4:0),put_byte(n,OS_CODE),n.status=BUSY_STATE);else{var o=Z_DEFLATED$2+(n.w_bits-8<<4)<<8,h=-1;n.strategy>=Z_HUFFMAN_ONLY||n.level<2?h=0:n.level<6?h=1:n.level===6?h=2:h=3,o|=h<<6,n.strstart!==0&&(o|=PRESET_DICT),o+=31-o%31,n.status=BUSY_STATE,putShortMSB(n,o),n.strstart!==0&&(putShortMSB(n,t.adler>>>16),putShortMSB(n,t.adler&65535)),t.adler=1}if(n.status===EXTRA_STATE)if(n.gzhead.extra){for(a=n.pending;n.gzindex<(n.gzhead.extra.length&65535)&&!(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),flush_pending(t),a=n.pending,n.pending===n.pending_buf_size));)put_byte(n,n.gzhead.extra[n.gzindex]&255),n.gzindex++;n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),n.gzindex===n.gzhead.extra.length&&(n.gzindex=0,n.status=NAME_STATE)}else n.status=NAME_STATE;if(n.status===NAME_STATE)if(n.gzhead.name){a=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),flush_pending(t),a=n.pending,n.pending===n.pending_buf_size)){s=1;break}n.gzindex<n.gzhead.name.length?s=n.gzhead.name.charCodeAt(n.gzindex++)&255:s=0,put_byte(n,s)}while(s!==0);n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),s===0&&(n.gzindex=0,n.status=COMMENT_STATE)}else n.status=COMMENT_STATE;if(n.status===COMMENT_STATE)if(n.gzhead.comment){a=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),flush_pending(t),a=n.pending,n.pending===n.pending_buf_size)){s=1;break}n.gzindex<n.gzhead.comment.length?s=n.gzhead.comment.charCodeAt(n.gzindex++)&255:s=0,put_byte(n,s)}while(s!==0);n.gzhead.hcrc&&n.pending>a&&(t.adler=crc32$1(t.adler,n.pending_buf,n.pending-a,a)),s===0&&(n.status=HCRC_STATE)}else n.status=HCRC_STATE;if(n.status===HCRC_STATE&&(n.gzhead.hcrc?(n.pending+2>n.pending_buf_size&&flush_pending(t),n.pending+2<=n.pending_buf_size&&(put_byte(n,t.adler&255),put_byte(n,t.adler>>8&255),t.adler=0,n.status=BUSY_STATE)):n.status=BUSY_STATE),n.pending!==0){if(flush_pending(t),t.avail_out===0)return n.last_flush=-1,Z_OK$2}else if(t.avail_in===0&&rank(e)<=rank(r)&&e!==Z_FINISH$2)return err(t,Z_BUF_ERROR$1);if(n.status===FINISH_STATE&&t.avail_in!==0)return err(t,Z_BUF_ERROR$1);if(t.avail_in!==0||n.lookahead!==0||e!==Z_NO_FLUSH$1&&n.status!==FINISH_STATE){var d=n.strategy===Z_HUFFMAN_ONLY?deflate_huff(n,e):n.strategy===Z_RLE?deflate_rle(n,e):configuration_table[n.level].func(n,e);if((d===BS_FINISH_STARTED||d===BS_FINISH_DONE)&&(n.status=FINISH_STATE),d===BS_NEED_MORE||d===BS_FINISH_STARTED)return t.avail_out===0&&(n.last_flush=-1),Z_OK$2;if(d===BS_BLOCK_DONE&&(e===Z_PARTIAL_FLUSH?trees._tr_align(n):e!==Z_BLOCK$1&&(trees._tr_stored_block(n,0,0,!1),e===Z_FULL_FLUSH&&(zero(n.head),n.lookahead===0&&(n.strstart=0,n.block_start=0,n.insert=0))),flush_pending(t),t.avail_out===0))return n.last_flush=-1,Z_OK$2}return e!==Z_FINISH$2?Z_OK$2:n.wrap<=0?Z_STREAM_END$2:(n.wrap===2?(put_byte(n,t.adler&255),put_byte(n,t.adler>>8&255),put_byte(n,t.adler>>16&255),put_byte(n,t.adler>>24&255),put_byte(n,t.total_in&255),put_byte(n,t.total_in>>8&255),put_byte(n,t.total_in>>16&255),put_byte(n,t.total_in>>24&255)):(putShortMSB(n,t.adler>>>16),putShortMSB(n,t.adler&65535)),flush_pending(t),n.wrap>0&&(n.wrap=-n.wrap),n.pending!==0?Z_OK$2:Z_STREAM_END$2)}function deflateEnd(t){var e;return!t||!t.state?Z_STREAM_ERROR$1:(e=t.state.status,e!==INIT_STATE&&e!==EXTRA_STATE&&e!==NAME_STATE&&e!==COMMENT_STATE&&e!==HCRC_STATE&&e!==BUSY_STATE&&e!==FINISH_STATE?err(t,Z_STREAM_ERROR$1):(t.state=null,e===BUSY_STATE?err(t,Z_DATA_ERROR$1):Z_OK$2))}function deflateSetDictionary(t,e){var r=e.length,n,a,s,o,h,d,l,u;if(!t||!t.state||(n=t.state,o=n.wrap,o===2||o===1&&n.status!==INIT_STATE||n.lookahead))return Z_STREAM_ERROR$1;for(o===1&&(t.adler=adler32$1(t.adler,e,r,0)),n.wrap=0,r>=n.w_size&&(o===0&&(zero(n.head),n.strstart=0,n.block_start=0,n.insert=0),u=new utils$5.Buf8(n.w_size),utils$5.arraySet(u,e,r-n.w_size,n.w_size,0),e=u,r=n.w_size),h=t.avail_in,d=t.next_in,l=t.input,t.avail_in=r,t.next_in=0,t.input=e,fill_window(n);n.lookahead>=MIN_MATCH;){a=n.strstart,s=n.lookahead-(MIN_MATCH-1);do n.ins_h=(n.ins_h<<n.hash_shift^n.window[a+MIN_MATCH-1])&n.hash_mask,n.prev[a&n.w_mask]=n.head[n.ins_h],n.head[n.ins_h]=a,a++;while(--s);n.strstart=a,n.lookahead=MIN_MATCH-1,fill_window(n)}return n.strstart+=n.lookahead,n.block_start=n.strstart,n.insert=n.lookahead,n.lookahead=0,n.match_length=n.prev_length=MIN_MATCH-1,n.match_available=0,t.next_in=d,t.input=l,t.avail_in=h,n.wrap=o,Z_OK$2}deflate$3.deflateInit=deflateInit,deflate$3.deflateInit2=deflateInit2,deflate$3.deflateReset=deflateReset,deflate$3.deflateResetKeep=deflateResetKeep,deflate$3.deflateSetHeader=deflateSetHeader,deflate$3.deflate=deflate$2,deflate$3.deflateEnd=deflateEnd,deflate$3.deflateSetDictionary=deflateSetDictionary,deflate$3.deflateInfo="pako deflate (from Nodeca project)";var strings$2={},utils$4=common,STR_APPLY_OK=!0,STR_APPLY_UIA_OK=!0;try{String.fromCharCode.apply(null,[0])}catch(t){STR_APPLY_OK=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(t){STR_APPLY_UIA_OK=!1}for(var _utf8len=new utils$4.Buf8(256),q=0;q<256;q++)_utf8len[q]=q>=252?6:q>=248?5:q>=240?4:q>=224?3:q>=192?2:1;_utf8len[254]=_utf8len[254]=1,strings$2.string2buf=function(t){var e,r,n,a,s,o=t.length,h=0;for(a=0;a<o;a++)r=t.charCodeAt(a),(r&64512)===55296&&a+1<o&&(n=t.charCodeAt(a+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),a++)),h+=r<128?1:r<2048?2:r<65536?3:4;for(e=new utils$4.Buf8(h),s=0,a=0;s<h;a++)r=t.charCodeAt(a),(r&64512)===55296&&a+1<o&&(n=t.charCodeAt(a+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),a++)),r<128?e[s++]=r:r<2048?(e[s++]=192|r>>>6,e[s++]=128|r&63):r<65536?(e[s++]=224|r>>>12,e[s++]=128|r>>>6&63,e[s++]=128|r&63):(e[s++]=240|r>>>18,e[s++]=128|r>>>12&63,e[s++]=128|r>>>6&63,e[s++]=128|r&63);return e};function buf2binstring(t,e){if(e<65534&&(t.subarray&&STR_APPLY_UIA_OK||!t.subarray&&STR_APPLY_OK))return String.fromCharCode.apply(null,utils$4.shrinkBuf(t,e));for(var r="",n=0;n<e;n++)r+=String.fromCharCode(t[n]);return r}strings$2.buf2binstring=function(t){return buf2binstring(t,t.length)},strings$2.binstring2buf=function(t){for(var e=new utils$4.Buf8(t.length),r=0,n=e.length;r<n;r++)e[r]=t.charCodeAt(r);return e},strings$2.buf2string=function(t,e){var r,n,a,s,o=e||t.length,h=new Array(o*2);for(n=0,r=0;r<o;){if(a=t[r++],a<128){h[n++]=a;continue}if(s=_utf8len[a],s>4){h[n++]=65533,r+=s-1;continue}for(a&=s===2?31:s===3?15:7;s>1&&r<o;)a=a<<6|t[r++]&63,s--;if(s>1){h[n++]=65533;continue}a<65536?h[n++]=a:(a-=65536,h[n++]=55296|a>>10&1023,h[n++]=56320|a&1023)}return buf2binstring(h,n)},strings$2.utf8border=function(t,e){var r;for(e=e||t.length,e>t.length&&(e=t.length),r=e-1;r>=0&&(t[r]&192)===128;)r--;return r<0||r===0?e:r+_utf8len[t[r]]>e?r:e};function ZStream$2(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}var zstream=ZStream$2,zlib_deflate=deflate$3,utils$3=common,strings$1=strings$2,msg$1=messages,ZStream$1=zstream,toString$1=Object.prototype.toString,Z_NO_FLUSH=0,Z_FINISH$1=4,Z_OK$1=0,Z_STREAM_END$1=1,Z_SYNC_FLUSH=2,Z_DEFAULT_COMPRESSION=-1,Z_DEFAULT_STRATEGY=0,Z_DEFLATED$1=8;function Deflate(t){if(!(this instanceof Deflate))return new Deflate(t);this.options=utils$3.assign({level:Z_DEFAULT_COMPRESSION,method:Z_DEFLATED$1,chunkSize:16384,windowBits:15,memLevel:8,strategy:Z_DEFAULT_STRATEGY,to:""},t||{});var e=this.options;e.raw&&e.windowBits>0?e.windowBits=-e.windowBits:e.gzip&&e.windowBits>0&&e.windowBits<16&&(e.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new ZStream$1,this.strm.avail_out=0;var r=zlib_deflate.deflateInit2(this.strm,e.level,e.method,e.windowBits,e.memLevel,e.strategy);if(r!==Z_OK$1)throw new Error(msg$1[r]);if(e.header&&zlib_deflate.deflateSetHeader(this.strm,e.header),e.dictionary){var n;if(typeof e.dictionary=="string"?n=strings$1.string2buf(e.dictionary):toString$1.call(e.dictionary)==="[object ArrayBuffer]"?n=new Uint8Array(e.dictionary):n=e.dictionary,r=zlib_deflate.deflateSetDictionary(this.strm,n),r!==Z_OK$1)throw new Error(msg$1[r]);this._dict_set=!0}}Deflate.prototype.push=function(t,e){var r=this.strm,n=this.options.chunkSize,a,s;if(this.ended)return!1;s=e===~~e?e:e===!0?Z_FINISH$1:Z_NO_FLUSH,typeof t=="string"?r.input=strings$1.string2buf(t):toString$1.call(t)==="[object ArrayBuffer]"?r.input=new Uint8Array(t):r.input=t,r.next_in=0,r.avail_in=r.input.length;do{if(r.avail_out===0&&(r.output=new utils$3.Buf8(n),r.next_out=0,r.avail_out=n),a=zlib_deflate.deflate(r,s),a!==Z_STREAM_END$1&&a!==Z_OK$1)return this.onEnd(a),this.ended=!0,!1;(r.avail_out===0||r.avail_in===0&&(s===Z_FINISH$1||s===Z_SYNC_FLUSH))&&(this.options.to==="string"?this.onData(strings$1.buf2binstring(utils$3.shrinkBuf(r.output,r.next_out))):this.onData(utils$3.shrinkBuf(r.output,r.next_out)))}while((r.avail_in>0||r.avail_out===0)&&a!==Z_STREAM_END$1);return s===Z_FINISH$1?(a=zlib_deflate.deflateEnd(this.strm),this.onEnd(a),this.ended=!0,a===Z_OK$1):(s===Z_SYNC_FLUSH&&(this.onEnd(Z_OK$1),r.avail_out=0),!0)},Deflate.prototype.onData=function(t){this.chunks.push(t)},Deflate.prototype.onEnd=function(t){t===Z_OK$1&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=utils$3.flattenChunks(this.chunks)),this.chunks=[],this.err=t,this.msg=this.strm.msg};function deflate$1(t,e){var r=new Deflate(e);if(r.push(t,!0),r.err)throw r.msg||msg$1[r.err];return r.result}function deflateRaw(t,e){return e=e||{},e.raw=!0,deflate$1(t,e)}function gzip(t,e){return e=e||{},e.gzip=!0,deflate$1(t,e)}deflate$4.Deflate=Deflate,deflate$4.deflate=deflate$1,deflate$4.deflateRaw=deflateRaw,deflate$4.gzip=gzip;var inflate$4={},inflate$3={},BAD$1=30,TYPE$1=12,inffast=function t(e,r){var n,a,s,o,h,d,l,u,p,g,f,v,y,S,m,w,R,_,x,F,A,D,T,M,C;n=e.state,a=e.next_in,M=e.input,s=a+(e.avail_in-5),o=e.next_out,C=e.output,h=o-(r-e.avail_out),d=o+(e.avail_out-257),l=n.dmax,u=n.wsize,p=n.whave,g=n.wnext,f=n.window,v=n.hold,y=n.bits,S=n.lencode,m=n.distcode,w=(1<<n.lenbits)-1,R=(1<<n.distbits)-1;e:do{y<15&&(v+=M[a++]<<y,y+=8,v+=M[a++]<<y,y+=8),_=S[v&w];t:for(;;){if(x=_>>>24,v>>>=x,y-=x,x=_>>>16&255,x===0)C[o++]=_&65535;else if(x&16){F=_&65535,x&=15,x&&(y<x&&(v+=M[a++]<<y,y+=8),F+=v&(1<<x)-1,v>>>=x,y-=x),y<15&&(v+=M[a++]<<y,y+=8,v+=M[a++]<<y,y+=8),_=m[v&R];r:for(;;){if(x=_>>>24,v>>>=x,y-=x,x=_>>>16&255,x&16){if(A=_&65535,x&=15,y<x&&(v+=M[a++]<<y,y+=8,y<x&&(v+=M[a++]<<y,y+=8)),A+=v&(1<<x)-1,A>l){e.msg="invalid distance too far back",n.mode=BAD$1;break e}if(v>>>=x,y-=x,x=o-h,A>x){if(x=A-x,x>p&&n.sane){e.msg="invalid distance too far back",n.mode=BAD$1;break e}if(D=0,T=f,g===0){if(D+=u-x,x<F){F-=x;do C[o++]=f[D++];while(--x);D=o-A,T=C}}else if(g<x){if(D+=u+g-x,x-=g,x<F){F-=x;do C[o++]=f[D++];while(--x);if(D=0,g<F){x=g,F-=x;do C[o++]=f[D++];while(--x);D=o-A,T=C}}}else if(D+=g-x,x<F){F-=x;do C[o++]=f[D++];while(--x);D=o-A,T=C}for(;F>2;)C[o++]=T[D++],C[o++]=T[D++],C[o++]=T[D++],F-=3;F&&(C[o++]=T[D++],F>1&&(C[o++]=T[D++]))}else{D=o-A;do C[o++]=C[D++],C[o++]=C[D++],C[o++]=C[D++],F-=3;while(F>2);F&&(C[o++]=C[D++],F>1&&(C[o++]=C[D++]))}}else if(x&64){e.msg="invalid distance code",n.mode=BAD$1;break e}else{_=m[(_&65535)+(v&(1<<x)-1)];continue r}break}}else if(x&64)if(x&32){n.mode=TYPE$1;break e}else{e.msg="invalid literal/length code",n.mode=BAD$1;break e}else{_=S[(_&65535)+(v&(1<<x)-1)];continue t}break}}while(a<s&&o<d);F=y>>3,a-=F,y-=F<<3,v&=(1<<y)-1,e.next_in=a,e.next_out=o,e.avail_in=a<s?5+(s-a):5-(a-s),e.avail_out=o<d?257+(d-o):257-(o-d),n.hold=v,n.bits=y},utils$2=common,MAXBITS=15,ENOUGH_LENS$1=852,ENOUGH_DISTS$1=592,CODES$1=0,LENS$1=1,DISTS$1=2,lbase=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],lext=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],dbase=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],dext=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64],inftrees=function t(e,r,n,a,s,o,h,d){var l=d.bits,u=0,p=0,g=0,f=0,v=0,y=0,S=0,m=0,w=0,R=0,_,x,F,A,D,T=null,M=0,C,k=new utils$2.Buf16(MAXBITS+1),O=new utils$2.Buf16(MAXBITS+1),$=null,K=0,J,Y,se;for(u=0;u<=MAXBITS;u++)k[u]=0;for(p=0;p<a;p++)k[r[n+p]]++;for(v=l,f=MAXBITS;f>=1&&k[f]===0;f--);if(v>f&&(v=f),f===0)return s[o++]=1<<24|64<<16|0,s[o++]=1<<24|64<<16|0,d.bits=1,0;for(g=1;g<f&&k[g]===0;g++);for(v<g&&(v=g),m=1,u=1;u<=MAXBITS;u++)if(m<<=1,m-=k[u],m<0)return-1;if(m>0&&(e===CODES$1||f!==1))return-1;for(O[1]=0,u=1;u<MAXBITS;u++)O[u+1]=O[u]+k[u];for(p=0;p<a;p++)r[n+p]!==0&&(h[O[r[n+p]]++]=p);if(e===CODES$1?(T=$=h,C=19):e===LENS$1?(T=lbase,M-=257,$=lext,K-=257,C=256):(T=dbase,$=dext,C=-1),R=0,p=0,u=g,D=o,y=v,S=0,F=-1,w=1<<v,A=w-1,e===LENS$1&&w>ENOUGH_LENS$1||e===DISTS$1&&w>ENOUGH_DISTS$1)return 1;for(;;){J=u-S,h[p]<C?(Y=0,se=h[p]):h[p]>C?(Y=$[K+h[p]],se=T[M+h[p]]):(Y=96,se=0),_=1<<u-S,x=1<<y,g=x;do x-=_,s[D+(R>>S)+x]=J<<24|Y<<16|se|0;while(x!==0);for(_=1<<u-1;R&_;)_>>=1;if(_!==0?(R&=_-1,R+=_):R=0,p++,--k[u]===0){if(u===f)break;u=r[n+h[p]]}if(u>v&&(R&A)!==F){for(S===0&&(S=v),D+=g,y=u-S,m=1<<y;y+S<f&&(m-=k[y+S],!(m<=0));)y++,m<<=1;if(w+=1<<y,e===LENS$1&&w>ENOUGH_LENS$1||e===DISTS$1&&w>ENOUGH_DISTS$1)return 1;F=R&A,s[F]=v<<24|y<<16|D-o|0}}return R!==0&&(s[D+R]=u-S<<24|64<<16|0),d.bits=v,0},utils$1=common,adler32=adler32_1,crc32=crc32_1,inflate_fast=inffast,inflate_table=inftrees,CODES=0,LENS=1,DISTS=2,Z_FINISH=4,Z_BLOCK=5,Z_TREES=6,Z_OK=0,Z_STREAM_END=1,Z_NEED_DICT=2,Z_STREAM_ERROR=-2,Z_DATA_ERROR=-3,Z_MEM_ERROR=-4,Z_BUF_ERROR=-5,Z_DEFLATED=8,HEAD=1,FLAGS=2,TIME=3,OS=4,EXLEN=5,EXTRA=6,NAME=7,COMMENT=8,HCRC=9,DICTID=10,DICT=11,TYPE=12,TYPEDO=13,STORED=14,COPY_=15,COPY=16,TABLE=17,LENLENS=18,CODELENS=19,LEN_=20,LEN=21,LENEXT=22,DIST=23,DISTEXT=24,MATCH=25,LIT=26,CHECK=27,LENGTH=28,DONE=29,BAD=30,MEM=31,SYNC=32,ENOUGH_LENS=852,ENOUGH_DISTS=592,MAX_WBITS=15,DEF_WBITS=MAX_WBITS;function zswap32(t){return(t>>>24&255)+(t>>>8&65280)+((t&65280)<<8)+((t&255)<<24)}function InflateState(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new utils$1.Buf16(320),this.work=new utils$1.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function inflateResetKeep(t){var e;return!t||!t.state?Z_STREAM_ERROR:(e=t.state,t.total_in=t.total_out=e.total=0,t.msg="",e.wrap&&(t.adler=e.wrap&1),e.mode=HEAD,e.last=0,e.havedict=0,e.dmax=32768,e.head=null,e.hold=0,e.bits=0,e.lencode=e.lendyn=new utils$1.Buf32(ENOUGH_LENS),e.distcode=e.distdyn=new utils$1.Buf32(ENOUGH_DISTS),e.sane=1,e.back=-1,Z_OK)}function inflateReset(t){var e;return!t||!t.state?Z_STREAM_ERROR:(e=t.state,e.wsize=0,e.whave=0,e.wnext=0,inflateResetKeep(t))}function inflateReset2(t,e){var r,n;return!t||!t.state||(n=t.state,e<0?(r=0,e=-e):(r=(e>>4)+1,e<48&&(e&=15)),e&&(e<8||e>15))?Z_STREAM_ERROR:(n.window!==null&&n.wbits!==e&&(n.window=null),n.wrap=r,n.wbits=e,inflateReset(t))}function inflateInit2(t,e){var r,n;return t?(n=new InflateState,t.state=n,n.window=null,r=inflateReset2(t,e),r!==Z_OK&&(t.state=null),r):Z_STREAM_ERROR}function inflateInit(t){return inflateInit2(t,DEF_WBITS)}var virgin=!0,lenfix,distfix;function fixedtables(t){if(virgin){var e;for(lenfix=new utils$1.Buf32(512),distfix=new utils$1.Buf32(32),e=0;e<144;)t.lens[e++]=8;for(;e<256;)t.lens[e++]=9;for(;e<280;)t.lens[e++]=7;for(;e<288;)t.lens[e++]=8;for(inflate_table(LENS,t.lens,0,288,lenfix,0,t.work,{bits:9}),e=0;e<32;)t.lens[e++]=5;inflate_table(DISTS,t.lens,0,32,distfix,0,t.work,{bits:5}),virgin=!1}t.lencode=lenfix,t.lenbits=9,t.distcode=distfix,t.distbits=5}function updatewindow(t,e,r,n){var a,s=t.state;return s.window===null&&(s.wsize=1<<s.wbits,s.wnext=0,s.whave=0,s.window=new utils$1.Buf8(s.wsize)),n>=s.wsize?(utils$1.arraySet(s.window,e,r-s.wsize,s.wsize,0),s.wnext=0,s.whave=s.wsize):(a=s.wsize-s.wnext,a>n&&(a=n),utils$1.arraySet(s.window,e,r-n,a,s.wnext),n-=a,n?(utils$1.arraySet(s.window,e,r-n,n,0),s.wnext=n,s.whave=s.wsize):(s.wnext+=a,s.wnext===s.wsize&&(s.wnext=0),s.whave<s.wsize&&(s.whave+=a))),0}function inflate$2(t,e){var r,n,a,s,o,h,d,l,u,p,g,f,v,y,S=0,m,w,R,_,x,F,A,D,T=new utils$1.Buf8(4),M,C,k=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!t||!t.state||!t.output||!t.input&&t.avail_in!==0)return Z_STREAM_ERROR;r=t.state,r.mode===TYPE&&(r.mode=TYPEDO),o=t.next_out,a=t.output,d=t.avail_out,s=t.next_in,n=t.input,h=t.avail_in,l=r.hold,u=r.bits,p=h,g=d,D=Z_OK;e:for(;;)switch(r.mode){case HEAD:if(r.wrap===0){r.mode=TYPEDO;break}for(;u<16;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(r.wrap&2&&l===35615){r.check=0,T[0]=l&255,T[1]=l>>>8&255,r.check=crc32(r.check,T,2,0),l=0,u=0,r.mode=FLAGS;break}if(r.flags=0,r.head&&(r.head.done=!1),!(r.wrap&1)||(((l&255)<<8)+(l>>8))%31){t.msg="incorrect header check",r.mode=BAD;break}if((l&15)!==Z_DEFLATED){t.msg="unknown compression method",r.mode=BAD;break}if(l>>>=4,u-=4,A=(l&15)+8,r.wbits===0)r.wbits=A;else if(A>r.wbits){t.msg="invalid window size",r.mode=BAD;break}r.dmax=1<<A,t.adler=r.check=1,r.mode=l&512?DICTID:TYPE,l=0,u=0;break;case FLAGS:for(;u<16;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(r.flags=l,(r.flags&255)!==Z_DEFLATED){t.msg="unknown compression method",r.mode=BAD;break}if(r.flags&57344){t.msg="unknown header flags set",r.mode=BAD;break}r.head&&(r.head.text=l>>8&1),r.flags&512&&(T[0]=l&255,T[1]=l>>>8&255,r.check=crc32(r.check,T,2,0)),l=0,u=0,r.mode=TIME;case TIME:for(;u<32;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.head&&(r.head.time=l),r.flags&512&&(T[0]=l&255,T[1]=l>>>8&255,T[2]=l>>>16&255,T[3]=l>>>24&255,r.check=crc32(r.check,T,4,0)),l=0,u=0,r.mode=OS;case OS:for(;u<16;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.head&&(r.head.xflags=l&255,r.head.os=l>>8),r.flags&512&&(T[0]=l&255,T[1]=l>>>8&255,r.check=crc32(r.check,T,2,0)),l=0,u=0,r.mode=EXLEN;case EXLEN:if(r.flags&1024){for(;u<16;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.length=l,r.head&&(r.head.extra_len=l),r.flags&512&&(T[0]=l&255,T[1]=l>>>8&255,r.check=crc32(r.check,T,2,0)),l=0,u=0}else r.head&&(r.head.extra=null);r.mode=EXTRA;case EXTRA:if(r.flags&1024&&(f=r.length,f>h&&(f=h),f&&(r.head&&(A=r.head.extra_len-r.length,r.head.extra||(r.head.extra=new Array(r.head.extra_len)),utils$1.arraySet(r.head.extra,n,s,f,A)),r.flags&512&&(r.check=crc32(r.check,n,f,s)),h-=f,s+=f,r.length-=f),r.length))break e;r.length=0,r.mode=NAME;case NAME:if(r.flags&2048){if(h===0)break e;f=0;do A=n[s+f++],r.head&&A&&r.length<65536&&(r.head.name+=String.fromCharCode(A));while(A&&f<h);if(r.flags&512&&(r.check=crc32(r.check,n,f,s)),h-=f,s+=f,A)break e}else r.head&&(r.head.name=null);r.length=0,r.mode=COMMENT;case COMMENT:if(r.flags&4096){if(h===0)break e;f=0;do A=n[s+f++],r.head&&A&&r.length<65536&&(r.head.comment+=String.fromCharCode(A));while(A&&f<h);if(r.flags&512&&(r.check=crc32(r.check,n,f,s)),h-=f,s+=f,A)break e}else r.head&&(r.head.comment=null);r.mode=HCRC;case HCRC:if(r.flags&512){for(;u<16;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(l!==(r.check&65535)){t.msg="header crc mismatch",r.mode=BAD;break}l=0,u=0}r.head&&(r.head.hcrc=r.flags>>9&1,r.head.done=!0),t.adler=r.check=0,r.mode=TYPE;break;case DICTID:for(;u<32;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}t.adler=r.check=zswap32(l),l=0,u=0,r.mode=DICT;case DICT:if(r.havedict===0)return t.next_out=o,t.avail_out=d,t.next_in=s,t.avail_in=h,r.hold=l,r.bits=u,Z_NEED_DICT;t.adler=r.check=1,r.mode=TYPE;case TYPE:if(e===Z_BLOCK||e===Z_TREES)break e;case TYPEDO:if(r.last){l>>>=u&7,u-=u&7,r.mode=CHECK;break}for(;u<3;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}switch(r.last=l&1,l>>>=1,u-=1,l&3){case 0:r.mode=STORED;break;case 1:if(fixedtables(r),r.mode=LEN_,e===Z_TREES){l>>>=2,u-=2;break e}break;case 2:r.mode=TABLE;break;case 3:t.msg="invalid block type",r.mode=BAD}l>>>=2,u-=2;break;case STORED:for(l>>>=u&7,u-=u&7;u<32;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if((l&65535)!==(l>>>16^65535)){t.msg="invalid stored block lengths",r.mode=BAD;break}if(r.length=l&65535,l=0,u=0,r.mode=COPY_,e===Z_TREES)break e;case COPY_:r.mode=COPY;case COPY:if(f=r.length,f){if(f>h&&(f=h),f>d&&(f=d),f===0)break e;utils$1.arraySet(a,n,s,f,o),h-=f,s+=f,d-=f,o+=f,r.length-=f;break}r.mode=TYPE;break;case TABLE:for(;u<14;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(r.nlen=(l&31)+257,l>>>=5,u-=5,r.ndist=(l&31)+1,l>>>=5,u-=5,r.ncode=(l&15)+4,l>>>=4,u-=4,r.nlen>286||r.ndist>30){t.msg="too many length or distance symbols",r.mode=BAD;break}r.have=0,r.mode=LENLENS;case LENLENS:for(;r.have<r.ncode;){for(;u<3;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.lens[k[r.have++]]=l&7,l>>>=3,u-=3}for(;r.have<19;)r.lens[k[r.have++]]=0;if(r.lencode=r.lendyn,r.lenbits=7,M={bits:r.lenbits},D=inflate_table(CODES,r.lens,0,19,r.lencode,0,r.work,M),r.lenbits=M.bits,D){t.msg="invalid code lengths set",r.mode=BAD;break}r.have=0,r.mode=CODELENS;case CODELENS:for(;r.have<r.nlen+r.ndist;){for(;S=r.lencode[l&(1<<r.lenbits)-1],m=S>>>24,w=S>>>16&255,R=S&65535,!(m<=u);){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(R<16)l>>>=m,u-=m,r.lens[r.have++]=R;else{if(R===16){for(C=m+2;u<C;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(l>>>=m,u-=m,r.have===0){t.msg="invalid bit length repeat",r.mode=BAD;break}A=r.lens[r.have-1],f=3+(l&3),l>>>=2,u-=2}else if(R===17){for(C=m+3;u<C;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}l>>>=m,u-=m,A=0,f=3+(l&7),l>>>=3,u-=3}else{for(C=m+7;u<C;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}l>>>=m,u-=m,A=0,f=11+(l&127),l>>>=7,u-=7}if(r.have+f>r.nlen+r.ndist){t.msg="invalid bit length repeat",r.mode=BAD;break}for(;f--;)r.lens[r.have++]=A}}if(r.mode===BAD)break;if(r.lens[256]===0){t.msg="invalid code -- missing end-of-block",r.mode=BAD;break}if(r.lenbits=9,M={bits:r.lenbits},D=inflate_table(LENS,r.lens,0,r.nlen,r.lencode,0,r.work,M),r.lenbits=M.bits,D){t.msg="invalid literal/lengths set",r.mode=BAD;break}if(r.distbits=6,r.distcode=r.distdyn,M={bits:r.distbits},D=inflate_table(DISTS,r.lens,r.nlen,r.ndist,r.distcode,0,r.work,M),r.distbits=M.bits,D){t.msg="invalid distances set",r.mode=BAD;break}if(r.mode=LEN_,e===Z_TREES)break e;case LEN_:r.mode=LEN;case LEN:if(h>=6&&d>=258){t.next_out=o,t.avail_out=d,t.next_in=s,t.avail_in=h,r.hold=l,r.bits=u,inflate_fast(t,g),o=t.next_out,a=t.output,d=t.avail_out,s=t.next_in,n=t.input,h=t.avail_in,l=r.hold,u=r.bits,r.mode===TYPE&&(r.back=-1);break}for(r.back=0;S=r.lencode[l&(1<<r.lenbits)-1],m=S>>>24,w=S>>>16&255,R=S&65535,!(m<=u);){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(w&&!(w&240)){for(_=m,x=w,F=R;S=r.lencode[F+((l&(1<<_+x)-1)>>_)],m=S>>>24,w=S>>>16&255,R=S&65535,!(_+m<=u);){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}l>>>=_,u-=_,r.back+=_}if(l>>>=m,u-=m,r.back+=m,r.length=R,w===0){r.mode=LIT;break}if(w&32){r.back=-1,r.mode=TYPE;break}if(w&64){t.msg="invalid literal/length code",r.mode=BAD;break}r.extra=w&15,r.mode=LENEXT;case LENEXT:if(r.extra){for(C=r.extra;u<C;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.length+=l&(1<<r.extra)-1,l>>>=r.extra,u-=r.extra,r.back+=r.extra}r.was=r.length,r.mode=DIST;case DIST:for(;S=r.distcode[l&(1<<r.distbits)-1],m=S>>>24,w=S>>>16&255,R=S&65535,!(m<=u);){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(!(w&240)){for(_=m,x=w,F=R;S=r.distcode[F+((l&(1<<_+x)-1)>>_)],m=S>>>24,w=S>>>16&255,R=S&65535,!(_+m<=u);){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}l>>>=_,u-=_,r.back+=_}if(l>>>=m,u-=m,r.back+=m,w&64){t.msg="invalid distance code",r.mode=BAD;break}r.offset=R,r.extra=w&15,r.mode=DISTEXT;case DISTEXT:if(r.extra){for(C=r.extra;u<C;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}r.offset+=l&(1<<r.extra)-1,l>>>=r.extra,u-=r.extra,r.back+=r.extra}if(r.offset>r.dmax){t.msg="invalid distance too far back",r.mode=BAD;break}r.mode=MATCH;case MATCH:if(d===0)break e;if(f=g-d,r.offset>f){if(f=r.offset-f,f>r.whave&&r.sane){t.msg="invalid distance too far back",r.mode=BAD;break}f>r.wnext?(f-=r.wnext,v=r.wsize-f):v=r.wnext-f,f>r.length&&(f=r.length),y=r.window}else y=a,v=o-r.offset,f=r.length;f>d&&(f=d),d-=f,r.length-=f;do a[o++]=y[v++];while(--f);r.length===0&&(r.mode=LEN);break;case LIT:if(d===0)break e;a[o++]=r.length,d--,r.mode=LEN;break;case CHECK:if(r.wrap){for(;u<32;){if(h===0)break e;h--,l|=n[s++]<<u,u+=8}if(g-=d,t.total_out+=g,r.total+=g,g&&(t.adler=r.check=r.flags?crc32(r.check,a,g,o-g):adler32(r.check,a,g,o-g)),g=d,(r.flags?l:zswap32(l))!==r.check){t.msg="incorrect data check",r.mode=BAD;break}l=0,u=0}r.mode=LENGTH;case LENGTH:if(r.wrap&&r.flags){for(;u<32;){if(h===0)break e;h--,l+=n[s++]<<u,u+=8}if(l!==(r.total&4294967295)){t.msg="incorrect length check",r.mode=BAD;break}l=0,u=0}r.mode=DONE;case DONE:D=Z_STREAM_END;break e;case BAD:D=Z_DATA_ERROR;break e;case MEM:return Z_MEM_ERROR;case SYNC:default:return Z_STREAM_ERROR}return t.next_out=o,t.avail_out=d,t.next_in=s,t.avail_in=h,r.hold=l,r.bits=u,(r.wsize||g!==t.avail_out&&r.mode<BAD&&(r.mode<CHECK||e!==Z_FINISH))&&updatewindow(t,t.output,t.next_out,g-t.avail_out),p-=t.avail_in,g-=t.avail_out,t.total_in+=p,t.total_out+=g,r.total+=g,r.wrap&&g&&(t.adler=r.check=r.flags?crc32(r.check,a,g,t.next_out-g):adler32(r.check,a,g,t.next_out-g)),t.data_type=r.bits+(r.last?64:0)+(r.mode===TYPE?128:0)+(r.mode===LEN_||r.mode===COPY_?256:0),(p===0&&g===0||e===Z_FINISH)&&D===Z_OK&&(D=Z_BUF_ERROR),D}function inflateEnd(t){if(!t||!t.state)return Z_STREAM_ERROR;var e=t.state;return e.window&&(e.window=null),t.state=null,Z_OK}function inflateGetHeader(t,e){var r;return!t||!t.state||(r=t.state,!(r.wrap&2))?Z_STREAM_ERROR:(r.head=e,e.done=!1,Z_OK)}function inflateSetDictionary(t,e){var r=e.length,n,a,s;return!t||!t.state||(n=t.state,n.wrap!==0&&n.mode!==DICT)?Z_STREAM_ERROR:n.mode===DICT&&(a=1,a=adler32(a,e,r,0),a!==n.check)?Z_DATA_ERROR:(s=updatewindow(t,e,r,r),s?(n.mode=MEM,Z_MEM_ERROR):(n.havedict=1,Z_OK))}inflate$3.inflateReset=inflateReset,inflate$3.inflateReset2=inflateReset2,inflate$3.inflateResetKeep=inflateResetKeep,inflate$3.inflateInit=inflateInit,inflate$3.inflateInit2=inflateInit2,inflate$3.inflate=inflate$2,inflate$3.inflateEnd=inflateEnd,inflate$3.inflateGetHeader=inflateGetHeader,inflate$3.inflateSetDictionary=inflateSetDictionary,inflate$3.inflateInfo="pako inflate (from Nodeca project)";var constants$1={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8};function GZheader$1(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}var gzheader=GZheader$1,zlib_inflate=inflate$3,utils=common,strings=strings$2,c=constants$1,msg=messages,ZStream=zstream,GZheader=gzheader,toString=Object.prototype.toString;function Inflate(t){if(!(this instanceof Inflate))return new Inflate(t);this.options=utils.assign({chunkSize:16384,windowBits:0,to:""},t||{});var e=this.options;e.raw&&e.windowBits>=0&&e.windowBits<16&&(e.windowBits=-e.windowBits,e.windowBits===0&&(e.windowBits=-15)),e.windowBits>=0&&e.windowBits<16&&!(t&&t.windowBits)&&(e.windowBits+=32),e.windowBits>15&&e.windowBits<48&&(e.windowBits&15||(e.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new ZStream,this.strm.avail_out=0;var r=zlib_inflate.inflateInit2(this.strm,e.windowBits);if(r!==c.Z_OK)throw new Error(msg[r]);if(this.header=new GZheader,zlib_inflate.inflateGetHeader(this.strm,this.header),e.dictionary&&(typeof e.dictionary=="string"?e.dictionary=strings.string2buf(e.dictionary):toString.call(e.dictionary)==="[object ArrayBuffer]"&&(e.dictionary=new Uint8Array(e.dictionary)),e.raw&&(r=zlib_inflate.inflateSetDictionary(this.strm,e.dictionary),r!==c.Z_OK)))throw new Error(msg[r])}Inflate.prototype.push=function(t,e){var r=this.strm,n=this.options.chunkSize,a=this.options.dictionary,s,o,h,d,l,u=!1;if(this.ended)return!1;o=e===~~e?e:e===!0?c.Z_FINISH:c.Z_NO_FLUSH,typeof t=="string"?r.input=strings.binstring2buf(t):toString.call(t)==="[object ArrayBuffer]"?r.input=new Uint8Array(t):r.input=t,r.next_in=0,r.avail_in=r.input.length;do{if(r.avail_out===0&&(r.output=new utils.Buf8(n),r.next_out=0,r.avail_out=n),s=zlib_inflate.inflate(r,c.Z_NO_FLUSH),s===c.Z_NEED_DICT&&a&&(s=zlib_inflate.inflateSetDictionary(this.strm,a)),s===c.Z_BUF_ERROR&&u===!0&&(s=c.Z_OK,u=!1),s!==c.Z_STREAM_END&&s!==c.Z_OK)return this.onEnd(s),this.ended=!0,!1;r.next_out&&(r.avail_out===0||s===c.Z_STREAM_END||r.avail_in===0&&(o===c.Z_FINISH||o===c.Z_SYNC_FLUSH))&&(this.options.to==="string"?(h=strings.utf8border(r.output,r.next_out),d=r.next_out-h,l=strings.buf2string(r.output,h),r.next_out=d,r.avail_out=n-d,d&&utils.arraySet(r.output,r.output,h,d,0),this.onData(l)):this.onData(utils.shrinkBuf(r.output,r.next_out))),r.avail_in===0&&r.avail_out===0&&(u=!0)}while((r.avail_in>0||r.avail_out===0)&&s!==c.Z_STREAM_END);return s===c.Z_STREAM_END&&(o=c.Z_FINISH),o===c.Z_FINISH?(s=zlib_inflate.inflateEnd(this.strm),this.onEnd(s),this.ended=!0,s===c.Z_OK):(o===c.Z_SYNC_FLUSH&&(this.onEnd(c.Z_OK),r.avail_out=0),!0)},Inflate.prototype.onData=function(t){this.chunks.push(t)},Inflate.prototype.onEnd=function(t){t===c.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=utils.flattenChunks(this.chunks)),this.chunks=[],this.err=t,this.msg=this.strm.msg};function inflate$1(t,e){var r=new Inflate(e);if(r.push(t,!0),r.err)throw r.msg||msg[r.err];return r.result}function inflateRaw(t,e){return e=e||{},e.raw=!0,inflate$1(t,e)}inflate$4.Inflate=Inflate,inflate$4.inflate=inflate$1,inflate$4.inflateRaw=inflateRaw,inflate$4.ungzip=inflate$1;var assign=common.assign,deflate=deflate$4,inflate=inflate$4,constants=constants$1,pako$1={};assign(pako$1,deflate,inflate,constants);var pako_1=pako$1;const pako=getDefaultExportFromCjs(pako_1);for(var chars="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",lookup=new Uint8Array(256),i=0;i<chars.length;i++)lookup[chars.charCodeAt(i)]=i;var decodeFromBase64=function(t){var e=t.length*.75,r=t.length,n,a=0,s,o,h,d;t[t.length-1]==="="&&(e--,t[t.length-2]==="="&&e--);var l=new Uint8Array(e);for(n=0;n<r;n+=4)s=lookup[t.charCodeAt(n)],o=lookup[t.charCodeAt(n+1)],h=lookup[t.charCodeAt(n+2)],d=lookup[t.charCodeAt(n+3)],l[a++]=s<<2|o>>4,l[a++]=(o&15)<<4|h>>2,l[a++]=(h&3)<<6|d&63;return l},arrayToString=function(t){for(var e="",r=0;r<t.length;r++)e+=String.fromCharCode(t[r]);return e},decompressJson=function(t){return arrayToString(pako.inflate(decodeFromBase64(t)))},padStart=function(t,e,r){for(var n="",a=0,s=e-t.length;a<s;a++)n+=r;return n+t};const CourierBoldCompressed="eJyFWdtyGjkQ/RVqnnar8Bb4lpg3jEnCxgEvGDtxKg9iphm01oyILrZxKv++mrGd3az6KC8UnNa0+nrUGr5lI11VVLtskF198FaU1Dns9w9OOkf7/ePDrJu90bWbiorCgpH2RpLZO9WqaCReqZ8lnReJqKTa/SwL8DXJctPs9Lxs4oSS+bAuVVjXC7/tG/lAxYV0+SYbOOOpm402w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o3CLhnIJBMFRvMZpqpNBMlQJzGT5WFQMVQI/AikPMIhEU1aDjqJvQwmjSHB05cC9jbYwc5UtAHNLhDw41ha+lEqF4JaH3gmB61SYcqInxTDmQK8v08vjqv4zDf1N0w3Lf4A8/vwPpfK11w==";var compressedJsonForFontName={Courier:CourierCompressed,"Courier-Bold":CourierBoldCompressed,"Courier-Oblique":CourierObliqueCompressed,"Courier-BoldOblique":CourierBoldObliqueCompressed,Helvetica:HelveticaCompressed,"Helvetica-Bold":HelveticaBoldCompressed,"Helvetica-Oblique":HelveticaObliqueCompressed,"Helvetica-BoldOblique":HelveticaBoldObliqueCompressed,"Times-Roman":TimesRomanCompressed,"Times-Bold":TimesBoldCompressed,"Times-Italic":TimesItalicCompressed,"Times-BoldItalic":TimesBoldItalicCompressed,Symbol:SymbolCompressed,ZapfDingbats:ZapfDingbatsCompressed},FontNames;(function(t){t.Courier="Courier",t.CourierBold="Courier-Bold",t.CourierOblique="Courier-Oblique",t.CourierBoldOblique="Courier-BoldOblique",t.Helvetica="Helvetica",t.HelveticaBold="Helvetica-Bold",t.HelveticaOblique="Helvetica-Oblique",t.HelveticaBoldOblique="Helvetica-BoldOblique",t.TimesRoman="Times-Roman",t.TimesRomanBold="Times-Bold",t.TimesRomanItalic="Times-Italic",t.TimesRomanBoldItalic="Times-BoldItalic",t.Symbol="Symbol",t.ZapfDingbats="ZapfDingbats"})(FontNames||(FontNames={}));var fontCache={},Font=function(){function t(){var e=this;this.getWidthOfGlyph=function(r){return e.CharWidths[r]},this.getXAxisKerningForPair=function(r,n){return(e.KernPairXAmounts[r]||{})[n]}}return t.load=function(e){var r=fontCache[e];if(r)return r;var n=decompressJson(compressedJsonForFontName[e]),a=Object.assign(new t,JSON.parse(n));return a.CharWidths=a.CharMetrics.reduce(function(s,o){return s[o.N]=o.WX,s},{}),a.KernPairXAmounts=a.KernPairs.reduce(function(s,o){var h=o[0],d=o[1],l=o[2];return s[h]||(s[h]={}),s[h][d]=l,s},{}),fontCache[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79+u7QT7/ePazrGf+UE7Zk6wf+Mmi8EJ9ocFQnCC/WGBEJxgf3gDgddNNIp/WC3Mb12i24cHXIEfkcs3FzGDM/UPnnJjcKb+cQXOmfrHFThn6h/fgItO1z8+4IjO2P+0LBOdsX9znHgBKUYn7Id+Pkklvh3TCgtpX9DFhbSvll1I+1t0C3NfTBcX5v4IeSHv5sYxX7g7H86dt+/Wbpw7c+8XsLkz934Bmztz79+AzZ2+9w+4cmfww2ptZ/DDam1n8MPbtZ3GDw9rs9ui3KZPblw4tz8vJiuc208LhMK5/bRAKJzbT28gFE7wp9XCTvCnR1zO8ZeLw7Fwjj8tTlw4x78v0Ern+PcFWukc//4GWulE//6AonSu/7paxrn+zZ2YnRclRK/rBXJsCAjxh2cKEAWVJ02ku/wOoFv2+12XkmnODwHgW4uQGVbZ0uM7mAJ1b/68/JlpUMnWdy5MF6/Vd5eL19YYSPd6FqPwBkNQo/h2NQxdQQ3bn/dpCxrGrqCW7U8rKZl/mfi0Xytk3Am66ZhYbg4y+KAVslDwbXdNL2d5qU5hnYBlTZaa6hs2t1qWdaeeTptcLco+hl5R7w4H5uOGcQbtEkpT18GusOI2xT9dYcVJf7zCSjmbD+Iud2s1NPRb9E+0UICmizb8ZK/+5JOLOulSqwaw5VJr2vB8dSFn89fvv/8H0oq1dA==";for(var decompressedEncodings=decompressJson(AllEncodingsCompressed),allUnicodeMappings=JSON.parse(decompressedEncodings),Encoding=function(){function t(e,r){var n=this;this.canEncodeUnicodeCodePoint=function(a){return a in n.unicodeMappings},this.encodeUnicodeCodePoint=function(a){var s=n.unicodeMappings[a];if(!s){var o=String.fromCharCode(a),h="0x"+padStart(a.toString(16),4,"0"),d=n.name+' cannot encode "'+o+'" ('+h+")";throw new Error(d)}return{code:s[0],name:s[1]}},this.name=e,this.supportedCodePoints=Object.keys(r).map(Number).sort(function(a,s){return a-s}),this.unicodeMappings=r}return t}(),Encodings={Symbol:new Encoding("Symbol",allUnicodeMappings.symbol),ZapfDingbats:new Encoding("ZapfDingbats",allUnicodeMappings.zapfdingbats),WinAnsi:new Encoding("WinAnsi",allUnicodeMappings.win1252)},values=function(t){return Object.keys(t).map(function(e){return t[e]})},StandardFontValues=values(FontNames),isStandardFont=function(t){return StandardFontValues.includes(t)},rectanglesAreEqual=function(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height},backtick=function(t){return"`"+t+"`"},singleQuote=function(t){return"'"+t+"'"},formatValue=function(t){var e=typeof t;return e==="string"?singleQuote(t):e==="undefined"?backtick(t):t},createValueErrorMsg=function(t,e,r){for(var n=new Array(r.length),a=0,s=r.length;a<s;a++){var o=r[a];n[a]=formatValue(o)}var h=n.join(" or ");return backtick(e)+" must be one of "+h+", but was actually "+formatValue(t)},assertIsOneOf=function(t,e,r){Array.isArray(r)||(r=values(r));for(var n=0,a=r.length;n<a;n++)if(t===r[n])return;throw new TypeError(createValueErrorMsg(t,e,r))},assertIsOneOfOrUndefined=function(t,e,r){Array.isArray(r)||(r=values(r)),assertIsOneOf(t,e,r.concat(void 0))},assertIsSubset=function(t,e,r){Array.isArray(r)||(r=values(r));for(var n=0,a=t.length;n<a;n++)assertIsOneOf(t[n],e,r)},getType=function(t){return t===null?"null":t===void 0?"undefined":typeof t=="string"?"string":isNaN(t)?"NaN":typeof t=="number"?"number":typeof t=="boolean"?"boolean":typeof t=="symbol"?"symbol":typeof t=="bigint"?"bigint":t.constructor&&t.constructor.name?t.constructor.name:t.name?t.name:t.constructor?String(t.constructor):String(t)},isType=function(t,e){return e==="null"?t===null:e==="undefined"?t===void 0:e==="string"?typeof t=="string":e==="number"?typeof t=="number"&&!isNaN(t):e==="boolean"?typeof t=="boolean":e==="symbol"?typeof t=="symbol":e==="bigint"?typeof t=="bigint":e===Date?t instanceof Date:e===Array?t instanceof Array:e===Uint8Array?t instanceof Uint8Array:e===ArrayBuffer?t instanceof ArrayBuffer:e===Function?t instanceof Function:t instanceof e[0]},createTypeErrorMsg=function(t,e,r){for(var n=new Array(r.length),a=0,s=r.length;a<s;a++){var o=r[a];o==="null"&&(n[a]=backtick("null")),o==="undefined"&&(n[a]=backtick("undefined")),o==="string"?n[a]=backtick("string"):o==="number"?n[a]=backtick("number"):o==="boolean"?n[a]=backtick("boolean"):o==="symbol"?n[a]=backtick("symbol"):o==="bigint"?n[a]=backtick("bigint"):o===Array?n[a]=backtick("Array"):o===Uint8Array?n[a]=backtick("Uint8Array"):o===ArrayBuffer?n[a]=backtick("ArrayBuffer"):n[a]=backtick(o[1])}var h=n.join(" or ");return backtick(e)+" must be of type "+h+", but was actually of type "+backtick(getType(t))},assertIs=function(t,e,r){for(var n=0,a=r.length;n<a;n++)if(isType(t,r[n]))return;throw new TypeError(createTypeErrorMsg(t,e,r))},assertOrUndefined=function(t,e,r){assertIs(t,e,r.concat("undefined"))},assertEachIs=function(t,e,r){for(var n=0,a=t.length;n<a;n++)assertIs(t[n],e,r)},assertRange=function(t,e,r,n){if(assertIs(t,e,["number"]),assertIs(r,"min",["number"]),assertIs(n,"max",["number"]),n=Math.max(r,n),t<r||t>n)throw new Error(backtick(e)+" must be at least "+r+" and at most "+n+", but was actually "+t)},assertRangeOrUndefined=function(t,e,r,n){assertIs(t,e,["number","undefined"]),typeof t=="number"&&assertRange(t,e,r,n)},assertMultiple=function(t,e,r){if(assertIs(t,e,["number"]),t%r!==0)throw new Error(backtick(e)+" must be a multiple of "+r+", but was actually "+t)},assertInteger=function(t,e){if(!Number.isInteger(t))throw new Error(backtick(e)+" must be an integer, but was actually "+t)},assertPositive=function(t,e){if(![1,0].includes(Math.sign(t)))throw new Error(backtick(e)+" must be a positive number or 0, but was actually "+t)},pdfDocEncodingToUnicode=new Uint16Array(256),idx$2=0;idx$2<256;idx$2++)pdfDocEncodingToUnicode[idx$2]=idx$2;pdfDocEncodingToUnicode[22]=toCharCode(""),pdfDocEncodingToUnicode[24]=toCharCode("˘"),pdfDocEncodingToUnicode[25]=toCharCode("ˇ"),pdfDocEncodingToUnicode[26]=toCharCode("ˆ"),pdfDocEncodingToUnicode[27]=toCharCode("˙"),pdfDocEncodingToUnicode[28]=toCharCode("˝"),pdfDocEncodingToUnicode[29]=toCharCode("˛"),pdfDocEncodingToUnicode[30]=toCharCode("˚"),pdfDocEncodingToUnicode[31]=toCharCode("˜"),pdfDocEncodingToUnicode[127]=toCharCode("�"),pdfDocEncodingToUnicode[128]=toCharCode("•"),pdfDocEncodingToUnicode[129]=toCharCode("†"),pdfDocEncodingToUnicode[130]=toCharCode("‡"),pdfDocEncodingToUnicode[131]=toCharCode("…"),pdfDocEncodingToUnicode[132]=toCharCode("—"),pdfDocEncodingToUnicode[133]=toCharCode("–"),pdfDocEncodingToUnicode[134]=toCharCode("ƒ"),pdfDocEncodingToUnicode[135]=toCharCode("⁄"),pdfDocEncodingToUnicode[136]=toCharCode("‹"),pdfDocEncodingToUnicode[137]=toCharCode("›"),pdfDocEncodingToUnicode[138]=toCharCode("−"),pdfDocEncodingToUnicode[139]=toCharCode("‰"),pdfDocEncodingToUnicode[140]=toCharCode("„"),pdfDocEncodingToUnicode[141]=toCharCode("“"),pdfDocEncodingToUnicode[142]=toCharCode("”"),pdfDocEncodingToUnicode[143]=toCharCode("‘"),pdfDocEncodingToUnicode[144]=toCharCode("’"),pdfDocEncodingToUnicode[145]=toCharCode("‚"),pdfDocEncodingToUnicode[146]=toCharCode("™"),pdfDocEncodingToUnicode[147]=toCharCode("fi"),pdfDocEncodingToUnicode[148]=toCharCode("fl"),pdfDocEncodingToUnicode[149]=toCharCode("Ł"),pdfDocEncodingToUnicode[150]=toCharCode("Œ"),pdfDocEncodingToUnicode[151]=toCharCode("Š"),pdfDocEncodingToUnicode[152]=toCharCode("Ÿ"),pdfDocEncodingToUnicode[153]=toCharCode("Ž"),pdfDocEncodingToUnicode[154]=toCharCode("ı"),pdfDocEncodingToUnicode[155]=toCharCode("ł"),pdfDocEncodingToUnicode[156]=toCharCode("œ"),pdfDocEncodingToUnicode[157]=toCharCode("š"),pdfDocEncodingToUnicode[158]=toCharCode("ž"),pdfDocEncodingToUnicode[159]=toCharCode("�"),pdfDocEncodingToUnicode[160]=toCharCode("€"),pdfDocEncodingToUnicode[173]=toCharCode("�");var pdfDocEncodingDecode=function(t){for(var e=new Array(t.length),r=0,n=t.length;r<n;r++)e[r]=pdfDocEncodingToUnicode[t[r]];return String.fromCodePoint.apply(String,e)},Cache=function(){function t(e){this.populate=e,this.value=void 0}return t.prototype.getValue=function(){return this.value},t.prototype.access=function(){return this.value||(this.value=this.populate()),this.value},t.prototype.invalidate=function(){this.value=void 0},t.populatedBy=function(e){return new t(e)},t}(),MethodNotImplementedError=function(t){__extends(e,t);function e(r,n){var a=this,s="Method "+r+"."+n+"() not implemented";return a=t.call(this,s)||this,a}return e}(Error),PrivateConstructorError=function(t){__extends(e,t);function e(r){var n=this,a="Cannot construct "+r+" - it has a private constructor";return n=t.call(this,a)||this,n}return e}(Error),UnexpectedObjectTypeError=function(t){__extends(e,t);function e(r,n){var a=this,s=function(d){var l,u;return(l=d==null?void 0:d.name)!==null&&l!==void 0?l:(u=d==null?void 0:d.constructor)===null||u===void 0?void 0:u.name},o=Array.isArray(r)?r.map(s):[s(r)],h="Expected instance of "+o.join(" or ")+", "+("but got instance of "+(n&&s(n)));return a=t.call(this,h)||this,a}return e}(Error),UnsupportedEncodingError=function(t){__extends(e,t);function e(r){var n=this,a=r+" stream encoding not supported";return n=t.call(this,a)||this,n}return e}(Error),ReparseError=function(t){__extends(e,t);function e(r,n){var a=this,s="Cannot call "+r+"."+n+"() more than once";return a=t.call(this,s)||this,a}return e}(Error);(function(t){__extends(e,t);function e(r){var n=this,a="Missing catalog (ref="+r+")";return n=t.call(this,a)||this,n}return e})(Error);var MissingPageContentsEmbeddingError=function(t){__extends(e,t);function e(){var r=this,n="Can't embed page with missing Contents";return r=t.call(this,n)||this,r}return e}(Error),UnrecognizedStreamTypeError=function(t){__extends(e,t);function e(r){var n,a,s,o=this,h=(s=(a=(n=r==null?void 0:r.contructor)===null||n===void 0?void 0:n.name)!==null&&a!==void 0?a:r==null?void 0:r.name)!==null&&s!==void 0?s:r,d="Unrecognized stream type: "+h;return o=t.call(this,d)||this,o}return e}(Error),PageEmbeddingMismatchedContextError=function(t){__extends(e,t);function e(){var r=this,n="Found mismatched contexts while embedding pages. All pages in the array passed to `PDFDocument.embedPages()` must be from the same document.";return r=t.call(this,n)||this,r}return e}(Error),PDFArrayIsNotRectangleError=function(t){__extends(e,t);function e(r){var n=this,a="Attempted to convert PDFArray with "+r+" elements to rectangle, but must have exactly 4 elements.";return n=t.call(this,a)||this,n}return e}(Error),InvalidPDFDateStringError=function(t){__extends(e,t);function e(r){var n=this,a='Attempted to convert "'+r+'" to a date, but it does not match the PDF date string format.';return n=t.call(this,a)||this,n}return e}(Error),InvalidTargetIndexError=function(t){__extends(e,t);function e(r,n){var a=this,s="Invalid targetIndex specified: targetIndex="+r+" must be less than Count="+n;return a=t.call(this,s)||this,a}return e}(Error),CorruptPageTreeError=function(t){__extends(e,t);function e(r,n){var a=this,s="Failed to "+n+" at targetIndex="+r+" due to corrupt page tree: It is likely that one or more 'Count' entries are invalid";return a=t.call(this,s)||this,a}return e}(Error),IndexOutOfBoundsError=function(t){__extends(e,t);function e(r,n,a){var s=this,o="index should be at least "+n+" and at most "+a+", but was actually "+r;return s=t.call(this,o)||this,s}return e}(Error),InvalidAcroFieldValueError=function(t){__extends(e,t);function e(){var r=this,n="Attempted to set invalid field value";return r=t.call(this,n)||this,r}return e}(Error),MultiSelectValueError=function(t){__extends(e,t);function e(){var r=this,n="Attempted to select multiple values for single-select field";return r=t.call(this,n)||this,r}return e}(Error),MissingDAEntryError=function(t){__extends(e,t);function e(r){var n=this,a="No /DA (default appearance) entry found for field: "+r;return n=t.call(this,a)||this,n}return e}(Error),MissingTfOperatorError=function(t){__extends(e,t);function e(r){var n=this,a="No Tf operator found for DA of field: "+r;return n=t.call(this,a)||this,n}return e}(Error),NumberParsingError=function(t){__extends(e,t);function e(r,n){var a=this,s="Failed to parse number "+("(line:"+r.line+" col:"+r.column+" offset="+r.offset+'): "'+n+'"');return a=t.call(this,s)||this,a}return e}(Error),PDFParsingError=function(t){__extends(e,t);function e(r,n){var a=this,s="Failed to parse PDF document "+("(line:"+r.line+" col:"+r.column+" offset="+r.offset+"): "+n);return a=t.call(this,s)||this,a}return e}(Error),NextByteAssertionError=function(t){__extends(e,t);function e(r,n,a){var s=this,o="Expected next byte to be "+n+" but it was actually "+a;return s=t.call(this,r,o)||this,s}return e}(PDFParsingError),PDFObjectParsingError=function(t){__extends(e,t);function e(r,n){var a=this,s="Failed to parse PDF object starting with the following byte: "+n;return a=t.call(this,r,s)||this,a}return e}(PDFParsingError),PDFInvalidObjectParsingError=function(t){__extends(e,t);function e(r){var n=this,a="Failed to parse invalid PDF object";return n=t.call(this,r,a)||this,n}return e}(PDFParsingError),PDFStreamParsingError=function(t){__extends(e,t);function e(r){var n=this,a="Failed to parse PDF stream";return n=t.call(this,r,a)||this,n}return e}(PDFParsingError),UnbalancedParenthesisError=function(t){__extends(e,t);function e(r){var n=this,a="Failed to parse PDF literal string due to unbalanced parenthesis";return n=t.call(this,r,a)||this,n}return e}(PDFParsingError),StalledParserError=function(t){__extends(e,t);function e(r){var n=this,a="Parser stalled";return n=t.call(this,r,a)||this,n}return e}(PDFParsingError),MissingPDFHeaderError=function(t){__extends(e,t);function e(r){var n=this,a="No PDF header found";return n=t.call(this,r,a)||this,n}return e}(PDFParsingError),MissingKeywordError=function(t){__extends(e,t);function e(r,n){var a=this,s="Did not find expected keyword '"+arrayAsString(n)+"'";return a=t.call(this,r,s)||this,a}return e}(PDFParsingError),CharCodes$1;(function(t){t[t.Null=0]="Null",t[t.Backspace=8]="Backspace",t[t.Tab=9]="Tab",t[t.Newline=10]="Newline",t[t.FormFeed=12]="FormFeed",t[t.CarriageReturn=13]="CarriageReturn",t[t.Space=32]="Space",t[t.ExclamationPoint=33]="ExclamationPoint",t[t.Hash=35]="Hash",t[t.Percent=37]="Percent",t[t.LeftParen=40]="LeftParen",t[t.RightParen=41]="RightParen",t[t.Plus=43]="Plus",t[t.Minus=45]="Minus",t[t.Dash=45]="Dash",t[t.Period=46]="Period",t[t.ForwardSlash=47]="ForwardSlash",t[t.Zero=48]="Zero",t[t.One=49]="One",t[t.Two=50]="Two",t[t.Three=51]="Three",t[t.Four=52]="Four",t[t.Five=53]="Five",t[t.Six=54]="Six",t[t.Seven=55]="Seven",t[t.Eight=56]="Eight",t[t.Nine=57]="Nine",t[t.LessThan=60]="LessThan",t[t.GreaterThan=62]="GreaterThan",t[t.A=65]="A",t[t.D=68]="D",t[t.E=69]="E",t[t.F=70]="F",t[t.O=79]="O",t[t.P=80]="P",t[t.R=82]="R",t[t.LeftSquareBracket=91]="LeftSquareBracket",t[t.BackSlash=92]="BackSlash",t[t.RightSquareBracket=93]="RightSquareBracket",t[t.a=97]="a",t[t.b=98]="b",t[t.d=100]="d",t[t.e=101]="e",t[t.f=102]="f",t[t.i=105]="i",t[t.j=106]="j",t[t.l=108]="l",t[t.m=109]="m",t[t.n=110]="n",t[t.o=111]="o",t[t.r=114]="r",t[t.s=115]="s",t[t.t=116]="t",t[t.u=117]="u",t[t.x=120]="x",t[t.LeftCurly=123]="LeftCurly",t[t.RightCurly=125]="RightCurly",t[t.Tilde=126]="Tilde"})(CharCodes$1||(CharCodes$1={}));const CharCodes=CharCodes$1;var PDFHeader=function(){function t(e,r){this.major=String(e),this.minor=String(r)}return t.prototype.toString=function(){var e=charFromCode(129);return"%PDF-"+this.major+"."+this.minor+`
|
|
24
24
|
%`+e+e+e+e},t.prototype.sizeInBytes=function(){return 12+this.major.length+this.minor.length},t.prototype.copyBytesInto=function(e,r){var n=r;return e[r++]=CharCodes.Percent,e[r++]=CharCodes.P,e[r++]=CharCodes.D,e[r++]=CharCodes.F,e[r++]=CharCodes.Dash,r+=copyStringIntoBuffer(this.major,e,r),e[r++]=CharCodes.Period,r+=copyStringIntoBuffer(this.minor,e,r),e[r++]=CharCodes.Newline,e[r++]=CharCodes.Percent,e[r++]=129,e[r++]=129,e[r++]=129,e[r++]=129,r-n},t.forVersion=function(e,r){return new t(e,r)},t}(),PDFObject=function(){function t(){}return t.prototype.clone=function(e){throw new MethodNotImplementedError(this.constructor.name,"clone")},t.prototype.toString=function(){throw new MethodNotImplementedError(this.constructor.name,"toString")},t.prototype.sizeInBytes=function(){throw new MethodNotImplementedError(this.constructor.name,"sizeInBytes")},t.prototype.copyBytesInto=function(e,r){throw new MethodNotImplementedError(this.constructor.name,"copyBytesInto")},t}(),PDFNumber=function(t){__extends(e,t);function e(r){var n=t.call(this)||this;return n.numberValue=r,n.stringValue=numberToString(r),n}return e.prototype.asNumber=function(){return this.numberValue},e.prototype.value=function(){return this.numberValue},e.prototype.clone=function(){return e.of(this.numberValue)},e.prototype.toString=function(){return this.stringValue},e.prototype.sizeInBytes=function(){return this.stringValue.length},e.prototype.copyBytesInto=function(r,n){return n+=copyStringIntoBuffer(this.stringValue,r,n),this.stringValue.length},e.of=function(r){return new e(r)},e}(PDFObject),PDFArray=function(t){__extends(e,t);function e(r){var n=t.call(this)||this;return n.array=[],n.context=r,n}return e.prototype.size=function(){return this.array.length},e.prototype.push=function(r){this.array.push(r)},e.prototype.insert=function(r,n){this.array.splice(r,0,n)},e.prototype.indexOf=function(r){var n=this.array.indexOf(r);return n===-1?void 0:n},e.prototype.remove=function(r){this.array.splice(r,1)},e.prototype.set=function(r,n){this.array[r]=n},e.prototype.get=function(r){return this.array[r]},e.prototype.lookupMaybe=function(r){for(var n,a=[],s=1;s<arguments.length;s++)a[s-1]=arguments[s];return(n=this.context).lookupMaybe.apply(n,__spreadArrays([this.get(r)],a))},e.prototype.lookup=function(r){for(var n,a=[],s=1;s<arguments.length;s++)a[s-1]=arguments[s];return(n=this.context).lookup.apply(n,__spreadArrays([this.get(r)],a))},e.prototype.asRectangle=function(){if(this.size()!==4)throw new PDFArrayIsNotRectangleError(this.size());var r=this.lookup(0,PDFNumber).asNumber(),n=this.lookup(1,PDFNumber).asNumber(),a=this.lookup(2,PDFNumber).asNumber(),s=this.lookup(3,PDFNumber).asNumber(),o=r,h=n,d=a-r,l=s-n;return{x:o,y:h,width:d,height:l}},e.prototype.asArray=function(){return this.array.slice()},e.prototype.clone=function(r){for(var n=e.withContext(r||this.context),a=0,s=this.size();a<s;a++)n.push(this.array[a]);return n},e.prototype.toString=function(){for(var r="[ ",n=0,a=this.size();n<a;n++)r+=this.get(n).toString(),r+=" ";return r+="]",r},e.prototype.sizeInBytes=function(){for(var r=3,n=0,a=this.size();n<a;n++)r+=this.get(n).sizeInBytes()+1;return r},e.prototype.copyBytesInto=function(r,n){var a=n;r[n++]=CharCodes.LeftSquareBracket,r[n++]=CharCodes.Space;for(var s=0,o=this.size();s<o;s++)n+=this.get(s).copyBytesInto(r,n),r[n++]=CharCodes.Space;return r[n++]=CharCodes.RightSquareBracket,n-a},e.prototype.scalePDFNumbers=function(r,n){for(var a=0,s=this.size();a<s;a++){var o=this.lookup(a);if(o instanceof PDFNumber){var h=a%2===0?r:n;this.set(a,PDFNumber.of(o.asNumber()*h))}}},e.withContext=function(r){return new e(r)},e}(PDFObject),ENFORCER$2={},PDFBool=function(t){__extends(e,t);function e(r,n){var a=this;if(r!==ENFORCER$2)throw new PrivateConstructorError("PDFBool");return a=t.call(this)||this,a.value=n,a}return e.prototype.asBoolean=function(){return this.value},e.prototype.clone=function(){return this},e.prototype.toString=function(){return String(this.value)},e.prototype.sizeInBytes=function(){return this.value?4:5},e.prototype.copyBytesInto=function(r,n){return this.value?(r[n++]=CharCodes.t,r[n++]=CharCodes.r,r[n++]=CharCodes.u,r[n++]=CharCodes.e,4):(r[n++]=CharCodes.f,r[n++]=CharCodes.a,r[n++]=CharCodes.l,r[n++]=CharCodes.s,r[n++]=CharCodes.e,5)},e.True=new e(ENFORCER$2,!0),e.False=new e(ENFORCER$2,!1),e}(PDFObject),IsDelimiter=new Uint8Array(256);IsDelimiter[CharCodes.LeftParen]=1,IsDelimiter[CharCodes.RightParen]=1,IsDelimiter[CharCodes.LessThan]=1,IsDelimiter[CharCodes.GreaterThan]=1,IsDelimiter[CharCodes.LeftSquareBracket]=1,IsDelimiter[CharCodes.RightSquareBracket]=1,IsDelimiter[CharCodes.LeftCurly]=1,IsDelimiter[CharCodes.RightCurly]=1,IsDelimiter[CharCodes.ForwardSlash]=1,IsDelimiter[CharCodes.Percent]=1;var IsWhitespace=new Uint8Array(256);IsWhitespace[CharCodes.Null]=1,IsWhitespace[CharCodes.Tab]=1,IsWhitespace[CharCodes.Newline]=1,IsWhitespace[CharCodes.FormFeed]=1,IsWhitespace[CharCodes.CarriageReturn]=1,IsWhitespace[CharCodes.Space]=1;for(var IsIrregular=new Uint8Array(256),idx$1=0,len$1=256;idx$1<len$1;idx$1++)IsIrregular[idx$1]=IsWhitespace[idx$1]||IsDelimiter[idx$1]?1:0;IsIrregular[CharCodes.Hash]=1;var decodeName=function(t){return t.replace(/#([\dABCDEF]{2})/g,function(e,r){return charFromHexCode(r)})},isRegularChar=function(t){return t>=CharCodes.ExclamationPoint&&t<=CharCodes.Tilde&&!IsIrregular[t]},ENFORCER$1={},pool$1=new Map,PDFName=function(t){__extends(e,t);function e(r,n){var a=this;if(r!==ENFORCER$1)throw new PrivateConstructorError("PDFName");a=t.call(this)||this;for(var s="/",o=0,h=n.length;o<h;o++){var d=n[o],l=toCharCode(d);s+=isRegularChar(l)?d:"#"+toHexString(l)}return a.encodedName=s,a}return e.prototype.asBytes=function(){for(var r=[],n="",a=!1,s=function(p){p!==void 0&&r.push(p),a=!1},o=1,h=this.encodedName.length;o<h;o++){var d=this.encodedName[o],l=toCharCode(d),u=this.encodedName[o+1];a?l>=CharCodes.Zero&&l<=CharCodes.Nine||l>=CharCodes.a&&l<=CharCodes.f||l>=CharCodes.A&&l<=CharCodes.F?(n+=d,(n.length===2||!(u>="0"&&u<="9"||u>="a"&&u<="f"||u>="A"&&u<="F"))&&(s(parseInt(n,16)),n="")):s(l):l===CharCodes.Hash?a=!0:s(l)}return new Uint8Array(r)},e.prototype.decodeText=function(){var r=this.asBytes();return String.fromCharCode.apply(String,Array.from(r))},e.prototype.asString=function(){return this.encodedName},e.prototype.value=function(){return this.encodedName},e.prototype.clone=function(){return this},e.prototype.toString=function(){return this.encodedName},e.prototype.sizeInBytes=function(){return this.encodedName.length},e.prototype.copyBytesInto=function(r,n){return n+=copyStringIntoBuffer(this.encodedName,r,n),this.encodedName.length},e.of=function(r){var n=decodeName(r),a=pool$1.get(n);return a||(a=new e(ENFORCER$1,n),pool$1.set(n,a)),a},e.Length=e.of("Length"),e.FlateDecode=e.of("FlateDecode"),e.Resources=e.of("Resources"),e.Font=e.of("Font"),e.XObject=e.of("XObject"),e.ExtGState=e.of("ExtGState"),e.Contents=e.of("Contents"),e.Type=e.of("Type"),e.Parent=e.of("Parent"),e.MediaBox=e.of("MediaBox"),e.Page=e.of("Page"),e.Annots=e.of("Annots"),e.TrimBox=e.of("TrimBox"),e.ArtBox=e.of("ArtBox"),e.BleedBox=e.of("BleedBox"),e.CropBox=e.of("CropBox"),e.Rotate=e.of("Rotate"),e.Title=e.of("Title"),e.Author=e.of("Author"),e.Subject=e.of("Subject"),e.Creator=e.of("Creator"),e.Keywords=e.of("Keywords"),e.Producer=e.of("Producer"),e.CreationDate=e.of("CreationDate"),e.ModDate=e.of("ModDate"),e}(PDFObject),PDFNull$1=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.asNull=function(){return null},e.prototype.clone=function(){return this},e.prototype.toString=function(){return"null"},e.prototype.sizeInBytes=function(){return 4},e.prototype.copyBytesInto=function(r,n){return r[n++]=CharCodes.n,r[n++]=CharCodes.u,r[n++]=CharCodes.l,r[n++]=CharCodes.l,4},e}(PDFObject);const PDFNull=new PDFNull$1;var PDFDict=function(t){__extends(e,t);function e(r,n){var a=t.call(this)||this;return a.dict=r,a.context=n,a}return e.prototype.keys=function(){return Array.from(this.dict.keys())},e.prototype.values=function(){return Array.from(this.dict.values())},e.prototype.entries=function(){return Array.from(this.dict.entries())},e.prototype.set=function(r,n){this.dict.set(r,n)},e.prototype.get=function(r,n){n===void 0&&(n=!1);var a=this.dict.get(r);if(!(a===PDFNull&&!n))return a},e.prototype.has=function(r){var n=this.dict.get(r);return n!==void 0&&n!==PDFNull},e.prototype.lookupMaybe=function(r){for(var n,a=[],s=1;s<arguments.length;s++)a[s-1]=arguments[s];var o=a.includes(PDFNull),h=(n=this.context).lookupMaybe.apply(n,__spreadArrays([this.get(r,o)],a));if(!(h===PDFNull&&!o))return h},e.prototype.lookup=function(r){for(var n,a=[],s=1;s<arguments.length;s++)a[s-1]=arguments[s];var o=a.includes(PDFNull),h=(n=this.context).lookup.apply(n,__spreadArrays([this.get(r,o)],a));if(!(h===PDFNull&&!o))return h},e.prototype.delete=function(r){return this.dict.delete(r)},e.prototype.asMap=function(){return new Map(this.dict)},e.prototype.uniqueKey=function(r){r===void 0&&(r="");for(var n=this.keys(),a=PDFName.of(this.context.addRandomSuffix(r,10));n.includes(a);)a=PDFName.of(this.context.addRandomSuffix(r,10));return a},e.prototype.clone=function(r){for(var n=e.withContext(r||this.context),a=this.entries(),s=0,o=a.length;s<o;s++){var h=a[s],d=h[0],l=h[1];n.set(d,l)}return n},e.prototype.toString=function(){for(var r=`<<
|
|
25
25
|
`,n=this.entries(),a=0,s=n.length;a<s;a++){var o=n[a],h=o[0],d=o[1];r+=h.toString()+" "+d.toString()+`
|
|
26
26
|
`}return r+=">>",r},e.prototype.sizeInBytes=function(){for(var r=5,n=this.entries(),a=0,s=n.length;a<s;a++){var o=n[a],h=o[0],d=o[1];r+=h.sizeInBytes()+d.sizeInBytes()+2}return r},e.prototype.copyBytesInto=function(r,n){var a=n;r[n++]=CharCodes.LessThan,r[n++]=CharCodes.LessThan,r[n++]=CharCodes.Newline;for(var s=this.entries(),o=0,h=s.length;o<h;o++){var d=s[o],l=d[0],u=d[1];n+=l.copyBytesInto(r,n),r[n++]=CharCodes.Space,n+=u.copyBytesInto(r,n),r[n++]=CharCodes.Newline}return r[n++]=CharCodes.GreaterThan,r[n++]=CharCodes.GreaterThan,n-a},e.withContext=function(r){return new e(new Map,r)},e.fromMapWithContext=function(r,n){return new e(r,n)},e}(PDFObject),PDFStream=function(t){__extends(e,t);function e(r){var n=t.call(this)||this;return n.dict=r,n}return e.prototype.clone=function(r){throw new MethodNotImplementedError(this.constructor.name,"clone")},e.prototype.getContentsString=function(){throw new MethodNotImplementedError(this.constructor.name,"getContentsString")},e.prototype.getContents=function(){throw new MethodNotImplementedError(this.constructor.name,"getContents")},e.prototype.getContentsSize=function(){throw new MethodNotImplementedError(this.constructor.name,"getContentsSize")},e.prototype.updateDict=function(){var r=this.getContentsSize();this.dict.set(PDFName.Length,PDFNumber.of(r))},e.prototype.sizeInBytes=function(){return this.updateDict(),this.dict.sizeInBytes()+this.getContentsSize()+18},e.prototype.toString=function(){this.updateDict();var r=this.dict.toString();return r+=`
|
|
@@ -34,7 +34,7 @@ endstream`,r},e.prototype.copyBytesInto=function(r,n){this.updateDict();var a=n;
|
|
|
34
34
|
`+this.lastXRefOffset+`
|
|
35
35
|
%%EOF`},t.prototype.sizeInBytes=function(){return 16+this.lastXRefOffset.length},t.prototype.copyBytesInto=function(e,r){var n=r;return e[r++]=CharCodes.s,e[r++]=CharCodes.t,e[r++]=CharCodes.a,e[r++]=CharCodes.r,e[r++]=CharCodes.t,e[r++]=CharCodes.x,e[r++]=CharCodes.r,e[r++]=CharCodes.e,e[r++]=CharCodes.f,e[r++]=CharCodes.Newline,r+=copyStringIntoBuffer(this.lastXRefOffset,e,r),e[r++]=CharCodes.Newline,e[r++]=CharCodes.Percent,e[r++]=CharCodes.Percent,e[r++]=CharCodes.E,e[r++]=CharCodes.O,e[r++]=CharCodes.F,r-n},t.forLastCrossRefSectionOffset=function(e){return new t(e)},t}(),PDFTrailerDict=function(){function t(e){this.dict=e}return t.prototype.toString=function(){return`trailer
|
|
36
36
|
`+this.dict.toString()},t.prototype.sizeInBytes=function(){return 8+this.dict.sizeInBytes()},t.prototype.copyBytesInto=function(e,r){var n=r;return e[r++]=CharCodes.t,e[r++]=CharCodes.r,e[r++]=CharCodes.a,e[r++]=CharCodes.i,e[r++]=CharCodes.l,e[r++]=CharCodes.e,e[r++]=CharCodes.r,e[r++]=CharCodes.Newline,r+=this.dict.copyBytesInto(e,r),r-n},t.of=function(e){return new t(e)},t}(),PDFObjectStream=function(t){__extends(e,t);function e(r,n,a){a===void 0&&(a=!0);var s=t.call(this,r.obj({}),a)||this;return s.objects=n,s.offsets=s.computeObjectOffsets(),s.offsetsString=s.computeOffsetsString(),s.dict.set(PDFName.of("Type"),PDFName.of("ObjStm")),s.dict.set(PDFName.of("N"),PDFNumber.of(s.objects.length)),s.dict.set(PDFName.of("First"),PDFNumber.of(s.offsetsString.length)),s}return e.prototype.getObjectsCount=function(){return this.objects.length},e.prototype.clone=function(r){return e.withContextAndObjects(r||this.dict.context,this.objects.slice(),this.encode)},e.prototype.getContentsString=function(){for(var r=this.offsetsString,n=0,a=this.objects.length;n<a;n++){var s=this.objects[n],o=s[1];r+=o+`
|
|
37
|
-
`}return r},e.prototype.getUnencodedContents=function(){for(var r=new Uint8Array(this.getUnencodedContentsSize()),n=copyStringIntoBuffer(this.offsetsString,r,0),a=0,s=this.objects.length;a<s;a++){var o=this.objects[a],h=o[1];n+=h.copyBytesInto(r,n),r[n++]=CharCodes.Newline}return r},e.prototype.getUnencodedContentsSize=function(){return this.offsetsString.length+last(this.offsets)[1]+last(this.objects)[1].sizeInBytes()+1},e.prototype.computeOffsetsString=function(){for(var r="",n=0,a=this.offsets.length;n<a;n++){var s=this.offsets[n],o=s[0],h=s[1];r+=o+" "+h+" "}return r},e.prototype.computeObjectOffsets=function(){for(var r=0,n=new Array(this.objects.length),a=0,s=this.objects.length;a<s;a++){var o=this.objects[a],h=o[0],d=o[1];n[a]=[h.objectNumber,r],r+=d.sizeInBytes()+1}return n},e.withContextAndObjects=function(r,n,a){return a===void 0&&(a=!0),new e(r,n,a)},e}(PDFFlateStream),PDFWriter=function(){function t(e,r){var n=this;this.parsedObjects=0,this.shouldWaitForTick=function(a){return n.parsedObjects+=a,n.parsedObjects%n.objectsPerTick===0},this.context=e,this.objectsPerTick=r}return t.prototype.serializeToBuffer=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n,a,s,o,h,d,l,u,p,g,f,v,y,x,m;return __generator(this,function(w){switch(w.label){case 0:return[4,this.computeBufferSize()];case 1:e=w.sent(),r=e.size,n=e.header,a=e.indirectObjects,s=e.xref,o=e.trailerDict,h=e.trailer,d=0,l=new Uint8Array(r),d+=n.copyBytesInto(l,d),l[d++]=CharCodes.Newline,l[d++]=CharCodes.Newline,u=0,p=a.length,w.label=2;case 2:return u<p?(g=a[u],f=g[0],v=g[1],y=String(f.objectNumber),d+=copyStringIntoBuffer(y,l,d),l[d++]=CharCodes.Space,x=String(f.generationNumber),d+=copyStringIntoBuffer(x,l,d),l[d++]=CharCodes.Space,l[d++]=CharCodes.o,l[d++]=CharCodes.b,l[d++]=CharCodes.j,l[d++]=CharCodes.Newline,d+=v.copyBytesInto(l,d),l[d++]=CharCodes.Newline,l[d++]=CharCodes.e,l[d++]=CharCodes.n,l[d++]=CharCodes.d,l[d++]=CharCodes.o,l[d++]=CharCodes.b,l[d++]=CharCodes.j,l[d++]=CharCodes.Newline,l[d++]=CharCodes.Newline,m=v instanceof PDFObjectStream?v.getObjectsCount():1,this.shouldWaitForTick(m)?[4,waitForTick()]:[3,4]):[3,5];case 3:w.sent(),w.label=4;case 4:return u++,[3,2];case 5:return s&&(d+=s.copyBytesInto(l,d),l[d++]=CharCodes.Newline),o&&(d+=o.copyBytesInto(l,d),l[d++]=CharCodes.Newline,l[d++]=CharCodes.Newline),d+=h.copyBytesInto(l,d),[2,l]}})})},t.prototype.computeIndirectObjectSize=function(e){var r=e[0],n=e[1],a=r.sizeInBytes()+3,s=n.sizeInBytes()+9;return a+s},t.prototype.createTrailerDict=function(){return this.context.obj({Size:this.context.largestObjectNumber+1,Root:this.context.trailerInfo.Root,Encrypt:this.context.trailerInfo.Encrypt,Info:this.context.trailerInfo.Info,ID:this.context.trailerInfo.ID})},t.prototype.computeBufferSize=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n,a,s,o,h,d,l,u,p;return __generator(this,function(g){switch(g.label){case 0:e=PDFHeader.forVersion(1,7),r=e.sizeInBytes()+2,n=PDFCrossRefSection.create(),a=this.context.enumerateIndirectObjects(),s=0,o=a.length,g.label=1;case 1:return s<o?(h=a[s],d=h[0],n.addEntry(d,r),r+=this.computeIndirectObjectSize(h),this.shouldWaitForTick(1)?[4,waitForTick()]:[3,3]):[3,4];case 2:g.sent(),g.label=3;case 3:return s++,[3,1];case 4:return l=r,r+=n.sizeInBytes()+1,u=PDFTrailerDict.of(this.createTrailerDict()),r+=u.sizeInBytes()+2,p=PDFTrailer.forLastCrossRefSectionOffset(l),r+=p.sizeInBytes(),[2,{size:r,header:e,indirectObjects:a,xref:n,trailerDict:u,trailer:p}]}})})},t.forContext=function(e,r){return new t(e,r)},t}(),PDFInvalidObject=function(t){__extends(e,t);function e(r){var n=t.call(this)||this;return n.data=r,n}return e.prototype.clone=function(){return e.of(this.data.slice())},e.prototype.toString=function(){return"PDFInvalidObject("+this.data.length+" bytes)"},e.prototype.sizeInBytes=function(){return this.data.length},e.prototype.copyBytesInto=function(r,n){for(var a=this.data.length,s=0;s<a;s++)r[n++]=this.data[s];return a},e.of=function(r){return new e(r)},e}(PDFObject),EntryType;(function(t){t[t.Deleted=0]="Deleted",t[t.Uncompressed=1]="Uncompressed",t[t.Compressed=2]="Compressed"})(EntryType||(EntryType={}));var PDFCrossRefStream=function(t){__extends(e,t);function e(r,n,a){a===void 0&&(a=!0);var s=t.call(this,r,a)||this;return s.computeIndex=function(){for(var o=[],h=0,d=0,l=s.entries.length;d<l;d++){var u=s.entries[d],p=s.entries[d-1];d===0?o.push(u.ref.objectNumber):u.ref.objectNumber-p.ref.objectNumber>1&&(o.push(h),o.push(u.ref.objectNumber),h=0),h+=1}return o.push(h),o},s.computeEntryTuples=function(){for(var o=new Array(s.entries.length),h=0,d=s.entries.length;h<d;h++){var l=s.entries[h];if(l.type===EntryType.Deleted){var u=l.type,p=l.nextFreeObjectNumber,g=l.ref;o[h]=[u,p,g.generationNumber]}if(l.type===EntryType.Uncompressed){var u=l.type,f=l.offset,g=l.ref;o[h]=[u,f,g.generationNumber]}if(l.type===EntryType.Compressed){var u=l.type,v=l.objectStreamRef,y=l.index;o[h]=[u,v.objectNumber,y]}}return o},s.computeMaxEntryByteWidths=function(){for(var o=s.entryTuplesCache.access(),h=[0,0,0],d=0,l=o.length;d<l;d++){var u=o[d],p=u[0],g=u[1],f=u[2],v=sizeInBytes(p),y=sizeInBytes(g),x=sizeInBytes(f);v>h[0]&&(h[0]=v),y>h[1]&&(h[1]=y),x>h[2]&&(h[2]=x)}return h},s.entries=n||[],s.entryTuplesCache=Cache.populatedBy(s.computeEntryTuples),s.maxByteWidthsCache=Cache.populatedBy(s.computeMaxEntryByteWidths),s.indexCache=Cache.populatedBy(s.computeIndex),r.set(PDFName.of("Type"),PDFName.of("XRef")),s}return e.prototype.addDeletedEntry=function(r,n){var a=EntryType.Deleted;this.entries.push({type:a,ref:r,nextFreeObjectNumber:n}),this.entryTuplesCache.invalidate(),this.maxByteWidthsCache.invalidate(),this.indexCache.invalidate(),this.contentsCache.invalidate()},e.prototype.addUncompressedEntry=function(r,n){var a=EntryType.Uncompressed;this.entries.push({type:a,ref:r,offset:n}),this.entryTuplesCache.invalidate(),this.maxByteWidthsCache.invalidate(),this.indexCache.invalidate(),this.contentsCache.invalidate()},e.prototype.addCompressedEntry=function(r,n,a){var s=EntryType.Compressed;this.entries.push({type:s,ref:r,objectStreamRef:n,index:a}),this.entryTuplesCache.invalidate(),this.maxByteWidthsCache.invalidate(),this.indexCache.invalidate(),this.contentsCache.invalidate()},e.prototype.clone=function(r){var n=this,a=n.dict,s=n.entries,o=n.encode;return e.of(a.clone(r),s.slice(),o)},e.prototype.getContentsString=function(){for(var r=this.entryTuplesCache.access(),n=this.maxByteWidthsCache.access(),a="",s=0,o=r.length;s<o;s++){for(var h=r[s],d=h[0],l=h[1],u=h[2],p=reverseArray(bytesFor(d)),g=reverseArray(bytesFor(l)),f=reverseArray(bytesFor(u)),v=n[0]-1;v>=0;v--)a+=(p[v]||0).toString(2);for(var v=n[1]-1;v>=0;v--)a+=(g[v]||0).toString(2);for(var v=n[2]-1;v>=0;v--)a+=(f[v]||0).toString(2)}return a},e.prototype.getUnencodedContents=function(){for(var r=this.entryTuplesCache.access(),n=this.maxByteWidthsCache.access(),a=new Uint8Array(this.getUnencodedContentsSize()),s=0,o=0,h=r.length;o<h;o++){for(var d=r[o],l=d[0],u=d[1],p=d[2],g=reverseArray(bytesFor(l)),f=reverseArray(bytesFor(u)),v=reverseArray(bytesFor(p)),y=n[0]-1;y>=0;y--)a[s++]=g[y]||0;for(var y=n[1]-1;y>=0;y--)a[s++]=f[y]||0;for(var y=n[2]-1;y>=0;y--)a[s++]=v[y]||0}return a},e.prototype.getUnencodedContentsSize=function(){var r=this.maxByteWidthsCache.access(),n=sum(r);return n*this.entries.length},e.prototype.updateDict=function(){t.prototype.updateDict.call(this);var r=this.maxByteWidthsCache.access(),n=this.indexCache.access(),a=this.dict.context;this.dict.set(PDFName.of("W"),a.obj(r)),this.dict.set(PDFName.of("Index"),a.obj(n))},e.create=function(r,n){n===void 0&&(n=!0);var a=new e(r,[],n);return a.addDeletedEntry(PDFRef.of(0,65535),0),a},e.of=function(r,n,a){return a===void 0&&(a=!0),new e(r,n,a)},e}(PDFFlateStream),PDFStreamWriter=function(t){__extends(e,t);function e(r,n,a,s){var o=t.call(this,r,n)||this;return o.encodeStreams=a,o.objectsPerStream=s,o}return e.prototype.computeBufferSize=function(){return __awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h,d,l,v,y,u,m,p,g,x,f,v,y,x,m,w,R,_,S;return __generator(this,function(F){switch(F.label){case 0:r=this.context.largestObjectNumber+1,n=PDFHeader.forVersion(1,7),a=n.sizeInBytes()+2,s=PDFCrossRefStream.create(this.createTrailerDict(),this.encodeStreams),o=[],h=[],d=[],l=this.context.enumerateIndirectObjects(),v=0,y=l.length,F.label=1;case 1:return v<y?(u=l[v],m=u[0],p=u[1],g=m===this.context.trailerInfo.Encrypt||p instanceof PDFStream||p instanceof PDFInvalidObject||m.generationNumber!==0,g?(o.push(u),s.addUncompressedEntry(m,a),a+=this.computeIndirectObjectSize(u),this.shouldWaitForTick(1)?[4,waitForTick()]:[3,3]):[3,4]):[3,6];case 2:F.sent(),F.label=3;case 3:return[3,5];case 4:x=last(h),f=last(d),(!x||x.length%this.objectsPerStream===0)&&(x=[],h.push(x),f=PDFRef.of(r++),d.push(f)),s.addCompressedEntry(m,f,x.length),x.push(u),F.label=5;case 5:return v++,[3,1];case 6:v=0,y=h.length,F.label=7;case 7:return v<y?(x=h[v],m=d[v],w=PDFObjectStream.withContextAndObjects(this.context,x,this.encodeStreams),s.addUncompressedEntry(m,a),a+=this.computeIndirectObjectSize([m,w]),o.push([m,w]),this.shouldWaitForTick(x.length)?[4,waitForTick()]:[3,9]):[3,10];case 8:F.sent(),F.label=9;case 9:return v++,[3,7];case 10:return R=PDFRef.of(r++),s.dict.set(PDFName.of("Size"),PDFNumber.of(r)),s.addUncompressedEntry(R,a),_=a,a+=this.computeIndirectObjectSize([R,s]),o.push([R,s]),S=PDFTrailer.forLastCrossRefSectionOffset(_),a+=S.sizeInBytes(),[2,{size:a,header:n,indirectObjects:o,trailer:S}]}})})},e.forContext=function(r,n,a,s){return a===void 0&&(a=!0),s===void 0&&(s=50),new e(r,n,a,s)},e}(PDFWriter),PDFHexString=function(t){__extends(e,t);function e(r){var n=t.call(this)||this;return n.value=r,n}return e.prototype.asBytes=function(){for(var r=this.value+(this.value.length%2===1?"0":""),n=r.length,a=new Uint8Array(r.length/2),s=0,o=0;s<n;){var h=parseInt(r.substring(s,s+2),16);a[o]=h,s+=2,o+=1}return a},e.prototype.decodeText=function(){var r=this.asBytes();return hasUtf16BOM(r)?utf16Decode(r):pdfDocEncodingDecode(r)},e.prototype.decodeDate=function(){var r=this.decodeText(),n=parseDate(r);if(!n)throw new InvalidPDFDateStringError(r);return n},e.prototype.asString=function(){return this.value},e.prototype.clone=function(){return e.of(this.value)},e.prototype.toString=function(){return"<"+this.value+">"},e.prototype.sizeInBytes=function(){return this.value.length+2},e.prototype.copyBytesInto=function(r,n){return r[n++]=CharCodes.LessThan,n+=copyStringIntoBuffer(this.value,r,n),r[n++]=CharCodes.GreaterThan,this.value.length+2},e.of=function(r){return new e(r)},e.fromText=function(r){for(var n=utf16Encode(r),a="",s=0,o=n.length;s<o;s++)a+=toHexStringOfMinLength(n[s],4);return new e(a)},e}(PDFObject),StandardFontEmbedder=function(){function t(e,r){this.encoding=e===FontNames.ZapfDingbats?Encodings.ZapfDingbats:e===FontNames.Symbol?Encodings.Symbol:Encodings.WinAnsi,this.font=Font.load(e),this.fontName=this.font.FontName,this.customName=r}return t.prototype.encodeText=function(e){for(var r=this.encodeTextAsGlyphs(e),n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]=toHexString(r[a].code);return PDFHexString.of(n.join(""))},t.prototype.widthOfTextAtSize=function(e,r){for(var n=this.encodeTextAsGlyphs(e),a=0,s=0,o=n.length;s<o;s++){var h=n[s].name,d=(n[s+1]||{}).name,l=this.font.getXAxisKerningForPair(h,d)||0;a+=this.widthOfGlyph(h)+l}var u=r/1e3;return a*u},t.prototype.heightOfFontAtSize=function(e,r){r===void 0&&(r={});var n=r.descender,a=n===void 0?!0:n,s=this.font,o=s.Ascender,h=s.Descender,d=s.FontBBox,l=o||d[3],u=h||d[1],p=l-u;return a||(p+=h||0),p/1e3*e},t.prototype.sizeOfFontAtHeight=function(e){var r=this.font,n=r.Ascender,a=r.Descender,s=r.FontBBox,o=n||s[3],h=a||s[1];return 1e3*e/(o-h)},t.prototype.embedIntoContext=function(e,r){var n=e.obj({Type:"Font",Subtype:"Type1",BaseFont:this.customName||this.fontName,Encoding:this.encoding===Encodings.WinAnsi?"WinAnsiEncoding":void 0});return r?(e.assign(r,n),r):e.register(n)},t.prototype.widthOfGlyph=function(e){return this.font.getWidthOfGlyph(e)||250},t.prototype.encodeTextAsGlyphs=function(e){for(var r=Array.from(e),n=new Array(r.length),a=0,s=r.length;a<s;a++){var o=toCodePoint(r[a]);n[a]=this.encoding.encodeUnicodeCodePoint(o)}return n},t.for=function(e,r){return new t(e,r)},t}(),createCmap=function(t,e){for(var r=new Array(t.length),n=0,a=t.length;n<a;n++){var s=t[n],o=cmapHexFormat(cmapHexString(e(s))),h=cmapHexFormat.apply(void 0,s.codePoints.map(cmapCodePointFormat));r[n]=[o,h]}return fillCmapTemplate(r)},fillCmapTemplate=function(t){return`/CIDInit /ProcSet findresource begin
|
|
37
|
+
`}return r},e.prototype.getUnencodedContents=function(){for(var r=new Uint8Array(this.getUnencodedContentsSize()),n=copyStringIntoBuffer(this.offsetsString,r,0),a=0,s=this.objects.length;a<s;a++){var o=this.objects[a],h=o[1];n+=h.copyBytesInto(r,n),r[n++]=CharCodes.Newline}return r},e.prototype.getUnencodedContentsSize=function(){return this.offsetsString.length+last(this.offsets)[1]+last(this.objects)[1].sizeInBytes()+1},e.prototype.computeOffsetsString=function(){for(var r="",n=0,a=this.offsets.length;n<a;n++){var s=this.offsets[n],o=s[0],h=s[1];r+=o+" "+h+" "}return r},e.prototype.computeObjectOffsets=function(){for(var r=0,n=new Array(this.objects.length),a=0,s=this.objects.length;a<s;a++){var o=this.objects[a],h=o[0],d=o[1];n[a]=[h.objectNumber,r],r+=d.sizeInBytes()+1}return n},e.withContextAndObjects=function(r,n,a){return a===void 0&&(a=!0),new e(r,n,a)},e}(PDFFlateStream),PDFWriter=function(){function t(e,r){var n=this;this.parsedObjects=0,this.shouldWaitForTick=function(a){return n.parsedObjects+=a,n.parsedObjects%n.objectsPerTick===0},this.context=e,this.objectsPerTick=r}return t.prototype.serializeToBuffer=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n,a,s,o,h,d,l,u,p,g,f,v,y,S,m;return __generator(this,function(w){switch(w.label){case 0:return[4,this.computeBufferSize()];case 1:e=w.sent(),r=e.size,n=e.header,a=e.indirectObjects,s=e.xref,o=e.trailerDict,h=e.trailer,d=0,l=new Uint8Array(r),d+=n.copyBytesInto(l,d),l[d++]=CharCodes.Newline,l[d++]=CharCodes.Newline,u=0,p=a.length,w.label=2;case 2:return u<p?(g=a[u],f=g[0],v=g[1],y=String(f.objectNumber),d+=copyStringIntoBuffer(y,l,d),l[d++]=CharCodes.Space,S=String(f.generationNumber),d+=copyStringIntoBuffer(S,l,d),l[d++]=CharCodes.Space,l[d++]=CharCodes.o,l[d++]=CharCodes.b,l[d++]=CharCodes.j,l[d++]=CharCodes.Newline,d+=v.copyBytesInto(l,d),l[d++]=CharCodes.Newline,l[d++]=CharCodes.e,l[d++]=CharCodes.n,l[d++]=CharCodes.d,l[d++]=CharCodes.o,l[d++]=CharCodes.b,l[d++]=CharCodes.j,l[d++]=CharCodes.Newline,l[d++]=CharCodes.Newline,m=v instanceof PDFObjectStream?v.getObjectsCount():1,this.shouldWaitForTick(m)?[4,waitForTick()]:[3,4]):[3,5];case 3:w.sent(),w.label=4;case 4:return u++,[3,2];case 5:return s&&(d+=s.copyBytesInto(l,d),l[d++]=CharCodes.Newline),o&&(d+=o.copyBytesInto(l,d),l[d++]=CharCodes.Newline,l[d++]=CharCodes.Newline),d+=h.copyBytesInto(l,d),[2,l]}})})},t.prototype.computeIndirectObjectSize=function(e){var r=e[0],n=e[1],a=r.sizeInBytes()+3,s=n.sizeInBytes()+9;return a+s},t.prototype.createTrailerDict=function(){return this.context.obj({Size:this.context.largestObjectNumber+1,Root:this.context.trailerInfo.Root,Encrypt:this.context.trailerInfo.Encrypt,Info:this.context.trailerInfo.Info,ID:this.context.trailerInfo.ID})},t.prototype.computeBufferSize=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n,a,s,o,h,d,l,u,p;return __generator(this,function(g){switch(g.label){case 0:e=PDFHeader.forVersion(1,7),r=e.sizeInBytes()+2,n=PDFCrossRefSection.create(),a=this.context.enumerateIndirectObjects(),s=0,o=a.length,g.label=1;case 1:return s<o?(h=a[s],d=h[0],n.addEntry(d,r),r+=this.computeIndirectObjectSize(h),this.shouldWaitForTick(1)?[4,waitForTick()]:[3,3]):[3,4];case 2:g.sent(),g.label=3;case 3:return s++,[3,1];case 4:return l=r,r+=n.sizeInBytes()+1,u=PDFTrailerDict.of(this.createTrailerDict()),r+=u.sizeInBytes()+2,p=PDFTrailer.forLastCrossRefSectionOffset(l),r+=p.sizeInBytes(),[2,{size:r,header:e,indirectObjects:a,xref:n,trailerDict:u,trailer:p}]}})})},t.forContext=function(e,r){return new t(e,r)},t}(),PDFInvalidObject=function(t){__extends(e,t);function e(r){var n=t.call(this)||this;return n.data=r,n}return e.prototype.clone=function(){return e.of(this.data.slice())},e.prototype.toString=function(){return"PDFInvalidObject("+this.data.length+" bytes)"},e.prototype.sizeInBytes=function(){return this.data.length},e.prototype.copyBytesInto=function(r,n){for(var a=this.data.length,s=0;s<a;s++)r[n++]=this.data[s];return a},e.of=function(r){return new e(r)},e}(PDFObject),EntryType;(function(t){t[t.Deleted=0]="Deleted",t[t.Uncompressed=1]="Uncompressed",t[t.Compressed=2]="Compressed"})(EntryType||(EntryType={}));var PDFCrossRefStream=function(t){__extends(e,t);function e(r,n,a){a===void 0&&(a=!0);var s=t.call(this,r,a)||this;return s.computeIndex=function(){for(var o=[],h=0,d=0,l=s.entries.length;d<l;d++){var u=s.entries[d],p=s.entries[d-1];d===0?o.push(u.ref.objectNumber):u.ref.objectNumber-p.ref.objectNumber>1&&(o.push(h),o.push(u.ref.objectNumber),h=0),h+=1}return o.push(h),o},s.computeEntryTuples=function(){for(var o=new Array(s.entries.length),h=0,d=s.entries.length;h<d;h++){var l=s.entries[h];if(l.type===EntryType.Deleted){var u=l.type,p=l.nextFreeObjectNumber,g=l.ref;o[h]=[u,p,g.generationNumber]}if(l.type===EntryType.Uncompressed){var u=l.type,f=l.offset,g=l.ref;o[h]=[u,f,g.generationNumber]}if(l.type===EntryType.Compressed){var u=l.type,v=l.objectStreamRef,y=l.index;o[h]=[u,v.objectNumber,y]}}return o},s.computeMaxEntryByteWidths=function(){for(var o=s.entryTuplesCache.access(),h=[0,0,0],d=0,l=o.length;d<l;d++){var u=o[d],p=u[0],g=u[1],f=u[2],v=sizeInBytes(p),y=sizeInBytes(g),S=sizeInBytes(f);v>h[0]&&(h[0]=v),y>h[1]&&(h[1]=y),S>h[2]&&(h[2]=S)}return h},s.entries=n||[],s.entryTuplesCache=Cache.populatedBy(s.computeEntryTuples),s.maxByteWidthsCache=Cache.populatedBy(s.computeMaxEntryByteWidths),s.indexCache=Cache.populatedBy(s.computeIndex),r.set(PDFName.of("Type"),PDFName.of("XRef")),s}return e.prototype.addDeletedEntry=function(r,n){var a=EntryType.Deleted;this.entries.push({type:a,ref:r,nextFreeObjectNumber:n}),this.entryTuplesCache.invalidate(),this.maxByteWidthsCache.invalidate(),this.indexCache.invalidate(),this.contentsCache.invalidate()},e.prototype.addUncompressedEntry=function(r,n){var a=EntryType.Uncompressed;this.entries.push({type:a,ref:r,offset:n}),this.entryTuplesCache.invalidate(),this.maxByteWidthsCache.invalidate(),this.indexCache.invalidate(),this.contentsCache.invalidate()},e.prototype.addCompressedEntry=function(r,n,a){var s=EntryType.Compressed;this.entries.push({type:s,ref:r,objectStreamRef:n,index:a}),this.entryTuplesCache.invalidate(),this.maxByteWidthsCache.invalidate(),this.indexCache.invalidate(),this.contentsCache.invalidate()},e.prototype.clone=function(r){var n=this,a=n.dict,s=n.entries,o=n.encode;return e.of(a.clone(r),s.slice(),o)},e.prototype.getContentsString=function(){for(var r=this.entryTuplesCache.access(),n=this.maxByteWidthsCache.access(),a="",s=0,o=r.length;s<o;s++){for(var h=r[s],d=h[0],l=h[1],u=h[2],p=reverseArray(bytesFor(d)),g=reverseArray(bytesFor(l)),f=reverseArray(bytesFor(u)),v=n[0]-1;v>=0;v--)a+=(p[v]||0).toString(2);for(var v=n[1]-1;v>=0;v--)a+=(g[v]||0).toString(2);for(var v=n[2]-1;v>=0;v--)a+=(f[v]||0).toString(2)}return a},e.prototype.getUnencodedContents=function(){for(var r=this.entryTuplesCache.access(),n=this.maxByteWidthsCache.access(),a=new Uint8Array(this.getUnencodedContentsSize()),s=0,o=0,h=r.length;o<h;o++){for(var d=r[o],l=d[0],u=d[1],p=d[2],g=reverseArray(bytesFor(l)),f=reverseArray(bytesFor(u)),v=reverseArray(bytesFor(p)),y=n[0]-1;y>=0;y--)a[s++]=g[y]||0;for(var y=n[1]-1;y>=0;y--)a[s++]=f[y]||0;for(var y=n[2]-1;y>=0;y--)a[s++]=v[y]||0}return a},e.prototype.getUnencodedContentsSize=function(){var r=this.maxByteWidthsCache.access(),n=sum(r);return n*this.entries.length},e.prototype.updateDict=function(){t.prototype.updateDict.call(this);var r=this.maxByteWidthsCache.access(),n=this.indexCache.access(),a=this.dict.context;this.dict.set(PDFName.of("W"),a.obj(r)),this.dict.set(PDFName.of("Index"),a.obj(n))},e.create=function(r,n){n===void 0&&(n=!0);var a=new e(r,[],n);return a.addDeletedEntry(PDFRef.of(0,65535),0),a},e.of=function(r,n,a){return a===void 0&&(a=!0),new e(r,n,a)},e}(PDFFlateStream),PDFStreamWriter=function(t){__extends(e,t);function e(r,n,a,s){var o=t.call(this,r,n)||this;return o.encodeStreams=a,o.objectsPerStream=s,o}return e.prototype.computeBufferSize=function(){return __awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h,d,l,v,y,u,m,p,g,S,f,v,y,S,m,w,R,_,x;return __generator(this,function(F){switch(F.label){case 0:r=this.context.largestObjectNumber+1,n=PDFHeader.forVersion(1,7),a=n.sizeInBytes()+2,s=PDFCrossRefStream.create(this.createTrailerDict(),this.encodeStreams),o=[],h=[],d=[],l=this.context.enumerateIndirectObjects(),v=0,y=l.length,F.label=1;case 1:return v<y?(u=l[v],m=u[0],p=u[1],g=m===this.context.trailerInfo.Encrypt||p instanceof PDFStream||p instanceof PDFInvalidObject||m.generationNumber!==0,g?(o.push(u),s.addUncompressedEntry(m,a),a+=this.computeIndirectObjectSize(u),this.shouldWaitForTick(1)?[4,waitForTick()]:[3,3]):[3,4]):[3,6];case 2:F.sent(),F.label=3;case 3:return[3,5];case 4:S=last(h),f=last(d),(!S||S.length%this.objectsPerStream===0)&&(S=[],h.push(S),f=PDFRef.of(r++),d.push(f)),s.addCompressedEntry(m,f,S.length),S.push(u),F.label=5;case 5:return v++,[3,1];case 6:v=0,y=h.length,F.label=7;case 7:return v<y?(S=h[v],m=d[v],w=PDFObjectStream.withContextAndObjects(this.context,S,this.encodeStreams),s.addUncompressedEntry(m,a),a+=this.computeIndirectObjectSize([m,w]),o.push([m,w]),this.shouldWaitForTick(S.length)?[4,waitForTick()]:[3,9]):[3,10];case 8:F.sent(),F.label=9;case 9:return v++,[3,7];case 10:return R=PDFRef.of(r++),s.dict.set(PDFName.of("Size"),PDFNumber.of(r)),s.addUncompressedEntry(R,a),_=a,a+=this.computeIndirectObjectSize([R,s]),o.push([R,s]),x=PDFTrailer.forLastCrossRefSectionOffset(_),a+=x.sizeInBytes(),[2,{size:a,header:n,indirectObjects:o,trailer:x}]}})})},e.forContext=function(r,n,a,s){return a===void 0&&(a=!0),s===void 0&&(s=50),new e(r,n,a,s)},e}(PDFWriter),PDFHexString=function(t){__extends(e,t);function e(r){var n=t.call(this)||this;return n.value=r,n}return e.prototype.asBytes=function(){for(var r=this.value+(this.value.length%2===1?"0":""),n=r.length,a=new Uint8Array(r.length/2),s=0,o=0;s<n;){var h=parseInt(r.substring(s,s+2),16);a[o]=h,s+=2,o+=1}return a},e.prototype.decodeText=function(){var r=this.asBytes();return hasUtf16BOM(r)?utf16Decode(r):pdfDocEncodingDecode(r)},e.prototype.decodeDate=function(){var r=this.decodeText(),n=parseDate(r);if(!n)throw new InvalidPDFDateStringError(r);return n},e.prototype.asString=function(){return this.value},e.prototype.clone=function(){return e.of(this.value)},e.prototype.toString=function(){return"<"+this.value+">"},e.prototype.sizeInBytes=function(){return this.value.length+2},e.prototype.copyBytesInto=function(r,n){return r[n++]=CharCodes.LessThan,n+=copyStringIntoBuffer(this.value,r,n),r[n++]=CharCodes.GreaterThan,this.value.length+2},e.of=function(r){return new e(r)},e.fromText=function(r){for(var n=utf16Encode(r),a="",s=0,o=n.length;s<o;s++)a+=toHexStringOfMinLength(n[s],4);return new e(a)},e}(PDFObject),StandardFontEmbedder=function(){function t(e,r){this.encoding=e===FontNames.ZapfDingbats?Encodings.ZapfDingbats:e===FontNames.Symbol?Encodings.Symbol:Encodings.WinAnsi,this.font=Font.load(e),this.fontName=this.font.FontName,this.customName=r}return t.prototype.encodeText=function(e){for(var r=this.encodeTextAsGlyphs(e),n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]=toHexString(r[a].code);return PDFHexString.of(n.join(""))},t.prototype.widthOfTextAtSize=function(e,r){for(var n=this.encodeTextAsGlyphs(e),a=0,s=0,o=n.length;s<o;s++){var h=n[s].name,d=(n[s+1]||{}).name,l=this.font.getXAxisKerningForPair(h,d)||0;a+=this.widthOfGlyph(h)+l}var u=r/1e3;return a*u},t.prototype.heightOfFontAtSize=function(e,r){r===void 0&&(r={});var n=r.descender,a=n===void 0?!0:n,s=this.font,o=s.Ascender,h=s.Descender,d=s.FontBBox,l=o||d[3],u=h||d[1],p=l-u;return a||(p+=h||0),p/1e3*e},t.prototype.sizeOfFontAtHeight=function(e){var r=this.font,n=r.Ascender,a=r.Descender,s=r.FontBBox,o=n||s[3],h=a||s[1];return 1e3*e/(o-h)},t.prototype.embedIntoContext=function(e,r){var n=e.obj({Type:"Font",Subtype:"Type1",BaseFont:this.customName||this.fontName,Encoding:this.encoding===Encodings.WinAnsi?"WinAnsiEncoding":void 0});return r?(e.assign(r,n),r):e.register(n)},t.prototype.widthOfGlyph=function(e){return this.font.getWidthOfGlyph(e)||250},t.prototype.encodeTextAsGlyphs=function(e){for(var r=Array.from(e),n=new Array(r.length),a=0,s=r.length;a<s;a++){var o=toCodePoint(r[a]);n[a]=this.encoding.encodeUnicodeCodePoint(o)}return n},t.for=function(e,r){return new t(e,r)},t}(),createCmap=function(t,e){for(var r=new Array(t.length),n=0,a=t.length;n<a;n++){var s=t[n],o=cmapHexFormat(cmapHexString(e(s))),h=cmapHexFormat.apply(void 0,s.codePoints.map(cmapCodePointFormat));r[n]=[o,h]}return fillCmapTemplate(r)},fillCmapTemplate=function(t){return`/CIDInit /ProcSet findresource begin
|
|
38
38
|
12 dict begin
|
|
39
39
|
begincmap
|
|
40
40
|
/CIDSystemInfo <<
|
|
@@ -54,9 +54,9 @@ endbfchar
|
|
|
54
54
|
endcmap
|
|
55
55
|
CMapName currentdict /CMap defineresource pop
|
|
56
56
|
end
|
|
57
|
-
end`},cmapHexFormat=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return"<"+t.join("")+">"},cmapHexString=function(t){return toHexStringOfMinLength(t,4)},cmapCodePointFormat=function(t){if(isWithinBMP(t))return cmapHexString(t);if(hasSurrogates(t)){var e=highSurrogate(t),r=lowSurrogate(t);return""+cmapHexString(e)+cmapHexString(r)}var n=toHexString(t),a="0x"+n+" is not a valid UTF-8 or UTF-16 codepoint.";throw new Error(a)},makeFontFlags=function(t){var e=0,r=function(n){e|=1<<n-1};return t.fixedPitch&&r(1),t.serif&&r(2),r(3),t.script&&r(4),t.nonsymbolic&&r(6),t.italic&&r(7),t.allCap&&r(17),t.smallCap&&r(18),t.forceBold&&r(19),e},deriveFontFlags=function(t){var e=t["OS/2"]?t["OS/2"].sFamilyClass:0,r=makeFontFlags({fixedPitch:t.post.isFixedPitch,serif:1<=e&&e<=7,script:e===10,italic:t.head.macStyle.italic});return r},PDFString=function(t){__extends(e,t);function e(r){var n=t.call(this)||this;return n.value=r,n}return e.prototype.asBytes=function(){for(var r=[],n="",a=!1,s=function(p){p!==void 0&&r.push(p),a=!1},o=0,h=this.value.length;o<h;o++){var d=this.value[o],l=toCharCode(d),u=this.value[o+1];a?l===CharCodes.Newline||l===CharCodes.CarriageReturn?s():l===CharCodes.n?s(CharCodes.Newline):l===CharCodes.r?s(CharCodes.CarriageReturn):l===CharCodes.t?s(CharCodes.Tab):l===CharCodes.b?s(CharCodes.Backspace):l===CharCodes.f?s(CharCodes.FormFeed):l===CharCodes.LeftParen?s(CharCodes.LeftParen):l===CharCodes.RightParen?s(CharCodes.RightParen):l===CharCodes.Backspace?s(CharCodes.BackSlash):l>=CharCodes.Zero&&l<=CharCodes.Seven?(n+=d,(n.length===3||!(u>="0"&&u<="7"))&&(s(parseInt(n,8)),n="")):s(l):l===CharCodes.BackSlash?a=!0:s(l)}return new Uint8Array(r)},e.prototype.decodeText=function(){var r=this.asBytes();return hasUtf16BOM(r)?utf16Decode(r):pdfDocEncodingDecode(r)},e.prototype.decodeDate=function(){var r=this.decodeText(),n=parseDate(r);if(!n)throw new InvalidPDFDateStringError(r);return n},e.prototype.asString=function(){return this.value},e.prototype.clone=function(){return e.of(this.value)},e.prototype.toString=function(){return"("+this.value+")"},e.prototype.sizeInBytes=function(){return this.value.length+2},e.prototype.copyBytesInto=function(r,n){return r[n++]=CharCodes.LeftParen,n+=copyStringIntoBuffer(this.value,r,n),r[n++]=CharCodes.RightParen,this.value.length+2},e.of=function(r){return new e(r)},e.fromDate=function(r){var n=padStart$1(String(r.getUTCFullYear()),4,"0"),a=padStart$1(String(r.getUTCMonth()+1),2,"0"),s=padStart$1(String(r.getUTCDate()),2,"0"),o=padStart$1(String(r.getUTCHours()),2,"0"),h=padStart$1(String(r.getUTCMinutes()),2,"0"),d=padStart$1(String(r.getUTCSeconds()),2,"0");return new e("D:"+n+a+s+o+h+d+"Z")},e}(PDFObject),CustomFontEmbedder=function(){function t(e,r,n,a){var s=this;this.allGlyphsInFontSortedById=function(){for(var o=new Array(s.font.characterSet.length),h=0,d=o.length;h<d;h++){var l=s.font.characterSet[h];o[h]=s.font.glyphForCodePoint(l)}return sortedUniq(o.sort(byAscendingId),function(u){return u.id})},this.font=e,this.scale=1e3/this.font.unitsPerEm,this.fontData=r,this.fontName=this.font.postscriptName||"Font",this.customName=n,this.fontFeatures=a,this.baseFontName="",this.glyphCache=Cache.populatedBy(this.allGlyphsInFontSortedById)}return t.for=function(e,r,n,a){return __awaiter(this,void 0,void 0,function(){var s;return __generator(this,function(o){switch(o.label){case 0:return[4,e.create(r)];case 1:return s=o.sent(),[2,new t(s,r,n,a)]}})})},t.prototype.encodeText=function(e){for(var r=this.font.layout(e,this.fontFeatures).glyphs,n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]=toHexStringOfMinLength(r[a].id,4);return PDFHexString.of(n.join(""))},t.prototype.widthOfTextAtSize=function(e,r){for(var n=this.font.layout(e,this.fontFeatures).glyphs,a=0,s=0,o=n.length;s<o;s++)a+=n[s].advanceWidth*this.scale;var h=r/1e3;return a*h},t.prototype.heightOfFontAtSize=function(e,r){r===void 0&&(r={});var n=r.descender,a=n===void 0?!0:n,s=this.font,o=s.ascent,h=s.descent,d=s.bbox,l=(o||d.maxY)*this.scale,u=(h||d.minY)*this.scale,p=l-u;return a||(p-=Math.abs(h)||0),p/1e3*e},t.prototype.sizeOfFontAtHeight=function(e){var r=this.font,n=r.ascent,a=r.descent,s=r.bbox,o=(n||s.maxY)*this.scale,h=(a||s.minY)*this.scale;return 1e3*e/(o-h)},t.prototype.embedIntoContext=function(e,r){return this.baseFontName=this.customName||e.addRandomSuffix(this.fontName),this.embedFontDict(e,r)},t.prototype.embedFontDict=function(e,r){return __awaiter(this,void 0,void 0,function(){var n,a,s;return __generator(this,function(o){switch(o.label){case 0:return[4,this.embedCIDFontDict(e)];case 1:return n=o.sent(),a=this.embedUnicodeCmap(e),s=e.obj({Type:"Font",Subtype:"Type0",BaseFont:this.baseFontName,Encoding:"Identity-H",DescendantFonts:[n],ToUnicode:a}),r?(e.assign(r,s),[2,r]):[2,e.register(s)]}})})},t.prototype.isCFF=function(){return this.font.cff},t.prototype.embedCIDFontDict=function(e){return __awaiter(this,void 0,void 0,function(){var r,n;return __generator(this,function(a){switch(a.label){case 0:return[4,this.embedFontDescriptor(e)];case 1:return r=a.sent(),n=e.obj({Type:"Font",Subtype:this.isCFF()?"CIDFontType0":"CIDFontType2",CIDToGIDMap:"Identity",BaseFont:this.baseFontName,CIDSystemInfo:{Registry:PDFString.of("Adobe"),Ordering:PDFString.of("Identity"),Supplement:0},FontDescriptor:r,W:this.computeWidths()}),[2,e.register(n)]}})})},t.prototype.embedFontDescriptor=function(e){return __awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h,d,l,u,p,g,f,v,y,x;return __generator(this,function(m){switch(m.label){case 0:return[4,this.embedFontStream(e)];case 1:return r=m.sent(),n=this.scale,a=this.font,s=a.italicAngle,o=a.ascent,h=a.descent,d=a.capHeight,l=a.xHeight,u=this.font.bbox,p=u.minX,g=u.minY,f=u.maxX,v=u.maxY,y=e.obj((x={Type:"FontDescriptor",FontName:this.baseFontName,Flags:deriveFontFlags(this.font),FontBBox:[p*n,g*n,f*n,v*n],ItalicAngle:s,Ascent:o*n,Descent:h*n,CapHeight:(d||o)*n,XHeight:(l||0)*n,StemV:0},x[this.isCFF()?"FontFile3":"FontFile2"]=r,x)),[2,e.register(y)]}})})},t.prototype.serializeFont=function(){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){return[2,this.fontData]})})},t.prototype.embedFontStream=function(e){return __awaiter(this,void 0,void 0,function(){var r,n,a;return __generator(this,function(s){switch(s.label){case 0:return a=(n=e).flateStream,[4,this.serializeFont()];case 1:return r=a.apply(n,[s.sent(),{Subtype:this.isCFF()?"CIDFontType0C":void 0}]),[2,e.register(r)]}})})},t.prototype.embedUnicodeCmap=function(e){var r=createCmap(this.glyphCache.access(),this.glyphId.bind(this)),n=e.flateStream(r);return e.register(n)},t.prototype.glyphId=function(e){return e?e.id:-1},t.prototype.computeWidths=function(){for(var e=this.glyphCache.access(),r=[],n=[],a=0,s=e.length;a<s;a++){var o=e[a],h=e[a-1],d=this.glyphId(o),l=this.glyphId(h);a===0?r.push(d):d-l!==1&&(r.push(n),r.push(d),n=[]),n.push(o.advanceWidth*this.scale)}return r.push(n),r},t}(),CustomFontSubsetEmbedder=function(t){__extends(e,t);function e(r,n,a,s){var o=t.call(this,r,n,a,s)||this;return o.subset=o.font.createSubset(),o.glyphs=[],o.glyphCache=Cache.populatedBy(function(){return o.glyphs}),o.glyphIdMap=new Map,o}return e.for=function(r,n,a,s){return __awaiter(this,void 0,void 0,function(){var o;return __generator(this,function(h){switch(h.label){case 0:return[4,r.create(n)];case 1:return o=h.sent(),[2,new e(o,n,a,s)]}})})},e.prototype.encodeText=function(r){for(var n=this.font.layout(r,this.fontFeatures).glyphs,a=new Array(n.length),s=0,o=n.length;s<o;s++){var h=n[s],d=this.subset.includeGlyph(h);this.glyphs[d-1]=h,this.glyphIdMap.set(h.id,d),a[s]=toHexStringOfMinLength(d,4)}return this.glyphCache.invalidate(),PDFHexString.of(a.join(""))},e.prototype.isCFF=function(){return this.subset.cff},e.prototype.glyphId=function(r){return r?this.glyphIdMap.get(r.id):-1},e.prototype.serializeFont=function(){var r=this;return new Promise(function(n,a){var s=[];r.subset.encodeStream().on("data",function(o){return s.push(o)}).on("end",function(){return n(mergeUint8Arrays(s))}).on("error",function(o){return a(o)})})},e}(CustomFontEmbedder),AFRelationship;(function(t){t.Source="Source",t.Data="Data",t.Alternative="Alternative",t.Supplement="Supplement",t.EncryptedPayload="EncryptedPayload",t.FormData="EncryptedPayload",t.Schema="Schema",t.Unspecified="Unspecified"})(AFRelationship||(AFRelationship={}));var FileEmbedder=function(){function t(e,r,n){n===void 0&&(n={}),this.fileData=e,this.fileName=r,this.options=n}return t.for=function(e,r,n){return n===void 0&&(n={}),new t(e,r,n)},t.prototype.embedIntoContext=function(e,r){return __awaiter(this,void 0,void 0,function(){var n,a,s,o,h,d,l,u,p;return __generator(this,function(g){return n=this.options,a=n.mimeType,s=n.description,o=n.creationDate,h=n.modificationDate,d=n.afRelationship,l=e.flateStream(this.fileData,{Type:"EmbeddedFile",Subtype:a??void 0,Params:{Size:this.fileData.length,CreationDate:o?PDFString.fromDate(o):void 0,ModDate:h?PDFString.fromDate(h):void 0}}),u=e.register(l),p=e.obj({Type:"Filespec",F:PDFString.of(this.fileName),UF:PDFHexString.fromText(this.fileName),EF:{F:u},Desc:s?PDFHexString.fromText(s):void 0,AFRelationship:d??void 0}),r?(e.assign(r,p),[2,r]):[2,e.register(p)]})})},t}(),MARKERS=[65472,65473,65474,65475,65477,65478,65479,65480,65481,65482,65483,65484,65485,65486,65487],ColorSpace;(function(t){t.DeviceGray="DeviceGray",t.DeviceRGB="DeviceRGB",t.DeviceCMYK="DeviceCMYK"})(ColorSpace||(ColorSpace={}));var ChannelToColorSpace={1:ColorSpace.DeviceGray,3:ColorSpace.DeviceRGB,4:ColorSpace.DeviceCMYK},JpegEmbedder=function(){function t(e,r,n,a,s){this.imageData=e,this.bitsPerComponent=r,this.width=n,this.height=a,this.colorSpace=s}return t.for=function(e){return __awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h,d,l,u,p;return __generator(this,function(g){if(r=new DataView(e.buffer),n=r.getUint16(0),n!==65496)throw new Error("SOI not found in JPEG");for(a=2;a<r.byteLength&&(s=r.getUint16(a),a+=2,!MARKERS.includes(s));)a+=r.getUint16(a);if(!MARKERS.includes(s))throw new Error("Invalid JPEG");if(a+=2,o=r.getUint8(a++),h=r.getUint16(a),a+=2,d=r.getUint16(a),a+=2,l=r.getUint8(a++),u=ChannelToColorSpace[l],!u)throw new Error("Unknown JPEG channel.");return p=u,[2,new t(e,o,d,h,p)]})})},t.prototype.embedIntoContext=function(e,r){return __awaiter(this,void 0,void 0,function(){var n;return __generator(this,function(a){return n=e.stream(this.imageData,{Type:"XObject",Subtype:"Image",BitsPerComponent:this.bitsPerComponent,Width:this.width,Height:this.height,ColorSpace:this.colorSpace,Filter:"DCTDecode",Decode:this.colorSpace===ColorSpace.DeviceCMYK?[1,0,1,0,1,0,1,0]:void 0}),r?(e.assign(r,n),[2,r]):[2,e.register(n)]})})},t}(),UPNG={};UPNG.toRGBA8=function(t){var e=t.width,r=t.height;if(t.tabs.acTL==null)return[UPNG.toRGBA8.decodeImage(t.data,e,r,t).buffer];var n=[];t.frames[0].data==null&&(t.frames[0].data=t.data);for(var a=e*r*4,s=new Uint8Array(a),o=new Uint8Array(a),h=new Uint8Array(a),d=0;d<t.frames.length;d++){var l=t.frames[d],u=l.rect.x,p=l.rect.y,g=l.rect.width,f=l.rect.height,v=UPNG.toRGBA8.decodeImage(l.data,g,f,t);if(d!=0)for(var y=0;y<a;y++)h[y]=s[y];if(l.blend==0?UPNG._copyTile(v,g,f,s,e,r,u,p,0):l.blend==1&&UPNG._copyTile(v,g,f,s,e,r,u,p,1),n.push(s.buffer.slice(0)),l.dispose!=0){if(l.dispose==1)UPNG._copyTile(o,g,f,s,e,r,u,p,0);else if(l.dispose==2)for(var y=0;y<a;y++)s[y]=h[y]}}return n},UPNG.toRGBA8.decodeImage=function(t,e,r,n){var a=e*r,s=UPNG.decode._getBPP(n),o=Math.ceil(e*s/8),h=new Uint8Array(a*4),d=new Uint32Array(h.buffer),l=n.ctype,u=n.depth,p=UPNG._bin.readUshort;if(l==6){var g=a<<2;if(u==8)for(var f=0;f<g;f+=4)h[f]=t[f],h[f+1]=t[f+1],h[f+2]=t[f+2],h[f+3]=t[f+3];if(u==16)for(var f=0;f<g;f++)h[f]=t[f<<1]}else if(l==2){var v=n.tabs.tRNS;if(v==null){if(u==8)for(var f=0;f<a;f++){var y=f*3;d[f]=255<<24|t[y+2]<<16|t[y+1]<<8|t[y]}if(u==16)for(var f=0;f<a;f++){var y=f*6;d[f]=255<<24|t[y+4]<<16|t[y+2]<<8|t[y]}}else{var x=v[0],m=v[1],w=v[2];if(u==8)for(var f=0;f<a;f++){var R=f<<2,y=f*3;d[f]=255<<24|t[y+2]<<16|t[y+1]<<8|t[y],t[y]==x&&t[y+1]==m&&t[y+2]==w&&(h[R+3]=0)}if(u==16)for(var f=0;f<a;f++){var R=f<<2,y=f*6;d[f]=255<<24|t[y+4]<<16|t[y+2]<<8|t[y],p(t,y)==x&&p(t,y+2)==m&&p(t,y+4)==w&&(h[R+3]=0)}}}else if(l==3){var _=n.tabs.PLTE,S=n.tabs.tRNS,F=S?S.length:0;if(u==1)for(var A=0;A<r;A++)for(var D=A*o,T=A*e,f=0;f<e;f++){var R=T+f<<2,M=t[D+(f>>3)]>>7-((f&7)<<0)&1,C=3*M;h[R]=_[C],h[R+1]=_[C+1],h[R+2]=_[C+2],h[R+3]=M<F?S[M]:255}if(u==2)for(var A=0;A<r;A++)for(var D=A*o,T=A*e,f=0;f<e;f++){var R=T+f<<2,M=t[D+(f>>2)]>>6-((f&3)<<1)&3,C=3*M;h[R]=_[C],h[R+1]=_[C+1],h[R+2]=_[C+2],h[R+3]=M<F?S[M]:255}if(u==4)for(var A=0;A<r;A++)for(var D=A*o,T=A*e,f=0;f<e;f++){var R=T+f<<2,M=t[D+(f>>1)]>>4-((f&1)<<2)&15,C=3*M;h[R]=_[C],h[R+1]=_[C+1],h[R+2]=_[C+2],h[R+3]=M<F?S[M]:255}if(u==8)for(var f=0;f<a;f++){var R=f<<2,M=t[f],C=3*M;h[R]=_[C],h[R+1]=_[C+1],h[R+2]=_[C+2],h[R+3]=M<F?S[M]:255}}else if(l==4){if(u==8)for(var f=0;f<a;f++){var R=f<<2,k=f<<1,O=t[k];h[R]=O,h[R+1]=O,h[R+2]=O,h[R+3]=t[k+1]}if(u==16)for(var f=0;f<a;f++){var R=f<<2,k=f<<2,O=t[k];h[R]=O,h[R+1]=O,h[R+2]=O,h[R+3]=t[k+2]}}else if(l==0)for(var x=n.tabs.tRNS?n.tabs.tRNS:-1,A=0;A<r;A++){var $=A*o,K=A*e;if(u==1)for(var J=0;J<e;J++){var O=255*(t[$+(J>>>3)]>>>7-(J&7)&1),Y=O==x*255?0:255;d[K+J]=Y<<24|O<<16|O<<8|O}else if(u==2)for(var J=0;J<e;J++){var O=85*(t[$+(J>>>2)]>>>6-((J&3)<<1)&3),Y=O==x*85?0:255;d[K+J]=Y<<24|O<<16|O<<8|O}else if(u==4)for(var J=0;J<e;J++){var O=17*(t[$+(J>>>1)]>>>4-((J&1)<<2)&15),Y=O==x*17?0:255;d[K+J]=Y<<24|O<<16|O<<8|O}else if(u==8)for(var J=0;J<e;J++){var O=t[$+J],Y=O==x?0:255;d[K+J]=Y<<24|O<<16|O<<8|O}else if(u==16)for(var J=0;J<e;J++){var O=t[$+(J<<1)],Y=p(t,$+(J<<f))==x?0:255;d[K+J]=Y<<24|O<<16|O<<8|O}}return h},UPNG.decode=function(t){for(var e=new Uint8Array(t),r=8,n=UPNG._bin,a=n.readUshort,s=n.readUint,o={tabs:{},frames:[]},h=new Uint8Array(e.length),d=0,l,u=0,p=[137,80,78,71,13,10,26,10],g=0;g<8;g++)if(e[g]!=p[g])throw"The input is not a PNG file!";for(;r<e.length;){var f=n.readUint(e,r);r+=4;var v=n.readASCII(e,r,4);if(r+=4,v=="IHDR")UPNG.decode._IHDR(e,r,o);else if(v=="IDAT"){for(var g=0;g<f;g++)h[d+g]=e[r+g];d+=f}else if(v=="acTL")o.tabs[v]={num_frames:s(e,r),num_plays:s(e,r+4)},l=new Uint8Array(e.length);else if(v=="fcTL"){if(u!=0){var y=o.frames[o.frames.length-1];y.data=UPNG.decode._decompress(o,l.slice(0,u),y.rect.width,y.rect.height),u=0}var x={x:s(e,r+12),y:s(e,r+16),width:s(e,r+4),height:s(e,r+8)},m=a(e,r+22);m=a(e,r+20)/(m==0?100:m);var w={rect:x,delay:Math.round(m*1e3),dispose:e[r+24],blend:e[r+25]};o.frames.push(w)}else if(v=="fdAT"){for(var g=0;g<f-4;g++)l[u+g]=e[r+g+4];u+=f-4}else if(v=="pHYs")o.tabs[v]=[n.readUint(e,r),n.readUint(e,r+4),e[r+8]];else if(v=="cHRM"){o.tabs[v]=[];for(var g=0;g<8;g++)o.tabs[v].push(n.readUint(e,r+g*4))}else if(v=="tEXt"){o.tabs[v]==null&&(o.tabs[v]={});var R=n.nextZero(e,r),_=n.readASCII(e,r,R-r),S=n.readASCII(e,R+1,r+f-R-1);o.tabs[v][_]=S}else if(v=="iTXt"){o.tabs[v]==null&&(o.tabs[v]={});var R=0,F=r;R=n.nextZero(e,F);var _=n.readASCII(e,F,R-F);F=R+1,e[F],e[F+1],F+=2,R=n.nextZero(e,F),n.readASCII(e,F,R-F),F=R+1,R=n.nextZero(e,F),n.readUTF8(e,F,R-F),F=R+1;var S=n.readUTF8(e,F,f-(F-r));o.tabs[v][_]=S}else if(v=="PLTE")o.tabs[v]=n.readBytes(e,r,f);else if(v=="hIST"){var A=o.tabs.PLTE.length/3;o.tabs[v]=[];for(var g=0;g<A;g++)o.tabs[v].push(a(e,r+g*2))}else if(v=="tRNS")o.ctype==3?o.tabs[v]=n.readBytes(e,r,f):o.ctype==0?o.tabs[v]=a(e,r):o.ctype==2&&(o.tabs[v]=[a(e,r),a(e,r+2),a(e,r+4)]);else if(v=="gAMA")o.tabs[v]=n.readUint(e,r)/1e5;else if(v=="sRGB")o.tabs[v]=e[r];else if(v=="bKGD")o.ctype==0||o.ctype==4?o.tabs[v]=[a(e,r)]:o.ctype==2||o.ctype==6?o.tabs[v]=[a(e,r),a(e,r+2),a(e,r+4)]:o.ctype==3&&(o.tabs[v]=e[r]);else if(v=="IEND")break;r+=f,n.readUint(e,r),r+=4}if(u!=0){var y=o.frames[o.frames.length-1];y.data=UPNG.decode._decompress(o,l.slice(0,u),y.rect.width,y.rect.height),u=0}return o.data=UPNG.decode._decompress(o,h,o.width,o.height),delete o.compress,delete o.interlace,delete o.filter,o},UPNG.decode._decompress=function(t,e,r,n){var a=UPNG.decode._getBPP(t),s=Math.ceil(r*a/8),o=new Uint8Array((s+1+t.interlace)*n);return e=UPNG.decode._inflate(e,o),t.interlace==0?e=UPNG.decode._filterZero(e,t,0,r,n):t.interlace==1&&(e=UPNG.decode._readInterlace(e,t)),e},UPNG.decode._inflate=function(t,e){var r=UPNG.inflateRaw(new Uint8Array(t.buffer,2,t.length-6),e);return r},UPNG.inflateRaw=function(){var t={};return t.H={},t.H.N=function(e,r){var n=Uint8Array,a=0,s=0,o=0,h=0,d=0,l=0,u=0,p=0,g=0,f,v;if(e[0]==3&&e[1]==0)return r||new n(0);var y=t.H,x=y.b,m=y.e,w=y.R,R=y.n,_=y.A,S=y.Z,F=y.m,A=r==null;for(A&&(r=new n(e.length>>>2<<3));a==0;){if(a=x(e,g,1),s=x(e,g+1,2),g+=3,s==0){g&7&&(g+=8-(g&7));var D=(g>>>3)+4,T=e[D-4]|e[D-3]<<8;A&&(r=t.H.W(r,p+T)),r.set(new n(e.buffer,e.byteOffset+D,T),p),g=D+T<<3,p+=T;continue}if(A&&(r=t.H.W(r,p+(1<<17))),s==1&&(f=F.J,v=F.h,l=511,u=31),s==2){o=m(e,g,5)+257,h=m(e,g+5,5)+1,d=m(e,g+10,4)+4,g+=14;for(var M=1,C=0;C<38;C+=2)F.Q[C]=0,F.Q[C+1]=0;for(var C=0;C<d;C++){var k=m(e,g+C*3,3);F.Q[(F.X[C]<<1)+1]=k,k>M&&(M=k)}g+=3*d,R(F.Q,M),_(F.Q,M,F.u),f=F.w,v=F.d,g=w(F.u,(1<<M)-1,o+h,e,g,F.v);var O=y.V(F.v,0,o,F.C);l=(1<<O)-1;var $=y.V(F.v,o,h,F.D);u=(1<<$)-1,R(F.C,O),_(F.C,O,f),R(F.D,$),_(F.D,$,v)}for(;;){var K=f[S(e,g)&l];g+=K&15;var J=K>>>4;if(!(J>>>8))r[p++]=J;else{if(J==256)break;var Y=p+J-254;if(J>264){var se=F.q[J-257];Y=p+(se>>>3)+m(e,g,se&7),g+=se&7}var B=v[S(e,g)&u];g+=B&15;var V=B>>>4,Q=F.c[V],N=(Q>>>4)+x(e,g,Q&15);for(g+=Q&15;p<Y;)r[p]=r[p++-N],r[p]=r[p++-N],r[p]=r[p++-N],r[p]=r[p++-N];p=Y}}}return r.length==p?r:r.slice(0,p)},t.H.W=function(e,r){var n=e.length;if(r<=n)return e;var a=new Uint8Array(n<<1);return a.set(e,0),a},t.H.R=function(e,r,n,a,s,o){for(var h=t.H.e,d=t.H.Z,l=0;l<n;){var u=e[d(a,s)&r];s+=u&15;var p=u>>>4;if(p<=15)o[l]=p,l++;else{var g=0,f=0;p==16?(f=3+h(a,s,2),s+=2,g=o[l-1]):p==17?(f=3+h(a,s,3),s+=3):p==18&&(f=11+h(a,s,7),s+=7);for(var v=l+f;l<v;)o[l]=g,l++}}return s},t.H.V=function(e,r,n,a){for(var s=0,o=0,h=a.length>>>1;o<n;){var d=e[o+r];a[o<<1]=0,a[(o<<1)+1]=d,d>s&&(s=d),o++}for(;o<h;)a[o<<1]=0,a[(o<<1)+1]=0,o++;return s},t.H.n=function(e,r){for(var n=t.H.m,a=e.length,s,o,h,d,l,u=n.j,d=0;d<=r;d++)u[d]=0;for(d=1;d<a;d+=2)u[e[d]]++;var p=n.K;for(s=0,u[0]=0,o=1;o<=r;o++)s=s+u[o-1]<<1,p[o]=s;for(h=0;h<a;h+=2)l=e[h+1],l!=0&&(e[h]=p[l],p[l]++)},t.H.A=function(e,r,n){for(var a=e.length,s=t.H.m,o=s.r,h=0;h<a;h+=2)if(e[h+1]!=0)for(var d=h>>1,l=e[h+1],u=d<<4|l,p=r-l,g=e[h]<<p,f=g+(1<<p);g!=f;){var v=o[g]>>>15-r;n[v]=u,g++}},t.H.l=function(e,r){for(var n=t.H.m.r,a=15-r,s=0;s<e.length;s+=2){var o=e[s]<<r-e[s+1];e[s]=n[o]>>>a}},t.H.M=function(e,r,n){n=n<<(r&7);var a=r>>>3;e[a]|=n,e[a+1]|=n>>>8},t.H.I=function(e,r,n){n=n<<(r&7);var a=r>>>3;e[a]|=n,e[a+1]|=n>>>8,e[a+2]|=n>>>16},t.H.e=function(e,r,n){return(e[r>>>3]|e[(r>>>3)+1]<<8)>>>(r&7)&(1<<n)-1},t.H.b=function(e,r,n){return(e[r>>>3]|e[(r>>>3)+1]<<8|e[(r>>>3)+2]<<16)>>>(r&7)&(1<<n)-1},t.H.Z=function(e,r){return(e[r>>>3]|e[(r>>>3)+1]<<8|e[(r>>>3)+2]<<16)>>>(r&7)},t.H.i=function(e,r){return(e[r>>>3]|e[(r>>>3)+1]<<8|e[(r>>>3)+2]<<16|e[(r>>>3)+3]<<24)>>>(r&7)},t.H.m=function(){var e=Uint16Array,r=Uint32Array;return{K:new e(16),j:new e(16),X:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],S:[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,999,999,999],T:[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0],q:new e(32),p:[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,65535,65535],z:[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0],c:new r(32),J:new e(512),_:[],h:new e(32),$:[],w:new e(32768),C:[],v:[],d:new e(32768),D:[],u:new e(512),Q:[],r:new e(32768),s:new r(286),Y:new r(30),a:new r(19),t:new r(15e3),k:new e(65536),g:new e(32768)}}(),function(){for(var e=t.H.m,r=32768,n=0;n<r;n++){var a=n;a=(a&2863311530)>>>1|(a&1431655765)<<1,a=(a&3435973836)>>>2|(a&858993459)<<2,a=(a&4042322160)>>>4|(a&252645135)<<4,a=(a&4278255360)>>>8|(a&16711935)<<8,e.r[n]=(a>>>16|a<<16)>>>17}function s(o,h,d){for(;h--!=0;)o.push(0,d)}for(var n=0;n<32;n++)e.q[n]=e.S[n]<<3|e.T[n],e.c[n]=e.p[n]<<4|e.z[n];s(e._,144,8),s(e._,112,9),s(e._,24,7),s(e._,8,8),t.H.n(e._,9),t.H.A(e._,9,e.J),t.H.l(e._,9),s(e.$,32,5),t.H.n(e.$,5),t.H.A(e.$,5,e.h),t.H.l(e.$,5),s(e.Q,19,0),s(e.C,286,0),s(e.D,30,0),s(e.v,320,0)}(),t.H.N}(),UPNG.decode._readInterlace=function(t,e){for(var r=e.width,n=e.height,a=UPNG.decode._getBPP(e),s=a>>3,o=Math.ceil(r*a/8),h=new Uint8Array(n*o),d=0,l=[0,0,4,0,2,0,1],u=[0,4,0,2,0,1,0],p=[8,8,8,4,4,2,2],g=[8,8,4,4,2,2,1],f=0;f<7;){for(var v=p[f],y=g[f],x=0,m=0,w=l[f];w<n;)w+=v,m++;for(var R=u[f];R<r;)R+=y,x++;var _=Math.ceil(x*a/8);UPNG.decode._filterZero(t,e,d,x,m);for(var S=0,F=l[f];F<n;){for(var A=u[f],D=d+S*_<<3;A<r;){if(a==1){var T=t[D>>3];T=T>>7-(D&7)&1,h[F*o+(A>>3)]|=T<<7-((A&7)<<0)}if(a==2){var T=t[D>>3];T=T>>6-(D&7)&3,h[F*o+(A>>2)]|=T<<6-((A&3)<<1)}if(a==4){var T=t[D>>3];T=T>>4-(D&7)&15,h[F*o+(A>>1)]|=T<<4-((A&1)<<2)}if(a>=8)for(var M=F*o+A*s,C=0;C<s;C++)h[M+C]=t[(D>>3)+C];D+=a,A+=y}S++,F+=v}x*m!=0&&(d+=m*(1+_)),f=f+1}return h},UPNG.decode._getBPP=function(t){var e=[1,null,3,1,2,null,4][t.ctype];return e*t.depth},UPNG.decode._filterZero=function(t,e,r,n,a){var s=UPNG.decode._getBPP(e),o=Math.ceil(n*s/8),h=UPNG.decode._paeth;s=Math.ceil(s/8);var d=0,l=1,u=t[r],p=0;if(u>1&&(t[r]=[0,0,1][u-2]),u==3)for(p=s;p<o;p++)t[p+1]=t[p+1]+(t[p+1-s]>>>1)&255;for(var g=0;g<a;g++)if(d=r+g*o,l=d+g+1,u=t[l-1],p=0,u==0)for(;p<o;p++)t[d+p]=t[l+p];else if(u==1){for(;p<s;p++)t[d+p]=t[l+p];for(;p<o;p++)t[d+p]=t[l+p]+t[d+p-s]}else if(u==2)for(;p<o;p++)t[d+p]=t[l+p]+t[d+p-o];else if(u==3){for(;p<s;p++)t[d+p]=t[l+p]+(t[d+p-o]>>>1);for(;p<o;p++)t[d+p]=t[l+p]+(t[d+p-o]+t[d+p-s]>>>1)}else{for(;p<s;p++)t[d+p]=t[l+p]+h(0,t[d+p-o],0);for(;p<o;p++)t[d+p]=t[l+p]+h(t[d+p-s],t[d+p-o],t[d+p-s-o])}return t},UPNG.decode._paeth=function(t,e,r){var n=t+e-r,a=n-t,s=n-e,o=n-r;return a*a<=s*s&&a*a<=o*o?t:s*s<=o*o?e:r},UPNG.decode._IHDR=function(t,e,r){var n=UPNG._bin;r.width=n.readUint(t,e),e+=4,r.height=n.readUint(t,e),e+=4,r.depth=t[e],e++,r.ctype=t[e],e++,r.compress=t[e],e++,r.filter=t[e],e++,r.interlace=t[e],e++},UPNG._bin={nextZero:function(t,e){for(;t[e]!=0;)e++;return e},readUshort:function(t,e){return t[e]<<8|t[e+1]},writeUshort:function(t,e,r){t[e]=r>>8&255,t[e+1]=r&255},readUint:function(t,e){return t[e]*(256*256*256)+(t[e+1]<<16|t[e+2]<<8|t[e+3])},writeUint:function(t,e,r){t[e]=r>>24&255,t[e+1]=r>>16&255,t[e+2]=r>>8&255,t[e+3]=r&255},readASCII:function(t,e,r){for(var n="",a=0;a<r;a++)n+=String.fromCharCode(t[e+a]);return n},writeASCII:function(t,e,r){for(var n=0;n<r.length;n++)t[e+n]=r.charCodeAt(n)},readBytes:function(t,e,r){for(var n=[],a=0;a<r;a++)n.push(t[e+a]);return n},pad:function(t){return t.length<2?"0"+t:t},readUTF8:function(t,e,r){for(var n="",a,s=0;s<r;s++)n+="%"+UPNG._bin.pad(t[e+s].toString(16));try{a=decodeURIComponent(n)}catch{return UPNG._bin.readASCII(t,e,r)}return a}},UPNG._copyTile=function(t,e,r,n,a,s,o,h,d){for(var l=Math.min(e,a),u=Math.min(r,s),p=0,g=0,f=0;f<u;f++)for(var v=0;v<l;v++)if(o>=0&&h>=0?(p=f*e+v<<2,g=(h+f)*a+o+v<<2):(p=(-h+f)*e-o+v<<2,g=f*a+v<<2),d==0)n[g]=t[p],n[g+1]=t[p+1],n[g+2]=t[p+2],n[g+3]=t[p+3];else if(d==1){var y=t[p+3]*.00392156862745098,x=t[p]*y,m=t[p+1]*y,w=t[p+2]*y,R=n[g+3]*(1/255),_=n[g]*R,S=n[g+1]*R,F=n[g+2]*R,A=1-y,D=y+R*A,T=D==0?0:1/D;n[g+3]=255*D,n[g+0]=(x+_*A)*T,n[g+1]=(m+S*A)*T,n[g+2]=(w+F*A)*T}else if(d==2){var y=t[p+3],x=t[p],m=t[p+1],w=t[p+2],R=n[g+3],_=n[g],S=n[g+1],F=n[g+2];y==R&&x==_&&m==S&&w==F?(n[g]=0,n[g+1]=0,n[g+2]=0,n[g+3]=0):(n[g]=x,n[g+1]=m,n[g+2]=w,n[g+3]=y)}else if(d==3){var y=t[p+3],x=t[p],m=t[p+1],w=t[p+2],R=n[g+3],_=n[g],S=n[g+1],F=n[g+2];if(y==R&&x==_&&m==S&&w==F)continue;if(y<220&&R>20)return!1}return!0},UPNG.encode=function(t,e,r,n,a,s,o){n==null&&(n=0),o==null&&(o=!1);var h=UPNG.encode.compress(t,e,r,n,[!1,!1,!1,0,o]);return UPNG.encode.compressPNG(h,-1),UPNG.encode._main(h,e,r,a,s)},UPNG.encodeLL=function(t,e,r,n,a,s,o,h){for(var d={ctype:0+(n==1?0:2)+(a==0?0:4),depth:s,frames:[]},l=(n+a)*s,u=l*e,p=0;p<t.length;p++)d.frames.push({rect:{x:0,y:0,width:e,height:r},img:new Uint8Array(t[p]),blend:0,dispose:1,bpp:Math.ceil(l/8),bpl:Math.ceil(u/8)});UPNG.encode.compressPNG(d,0,!0);var g=UPNG.encode._main(d,e,r,o,h);return g},UPNG.encode._main=function(t,e,r,n,a){a==null&&(a={});var s=UPNG.crc.crc,o=UPNG._bin.writeUint,h=UPNG._bin.writeUshort,d=UPNG._bin.writeASCII,l=8,u=t.frames.length>1,p=!1,g=33+(u?20:0);if(a.sRGB!=null&&(g+=13),a.pHYs!=null&&(g+=21),t.ctype==3){for(var f=t.plte.length,v=0;v<f;v++)t.plte[v]>>>24!=255&&(p=!0);g+=8+f*3+4+(p?8+f*1+4:0)}for(var y=0;y<t.frames.length;y++){var x=t.frames[y];u&&(g+=38),g+=x.cimg.length+12,y!=0&&(g+=4)}g+=12;for(var m=new Uint8Array(g),w=[137,80,78,71,13,10,26,10],v=0;v<8;v++)m[v]=w[v];if(o(m,l,13),l+=4,d(m,l,"IHDR"),l+=4,o(m,l,e),l+=4,o(m,l,r),l+=4,m[l]=t.depth,l++,m[l]=t.ctype,l++,m[l]=0,l++,m[l]=0,l++,m[l]=0,l++,o(m,l,s(m,l-17,17)),l+=4,a.sRGB!=null&&(o(m,l,1),l+=4,d(m,l,"sRGB"),l+=4,m[l]=a.sRGB,l++,o(m,l,s(m,l-5,5)),l+=4),a.pHYs!=null&&(o(m,l,9),l+=4,d(m,l,"pHYs"),l+=4,o(m,l,a.pHYs[0]),l+=4,o(m,l,a.pHYs[1]),l+=4,m[l]=a.pHYs[2],l++,o(m,l,s(m,l-13,13)),l+=4),u&&(o(m,l,8),l+=4,d(m,l,"acTL"),l+=4,o(m,l,t.frames.length),l+=4,o(m,l,a.loop!=null?a.loop:0),l+=4,o(m,l,s(m,l-12,12)),l+=4),t.ctype==3){var f=t.plte.length;o(m,l,f*3),l+=4,d(m,l,"PLTE"),l+=4;for(var v=0;v<f;v++){var R=v*3,_=t.plte[v],S=_&255,F=_>>>8&255,A=_>>>16&255;m[l+R+0]=S,m[l+R+1]=F,m[l+R+2]=A}if(l+=f*3,o(m,l,s(m,l-f*3-4,f*3+4)),l+=4,p){o(m,l,f),l+=4,d(m,l,"tRNS"),l+=4;for(var v=0;v<f;v++)m[l+v]=t.plte[v]>>>24&255;l+=f,o(m,l,s(m,l-f-4,f+4)),l+=4}}for(var D=0,y=0;y<t.frames.length;y++){var x=t.frames[y];u&&(o(m,l,26),l+=4,d(m,l,"fcTL"),l+=4,o(m,l,D++),l+=4,o(m,l,x.rect.width),l+=4,o(m,l,x.rect.height),l+=4,o(m,l,x.rect.x),l+=4,o(m,l,x.rect.y),l+=4,h(m,l,n[y]),l+=2,h(m,l,1e3),l+=2,m[l]=x.dispose,l++,m[l]=x.blend,l++,o(m,l,s(m,l-30,30)),l+=4);var T=x.cimg,f=T.length;o(m,l,f+(y==0?0:4)),l+=4;var M=l;d(m,l,y==0?"IDAT":"fdAT"),l+=4,y!=0&&(o(m,l,D++),l+=4),m.set(T,l),l+=f,o(m,l,s(m,M,l-M)),l+=4}return o(m,l,0),l+=4,d(m,l,"IEND"),l+=4,o(m,l,s(m,l-4,4)),l+=4,m.buffer},UPNG.encode.compressPNG=function(t,e,r){for(var n=0;n<t.frames.length;n++){var a=t.frames[n];a.rect.width;var s=a.rect.height,o=new Uint8Array(s*a.bpl+s);a.cimg=UPNG.encode._filterZero(a.img,s,a.bpp,a.bpl,o,e,r)}},UPNG.encode.compress=function(t,e,r,n,a){for(var s=a[0],o=a[1],h=a[2],d=a[3],l=a[4],u=6,p=8,g=255,f=0;f<t.length;f++)for(var v=new Uint8Array(t[f]),y=v.length,x=0;x<y;x+=4)g&=v[x+3];var m=g!=255,w=UPNG.encode.framize(t,e,r,s,o,h),R={},_=[],S=[];if(n!=0){for(var F=[],x=0;x<w.length;x++)F.push(w[x].img.buffer);for(var A=UPNG.encode.concatRGBA(F),D=UPNG.quantize(A,n),T=0,M=new Uint8Array(D.abuf),x=0;x<w.length;x++){var C=w[x].img,k=C.length;S.push(new Uint8Array(D.inds.buffer,T>>2,k>>2));for(var f=0;f<k;f+=4)C[f]=M[T+f],C[f+1]=M[T+f+1],C[f+2]=M[T+f+2],C[f+3]=M[T+f+3];T+=k}for(var x=0;x<D.plte.length;x++)_.push(D.plte[x].est.rgba)}else for(var f=0;f<w.length;f++){var O=w[f],$=new Uint32Array(O.img.buffer),K=O.rect.width,y=$.length,J=new Uint8Array(y);S.push(J);for(var x=0;x<y;x++){var Y=$[x];if(x!=0&&Y==$[x-1])J[x]=J[x-1];else if(x>K&&Y==$[x-K])J[x]=J[x-K];else{var se=R[Y];if(se==null&&(R[Y]=se=_.length,_.push(Y),_.length>=300))break;J[x]=se}}}var B=_.length;B<=256&&l==!1&&(B<=2?p=1:B<=4?p=2:B<=16?p=4:p=8,p=Math.max(p,d));for(var f=0;f<w.length;f++){var O=w[f];O.rect.x,O.rect.y;var K=O.rect.width,V=O.rect.height,Q=O.img;new Uint32Array(Q.buffer);var N=4*K,P=4;if(B<=256&&l==!1){N=Math.ceil(p*K/8);for(var E=new Uint8Array(N*V),I=S[f],z=0;z<V;z++){var x=z*N,G=z*K;if(p==8)for(var H=0;H<K;H++)E[x+H]=I[G+H];else if(p==4)for(var H=0;H<K;H++)E[x+(H>>1)]|=I[G+H]<<4-(H&1)*4;else if(p==2)for(var H=0;H<K;H++)E[x+(H>>2)]|=I[G+H]<<6-(H&3)*2;else if(p==1)for(var H=0;H<K;H++)E[x+(H>>3)]|=I[G+H]<<7-(H&7)*1}Q=E,u=3,P=1}else if(m==!1&&w.length==1){for(var E=new Uint8Array(K*V*3),ee=K*V,x=0;x<ee;x++){var C=x*3,ce=x*4;E[C]=Q[ce],E[C+1]=Q[ce+1],E[C+2]=Q[ce+2]}Q=E,u=2,P=3,N=3*K}O.img=Q,O.bpl=N,O.bpp=P}return{ctype:u,depth:p,plte:_,frames:w}},UPNG.encode.framize=function(t,e,r,n,a,s){for(var o=[],h=0;h<t.length;h++){var d=new Uint8Array(t[h]),l=new Uint32Array(d.buffer),u,p=0,g=0,f=e,v=r,y=n?1:0;if(h!=0){for(var x=s||n||h==1||o[h-2].dispose!=0?1:2,m=0,w=1e9,R=0;R<x;R++){for(var O=new Uint8Array(t[h-1-R]),_=new Uint32Array(t[h-1-R]),S=e,F=r,A=-1,D=-1,T=0;T<r;T++)for(var M=0;M<e;M++){var C=T*e+M;l[C]!=_[C]&&(M<S&&(S=M),M>A&&(A=M),T<F&&(F=T),T>D&&(D=T))}A==-1&&(S=F=A=D=0),a&&((S&1)==1&&S--,(F&1)==1&&F--);var k=(A-S+1)*(D-F+1);k<w&&(w=k,m=R,p=S,g=F,f=A-S+1,v=D-F+1)}var O=new Uint8Array(t[h-1-m]);m==1&&(o[h-1].dispose=2),u=new Uint8Array(f*v*4),UPNG._copyTile(O,e,r,u,f,v,-p,-g,0),y=UPNG._copyTile(d,e,r,u,f,v,-p,-g,3)?1:0,y==1?UPNG.encode._prepareDiff(d,e,r,u,{x:p,y:g,width:f,height:v}):UPNG._copyTile(d,e,r,u,f,v,-p,-g,0)}else u=d.slice(0);o.push({rect:{x:p,y:g,width:f,height:v},img:u,blend:y,dispose:0})}if(n)for(var h=0;h<o.length;h++){var $=o[h];if($.blend!=1){var K=$.rect,J=o[h-1].rect,Y=Math.min(K.x,J.x),se=Math.min(K.y,J.y),B=Math.max(K.x+K.width,J.x+J.width),V=Math.max(K.y+K.height,J.y+J.height),Q={x:Y,y:se,width:B-Y,height:V-se};o[h-1].dispose=1,h-1!=0&&UPNG.encode._updateFrame(t,e,r,o,h-1,Q,a),UPNG.encode._updateFrame(t,e,r,o,h,Q,a)}}var N=0;if(t.length!=1)for(var C=0;C<o.length;C++){var $=o[C];N+=$.rect.width*$.rect.height}return o},UPNG.encode._updateFrame=function(t,e,r,n,a,s,o){for(var h=Uint8Array,d=Uint32Array,l=new h(t[a-1]),u=new d(t[a-1]),p=a+1<t.length?new h(t[a+1]):null,g=new h(t[a]),f=new d(g.buffer),v=e,y=r,x=-1,m=-1,w=0;w<s.height;w++)for(var R=0;R<s.width;R++){var _=s.x+R,S=s.y+w,F=S*e+_,A=f[F];A==0||n[a-1].dispose==0&&u[F]==A&&(p==null||p[F*4+3]!=0)||(_<v&&(v=_),_>x&&(x=_),S<y&&(y=S),S>m&&(m=S))}x==-1&&(v=y=x=m=0),o&&((v&1)==1&&v--,(y&1)==1&&y--),s={x:v,y,width:x-v+1,height:m-y+1};var D=n[a];D.rect=s,D.blend=1,D.img=new Uint8Array(s.width*s.height*4),n[a-1].dispose==0?(UPNG._copyTile(l,e,r,D.img,s.width,s.height,-s.x,-s.y,0),UPNG.encode._prepareDiff(g,e,r,D.img,s)):UPNG._copyTile(g,e,r,D.img,s.width,s.height,-s.x,-s.y,0)},UPNG.encode._prepareDiff=function(t,e,r,n,a){UPNG._copyTile(t,e,r,n,a.width,a.height,-a.x,-a.y,2)},UPNG.encode._filterZero=function(t,e,r,n,a,s,o){var h=[],d=[0,1,2,3,4];s!=-1?d=[s]:(e*n>5e5||r==1)&&(d=[0]);var l;o&&(l={level:0});for(var u=o&&UZIP!=null?UZIP:pako,p=0;p<d.length;p++){for(var g=0;g<e;g++)UPNG.encode._filterLine(a,t,g,n,r,d[p]);h.push(u.deflate(a,l))}for(var f,v=1e9,p=0;p<h.length;p++)h[p].length<v&&(f=p,v=h[p].length);return h[f]},UPNG.encode._filterLine=function(t,e,r,n,a,s){var o=r*n,h=o+r,d=UPNG.decode._paeth;if(t[h]=s,h++,s==0)if(n<500)for(var l=0;l<n;l++)t[h+l]=e[o+l];else t.set(new Uint8Array(e.buffer,o,n),h);else if(s==1){for(var l=0;l<a;l++)t[h+l]=e[o+l];for(var l=a;l<n;l++)t[h+l]=e[o+l]-e[o+l-a]+256&255}else if(r==0){for(var l=0;l<a;l++)t[h+l]=e[o+l];if(s==2)for(var l=a;l<n;l++)t[h+l]=e[o+l];if(s==3)for(var l=a;l<n;l++)t[h+l]=e[o+l]-(e[o+l-a]>>1)+256&255;if(s==4)for(var l=a;l<n;l++)t[h+l]=e[o+l]-d(e[o+l-a],0,0)+256&255}else{if(s==2)for(var l=0;l<n;l++)t[h+l]=e[o+l]+256-e[o+l-n]&255;if(s==3){for(var l=0;l<a;l++)t[h+l]=e[o+l]+256-(e[o+l-n]>>1)&255;for(var l=a;l<n;l++)t[h+l]=e[o+l]+256-(e[o+l-n]+e[o+l-a]>>1)&255}if(s==4){for(var l=0;l<a;l++)t[h+l]=e[o+l]+256-d(0,e[o+l-n],0)&255;for(var l=a;l<n;l++)t[h+l]=e[o+l]+256-d(e[o+l-a],e[o+l-n],e[o+l-a-n])&255}}},UPNG.crc={table:function(){for(var t=new Uint32Array(256),e=0;e<256;e++){for(var r=e,n=0;n<8;n++)r&1?r=3988292384^r>>>1:r=r>>>1;t[e]=r}return t}(),update:function(t,e,r,n){for(var a=0;a<n;a++)t=UPNG.crc.table[(t^e[r+a])&255]^t>>>8;return t},crc:function(t,e,r){return UPNG.crc.update(4294967295,t,e,r)^4294967295}},UPNG.quantize=function(t,e){var r=new Uint8Array(t),n=r.slice(0),a=new Uint32Array(n.buffer),s=UPNG.quantize.getKDtree(n,e),o=s[0],h=s[1];UPNG.quantize.planeDst;for(var d=r,l=a,u=d.length,p=new Uint8Array(r.length>>2),g=0;g<u;g+=4){var f=d[g]*.00392156862745098,v=d[g+1]*(1/255),y=d[g+2]*(1/255),x=d[g+3]*(1/255),m=UPNG.quantize.getNearest(o,f,v,y,x);p[g>>2]=m.ind,l[g>>2]=m.est.rgba}return{abuf:n.buffer,inds:p,plte:h}},UPNG.quantize.getKDtree=function(t,e,r){r==null&&(r=1e-4);var n=new Uint32Array(t.buffer),a={i0:0,i1:t.length,bst:null,est:null,tdst:0,left:null,right:null};a.bst=UPNG.quantize.stats(t,a.i0,a.i1),a.est=UPNG.quantize.estats(a.bst);for(var s=[a];s.length<e;){for(var o=0,h=0,d=0;d<s.length;d++)s[d].est.L>o&&(o=s[d].est.L,h=d);if(o<r)break;var l=s[h],u=UPNG.quantize.splitPixels(t,n,l.i0,l.i1,l.est.e,l.est.eMq255),p=l.i0>=u||l.i1<=u;if(p){l.est.L=0;continue}var g={i0:l.i0,i1:u,bst:null,est:null,tdst:0,left:null,right:null};g.bst=UPNG.quantize.stats(t,g.i0,g.i1),g.est=UPNG.quantize.estats(g.bst);var f={i0:u,i1:l.i1,bst:null,est:null,tdst:0,left:null,right:null};f.bst={R:[],m:[],N:l.bst.N-g.bst.N};for(var d=0;d<16;d++)f.bst.R[d]=l.bst.R[d]-g.bst.R[d];for(var d=0;d<4;d++)f.bst.m[d]=l.bst.m[d]-g.bst.m[d];f.est=UPNG.quantize.estats(f.bst),l.left=g,l.right=f,s[h]=g,s.push(f)}s.sort(function(v,y){return y.bst.N-v.bst.N});for(var d=0;d<s.length;d++)s[d].ind=d;return[a,s]},UPNG.quantize.getNearest=function(t,e,r,n,a){if(t.left==null)return t.tdst=UPNG.quantize.dist(t.est.q,e,r,n,a),t;var s=UPNG.quantize.planeDst(t.est,e,r,n,a),o=t.left,h=t.right;s>0&&(o=t.right,h=t.left);var d=UPNG.quantize.getNearest(o,e,r,n,a);if(d.tdst<=s*s)return d;var l=UPNG.quantize.getNearest(h,e,r,n,a);return l.tdst<d.tdst?l:d},UPNG.quantize.planeDst=function(t,e,r,n,a){var s=t.e;return s[0]*e+s[1]*r+s[2]*n+s[3]*a-t.eMq},UPNG.quantize.dist=function(t,e,r,n,a){var s=e-t[0],o=r-t[1],h=n-t[2],d=a-t[3];return s*s+o*o+h*h+d*d},UPNG.quantize.splitPixels=function(t,e,r,n,a,s){var o=UPNG.quantize.vecDot;for(n-=4;r<n;){for(;o(t,r,a)<=s;)r+=4;for(;o(t,n,a)>s;)n-=4;if(r>=n)break;var h=e[r>>2];e[r>>2]=e[n>>2],e[n>>2]=h,r+=4,n-=4}for(;o(t,r,a)>s;)r-=4;return r+4},UPNG.quantize.vecDot=function(t,e,r){return t[e]*r[0]+t[e+1]*r[1]+t[e+2]*r[2]+t[e+3]*r[3]},UPNG.quantize.stats=function(t,e,r){for(var n=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],a=[0,0,0,0],s=r-e>>2,o=e;o<r;o+=4){var h=t[o]*.00392156862745098,d=t[o+1]*(1/255),l=t[o+2]*(1/255),u=t[o+3]*(1/255);a[0]+=h,a[1]+=d,a[2]+=l,a[3]+=u,n[0]+=h*h,n[1]+=h*d,n[2]+=h*l,n[3]+=h*u,n[5]+=d*d,n[6]+=d*l,n[7]+=d*u,n[10]+=l*l,n[11]+=l*u,n[15]+=u*u}return n[4]=n[1],n[8]=n[2],n[9]=n[6],n[12]=n[3],n[13]=n[7],n[14]=n[11],{R:n,m:a,N:s}},UPNG.quantize.estats=function(t){var e=t.R,r=t.m,n=t.N,a=r[0],s=r[1],o=r[2],h=r[3],d=n==0?0:1/n,l=[e[0]-a*a*d,e[1]-a*s*d,e[2]-a*o*d,e[3]-a*h*d,e[4]-s*a*d,e[5]-s*s*d,e[6]-s*o*d,e[7]-s*h*d,e[8]-o*a*d,e[9]-o*s*d,e[10]-o*o*d,e[11]-o*h*d,e[12]-h*a*d,e[13]-h*s*d,e[14]-h*o*d,e[15]-h*h*d],u=l,p=UPNG.M4,g=[.5,.5,.5,.5],f=0,v=0;if(n!=0)for(var y=0;y<10&&(g=p.multVec(u,g),v=Math.sqrt(p.dot(g,g)),g=p.sml(1/v,g),!(Math.abs(v-f)<1e-9));y++)f=v;var x=[a*d,s*d,o*d,h*d],m=p.dot(p.sml(255,x),g);return{Cov:l,q:x,e:g,L:f,eMq255:m,eMq:p.dot(g,x),rgba:(Math.round(255*x[3])<<24|Math.round(255*x[2])<<16|Math.round(255*x[1])<<8|Math.round(255*x[0])<<0)>>>0}},UPNG.M4={multVec:function(t,e){return[t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3],t[4]*e[0]+t[5]*e[1]+t[6]*e[2]+t[7]*e[3],t[8]*e[0]+t[9]*e[1]+t[10]*e[2]+t[11]*e[3],t[12]*e[0]+t[13]*e[1]+t[14]*e[2]+t[15]*e[3]]},dot:function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3]},sml:function(t,e){return[t*e[0],t*e[1],t*e[2],t*e[3]]}},UPNG.encode.concatRGBA=function(t){for(var e=0,r=0;r<t.length;r++)e+=t[r].byteLength;for(var n=new Uint8Array(e),a=0,r=0;r<t.length;r++){for(var s=new Uint8Array(t[r]),o=s.length,h=0;h<o;h+=4){var d=s[h],l=s[h+1],u=s[h+2],p=s[h+3];p==0&&(d=l=u=0),n[a+h]=d,n[a+h+1]=l,n[a+h+2]=u,n[a+h+3]=p}a+=o}return n.buffer};var getImageType=function(t){if(t===0)return PngType.Greyscale;if(t===2)return PngType.Truecolour;if(t===3)return PngType.IndexedColour;if(t===4)return PngType.GreyscaleWithAlpha;if(t===6)return PngType.TruecolourWithAlpha;throw new Error("Unknown color type: "+t)},splitAlphaChannel=function(t){for(var e=Math.floor(t.length/4),r=new Uint8Array(e*3),n=new Uint8Array(e*1),a=0,s=0,o=0;a<t.length;)r[s++]=t[a++],r[s++]=t[a++],r[s++]=t[a++],n[o++]=t[a++];return{rgbChannel:r,alphaChannel:n}},PngType;(function(t){t.Greyscale="Greyscale",t.Truecolour="Truecolour",t.IndexedColour="IndexedColour",t.GreyscaleWithAlpha="GreyscaleWithAlpha",t.TruecolourWithAlpha="TruecolourWithAlpha"})(PngType||(PngType={}));var PNG=function(){function t(e){var r=UPNG.decode(e),n=UPNG.toRGBA8(r);if(n.length>1)throw new Error("Animated PNGs are not supported");var a=new Uint8Array(n[0]),s=splitAlphaChannel(a),o=s.rgbChannel,h=s.alphaChannel;this.rgbChannel=o;var d=h.some(function(l){return l<255});d&&(this.alphaChannel=h),this.type=getImageType(r.ctype),this.width=r.width,this.height=r.height,this.bitsPerComponent=8}return t.load=function(e){return new t(e)},t}(),PngEmbedder=function(){function t(e){this.image=e,this.bitsPerComponent=e.bitsPerComponent,this.width=e.width,this.height=e.height,this.colorSpace="DeviceRGB"}return t.for=function(e){return __awaiter(this,void 0,void 0,function(){var r;return __generator(this,function(n){return r=PNG.load(e),[2,new t(r)]})})},t.prototype.embedIntoContext=function(e,r){return __awaiter(this,void 0,void 0,function(){var n,a;return __generator(this,function(s){return n=this.embedAlphaChannel(e),a=e.flateStream(this.image.rgbChannel,{Type:"XObject",Subtype:"Image",BitsPerComponent:this.image.bitsPerComponent,Width:this.image.width,Height:this.image.height,ColorSpace:this.colorSpace,SMask:n}),r?(e.assign(r,a),[2,r]):[2,e.register(a)]})})},t.prototype.embedAlphaChannel=function(e){if(this.image.alphaChannel){var r=e.flateStream(this.image.alphaChannel,{Type:"XObject",Subtype:"Image",Height:this.image.height,Width:this.image.width,BitsPerComponent:this.image.bitsPerComponent,ColorSpace:"DeviceGray",Decode:[0,1]});return e.register(r)}},t}(),Stream=function(){function t(e,r,n){this.bytes=e,this.start=r||0,this.pos=this.start,this.end=r&&n?r+n:this.bytes.length}return Object.defineProperty(t.prototype,"length",{get:function(){return this.end-this.start},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isEmpty",{get:function(){return this.length===0},enumerable:!1,configurable:!0}),t.prototype.getByte=function(){return this.pos>=this.end?-1:this.bytes[this.pos++]},t.prototype.getUint16=function(){var e=this.getByte(),r=this.getByte();return e===-1||r===-1?-1:(e<<8)+r},t.prototype.getInt32=function(){var e=this.getByte(),r=this.getByte(),n=this.getByte(),a=this.getByte();return(e<<24)+(r<<16)+(n<<8)+a},t.prototype.getBytes=function(e,r){r===void 0&&(r=!1);var n=this.bytes,a=this.pos,s=this.end;if(e){var h=a+e;h>s&&(h=s),this.pos=h;var o=n.subarray(a,h);return r?new Uint8ClampedArray(o):o}else{var o=n.subarray(a,s);return r?new Uint8ClampedArray(o):o}},t.prototype.peekByte=function(){var e=this.getByte();return this.pos--,e},t.prototype.peekBytes=function(e,r){r===void 0&&(r=!1);var n=this.getBytes(e,r);return this.pos-=n.length,n},t.prototype.skip=function(e){e||(e=1),this.pos+=e},t.prototype.reset=function(){this.pos=this.start},t.prototype.moveStart=function(){this.start=this.pos},t.prototype.makeSubStream=function(e,r){return new t(this.bytes,e,r)},t.prototype.decode=function(){return this.bytes},t}(),emptyBuffer=new Uint8Array(0),DecodeStream=function(){function t(e){if(this.pos=0,this.bufferLength=0,this.eof=!1,this.buffer=emptyBuffer,this.minBufferLength=512,e)for(;this.minBufferLength<e;)this.minBufferLength*=2}return Object.defineProperty(t.prototype,"isEmpty",{get:function(){for(;!this.eof&&this.bufferLength===0;)this.readBlock();return this.bufferLength===0},enumerable:!1,configurable:!0}),t.prototype.getByte=function(){for(var e=this.pos;this.bufferLength<=e;){if(this.eof)return-1;this.readBlock()}return this.buffer[this.pos++]},t.prototype.getUint16=function(){var e=this.getByte(),r=this.getByte();return e===-1||r===-1?-1:(e<<8)+r},t.prototype.getInt32=function(){var e=this.getByte(),r=this.getByte(),n=this.getByte(),a=this.getByte();return(e<<24)+(r<<16)+(n<<8)+a},t.prototype.getBytes=function(e,r){r===void 0&&(r=!1);var n,a=this.pos;if(e){for(this.ensureBuffer(a+e),n=a+e;!this.eof&&this.bufferLength<n;)this.readBlock();var s=this.bufferLength;n>s&&(n=s)}else{for(;!this.eof;)this.readBlock();n=this.bufferLength}this.pos=n;var o=this.buffer.subarray(a,n);return r&&!(o instanceof Uint8ClampedArray)?new Uint8ClampedArray(o):o},t.prototype.peekByte=function(){var e=this.getByte();return this.pos--,e},t.prototype.peekBytes=function(e,r){r===void 0&&(r=!1);var n=this.getBytes(e,r);return this.pos-=n.length,n},t.prototype.skip=function(e){e||(e=1),this.pos+=e},t.prototype.reset=function(){this.pos=0},t.prototype.makeSubStream=function(e,r){for(var n=e+r;this.bufferLength<=n&&!this.eof;)this.readBlock();return new Stream(this.buffer,e,r)},t.prototype.decode=function(){for(;!this.eof;)this.readBlock();return this.buffer.subarray(0,this.bufferLength)},t.prototype.readBlock=function(){throw new MethodNotImplementedError(this.constructor.name,"readBlock")},t.prototype.ensureBuffer=function(e){var r=this.buffer;if(e<=r.byteLength)return r;for(var n=this.minBufferLength;n<e;)n*=2;var a=new Uint8Array(n);return a.set(r),this.buffer=a},t}(),isSpace=function(t){return t===32||t===9||t===13||t===10},Ascii85Stream=function(t){__extends(e,t);function e(r,n){var a=t.call(this,n)||this;return a.stream=r,a.input=new Uint8Array(5),n&&(n=.8*n),a}return e.prototype.readBlock=function(){for(var r=126,n=122,a=-1,s=this.stream,o=s.getByte();isSpace(o);)o=s.getByte();if(o===a||o===r){this.eof=!0;return}var h=this.bufferLength,d,l;if(o===n){for(d=this.ensureBuffer(h+4),l=0;l<4;++l)d[h+l]=0;this.bufferLength+=4}else{var u=this.input;for(u[0]=o,l=1;l<5;++l){for(o=s.getByte();isSpace(o);)o=s.getByte();if(u[l]=o,o===a||o===r)break}if(d=this.ensureBuffer(h+l-1),this.bufferLength+=l-1,l<5){for(;l<5;++l)u[l]=117;this.eof=!0}var p=0;for(l=0;l<5;++l)p=p*85+(u[l]-33);for(l=3;l>=0;--l)d[h+l]=p&255,p>>=8}},e}(DecodeStream),AsciiHexStream=function(t){__extends(e,t);function e(r,n){var a=t.call(this,n)||this;return a.stream=r,a.firstDigit=-1,n&&(n=.5*n),a}return e.prototype.readBlock=function(){var r=8e3,n=this.stream.getBytes(r);if(!n.length){this.eof=!0;return}for(var a=n.length+1>>1,s=this.ensureBuffer(this.bufferLength+a),o=this.bufferLength,h=this.firstDigit,d=0,l=n.length;d<l;d++){var u=n[d],p=void 0;if(u>=48&&u<=57)p=u&15;else if(u>=65&&u<=70||u>=97&&u<=102)p=(u&15)+9;else if(u===62){this.eof=!0;break}else continue;h<0?h=p:(s[o++]=h<<4|p,h=-1)}h>=0&&this.eof&&(s[o++]=h<<4,h=-1),this.firstDigit=h,this.bufferLength=o},e}(DecodeStream),codeLenCodeMap=new Int32Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),lengthDecode=new Int32Array([3,4,5,6,7,8,9,10,65547,65549,65551,65553,131091,131095,131099,131103,196643,196651,196659,196667,262211,262227,262243,262259,327811,327843,327875,327907,258,258,258]),distDecode=new Int32Array([1,2,3,4,65541,65543,131081,131085,196625,196633,262177,262193,327745,327777,393345,393409,459009,459137,524801,525057,590849,591361,657409,658433,724993,727041,794625,798721,868353,876545]),fixedLitCodeTab=[new Int32Array([459008,524368,524304,524568,459024,524400,524336,590016,459016,524384,524320,589984,524288,524416,524352,590048,459012,524376,524312,589968,459028,524408,524344,590032,459020,524392,524328,59e4,524296,524424,524360,590064,459010,524372,524308,524572,459026,524404,524340,590024,459018,524388,524324,589992,524292,524420,524356,590056,459014,524380,524316,589976,459030,524412,524348,590040,459022,524396,524332,590008,524300,524428,524364,590072,459009,524370,524306,524570,459025,524402,524338,590020,459017,524386,524322,589988,524290,524418,524354,590052,459013,524378,524314,589972,459029,524410,524346,590036,459021,524394,524330,590004,524298,524426,524362,590068,459011,524374,524310,524574,459027,524406,524342,590028,459019,524390,524326,589996,524294,524422,524358,590060,459015,524382,524318,589980,459031,524414,524350,590044,459023,524398,524334,590012,524302,524430,524366,590076,459008,524369,524305,524569,459024,524401,524337,590018,459016,524385,524321,589986,524289,524417,524353,590050,459012,524377,524313,589970,459028,524409,524345,590034,459020,524393,524329,590002,524297,524425,524361,590066,459010,524373,524309,524573,459026,524405,524341,590026,459018,524389,524325,589994,524293,524421,524357,590058,459014,524381,524317,589978,459030,524413,524349,590042,459022,524397,524333,590010,524301,524429,524365,590074,459009,524371,524307,524571,459025,524403,524339,590022,459017,524387,524323,589990,524291,524419,524355,590054,459013,524379,524315,589974,459029,524411,524347,590038,459021,524395,524331,590006,524299,524427,524363,590070,459011,524375,524311,524575,459027,524407,524343,590030,459019,524391,524327,589998,524295,524423,524359,590062,459015,524383,524319,589982,459031,524415,524351,590046,459023,524399,524335,590014,524303,524431,524367,590078,459008,524368,524304,524568,459024,524400,524336,590017,459016,524384,524320,589985,524288,524416,524352,590049,459012,524376,524312,589969,459028,524408,524344,590033,459020,524392,524328,590001,524296,524424,524360,590065,459010,524372,524308,524572,459026,524404,524340,590025,459018,524388,524324,589993,524292,524420,524356,590057,459014,524380,524316,589977,459030,524412,524348,590041,459022,524396,524332,590009,524300,524428,524364,590073,459009,524370,524306,524570,459025,524402,524338,590021,459017,524386,524322,589989,524290,524418,524354,590053,459013,524378,524314,589973,459029,524410,524346,590037,459021,524394,524330,590005,524298,524426,524362,590069,459011,524374,524310,524574,459027,524406,524342,590029,459019,524390,524326,589997,524294,524422,524358,590061,459015,524382,524318,589981,459031,524414,524350,590045,459023,524398,524334,590013,524302,524430,524366,590077,459008,524369,524305,524569,459024,524401,524337,590019,459016,524385,524321,589987,524289,524417,524353,590051,459012,524377,524313,589971,459028,524409,524345,590035,459020,524393,524329,590003,524297,524425,524361,590067,459010,524373,524309,524573,459026,524405,524341,590027,459018,524389,524325,589995,524293,524421,524357,590059,459014,524381,524317,589979,459030,524413,524349,590043,459022,524397,524333,590011,524301,524429,524365,590075,459009,524371,524307,524571,459025,524403,524339,590023,459017,524387,524323,589991,524291,524419,524355,590055,459013,524379,524315,589975,459029,524411,524347,590039,459021,524395,524331,590007,524299,524427,524363,590071,459011,524375,524311,524575,459027,524407,524343,590031,459019,524391,524327,589999,524295,524423,524359,590063,459015,524383,524319,589983,459031,524415,524351,590047,459023,524399,524335,590015,524303,524431,524367,590079]),9],fixedDistCodeTab=[new Int32Array([327680,327696,327688,327704,327684,327700,327692,327708,327682,327698,327690,327706,327686,327702,327694,0,327681,327697,327689,327705,327685,327701,327693,327709,327683,327699,327691,327707,327687,327703,327695,0]),5],FlateStream=function(t){__extends(e,t);function e(r,n){var a=t.call(this,n)||this;a.stream=r;var s=r.getByte(),o=r.getByte();if(s===-1||o===-1)throw new Error("Invalid header in flate stream: "+s+", "+o);if((s&15)!==8)throw new Error("Unknown compression method in flate stream: "+s+", "+o);if(((s<<8)+o)%31!==0)throw new Error("Bad FCHECK in flate stream: "+s+", "+o);if(o&32)throw new Error("FDICT bit set in flate stream: "+s+", "+o);return a.codeSize=0,a.codeBuf=0,a}return e.prototype.readBlock=function(){var r,n,a=this.stream,s=this.getBits(3);if(s&1&&(this.eof=!0),s>>=1,s===0){var o=void 0;if((o=a.getByte())===-1)throw new Error("Bad block header in flate stream");var h=o;if((o=a.getByte())===-1)throw new Error("Bad block header in flate stream");if(h|=o<<8,(o=a.getByte())===-1)throw new Error("Bad block header in flate stream");var d=o;if((o=a.getByte())===-1)throw new Error("Bad block header in flate stream");if(d|=o<<8,d!==(~h&65535)&&(h!==0||d!==0))throw new Error("Bad uncompressed block length in flate stream");this.codeBuf=0,this.codeSize=0;var l=this.bufferLength;r=this.ensureBuffer(l+h);var u=l+h;if(this.bufferLength=u,h===0)a.peekByte()===-1&&(this.eof=!0);else for(var p=l;p<u;++p){if((o=a.getByte())===-1){this.eof=!0;break}r[p]=o}return}var g,f;if(s===1)g=fixedLitCodeTab,f=fixedDistCodeTab;else if(s===2){var v=this.getBits(5)+257,y=this.getBits(5)+1,x=this.getBits(4)+4,m=new Uint8Array(codeLenCodeMap.length),w=void 0;for(w=0;w<x;++w)m[codeLenCodeMap[w]]=this.getBits(3);var R=this.generateHuffmanTable(m);n=0,w=0;for(var _=v+y,S=new Uint8Array(_),F=void 0,A=void 0,D=void 0;w<_;){var T=this.getCode(R);if(T===16)F=2,A=3,D=n;else if(T===17)F=3,A=3,D=n=0;else if(T===18)F=7,A=11,D=n=0;else{S[w++]=n=T;continue}for(var M=this.getBits(F)+A;M-- >0;)S[w++]=D}g=this.generateHuffmanTable(S.subarray(0,v)),f=this.generateHuffmanTable(S.subarray(v,_))}else throw new Error("Unknown block type in flate stream");r=this.buffer;for(var C=r?r.length:0,k=this.bufferLength;;){var O=this.getCode(g);if(O<256){k+1>=C&&(r=this.ensureBuffer(k+1),C=r.length),r[k++]=O;continue}if(O===256){this.bufferLength=k;return}O-=257,O=lengthDecode[O];var $=O>>16;$>0&&($=this.getBits($)),n=(O&65535)+$,O=this.getCode(f),O=distDecode[O],$=O>>16,$>0&&($=this.getBits($));var K=(O&65535)+$;k+n>=C&&(r=this.ensureBuffer(k+n),C=r.length);for(var J=0;J<n;++J,++k)r[k]=r[k-K]}},e.prototype.getBits=function(r){for(var n=this.stream,a=this.codeSize,s=this.codeBuf,o;a<r;){if((o=n.getByte())===-1)throw new Error("Bad encoding in flate stream");s|=o<<a,a+=8}return o=s&(1<<r)-1,this.codeBuf=s>>r,this.codeSize=a-=r,o},e.prototype.getCode=function(r){for(var n=this.stream,a=r[0],s=r[1],o=this.codeSize,h=this.codeBuf,d;o<s&&(d=n.getByte())!==-1;)h|=d<<o,o+=8;var l=a[h&(1<<s)-1];typeof a=="number"&&console.log("FLATE:",l);var u=l>>16,p=l&65535;if(u<1||o<u)throw new Error("Bad encoding in flate stream");return this.codeBuf=h>>u,this.codeSize=o-u,p},e.prototype.generateHuffmanTable=function(r){var n=r.length,a=0,s;for(s=0;s<n;++s)r[s]>a&&(a=r[s]);for(var o=1<<a,h=new Int32Array(o),d=1,l=0,u=2;d<=a;++d,l<<=1,u<<=1)for(var p=0;p<n;++p)if(r[p]===d){var g=0,f=l;for(s=0;s<d;++s)g=g<<1|f&1,f>>=1;for(s=g;s<o;s+=u)h[s]=d<<16|p;++l}return[h,a]},e}(DecodeStream),LZWStream=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,n)||this;s.stream=r,s.cachedData=0,s.bitsCached=0;for(var o=4096,h={earlyChange:a,codeLength:9,nextCode:258,dictionaryValues:new Uint8Array(o),dictionaryLengths:new Uint16Array(o),dictionaryPrevCodes:new Uint16Array(o),currentSequence:new Uint8Array(o),currentSequenceLength:0},d=0;d<256;++d)h.dictionaryValues[d]=d,h.dictionaryLengths[d]=1;return s.lzwState=h,s}return e.prototype.readBlock=function(){var r=512,n=r*2,a=r,s,o,h,d=this.lzwState;if(d){var l=d.earlyChange,u=d.nextCode,p=d.dictionaryValues,g=d.dictionaryLengths,f=d.dictionaryPrevCodes,v=d.codeLength,y=d.prevCode,x=d.currentSequence,m=d.currentSequenceLength,w=0,R=this.bufferLength,_=this.ensureBuffer(this.bufferLength+n);for(s=0;s<r;s++){var S=this.readBits(v),F=m>0;if(!S||S<256)x[0]=S,m=1;else if(S>=258)if(S<u)for(m=g[S],o=m-1,h=S;o>=0;o--)x[o]=p[h],h=f[h];else x[m++]=x[0];else if(S===256){v=9,u=258,m=0;continue}else{this.eof=!0,delete this.lzwState;break}if(F&&(f[u]=y,g[u]=g[y]+1,p[u]=x[0],u++,v=u+l&u+l-1?v:Math.min(Math.log(u+l)/.6931471805599453+1,12)|0),y=S,w+=m,n<w){do n+=a;while(n<w);_=this.ensureBuffer(this.bufferLength+n)}for(o=0;o<m;o++)_[R++]=x[o]}d.nextCode=u,d.codeLength=v,d.prevCode=y,d.currentSequenceLength=m,this.bufferLength=R}},e.prototype.readBits=function(r){for(var n=this.bitsCached,a=this.cachedData;n<r;){var s=this.stream.getByte();if(s===-1)return this.eof=!0,null;a=a<<8|s,n+=8}return this.bitsCached=n-=r,this.cachedData=a,a>>>n&(1<<r)-1},e}(DecodeStream),RunLengthStream=function(t){__extends(e,t);function e(r,n){var a=t.call(this,n)||this;return a.stream=r,a}return e.prototype.readBlock=function(){var r=this.stream.getBytes(2);if(!r||r.length<2||r[0]===128){this.eof=!0;return}var n,a=this.bufferLength,s=r[0];if(s<128){if(n=this.ensureBuffer(a+s+1),n[a++]=r[1],s>0){var o=this.stream.getBytes(s);n.set(o,a),a+=s}}else{s=257-s;var h=r[1];n=this.ensureBuffer(a+s+1);for(var d=0;d<s;d++)n[a++]=h}this.bufferLength=a},e}(DecodeStream),decodeStream=function(t,e,r){if(e===PDFName.of("FlateDecode"))return new FlateStream(t);if(e===PDFName.of("LZWDecode")){var n=1;if(r instanceof PDFDict){var a=r.lookup(PDFName.of("EarlyChange"));a instanceof PDFNumber&&(n=a.asNumber())}return new LZWStream(t,void 0,n)}if(e===PDFName.of("ASCII85Decode"))return new Ascii85Stream(t);if(e===PDFName.of("ASCIIHexDecode"))return new AsciiHexStream(t);if(e===PDFName.of("RunLengthDecode"))return new RunLengthStream(t);throw new UnsupportedEncodingError(e.asString())},decodePDFRawStream=function(t){var e=t.dict,r=t.contents,n=new Stream(r),a=e.lookup(PDFName.of("Filter")),s=e.lookup(PDFName.of("DecodeParms"));if(a instanceof PDFName)n=decodeStream(n,a,s);else if(a instanceof PDFArray)for(var o=0,h=a.size();o<h;o++)n=decodeStream(n,a.lookup(o,PDFName),s&&s.lookupMaybe(o,PDFDict));else if(a)throw new UnexpectedObjectTypeError([PDFName,PDFArray],a);return n},fullPageBoundingBox=function(t){var e=t.MediaBox(),r=e.lookup(2,PDFNumber).asNumber()-e.lookup(0,PDFNumber).asNumber(),n=e.lookup(3,PDFNumber).asNumber()-e.lookup(1,PDFNumber).asNumber();return{left:0,bottom:0,right:r,top:n}},boundingBoxAdjustedMatrix=function(t){return[1,0,0,1,-t.left,-t.bottom]},PDFPageEmbedder=function(){function t(e,r,n){this.page=e;var a=r??fullPageBoundingBox(e);this.width=a.right-a.left,this.height=a.top-a.bottom,this.boundingBox=a,this.transformationMatrix=n??boundingBoxAdjustedMatrix(a)}return t.for=function(e,r,n){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(a){return[2,new t(e,r,n)]})})},t.prototype.embedIntoContext=function(e,r){return __awaiter(this,void 0,void 0,function(){var n,a,s,o,h,d,l,u,p,g;return __generator(this,function(f){if(n=this.page.normalizedEntries(),a=n.Contents,s=n.Resources,!a)throw new MissingPageContentsEmbeddingError;return o=this.decodeContents(a),h=this.boundingBox,d=h.left,l=h.bottom,u=h.right,p=h.top,g=e.flateStream(o,{Type:"XObject",Subtype:"Form",FormType:1,BBox:[d,l,u,p],Matrix:this.transformationMatrix,Resources:s}),r?(e.assign(r,g),[2,r]):[2,e.register(g)]})})},t.prototype.decodeContents=function(e){for(var r=Uint8Array.of(CharCodes.Newline),n=[],a=0,s=e.size();a<s;a++){var o=e.lookup(a,PDFStream),h=void 0;if(o instanceof PDFRawStream)h=decodePDFRawStream(o).decode();else if(o instanceof PDFContentStream)h=o.getUnencodedContents();else throw new UnrecognizedStreamTypeError(o);n.push(h,r)}return mergeIntoTypedArray.apply(void 0,n)},t}(),asEnum=function(t,e){if(t!==void 0)return e[t]},NonFullScreenPageMode;(function(t){t.UseNone="UseNone",t.UseOutlines="UseOutlines",t.UseThumbs="UseThumbs",t.UseOC="UseOC"})(NonFullScreenPageMode||(NonFullScreenPageMode={}));var ReadingDirection;(function(t){t.L2R="L2R",t.R2L="R2L"})(ReadingDirection||(ReadingDirection={}));var PrintScaling;(function(t){t.None="None",t.AppDefault="AppDefault"})(PrintScaling||(PrintScaling={}));var Duplex;(function(t){t.Simplex="Simplex",t.DuplexFlipShortEdge="DuplexFlipShortEdge",t.DuplexFlipLongEdge="DuplexFlipLongEdge"})(Duplex||(Duplex={}));var ViewerPreferences=function(){function t(e){this.dict=e}return t.prototype.lookupBool=function(e){var r=this.dict.lookup(PDFName.of(e));if(r instanceof PDFBool)return r},t.prototype.lookupName=function(e){var r=this.dict.lookup(PDFName.of(e));if(r instanceof PDFName)return r},t.prototype.HideToolbar=function(){return this.lookupBool("HideToolbar")},t.prototype.HideMenubar=function(){return this.lookupBool("HideMenubar")},t.prototype.HideWindowUI=function(){return this.lookupBool("HideWindowUI")},t.prototype.FitWindow=function(){return this.lookupBool("FitWindow")},t.prototype.CenterWindow=function(){return this.lookupBool("CenterWindow")},t.prototype.DisplayDocTitle=function(){return this.lookupBool("DisplayDocTitle")},t.prototype.NonFullScreenPageMode=function(){return this.lookupName("NonFullScreenPageMode")},t.prototype.Direction=function(){return this.lookupName("Direction")},t.prototype.PrintScaling=function(){return this.lookupName("PrintScaling")},t.prototype.Duplex=function(){return this.lookupName("Duplex")},t.prototype.PickTrayByPDFSize=function(){return this.lookupBool("PickTrayByPDFSize")},t.prototype.PrintPageRange=function(){var e=this.dict.lookup(PDFName.of("PrintPageRange"));if(e instanceof PDFArray)return e},t.prototype.NumCopies=function(){var e=this.dict.lookup(PDFName.of("NumCopies"));if(e instanceof PDFNumber)return e},t.prototype.getHideToolbar=function(){var e,r;return(r=(e=this.HideToolbar())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getHideMenubar=function(){var e,r;return(r=(e=this.HideMenubar())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getHideWindowUI=function(){var e,r;return(r=(e=this.HideWindowUI())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getFitWindow=function(){var e,r;return(r=(e=this.FitWindow())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getCenterWindow=function(){var e,r;return(r=(e=this.CenterWindow())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getDisplayDocTitle=function(){var e,r;return(r=(e=this.DisplayDocTitle())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getNonFullScreenPageMode=function(){var e,r,n=(e=this.NonFullScreenPageMode())===null||e===void 0?void 0:e.decodeText();return(r=asEnum(n,NonFullScreenPageMode))!==null&&r!==void 0?r:NonFullScreenPageMode.UseNone},t.prototype.getReadingDirection=function(){var e,r,n=(e=this.Direction())===null||e===void 0?void 0:e.decodeText();return(r=asEnum(n,ReadingDirection))!==null&&r!==void 0?r:ReadingDirection.L2R},t.prototype.getPrintScaling=function(){var e,r,n=(e=this.PrintScaling())===null||e===void 0?void 0:e.decodeText();return(r=asEnum(n,PrintScaling))!==null&&r!==void 0?r:PrintScaling.AppDefault},t.prototype.getDuplex=function(){var e,r=(e=this.Duplex())===null||e===void 0?void 0:e.decodeText();return asEnum(r,Duplex)},t.prototype.getPickTrayByPDFSize=function(){var e;return(e=this.PickTrayByPDFSize())===null||e===void 0?void 0:e.asBoolean()},t.prototype.getPrintPageRange=function(){var e=this.PrintPageRange();if(!e)return[];for(var r=[],n=0;n<e.size();n+=2){var a=e.lookup(n,PDFNumber).asNumber(),s=e.lookup(n+1,PDFNumber).asNumber();r.push({start:a,end:s})}return r},t.prototype.getNumCopies=function(){var e,r;return(r=(e=this.NumCopies())===null||e===void 0?void 0:e.asNumber())!==null&&r!==void 0?r:1},t.prototype.setHideToolbar=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("HideToolbar"),r)},t.prototype.setHideMenubar=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("HideMenubar"),r)},t.prototype.setHideWindowUI=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("HideWindowUI"),r)},t.prototype.setFitWindow=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("FitWindow"),r)},t.prototype.setCenterWindow=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("CenterWindow"),r)},t.prototype.setDisplayDocTitle=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("DisplayDocTitle"),r)},t.prototype.setNonFullScreenPageMode=function(e){assertIsOneOf(e,"nonFullScreenPageMode",NonFullScreenPageMode);var r=PDFName.of(e);this.dict.set(PDFName.of("NonFullScreenPageMode"),r)},t.prototype.setReadingDirection=function(e){assertIsOneOf(e,"readingDirection",ReadingDirection);var r=PDFName.of(e);this.dict.set(PDFName.of("Direction"),r)},t.prototype.setPrintScaling=function(e){assertIsOneOf(e,"printScaling",PrintScaling);var r=PDFName.of(e);this.dict.set(PDFName.of("PrintScaling"),r)},t.prototype.setDuplex=function(e){assertIsOneOf(e,"duplex",Duplex);var r=PDFName.of(e);this.dict.set(PDFName.of("Duplex"),r)},t.prototype.setPickTrayByPDFSize=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("PickTrayByPDFSize"),r)},t.prototype.setPrintPageRange=function(e){Array.isArray(e)||(e=[e]);for(var r=[],n=0,a=e.length;n<a;n++)r.push(e[n].start),r.push(e[n].end);assertEachIs(r,"printPageRange",["number"]);var s=this.dict.context.obj(r);this.dict.set(PDFName.of("PrintPageRange"),s)},t.prototype.setNumCopies=function(e){assertRange(e,"numCopies",1,Number.MAX_VALUE),assertInteger(e,"numCopies");var r=this.dict.context.obj(e);this.dict.set(PDFName.of("NumCopies"),r)},t.fromDict=function(e){return new t(e)},t.create=function(e){var r=e.obj({});return new t(r)},t}(),tfRegex$1=/\/([^\0\t\n\f\r\ ]+)[\0\t\n\f\r\ ]*(\d*\.\d+|\d+)?[\0\t\n\f\r\ ]+Tf/,PDFAcroField=function(){function t(e,r){this.dict=e,this.ref=r}return t.prototype.T=function(){return this.dict.lookupMaybe(PDFName.of("T"),PDFString,PDFHexString)},t.prototype.Ff=function(){var e=this.getInheritableAttribute(PDFName.of("Ff"));return this.dict.context.lookupMaybe(e,PDFNumber)},t.prototype.V=function(){var e=this.getInheritableAttribute(PDFName.of("V"));return this.dict.context.lookup(e)},t.prototype.Kids=function(){return this.dict.lookupMaybe(PDFName.of("Kids"),PDFArray)},t.prototype.DA=function(){var e=this.dict.lookup(PDFName.of("DA"));if(e instanceof PDFString||e instanceof PDFHexString)return e},t.prototype.setKids=function(e){this.dict.set(PDFName.of("Kids"),this.dict.context.obj(e))},t.prototype.getParent=function(){var e=this.dict.get(PDFName.of("Parent"));if(e instanceof PDFRef){var r=this.dict.lookup(PDFName.of("Parent"),PDFDict);return new t(r,e)}},t.prototype.setParent=function(e){e?this.dict.set(PDFName.of("Parent"),e):this.dict.delete(PDFName.of("Parent"))},t.prototype.getFullyQualifiedName=function(){var e=this.getParent();return e?e.getFullyQualifiedName()+"."+this.getPartialName():this.getPartialName()},t.prototype.getPartialName=function(){var e;return(e=this.T())===null||e===void 0?void 0:e.decodeText()},t.prototype.setPartialName=function(e){e?this.dict.set(PDFName.of("T"),PDFHexString.fromText(e)):this.dict.delete(PDFName.of("T"))},t.prototype.setDefaultAppearance=function(e){this.dict.set(PDFName.of("DA"),PDFString.of(e))},t.prototype.getDefaultAppearance=function(){var e=this.DA();return e instanceof PDFHexString?e.decodeText():e==null?void 0:e.asString()},t.prototype.setFontSize=function(e){var r,n=(r=this.getFullyQualifiedName())!==null&&r!==void 0?r:"",a=this.getDefaultAppearance();if(!a)throw new MissingDAEntryError(n);var s=findLastMatch(a,tfRegex$1);if(!s.match)throw new MissingTfOperatorError(n);var o=a.slice(0,s.pos-s.match[0].length),h=s.pos<=a.length?a.slice(s.pos):"",d=s.match[1],l=o+" /"+d+" "+e+" Tf "+h;this.setDefaultAppearance(l)},t.prototype.getFlags=function(){var e,r;return(r=(e=this.Ff())===null||e===void 0?void 0:e.asNumber())!==null&&r!==void 0?r:0},t.prototype.setFlags=function(e){this.dict.set(PDFName.of("Ff"),PDFNumber.of(e))},t.prototype.hasFlag=function(e){var r=this.getFlags();return(r&e)!==0},t.prototype.setFlag=function(e){var r=this.getFlags();this.setFlags(r|e)},t.prototype.clearFlag=function(e){var r=this.getFlags();this.setFlags(r&~e)},t.prototype.setFlagTo=function(e,r){r?this.setFlag(e):this.clearFlag(e)},t.prototype.getInheritableAttribute=function(e){var r;return this.ascend(function(n){r||(r=n.dict.get(e))}),r},t.prototype.ascend=function(e){e(this);var r=this.getParent();r&&r.ascend(e)},t}(),BorderStyle=function(){function t(e){this.dict=e}return t.prototype.W=function(){var e=this.dict.lookup(PDFName.of("W"));if(e instanceof PDFNumber)return e},t.prototype.getWidth=function(){var e,r;return(r=(e=this.W())===null||e===void 0?void 0:e.asNumber())!==null&&r!==void 0?r:1},t.prototype.setWidth=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("W"),r)},t.fromDict=function(e){return new t(e)},t}(),PDFAnnotation=function(){function t(e){this.dict=e}return t.prototype.Rect=function(){return this.dict.lookup(PDFName.of("Rect"),PDFArray)},t.prototype.AP=function(){return this.dict.lookupMaybe(PDFName.of("AP"),PDFDict)},t.prototype.F=function(){var e=this.dict.lookup(PDFName.of("F"));return this.dict.context.lookupMaybe(e,PDFNumber)},t.prototype.getRectangle=function(){var e,r=this.Rect();return(e=r==null?void 0:r.asRectangle())!==null&&e!==void 0?e:{x:0,y:0,width:0,height:0}},t.prototype.setRectangle=function(e){var r=e.x,n=e.y,a=e.width,s=e.height,o=this.dict.context.obj([r,n,r+a,n+s]);this.dict.set(PDFName.of("Rect"),o)},t.prototype.getAppearanceState=function(){var e=this.dict.lookup(PDFName.of("AS"));if(e instanceof PDFName)return e},t.prototype.setAppearanceState=function(e){this.dict.set(PDFName.of("AS"),e)},t.prototype.setAppearances=function(e){this.dict.set(PDFName.of("AP"),e)},t.prototype.ensureAP=function(){var e=this.AP();return e||(e=this.dict.context.obj({}),this.dict.set(PDFName.of("AP"),e)),e},t.prototype.getNormalAppearance=function(){var e=this.ensureAP(),r=e.get(PDFName.of("N"));if(r instanceof PDFRef||r instanceof PDFDict)return r;throw new Error("Unexpected N type: "+(r==null?void 0:r.constructor.name))},t.prototype.setNormalAppearance=function(e){var r=this.ensureAP();r.set(PDFName.of("N"),e)},t.prototype.setRolloverAppearance=function(e){var r=this.ensureAP();r.set(PDFName.of("R"),e)},t.prototype.setDownAppearance=function(e){var r=this.ensureAP();r.set(PDFName.of("D"),e)},t.prototype.removeRolloverAppearance=function(){var e=this.AP();e==null||e.delete(PDFName.of("R"))},t.prototype.removeDownAppearance=function(){var e=this.AP();e==null||e.delete(PDFName.of("D"))},t.prototype.getAppearances=function(){var e=this.AP();if(e){var r=e.lookup(PDFName.of("N"),PDFDict,PDFStream),n=e.lookupMaybe(PDFName.of("R"),PDFDict,PDFStream),a=e.lookupMaybe(PDFName.of("D"),PDFDict,PDFStream);return{normal:r,rollover:n,down:a}}},t.prototype.getFlags=function(){var e,r;return(r=(e=this.F())===null||e===void 0?void 0:e.asNumber())!==null&&r!==void 0?r:0},t.prototype.setFlags=function(e){this.dict.set(PDFName.of("F"),PDFNumber.of(e))},t.prototype.hasFlag=function(e){var r=this.getFlags();return(r&e)!==0},t.prototype.setFlag=function(e){var r=this.getFlags();this.setFlags(r|e)},t.prototype.clearFlag=function(e){var r=this.getFlags();this.setFlags(r&~e)},t.prototype.setFlagTo=function(e,r){r?this.setFlag(e):this.clearFlag(e)},t.fromDict=function(e){return new t(e)},t}(),AppearanceCharacteristics=function(){function t(e){this.dict=e}return t.prototype.R=function(){var e=this.dict.lookup(PDFName.of("R"));if(e instanceof PDFNumber)return e},t.prototype.BC=function(){var e=this.dict.lookup(PDFName.of("BC"));if(e instanceof PDFArray)return e},t.prototype.BG=function(){var e=this.dict.lookup(PDFName.of("BG"));if(e instanceof PDFArray)return e},t.prototype.CA=function(){var e=this.dict.lookup(PDFName.of("CA"));if(e instanceof PDFHexString||e instanceof PDFString)return e},t.prototype.RC=function(){var e=this.dict.lookup(PDFName.of("RC"));if(e instanceof PDFHexString||e instanceof PDFString)return e},t.prototype.AC=function(){var e=this.dict.lookup(PDFName.of("AC"));if(e instanceof PDFHexString||e instanceof PDFString)return e},t.prototype.getRotation=function(){var e;return(e=this.R())===null||e===void 0?void 0:e.asNumber()},t.prototype.getBorderColor=function(){var e=this.BC();if(e){for(var r=[],n=0,a=e==null?void 0:e.size();n<a;n++){var s=e.get(n);s instanceof PDFNumber&&r.push(s.asNumber())}return r}},t.prototype.getBackgroundColor=function(){var e=this.BG();if(e){for(var r=[],n=0,a=e==null?void 0:e.size();n<a;n++){var s=e.get(n);s instanceof PDFNumber&&r.push(s.asNumber())}return r}},t.prototype.getCaptions=function(){var e=this.CA(),r=this.RC(),n=this.AC();return{normal:e==null?void 0:e.decodeText(),rollover:r==null?void 0:r.decodeText(),down:n==null?void 0:n.decodeText()}},t.prototype.setRotation=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("R"),r)},t.prototype.setBorderColor=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("BC"),r)},t.prototype.setBackgroundColor=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("BG"),r)},t.prototype.setCaptions=function(e){var r=PDFHexString.fromText(e.normal);if(this.dict.set(PDFName.of("CA"),r),e.rollover){var n=PDFHexString.fromText(e.rollover);this.dict.set(PDFName.of("RC"),n)}else this.dict.delete(PDFName.of("RC"));if(e.down){var a=PDFHexString.fromText(e.down);this.dict.set(PDFName.of("AC"),a)}else this.dict.delete(PDFName.of("AC"))},t.fromDict=function(e){return new t(e)},t}(),PDFWidgetAnnotation=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.MK=function(){var r=this.dict.lookup(PDFName.of("MK"));if(r instanceof PDFDict)return r},e.prototype.BS=function(){var r=this.dict.lookup(PDFName.of("BS"));if(r instanceof PDFDict)return r},e.prototype.DA=function(){var r=this.dict.lookup(PDFName.of("DA"));if(r instanceof PDFString||r instanceof PDFHexString)return r},e.prototype.P=function(){var r=this.dict.get(PDFName.of("P"));if(r instanceof PDFRef)return r},e.prototype.setP=function(r){this.dict.set(PDFName.of("P"),r)},e.prototype.setDefaultAppearance=function(r){this.dict.set(PDFName.of("DA"),PDFString.of(r))},e.prototype.getDefaultAppearance=function(){var r=this.DA();return r instanceof PDFHexString?r.decodeText():r==null?void 0:r.asString()},e.prototype.getAppearanceCharacteristics=function(){var r=this.MK();if(r)return AppearanceCharacteristics.fromDict(r)},e.prototype.getOrCreateAppearanceCharacteristics=function(){var r=this.MK();if(r)return AppearanceCharacteristics.fromDict(r);var n=AppearanceCharacteristics.fromDict(this.dict.context.obj({}));return this.dict.set(PDFName.of("MK"),n.dict),n},e.prototype.getBorderStyle=function(){var r=this.BS();if(r)return BorderStyle.fromDict(r)},e.prototype.getOrCreateBorderStyle=function(){var r=this.BS();if(r)return BorderStyle.fromDict(r);var n=BorderStyle.fromDict(this.dict.context.obj({}));return this.dict.set(PDFName.of("BS"),n.dict),n},e.prototype.getOnValue=function(){var r,n=(r=this.getAppearances())===null||r===void 0?void 0:r.normal;if(n instanceof PDFDict)for(var a=n.keys(),s=0,o=a.length;s<o;s++){var h=a[s];if(h!==PDFName.of("Off"))return h}},e.fromDict=function(r){return new e(r)},e.create=function(r,n){var a=r.obj({Type:"Annot",Subtype:"Widget",Rect:[0,0,0,0],Parent:n});return new e(a)},e}(PDFAnnotation),PDFAcroTerminal=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.FT=function(){var r=this.getInheritableAttribute(PDFName.of("FT"));return this.dict.context.lookup(r,PDFName)},e.prototype.getWidgets=function(){var r=this.Kids();if(!r)return[PDFWidgetAnnotation.fromDict(this.dict)];for(var n=new Array(r.size()),a=0,s=r.size();a<s;a++){var o=r.lookup(a,PDFDict);n[a]=PDFWidgetAnnotation.fromDict(o)}return n},e.prototype.addWidget=function(r){var n=this.normalizedEntries().Kids;n.push(r)},e.prototype.removeWidget=function(r){var n=this.Kids();if(n){if(r<0||r>n.size())throw new IndexOutOfBoundsError(r,0,n.size());n.remove(r)}else{if(r!==0)throw new IndexOutOfBoundsError(r,0,0);this.setKids([])}},e.prototype.normalizedEntries=function(){var r=this.Kids();return r||(r=this.dict.context.obj([this.ref]),this.dict.set(PDFName.of("Kids"),r)),{Kids:r}},e.fromDict=function(r,n){return new e(r,n)},e}(PDFAcroField),PDFAcroButton=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.Opt=function(){return this.dict.lookupMaybe(PDFName.of("Opt"),PDFString,PDFHexString,PDFArray)},e.prototype.setOpt=function(r){this.dict.set(PDFName.of("Opt"),this.dict.context.obj(r))},e.prototype.getExportValues=function(){var r=this.Opt();if(r){if(r instanceof PDFString||r instanceof PDFHexString)return[r];for(var n=[],a=0,s=r.size();a<s;a++){var o=r.lookup(a);(o instanceof PDFString||o instanceof PDFHexString)&&n.push(o)}return n}},e.prototype.removeExportValue=function(r){var n=this.Opt();if(n)if(n instanceof PDFString||n instanceof PDFHexString){if(r!==0)throw new IndexOutOfBoundsError(r,0,0);this.setOpt([])}else{if(r<0||r>n.size())throw new IndexOutOfBoundsError(r,0,n.size());n.remove(r)}},e.prototype.normalizeExportValues=function(){for(var r,n,a,s,o=(r=this.getExportValues())!==null&&r!==void 0?r:[],h=[],d=this.getWidgets(),l=0,u=d.length;l<u;l++){var p=d[l],g=(n=o[l])!==null&&n!==void 0?n:PDFHexString.fromText((s=(a=p.getOnValue())===null||a===void 0?void 0:a.decodeText())!==null&&s!==void 0?s:"");h.push(g)}this.setOpt(h)},e.prototype.addOpt=function(r,n){var a;this.normalizeExportValues();var s=r.decodeText(),o;if(n)for(var h=(a=this.getExportValues())!==null&&a!==void 0?a:[],d=0,l=h.length;d<l;d++){var u=h[d];u.decodeText()===s&&(o=d)}var p=this.Opt();return p.push(r),o??p.size()-1},e.prototype.addWidgetWithOpt=function(r,n,a){var s=this.addOpt(n,a),o=PDFName.of(String(s));return this.addWidget(r),o},e}(PDFAcroTerminal),PDFAcroCheckBox=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.setValue=function(r){var n,a=(n=this.getOnValue())!==null&&n!==void 0?n:PDFName.of("Yes");if(r!==a&&r!==PDFName.of("Off"))throw new InvalidAcroFieldValueError;this.dict.set(PDFName.of("V"),r);for(var s=this.getWidgets(),o=0,h=s.length;o<h;o++){var d=s[o],l=d.getOnValue()===r?r:PDFName.of("Off");d.setAppearanceState(l)}},e.prototype.getValue=function(){var r=this.V();return r instanceof PDFName?r:PDFName.of("Off")},e.prototype.getOnValue=function(){var r=this.getWidgets()[0];return r==null?void 0:r.getOnValue()},e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Btn",Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroButton),flag$1=function(t){return 1<<t},AcroFieldFlags;(function(t){t[t.ReadOnly=flag$1(0)]="ReadOnly",t[t.Required=flag$1(1)]="Required",t[t.NoExport=flag$1(2)]="NoExport"})(AcroFieldFlags||(AcroFieldFlags={}));var AcroButtonFlags;(function(t){t[t.NoToggleToOff=flag$1(14)]="NoToggleToOff",t[t.Radio=flag$1(15)]="Radio",t[t.PushButton=flag$1(16)]="PushButton",t[t.RadiosInUnison=flag$1(25)]="RadiosInUnison"})(AcroButtonFlags||(AcroButtonFlags={}));var AcroTextFlags;(function(t){t[t.Multiline=flag$1(12)]="Multiline",t[t.Password=flag$1(13)]="Password",t[t.FileSelect=flag$1(20)]="FileSelect",t[t.DoNotSpellCheck=flag$1(22)]="DoNotSpellCheck",t[t.DoNotScroll=flag$1(23)]="DoNotScroll",t[t.Comb=flag$1(24)]="Comb",t[t.RichText=flag$1(25)]="RichText"})(AcroTextFlags||(AcroTextFlags={}));var AcroChoiceFlags;(function(t){t[t.Combo=flag$1(17)]="Combo",t[t.Edit=flag$1(18)]="Edit",t[t.Sort=flag$1(19)]="Sort",t[t.MultiSelect=flag$1(21)]="MultiSelect",t[t.DoNotSpellCheck=flag$1(22)]="DoNotSpellCheck",t[t.CommitOnSelChange=flag$1(26)]="CommitOnSelChange"})(AcroChoiceFlags||(AcroChoiceFlags={}));var PDFAcroChoice=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.setValues=function(r){if(this.hasFlag(AcroChoiceFlags.Combo)&&!this.hasFlag(AcroChoiceFlags.Edit)&&!this.valuesAreValid(r))throw new InvalidAcroFieldValueError;if(r.length===0&&this.dict.delete(PDFName.of("V")),r.length===1&&this.dict.set(PDFName.of("V"),r[0]),r.length>1){if(!this.hasFlag(AcroChoiceFlags.MultiSelect))throw new MultiSelectValueError;this.dict.set(PDFName.of("V"),this.dict.context.obj(r))}this.updateSelectedIndices(r)},e.prototype.valuesAreValid=function(r){for(var n=this.getOptions(),a=function(d,l){var u=r[d].decodeText();if(!n.find(function(p){return u===(p.display||p.value).decodeText()}))return{value:!1}},s=0,o=r.length;s<o;s++){var h=a(s);if(typeof h=="object")return h.value}return!0},e.prototype.updateSelectedIndices=function(r){if(r.length>1){for(var n=new Array(r.length),a=this.getOptions(),s=function(d,l){var u=r[d].decodeText();n[d]=a.findIndex(function(p){return u===(p.display||p.value).decodeText()})},o=0,h=r.length;o<h;o++)s(o,h);this.dict.set(PDFName.of("I"),this.dict.context.obj(n.sort()))}else this.dict.delete(PDFName.of("I"))},e.prototype.getValues=function(){var r=this.V();if(r instanceof PDFString||r instanceof PDFHexString)return[r];if(r instanceof PDFArray){for(var n=[],a=0,s=r.size();a<s;a++){var o=r.lookup(a);(o instanceof PDFString||o instanceof PDFHexString)&&n.push(o)}return n}return[]},e.prototype.Opt=function(){return this.dict.lookupMaybe(PDFName.of("Opt"),PDFString,PDFHexString,PDFArray)},e.prototype.setOptions=function(r){for(var n=new Array(r.length),a=0,s=r.length;a<s;a++){var o=r[a],h=o.value,d=o.display;n[a]=this.dict.context.obj([h,d||h])}this.dict.set(PDFName.of("Opt"),this.dict.context.obj(n))},e.prototype.getOptions=function(){var r=this.Opt();if(r instanceof PDFString||r instanceof PDFHexString)return[{value:r,display:r}];if(r instanceof PDFArray){for(var n=[],a=0,s=r.size();a<s;a++){var o=r.lookup(a);if((o instanceof PDFString||o instanceof PDFHexString)&&n.push({value:o,display:o}),o instanceof PDFArray&&o.size()>0){var h=o.lookup(0,PDFString,PDFHexString),d=o.lookupMaybe(1,PDFString,PDFHexString);n.push({value:h,display:d||h})}}return n}return[]},e}(PDFAcroTerminal),PDFAcroComboBox=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Ch",Ff:AcroChoiceFlags.Combo,Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroChoice),PDFAcroNonTerminal=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.addField=function(r){var n=this.normalizedEntries().Kids;n==null||n.push(r)},e.prototype.normalizedEntries=function(){var r=this.Kids();return r||(r=this.dict.context.obj([]),this.dict.set(PDFName.of("Kids"),r)),{Kids:r}},e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({}),a=r.register(n);return new e(n,a)},e}(PDFAcroField),PDFAcroSignature=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.fromDict=function(r,n){return new e(r,n)},e}(PDFAcroTerminal),PDFAcroText=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.MaxLen=function(){var r=this.dict.lookup(PDFName.of("MaxLen"));if(r instanceof PDFNumber)return r},e.prototype.Q=function(){var r=this.dict.lookup(PDFName.of("Q"));if(r instanceof PDFNumber)return r},e.prototype.setMaxLength=function(r){this.dict.set(PDFName.of("MaxLen"),PDFNumber.of(r))},e.prototype.removeMaxLength=function(){this.dict.delete(PDFName.of("MaxLen"))},e.prototype.getMaxLength=function(){var r;return(r=this.MaxLen())===null||r===void 0?void 0:r.asNumber()},e.prototype.setQuadding=function(r){this.dict.set(PDFName.of("Q"),PDFNumber.of(r))},e.prototype.getQuadding=function(){var r;return(r=this.Q())===null||r===void 0?void 0:r.asNumber()},e.prototype.setValue=function(r){this.dict.set(PDFName.of("V"),r)},e.prototype.removeValue=function(){this.dict.delete(PDFName.of("V"))},e.prototype.getValue=function(){var r=this.V();if(r instanceof PDFString||r instanceof PDFHexString)return r},e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Tx",Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroTerminal),PDFAcroPushButton=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Btn",Ff:AcroButtonFlags.PushButton,Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroButton),PDFAcroRadioButton=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.setValue=function(r){var n=this.getOnValues();if(!n.includes(r)&&r!==PDFName.of("Off"))throw new InvalidAcroFieldValueError;this.dict.set(PDFName.of("V"),r);for(var a=this.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s],d=h.getOnValue()===r?r:PDFName.of("Off");h.setAppearanceState(d)}},e.prototype.getValue=function(){var r=this.V();return r instanceof PDFName?r:PDFName.of("Off")},e.prototype.getOnValues=function(){for(var r=this.getWidgets(),n=[],a=0,s=r.length;a<s;a++){var o=r[a].getOnValue();o&&n.push(o)}return n},e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Btn",Ff:AcroButtonFlags.Radio,Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroButton),PDFAcroListBox=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Ch",Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroChoice),createPDFAcroFields=function(t){if(!t)return[];for(var e=[],r=0,n=t.size();r<n;r++){var a=t.get(r),s=t.lookup(r);a instanceof PDFRef&&s instanceof PDFDict&&e.push([createPDFAcroField(s,a),a])}return e},createPDFAcroField=function(t,e){var r=isNonTerminalAcroField(t);return r?PDFAcroNonTerminal.fromDict(t,e):createPDFAcroTerminal(t,e)},isNonTerminalAcroField=function(t){var e=t.lookup(PDFName.of("Kids"));if(e instanceof PDFArray)for(var r=0,n=e.size();r<n;r++){var a=e.lookup(r),s=a instanceof PDFDict&&a.has(PDFName.of("T"));if(s)return!0}return!1},createPDFAcroTerminal=function(t,e){var r=getInheritableAttribute(t,PDFName.of("FT")),n=t.context.lookup(r,PDFName);return n===PDFName.of("Btn")?createPDFAcroButton(t,e):n===PDFName.of("Ch")?createPDFAcroChoice(t,e):n===PDFName.of("Tx")?PDFAcroText.fromDict(t,e):n===PDFName.of("Sig")?PDFAcroSignature.fromDict(t,e):PDFAcroTerminal.fromDict(t,e)},createPDFAcroButton=function(t,e){var r,n=getInheritableAttribute(t,PDFName.of("Ff")),a=t.context.lookupMaybe(n,PDFNumber),s=(r=a==null?void 0:a.asNumber())!==null&&r!==void 0?r:0;return flagIsSet(s,AcroButtonFlags.PushButton)?PDFAcroPushButton.fromDict(t,e):flagIsSet(s,AcroButtonFlags.Radio)?PDFAcroRadioButton.fromDict(t,e):PDFAcroCheckBox.fromDict(t,e)},createPDFAcroChoice=function(t,e){var r,n=getInheritableAttribute(t,PDFName.of("Ff")),a=t.context.lookupMaybe(n,PDFNumber),s=(r=a==null?void 0:a.asNumber())!==null&&r!==void 0?r:0;return flagIsSet(s,AcroChoiceFlags.Combo)?PDFAcroComboBox.fromDict(t,e):PDFAcroListBox.fromDict(t,e)},flagIsSet=function(t,e){return(t&e)!==0},getInheritableAttribute=function(t,e){var r;return ascend(t,function(n){r||(r=n.get(e))}),r},ascend=function(t,e){e(t);var r=t.lookupMaybe(PDFName.of("Parent"),PDFDict);r&&ascend(r,e)},PDFAcroForm=function(){function t(e){this.dict=e}return t.prototype.Fields=function(){var e=this.dict.lookup(PDFName.of("Fields"));if(e instanceof PDFArray)return e},t.prototype.getFields=function(){for(var e=this.normalizedEntries().Fields,r=new Array(e.size()),n=0,a=e.size();n<a;n++){var s=e.get(n),o=e.lookup(n,PDFDict);r[n]=[createPDFAcroField(o,s),s]}return r},t.prototype.getAllFields=function(){var e=[],r=function(n){if(n)for(var a=0,s=n.length;a<s;a++){var o=n[a];e.push(o);var h=o[0];h instanceof PDFAcroNonTerminal&&r(createPDFAcroFields(h.Kids()))}};return r(this.getFields()),e},t.prototype.addField=function(e){var r=this.normalizedEntries().Fields;r==null||r.push(e)},t.prototype.removeField=function(e){var r=e.getParent(),n=r===void 0?this.normalizedEntries().Fields:r.Kids(),a=n==null?void 0:n.indexOf(e.ref);if(n===void 0||a===void 0)throw new Error("Tried to remove inexistent field "+e.getFullyQualifiedName());n.remove(a),r!==void 0&&n.size()===0&&this.removeField(r)},t.prototype.normalizedEntries=function(){var e=this.Fields();return e||(e=this.dict.context.obj([]),this.dict.set(PDFName.of("Fields"),e)),{Fields:e}},t.fromDict=function(e){return new t(e)},t.create=function(e){var r=e.obj({Fields:[]});return new t(r)},t}(),PDFCatalog=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.Pages=function(){return this.lookup(PDFName.of("Pages"),PDFDict)},e.prototype.AcroForm=function(){return this.lookupMaybe(PDFName.of("AcroForm"),PDFDict)},e.prototype.getAcroForm=function(){var r=this.AcroForm();if(r)return PDFAcroForm.fromDict(r)},e.prototype.getOrCreateAcroForm=function(){var r=this.getAcroForm();if(!r){r=PDFAcroForm.create(this.context);var n=this.context.register(r.dict);this.set(PDFName.of("AcroForm"),n)}return r},e.prototype.ViewerPreferences=function(){return this.lookupMaybe(PDFName.of("ViewerPreferences"),PDFDict)},e.prototype.getViewerPreferences=function(){var r=this.ViewerPreferences();if(r)return ViewerPreferences.fromDict(r)},e.prototype.getOrCreateViewerPreferences=function(){var r=this.getViewerPreferences();if(!r){r=ViewerPreferences.create(this.context);var n=this.context.register(r.dict);this.set(PDFName.of("ViewerPreferences"),n)}return r},e.prototype.insertLeafNode=function(r,n){var a=this.get(PDFName.of("Pages")),s=this.Pages().insertLeafNode(r,n);return s||a},e.prototype.removeLeafNode=function(r){this.Pages().removeLeafNode(r)},e.withContextAndPages=function(r,n){var a=new Map;return a.set(PDFName.of("Type"),PDFName.of("Catalog")),a.set(PDFName.of("Pages"),n),new e(a,r)},e.fromMapWithContext=function(r,n){return new e(r,n)},e}(PDFDict),PDFPageTree=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.Parent=function(){return this.lookup(PDFName.of("Parent"))},e.prototype.Kids=function(){return this.lookup(PDFName.of("Kids"),PDFArray)},e.prototype.Count=function(){return this.lookup(PDFName.of("Count"),PDFNumber)},e.prototype.pushTreeNode=function(r){var n=this.Kids();n.push(r)},e.prototype.pushLeafNode=function(r){var n=this.Kids();this.insertLeafKid(n.size(),r)},e.prototype.insertLeafNode=function(r,n){var a=this.Kids(),s=this.Count().asNumber();if(n>s)throw new InvalidTargetIndexError(n,s);for(var o=n,h=0,d=a.size();h<d;h++){if(o===0){this.insertLeafKid(h,r);return}var l=a.get(h),u=this.context.lookup(l);if(u instanceof e){if(u.Count().asNumber()>o)return u.insertLeafNode(r,o)||l;o-=u.Count().asNumber()}u instanceof PDFPageLeaf&&(o-=1)}if(o===0){this.insertLeafKid(a.size(),r);return}throw new CorruptPageTreeError(n,"insertLeafNode")},e.prototype.removeLeafNode=function(r,n){n===void 0&&(n=!0);var a=this.Kids(),s=this.Count().asNumber();if(r>=s)throw new InvalidTargetIndexError(r,s);for(var o=r,h=0,d=a.size();h<d;h++){var l=a.get(h),u=this.context.lookup(l);if(u instanceof e)if(u.Count().asNumber()>o){u.removeLeafNode(o,n),n&&u.Kids().size()===0&&a.remove(h);return}else o-=u.Count().asNumber();if(u instanceof PDFPageLeaf)if(o===0){this.removeKid(h);return}else o-=1}throw new CorruptPageTreeError(r,"removeLeafNode")},e.prototype.ascend=function(r){r(this);var n=this.Parent();n&&n.ascend(r)},e.prototype.traverse=function(r){for(var n=this.Kids(),a=0,s=n.size();a<s;a++){var o=n.get(a),h=this.context.lookup(o);h instanceof e&&h.traverse(r),r(h,o)}},e.prototype.insertLeafKid=function(r,n){var a=this.Kids();this.ascend(function(s){var o=s.Count().asNumber()+1;s.set(PDFName.of("Count"),PDFNumber.of(o))}),a.insert(r,n)},e.prototype.removeKid=function(r){var n=this.Kids(),a=n.lookup(r);a instanceof PDFPageLeaf&&this.ascend(function(s){var o=s.Count().asNumber()-1;s.set(PDFName.of("Count"),PDFNumber.of(o))}),n.remove(r)},e.withContext=function(r,n){var a=new Map;return a.set(PDFName.of("Type"),PDFName.of("Pages")),a.set(PDFName.of("Kids"),r.obj([])),a.set(PDFName.of("Count"),r.obj(0)),n&&a.set(PDFName.of("Parent"),n),new e(a,r)},e.fromMapWithContext=function(r,n){return new e(r,n)},e}(PDFDict),IsDigit=new Uint8Array(256);IsDigit[CharCodes.Zero]=1,IsDigit[CharCodes.One]=1,IsDigit[CharCodes.Two]=1,IsDigit[CharCodes.Three]=1,IsDigit[CharCodes.Four]=1,IsDigit[CharCodes.Five]=1,IsDigit[CharCodes.Six]=1,IsDigit[CharCodes.Seven]=1,IsDigit[CharCodes.Eight]=1,IsDigit[CharCodes.Nine]=1;var IsNumericPrefix=new Uint8Array(256);IsNumericPrefix[CharCodes.Period]=1,IsNumericPrefix[CharCodes.Plus]=1,IsNumericPrefix[CharCodes.Minus]=1;for(var IsNumeric=new Uint8Array(256),idx=0,len=256;idx<len;idx++)IsNumeric[idx]=IsDigit[idx]||IsNumericPrefix[idx]?1:0;var Newline$1=CharCodes.Newline,CarriageReturn$1=CharCodes.CarriageReturn,BaseParser=function(){function t(e,r){r===void 0&&(r=!1),this.bytes=e,this.capNumbers=r}return t.prototype.parseRawInt=function(){for(var e="";!this.bytes.done();){var r=this.bytes.peek();if(!IsDigit[r])break;e+=charFromCode(this.bytes.next())}var n=Number(e);if(!e||!isFinite(n))throw new NumberParsingError(this.bytes.position(),e);return n},t.prototype.parseRawNumber=function(){for(var e="";!this.bytes.done();){var r=this.bytes.peek();if(!IsNumeric[r]||(e+=charFromCode(this.bytes.next()),r===CharCodes.Period))break}for(;!this.bytes.done();){var r=this.bytes.peek();if(!IsDigit[r])break;e+=charFromCode(this.bytes.next())}var n=Number(e);if(!e||!isFinite(n))throw new NumberParsingError(this.bytes.position(),e);if(n>Number.MAX_SAFE_INTEGER)if(this.capNumbers){var a="Parsed number that is too large for some PDF readers: "+e+", using Number.MAX_SAFE_INTEGER instead.";return console.warn(a),Number.MAX_SAFE_INTEGER}else{var a="Parsed number that is too large for some PDF readers: "+e+", not capping.";console.warn(a)}return n},t.prototype.skipWhitespace=function(){for(;!this.bytes.done()&&IsWhitespace[this.bytes.peek()];)this.bytes.next()},t.prototype.skipLine=function(){for(;!this.bytes.done();){var e=this.bytes.peek();if(e===Newline$1||e===CarriageReturn$1)return;this.bytes.next()}},t.prototype.skipComment=function(){if(this.bytes.peek()!==CharCodes.Percent)return!1;for(;!this.bytes.done();){var e=this.bytes.peek();if(e===Newline$1||e===CarriageReturn$1)return!0;this.bytes.next()}return!0},t.prototype.skipWhitespaceAndComments=function(){for(this.skipWhitespace();this.skipComment();)this.skipWhitespace()},t.prototype.matchKeyword=function(e){for(var r=this.bytes.offset(),n=0,a=e.length;n<a;n++)if(this.bytes.done()||this.bytes.next()!==e[n])return this.bytes.moveTo(r),!1;return!0},t}(),ByteStream=function(){function t(e){this.idx=0,this.line=0,this.column=0,this.bytes=e,this.length=this.bytes.length}return t.prototype.moveTo=function(e){this.idx=e},t.prototype.next=function(){var e=this.bytes[this.idx++];return e===CharCodes.Newline?(this.line+=1,this.column=0):this.column+=1,e},t.prototype.assertNext=function(e){if(this.peek()!==e)throw new NextByteAssertionError(this.position(),e,this.peek());return this.next()},t.prototype.peek=function(){return this.bytes[this.idx]},t.prototype.peekAhead=function(e){return this.bytes[this.idx+e]},t.prototype.peekAt=function(e){return this.bytes[e]},t.prototype.done=function(){return this.idx>=this.length},t.prototype.offset=function(){return this.idx},t.prototype.slice=function(e,r){return this.bytes.slice(e,r)},t.prototype.position=function(){return{line:this.line,column:this.column,offset:this.idx}},t.of=function(e){return new t(e)},t.fromPDFRawStream=function(e){return t.of(decodePDFRawStream(e).decode())},t}(),Space=CharCodes.Space,CarriageReturn=CharCodes.CarriageReturn,Newline=CharCodes.Newline,stream=[CharCodes.s,CharCodes.t,CharCodes.r,CharCodes.e,CharCodes.a,CharCodes.m],endstream=[CharCodes.e,CharCodes.n,CharCodes.d,CharCodes.s,CharCodes.t,CharCodes.r,CharCodes.e,CharCodes.a,CharCodes.m],Keywords={header:[CharCodes.Percent,CharCodes.P,CharCodes.D,CharCodes.F,CharCodes.Dash],eof:[CharCodes.Percent,CharCodes.Percent,CharCodes.E,CharCodes.O,CharCodes.F],obj:[CharCodes.o,CharCodes.b,CharCodes.j],endobj:[CharCodes.e,CharCodes.n,CharCodes.d,CharCodes.o,CharCodes.b,CharCodes.j],xref:[CharCodes.x,CharCodes.r,CharCodes.e,CharCodes.f],trailer:[CharCodes.t,CharCodes.r,CharCodes.a,CharCodes.i,CharCodes.l,CharCodes.e,CharCodes.r],startxref:[CharCodes.s,CharCodes.t,CharCodes.a,CharCodes.r,CharCodes.t,CharCodes.x,CharCodes.r,CharCodes.e,CharCodes.f],true:[CharCodes.t,CharCodes.r,CharCodes.u,CharCodes.e],false:[CharCodes.f,CharCodes.a,CharCodes.l,CharCodes.s,CharCodes.e],null:[CharCodes.n,CharCodes.u,CharCodes.l,CharCodes.l],stream,streamEOF1:__spreadArrays(stream,[Space,CarriageReturn,Newline]),streamEOF2:__spreadArrays(stream,[CarriageReturn,Newline]),streamEOF3:__spreadArrays(stream,[CarriageReturn]),streamEOF4:__spreadArrays(stream,[Newline]),endstream,EOF1endstream:__spreadArrays([CarriageReturn,Newline],endstream),EOF2endstream:__spreadArrays([CarriageReturn],endstream),EOF3endstream:__spreadArrays([Newline],endstream)},PDFObjectParser=function(t){__extends(e,t);function e(r,n,a){a===void 0&&(a=!1);var s=t.call(this,r,a)||this;return s.context=n,s}return e.prototype.parseObject=function(){if(this.skipWhitespaceAndComments(),this.matchKeyword(Keywords.true))return PDFBool.True;if(this.matchKeyword(Keywords.false))return PDFBool.False;if(this.matchKeyword(Keywords.null))return PDFNull;var r=this.bytes.peek();if(r===CharCodes.LessThan&&this.bytes.peekAhead(1)===CharCodes.LessThan)return this.parseDictOrStream();if(r===CharCodes.LessThan)return this.parseHexString();if(r===CharCodes.LeftParen)return this.parseString();if(r===CharCodes.ForwardSlash)return this.parseName();if(r===CharCodes.LeftSquareBracket)return this.parseArray();if(IsNumeric[r])return this.parseNumberOrRef();throw new PDFObjectParsingError(this.bytes.position(),r)},e.prototype.parseNumberOrRef=function(){var r=this.parseRawNumber();this.skipWhitespaceAndComments();var n=this.bytes.offset();if(IsDigit[this.bytes.peek()]){var a=this.parseRawNumber();if(this.skipWhitespaceAndComments(),this.bytes.peek()===CharCodes.R)return this.bytes.assertNext(CharCodes.R),PDFRef.of(r,a)}return this.bytes.moveTo(n),PDFNumber.of(r)},e.prototype.parseHexString=function(){var r="";for(this.bytes.assertNext(CharCodes.LessThan);!this.bytes.done()&&this.bytes.peek()!==CharCodes.GreaterThan;)r+=charFromCode(this.bytes.next());return this.bytes.assertNext(CharCodes.GreaterThan),PDFHexString.of(r)},e.prototype.parseString=function(){for(var r=0,n=!1,a="";!this.bytes.done();){var s=this.bytes.next();if(a+=charFromCode(s),n||(s===CharCodes.LeftParen&&(r+=1),s===CharCodes.RightParen&&(r-=1)),s===CharCodes.BackSlash?n=!n:n&&(n=!1),r===0)return PDFString.of(a.substring(1,a.length-1))}throw new UnbalancedParenthesisError(this.bytes.position())},e.prototype.parseName=function(){this.bytes.assertNext(CharCodes.ForwardSlash);for(var r="";!this.bytes.done();){var n=this.bytes.peek();if(IsWhitespace[n]||IsDelimiter[n])break;r+=charFromCode(n),this.bytes.next()}return PDFName.of(r)},e.prototype.parseArray=function(){this.bytes.assertNext(CharCodes.LeftSquareBracket),this.skipWhitespaceAndComments();for(var r=PDFArray.withContext(this.context);this.bytes.peek()!==CharCodes.RightSquareBracket;){var n=this.parseObject();r.push(n),this.skipWhitespaceAndComments()}return this.bytes.assertNext(CharCodes.RightSquareBracket),r},e.prototype.parseDict=function(){this.bytes.assertNext(CharCodes.LessThan),this.bytes.assertNext(CharCodes.LessThan),this.skipWhitespaceAndComments();for(var r=new Map;!this.bytes.done()&&this.bytes.peek()!==CharCodes.GreaterThan&&this.bytes.peekAhead(1)!==CharCodes.GreaterThan;){var n=this.parseName(),a=this.parseObject();r.set(n,a),this.skipWhitespaceAndComments()}this.skipWhitespaceAndComments(),this.bytes.assertNext(CharCodes.GreaterThan),this.bytes.assertNext(CharCodes.GreaterThan);var s=r.get(PDFName.of("Type"));return s===PDFName.of("Catalog")?PDFCatalog.fromMapWithContext(r,this.context):s===PDFName.of("Pages")?PDFPageTree.fromMapWithContext(r,this.context):s===PDFName.of("Page")?PDFPageLeaf.fromMapWithContext(r,this.context):PDFDict.fromMapWithContext(r,this.context)},e.prototype.parseDictOrStream=function(){var r=this.bytes.position(),n=this.parseDict();if(this.skipWhitespaceAndComments(),!this.matchKeyword(Keywords.streamEOF1)&&!this.matchKeyword(Keywords.streamEOF2)&&!this.matchKeyword(Keywords.streamEOF3)&&!this.matchKeyword(Keywords.streamEOF4)&&!this.matchKeyword(Keywords.stream))return n;var a=this.bytes.offset(),s,o=n.get(PDFName.of("Length"));o instanceof PDFNumber?(s=a+o.asNumber(),this.bytes.moveTo(s),this.skipWhitespaceAndComments(),this.matchKeyword(Keywords.endstream)||(this.bytes.moveTo(a),s=this.findEndOfStreamFallback(r))):s=this.findEndOfStreamFallback(r);var h=this.bytes.slice(a,s);return PDFRawStream.of(n,h)},e.prototype.findEndOfStreamFallback=function(r){for(var n=1,a=this.bytes.offset();!this.bytes.done()&&(a=this.bytes.offset(),this.matchKeyword(Keywords.stream)?n+=1:this.matchKeyword(Keywords.EOF1endstream)||this.matchKeyword(Keywords.EOF2endstream)||this.matchKeyword(Keywords.EOF3endstream)||this.matchKeyword(Keywords.endstream)?n-=1:this.bytes.next(),n!==0););if(n!==0)throw new PDFStreamParsingError(r);return a},e.forBytes=function(r,n,a){return new e(ByteStream.of(r),n,a)},e.forByteStream=function(r,n,a){return a===void 0&&(a=!1),new e(r,n,a)},e}(BaseParser),PDFObjectStreamParser=function(t){__extends(e,t);function e(r,n){var a=t.call(this,ByteStream.fromPDFRawStream(r),r.dict.context)||this,s=r.dict;return a.alreadyParsed=!1,a.shouldWaitForTick=n||function(){return!1},a.firstOffset=s.lookup(PDFName.of("First"),PDFNumber).asNumber(),a.objectCount=s.lookup(PDFName.of("N"),PDFNumber).asNumber(),a}return e.prototype.parseIntoContext=function(){return __awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h,d,l;return __generator(this,function(u){switch(u.label){case 0:if(this.alreadyParsed)throw new ReparseError("PDFObjectStreamParser","parseIntoContext");this.alreadyParsed=!0,r=this.parseOffsetsAndObjectNumbers(),n=0,a=r.length,u.label=1;case 1:return n<a?(s=r[n],o=s.objectNumber,h=s.offset,this.bytes.moveTo(this.firstOffset+h),d=this.parseObject(),l=PDFRef.of(o,0),this.context.assign(l,d),this.shouldWaitForTick()?[4,waitForTick()]:[3,3]):[3,4];case 2:u.sent(),u.label=3;case 3:return n++,[3,1];case 4:return[2]}})})},e.prototype.parseOffsetsAndObjectNumbers=function(){for(var r=[],n=0,a=this.objectCount;n<a;n++){this.skipWhitespaceAndComments();var s=this.parseRawInt();this.skipWhitespaceAndComments();var o=this.parseRawInt();r.push({objectNumber:s,offset:o})}return r},e.forStream=function(r,n){return new e(r,n)},e}(PDFObjectParser),PDFXRefStreamParser=function(){function t(e){this.alreadyParsed=!1,this.dict=e.dict,this.bytes=ByteStream.fromPDFRawStream(e),this.context=this.dict.context;var r=this.dict.lookup(PDFName.of("Size"),PDFNumber),n=this.dict.lookup(PDFName.of("Index"));if(n instanceof PDFArray){this.subsections=[];for(var a=0,s=n.size();a<s;a+=2){var o=n.lookup(a+0,PDFNumber).asNumber(),h=n.lookup(a+1,PDFNumber).asNumber();this.subsections.push({firstObjectNumber:o,length:h})}}else this.subsections=[{firstObjectNumber:0,length:r.asNumber()}];var d=this.dict.lookup(PDFName.of("W"),PDFArray);this.byteWidths=[-1,-1,-1];for(var a=0,s=d.size();a<s;a++)this.byteWidths[a]=d.lookup(a,PDFNumber).asNumber()}return t.prototype.parseIntoContext=function(){if(this.alreadyParsed)throw new ReparseError("PDFXRefStreamParser","parseIntoContext");this.alreadyParsed=!0,this.context.trailerInfo={Root:this.dict.get(PDFName.of("Root")),Encrypt:this.dict.get(PDFName.of("Encrypt")),Info:this.dict.get(PDFName.of("Info")),ID:this.dict.get(PDFName.of("ID"))};var e=this.parseEntries();return e},t.prototype.parseEntries=function(){for(var e=[],r=this.byteWidths,n=r[0],a=r[1],s=r[2],o=0,h=this.subsections.length;o<h;o++)for(var d=this.subsections[o],l=d.firstObjectNumber,u=d.length,p=0;p<u;p++){for(var g=0,f=0,v=n;f<v;f++)g=g<<8|this.bytes.next();for(var y=0,f=0,v=a;f<v;f++)y=y<<8|this.bytes.next();for(var x=0,f=0,v=s;f<v;f++)x=x<<8|this.bytes.next();n===0&&(g=1);var m=l+p,w={ref:PDFRef.of(m,x),offset:y,deleted:g===0,inObjectStream:g===2};e.push(w)}return e},t.forStream=function(e){return new t(e)},t}(),PDFParser=function(t){__extends(e,t);function e(r,n,a,s){n===void 0&&(n=1/0),a===void 0&&(a=!1),s===void 0&&(s=!1);var o=t.call(this,ByteStream.of(r),PDFContext.create(),s)||this;return o.alreadyParsed=!1,o.parsedObjects=0,o.shouldWaitForTick=function(){return o.parsedObjects+=1,o.parsedObjects%o.objectsPerTick===0},o.objectsPerTick=n,o.throwOnInvalidObject=a,o}return e.prototype.parseDocument=function(){return __awaiter(this,void 0,void 0,function(){var r,n;return __generator(this,function(a){switch(a.label){case 0:if(this.alreadyParsed)throw new ReparseError("PDFParser","parseDocument");this.alreadyParsed=!0,this.context.header=this.parseHeader(),a.label=1;case 1:return this.bytes.done()?[3,3]:[4,this.parseDocumentSection()];case 2:if(a.sent(),n=this.bytes.offset(),n===r)throw new StalledParserError(this.bytes.position());return r=n,[3,1];case 3:return this.maybeRecoverRoot(),this.context.lookup(PDFRef.of(0))&&(console.warn("Removing parsed object: 0 0 R"),this.context.delete(PDFRef.of(0))),[2,this.context]}})})},e.prototype.maybeRecoverRoot=function(){var r=function(u){return u instanceof PDFDict&&u.lookup(PDFName.of("Type"))===PDFName.of("Catalog")},n=this.context.lookup(this.context.trailerInfo.Root);if(!r(n))for(var a=this.context.enumerateIndirectObjects(),s=0,o=a.length;s<o;s++){var h=a[s],d=h[0],l=h[1];r(l)&&(this.context.trailerInfo.Root=d)}},e.prototype.parseHeader=function(){for(;!this.bytes.done();){if(this.matchKeyword(Keywords.header)){var r=this.parseRawInt();this.bytes.assertNext(CharCodes.Period);var n=this.parseRawInt(),a=PDFHeader.forVersion(r,n);return this.skipBinaryHeaderComment(),a}this.bytes.next()}throw new MissingPDFHeaderError(this.bytes.position())},e.prototype.parseIndirectObjectHeader=function(){this.skipWhitespaceAndComments();var r=this.parseRawInt();this.skipWhitespaceAndComments();var n=this.parseRawInt();if(this.skipWhitespaceAndComments(),!this.matchKeyword(Keywords.obj))throw new MissingKeywordError(this.bytes.position(),Keywords.obj);return PDFRef.of(r,n)},e.prototype.matchIndirectObjectHeader=function(){var r=this.bytes.offset();try{return this.parseIndirectObjectHeader(),!0}catch{return this.bytes.moveTo(r),!1}},e.prototype.parseIndirectObject=function(){return __awaiter(this,void 0,void 0,function(){var r,n;return __generator(this,function(a){switch(a.label){case 0:return r=this.parseIndirectObjectHeader(),this.skipWhitespaceAndComments(),n=this.parseObject(),this.skipWhitespaceAndComments(),this.matchKeyword(Keywords.endobj),n instanceof PDFRawStream&&n.dict.lookup(PDFName.of("Type"))===PDFName.of("ObjStm")?[4,PDFObjectStreamParser.forStream(n,this.shouldWaitForTick).parseIntoContext()]:[3,2];case 1:return a.sent(),[3,3];case 2:n instanceof PDFRawStream&&n.dict.lookup(PDFName.of("Type"))===PDFName.of("XRef")?PDFXRefStreamParser.forStream(n).parseIntoContext():this.context.assign(r,n),a.label=3;case 3:return[2,r]}})})},e.prototype.tryToParseInvalidIndirectObject=function(){var r=this.bytes.position(),n="Trying to parse invalid object: "+JSON.stringify(r)+")";if(this.throwOnInvalidObject)throw new Error(n);console.warn(n);var a=this.parseIndirectObjectHeader();console.warn("Invalid object ref: "+a),this.skipWhitespaceAndComments();for(var s=this.bytes.offset(),o=!0;!this.bytes.done()&&(this.matchKeyword(Keywords.endobj)&&(o=!1),!!o);)this.bytes.next();if(o)throw new PDFInvalidObjectParsingError(r);var h=this.bytes.offset()-Keywords.endobj.length,d=PDFInvalidObject.of(this.bytes.slice(s,h));return this.context.assign(a,d),a},e.prototype.parseIndirectObjects=function(){return __awaiter(this,void 0,void 0,function(){var r;return __generator(this,function(n){switch(n.label){case 0:this.skipWhitespaceAndComments(),n.label=1;case 1:if(!(!this.bytes.done()&&IsDigit[this.bytes.peek()]))return[3,8];r=this.bytes.offset(),n.label=2;case 2:return n.trys.push([2,4,,5]),[4,this.parseIndirectObject()];case 3:return n.sent(),[3,5];case 4:return n.sent(),this.bytes.moveTo(r),this.tryToParseInvalidIndirectObject(),[3,5];case 5:return this.skipWhitespaceAndComments(),this.skipJibberish(),this.shouldWaitForTick()?[4,waitForTick()]:[3,7];case 6:n.sent(),n.label=7;case 7:return[3,1];case 8:return[2]}})})},e.prototype.maybeParseCrossRefSection=function(){if(this.skipWhitespaceAndComments(),!!this.matchKeyword(Keywords.xref)){this.skipWhitespaceAndComments();for(var r=-1,n=PDFCrossRefSection.createEmpty();!this.bytes.done()&&IsDigit[this.bytes.peek()];){var a=this.parseRawInt();this.skipWhitespaceAndComments();var s=this.parseRawInt();this.skipWhitespaceAndComments();var o=this.bytes.peek();if(o===CharCodes.n||o===CharCodes.f){var h=PDFRef.of(r,s);this.bytes.next()===CharCodes.n?n.addEntry(h,a):n.addDeletedEntry(h,a),r+=1}else r=a;this.skipWhitespaceAndComments()}return n}},e.prototype.maybeParseTrailerDict=function(){if(this.skipWhitespaceAndComments(),!!this.matchKeyword(Keywords.trailer)){this.skipWhitespaceAndComments();var r=this.parseDict(),n=this.context;n.trailerInfo={Root:r.get(PDFName.of("Root"))||n.trailerInfo.Root,Encrypt:r.get(PDFName.of("Encrypt"))||n.trailerInfo.Encrypt,Info:r.get(PDFName.of("Info"))||n.trailerInfo.Info,ID:r.get(PDFName.of("ID"))||n.trailerInfo.ID}}},e.prototype.maybeParseTrailer=function(){if(this.skipWhitespaceAndComments(),!!this.matchKeyword(Keywords.startxref)){this.skipWhitespaceAndComments();var r=this.parseRawInt();return this.skipWhitespace(),this.matchKeyword(Keywords.eof),this.skipWhitespaceAndComments(),this.matchKeyword(Keywords.eof),this.skipWhitespaceAndComments(),PDFTrailer.forLastCrossRefSectionOffset(r)}},e.prototype.parseDocumentSection=function(){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(r){switch(r.label){case 0:return[4,this.parseIndirectObjects()];case 1:return r.sent(),this.maybeParseCrossRefSection(),this.maybeParseTrailerDict(),this.maybeParseTrailer(),this.skipJibberish(),[2]}})})},e.prototype.skipJibberish=function(){for(this.skipWhitespaceAndComments();!this.bytes.done();){var r=this.bytes.offset(),n=this.bytes.peek(),a=n>=CharCodes.Space&&n<=CharCodes.Tilde;if(a&&(this.matchKeyword(Keywords.xref)||this.matchKeyword(Keywords.trailer)||this.matchKeyword(Keywords.startxref)||this.matchIndirectObjectHeader())){this.bytes.moveTo(r);break}this.bytes.next()}},e.prototype.skipBinaryHeaderComment=function(){this.skipWhitespaceAndComments();try{var r=this.bytes.offset();this.parseIndirectObjectHeader(),this.bytes.moveTo(r)}catch{this.bytes.next(),this.skipWhitespaceAndComments()}},e.forBytesWithOptions=function(r,n,a,s){return new e(r,n,a,s)},e}(PDFObjectParser),flag=function(t){return 1<<t},AnnotationFlags;(function(t){t[t.Invisible=flag(0)]="Invisible",t[t.Hidden=flag(1)]="Hidden",t[t.Print=flag(2)]="Print",t[t.NoZoom=flag(3)]="NoZoom",t[t.NoRotate=flag(4)]="NoRotate",t[t.NoView=flag(5)]="NoView",t[t.ReadOnly=flag(6)]="ReadOnly",t[t.Locked=flag(7)]="Locked",t[t.ToggleNoView=flag(8)]="ToggleNoView",t[t.LockedContents=flag(9)]="LockedContents"})(AnnotationFlags||(AnnotationFlags={}));var asPDFName=function(t){return t instanceof PDFName?t:PDFName.of(t)},asPDFNumber=function(t){return t instanceof PDFNumber?t:PDFNumber.of(t)},asNumber=function(t){return t instanceof PDFNumber?t.asNumber():t},RotationTypes;(function(t){t.Degrees="degrees",t.Radians="radians"})(RotationTypes||(RotationTypes={}));var degrees=function(t){return assertIs(t,"degreeAngle",["number"]),{type:RotationTypes.Degrees,angle:t}},Radians=RotationTypes.Radians,Degrees=RotationTypes.Degrees,degreesToRadians=function(t){return t*Math.PI/180},radiansToDegrees=function(t){return t*180/Math.PI},toRadians=function(t){return t.type===Radians?t.angle:t.type===Degrees?degreesToRadians(t.angle):error("Invalid rotation: "+JSON.stringify(t))},toDegrees=function(t){return t.type===Radians?radiansToDegrees(t.angle):t.type===Degrees?t.angle:error("Invalid rotation: "+JSON.stringify(t))},reduceRotation=function(t){t===void 0&&(t=0);var e=t/90%4;return e===0?0:e===1?90:e===2?180:e===3?270:0},adjustDimsForRotation=function(t,e){e===void 0&&(e=0);var r=reduceRotation(e);return r===90||r===270?{width:t.height,height:t.width}:{width:t.width,height:t.height}},rotateRectangle=function(t,e,r){e===void 0&&(e=0),r===void 0&&(r=0);var n=t.x,a=t.y,s=t.width,o=t.height,h=reduceRotation(r),d=e/2;return h===0?{x:n-d,y:a-d,width:s,height:o}:h===90?{x:n-o+d,y:a-d,width:o,height:s}:h===180?{x:n-s+d,y:a-o+d,width:s,height:o}:h===270?{x:n-d,y:a-s+d,width:o,height:s}:{x:n-d,y:a-d,width:s,height:o}},clip=function(){return PDFOperator.of(Ops.ClipNonZero)},cos=Math.cos,sin=Math.sin,tan=Math.tan,concatTransformationMatrix=function(t,e,r,n,a,s){return PDFOperator.of(Ops.ConcatTransformationMatrix,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n),asPDFNumber(a),asPDFNumber(s)])},translate=function(t,e){return concatTransformationMatrix(1,0,0,1,t,e)},scale=function(t,e){return concatTransformationMatrix(t,0,0,e,0,0)},rotateRadians=function(t){return concatTransformationMatrix(cos(asNumber(t)),sin(asNumber(t)),-sin(asNumber(t)),cos(asNumber(t)),0,0)},rotateDegrees=function(t){return rotateRadians(degreesToRadians(asNumber(t)))},skewRadians=function(t,e){return concatTransformationMatrix(1,tan(asNumber(t)),tan(asNumber(e)),1,0,0)},setDashPattern=function(t,e){return PDFOperator.of(Ops.SetLineDashPattern,["["+t.map(asPDFNumber).join(" ")+"]",asPDFNumber(e)])},LineCapStyle;(function(t){t[t.Butt=0]="Butt",t[t.Round=1]="Round",t[t.Projecting=2]="Projecting"})(LineCapStyle||(LineCapStyle={}));var setLineCap=function(t){return PDFOperator.of(Ops.SetLineCapStyle,[asPDFNumber(t)])},LineJoinStyle;(function(t){t[t.Miter=0]="Miter",t[t.Round=1]="Round",t[t.Bevel=2]="Bevel"})(LineJoinStyle||(LineJoinStyle={}));var setGraphicsState=function(t){return PDFOperator.of(Ops.SetGraphicsStateParams,[asPDFName(t)])},pushGraphicsState=function(){return PDFOperator.of(Ops.PushGraphicsState)},popGraphicsState=function(){return PDFOperator.of(Ops.PopGraphicsState)},setLineWidth=function(t){return PDFOperator.of(Ops.SetLineWidth,[asPDFNumber(t)])},appendBezierCurve=function(t,e,r,n,a,s){return PDFOperator.of(Ops.AppendBezierCurve,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n),asPDFNumber(a),asPDFNumber(s)])},appendQuadraticCurve=function(t,e,r,n){return PDFOperator.of(Ops.CurveToReplicateInitialPoint,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n)])},closePath=function(){return PDFOperator.of(Ops.ClosePath)},moveTo=function(t,e){return PDFOperator.of(Ops.MoveTo,[asPDFNumber(t),asPDFNumber(e)])},lineTo=function(t,e){return PDFOperator.of(Ops.LineTo,[asPDFNumber(t),asPDFNumber(e)])},stroke=function(){return PDFOperator.of(Ops.StrokePath)},fill=function(){return PDFOperator.of(Ops.FillNonZero)},fillAndStroke=function(){return PDFOperator.of(Ops.FillNonZeroAndStroke)},endPath=function(){return PDFOperator.of(Ops.EndPath)},nextLine=function(){return PDFOperator.of(Ops.NextLine)},showText=function(t){return PDFOperator.of(Ops.ShowText,[t])},beginText=function(){return PDFOperator.of(Ops.BeginText)},endText=function(){return PDFOperator.of(Ops.EndText)},setFontAndSize=function(t,e){return PDFOperator.of(Ops.SetFontAndSize,[asPDFName(t),asPDFNumber(e)])},setLineHeight=function(t){return PDFOperator.of(Ops.SetTextLineHeight,[asPDFNumber(t)])},TextRenderingMode;(function(t){t[t.Fill=0]="Fill",t[t.Outline=1]="Outline",t[t.FillAndOutline=2]="FillAndOutline",t[t.Invisible=3]="Invisible",t[t.FillAndClip=4]="FillAndClip",t[t.OutlineAndClip=5]="OutlineAndClip",t[t.FillAndOutlineAndClip=6]="FillAndOutlineAndClip",t[t.Clip=7]="Clip"})(TextRenderingMode||(TextRenderingMode={}));var setTextMatrix=function(t,e,r,n,a,s){return PDFOperator.of(Ops.SetTextMatrix,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n),asPDFNumber(a),asPDFNumber(s)])},rotateAndSkewTextRadiansAndTranslate=function(t,e,r,n,a){return setTextMatrix(cos(asNumber(t)),sin(asNumber(t))+tan(asNumber(e)),-sin(asNumber(t))+tan(asNumber(r)),cos(asNumber(t)),n,a)},drawObject=function(t){return PDFOperator.of(Ops.DrawObject,[asPDFName(t)])},setFillingGrayscaleColor=function(t){return PDFOperator.of(Ops.NonStrokingColorGray,[asPDFNumber(t)])},setStrokingGrayscaleColor=function(t){return PDFOperator.of(Ops.StrokingColorGray,[asPDFNumber(t)])},setFillingRgbColor=function(t,e,r){return PDFOperator.of(Ops.NonStrokingColorRgb,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r)])},setStrokingRgbColor=function(t,e,r){return PDFOperator.of(Ops.StrokingColorRgb,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r)])},setFillingCmykColor=function(t,e,r,n){return PDFOperator.of(Ops.NonStrokingColorCmyk,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n)])},setStrokingCmykColor=function(t,e,r,n){return PDFOperator.of(Ops.StrokingColorCmyk,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n)])},beginMarkedContent=function(t){return PDFOperator.of(Ops.BeginMarkedContent,[asPDFName(t)])},endMarkedContent=function(){return PDFOperator.of(Ops.EndMarkedContent)},ColorTypes;(function(t){t.Grayscale="Grayscale",t.RGB="RGB",t.CMYK="CMYK"})(ColorTypes||(ColorTypes={}));var grayscale=function(t){return assertRange(t,"gray",0,1),{type:ColorTypes.Grayscale,gray:t}},rgb=function(t,e,r){return assertRange(t,"red",0,1),assertRange(e,"green",0,1),assertRange(r,"blue",0,1),{type:ColorTypes.RGB,red:t,green:e,blue:r}},cmyk=function(t,e,r,n){return assertRange(t,"cyan",0,1),assertRange(e,"magenta",0,1),assertRange(r,"yellow",0,1),assertRange(n,"key",0,1),{type:ColorTypes.CMYK,cyan:t,magenta:e,yellow:r,key:n}},Grayscale=ColorTypes.Grayscale,RGB=ColorTypes.RGB,CMYK=ColorTypes.CMYK,setFillingColor=function(t){return t.type===Grayscale?setFillingGrayscaleColor(t.gray):t.type===RGB?setFillingRgbColor(t.red,t.green,t.blue):t.type===CMYK?setFillingCmykColor(t.cyan,t.magenta,t.yellow,t.key):error("Invalid color: "+JSON.stringify(t))},setStrokingColor=function(t){return t.type===Grayscale?setStrokingGrayscaleColor(t.gray):t.type===RGB?setStrokingRgbColor(t.red,t.green,t.blue):t.type===CMYK?setStrokingCmykColor(t.cyan,t.magenta,t.yellow,t.key):error("Invalid color: "+JSON.stringify(t))},componentsToColor=function(t,e){return e===void 0&&(e=1),(t==null?void 0:t.length)===1?grayscale(t[0]*e):(t==null?void 0:t.length)===3?rgb(t[0]*e,t[1]*e,t[2]*e):(t==null?void 0:t.length)===4?cmyk(t[0]*e,t[1]*e,t[2]*e,t[3]*e):void 0},colorToComponents=function(t){return t.type===Grayscale?[t.gray]:t.type===RGB?[t.red,t.green,t.blue]:t.type===CMYK?[t.cyan,t.magenta,t.yellow,t.key]:error("Invalid color: "+JSON.stringify(t))},cx=0,cy=0,px=0,py=0,sx=0,sy=0,parameters=new Map([["A",7],["a",7],["C",6],["c",6],["H",1],["h",1],["L",2],["l",2],["M",2],["m",2],["Q",4],["q",4],["S",4],["s",4],["T",2],["t",2],["V",1],["v",1],["Z",0],["z",0]]),parse=function(t){for(var e,r=[],n=[],a="",s=!1,o=0,h=0,d=t;h<d.length;h++){var l=d[h];if(parameters.has(l))o=parameters.get(l),e&&(a.length>0&&(n[n.length]=+a),r[r.length]={cmd:e,args:n},n=[],a="",s=!1),e=l;else if([" ",","].includes(l)||l==="-"&&a.length>0&&a[a.length-1]!=="e"||l==="."&&s){if(a.length===0)continue;n.length===o?(r[r.length]={cmd:e,args:n},n=[+a],e==="M"&&(e="L"),e==="m"&&(e="l")):n[n.length]=+a,s=l===".",a=["-","."].includes(l)?l:""}else a+=l,l==="."&&(s=!0)}return a.length>0&&(n.length===o?(r[r.length]={cmd:e,args:n},n=[+a],e==="M"&&(e="L"),e==="m"&&(e="l")):n[n.length]=+a),r[r.length]={cmd:e,args:n},r},apply=function(t){cx=cy=px=py=sx=sy=0;for(var e=[],r=0;r<t.length;r++){var n=t[r];if(n.cmd&&typeof runners[n.cmd]=="function"){var a=runners[n.cmd](n.args);Array.isArray(a)?e=e.concat(a):e.push(a)}}return e},runners={M:function(t){return cx=t[0],cy=t[1],px=py=null,sx=cx,sy=cy,moveTo(cx,cy)},m:function(t){return cx+=t[0],cy+=t[1],px=py=null,sx=cx,sy=cy,moveTo(cx,cy)},C:function(t){return cx=t[4],cy=t[5],px=t[2],py=t[3],appendBezierCurve(t[0],t[1],t[2],t[3],t[4],t[5])},c:function(t){var e=appendBezierCurve(t[0]+cx,t[1]+cy,t[2]+cx,t[3]+cy,t[4]+cx,t[5]+cy);return px=cx+t[2],py=cy+t[3],cx+=t[4],cy+=t[5],e},S:function(t){(px===null||py===null)&&(px=cx,py=cy);var e=appendBezierCurve(cx-(px-cx),cy-(py-cy),t[0],t[1],t[2],t[3]);return px=t[0],py=t[1],cx=t[2],cy=t[3],e},s:function(t){(px===null||py===null)&&(px=cx,py=cy);var e=appendBezierCurve(cx-(px-cx),cy-(py-cy),cx+t[0],cy+t[1],cx+t[2],cy+t[3]);return px=cx+t[0],py=cy+t[1],cx+=t[2],cy+=t[3],e},Q:function(t){return px=t[0],py=t[1],cx=t[2],cy=t[3],appendQuadraticCurve(t[0],t[1],cx,cy)},q:function(t){var e=appendQuadraticCurve(t[0]+cx,t[1]+cy,t[2]+cx,t[3]+cy);return px=cx+t[0],py=cy+t[1],cx+=t[2],cy+=t[3],e},T:function(t){px===null||py===null?(px=cx,py=cy):(px=cx-(px-cx),py=cy-(py-cy));var e=appendQuadraticCurve(px,py,t[0],t[1]);return px=cx-(px-cx),py=cy-(py-cy),cx=t[0],cy=t[1],e},t:function(t){px===null||py===null?(px=cx,py=cy):(px=cx-(px-cx),py=cy-(py-cy));var e=appendQuadraticCurve(px,py,cx+t[0],cy+t[1]);return cx+=t[0],cy+=t[1],e},A:function(t){var e=solveArc(cx,cy,t);return cx=t[5],cy=t[6],e},a:function(t){t[5]+=cx,t[6]+=cy;var e=solveArc(cx,cy,t);return cx=t[5],cy=t[6],e},L:function(t){return cx=t[0],cy=t[1],px=py=null,lineTo(cx,cy)},l:function(t){return cx+=t[0],cy+=t[1],px=py=null,lineTo(cx,cy)},H:function(t){return cx=t[0],px=py=null,lineTo(cx,cy)},h:function(t){return cx+=t[0],px=py=null,lineTo(cx,cy)},V:function(t){return cy=t[0],px=py=null,lineTo(cx,cy)},v:function(t){return cy+=t[0],px=py=null,lineTo(cx,cy)},Z:function(){var t=closePath();return cx=sx,cy=sy,t},z:function(){var t=closePath();return cx=sx,cy=sy,t}},solveArc=function(t,e,r){for(var n=r[0],a=r[1],s=r[2],o=r[3],h=r[4],d=r[5],l=r[6],u=arcToSegments(d,l,n,a,o,h,s,t,e),p=[],g=0,f=u;g<f.length;g++){var v=f[g],y=segmentToBezier.apply(void 0,v);p.push(appendBezierCurve.apply(void 0,y))}return p},arcToSegments=function(t,e,r,n,a,s,o,h,d){var l=o*(Math.PI/180),u=Math.sin(l),p=Math.cos(l);r=Math.abs(r),n=Math.abs(n),px=p*(h-t)*.5+u*(d-e)*.5,py=p*(d-e)*.5-u*(h-t)*.5;var g=px*px/(r*r)+py*py/(n*n);g>1&&(g=Math.sqrt(g),r*=g,n*=g);var f=p/r,v=u/r,y=-u/n,x=p/n,m=f*h+v*d,w=y*h+x*d,R=f*t+v*e,_=y*t+x*e,S=(R-m)*(R-m)+(_-w)*(_-w),F=1/S-.25;F<0&&(F=0);var A=Math.sqrt(F);s===a&&(A=-A);var D=.5*(m+R)-A*(_-w),T=.5*(w+_)+A*(R-m),M=Math.atan2(w-T,m-D),C=Math.atan2(_-T,R-D),k=C-M;k<0&&s===1?k+=2*Math.PI:k>0&&s===0&&(k-=2*Math.PI);for(var O=Math.ceil(Math.abs(k/(Math.PI*.5+.001))),$=[],K=0;K<O;K++){var J=M+K*k/O,Y=M+(K+1)*k/O;$[K]=[D,T,J,Y,r,n,u,p]}return $},segmentToBezier=function(t,e,r,n,a,s,o,h){var d=h*a,l=-o*s,u=o*a,p=h*s,g=.5*(n-r),f=8/3*Math.sin(g*.5)*Math.sin(g*.5)/Math.sin(g),v=t+Math.cos(r)-f*Math.sin(r),y=e+Math.sin(r)+f*Math.cos(r),x=t+Math.cos(n),m=e+Math.sin(n),w=x+f*Math.sin(n),R=m-f*Math.cos(n),_=[d*v+l*y,u*v+p*y,d*w+l*R,u*w+p*R,d*x+l*m,u*x+p*m];return _},svgPathToOperators=function(t){return apply(parse(t))},drawLinesOfText=function(t,e){for(var r=[pushGraphicsState(),e.graphicsState&&setGraphicsState(e.graphicsState),beginText(),setFillingColor(e.color),setFontAndSize(e.font,e.size),setLineHeight(e.lineHeight),rotateAndSkewTextRadiansAndTranslate(toRadians(e.rotate),toRadians(e.xSkew),toRadians(e.ySkew),e.x,e.y)].filter(Boolean),n=0,a=t.length;n<a;n++)r.push(showText(t[n]),nextLine());return r.push(endText(),popGraphicsState()),r},drawImage=function(t,e){return[pushGraphicsState(),e.graphicsState&&setGraphicsState(e.graphicsState),translate(e.x,e.y),rotateRadians(toRadians(e.rotate)),scale(e.width,e.height),skewRadians(toRadians(e.xSkew),toRadians(e.ySkew)),drawObject(t),popGraphicsState()].filter(Boolean)},drawPage=function(t,e){return[pushGraphicsState(),e.graphicsState&&setGraphicsState(e.graphicsState),translate(e.x,e.y),rotateRadians(toRadians(e.rotate)),scale(e.xScale,e.yScale),skewRadians(toRadians(e.xSkew),toRadians(e.ySkew)),drawObject(t),popGraphicsState()].filter(Boolean)},drawLine=function(t){var e,r;return[pushGraphicsState(),t.graphicsState&&setGraphicsState(t.graphicsState),t.color&&setStrokingColor(t.color),setLineWidth(t.thickness),setDashPattern((e=t.dashArray)!==null&&e!==void 0?e:[],(r=t.dashPhase)!==null&&r!==void 0?r:0),moveTo(t.start.x,t.start.y),t.lineCap&&setLineCap(t.lineCap),moveTo(t.start.x,t.start.y),lineTo(t.end.x,t.end.y),stroke(),popGraphicsState()].filter(Boolean)},drawRectangle=function(t){var e,r;return[pushGraphicsState(),t.graphicsState&&setGraphicsState(t.graphicsState),t.color&&setFillingColor(t.color),t.borderColor&&setStrokingColor(t.borderColor),setLineWidth(t.borderWidth),t.borderLineCap&&setLineCap(t.borderLineCap),setDashPattern((e=t.borderDashArray)!==null&&e!==void 0?e:[],(r=t.borderDashPhase)!==null&&r!==void 0?r:0),translate(t.x,t.y),rotateRadians(toRadians(t.rotate)),skewRadians(toRadians(t.xSkew),toRadians(t.ySkew)),moveTo(0,0),lineTo(0,t.height),lineTo(t.width,t.height),lineTo(t.width,0),closePath(),t.color&&t.borderWidth?fillAndStroke():t.color?fill():t.borderColor?stroke():closePath(),popGraphicsState()].filter(Boolean)},KAPPA=4*((Math.sqrt(2)-1)/3),drawEllipsePath=function(t){var e=asNumber(t.x),r=asNumber(t.y),n=asNumber(t.xScale),a=asNumber(t.yScale);e-=n,r-=a;var s=n*KAPPA,o=a*KAPPA,h=e+n*2,d=r+a*2,l=e+n,u=r+a;return[pushGraphicsState(),moveTo(e,u),appendBezierCurve(e,u-o,l-s,r,l,r),appendBezierCurve(l+s,r,h,u-o,h,u),appendBezierCurve(h,u+o,l+s,d,l,d),appendBezierCurve(l-s,d,e,u+o,e,u),popGraphicsState()]},drawEllipseCurves=function(t){var e=asNumber(t.x),r=asNumber(t.y),n=asNumber(t.xScale),a=asNumber(t.yScale),s=-n,o=-a,h=n*KAPPA,d=a*KAPPA,l=s+n*2,u=o+a*2,p=s+n,g=o+a;return[translate(e,r),rotateRadians(toRadians(t.rotate)),moveTo(s,g),appendBezierCurve(s,g-d,p-h,o,p,o),appendBezierCurve(p+h,o,l,g-d,l,g),appendBezierCurve(l,g+d,p+h,u,p,u),appendBezierCurve(p-h,u,s,g+d,s,g)]},drawEllipse=function(t){var e,r,n;return __spreadArrays([pushGraphicsState(),t.graphicsState&&setGraphicsState(t.graphicsState),t.color&&setFillingColor(t.color),t.borderColor&&setStrokingColor(t.borderColor),setLineWidth(t.borderWidth),t.borderLineCap&&setLineCap(t.borderLineCap),setDashPattern((e=t.borderDashArray)!==null&&e!==void 0?e:[],(r=t.borderDashPhase)!==null&&r!==void 0?r:0)],t.rotate===void 0?drawEllipsePath({x:t.x,y:t.y,xScale:t.xScale,yScale:t.yScale}):drawEllipseCurves({x:t.x,y:t.y,xScale:t.xScale,yScale:t.yScale,rotate:(n=t.rotate)!==null&&n!==void 0?n:degrees(0)}),[t.color&&t.borderWidth?fillAndStroke():t.color?fill():t.borderColor?stroke():closePath(),popGraphicsState()]).filter(Boolean)},drawSvgPath=function(t,e){var r,n,a;return __spreadArrays([pushGraphicsState(),e.graphicsState&&setGraphicsState(e.graphicsState),translate(e.x,e.y),rotateRadians(toRadians((r=e.rotate)!==null&&r!==void 0?r:degrees(0))),e.scale?scale(e.scale,-e.scale):scale(1,-1),e.color&&setFillingColor(e.color),e.borderColor&&setStrokingColor(e.borderColor),e.borderWidth&&setLineWidth(e.borderWidth),e.borderLineCap&&setLineCap(e.borderLineCap),setDashPattern((n=e.borderDashArray)!==null&&n!==void 0?n:[],(a=e.borderDashPhase)!==null&&a!==void 0?a:0)],svgPathToOperators(t),[e.color&&e.borderWidth?fillAndStroke():e.color?fill():e.borderColor?stroke():closePath(),popGraphicsState()]).filter(Boolean)},drawCheckMark=function(t){var e=asNumber(t.size),r=-1+.75,n=-1+.51,a=1-.525,s=1-.31,o=-1+.325,h=.3995/(a-n)+n;return[pushGraphicsState(),t.color&&setStrokingColor(t.color),setLineWidth(t.thickness),translate(t.x,t.y),moveTo(o*e,h*e),lineTo(r*e,n*e),lineTo(s*e,a*e),stroke(),popGraphicsState()].filter(Boolean)},rotateInPlace=function(t){return t.rotation===0?[translate(0,0),rotateDegrees(0)]:t.rotation===90?[translate(t.width,0),rotateDegrees(90)]:t.rotation===180?[translate(t.width,t.height),rotateDegrees(180)]:t.rotation===270?[translate(0,t.height),rotateDegrees(270)]:[]},drawCheckBox=function(t){var e=drawRectangle({x:t.x,y:t.y,width:t.width,height:t.height,borderWidth:t.borderWidth,color:t.color,borderColor:t.borderColor,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)});if(!t.filled)return e;var r=asNumber(t.width),n=asNumber(t.height),a=Math.min(r,n)/2,s=drawCheckMark({x:r/2,y:n/2,size:a,thickness:t.thickness,color:t.markColor});return __spreadArrays([pushGraphicsState()],e,s,[popGraphicsState()])},drawRadioButton=function(t){var e=asNumber(t.width),r=asNumber(t.height),n=Math.min(e,r)/2,a=drawEllipse({x:t.x,y:t.y,xScale:n,yScale:n,color:t.color,borderColor:t.borderColor,borderWidth:t.borderWidth});if(!t.filled)return a;var s=drawEllipse({x:t.x,y:t.y,xScale:n*.45,yScale:n*.45,color:t.dotColor,borderColor:void 0,borderWidth:0});return __spreadArrays([pushGraphicsState()],a,s,[popGraphicsState()])},drawButton=function(t){var e=asNumber(t.x),r=asNumber(t.y),n=asNumber(t.width),a=asNumber(t.height),s=drawRectangle({x:e,y:r,width:n,height:a,borderWidth:t.borderWidth,color:t.color,borderColor:t.borderColor,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}),o=drawTextLines(t.textLines,{color:t.textColor,font:t.font,size:t.fontSize,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)});return __spreadArrays([pushGraphicsState()],s,o,[popGraphicsState()])},drawTextLines=function(t,e){for(var r=[beginText(),setFillingColor(e.color),setFontAndSize(e.font,e.size)],n=0,a=t.length;n<a;n++){var s=t[n],o=s.encoded,h=s.x,d=s.y;r.push(rotateAndSkewTextRadiansAndTranslate(toRadians(e.rotate),toRadians(e.xSkew),toRadians(e.ySkew),h,d),showText(o))}return r.push(endText()),r},drawTextField=function(t){var e=asNumber(t.x),r=asNumber(t.y),n=asNumber(t.width),a=asNumber(t.height),s=asNumber(t.borderWidth),o=asNumber(t.padding),h=e+s/2+o,d=r+s/2+o,l=n-(s/2+o)*2,u=a-(s/2+o)*2,p=[moveTo(h,d),lineTo(h,d+u),lineTo(h+l,d+u),lineTo(h+l,d),closePath(),clip(),endPath()],g=drawRectangle({x:e,y:r,width:n,height:a,borderWidth:t.borderWidth,color:t.color,borderColor:t.borderColor,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}),f=drawTextLines(t.textLines,{color:t.textColor,font:t.font,size:t.fontSize,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}),v=__spreadArrays([beginMarkedContent("Tx"),pushGraphicsState()],f,[popGraphicsState(),endMarkedContent()]);return __spreadArrays([pushGraphicsState()],g,p,v,[popGraphicsState()])},drawOptionList=function(t){for(var e=asNumber(t.x),r=asNumber(t.y),n=asNumber(t.width),a=asNumber(t.height),s=asNumber(t.lineHeight),o=asNumber(t.borderWidth),h=asNumber(t.padding),d=e+o/2+h,l=r+o/2+h,u=n-(o/2+h)*2,p=a-(o/2+h)*2,g=[moveTo(d,l),lineTo(d,l+p),lineTo(d+u,l+p),lineTo(d+u,l),closePath(),clip(),endPath()],f=drawRectangle({x:e,y:r,width:n,height:a,borderWidth:t.borderWidth,color:t.color,borderColor:t.borderColor,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}),v=[],y=0,x=t.selectedLines.length;y<x;y++){var m=t.textLines[t.selectedLines[y]];v.push.apply(v,drawRectangle({x:m.x-h,y:m.y-(s-m.height)/2,width:n-o,height:m.height+(s-m.height)/2,borderWidth:0,color:t.selectedColor,borderColor:void 0,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}))}var w=drawTextLines(t.textLines,{color:t.textColor,font:t.font,size:t.fontSize,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}),R=__spreadArrays([beginMarkedContent("Tx"),pushGraphicsState()],w,[popGraphicsState(),endMarkedContent()]);return __spreadArrays([pushGraphicsState()],f,v,g,R,[popGraphicsState()])},EncryptedPDFError=function(t){__extends(e,t);function e(){var r=this,n="Input document to `PDFDocument.load` is encrypted. You can use `PDFDocument.load(..., { ignoreEncryption: true })` if you wish to load the document anyways.";return r=t.call(this,n)||this,r}return e}(Error),FontkitNotRegisteredError=function(t){__extends(e,t);function e(){var r=this,n="Input to `PDFDocument.embedFont` was a custom font, but no `fontkit` instance was found. You must register a `fontkit` instance with `PDFDocument.registerFontkit(...)` before embedding custom fonts.";return r=t.call(this,n)||this,r}return e}(Error),ForeignPageError=function(t){__extends(e,t);function e(){var r=this,n="A `page` passed to `PDFDocument.addPage` or `PDFDocument.insertPage` was from a different (foreign) PDF document. If you want to copy pages from one PDFDocument to another, you must use `PDFDocument.copyPages(...)` to copy the pages before adding or inserting them.";return r=t.call(this,n)||this,r}return e}(Error),RemovePageFromEmptyDocumentError=function(t){__extends(e,t);function e(){var r=this,n="PDFDocument has no pages so `PDFDocument.removePage` cannot be called";return r=t.call(this,n)||this,r}return e}(Error),NoSuchFieldError=function(t){__extends(e,t);function e(r){var n=this,a='PDFDocument has no form field with the name "'+r+'"';return n=t.call(this,a)||this,n}return e}(Error),UnexpectedFieldTypeError=function(t){__extends(e,t);function e(r,n,a){var s,o,h=this,d=n==null?void 0:n.name,l=(o=(s=a==null?void 0:a.constructor)===null||s===void 0?void 0:s.name)!==null&&o!==void 0?o:a,u='Expected field "'+r+'" to be of type '+d+", "+("but it is actually of type "+l);return h=t.call(this,u)||this,h}return e}(Error);(function(t){__extends(e,t);function e(r){var n=this,a='Failed to select check box due to missing onValue: "'+r+'"';return n=t.call(this,a)||this,n}return e})(Error);var FieldAlreadyExistsError=function(t){__extends(e,t);function e(r){var n=this,a='A field already exists with the specified name: "'+r+'"';return n=t.call(this,a)||this,n}return e}(Error),InvalidFieldNamePartError=function(t){__extends(e,t);function e(r){var n=this,a='Field name contains invalid component: "'+r+'"';return n=t.call(this,a)||this,n}return e}(Error);(function(t){__extends(e,t);function e(r){var n=this,a='A non-terminal field already exists with the specified name: "'+r+'"';return n=t.call(this,a)||this,n}return e})(Error);var RichTextFieldReadError=function(t){__extends(e,t);function e(r){var n=this,a="Reading rich text fields is not supported: Attempted to read rich text field: "+r;return n=t.call(this,a)||this,n}return e}(Error),CombedTextLayoutError=function(t){__extends(e,t);function e(r,n){var a=this,s="Failed to layout combed text as lineLength="+r+" is greater than cellCount="+n;return a=t.call(this,s)||this,a}return e}(Error),ExceededMaxLengthError=function(t){__extends(e,t);function e(r,n,a){var s=this,o="Attempted to set text with length="+r+" for TextField with maxLength="+n+" and name="+a;return s=t.call(this,o)||this,s}return e}(Error),InvalidMaxLengthError=function(t){__extends(e,t);function e(r,n,a){var s=this,o="Attempted to set maxLength="+n+", which is less than "+r+", the length of this field's current value (name="+a+")";return s=t.call(this,o)||this,s}return e}(Error),TextAlignment;(function(t){t[t.Left=0]="Left",t[t.Center=1]="Center",t[t.Right=2]="Right"})(TextAlignment||(TextAlignment={}));var MIN_FONT_SIZE=4,MAX_FONT_SIZE=500,computeFontSize=function(t,e,r,n){n===void 0&&(n=!1);for(var a=MIN_FONT_SIZE;a<MAX_FONT_SIZE;){for(var s=0,o=0,h=t.length;o<h;o++){s+=1;for(var d=t[o],l=d.split(" "),u=r.width,p=0,g=l.length;p<g;p++){var f=p===g-1,v=f?l[p]:l[p]+" ",y=e.widthOfTextAtSize(v,a);u-=y,u<=0&&(s+=1,u=r.width-y)}}if(!n&&s>t.length)return a-1;var x=e.heightAtSize(a),m=x+x*.2,w=m*s;if(w>Math.abs(r.height))return a-1;a+=1}return a},computeCombedFontSize=function(t,e,r,n){for(var a=r.width/n,s=r.height,o=MIN_FONT_SIZE,h=charSplit(t);o<MAX_FONT_SIZE;){for(var d=0,l=h.length;d<l;d++){var u=h[d],p=e.widthOfTextAtSize(u,o)>a*.75;if(p)return o-1}var g=e.heightAtSize(o,{descender:!1});if(g>s)return o-1;o+=1}return o},lastIndexOfWhitespace=function(t){for(var e=t.length;e>0;e--)if(/\s/.test(t[e]))return e},splitOutLines=function(t,e,r,n){for(var a,s=t.length;s>0;){var o=t.substring(0,s),h=r.encodeText(o),d=r.widthOfTextAtSize(o,n);if(d<e){var l=t.substring(s)||void 0;return{line:o,encoded:h,width:d,remainder:l}}s=(a=lastIndexOfWhitespace(o))!==null&&a!==void 0?a:0}return{line:t,encoded:r.encodeText(t),width:r.widthOfTextAtSize(t,n),remainder:void 0}},layoutMultilineText=function(t,e){var r=e.alignment,n=e.fontSize,a=e.font,s=e.bounds,o=lineSplit(cleanText(t));(n===void 0||n===0)&&(n=computeFontSize(o,a,s,!0));for(var h=a.heightAtSize(n),d=h+h*.2,l=[],u=s.x,p=s.y,g=s.x+s.width,f=s.y+s.height,v=s.y+s.height,y=0,x=o.length;y<x;y++)for(var m=o[y];m!==void 0;){var w=splitOutLines(m,s.width,a,n),R=w.line,_=w.encoded,S=w.width,F=w.remainder,A=r===TextAlignment.Left?s.x:r===TextAlignment.Center?s.x+s.width/2-S/2:r===TextAlignment.Right?s.x+s.width-S:s.x;v-=d,A<u&&(u=A),v<p&&(p=v),A+S>g&&(g=A+S),v+h>f&&(f=v+h),l.push({text:R,encoded:_,width:S,height:h,x:A,y:v}),m=F==null?void 0:F.trim()}return{fontSize:n,lineHeight:d,lines:l,bounds:{x:u,y:p,width:g-u,height:f-p}}},layoutCombedText=function(t,e){var r=e.fontSize,n=e.font,a=e.bounds,s=e.cellCount,o=mergeLines(cleanText(t));if(o.length>s)throw new CombedTextLayoutError(o.length,s);(r===void 0||r===0)&&(r=computeCombedFontSize(o,n,a,s));for(var h=a.width/s,d=n.heightAtSize(r,{descender:!1}),l=a.y+(a.height/2-d/2),u=[],p=a.x,g=a.y,f=a.x+a.width,v=a.y+a.height,y=0,x=0;y<s;){var m=charAtIndex(o,x),w=m[0],R=m[1],_=n.encodeText(w),S=n.widthOfTextAtSize(w,r),F=a.x+(h*y+h/2),A=F-S/2;A<p&&(p=A),l<g&&(g=l),A+S>f&&(f=A+S),l+d>v&&(v=l+d),u.push({text:o,encoded:_,width:S,height:d,x:A,y:l}),y+=1,x+=R}return{fontSize:r,cells:u,bounds:{x:p,y:g,width:f-p,height:v-g}}},layoutSinglelineText=function(t,e){var r=e.alignment,n=e.fontSize,a=e.font,s=e.bounds,o=mergeLines(cleanText(t));(n===void 0||n===0)&&(n=computeFontSize([o],a,s));var h=a.encodeText(o),d=a.widthOfTextAtSize(o,n),l=a.heightAtSize(n,{descender:!1}),u=r===TextAlignment.Left?s.x:r===TextAlignment.Center?s.x+s.width/2-d/2:r===TextAlignment.Right?s.x+s.width-d:s.x,p=s.y+(s.height/2-l/2);return{fontSize:n,line:{text:o,encoded:h,width:d,height:l,x:u,y:p},bounds:{x:u,y:p,width:d,height:l}}},normalizeAppearance=function(t){return"normal"in t?t:{normal:t}},tfRegex=/\/([^\0\t\n\f\r\ ]+)[\0\t\n\f\r\ ]+(\d*\.\d+|\d+)[\0\t\n\f\r\ ]+Tf/,getDefaultFontSize=function(t){var e,r,n=(e=t.getDefaultAppearance())!==null&&e!==void 0?e:"",a=(r=findLastMatch(n,tfRegex).match)!==null&&r!==void 0?r:[],s=Number(a[2]);return isFinite(s)?s:void 0},colorRegex=/(\d*\.\d+|\d+)[\0\t\n\f\r\ ]*(\d*\.\d+|\d+)?[\0\t\n\f\r\ ]*(\d*\.\d+|\d+)?[\0\t\n\f\r\ ]*(\d*\.\d+|\d+)?[\0\t\n\f\r\ ]+(g|rg|k)/,getDefaultColor=function(t){var e,r=(e=t.getDefaultAppearance())!==null&&e!==void 0?e:"",n=findLastMatch(r,colorRegex).match,a=n??[],s=a[1],o=a[2],h=a[3],d=a[4],l=a[5];if(l==="g"&&s)return grayscale(Number(s));if(l==="rg"&&s&&o&&h)return rgb(Number(s),Number(o),Number(h));if(l==="k"&&s&&o&&h&&d)return cmyk(Number(s),Number(o),Number(h),Number(d))},updateDefaultAppearance=function(t,e,r,n){var a;n===void 0&&(n=0);var s=[setFillingColor(e).toString(),setFontAndSize((a=r==null?void 0:r.name)!==null&&a!==void 0?a:"dummy__noop",n).toString()].join(`
|
|
58
|
-
`);t.setDefaultAppearance(s)},defaultCheckBoxAppearanceProvider=function(t,e){var r,n,a,s=getDefaultColor(e),o=getDefaultColor(t.acroField),h=e.getRectangle(),d=e.getAppearanceCharacteristics(),l=e.getBorderStyle(),u=(r=l==null?void 0:l.getWidth())!==null&&r!==void 0?r:0,p=reduceRotation(d==null?void 0:d.getRotation()),g=adjustDimsForRotation(h,p),f=g.width,v=g.height,y=rotateInPlace(__assign(__assign({},h),{rotation:p})),
|
|
59
|
-
`);for(var M=1,C={x:g+M,y:g+M,width:y-(g+M)*2,height:
|
|
60
|
-
`+setFillingColor(n).toString();this.acroField.setDefaultAppearance(_)}return y},t.prototype.updateWidgetAppearanceWithFont=function(e,r,n){var a=n.normal,s=n.rollover,o=n.down;this.updateWidgetAppearances(e,{normal:this.createAppearanceStream(e,a,r),rollover:s&&this.createAppearanceStream(e,s,r),down:o&&this.createAppearanceStream(e,o,r)})},t.prototype.updateOnOffWidgetAppearance=function(e,r,n){var a=n.normal,s=n.rollover,o=n.down;this.updateWidgetAppearances(e,{normal:this.createAppearanceDict(e,a,r),rollover:s&&this.createAppearanceDict(e,s,r),down:o&&this.createAppearanceDict(e,o,r)})},t.prototype.updateWidgetAppearances=function(e,r){var n=r.normal,a=r.rollover,s=r.down;e.setNormalAppearance(n),a?e.setRolloverAppearance(a):e.removeRolloverAppearance(),s?e.setDownAppearance(s):e.removeDownAppearance()},t.prototype.createAppearanceStream=function(e,r,n){var a,s=this.acroField.dict.context,o=e.getRectangle(),h=o.width,d=o.height,l=n&&{Font:(a={},a[n.name]=n.ref,a)},u=s.formXObject(r,{Resources:l,BBox:s.obj([0,0,h,d]),Matrix:s.obj([1,0,0,1,0,0])}),p=s.register(u);return p},t.prototype.createImageAppearanceStream=function(e,r,n){var a,s,o=this.acroField.dict.context,h=e.getRectangle(),d=e.getAppearanceCharacteristics(),l=e.getBorderStyle(),u=(s=l==null?void 0:l.getWidth())!==null&&s!==void 0?s:0,p=reduceRotation(d==null?void 0:d.getRotation()),g=rotateInPlace(__assign(__assign({},h),{rotation:p})),f=adjustDimsForRotation(h,p),v=r.scaleToFit(f.width-u*2,f.height-u*2),y={x:u,y:u,width:v.width,height:v.height,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)};n===ImageAlignment.Center?(y.x+=(f.width-u*2)/2-v.width/2,y.y+=(f.height-u*2)/2-v.height/2):n===ImageAlignment.Right&&(y.x=f.width-u-v.width,y.y=f.height-u-v.height);var x=this.doc.context.addRandomSuffix("Image",10),m=__spreadArrays(g,drawImage(x,y)),w={XObject:(a={},a[x]=r.ref,a)},R=o.formXObject(m,{Resources:w,BBox:o.obj([0,0,h.width,h.height]),Matrix:o.obj([1,0,0,1,0,0])});return o.register(R)},t.prototype.createAppearanceDict=function(e,r,n){var a=this.acroField.dict.context,s=this.createAppearanceStream(e,r.on),o=this.createAppearanceStream(e,r.off),h=a.obj({});return h.set(n,s),h.set(PDFName.of("Off"),o),h},t}(),PDFCheckBox=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroCheckBox",[[PDFAcroCheckBox,"PDFAcroCheckBox"]]),s.acroField=r,s}return e.prototype.check=function(){var r,n=(r=this.acroField.getOnValue())!==null&&r!==void 0?r:PDFName.of("Yes");this.markAsDirty(),this.acroField.setValue(n)},e.prototype.uncheck=function(){this.markAsDirty(),this.acroField.setValue(PDFName.of("Off"))},e.prototype.isChecked=function(){var r=this.acroField.getOnValue();return!!r&&r===this.acroField.getValue()},e.prototype.addToPage=function(r,n){var a,s,o,h,d,l;assertIs(r,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(n),n||(n={}),"textColor"in n||(n.textColor=rgb(0,0,0)),"backgroundColor"in n||(n.backgroundColor=rgb(1,1,1)),"borderColor"in n||(n.borderColor=rgb(0,0,0)),"borderWidth"in n||(n.borderWidth=1);var u=this.createWidget({x:(a=n.x)!==null&&a!==void 0?a:0,y:(s=n.y)!==null&&s!==void 0?s:0,width:(o=n.width)!==null&&o!==void 0?o:50,height:(h=n.height)!==null&&h!==void 0?h:50,textColor:n.textColor,backgroundColor:n.backgroundColor,borderColor:n.borderColor,borderWidth:(d=n.borderWidth)!==null&&d!==void 0?d:0,rotate:(l=n.rotate)!==null&&l!==void 0?l:degrees(0),hidden:n.hidden,page:r.ref}),p=this.doc.context.register(u.dict);this.acroField.addWidget(p),u.setAppearanceState(PDFName.of("Off")),this.updateWidgetAppearance(u,PDFName.of("Yes")),r.node.addAnnot(p)},e.prototype.needsAppearancesUpdate=function(){for(var r,n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=o.getAppearanceState(),d=(r=o.getAppearances())===null||r===void 0?void 0:r.normal;if(!(d instanceof PDFDict)||h&&!d.has(h))return!0}return!1},e.prototype.defaultUpdateAppearances=function(){this.updateAppearances()},e.prototype.updateAppearances=function(r){var n;assertOrUndefined(r,"provider",[Function]);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s],d=(n=h.getOnValue())!==null&&n!==void 0?n:PDFName.of("Yes");d&&this.updateWidgetAppearance(h,d,r)}this.markAsClean()},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultCheckBoxAppearanceProvider,o=normalizeAppearance(s(this,r));this.updateOnOffWidgetAppearance(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),PDFDropdown=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroComboBox",[[PDFAcroComboBox,"PDFAcroComboBox"]]),s.acroField=r,s}return e.prototype.getOptions=function(){for(var r=this.acroField.getOptions(),n=new Array(r.length),a=0,s=n.length;a<s;a++){var o=r[a],h=o.display,d=o.value;n[a]=(h??d).decodeText()}return n},e.prototype.getSelected=function(){for(var r=this.acroField.getValues(),n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]=r[a].decodeText();return n},e.prototype.setOptions=function(r){assertIs(r,"options",[Array]);for(var n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]={value:PDFHexString.fromText(r[a])};this.acroField.setOptions(n)},e.prototype.addOptions=function(r){assertIs(r,"options",["string",Array]);for(var n=Array.isArray(r)?r:[r],a=this.acroField.getOptions(),s=new Array(n.length),o=0,h=n.length;o<h;o++)s[o]={value:PDFHexString.fromText(n[o])};this.acroField.setOptions(a.concat(s))},e.prototype.select=function(r,n){n===void 0&&(n=!1),assertIs(r,"options",["string",Array]),assertIs(n,"merge",["boolean"]);var a=Array.isArray(r)?r:[r],s=this.getOptions(),o=a.find(function(p){return!s.includes(p)});o&&this.enableEditing(),this.markAsDirty(),(a.length>1||a.length===1&&n)&&this.enableMultiselect();for(var h=new Array(a.length),d=0,l=a.length;d<l;d++)h[d]=PDFHexString.fromText(a[d]);if(n){var u=this.acroField.getValues();this.acroField.setValues(u.concat(h))}else this.acroField.setValues(h)},e.prototype.clear=function(){this.markAsDirty(),this.acroField.setValues([])},e.prototype.setFontSize=function(r){assertPositive(r,"fontSize"),this.acroField.setFontSize(r),this.markAsDirty()},e.prototype.isEditable=function(){return this.acroField.hasFlag(AcroChoiceFlags.Edit)},e.prototype.enableEditing=function(){this.acroField.setFlagTo(AcroChoiceFlags.Edit,!0)},e.prototype.disableEditing=function(){this.acroField.setFlagTo(AcroChoiceFlags.Edit,!1)},e.prototype.isSorted=function(){return this.acroField.hasFlag(AcroChoiceFlags.Sort)},e.prototype.enableSorting=function(){this.acroField.setFlagTo(AcroChoiceFlags.Sort,!0)},e.prototype.disableSorting=function(){this.acroField.setFlagTo(AcroChoiceFlags.Sort,!1)},e.prototype.isMultiselect=function(){return this.acroField.hasFlag(AcroChoiceFlags.MultiSelect)},e.prototype.enableMultiselect=function(){this.acroField.setFlagTo(AcroChoiceFlags.MultiSelect,!0)},e.prototype.disableMultiselect=function(){this.acroField.setFlagTo(AcroChoiceFlags.MultiSelect,!1)},e.prototype.isSpellChecked=function(){return!this.acroField.hasFlag(AcroChoiceFlags.DoNotSpellCheck)},e.prototype.enableSpellChecking=function(){this.acroField.setFlagTo(AcroChoiceFlags.DoNotSpellCheck,!1)},e.prototype.disableSpellChecking=function(){this.acroField.setFlagTo(AcroChoiceFlags.DoNotSpellCheck,!0)},e.prototype.isSelectOnClick=function(){return this.acroField.hasFlag(AcroChoiceFlags.CommitOnSelChange)},e.prototype.enableSelectOnClick=function(){this.acroField.setFlagTo(AcroChoiceFlags.CommitOnSelChange,!0)},e.prototype.disableSelectOnClick=function(){this.acroField.setFlagTo(AcroChoiceFlags.CommitOnSelChange,!1)},e.prototype.addToPage=function(r,n){var a,s,o,h,d,l,u;assertIs(r,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(n),n||(n={}),"textColor"in n||(n.textColor=rgb(0,0,0)),"backgroundColor"in n||(n.backgroundColor=rgb(1,1,1)),"borderColor"in n||(n.borderColor=rgb(0,0,0)),"borderWidth"in n||(n.borderWidth=1);var p=this.createWidget({x:(a=n.x)!==null&&a!==void 0?a:0,y:(s=n.y)!==null&&s!==void 0?s:0,width:(o=n.width)!==null&&o!==void 0?o:200,height:(h=n.height)!==null&&h!==void 0?h:50,textColor:n.textColor,backgroundColor:n.backgroundColor,borderColor:n.borderColor,borderWidth:(d=n.borderWidth)!==null&&d!==void 0?d:0,rotate:(l=n.rotate)!==null&&l!==void 0?l:degrees(0),hidden:n.hidden,page:r.ref}),g=this.doc.context.register(p.dict);this.acroField.addWidget(g);var f=(u=n.font)!==null&&u!==void 0?u:this.doc.getForm().getDefaultFont();this.updateWidgetAppearance(p,f),r.node.addAnnot(g)},e.prototype.needsAppearancesUpdate=function(){var r;if(this.isDirty())return!0;for(var n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=((r=o.getAppearances())===null||r===void 0?void 0:r.normal)instanceof PDFStream;if(!h)return!0}return!1},e.prototype.defaultUpdateAppearances=function(r){assertIs(r,"font",[[PDFFont,"PDFFont"]]),this.updateAppearances(r)},e.prototype.updateAppearances=function(r,n){assertIs(r,"font",[[PDFFont,"PDFFont"]]),assertOrUndefined(n,"provider",[Function]);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s];this.updateWidgetAppearance(h,r,n)}this.markAsClean()},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultDropdownAppearanceProvider,o=normalizeAppearance(s(this,r,n));this.updateWidgetAppearanceWithFont(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),PDFOptionList=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroListBox",[[PDFAcroListBox,"PDFAcroListBox"]]),s.acroField=r,s}return e.prototype.getOptions=function(){for(var r=this.acroField.getOptions(),n=new Array(r.length),a=0,s=n.length;a<s;a++){var o=r[a],h=o.display,d=o.value;n[a]=(h??d).decodeText()}return n},e.prototype.getSelected=function(){for(var r=this.acroField.getValues(),n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]=r[a].decodeText();return n},e.prototype.setOptions=function(r){assertIs(r,"options",[Array]),this.markAsDirty();for(var n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]={value:PDFHexString.fromText(r[a])};this.acroField.setOptions(n)},e.prototype.addOptions=function(r){assertIs(r,"options",["string",Array]),this.markAsDirty();for(var n=Array.isArray(r)?r:[r],a=this.acroField.getOptions(),s=new Array(n.length),o=0,h=n.length;o<h;o++)s[o]={value:PDFHexString.fromText(n[o])};this.acroField.setOptions(a.concat(s))},e.prototype.select=function(r,n){n===void 0&&(n=!1),assertIs(r,"options",["string",Array]),assertIs(n,"merge",["boolean"]);var a=Array.isArray(r)?r:[r],s=this.getOptions();assertIsSubset(a,"option",s),this.markAsDirty(),(a.length>1||a.length===1&&n)&&this.enableMultiselect();for(var o=new Array(a.length),h=0,d=a.length;h<d;h++)o[h]=PDFHexString.fromText(a[h]);if(n){var l=this.acroField.getValues();this.acroField.setValues(l.concat(o))}else this.acroField.setValues(o)},e.prototype.clear=function(){this.markAsDirty(),this.acroField.setValues([])},e.prototype.setFontSize=function(r){assertPositive(r,"fontSize"),this.acroField.setFontSize(r),this.markAsDirty()},e.prototype.isSorted=function(){return this.acroField.hasFlag(AcroChoiceFlags.Sort)},e.prototype.enableSorting=function(){this.acroField.setFlagTo(AcroChoiceFlags.Sort,!0)},e.prototype.disableSorting=function(){this.acroField.setFlagTo(AcroChoiceFlags.Sort,!1)},e.prototype.isMultiselect=function(){return this.acroField.hasFlag(AcroChoiceFlags.MultiSelect)},e.prototype.enableMultiselect=function(){this.acroField.setFlagTo(AcroChoiceFlags.MultiSelect,!0)},e.prototype.disableMultiselect=function(){this.acroField.setFlagTo(AcroChoiceFlags.MultiSelect,!1)},e.prototype.isSelectOnClick=function(){return this.acroField.hasFlag(AcroChoiceFlags.CommitOnSelChange)},e.prototype.enableSelectOnClick=function(){this.acroField.setFlagTo(AcroChoiceFlags.CommitOnSelChange,!0)},e.prototype.disableSelectOnClick=function(){this.acroField.setFlagTo(AcroChoiceFlags.CommitOnSelChange,!1)},e.prototype.addToPage=function(r,n){var a,s,o,h,d,l,u;assertIs(r,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(n),n||(n={}),"textColor"in n||(n.textColor=rgb(0,0,0)),"backgroundColor"in n||(n.backgroundColor=rgb(1,1,1)),"borderColor"in n||(n.borderColor=rgb(0,0,0)),"borderWidth"in n||(n.borderWidth=1);var p=this.createWidget({x:(a=n.x)!==null&&a!==void 0?a:0,y:(s=n.y)!==null&&s!==void 0?s:0,width:(o=n.width)!==null&&o!==void 0?o:200,height:(h=n.height)!==null&&h!==void 0?h:100,textColor:n.textColor,backgroundColor:n.backgroundColor,borderColor:n.borderColor,borderWidth:(d=n.borderWidth)!==null&&d!==void 0?d:0,rotate:(l=n.rotate)!==null&&l!==void 0?l:degrees(0),hidden:n.hidden,page:r.ref}),g=this.doc.context.register(p.dict);this.acroField.addWidget(g);var f=(u=n.font)!==null&&u!==void 0?u:this.doc.getForm().getDefaultFont();this.updateWidgetAppearance(p,f),r.node.addAnnot(g)},e.prototype.needsAppearancesUpdate=function(){var r;if(this.isDirty())return!0;for(var n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=((r=o.getAppearances())===null||r===void 0?void 0:r.normal)instanceof PDFStream;if(!h)return!0}return!1},e.prototype.defaultUpdateAppearances=function(r){assertIs(r,"font",[[PDFFont,"PDFFont"]]),this.updateAppearances(r)},e.prototype.updateAppearances=function(r,n){assertIs(r,"font",[[PDFFont,"PDFFont"]]),assertOrUndefined(n,"provider",[Function]);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s];this.updateWidgetAppearance(h,r,n)}this.markAsClean()},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultOptionListAppearanceProvider,o=normalizeAppearance(s(this,r,n));this.updateWidgetAppearanceWithFont(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),PDFRadioGroup=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroRadioButton",[[PDFAcroRadioButton,"PDFAcroRadioButton"]]),s.acroField=r,s}return e.prototype.getOptions=function(){var r=this.acroField.getExportValues();if(r){for(var n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]=r[a].decodeText();return n}for(var o=this.acroField.getOnValues(),h=new Array(o.length),a=0,s=h.length;a<s;a++)h[a]=o[a].decodeText();return h},e.prototype.getSelected=function(){var r=this.acroField.getValue();if(r!==PDFName.of("Off")){var n=this.acroField.getExportValues();if(n){for(var a=this.acroField.getOnValues(),s=0,o=a.length;s<o;s++)if(a[s]===r)return n[s].decodeText()}return r.decodeText()}},e.prototype.select=function(r){assertIs(r,"option",["string"]);var n=this.getOptions();assertIsOneOf(r,"option",n),this.markAsDirty();var a=this.acroField.getOnValues(),s=this.acroField.getExportValues();if(s)for(var o=0,h=s.length;o<h;o++)s[o].decodeText()===r&&this.acroField.setValue(a[o]);else for(var o=0,h=a.length;o<h;o++){var d=a[o];d.decodeText()===r&&this.acroField.setValue(d)}},e.prototype.clear=function(){this.markAsDirty(),this.acroField.setValue(PDFName.of("Off"))},e.prototype.isOffToggleable=function(){return!this.acroField.hasFlag(AcroButtonFlags.NoToggleToOff)},e.prototype.enableOffToggling=function(){this.acroField.setFlagTo(AcroButtonFlags.NoToggleToOff,!1)},e.prototype.disableOffToggling=function(){this.acroField.setFlagTo(AcroButtonFlags.NoToggleToOff,!0)},e.prototype.isMutuallyExclusive=function(){return!this.acroField.hasFlag(AcroButtonFlags.RadiosInUnison)},e.prototype.enableMutualExclusion=function(){this.acroField.setFlagTo(AcroButtonFlags.RadiosInUnison,!1)},e.prototype.disableMutualExclusion=function(){this.acroField.setFlagTo(AcroButtonFlags.RadiosInUnison,!0)},e.prototype.addOptionToPage=function(r,n,a){var s,o,h,d,l,u,p,g,f;assertIs(r,"option",["string"]),assertIs(n,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(a);var v=this.createWidget({x:(s=a==null?void 0:a.x)!==null&&s!==void 0?s:0,y:(o=a==null?void 0:a.y)!==null&&o!==void 0?o:0,width:(h=a==null?void 0:a.width)!==null&&h!==void 0?h:50,height:(d=a==null?void 0:a.height)!==null&&d!==void 0?d:50,textColor:(l=a==null?void 0:a.textColor)!==null&&l!==void 0?l:rgb(0,0,0),backgroundColor:(u=a==null?void 0:a.backgroundColor)!==null&&u!==void 0?u:rgb(1,1,1),borderColor:(p=a==null?void 0:a.borderColor)!==null&&p!==void 0?p:rgb(0,0,0),borderWidth:(g=a==null?void 0:a.borderWidth)!==null&&g!==void 0?g:1,rotate:(f=a==null?void 0:a.rotate)!==null&&f!==void 0?f:degrees(0),hidden:a==null?void 0:a.hidden,page:n.ref}),y=this.doc.context.register(v.dict),x=this.acroField.addWidgetWithOpt(y,PDFHexString.fromText(r),!this.isMutuallyExclusive());v.setAppearanceState(PDFName.of("Off")),this.updateWidgetAppearance(v,x),n.node.addAnnot(y)},e.prototype.needsAppearancesUpdate=function(){for(var r,n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=o.getAppearanceState(),d=(r=o.getAppearances())===null||r===void 0?void 0:r.normal;if(!(d instanceof PDFDict)||h&&!d.has(h))return!0}return!1},e.prototype.defaultUpdateAppearances=function(){this.updateAppearances()},e.prototype.updateAppearances=function(r){assertOrUndefined(r,"provider",[Function]);for(var n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=o.getOnValue();h&&this.updateWidgetAppearance(o,h,r)}},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultRadioGroupAppearanceProvider,o=normalizeAppearance(s(this,r));this.updateOnOffWidgetAppearance(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),PDFSignature=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroSignature",[[PDFAcroSignature,"PDFAcroSignature"]]),s.acroField=r,s}return e.prototype.needsAppearancesUpdate=function(){return!1},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),PDFTextField=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroText",[[PDFAcroText,"PDFAcroText"]]),s.acroField=r,s}return e.prototype.getText=function(){var r=this.acroField.getValue();if(!r&&this.isRichFormatted())throw new RichTextFieldReadError(this.getName());return r==null?void 0:r.decodeText()},e.prototype.setText=function(r){assertOrUndefined(r,"text",["string"]);var n=this.getMaxLength();if(n!==void 0&&r&&r.length>n)throw new ExceededMaxLengthError(r.length,n,this.getName());this.markAsDirty(),this.disableRichFormatting(),r?this.acroField.setValue(PDFHexString.fromText(r)):this.acroField.removeValue()},e.prototype.getAlignment=function(){var r=this.acroField.getQuadding();return r===0?TextAlignment.Left:r===1?TextAlignment.Center:r===2?TextAlignment.Right:TextAlignment.Left},e.prototype.setAlignment=function(r){assertIsOneOf(r,"alignment",TextAlignment),this.markAsDirty(),this.acroField.setQuadding(r)},e.prototype.getMaxLength=function(){return this.acroField.getMaxLength()},e.prototype.setMaxLength=function(r){if(assertRangeOrUndefined(r,"maxLength",0,Number.MAX_SAFE_INTEGER),this.markAsDirty(),r===void 0)this.acroField.removeMaxLength();else{var n=this.getText();if(n&&n.length>r)throw new InvalidMaxLengthError(n.length,r,this.getName());this.acroField.setMaxLength(r)}},e.prototype.removeMaxLength=function(){this.markAsDirty(),this.acroField.removeMaxLength()},e.prototype.setImage=function(r){for(var n=this.getAlignment(),a=n===TextAlignment.Center?ImageAlignment.Center:n===TextAlignment.Right?ImageAlignment.Right:ImageAlignment.Left,s=this.acroField.getWidgets(),o=0,h=s.length;o<h;o++){var d=s[o],l=this.createImageAppearanceStream(d,r,a);this.updateWidgetAppearances(d,{normal:l})}this.markAsClean()},e.prototype.setFontSize=function(r){assertPositive(r,"fontSize"),this.acroField.setFontSize(r),this.markAsDirty()},e.prototype.isMultiline=function(){return this.acroField.hasFlag(AcroTextFlags.Multiline)},e.prototype.enableMultiline=function(){this.markAsDirty(),this.acroField.setFlagTo(AcroTextFlags.Multiline,!0)},e.prototype.disableMultiline=function(){this.markAsDirty(),this.acroField.setFlagTo(AcroTextFlags.Multiline,!1)},e.prototype.isPassword=function(){return this.acroField.hasFlag(AcroTextFlags.Password)},e.prototype.enablePassword=function(){this.acroField.setFlagTo(AcroTextFlags.Password,!0)},e.prototype.disablePassword=function(){this.acroField.setFlagTo(AcroTextFlags.Password,!1)},e.prototype.isFileSelector=function(){return this.acroField.hasFlag(AcroTextFlags.FileSelect)},e.prototype.enableFileSelection=function(){this.acroField.setFlagTo(AcroTextFlags.FileSelect,!0)},e.prototype.disableFileSelection=function(){this.acroField.setFlagTo(AcroTextFlags.FileSelect,!1)},e.prototype.isSpellChecked=function(){return!this.acroField.hasFlag(AcroTextFlags.DoNotSpellCheck)},e.prototype.enableSpellChecking=function(){this.acroField.setFlagTo(AcroTextFlags.DoNotSpellCheck,!1)},e.prototype.disableSpellChecking=function(){this.acroField.setFlagTo(AcroTextFlags.DoNotSpellCheck,!0)},e.prototype.isScrollable=function(){return!this.acroField.hasFlag(AcroTextFlags.DoNotScroll)},e.prototype.enableScrolling=function(){this.acroField.setFlagTo(AcroTextFlags.DoNotScroll,!1)},e.prototype.disableScrolling=function(){this.acroField.setFlagTo(AcroTextFlags.DoNotScroll,!0)},e.prototype.isCombed=function(){return this.acroField.hasFlag(AcroTextFlags.Comb)&&!this.isMultiline()&&!this.isPassword()&&!this.isFileSelector()&&this.getMaxLength()!==void 0},e.prototype.enableCombing=function(){if(this.getMaxLength()===void 0){var r="PDFTextFields must have a max length in order to be combed";console.warn(r)}this.markAsDirty(),this.disableMultiline(),this.disablePassword(),this.disableFileSelection(),this.acroField.setFlagTo(AcroTextFlags.Comb,!0)},e.prototype.disableCombing=function(){this.markAsDirty(),this.acroField.setFlagTo(AcroTextFlags.Comb,!1)},e.prototype.isRichFormatted=function(){return this.acroField.hasFlag(AcroTextFlags.RichText)},e.prototype.enableRichFormatting=function(){this.acroField.setFlagTo(AcroTextFlags.RichText,!0)},e.prototype.disableRichFormatting=function(){this.acroField.setFlagTo(AcroTextFlags.RichText,!1)},e.prototype.addToPage=function(r,n){var a,s,o,h,d,l,u;assertIs(r,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(n),n||(n={}),"textColor"in n||(n.textColor=rgb(0,0,0)),"backgroundColor"in n||(n.backgroundColor=rgb(1,1,1)),"borderColor"in n||(n.borderColor=rgb(0,0,0)),"borderWidth"in n||(n.borderWidth=1);var p=this.createWidget({x:(a=n.x)!==null&&a!==void 0?a:0,y:(s=n.y)!==null&&s!==void 0?s:0,width:(o=n.width)!==null&&o!==void 0?o:200,height:(h=n.height)!==null&&h!==void 0?h:50,textColor:n.textColor,backgroundColor:n.backgroundColor,borderColor:n.borderColor,borderWidth:(d=n.borderWidth)!==null&&d!==void 0?d:0,rotate:(l=n.rotate)!==null&&l!==void 0?l:degrees(0),hidden:n.hidden,page:r.ref}),g=this.doc.context.register(p.dict);this.acroField.addWidget(g);var f=(u=n.font)!==null&&u!==void 0?u:this.doc.getForm().getDefaultFont();this.updateWidgetAppearance(p,f),r.node.addAnnot(g)},e.prototype.needsAppearancesUpdate=function(){var r;if(this.isDirty())return!0;for(var n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=((r=o.getAppearances())===null||r===void 0?void 0:r.normal)instanceof PDFStream;if(!h)return!0}return!1},e.prototype.defaultUpdateAppearances=function(r){assertIs(r,"font",[[PDFFont,"PDFFont"]]),this.updateAppearances(r)},e.prototype.updateAppearances=function(r,n){assertIs(r,"font",[[PDFFont,"PDFFont"]]),assertOrUndefined(n,"provider",[Function]);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s];this.updateWidgetAppearance(h,r,n)}this.markAsClean()},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultTextFieldAppearanceProvider,o=normalizeAppearance(s(this,r,n));this.updateWidgetAppearanceWithFont(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),StandardFonts;(function(t){t.Courier="Courier",t.CourierBold="Courier-Bold",t.CourierOblique="Courier-Oblique",t.CourierBoldOblique="Courier-BoldOblique",t.Helvetica="Helvetica",t.HelveticaBold="Helvetica-Bold",t.HelveticaOblique="Helvetica-Oblique",t.HelveticaBoldOblique="Helvetica-BoldOblique",t.TimesRoman="Times-Roman",t.TimesRomanBold="Times-Bold",t.TimesRomanItalic="Times-Italic",t.TimesRomanBoldItalic="Times-BoldItalic",t.Symbol="Symbol",t.ZapfDingbats="ZapfDingbats"})(StandardFonts||(StandardFonts={}));var PDFForm=function(){function t(e,r){var n=this;this.embedDefaultFont=function(){return n.doc.embedStandardFont(StandardFonts.Helvetica)},assertIs(e,"acroForm",[[PDFAcroForm,"PDFAcroForm"]]),assertIs(r,"doc",[[PDFDocument,"PDFDocument"]]),this.acroForm=e,this.doc=r,this.dirtyFields=new Set,this.defaultFontCache=Cache.populatedBy(this.embedDefaultFont)}return t.prototype.hasXFA=function(){return this.acroForm.dict.has(PDFName.of("XFA"))},t.prototype.deleteXFA=function(){this.acroForm.dict.delete(PDFName.of("XFA"))},t.prototype.getFields=function(){for(var e=this.acroForm.getAllFields(),r=[],n=0,a=e.length;n<a;n++){var s=e[n],o=s[0],h=s[1],d=convertToPDFField(o,h,this.doc);d&&r.push(d)}return r},t.prototype.getFieldMaybe=function(e){assertIs(e,"name",["string"]);for(var r=this.getFields(),n=0,a=r.length;n<a;n++){var s=r[n];if(s.getName()===e)return s}},t.prototype.getField=function(e){assertIs(e,"name",["string"]);var r=this.getFieldMaybe(e);if(r)return r;throw new NoSuchFieldError(e)},t.prototype.getButton=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFButton)return r;throw new UnexpectedFieldTypeError(e,PDFButton,r)},t.prototype.getCheckBox=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFCheckBox)return r;throw new UnexpectedFieldTypeError(e,PDFCheckBox,r)},t.prototype.getDropdown=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFDropdown)return r;throw new UnexpectedFieldTypeError(e,PDFDropdown,r)},t.prototype.getOptionList=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFOptionList)return r;throw new UnexpectedFieldTypeError(e,PDFOptionList,r)},t.prototype.getRadioGroup=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFRadioGroup)return r;throw new UnexpectedFieldTypeError(e,PDFRadioGroup,r)},t.prototype.getSignature=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFSignature)return r;throw new UnexpectedFieldTypeError(e,PDFSignature,r)},t.prototype.getTextField=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFTextField)return r;throw new UnexpectedFieldTypeError(e,PDFTextField,r)},t.prototype.createButton=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroPushButton.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFButton.of(a,a.ref,this.doc)},t.prototype.createCheckBox=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroCheckBox.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFCheckBox.of(a,a.ref,this.doc)},t.prototype.createDropdown=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroComboBox.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFDropdown.of(a,a.ref,this.doc)},t.prototype.createOptionList=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroListBox.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFOptionList.of(a,a.ref,this.doc)},t.prototype.createRadioGroup=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroRadioButton.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFRadioGroup.of(a,a.ref,this.doc)},t.prototype.createTextField=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroText.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFTextField.of(a,a.ref,this.doc)},t.prototype.flatten=function(e){e===void 0&&(e={updateFieldAppearances:!0}),e.updateFieldAppearances&&this.updateFieldAppearances();for(var r=this.getFields(),n=0,a=r.length;n<a;n++){for(var s=r[n],o=s.acroField.getWidgets(),h=0,d=o.length;h<d;h++){var l=o[h],u=this.findWidgetPage(l),p=this.findWidgetAppearanceRef(s,l),g=u.node.newXObject("FlatWidget",p),f=l.getRectangle(),v=__spreadArrays([pushGraphicsState(),translate(f.x,f.y)],rotateInPlace(__assign(__assign({},f),{rotation:0})),[drawObject(g),popGraphicsState()]).filter(Boolean);u.pushOperators.apply(u,v)}this.removeField(s)}},t.prototype.removeField=function(e){for(var r=e.acroField.getWidgets(),n=new Set,a=0,s=r.length;a<s;a++){var o=r[a],h=this.findWidgetAppearanceRef(e,o),d=this.findWidgetPage(o);n.add(d),d.node.removeAnnot(h)}n.forEach(function(f){return f.node.removeAnnot(e.ref)}),this.acroForm.removeField(e.acroField);for(var l=e.acroField.normalizedEntries().Kids,u=l.size(),p=0;p<u;p++){var g=l.get(p);g instanceof PDFRef&&this.doc.context.delete(g)}this.doc.context.delete(e.ref)},t.prototype.updateFieldAppearances=function(e){assertOrUndefined(e,"font",[[PDFFont,"PDFFont"]]),e=e??this.getDefaultFont();for(var r=this.getFields(),n=0,a=r.length;n<a;n++){var s=r[n];s.needsAppearancesUpdate()&&s.defaultUpdateAppearances(e)}},t.prototype.markFieldAsDirty=function(e){assertOrUndefined(e,"fieldRef",[[PDFRef,"PDFRef"]]),this.dirtyFields.add(e)},t.prototype.markFieldAsClean=function(e){assertOrUndefined(e,"fieldRef",[[PDFRef,"PDFRef"]]),this.dirtyFields.delete(e)},t.prototype.fieldIsDirty=function(e){return assertOrUndefined(e,"fieldRef",[[PDFRef,"PDFRef"]]),this.dirtyFields.has(e)},t.prototype.getDefaultFont=function(){return this.defaultFontCache.access()},t.prototype.findWidgetPage=function(e){var r=e.P(),n=this.doc.getPages().find(function(s){return s.ref===r});if(n===void 0){var a=this.doc.context.getObjectRef(e.dict);if(a===void 0)throw new Error("Could not find PDFRef for PDFObject");if(n=this.doc.findPageForAnnotationRef(a),n===void 0)throw new Error("Could not find page for PDFRef "+a)}return n},t.prototype.findWidgetAppearanceRef=function(e,r){var n,a=r.getNormalAppearance();if(a instanceof PDFDict&&(e instanceof PDFCheckBox||e instanceof PDFRadioGroup)){var s=e.acroField.getValue(),o=(n=a.get(s))!==null&&n!==void 0?n:a.get(PDFName.of("Off"));o instanceof PDFRef&&(a=o)}if(!(a instanceof PDFRef)){var h=e.getName();throw new Error("Failed to extract appearance ref for: "+h)}return a},t.prototype.findOrCreateNonTerminals=function(e){for(var r=[this.acroForm],n=0,a=e.length;n<a;n++){var s=e[n];if(!s)throw new InvalidFieldNamePartError(s);var o=r[0],h=r[1],d=this.findNonTerminal(s,o);if(d)r=d;else{var l=PDFAcroNonTerminal.create(this.doc.context);l.setPartialName(s),l.setParent(h);var u=this.doc.context.register(l.dict);o.addField(u),r=[l,u]}}return r},t.prototype.findNonTerminal=function(e,r){for(var n=r instanceof PDFAcroForm?this.acroForm.getFields():createPDFAcroFields(r.Kids()),a=0,s=n.length;a<s;a++){var o=n[a],h=o[0],d=o[1];if(h.getPartialName()===e){if(h instanceof PDFAcroNonTerminal)return[h,d];throw new FieldAlreadyExistsError(e)}}},t.of=function(e,r){return new t(e,r)},t}(),convertToPDFField=function(t,e,r){if(t instanceof PDFAcroPushButton)return PDFButton.of(t,e,r);if(t instanceof PDFAcroCheckBox)return PDFCheckBox.of(t,e,r);if(t instanceof PDFAcroComboBox)return PDFDropdown.of(t,e,r);if(t instanceof PDFAcroListBox)return PDFOptionList.of(t,e,r);if(t instanceof PDFAcroText)return PDFTextField.of(t,e,r);if(t instanceof PDFAcroRadioButton)return PDFRadioGroup.of(t,e,r);if(t instanceof PDFAcroSignature)return PDFSignature.of(t,e,r)},splitFieldName=function(t){if(t.length===0)throw new Error("PDF field names must not be empty strings");for(var e=t.split("."),r=0,n=e.length;r<n;r++)if(e[r]==="")throw new Error('Periods in PDF field names must be separated by at least one character: "'+t+'"');return e.length===1?{nonTerminal:[],terminal:e[0]}:{nonTerminal:e.slice(0,e.length-1),terminal:e[e.length-1]}},addFieldToParent=function(t,e,r){for(var n=t[0],a=t[1],s=e[0],o=e[1],h=n.normalizedEntries(),d=createPDFAcroFields("Kids"in h?h.Kids:h.Fields),l=0,u=d.length;l<u;l++)if(d[l][0].getPartialName()===r)throw new FieldAlreadyExistsError(r);n.addField(o),s.setParent(a)},PageSizes={A4:[595.28,841.89]},ParseSpeeds;(function(t){t[t.Fastest=1/0]="Fastest",t[t.Fast=1500]="Fast",t[t.Medium=500]="Medium",t[t.Slow=100]="Slow"})(ParseSpeeds||(ParseSpeeds={}));var PDFEmbeddedFile=function(){function t(e,r,n){this.alreadyEmbedded=!1,this.ref=e,this.doc=r,this.embedder=n}return t.prototype.embed=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n,a,s;return __generator(this,function(o){switch(o.label){case 0:return this.alreadyEmbedded?[3,2]:[4,this.embedder.embedIntoContext(this.doc.context,this.ref)];case 1:e=o.sent(),this.doc.catalog.has(PDFName.of("Names"))||this.doc.catalog.set(PDFName.of("Names"),this.doc.context.obj({})),r=this.doc.catalog.lookup(PDFName.of("Names"),PDFDict),r.has(PDFName.of("EmbeddedFiles"))||r.set(PDFName.of("EmbeddedFiles"),this.doc.context.obj({})),n=r.lookup(PDFName.of("EmbeddedFiles"),PDFDict),n.has(PDFName.of("Names"))||n.set(PDFName.of("Names"),this.doc.context.obj([])),a=n.lookup(PDFName.of("Names"),PDFArray),a.push(PDFHexString.fromText(this.embedder.fileName)),a.push(e),this.doc.catalog.has(PDFName.of("AF"))||this.doc.catalog.set(PDFName.of("AF"),this.doc.context.obj([])),s=this.doc.catalog.lookup(PDFName.of("AF"),PDFArray),s.push(e),this.alreadyEmbedded=!0,o.label=2;case 2:return[2]}})})},t.of=function(e,r,n){return new t(e,r,n)},t}(),PDFJavaScript=function(){function t(e,r,n){this.alreadyEmbedded=!1,this.ref=e,this.doc=r,this.embedder=n}return t.prototype.embed=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n,a,s,o,h;return __generator(this,function(d){switch(d.label){case 0:return this.alreadyEmbedded?[3,2]:(e=this.doc,r=e.catalog,n=e.context,[4,this.embedder.embedIntoContext(this.doc.context,this.ref)]);case 1:a=d.sent(),r.has(PDFName.of("Names"))||r.set(PDFName.of("Names"),n.obj({})),s=r.lookup(PDFName.of("Names"),PDFDict),s.has(PDFName.of("JavaScript"))||s.set(PDFName.of("JavaScript"),n.obj({})),o=s.lookup(PDFName.of("JavaScript"),PDFDict),o.has(PDFName.of("Names"))||o.set(PDFName.of("Names"),n.obj([])),h=o.lookup(PDFName.of("Names"),PDFArray),h.push(PDFHexString.fromText(this.embedder.scriptName)),h.push(a),this.alreadyEmbedded=!0,d.label=2;case 2:return[2]}})})},t.of=function(e,r,n){return new t(e,r,n)},t}(),JavaScriptEmbedder=function(){function t(e,r){this.script=e,this.scriptName=r}return t.for=function(e,r){return new t(e,r)},t.prototype.embedIntoContext=function(e,r){return __awaiter(this,void 0,void 0,function(){var n;return __generator(this,function(a){return n=e.obj({Type:"Action",S:"JavaScript",JS:PDFHexString.fromText(this.script)}),r?(e.assign(r,n),[2,r]):[2,e.register(n)]})})},t}(),PDFDocument=function(){function t(e,r,n){var a=this;if(this.defaultWordBreaks=[" "],this.computePages=function(){var s=[];return a.catalog.Pages().traverse(function(o,h){if(o instanceof PDFPageLeaf){var d=a.pageMap.get(o);d||(d=PDFPage.of(o,h,a),a.pageMap.set(o,d)),s.push(d)}}),s},this.getOrCreateForm=function(){var s=a.catalog.getOrCreateAcroForm();return PDFForm.of(s,a)},assertIs(e,"context",[[PDFContext,"PDFContext"]]),assertIs(r,"ignoreEncryption",["boolean"]),this.context=e,this.catalog=e.lookup(e.trailerInfo.Root),this.isEncrypted=!!e.lookup(e.trailerInfo.Encrypt),this.pageCache=Cache.populatedBy(this.computePages),this.pageMap=new Map,this.formCache=Cache.populatedBy(this.getOrCreateForm),this.fonts=[],this.images=[],this.embeddedPages=[],this.embeddedFiles=[],this.javaScripts=[],!r&&this.isEncrypted)throw new EncryptedPDFError;n&&this.updateInfoDict()}return t.load=function(e,r){return r===void 0&&(r={}),__awaiter(this,void 0,void 0,function(){var n,a,s,o,h,d,l,u,p,g,f,v;return __generator(this,function(y){switch(y.label){case 0:return n=r.ignoreEncryption,a=n===void 0?!1:n,s=r.parseSpeed,o=s===void 0?ParseSpeeds.Slow:s,h=r.throwOnInvalidObject,d=h===void 0?!1:h,l=r.updateMetadata,u=l===void 0?!0:l,p=r.capNumbers,g=p===void 0?!1:p,assertIs(e,"pdf",["string",Uint8Array,ArrayBuffer]),assertIs(a,"ignoreEncryption",["boolean"]),assertIs(o,"parseSpeed",["number"]),assertIs(d,"throwOnInvalidObject",["boolean"]),f=toUint8Array(e),[4,PDFParser.forBytesWithOptions(f,o,d,g).parseDocument()];case 1:return v=y.sent(),[2,new t(v,a,u)]}})})},t.create=function(e){return e===void 0&&(e={}),__awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h;return __generator(this,function(d){return r=e.updateMetadata,n=r===void 0?!0:r,a=PDFContext.create(),s=PDFPageTree.withContext(a),o=a.register(s),h=PDFCatalog.withContextAndPages(a,o),a.trailerInfo.Root=a.register(h),[2,new t(a,!1,n)]})})},t.prototype.registerFontkit=function(e){this.fontkit=e},t.prototype.getForm=function(){var e=this.formCache.access();return e.hasXFA()&&(console.warn("Removing XFA form data as pdf-lib does not support reading or writing XFA"),e.deleteXFA()),e},t.prototype.getTitle=function(){var e=this.getInfoDict().lookup(PDFName.Title);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getAuthor=function(){var e=this.getInfoDict().lookup(PDFName.Author);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getSubject=function(){var e=this.getInfoDict().lookup(PDFName.Subject);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getKeywords=function(){var e=this.getInfoDict().lookup(PDFName.Keywords);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getCreator=function(){var e=this.getInfoDict().lookup(PDFName.Creator);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getProducer=function(){var e=this.getInfoDict().lookup(PDFName.Producer);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getCreationDate=function(){var e=this.getInfoDict().lookup(PDFName.CreationDate);if(e)return assertIsLiteralOrHexString(e),e.decodeDate()},t.prototype.getModificationDate=function(){var e=this.getInfoDict().lookup(PDFName.ModDate);if(e)return assertIsLiteralOrHexString(e),e.decodeDate()},t.prototype.setTitle=function(e,r){assertIs(e,"title",["string"]);var n=PDFName.of("Title");if(this.getInfoDict().set(n,PDFHexString.fromText(e)),r!=null&&r.showInWindowTitleBar){var a=this.catalog.getOrCreateViewerPreferences();a.setDisplayDocTitle(!0)}},t.prototype.setAuthor=function(e){assertIs(e,"author",["string"]);var r=PDFName.of("Author");this.getInfoDict().set(r,PDFHexString.fromText(e))},t.prototype.setSubject=function(e){assertIs(e,"author",["string"]);var r=PDFName.of("Subject");this.getInfoDict().set(r,PDFHexString.fromText(e))},t.prototype.setKeywords=function(e){assertIs(e,"keywords",[Array]);var r=PDFName.of("Keywords");this.getInfoDict().set(r,PDFHexString.fromText(e.join(" ")))},t.prototype.setCreator=function(e){assertIs(e,"creator",["string"]);var r=PDFName.of("Creator");this.getInfoDict().set(r,PDFHexString.fromText(e))},t.prototype.setProducer=function(e){assertIs(e,"creator",["string"]);var r=PDFName.of("Producer");this.getInfoDict().set(r,PDFHexString.fromText(e))},t.prototype.setLanguage=function(e){assertIs(e,"language",["string"]);var r=PDFName.of("Lang");this.catalog.set(r,PDFString.of(e))},t.prototype.setCreationDate=function(e){assertIs(e,"creationDate",[[Date,"Date"]]);var r=PDFName.of("CreationDate");this.getInfoDict().set(r,PDFString.fromDate(e))},t.prototype.setModificationDate=function(e){assertIs(e,"modificationDate",[[Date,"Date"]]);var r=PDFName.of("ModDate");this.getInfoDict().set(r,PDFString.fromDate(e))},t.prototype.getPageCount=function(){return this.pageCount===void 0&&(this.pageCount=this.getPages().length),this.pageCount},t.prototype.getPages=function(){return this.pageCache.access()},t.prototype.getPage=function(e){var r=this.getPages();return assertRange(e,"index",0,r.length-1),r[e]},t.prototype.getPageIndices=function(){return range(0,this.getPageCount())},t.prototype.removePage=function(e){var r=this.getPageCount();if(this.pageCount===0)throw new RemovePageFromEmptyDocumentError;assertRange(e,"index",0,r-1),this.catalog.removeLeafNode(e),this.pageCount=r-1},t.prototype.addPage=function(e){return assertIs(e,"page",["undefined",[PDFPage,"PDFPage"],Array]),this.insertPage(this.getPageCount(),e)},t.prototype.insertPage=function(e,r){var n=this.getPageCount();if(assertRange(e,"index",0,n),assertIs(r,"page",["undefined",[PDFPage,"PDFPage"],Array]),!r||Array.isArray(r)){var a=Array.isArray(r)?r:PageSizes.A4;r=PDFPage.create(this),r.setSize.apply(r,a)}else if(r.doc!==this)throw new ForeignPageError;var s=this.catalog.insertLeafNode(r.ref,e);return r.node.setParent(s),this.pageMap.set(r.node,r),this.pageCache.invalidate(),this.pageCount=n+1,r},t.prototype.copyPages=function(e,r){return __awaiter(this,void 0,void 0,function(){var n,a,s,o,h,d,l,u;return __generator(this,function(p){switch(p.label){case 0:return assertIs(e,"srcDoc",[[t,"PDFDocument"]]),assertIs(r,"indices",[Array]),[4,e.flush()];case 1:for(p.sent(),n=PDFObjectCopier.for(e.context,this.context),a=e.getPages(),s=new Array(r.length),o=0,h=r.length;o<h;o++)d=a[r[o]],l=n.copy(d.node),u=this.context.register(l),s[o]=PDFPage.of(l,u,this);return[2,s]}})})},t.prototype.copy=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n,a;return __generator(this,function(s){switch(s.label){case 0:return[4,t.create()];case 1:return e=s.sent(),[4,e.copyPages(this,this.getPageIndices())];case 2:for(r=s.sent(),n=0,a=r.length;n<a;n++)e.addPage(r[n]);return this.getAuthor()!==void 0&&e.setAuthor(this.getAuthor()),this.getCreationDate()!==void 0&&e.setCreationDate(this.getCreationDate()),this.getCreator()!==void 0&&e.setCreator(this.getCreator()),this.getModificationDate()!==void 0&&e.setModificationDate(this.getModificationDate()),this.getProducer()!==void 0&&e.setProducer(this.getProducer()),this.getSubject()!==void 0&&e.setSubject(this.getSubject()),this.getTitle()!==void 0&&e.setTitle(this.getTitle()),e.defaultWordBreaks=this.defaultWordBreaks,[2,e]}})})},t.prototype.addJavaScript=function(e,r){assertIs(e,"name",["string"]),assertIs(r,"script",["string"]);var n=JavaScriptEmbedder.for(r,e),a=this.context.nextRef(),s=PDFJavaScript.of(a,this,n);this.javaScripts.push(s)},t.prototype.attach=function(e,r,n){return n===void 0&&(n={}),__awaiter(this,void 0,void 0,function(){var a,s,o,h;return __generator(this,function(d){return assertIs(e,"attachment",["string",Uint8Array,ArrayBuffer]),assertIs(r,"name",["string"]),assertOrUndefined(n.mimeType,"mimeType",["string"]),assertOrUndefined(n.description,"description",["string"]),assertOrUndefined(n.creationDate,"options.creationDate",[Date]),assertOrUndefined(n.modificationDate,"options.modificationDate",[Date]),assertIsOneOfOrUndefined(n.afRelationship,"options.afRelationship",AFRelationship),a=toUint8Array(e),s=FileEmbedder.for(a,r,n),o=this.context.nextRef(),h=PDFEmbeddedFile.of(o,this,s),this.embeddedFiles.push(h),[2]})})},t.prototype.embedFont=function(e,r){return r===void 0&&(r={}),__awaiter(this,void 0,void 0,function(){var n,a,s,o,h,d,l,u,p,g;return __generator(this,function(f){switch(f.label){case 0:return n=r.subset,a=n===void 0?!1:n,s=r.customName,o=r.features,assertIs(e,"font",["string",Uint8Array,ArrayBuffer]),assertIs(a,"subset",["boolean"]),isStandardFont(e)?(h=StandardFontEmbedder.for(e,s),[3,7]):[3,1];case 1:return canBeConvertedToUint8Array(e)?(d=toUint8Array(e),l=this.assertFontkit(),a?[4,CustomFontSubsetEmbedder.for(l,d,s,o)]:[3,3]):[3,6];case 2:return u=f.sent(),[3,5];case 3:return[4,CustomFontEmbedder.for(l,d,s,o)];case 4:u=f.sent(),f.label=5;case 5:return h=u,[3,7];case 6:throw new TypeError("`font` must be one of `StandardFonts | string | Uint8Array | ArrayBuffer`");case 7:return p=this.context.nextRef(),g=PDFFont.of(p,this,h),this.fonts.push(g),[2,g]}})})},t.prototype.embedStandardFont=function(e,r){if(assertIs(e,"font",["string"]),!isStandardFont(e))throw new TypeError("`font` must be one of type `StandardFonts`");var n=StandardFontEmbedder.for(e,r),a=this.context.nextRef(),s=PDFFont.of(a,this,n);return this.fonts.push(s),s},t.prototype.embedJpg=function(e){return __awaiter(this,void 0,void 0,function(){var r,n,a,s;return __generator(this,function(o){switch(o.label){case 0:return assertIs(e,"jpg",["string",Uint8Array,ArrayBuffer]),r=toUint8Array(e),[4,JpegEmbedder.for(r)];case 1:return n=o.sent(),a=this.context.nextRef(),s=PDFImage.of(a,this,n),this.images.push(s),[2,s]}})})},t.prototype.embedPng=function(e){return __awaiter(this,void 0,void 0,function(){var r,n,a,s;return __generator(this,function(o){switch(o.label){case 0:return assertIs(e,"png",["string",Uint8Array,ArrayBuffer]),r=toUint8Array(e),[4,PngEmbedder.for(r)];case 1:return n=o.sent(),a=this.context.nextRef(),s=PDFImage.of(a,this,n),this.images.push(s),[2,s]}})})},t.prototype.embedPdf=function(e,r){return r===void 0&&(r=[0]),__awaiter(this,void 0,void 0,function(){var n,a,s;return __generator(this,function(o){switch(o.label){case 0:return assertIs(e,"pdf",["string",Uint8Array,ArrayBuffer,[t,"PDFDocument"]]),assertIs(r,"indices",[Array]),e instanceof t?(a=e,[3,3]):[3,1];case 1:return[4,t.load(e)];case 2:a=o.sent(),o.label=3;case 3:return n=a,s=pluckIndices(n.getPages(),r),[2,this.embedPages(s)]}})})},t.prototype.embedPage=function(e,r,n){return __awaiter(this,void 0,void 0,function(){var a;return __generator(this,function(s){switch(s.label){case 0:return assertIs(e,"page",[[PDFPage,"PDFPage"]]),[4,this.embedPages([e],[r],[n])];case 1:return a=s.sent()[0],[2,a]}})})},t.prototype.embedPages=function(e,r,n){return r===void 0&&(r=[]),n===void 0&&(n=[]),__awaiter(this,void 0,void 0,function(){var l,u,a,s,o,h,d,l,u,p,g,f,v,y,x;return __generator(this,function(m){switch(m.label){case 0:if(e.length===0)return[2,[]];for(l=0,u=e.length-1;l<u;l++)if(a=e[l],s=e[l+1],a.node.context!==s.node.context)throw new PageEmbeddingMismatchedContextError;o=e[0].node.context,h=o===this.context?function(w){return w}:PDFObjectCopier.for(o,this.context).copy,d=new Array(e.length),l=0,u=e.length,m.label=1;case 1:return l<u?(p=h(e[l].node),g=r[l],f=n[l],[4,PDFPageEmbedder.for(p,g,f)]):[3,4];case 2:v=m.sent(),y=this.context.nextRef(),d[l]=PDFEmbeddedPage.of(y,this,v),m.label=3;case 3:return l++,[3,1];case 4:return(x=this.embeddedPages).push.apply(x,d),[2,d]}})})},t.prototype.flush=function(){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return[4,this.embedAll(this.fonts)];case 1:return e.sent(),[4,this.embedAll(this.images)];case 2:return e.sent(),[4,this.embedAll(this.embeddedPages)];case 3:return e.sent(),[4,this.embedAll(this.embeddedFiles)];case 4:return e.sent(),[4,this.embedAll(this.javaScripts)];case 5:return e.sent(),[2]}})})},t.prototype.save=function(e){return e===void 0&&(e={}),__awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h,d,l,u,p;return __generator(this,function(g){switch(g.label){case 0:return r=e.useObjectStreams,n=r===void 0?!0:r,a=e.addDefaultPage,s=a===void 0?!0:a,o=e.objectsPerTick,h=o===void 0?50:o,d=e.updateFieldAppearances,l=d===void 0?!0:d,assertIs(n,"useObjectStreams",["boolean"]),assertIs(s,"addDefaultPage",["boolean"]),assertIs(h,"objectsPerTick",["number"]),assertIs(l,"updateFieldAppearances",["boolean"]),s&&this.getPageCount()===0&&this.addPage(),l&&(u=this.formCache.getValue(),u&&u.updateFieldAppearances()),[4,this.flush()];case 1:return g.sent(),p=n?PDFStreamWriter:PDFWriter,[2,p.forContext(this.context,h).serializeToBuffer()]}})})},t.prototype.saveAsBase64=function(e){return e===void 0&&(e={}),__awaiter(this,void 0,void 0,function(){var r,n,a,s,o;return __generator(this,function(h){switch(h.label){case 0:return r=e.dataUri,n=r===void 0?!1:r,a=__rest(e,["dataUri"]),assertIs(n,"dataUri",["boolean"]),[4,this.save(a)];case 1:return s=h.sent(),o=encodeToBase64(s),[2,n?"data:application/pdf;base64,"+o:o]}})})},t.prototype.findPageForAnnotationRef=function(e){for(var r=this.getPages(),n=0,a=r.length;n<a;n++){var s=r[n],o=s.node.Annots();if((o==null?void 0:o.indexOf(e))!==void 0)return s}},t.prototype.embedAll=function(e){return __awaiter(this,void 0,void 0,function(){var r,n;return __generator(this,function(a){switch(a.label){case 0:r=0,n=e.length,a.label=1;case 1:return r<n?[4,e[r].embed()]:[3,4];case 2:a.sent(),a.label=3;case 3:return r++,[3,1];case 4:return[2]}})})},t.prototype.updateInfoDict=function(){var e="pdf-lib (https://github.com/Hopding/pdf-lib)",r=new Date,n=this.getInfoDict();this.setProducer(e),this.setModificationDate(r),n.get(PDFName.of("Creator"))||this.setCreator(e),n.get(PDFName.of("CreationDate"))||this.setCreationDate(r)},t.prototype.getInfoDict=function(){var e=this.context.lookup(this.context.trailerInfo.Info);if(e instanceof PDFDict)return e;var r=this.context.obj({});return this.context.trailerInfo.Info=this.context.register(r),r},t.prototype.assertFontkit=function(){if(!this.fontkit)throw new FontkitNotRegisteredError;return this.fontkit},t}();function assertIsLiteralOrHexString(t){if(!(t instanceof PDFHexString)&&!(t instanceof PDFString))throw new UnexpectedObjectTypeError([PDFHexString,PDFString],t)}var BlendMode;(function(t){t.Normal="Normal",t.Multiply="Multiply",t.Screen="Screen",t.Overlay="Overlay",t.Darken="Darken",t.Lighten="Lighten",t.ColorDodge="ColorDodge",t.ColorBurn="ColorBurn",t.HardLight="HardLight",t.SoftLight="SoftLight",t.Difference="Difference",t.Exclusion="Exclusion"})(BlendMode||(BlendMode={}));var PDFPage=function(){function t(e,r,n){this.fontSize=24,this.fontColor=rgb(0,0,0),this.lineHeight=24,this.x=0,this.y=0,assertIs(e,"leafNode",[[PDFPageLeaf,"PDFPageLeaf"]]),assertIs(r,"ref",[[PDFRef,"PDFRef"]]),assertIs(n,"doc",[[PDFDocument,"PDFDocument"]]),this.node=e,this.ref=r,this.doc=n}return t.prototype.setRotation=function(e){var r=toDegrees(e);assertMultiple(r,"degreesAngle",90),this.node.set(PDFName.of("Rotate"),this.doc.context.obj(r))},t.prototype.getRotation=function(){var e=this.node.Rotate();return degrees(e?e.asNumber():0)},t.prototype.setSize=function(e,r){assertIs(e,"width",["number"]),assertIs(r,"height",["number"]);var n=this.getMediaBox();this.setMediaBox(n.x,n.y,e,r);var a=this.getCropBox(),s=this.getBleedBox(),o=this.getTrimBox(),h=this.getArtBox(),d=this.node.CropBox(),l=this.node.BleedBox(),u=this.node.TrimBox(),p=this.node.ArtBox();d&&rectanglesAreEqual(a,n)&&this.setCropBox(n.x,n.y,e,r),l&&rectanglesAreEqual(s,n)&&this.setBleedBox(n.x,n.y,e,r),u&&rectanglesAreEqual(o,n)&&this.setTrimBox(n.x,n.y,e,r),p&&rectanglesAreEqual(h,n)&&this.setArtBox(n.x,n.y,e,r)},t.prototype.setWidth=function(e){assertIs(e,"width",["number"]),this.setSize(e,this.getSize().height)},t.prototype.setHeight=function(e){assertIs(e,"height",["number"]),this.setSize(this.getSize().width,e)},t.prototype.setMediaBox=function(e,r,n,a){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),assertIs(n,"width",["number"]),assertIs(a,"height",["number"]);var s=this.doc.context.obj([e,r,e+n,r+a]);this.node.set(PDFName.MediaBox,s)},t.prototype.setCropBox=function(e,r,n,a){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),assertIs(n,"width",["number"]),assertIs(a,"height",["number"]);var s=this.doc.context.obj([e,r,e+n,r+a]);this.node.set(PDFName.CropBox,s)},t.prototype.setBleedBox=function(e,r,n,a){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),assertIs(n,"width",["number"]),assertIs(a,"height",["number"]);var s=this.doc.context.obj([e,r,e+n,r+a]);this.node.set(PDFName.BleedBox,s)},t.prototype.setTrimBox=function(e,r,n,a){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),assertIs(n,"width",["number"]),assertIs(a,"height",["number"]);var s=this.doc.context.obj([e,r,e+n,r+a]);this.node.set(PDFName.TrimBox,s)},t.prototype.setArtBox=function(e,r,n,a){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),assertIs(n,"width",["number"]),assertIs(a,"height",["number"]);var s=this.doc.context.obj([e,r,e+n,r+a]);this.node.set(PDFName.ArtBox,s)},t.prototype.getSize=function(){var e=this.getMediaBox(),r=e.width,n=e.height;return{width:r,height:n}},t.prototype.getWidth=function(){return this.getSize().width},t.prototype.getHeight=function(){return this.getSize().height},t.prototype.getMediaBox=function(){var e=this.node.MediaBox();return e.asRectangle()},t.prototype.getCropBox=function(){var e,r=this.node.CropBox();return(e=r==null?void 0:r.asRectangle())!==null&&e!==void 0?e:this.getMediaBox()},t.prototype.getBleedBox=function(){var e,r=this.node.BleedBox();return(e=r==null?void 0:r.asRectangle())!==null&&e!==void 0?e:this.getCropBox()},t.prototype.getTrimBox=function(){var e,r=this.node.TrimBox();return(e=r==null?void 0:r.asRectangle())!==null&&e!==void 0?e:this.getCropBox()},t.prototype.getArtBox=function(){var e,r=this.node.ArtBox();return(e=r==null?void 0:r.asRectangle())!==null&&e!==void 0?e:this.getCropBox()},t.prototype.translateContent=function(e,r){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),this.node.normalize(),this.getContentStream();var n=this.createContentStream(pushGraphicsState(),translate(e,r)),a=this.doc.context.register(n),s=this.createContentStream(popGraphicsState()),o=this.doc.context.register(s);this.node.wrapContentStreams(a,o)},t.prototype.scale=function(e,r){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),this.setSize(this.getWidth()*e,this.getHeight()*r),this.scaleContent(e,r),this.scaleAnnotations(e,r)},t.prototype.scaleContent=function(e,r){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),this.node.normalize(),this.getContentStream();var n=this.createContentStream(pushGraphicsState(),scale(e,r)),a=this.doc.context.register(n),s=this.createContentStream(popGraphicsState()),o=this.doc.context.register(s);this.node.wrapContentStreams(a,o)},t.prototype.scaleAnnotations=function(e,r){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]);var n=this.node.Annots();if(n)for(var a=0;a<n.size();a++){var s=n.lookup(a);s instanceof PDFDict&&this.scaleAnnot(s,e,r)}},t.prototype.resetPosition=function(){this.getContentStream(!1),this.x=0,this.y=0},t.prototype.setFont=function(e){assertIs(e,"font",[[PDFFont,"PDFFont"]]),this.font=e,this.fontKey=this.node.newFontDictionary(this.font.name,this.font.ref)},t.prototype.setFontSize=function(e){assertIs(e,"fontSize",["number"]),this.fontSize=e},t.prototype.setFontColor=function(e){assertIs(e,"fontColor",[[Object,"Color"]]),this.fontColor=e},t.prototype.setLineHeight=function(e){assertIs(e,"lineHeight",["number"]),this.lineHeight=e},t.prototype.getPosition=function(){return{x:this.x,y:this.y}},t.prototype.getX=function(){return this.x},t.prototype.getY=function(){return this.y},t.prototype.moveTo=function(e,r){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),this.x=e,this.y=r},t.prototype.moveDown=function(e){assertIs(e,"yDecrease",["number"]),this.y-=e},t.prototype.moveUp=function(e){assertIs(e,"yIncrease",["number"]),this.y+=e},t.prototype.moveLeft=function(e){assertIs(e,"xDecrease",["number"]),this.x-=e},t.prototype.moveRight=function(e){assertIs(e,"xIncrease",["number"]),this.x+=e},t.prototype.pushOperators=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];assertEachIs(e,"operator",[[PDFOperator,"PDFOperator"]]);var n=this.getContentStream();n.push.apply(n,e)},t.prototype.drawText=function(e,r){var n,a,s,o,h,d,l;r===void 0&&(r={}),assertIs(e,"text",["string"]),assertOrUndefined(r.color,"options.color",[[Object,"Color"]]),assertRangeOrUndefined(r.opacity,"opacity.opacity",0,1),assertOrUndefined(r.font,"options.font",[[PDFFont,"PDFFont"]]),assertOrUndefined(r.size,"options.size",["number"]),assertOrUndefined(r.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(r.xSkew,"options.xSkew",[[Object,"Rotation"]]),assertOrUndefined(r.ySkew,"options.ySkew",[[Object,"Rotation"]]),assertOrUndefined(r.x,"options.x",["number"]),assertOrUndefined(r.y,"options.y",["number"]),assertOrUndefined(r.lineHeight,"options.lineHeight",["number"]),assertOrUndefined(r.maxWidth,"options.maxWidth",["number"]),assertOrUndefined(r.wordBreaks,"options.wordBreaks",[Array]),assertIsOneOfOrUndefined(r.blendMode,"options.blendMode",BlendMode);for(var u=this.setOrEmbedFont(r.font),p=u.oldFont,g=u.newFont,f=u.newFontKey,v=r.size||this.fontSize,y=r.wordBreaks||this.doc.defaultWordBreaks,x=function(A){return g.widthOfTextAtSize(A,v)},m=r.maxWidth===void 0?lineSplit(cleanText(e)):breakTextIntoLines(e,y,r.maxWidth,x),w=new Array(m.length),R=0,_=m.length;R<_;R++)w[R]=g.encodeText(m[R]);var S=this.maybeEmbedGraphicsState({opacity:r.opacity,blendMode:r.blendMode}),F=this.getContentStream();F.push.apply(F,drawLinesOfText(w,{color:(n=r.color)!==null&&n!==void 0?n:this.fontColor,font:f,size:v,rotate:(a=r.rotate)!==null&&a!==void 0?a:degrees(0),xSkew:(s=r.xSkew)!==null&&s!==void 0?s:degrees(0),ySkew:(o=r.ySkew)!==null&&o!==void 0?o:degrees(0),x:(h=r.x)!==null&&h!==void 0?h:this.x,y:(d=r.y)!==null&&d!==void 0?d:this.y,lineHeight:(l=r.lineHeight)!==null&&l!==void 0?l:this.lineHeight,graphicsState:S})),r.font&&(p?this.setFont(p):this.resetFont())},t.prototype.drawImage=function(e,r){var n,a,s,o,h,d,l;r===void 0&&(r={}),assertIs(e,"image",[[PDFImage,"PDFImage"]]),assertOrUndefined(r.x,"options.x",["number"]),assertOrUndefined(r.y,"options.y",["number"]),assertOrUndefined(r.width,"options.width",["number"]),assertOrUndefined(r.height,"options.height",["number"]),assertOrUndefined(r.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(r.xSkew,"options.xSkew",[[Object,"Rotation"]]),assertOrUndefined(r.ySkew,"options.ySkew",[[Object,"Rotation"]]),assertRangeOrUndefined(r.opacity,"opacity.opacity",0,1),assertIsOneOfOrUndefined(r.blendMode,"options.blendMode",BlendMode);var u=this.node.newXObject("Image",e.ref),p=this.maybeEmbedGraphicsState({opacity:r.opacity,blendMode:r.blendMode}),g=this.getContentStream();g.push.apply(g,drawImage(u,{x:(n=r.x)!==null&&n!==void 0?n:this.x,y:(a=r.y)!==null&&a!==void 0?a:this.y,width:(s=r.width)!==null&&s!==void 0?s:e.size().width,height:(o=r.height)!==null&&o!==void 0?o:e.size().height,rotate:(h=r.rotate)!==null&&h!==void 0?h:degrees(0),xSkew:(d=r.xSkew)!==null&&d!==void 0?d:degrees(0),ySkew:(l=r.ySkew)!==null&&l!==void 0?l:degrees(0),graphicsState:p}))},t.prototype.drawPage=function(e,r){var n,a,s,o,h;r===void 0&&(r={}),assertIs(e,"embeddedPage",[[PDFEmbeddedPage,"PDFEmbeddedPage"]]),assertOrUndefined(r.x,"options.x",["number"]),assertOrUndefined(r.y,"options.y",["number"]),assertOrUndefined(r.xScale,"options.xScale",["number"]),assertOrUndefined(r.yScale,"options.yScale",["number"]),assertOrUndefined(r.width,"options.width",["number"]),assertOrUndefined(r.height,"options.height",["number"]),assertOrUndefined(r.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(r.xSkew,"options.xSkew",[[Object,"Rotation"]]),assertOrUndefined(r.ySkew,"options.ySkew",[[Object,"Rotation"]]),assertRangeOrUndefined(r.opacity,"opacity.opacity",0,1),assertIsOneOfOrUndefined(r.blendMode,"options.blendMode",BlendMode);var d=this.node.newXObject("EmbeddedPdfPage",e.ref),l=this.maybeEmbedGraphicsState({opacity:r.opacity,blendMode:r.blendMode}),u=r.width!==void 0?r.width/e.width:r.xScale!==void 0?r.xScale:1,p=r.height!==void 0?r.height/e.height:r.yScale!==void 0?r.yScale:1,g=this.getContentStream();g.push.apply(g,drawPage(d,{x:(n=r.x)!==null&&n!==void 0?n:this.x,y:(a=r.y)!==null&&a!==void 0?a:this.y,xScale:u,yScale:p,rotate:(s=r.rotate)!==null&&s!==void 0?s:degrees(0),xSkew:(o=r.xSkew)!==null&&o!==void 0?o:degrees(0),ySkew:(h=r.ySkew)!==null&&h!==void 0?h:degrees(0),graphicsState:l}))},t.prototype.drawSvgPath=function(e,r){var n,a,s,o,h,d,l,u,p;r===void 0&&(r={}),assertIs(e,"path",["string"]),assertOrUndefined(r.x,"options.x",["number"]),assertOrUndefined(r.y,"options.y",["number"]),assertOrUndefined(r.scale,"options.scale",["number"]),assertOrUndefined(r.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(r.borderWidth,"options.borderWidth",["number"]),assertOrUndefined(r.color,"options.color",[[Object,"Color"]]),assertRangeOrUndefined(r.opacity,"opacity.opacity",0,1),assertOrUndefined(r.borderColor,"options.borderColor",[[Object,"Color"]]),assertOrUndefined(r.borderDashArray,"options.borderDashArray",[Array]),assertOrUndefined(r.borderDashPhase,"options.borderDashPhase",["number"]),assertIsOneOfOrUndefined(r.borderLineCap,"options.borderLineCap",LineCapStyle),assertRangeOrUndefined(r.borderOpacity,"options.borderOpacity",0,1),assertIsOneOfOrUndefined(r.blendMode,"options.blendMode",BlendMode);var g=this.maybeEmbedGraphicsState({opacity:r.opacity,borderOpacity:r.borderOpacity,blendMode:r.blendMode});!("color"in r)&&!("borderColor"in r)&&(r.borderColor=rgb(0,0,0));var f=this.getContentStream();f.push.apply(f,drawSvgPath(e,{x:(n=r.x)!==null&&n!==void 0?n:this.x,y:(a=r.y)!==null&&a!==void 0?a:this.y,scale:r.scale,rotate:(s=r.rotate)!==null&&s!==void 0?s:degrees(0),color:(o=r.color)!==null&&o!==void 0?o:void 0,borderColor:(h=r.borderColor)!==null&&h!==void 0?h:void 0,borderWidth:(d=r.borderWidth)!==null&&d!==void 0?d:0,borderDashArray:(l=r.borderDashArray)!==null&&l!==void 0?l:void 0,borderDashPhase:(u=r.borderDashPhase)!==null&&u!==void 0?u:void 0,borderLineCap:(p=r.borderLineCap)!==null&&p!==void 0?p:void 0,graphicsState:g}))},t.prototype.drawLine=function(e){var r,n,a,s,o;assertIs(e.start,"options.start",[[Object,"{ x: number, y: number }"]]),assertIs(e.end,"options.end",[[Object,"{ x: number, y: number }"]]),assertIs(e.start.x,"options.start.x",["number"]),assertIs(e.start.y,"options.start.y",["number"]),assertIs(e.end.x,"options.end.x",["number"]),assertIs(e.end.y,"options.end.y",["number"]),assertOrUndefined(e.thickness,"options.thickness",["number"]),assertOrUndefined(e.color,"options.color",[[Object,"Color"]]),assertOrUndefined(e.dashArray,"options.dashArray",[Array]),assertOrUndefined(e.dashPhase,"options.dashPhase",["number"]),assertIsOneOfOrUndefined(e.lineCap,"options.lineCap",LineCapStyle),assertRangeOrUndefined(e.opacity,"opacity.opacity",0,1),assertIsOneOfOrUndefined(e.blendMode,"options.blendMode",BlendMode);var h=this.maybeEmbedGraphicsState({borderOpacity:e.opacity,blendMode:e.blendMode});"color"in e||(e.color=rgb(0,0,0));var d=this.getContentStream();d.push.apply(d,drawLine({start:e.start,end:e.end,thickness:(r=e.thickness)!==null&&r!==void 0?r:1,color:(n=e.color)!==null&&n!==void 0?n:void 0,dashArray:(a=e.dashArray)!==null&&a!==void 0?a:void 0,dashPhase:(s=e.dashPhase)!==null&&s!==void 0?s:void 0,lineCap:(o=e.lineCap)!==null&&o!==void 0?o:void 0,graphicsState:h}))},t.prototype.drawRectangle=function(e){var r,n,a,s,o,h,d,l,u,p,g,f,v;e===void 0&&(e={}),assertOrUndefined(e.x,"options.x",["number"]),assertOrUndefined(e.y,"options.y",["number"]),assertOrUndefined(e.width,"options.width",["number"]),assertOrUndefined(e.height,"options.height",["number"]),assertOrUndefined(e.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(e.xSkew,"options.xSkew",[[Object,"Rotation"]]),assertOrUndefined(e.ySkew,"options.ySkew",[[Object,"Rotation"]]),assertOrUndefined(e.borderWidth,"options.borderWidth",["number"]),assertOrUndefined(e.color,"options.color",[[Object,"Color"]]),assertRangeOrUndefined(e.opacity,"opacity.opacity",0,1),assertOrUndefined(e.borderColor,"options.borderColor",[[Object,"Color"]]),assertOrUndefined(e.borderDashArray,"options.borderDashArray",[Array]),assertOrUndefined(e.borderDashPhase,"options.borderDashPhase",["number"]),assertIsOneOfOrUndefined(e.borderLineCap,"options.borderLineCap",LineCapStyle),assertRangeOrUndefined(e.borderOpacity,"options.borderOpacity",0,1),assertIsOneOfOrUndefined(e.blendMode,"options.blendMode",BlendMode);var y=this.maybeEmbedGraphicsState({opacity:e.opacity,borderOpacity:e.borderOpacity,blendMode:e.blendMode});!("color"in e)&&!("borderColor"in e)&&(e.color=rgb(0,0,0));var x=this.getContentStream();x.push.apply(x,drawRectangle({x:(r=e.x)!==null&&r!==void 0?r:this.x,y:(n=e.y)!==null&&n!==void 0?n:this.y,width:(a=e.width)!==null&&a!==void 0?a:150,height:(s=e.height)!==null&&s!==void 0?s:100,rotate:(o=e.rotate)!==null&&o!==void 0?o:degrees(0),xSkew:(h=e.xSkew)!==null&&h!==void 0?h:degrees(0),ySkew:(d=e.ySkew)!==null&&d!==void 0?d:degrees(0),borderWidth:(l=e.borderWidth)!==null&&l!==void 0?l:0,color:(u=e.color)!==null&&u!==void 0?u:void 0,borderColor:(p=e.borderColor)!==null&&p!==void 0?p:void 0,borderDashArray:(g=e.borderDashArray)!==null&&g!==void 0?g:void 0,borderDashPhase:(f=e.borderDashPhase)!==null&&f!==void 0?f:void 0,graphicsState:y,borderLineCap:(v=e.borderLineCap)!==null&&v!==void 0?v:void 0}))},t.prototype.drawSquare=function(e){e===void 0&&(e={});var r=e.size;assertOrUndefined(r,"size",["number"]),this.drawRectangle(__assign(__assign({},e),{width:r,height:r}))},t.prototype.drawEllipse=function(e){var r,n,a,s,o,h,d,l,u,p,g;e===void 0&&(e={}),assertOrUndefined(e.x,"options.x",["number"]),assertOrUndefined(e.y,"options.y",["number"]),assertOrUndefined(e.xScale,"options.xScale",["number"]),assertOrUndefined(e.yScale,"options.yScale",["number"]),assertOrUndefined(e.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(e.color,"options.color",[[Object,"Color"]]),assertRangeOrUndefined(e.opacity,"opacity.opacity",0,1),assertOrUndefined(e.borderColor,"options.borderColor",[[Object,"Color"]]),assertRangeOrUndefined(e.borderOpacity,"options.borderOpacity",0,1),assertOrUndefined(e.borderWidth,"options.borderWidth",["number"]),assertOrUndefined(e.borderDashArray,"options.borderDashArray",[Array]),assertOrUndefined(e.borderDashPhase,"options.borderDashPhase",["number"]),assertIsOneOfOrUndefined(e.borderLineCap,"options.borderLineCap",LineCapStyle),assertIsOneOfOrUndefined(e.blendMode,"options.blendMode",BlendMode);var f=this.maybeEmbedGraphicsState({opacity:e.opacity,borderOpacity:e.borderOpacity,blendMode:e.blendMode});!("color"in e)&&!("borderColor"in e)&&(e.color=rgb(0,0,0));var v=this.getContentStream();v.push.apply(v,drawEllipse({x:(r=e.x)!==null&&r!==void 0?r:this.x,y:(n=e.y)!==null&&n!==void 0?n:this.y,xScale:(a=e.xScale)!==null&&a!==void 0?a:100,yScale:(s=e.yScale)!==null&&s!==void 0?s:100,rotate:(o=e.rotate)!==null&&o!==void 0?o:void 0,color:(h=e.color)!==null&&h!==void 0?h:void 0,borderColor:(d=e.borderColor)!==null&&d!==void 0?d:void 0,borderWidth:(l=e.borderWidth)!==null&&l!==void 0?l:0,borderDashArray:(u=e.borderDashArray)!==null&&u!==void 0?u:void 0,borderDashPhase:(p=e.borderDashPhase)!==null&&p!==void 0?p:void 0,borderLineCap:(g=e.borderLineCap)!==null&&g!==void 0?g:void 0,graphicsState:f}))},t.prototype.drawCircle=function(e){e===void 0&&(e={});var r=e.size,n=r===void 0?100:r;assertOrUndefined(n,"size",["number"]),this.drawEllipse(__assign(__assign({},e),{xScale:n,yScale:n}))},t.prototype.setOrEmbedFont=function(e){var r=this.font,n=this.fontKey;e?this.setFont(e):this.getFont();var a=this.font,s=this.fontKey;return{oldFont:r,oldFontKey:n,newFont:a,newFontKey:s}},t.prototype.getFont=function(){if(!this.font||!this.fontKey){var e=this.doc.embedStandardFont(StandardFonts.Helvetica);this.setFont(e)}return[this.font,this.fontKey]},t.prototype.resetFont=function(){this.font=void 0,this.fontKey=void 0},t.prototype.getContentStream=function(e){return e===void 0&&(e=!0),e&&this.contentStream?this.contentStream:(this.contentStream=this.createContentStream(),this.contentStreamRef=this.doc.context.register(this.contentStream),this.node.addContentStream(this.contentStreamRef),this.contentStream)},t.prototype.createContentStream=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];var n=this.doc.context.obj({}),a=PDFContentStream.of(n,e);return a},t.prototype.maybeEmbedGraphicsState=function(e){var r=e.opacity,n=e.borderOpacity,a=e.blendMode;if(!(r===void 0&&n===void 0&&a===void 0)){var s=this.doc.context.obj({Type:"ExtGState",ca:r,CA:n,BM:a}),o=this.node.newExtGState("GS",s);return o}},t.prototype.scaleAnnot=function(e,r,n){for(var a=["RD","CL","Vertices","QuadPoints","L","Rect"],s=0,o=a.length;s<o;s++){var h=e.lookup(PDFName.of(a[s]));h instanceof PDFArray&&h.scalePDFNumbers(r,n)}var d=e.lookup(PDFName.of("InkList"));if(d instanceof PDFArray)for(var s=0,o=d.size();s<o;s++){var l=d.lookup(s);l instanceof PDFArray&&l.scalePDFNumbers(r,n)}},t.of=function(e,r,n){return new t(e,r,n)},t.create=function(e){assertIs(e,"doc",[[PDFDocument,"PDFDocument"]]);var r=PDFRef.of(-1),n=PDFPageLeaf.withContextAndParent(e.context,r),a=e.context.register(n);return new t(n,a,e)},t}(),PDFButton=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroButton",[[PDFAcroPushButton,"PDFAcroPushButton"]]),s.acroField=r,s}return e.prototype.setImage=function(r,n){n===void 0&&(n=ImageAlignment.Center);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s],d=this.createImageAppearanceStream(h,r,n);this.updateWidgetAppearances(h,{normal:d})}this.markAsClean()},e.prototype.setFontSize=function(r){assertPositive(r,"fontSize"),this.acroField.setFontSize(r),this.markAsDirty()},e.prototype.addToPage=function(r,n,a){var s,o,h,d,l,u,p,g,f,v,y;assertOrUndefined(r,"text",["string"]),assertOrUndefined(n,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(a);var x=this.createWidget({x:((s=a==null?void 0:a.x)!==null&&s!==void 0?s:0)-((o=a==null?void 0:a.borderWidth)!==null&&o!==void 0?o:0)/2,y:((h=a==null?void 0:a.y)!==null&&h!==void 0?h:0)-((d=a==null?void 0:a.borderWidth)!==null&&d!==void 0?d:0)/2,width:(l=a==null?void 0:a.width)!==null&&l!==void 0?l:100,height:(u=a==null?void 0:a.height)!==null&&u!==void 0?u:50,textColor:(p=a==null?void 0:a.textColor)!==null&&p!==void 0?p:rgb(0,0,0),backgroundColor:(g=a==null?void 0:a.backgroundColor)!==null&&g!==void 0?g:rgb(.75,.75,.75),borderColor:a==null?void 0:a.borderColor,borderWidth:(f=a==null?void 0:a.borderWidth)!==null&&f!==void 0?f:0,rotate:(v=a==null?void 0:a.rotate)!==null&&v!==void 0?v:degrees(0),caption:r,hidden:a==null?void 0:a.hidden,page:n.ref}),m=this.doc.context.register(x.dict);this.acroField.addWidget(m);var w=(y=a==null?void 0:a.font)!==null&&y!==void 0?y:this.doc.getForm().getDefaultFont();this.updateWidgetAppearance(x,w),n.node.addAnnot(m)},e.prototype.needsAppearancesUpdate=function(){var r;if(this.isDirty())return!0;for(var n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=((r=o.getAppearances())===null||r===void 0?void 0:r.normal)instanceof PDFStream;if(!h)return!0}return!1},e.prototype.defaultUpdateAppearances=function(r){assertIs(r,"font",[[PDFFont,"PDFFont"]]),this.updateAppearances(r)},e.prototype.updateAppearances=function(r,n){assertIs(r,"font",[[PDFFont,"PDFFont"]]),assertOrUndefined(n,"provider",[Function]);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s];this.updateWidgetAppearance(h,r,n)}},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultButtonAppearanceProvider,o=normalizeAppearance(s(this,r,n));this.updateWidgetAppearanceWithFont(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField);pdfExports.GlobalWorkerOptions.workerSrc="https://cdnjs.cloudflare.com/ajax/libs/pdf.js/3.11.174/pdf.worker.min.js";const ANNOTATION_METADATA_SUBJECT_PREFIX="PDF_ANNOTATOR_DATA::",safeGetAnnotationData=(t,e,r)=>{try{return JSON.stringify(e),{annotations:t,historyState:e,pageRotations:r}}catch(n){return console.warn("Full history state has circular references or is too large, using current state only",n),{annotations:t,historyState:{history:[t],index:0},pageRotations:r}}},PdfViewer=react.forwardRef(({fileUrl:t,fileName:e,readonly:r=!1,onAnnotationsChange:n,initialAnnotations:a,initialHistoryState:s,onSave:o,onPrint:h,onGetAnnotationData:d},l)=>{const[u,p]=react.useState(null),[g,f]=react.useState(0),[v,y]=react.useState(1),[x,m]=react.useState(1),[w,R]=react.useState("SELECT"),[_,S]=react.useState(DEFAULT_COLOR),[F,A]=react.useState(DEFAULT_STROKE_WIDTH),[D,T]=react.useState(DEFAULT_FONT_SIZE),[M,C]=react.useState(!1),[k,O]=react.useState(null),[$,K]=react.useState(null),[J,Y]=react.useState(null),[se,B]=react.useState(null),[V,Q]=react.useState("APPROVED"),[N,P]=react.useState({}),{annotations:E,addAnnotation:I,deleteAnnotation:z,updateAnnotation:G,clearAnnotations:H,undo:ee,redo:ce,canUndo:ve,canRedo:me,setAnnotations:xe,historyState:Se,setHistoryState:Ce}=useAnnotationHistory(),ne=react.useRef(null),le=react.useRef([]),[L,Z]=react.useState(!1),[re,he]=react.useState({x:0,y:0}),ye=react.useCallback((Ee,Ie)=>{P(ze=>{const ae=(((ze[Ee]||0)+(Ie==="cw"?90:-90))%360+360)%360;return{...ze,[Ee]:ae}})},[]);react.useEffect(()=>{if(!ne.current||g===0)return;const Ee=new IntersectionObserver(Ie=>{let ze=0,be=0;Ie.forEach(oe=>{const ae=Number(oe.target.getAttribute("data-page-number"));ae&&oe.intersectionRatio>be&&(ze=ae,be=oe.intersectionRatio)}),ze>0&&y(ze)},{root:ne.current,threshold:[0,.25,.5,.75,1]});return le.current.forEach(Ie=>{Ie&&Ee.observe(Ie)}),()=>Ee.disconnect()},[g]),react.useEffect(()=>{n&&n(E)},[E,n]);const Fe=react.useRef(!1);react.useEffect(()=>{s?(Ce(s),Fe.current=!0):a?(xe(a),Fe.current=!0):Fe.current=!1},[a,s,xe,Ce]),react.useEffect(()=>{(async()=>{try{const ze=await pdfExports.getDocument(t).promise;if(p(ze),f(ze.numPages),le.current=Array(ze.numPages).fill(null),y(1),!Fe.current){const be=await fetch(t).then(Re=>Re.arrayBuffer()),ae=(await PDFDocument.load(be)).getSubject();if(ae&&ae.startsWith(ANNOTATION_METADATA_SUBJECT_PREFIX))try{const Re=ae.substring(ANNOTATION_METADATA_SUBJECT_PREFIX.length),We=JSON.parse(Re);We.pageRotations&&P(We.pageRotations),Ce({history:We.history,index:We.index})}catch(Re){console.error("Failed to parse annotation metadata:",Re)}}}catch(Ie){console.error("Error loading PDF:",Ie)}})()},[t]);const Pe=Ee=>{if(Ee>0&&Ee<=g){y(Ee);const Ie=le.current[Ee-1];if(Ie&&ne.current){const ze=ne.current.scrollTop,be=ne.current.getBoundingClientRect(),ae=Ie.getBoundingClientRect().top-be.top+ze;ne.current.scrollTo({top:ae,behavior:"smooth"})}}},ie=react.useCallback(()=>{if(k)for(const Ee in E){const Ie=parseInt(Ee,10);if(E[Ie].some(ze=>ze.id===k)){z(Ie,k),O(null);break}}},[k,E,z]);react.useEffect(()=>{const Ee=Ie=>{(Ie.key==="Delete"||Ie.key==="Backspace")&&k&&(Ie.preventDefault(),ie()),(Ie.ctrlKey||Ie.metaKey)&&Ie.key==="z"&&(Ie.preventDefault(),ee()),(Ie.ctrlKey||Ie.metaKey)&&Ie.key==="y"&&(Ie.preventDefault(),ce())};return window.addEventListener("keydown",Ee),()=>window.removeEventListener("keydown",Ee)},[k,ie,ee,ce]);const _e=react.useCallback(async(Ee=!1)=>{if(!u)return null;const Ie=await fetch(t).then(We=>We.arrayBuffer()),ze=await PDFDocument.load(Ie);try{const We={...Se,pageRotations:N},Ve=JSON.stringify(We),X=ANNOTATION_METADATA_SUBJECT_PREFIX+Ve;if(X.length>32e3){const ke=JSON.stringify({history:[E],index:0,pageRotations:N});ze.setSubject(ANNOTATION_METADATA_SUBJECT_PREFIX+ke)}else ze.setSubject(X)}catch(We){console.error("Failed to serialize history state:",We);try{const X=JSON.stringify({history:[E],index:0,pageRotations:N});ze.setSubject(ANNOTATION_METADATA_SUBJECT_PREFIX+X)}catch(Ve){console.error("Failed to serialize even current annotations:",Ve)}}const be=ze.getPages();for(let We=1;We<=be.length;We++){const Ve=N[We]||0;if(Ve!==0){const X=be[We-1].getRotation().angle;be[We-1].setRotation(degrees((X+Ve)%360))}}if(!Ee)return await ze.save();console.log("Rendering annotations onto PDF");const oe=await ze.embedFont(StandardFonts.Helvetica),ae=await ze.embedFont(StandardFonts.HelveticaBold),Re={};for(const We in E){const Ve=parseInt(We,10);if(Ve<1||Ve>be.length)continue;const X=E[Ve],ge=be[Ve-1],{width:ke,height:Be}=ge.getSize(),Ne=(await u.getPage(Ve)).getViewport({scale:1}),U=ke/Ne.width,j=Be/Ne.height;for(const W of X){const fe=rgb(parseInt(W.color.slice(1,3),16)/255,parseInt(W.color.slice(3,5),16)/255,parseInt(W.color.slice(5,7),16)/255),pe=Ae=>Be-Ae*j;switch(W.type){case"PEN":if(W.points.length>1)for(let De=0;De<W.points.length-1;De++){const Ge=W.points[De],Oe=W.points[De+1];ge.drawLine({start:{x:Ge.x*U,y:pe(Ge.y)},end:{x:Oe.x*U,y:pe(Oe.y)},thickness:W.strokeWidth*U,color:fe,opacity:1})}break;case"UNDERLINE":case"STRIKETHROUGH":if(W.points.length>1)for(let De=0;De<W.points.length-1;De++){const Ge=W.points[De],Oe=W.points[De+1];ge.drawLine({start:{x:Ge.x*U,y:pe(Ge.y)},end:{x:Oe.x*U,y:pe(Oe.y)},thickness:W.strokeWidth*U,color:fe,opacity:1})}break;case"SQUIGGLY":if(W.points.length>1){let De=`M ${W.points[0].x*U} ${pe(W.points[0].y)}`;for(let Ge=1;Ge<W.points.length;Ge++){const Oe=W.points[Ge];De+=` Q ${(Oe.x-2.5)*U} ${pe(Oe.y+(Ge%2===0?-1:1)*2)}, ${Oe.x*U} ${pe(Oe.y)}`}ge.drawSvgPath(De,{borderColor:fe,borderWidth:W.strokeWidth})}break;case"HIGHLIGHTER":if(W.points.length>1)for(let De=0;De<W.points.length-1;De++){const Ge=W.points[De],Oe=W.points[De+1];ge.drawLine({start:{x:Ge.x*U,y:pe(Ge.y)},end:{x:Oe.x*U,y:pe(Oe.y)},thickness:W.strokeWidth*5*U,color:fe,opacity:.4})}break;case"RECTANGLE":ge.drawRectangle({x:W.x*U,y:pe(W.y+W.height),width:W.width*U,height:W.height*j,borderColor:fe,borderWidth:W.strokeWidth});break;case"CIRCLE":ge.drawEllipse({x:W.cx*U,y:pe(W.cy),xScale:W.rx*U,yScale:W.ry*j,borderColor:fe,borderWidth:W.strokeWidth});break;case"TEXT":W.content.split(`
|
|
61
|
-
`).forEach((De,Ge)=>{ge.drawText(De,{x:W.x*U,y:pe(W.y+W.fontSize+Ge*W.fontSize*1.2),size:W.fontSize*j,font:oe,color:fe})});break;case"STAMP":ge.drawRectangle({x:W.x*U,y:pe(W.y+W.height),width:W.width*U,height:W.height*j,borderColor:fe,borderWidth:2,borderOpacity:.8});const we=W.text,je=ae.widthOfTextAtSize(we,W.fontSize*j);if(ge.drawText(we,{x:(W.x+W.width/2)*U-je/2,y:pe(W.y+W.height*.35),font:ae,size:W.fontSize*j,color:fe,opacity:.8}),W.timestamp){const De=W.fontSize*.45*j,Ge=oe.widthOfTextAtSize(W.timestamp,De);ge.drawText(W.timestamp,{x:(W.x+W.width/2)*U-Ge/2,y:pe(W.y+W.height*.7),font:oe,size:De,color:fe,opacity:.7})}break;case"SIGNATURE":case"INITIALS":Re[W.imageData]||(Re[W.imageData]=await ze.embedPng(W.imageData));const Le=Re[W.imageData];ge.drawImage(Le,{x:W.x*U,y:pe(W.y+W.height),width:W.width*U,height:W.height*j});break}}}return await ze.save()},[u,t,E,Se,N]);react.useImperativeHandle(l,()=>({getAnnotatedDocument:async()=>{try{const Ee=await _e();return Ee?new Blob([Ee],{type:"application/pdf"}):null}catch(Ee){return console.error("Failed to generate annotated document:",Ee),null}},getAnnotatedDocumentUrl:async()=>{try{const Ee=await _e();if(!Ee)return null;const Ie=new Blob([Ee],{type:"application/pdf"});return URL.createObjectURL(Ie)}catch(Ee){return console.error("Failed to generate annotated document URL:",Ee),null}},getAnnotationData:()=>{const Ee=safeGetAnnotationData(E,Se,N);return d&&d(Ee),Ee}}),[_e,E,Se,N,d]);const Te=react.useCallback(async Ee=>{C(!0);try{const ze=await _e(Ee==="print");if(!ze){C(!1);return}const be=safeGetAnnotationData(E,Se,N),oe=new Blob([ze],{type:"application/pdf"}),ae=URL.createObjectURL(oe);if(Ee==="download"){o&&o(be);const Re=document.createElement("a");Re.href=ae,Re.download=`${e.replace(".pdf","")}-annotated.pdf`,document.body.appendChild(Re),Re.click(),document.body.removeChild(Re),URL.revokeObjectURL(ae)}else{h&&h(be);const Re=document.createElement("iframe");Re.style.display="none",Re.src=ae,document.body.appendChild(Re),Re.onload=()=>{setTimeout(()=>{var We,Ve;try{(We=Re.contentWindow)==null||We.focus(),(Ve=Re.contentWindow)==null||Ve.print()}catch(X){console.error("Printing failed:",X),alert("Could not print the document. Your browser might be blocking it.")}setTimeout(()=>{document.body.contains(Re)&&(document.body.removeChild(Re),URL.revokeObjectURL(ae))},1e3)},1)}}}catch(Ie){console.error(`Failed to ${Ee} annotated PDF:`,Ie)}finally{C(!1)}},[_e,e,E,Se,N,o,h]),Ke=Ee=>{w==="PAN"&&ne.current&&(Z(!0),he({x:Ee.clientX+ne.current.scrollLeft,y:Ee.clientY+ne.current.scrollTop}),ne.current&&(ne.current.style.cursor="grabbing"))},qe=Ee=>{if(L&&ne.current&&w==="PAN"){const Ie=re.x-Ee.clientX,ze=re.y-Ee.clientY;ne.current.scrollLeft=Ie,ne.current.scrollTop=ze}},Ye=()=>{L&&(Z(!1),ne.current&&(ne.current.style.cursor="grab"))},Me=()=>{if(!u)return null;const Ee=[];for(let Ie=1;Ie<=g;Ie++)Ee.push(jsxRuntime.jsx("div",{ref:ze=>{le.current[Ie-1]=ze},"data-page-number":Ie,className:"mb-4",children:jsxRuntime.jsx(PdfPage,{pdf:u,pageNumber:Ie,zoom:
|
|
57
|
+
end`},cmapHexFormat=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return"<"+t.join("")+">"},cmapHexString=function(t){return toHexStringOfMinLength(t,4)},cmapCodePointFormat=function(t){if(isWithinBMP(t))return cmapHexString(t);if(hasSurrogates(t)){var e=highSurrogate(t),r=lowSurrogate(t);return""+cmapHexString(e)+cmapHexString(r)}var n=toHexString(t),a="0x"+n+" is not a valid UTF-8 or UTF-16 codepoint.";throw new Error(a)},makeFontFlags=function(t){var e=0,r=function(n){e|=1<<n-1};return t.fixedPitch&&r(1),t.serif&&r(2),r(3),t.script&&r(4),t.nonsymbolic&&r(6),t.italic&&r(7),t.allCap&&r(17),t.smallCap&&r(18),t.forceBold&&r(19),e},deriveFontFlags=function(t){var e=t["OS/2"]?t["OS/2"].sFamilyClass:0,r=makeFontFlags({fixedPitch:t.post.isFixedPitch,serif:1<=e&&e<=7,script:e===10,italic:t.head.macStyle.italic});return r},PDFString=function(t){__extends(e,t);function e(r){var n=t.call(this)||this;return n.value=r,n}return e.prototype.asBytes=function(){for(var r=[],n="",a=!1,s=function(p){p!==void 0&&r.push(p),a=!1},o=0,h=this.value.length;o<h;o++){var d=this.value[o],l=toCharCode(d),u=this.value[o+1];a?l===CharCodes.Newline||l===CharCodes.CarriageReturn?s():l===CharCodes.n?s(CharCodes.Newline):l===CharCodes.r?s(CharCodes.CarriageReturn):l===CharCodes.t?s(CharCodes.Tab):l===CharCodes.b?s(CharCodes.Backspace):l===CharCodes.f?s(CharCodes.FormFeed):l===CharCodes.LeftParen?s(CharCodes.LeftParen):l===CharCodes.RightParen?s(CharCodes.RightParen):l===CharCodes.Backspace?s(CharCodes.BackSlash):l>=CharCodes.Zero&&l<=CharCodes.Seven?(n+=d,(n.length===3||!(u>="0"&&u<="7"))&&(s(parseInt(n,8)),n="")):s(l):l===CharCodes.BackSlash?a=!0:s(l)}return new Uint8Array(r)},e.prototype.decodeText=function(){var r=this.asBytes();return hasUtf16BOM(r)?utf16Decode(r):pdfDocEncodingDecode(r)},e.prototype.decodeDate=function(){var r=this.decodeText(),n=parseDate(r);if(!n)throw new InvalidPDFDateStringError(r);return n},e.prototype.asString=function(){return this.value},e.prototype.clone=function(){return e.of(this.value)},e.prototype.toString=function(){return"("+this.value+")"},e.prototype.sizeInBytes=function(){return this.value.length+2},e.prototype.copyBytesInto=function(r,n){return r[n++]=CharCodes.LeftParen,n+=copyStringIntoBuffer(this.value,r,n),r[n++]=CharCodes.RightParen,this.value.length+2},e.of=function(r){return new e(r)},e.fromDate=function(r){var n=padStart$1(String(r.getUTCFullYear()),4,"0"),a=padStart$1(String(r.getUTCMonth()+1),2,"0"),s=padStart$1(String(r.getUTCDate()),2,"0"),o=padStart$1(String(r.getUTCHours()),2,"0"),h=padStart$1(String(r.getUTCMinutes()),2,"0"),d=padStart$1(String(r.getUTCSeconds()),2,"0");return new e("D:"+n+a+s+o+h+d+"Z")},e}(PDFObject),CustomFontEmbedder=function(){function t(e,r,n,a){var s=this;this.allGlyphsInFontSortedById=function(){for(var o=new Array(s.font.characterSet.length),h=0,d=o.length;h<d;h++){var l=s.font.characterSet[h];o[h]=s.font.glyphForCodePoint(l)}return sortedUniq(o.sort(byAscendingId),function(u){return u.id})},this.font=e,this.scale=1e3/this.font.unitsPerEm,this.fontData=r,this.fontName=this.font.postscriptName||"Font",this.customName=n,this.fontFeatures=a,this.baseFontName="",this.glyphCache=Cache.populatedBy(this.allGlyphsInFontSortedById)}return t.for=function(e,r,n,a){return __awaiter(this,void 0,void 0,function(){var s;return __generator(this,function(o){switch(o.label){case 0:return[4,e.create(r)];case 1:return s=o.sent(),[2,new t(s,r,n,a)]}})})},t.prototype.encodeText=function(e){for(var r=this.font.layout(e,this.fontFeatures).glyphs,n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]=toHexStringOfMinLength(r[a].id,4);return PDFHexString.of(n.join(""))},t.prototype.widthOfTextAtSize=function(e,r){for(var n=this.font.layout(e,this.fontFeatures).glyphs,a=0,s=0,o=n.length;s<o;s++)a+=n[s].advanceWidth*this.scale;var h=r/1e3;return a*h},t.prototype.heightOfFontAtSize=function(e,r){r===void 0&&(r={});var n=r.descender,a=n===void 0?!0:n,s=this.font,o=s.ascent,h=s.descent,d=s.bbox,l=(o||d.maxY)*this.scale,u=(h||d.minY)*this.scale,p=l-u;return a||(p-=Math.abs(h)||0),p/1e3*e},t.prototype.sizeOfFontAtHeight=function(e){var r=this.font,n=r.ascent,a=r.descent,s=r.bbox,o=(n||s.maxY)*this.scale,h=(a||s.minY)*this.scale;return 1e3*e/(o-h)},t.prototype.embedIntoContext=function(e,r){return this.baseFontName=this.customName||e.addRandomSuffix(this.fontName),this.embedFontDict(e,r)},t.prototype.embedFontDict=function(e,r){return __awaiter(this,void 0,void 0,function(){var n,a,s;return __generator(this,function(o){switch(o.label){case 0:return[4,this.embedCIDFontDict(e)];case 1:return n=o.sent(),a=this.embedUnicodeCmap(e),s=e.obj({Type:"Font",Subtype:"Type0",BaseFont:this.baseFontName,Encoding:"Identity-H",DescendantFonts:[n],ToUnicode:a}),r?(e.assign(r,s),[2,r]):[2,e.register(s)]}})})},t.prototype.isCFF=function(){return this.font.cff},t.prototype.embedCIDFontDict=function(e){return __awaiter(this,void 0,void 0,function(){var r,n;return __generator(this,function(a){switch(a.label){case 0:return[4,this.embedFontDescriptor(e)];case 1:return r=a.sent(),n=e.obj({Type:"Font",Subtype:this.isCFF()?"CIDFontType0":"CIDFontType2",CIDToGIDMap:"Identity",BaseFont:this.baseFontName,CIDSystemInfo:{Registry:PDFString.of("Adobe"),Ordering:PDFString.of("Identity"),Supplement:0},FontDescriptor:r,W:this.computeWidths()}),[2,e.register(n)]}})})},t.prototype.embedFontDescriptor=function(e){return __awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h,d,l,u,p,g,f,v,y,S;return __generator(this,function(m){switch(m.label){case 0:return[4,this.embedFontStream(e)];case 1:return r=m.sent(),n=this.scale,a=this.font,s=a.italicAngle,o=a.ascent,h=a.descent,d=a.capHeight,l=a.xHeight,u=this.font.bbox,p=u.minX,g=u.minY,f=u.maxX,v=u.maxY,y=e.obj((S={Type:"FontDescriptor",FontName:this.baseFontName,Flags:deriveFontFlags(this.font),FontBBox:[p*n,g*n,f*n,v*n],ItalicAngle:s,Ascent:o*n,Descent:h*n,CapHeight:(d||o)*n,XHeight:(l||0)*n,StemV:0},S[this.isCFF()?"FontFile3":"FontFile2"]=r,S)),[2,e.register(y)]}})})},t.prototype.serializeFont=function(){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){return[2,this.fontData]})})},t.prototype.embedFontStream=function(e){return __awaiter(this,void 0,void 0,function(){var r,n,a;return __generator(this,function(s){switch(s.label){case 0:return a=(n=e).flateStream,[4,this.serializeFont()];case 1:return r=a.apply(n,[s.sent(),{Subtype:this.isCFF()?"CIDFontType0C":void 0}]),[2,e.register(r)]}})})},t.prototype.embedUnicodeCmap=function(e){var r=createCmap(this.glyphCache.access(),this.glyphId.bind(this)),n=e.flateStream(r);return e.register(n)},t.prototype.glyphId=function(e){return e?e.id:-1},t.prototype.computeWidths=function(){for(var e=this.glyphCache.access(),r=[],n=[],a=0,s=e.length;a<s;a++){var o=e[a],h=e[a-1],d=this.glyphId(o),l=this.glyphId(h);a===0?r.push(d):d-l!==1&&(r.push(n),r.push(d),n=[]),n.push(o.advanceWidth*this.scale)}return r.push(n),r},t}(),CustomFontSubsetEmbedder=function(t){__extends(e,t);function e(r,n,a,s){var o=t.call(this,r,n,a,s)||this;return o.subset=o.font.createSubset(),o.glyphs=[],o.glyphCache=Cache.populatedBy(function(){return o.glyphs}),o.glyphIdMap=new Map,o}return e.for=function(r,n,a,s){return __awaiter(this,void 0,void 0,function(){var o;return __generator(this,function(h){switch(h.label){case 0:return[4,r.create(n)];case 1:return o=h.sent(),[2,new e(o,n,a,s)]}})})},e.prototype.encodeText=function(r){for(var n=this.font.layout(r,this.fontFeatures).glyphs,a=new Array(n.length),s=0,o=n.length;s<o;s++){var h=n[s],d=this.subset.includeGlyph(h);this.glyphs[d-1]=h,this.glyphIdMap.set(h.id,d),a[s]=toHexStringOfMinLength(d,4)}return this.glyphCache.invalidate(),PDFHexString.of(a.join(""))},e.prototype.isCFF=function(){return this.subset.cff},e.prototype.glyphId=function(r){return r?this.glyphIdMap.get(r.id):-1},e.prototype.serializeFont=function(){var r=this;return new Promise(function(n,a){var s=[];r.subset.encodeStream().on("data",function(o){return s.push(o)}).on("end",function(){return n(mergeUint8Arrays(s))}).on("error",function(o){return a(o)})})},e}(CustomFontEmbedder),AFRelationship;(function(t){t.Source="Source",t.Data="Data",t.Alternative="Alternative",t.Supplement="Supplement",t.EncryptedPayload="EncryptedPayload",t.FormData="EncryptedPayload",t.Schema="Schema",t.Unspecified="Unspecified"})(AFRelationship||(AFRelationship={}));var FileEmbedder=function(){function t(e,r,n){n===void 0&&(n={}),this.fileData=e,this.fileName=r,this.options=n}return t.for=function(e,r,n){return n===void 0&&(n={}),new t(e,r,n)},t.prototype.embedIntoContext=function(e,r){return __awaiter(this,void 0,void 0,function(){var n,a,s,o,h,d,l,u,p;return __generator(this,function(g){return n=this.options,a=n.mimeType,s=n.description,o=n.creationDate,h=n.modificationDate,d=n.afRelationship,l=e.flateStream(this.fileData,{Type:"EmbeddedFile",Subtype:a??void 0,Params:{Size:this.fileData.length,CreationDate:o?PDFString.fromDate(o):void 0,ModDate:h?PDFString.fromDate(h):void 0}}),u=e.register(l),p=e.obj({Type:"Filespec",F:PDFString.of(this.fileName),UF:PDFHexString.fromText(this.fileName),EF:{F:u},Desc:s?PDFHexString.fromText(s):void 0,AFRelationship:d??void 0}),r?(e.assign(r,p),[2,r]):[2,e.register(p)]})})},t}(),MARKERS=[65472,65473,65474,65475,65477,65478,65479,65480,65481,65482,65483,65484,65485,65486,65487],ColorSpace;(function(t){t.DeviceGray="DeviceGray",t.DeviceRGB="DeviceRGB",t.DeviceCMYK="DeviceCMYK"})(ColorSpace||(ColorSpace={}));var ChannelToColorSpace={1:ColorSpace.DeviceGray,3:ColorSpace.DeviceRGB,4:ColorSpace.DeviceCMYK},JpegEmbedder=function(){function t(e,r,n,a,s){this.imageData=e,this.bitsPerComponent=r,this.width=n,this.height=a,this.colorSpace=s}return t.for=function(e){return __awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h,d,l,u,p;return __generator(this,function(g){if(r=new DataView(e.buffer),n=r.getUint16(0),n!==65496)throw new Error("SOI not found in JPEG");for(a=2;a<r.byteLength&&(s=r.getUint16(a),a+=2,!MARKERS.includes(s));)a+=r.getUint16(a);if(!MARKERS.includes(s))throw new Error("Invalid JPEG");if(a+=2,o=r.getUint8(a++),h=r.getUint16(a),a+=2,d=r.getUint16(a),a+=2,l=r.getUint8(a++),u=ChannelToColorSpace[l],!u)throw new Error("Unknown JPEG channel.");return p=u,[2,new t(e,o,d,h,p)]})})},t.prototype.embedIntoContext=function(e,r){return __awaiter(this,void 0,void 0,function(){var n;return __generator(this,function(a){return n=e.stream(this.imageData,{Type:"XObject",Subtype:"Image",BitsPerComponent:this.bitsPerComponent,Width:this.width,Height:this.height,ColorSpace:this.colorSpace,Filter:"DCTDecode",Decode:this.colorSpace===ColorSpace.DeviceCMYK?[1,0,1,0,1,0,1,0]:void 0}),r?(e.assign(r,n),[2,r]):[2,e.register(n)]})})},t}(),UPNG={};UPNG.toRGBA8=function(t){var e=t.width,r=t.height;if(t.tabs.acTL==null)return[UPNG.toRGBA8.decodeImage(t.data,e,r,t).buffer];var n=[];t.frames[0].data==null&&(t.frames[0].data=t.data);for(var a=e*r*4,s=new Uint8Array(a),o=new Uint8Array(a),h=new Uint8Array(a),d=0;d<t.frames.length;d++){var l=t.frames[d],u=l.rect.x,p=l.rect.y,g=l.rect.width,f=l.rect.height,v=UPNG.toRGBA8.decodeImage(l.data,g,f,t);if(d!=0)for(var y=0;y<a;y++)h[y]=s[y];if(l.blend==0?UPNG._copyTile(v,g,f,s,e,r,u,p,0):l.blend==1&&UPNG._copyTile(v,g,f,s,e,r,u,p,1),n.push(s.buffer.slice(0)),l.dispose!=0){if(l.dispose==1)UPNG._copyTile(o,g,f,s,e,r,u,p,0);else if(l.dispose==2)for(var y=0;y<a;y++)s[y]=h[y]}}return n},UPNG.toRGBA8.decodeImage=function(t,e,r,n){var a=e*r,s=UPNG.decode._getBPP(n),o=Math.ceil(e*s/8),h=new Uint8Array(a*4),d=new Uint32Array(h.buffer),l=n.ctype,u=n.depth,p=UPNG._bin.readUshort;if(l==6){var g=a<<2;if(u==8)for(var f=0;f<g;f+=4)h[f]=t[f],h[f+1]=t[f+1],h[f+2]=t[f+2],h[f+3]=t[f+3];if(u==16)for(var f=0;f<g;f++)h[f]=t[f<<1]}else if(l==2){var v=n.tabs.tRNS;if(v==null){if(u==8)for(var f=0;f<a;f++){var y=f*3;d[f]=255<<24|t[y+2]<<16|t[y+1]<<8|t[y]}if(u==16)for(var f=0;f<a;f++){var y=f*6;d[f]=255<<24|t[y+4]<<16|t[y+2]<<8|t[y]}}else{var S=v[0],m=v[1],w=v[2];if(u==8)for(var f=0;f<a;f++){var R=f<<2,y=f*3;d[f]=255<<24|t[y+2]<<16|t[y+1]<<8|t[y],t[y]==S&&t[y+1]==m&&t[y+2]==w&&(h[R+3]=0)}if(u==16)for(var f=0;f<a;f++){var R=f<<2,y=f*6;d[f]=255<<24|t[y+4]<<16|t[y+2]<<8|t[y],p(t,y)==S&&p(t,y+2)==m&&p(t,y+4)==w&&(h[R+3]=0)}}}else if(l==3){var _=n.tabs.PLTE,x=n.tabs.tRNS,F=x?x.length:0;if(u==1)for(var A=0;A<r;A++)for(var D=A*o,T=A*e,f=0;f<e;f++){var R=T+f<<2,M=t[D+(f>>3)]>>7-((f&7)<<0)&1,C=3*M;h[R]=_[C],h[R+1]=_[C+1],h[R+2]=_[C+2],h[R+3]=M<F?x[M]:255}if(u==2)for(var A=0;A<r;A++)for(var D=A*o,T=A*e,f=0;f<e;f++){var R=T+f<<2,M=t[D+(f>>2)]>>6-((f&3)<<1)&3,C=3*M;h[R]=_[C],h[R+1]=_[C+1],h[R+2]=_[C+2],h[R+3]=M<F?x[M]:255}if(u==4)for(var A=0;A<r;A++)for(var D=A*o,T=A*e,f=0;f<e;f++){var R=T+f<<2,M=t[D+(f>>1)]>>4-((f&1)<<2)&15,C=3*M;h[R]=_[C],h[R+1]=_[C+1],h[R+2]=_[C+2],h[R+3]=M<F?x[M]:255}if(u==8)for(var f=0;f<a;f++){var R=f<<2,M=t[f],C=3*M;h[R]=_[C],h[R+1]=_[C+1],h[R+2]=_[C+2],h[R+3]=M<F?x[M]:255}}else if(l==4){if(u==8)for(var f=0;f<a;f++){var R=f<<2,k=f<<1,O=t[k];h[R]=O,h[R+1]=O,h[R+2]=O,h[R+3]=t[k+1]}if(u==16)for(var f=0;f<a;f++){var R=f<<2,k=f<<2,O=t[k];h[R]=O,h[R+1]=O,h[R+2]=O,h[R+3]=t[k+2]}}else if(l==0)for(var S=n.tabs.tRNS?n.tabs.tRNS:-1,A=0;A<r;A++){var $=A*o,K=A*e;if(u==1)for(var J=0;J<e;J++){var O=255*(t[$+(J>>>3)]>>>7-(J&7)&1),Y=O==S*255?0:255;d[K+J]=Y<<24|O<<16|O<<8|O}else if(u==2)for(var J=0;J<e;J++){var O=85*(t[$+(J>>>2)]>>>6-((J&3)<<1)&3),Y=O==S*85?0:255;d[K+J]=Y<<24|O<<16|O<<8|O}else if(u==4)for(var J=0;J<e;J++){var O=17*(t[$+(J>>>1)]>>>4-((J&1)<<2)&15),Y=O==S*17?0:255;d[K+J]=Y<<24|O<<16|O<<8|O}else if(u==8)for(var J=0;J<e;J++){var O=t[$+J],Y=O==S?0:255;d[K+J]=Y<<24|O<<16|O<<8|O}else if(u==16)for(var J=0;J<e;J++){var O=t[$+(J<<1)],Y=p(t,$+(J<<f))==S?0:255;d[K+J]=Y<<24|O<<16|O<<8|O}}return h},UPNG.decode=function(t){for(var e=new Uint8Array(t),r=8,n=UPNG._bin,a=n.readUshort,s=n.readUint,o={tabs:{},frames:[]},h=new Uint8Array(e.length),d=0,l,u=0,p=[137,80,78,71,13,10,26,10],g=0;g<8;g++)if(e[g]!=p[g])throw"The input is not a PNG file!";for(;r<e.length;){var f=n.readUint(e,r);r+=4;var v=n.readASCII(e,r,4);if(r+=4,v=="IHDR")UPNG.decode._IHDR(e,r,o);else if(v=="IDAT"){for(var g=0;g<f;g++)h[d+g]=e[r+g];d+=f}else if(v=="acTL")o.tabs[v]={num_frames:s(e,r),num_plays:s(e,r+4)},l=new Uint8Array(e.length);else if(v=="fcTL"){if(u!=0){var y=o.frames[o.frames.length-1];y.data=UPNG.decode._decompress(o,l.slice(0,u),y.rect.width,y.rect.height),u=0}var S={x:s(e,r+12),y:s(e,r+16),width:s(e,r+4),height:s(e,r+8)},m=a(e,r+22);m=a(e,r+20)/(m==0?100:m);var w={rect:S,delay:Math.round(m*1e3),dispose:e[r+24],blend:e[r+25]};o.frames.push(w)}else if(v=="fdAT"){for(var g=0;g<f-4;g++)l[u+g]=e[r+g+4];u+=f-4}else if(v=="pHYs")o.tabs[v]=[n.readUint(e,r),n.readUint(e,r+4),e[r+8]];else if(v=="cHRM"){o.tabs[v]=[];for(var g=0;g<8;g++)o.tabs[v].push(n.readUint(e,r+g*4))}else if(v=="tEXt"){o.tabs[v]==null&&(o.tabs[v]={});var R=n.nextZero(e,r),_=n.readASCII(e,r,R-r),x=n.readASCII(e,R+1,r+f-R-1);o.tabs[v][_]=x}else if(v=="iTXt"){o.tabs[v]==null&&(o.tabs[v]={});var R=0,F=r;R=n.nextZero(e,F);var _=n.readASCII(e,F,R-F);F=R+1,e[F],e[F+1],F+=2,R=n.nextZero(e,F),n.readASCII(e,F,R-F),F=R+1,R=n.nextZero(e,F),n.readUTF8(e,F,R-F),F=R+1;var x=n.readUTF8(e,F,f-(F-r));o.tabs[v][_]=x}else if(v=="PLTE")o.tabs[v]=n.readBytes(e,r,f);else if(v=="hIST"){var A=o.tabs.PLTE.length/3;o.tabs[v]=[];for(var g=0;g<A;g++)o.tabs[v].push(a(e,r+g*2))}else if(v=="tRNS")o.ctype==3?o.tabs[v]=n.readBytes(e,r,f):o.ctype==0?o.tabs[v]=a(e,r):o.ctype==2&&(o.tabs[v]=[a(e,r),a(e,r+2),a(e,r+4)]);else if(v=="gAMA")o.tabs[v]=n.readUint(e,r)/1e5;else if(v=="sRGB")o.tabs[v]=e[r];else if(v=="bKGD")o.ctype==0||o.ctype==4?o.tabs[v]=[a(e,r)]:o.ctype==2||o.ctype==6?o.tabs[v]=[a(e,r),a(e,r+2),a(e,r+4)]:o.ctype==3&&(o.tabs[v]=e[r]);else if(v=="IEND")break;r+=f,n.readUint(e,r),r+=4}if(u!=0){var y=o.frames[o.frames.length-1];y.data=UPNG.decode._decompress(o,l.slice(0,u),y.rect.width,y.rect.height),u=0}return o.data=UPNG.decode._decompress(o,h,o.width,o.height),delete o.compress,delete o.interlace,delete o.filter,o},UPNG.decode._decompress=function(t,e,r,n){var a=UPNG.decode._getBPP(t),s=Math.ceil(r*a/8),o=new Uint8Array((s+1+t.interlace)*n);return e=UPNG.decode._inflate(e,o),t.interlace==0?e=UPNG.decode._filterZero(e,t,0,r,n):t.interlace==1&&(e=UPNG.decode._readInterlace(e,t)),e},UPNG.decode._inflate=function(t,e){var r=UPNG.inflateRaw(new Uint8Array(t.buffer,2,t.length-6),e);return r},UPNG.inflateRaw=function(){var t={};return t.H={},t.H.N=function(e,r){var n=Uint8Array,a=0,s=0,o=0,h=0,d=0,l=0,u=0,p=0,g=0,f,v;if(e[0]==3&&e[1]==0)return r||new n(0);var y=t.H,S=y.b,m=y.e,w=y.R,R=y.n,_=y.A,x=y.Z,F=y.m,A=r==null;for(A&&(r=new n(e.length>>>2<<3));a==0;){if(a=S(e,g,1),s=S(e,g+1,2),g+=3,s==0){g&7&&(g+=8-(g&7));var D=(g>>>3)+4,T=e[D-4]|e[D-3]<<8;A&&(r=t.H.W(r,p+T)),r.set(new n(e.buffer,e.byteOffset+D,T),p),g=D+T<<3,p+=T;continue}if(A&&(r=t.H.W(r,p+(1<<17))),s==1&&(f=F.J,v=F.h,l=511,u=31),s==2){o=m(e,g,5)+257,h=m(e,g+5,5)+1,d=m(e,g+10,4)+4,g+=14;for(var M=1,C=0;C<38;C+=2)F.Q[C]=0,F.Q[C+1]=0;for(var C=0;C<d;C++){var k=m(e,g+C*3,3);F.Q[(F.X[C]<<1)+1]=k,k>M&&(M=k)}g+=3*d,R(F.Q,M),_(F.Q,M,F.u),f=F.w,v=F.d,g=w(F.u,(1<<M)-1,o+h,e,g,F.v);var O=y.V(F.v,0,o,F.C);l=(1<<O)-1;var $=y.V(F.v,o,h,F.D);u=(1<<$)-1,R(F.C,O),_(F.C,O,f),R(F.D,$),_(F.D,$,v)}for(;;){var K=f[x(e,g)&l];g+=K&15;var J=K>>>4;if(!(J>>>8))r[p++]=J;else{if(J==256)break;var Y=p+J-254;if(J>264){var se=F.q[J-257];Y=p+(se>>>3)+m(e,g,se&7),g+=se&7}var B=v[x(e,g)&u];g+=B&15;var V=B>>>4,Q=F.c[V],N=(Q>>>4)+S(e,g,Q&15);for(g+=Q&15;p<Y;)r[p]=r[p++-N],r[p]=r[p++-N],r[p]=r[p++-N],r[p]=r[p++-N];p=Y}}}return r.length==p?r:r.slice(0,p)},t.H.W=function(e,r){var n=e.length;if(r<=n)return e;var a=new Uint8Array(n<<1);return a.set(e,0),a},t.H.R=function(e,r,n,a,s,o){for(var h=t.H.e,d=t.H.Z,l=0;l<n;){var u=e[d(a,s)&r];s+=u&15;var p=u>>>4;if(p<=15)o[l]=p,l++;else{var g=0,f=0;p==16?(f=3+h(a,s,2),s+=2,g=o[l-1]):p==17?(f=3+h(a,s,3),s+=3):p==18&&(f=11+h(a,s,7),s+=7);for(var v=l+f;l<v;)o[l]=g,l++}}return s},t.H.V=function(e,r,n,a){for(var s=0,o=0,h=a.length>>>1;o<n;){var d=e[o+r];a[o<<1]=0,a[(o<<1)+1]=d,d>s&&(s=d),o++}for(;o<h;)a[o<<1]=0,a[(o<<1)+1]=0,o++;return s},t.H.n=function(e,r){for(var n=t.H.m,a=e.length,s,o,h,d,l,u=n.j,d=0;d<=r;d++)u[d]=0;for(d=1;d<a;d+=2)u[e[d]]++;var p=n.K;for(s=0,u[0]=0,o=1;o<=r;o++)s=s+u[o-1]<<1,p[o]=s;for(h=0;h<a;h+=2)l=e[h+1],l!=0&&(e[h]=p[l],p[l]++)},t.H.A=function(e,r,n){for(var a=e.length,s=t.H.m,o=s.r,h=0;h<a;h+=2)if(e[h+1]!=0)for(var d=h>>1,l=e[h+1],u=d<<4|l,p=r-l,g=e[h]<<p,f=g+(1<<p);g!=f;){var v=o[g]>>>15-r;n[v]=u,g++}},t.H.l=function(e,r){for(var n=t.H.m.r,a=15-r,s=0;s<e.length;s+=2){var o=e[s]<<r-e[s+1];e[s]=n[o]>>>a}},t.H.M=function(e,r,n){n=n<<(r&7);var a=r>>>3;e[a]|=n,e[a+1]|=n>>>8},t.H.I=function(e,r,n){n=n<<(r&7);var a=r>>>3;e[a]|=n,e[a+1]|=n>>>8,e[a+2]|=n>>>16},t.H.e=function(e,r,n){return(e[r>>>3]|e[(r>>>3)+1]<<8)>>>(r&7)&(1<<n)-1},t.H.b=function(e,r,n){return(e[r>>>3]|e[(r>>>3)+1]<<8|e[(r>>>3)+2]<<16)>>>(r&7)&(1<<n)-1},t.H.Z=function(e,r){return(e[r>>>3]|e[(r>>>3)+1]<<8|e[(r>>>3)+2]<<16)>>>(r&7)},t.H.i=function(e,r){return(e[r>>>3]|e[(r>>>3)+1]<<8|e[(r>>>3)+2]<<16|e[(r>>>3)+3]<<24)>>>(r&7)},t.H.m=function(){var e=Uint16Array,r=Uint32Array;return{K:new e(16),j:new e(16),X:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],S:[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,999,999,999],T:[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0],q:new e(32),p:[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,65535,65535],z:[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0],c:new r(32),J:new e(512),_:[],h:new e(32),$:[],w:new e(32768),C:[],v:[],d:new e(32768),D:[],u:new e(512),Q:[],r:new e(32768),s:new r(286),Y:new r(30),a:new r(19),t:new r(15e3),k:new e(65536),g:new e(32768)}}(),function(){for(var e=t.H.m,r=32768,n=0;n<r;n++){var a=n;a=(a&2863311530)>>>1|(a&1431655765)<<1,a=(a&3435973836)>>>2|(a&858993459)<<2,a=(a&4042322160)>>>4|(a&252645135)<<4,a=(a&4278255360)>>>8|(a&16711935)<<8,e.r[n]=(a>>>16|a<<16)>>>17}function s(o,h,d){for(;h--!=0;)o.push(0,d)}for(var n=0;n<32;n++)e.q[n]=e.S[n]<<3|e.T[n],e.c[n]=e.p[n]<<4|e.z[n];s(e._,144,8),s(e._,112,9),s(e._,24,7),s(e._,8,8),t.H.n(e._,9),t.H.A(e._,9,e.J),t.H.l(e._,9),s(e.$,32,5),t.H.n(e.$,5),t.H.A(e.$,5,e.h),t.H.l(e.$,5),s(e.Q,19,0),s(e.C,286,0),s(e.D,30,0),s(e.v,320,0)}(),t.H.N}(),UPNG.decode._readInterlace=function(t,e){for(var r=e.width,n=e.height,a=UPNG.decode._getBPP(e),s=a>>3,o=Math.ceil(r*a/8),h=new Uint8Array(n*o),d=0,l=[0,0,4,0,2,0,1],u=[0,4,0,2,0,1,0],p=[8,8,8,4,4,2,2],g=[8,8,4,4,2,2,1],f=0;f<7;){for(var v=p[f],y=g[f],S=0,m=0,w=l[f];w<n;)w+=v,m++;for(var R=u[f];R<r;)R+=y,S++;var _=Math.ceil(S*a/8);UPNG.decode._filterZero(t,e,d,S,m);for(var x=0,F=l[f];F<n;){for(var A=u[f],D=d+x*_<<3;A<r;){if(a==1){var T=t[D>>3];T=T>>7-(D&7)&1,h[F*o+(A>>3)]|=T<<7-((A&7)<<0)}if(a==2){var T=t[D>>3];T=T>>6-(D&7)&3,h[F*o+(A>>2)]|=T<<6-((A&3)<<1)}if(a==4){var T=t[D>>3];T=T>>4-(D&7)&15,h[F*o+(A>>1)]|=T<<4-((A&1)<<2)}if(a>=8)for(var M=F*o+A*s,C=0;C<s;C++)h[M+C]=t[(D>>3)+C];D+=a,A+=y}x++,F+=v}S*m!=0&&(d+=m*(1+_)),f=f+1}return h},UPNG.decode._getBPP=function(t){var e=[1,null,3,1,2,null,4][t.ctype];return e*t.depth},UPNG.decode._filterZero=function(t,e,r,n,a){var s=UPNG.decode._getBPP(e),o=Math.ceil(n*s/8),h=UPNG.decode._paeth;s=Math.ceil(s/8);var d=0,l=1,u=t[r],p=0;if(u>1&&(t[r]=[0,0,1][u-2]),u==3)for(p=s;p<o;p++)t[p+1]=t[p+1]+(t[p+1-s]>>>1)&255;for(var g=0;g<a;g++)if(d=r+g*o,l=d+g+1,u=t[l-1],p=0,u==0)for(;p<o;p++)t[d+p]=t[l+p];else if(u==1){for(;p<s;p++)t[d+p]=t[l+p];for(;p<o;p++)t[d+p]=t[l+p]+t[d+p-s]}else if(u==2)for(;p<o;p++)t[d+p]=t[l+p]+t[d+p-o];else if(u==3){for(;p<s;p++)t[d+p]=t[l+p]+(t[d+p-o]>>>1);for(;p<o;p++)t[d+p]=t[l+p]+(t[d+p-o]+t[d+p-s]>>>1)}else{for(;p<s;p++)t[d+p]=t[l+p]+h(0,t[d+p-o],0);for(;p<o;p++)t[d+p]=t[l+p]+h(t[d+p-s],t[d+p-o],t[d+p-s-o])}return t},UPNG.decode._paeth=function(t,e,r){var n=t+e-r,a=n-t,s=n-e,o=n-r;return a*a<=s*s&&a*a<=o*o?t:s*s<=o*o?e:r},UPNG.decode._IHDR=function(t,e,r){var n=UPNG._bin;r.width=n.readUint(t,e),e+=4,r.height=n.readUint(t,e),e+=4,r.depth=t[e],e++,r.ctype=t[e],e++,r.compress=t[e],e++,r.filter=t[e],e++,r.interlace=t[e],e++},UPNG._bin={nextZero:function(t,e){for(;t[e]!=0;)e++;return e},readUshort:function(t,e){return t[e]<<8|t[e+1]},writeUshort:function(t,e,r){t[e]=r>>8&255,t[e+1]=r&255},readUint:function(t,e){return t[e]*(256*256*256)+(t[e+1]<<16|t[e+2]<<8|t[e+3])},writeUint:function(t,e,r){t[e]=r>>24&255,t[e+1]=r>>16&255,t[e+2]=r>>8&255,t[e+3]=r&255},readASCII:function(t,e,r){for(var n="",a=0;a<r;a++)n+=String.fromCharCode(t[e+a]);return n},writeASCII:function(t,e,r){for(var n=0;n<r.length;n++)t[e+n]=r.charCodeAt(n)},readBytes:function(t,e,r){for(var n=[],a=0;a<r;a++)n.push(t[e+a]);return n},pad:function(t){return t.length<2?"0"+t:t},readUTF8:function(t,e,r){for(var n="",a,s=0;s<r;s++)n+="%"+UPNG._bin.pad(t[e+s].toString(16));try{a=decodeURIComponent(n)}catch{return UPNG._bin.readASCII(t,e,r)}return a}},UPNG._copyTile=function(t,e,r,n,a,s,o,h,d){for(var l=Math.min(e,a),u=Math.min(r,s),p=0,g=0,f=0;f<u;f++)for(var v=0;v<l;v++)if(o>=0&&h>=0?(p=f*e+v<<2,g=(h+f)*a+o+v<<2):(p=(-h+f)*e-o+v<<2,g=f*a+v<<2),d==0)n[g]=t[p],n[g+1]=t[p+1],n[g+2]=t[p+2],n[g+3]=t[p+3];else if(d==1){var y=t[p+3]*.00392156862745098,S=t[p]*y,m=t[p+1]*y,w=t[p+2]*y,R=n[g+3]*(1/255),_=n[g]*R,x=n[g+1]*R,F=n[g+2]*R,A=1-y,D=y+R*A,T=D==0?0:1/D;n[g+3]=255*D,n[g+0]=(S+_*A)*T,n[g+1]=(m+x*A)*T,n[g+2]=(w+F*A)*T}else if(d==2){var y=t[p+3],S=t[p],m=t[p+1],w=t[p+2],R=n[g+3],_=n[g],x=n[g+1],F=n[g+2];y==R&&S==_&&m==x&&w==F?(n[g]=0,n[g+1]=0,n[g+2]=0,n[g+3]=0):(n[g]=S,n[g+1]=m,n[g+2]=w,n[g+3]=y)}else if(d==3){var y=t[p+3],S=t[p],m=t[p+1],w=t[p+2],R=n[g+3],_=n[g],x=n[g+1],F=n[g+2];if(y==R&&S==_&&m==x&&w==F)continue;if(y<220&&R>20)return!1}return!0},UPNG.encode=function(t,e,r,n,a,s,o){n==null&&(n=0),o==null&&(o=!1);var h=UPNG.encode.compress(t,e,r,n,[!1,!1,!1,0,o]);return UPNG.encode.compressPNG(h,-1),UPNG.encode._main(h,e,r,a,s)},UPNG.encodeLL=function(t,e,r,n,a,s,o,h){for(var d={ctype:0+(n==1?0:2)+(a==0?0:4),depth:s,frames:[]},l=(n+a)*s,u=l*e,p=0;p<t.length;p++)d.frames.push({rect:{x:0,y:0,width:e,height:r},img:new Uint8Array(t[p]),blend:0,dispose:1,bpp:Math.ceil(l/8),bpl:Math.ceil(u/8)});UPNG.encode.compressPNG(d,0,!0);var g=UPNG.encode._main(d,e,r,o,h);return g},UPNG.encode._main=function(t,e,r,n,a){a==null&&(a={});var s=UPNG.crc.crc,o=UPNG._bin.writeUint,h=UPNG._bin.writeUshort,d=UPNG._bin.writeASCII,l=8,u=t.frames.length>1,p=!1,g=33+(u?20:0);if(a.sRGB!=null&&(g+=13),a.pHYs!=null&&(g+=21),t.ctype==3){for(var f=t.plte.length,v=0;v<f;v++)t.plte[v]>>>24!=255&&(p=!0);g+=8+f*3+4+(p?8+f*1+4:0)}for(var y=0;y<t.frames.length;y++){var S=t.frames[y];u&&(g+=38),g+=S.cimg.length+12,y!=0&&(g+=4)}g+=12;for(var m=new Uint8Array(g),w=[137,80,78,71,13,10,26,10],v=0;v<8;v++)m[v]=w[v];if(o(m,l,13),l+=4,d(m,l,"IHDR"),l+=4,o(m,l,e),l+=4,o(m,l,r),l+=4,m[l]=t.depth,l++,m[l]=t.ctype,l++,m[l]=0,l++,m[l]=0,l++,m[l]=0,l++,o(m,l,s(m,l-17,17)),l+=4,a.sRGB!=null&&(o(m,l,1),l+=4,d(m,l,"sRGB"),l+=4,m[l]=a.sRGB,l++,o(m,l,s(m,l-5,5)),l+=4),a.pHYs!=null&&(o(m,l,9),l+=4,d(m,l,"pHYs"),l+=4,o(m,l,a.pHYs[0]),l+=4,o(m,l,a.pHYs[1]),l+=4,m[l]=a.pHYs[2],l++,o(m,l,s(m,l-13,13)),l+=4),u&&(o(m,l,8),l+=4,d(m,l,"acTL"),l+=4,o(m,l,t.frames.length),l+=4,o(m,l,a.loop!=null?a.loop:0),l+=4,o(m,l,s(m,l-12,12)),l+=4),t.ctype==3){var f=t.plte.length;o(m,l,f*3),l+=4,d(m,l,"PLTE"),l+=4;for(var v=0;v<f;v++){var R=v*3,_=t.plte[v],x=_&255,F=_>>>8&255,A=_>>>16&255;m[l+R+0]=x,m[l+R+1]=F,m[l+R+2]=A}if(l+=f*3,o(m,l,s(m,l-f*3-4,f*3+4)),l+=4,p){o(m,l,f),l+=4,d(m,l,"tRNS"),l+=4;for(var v=0;v<f;v++)m[l+v]=t.plte[v]>>>24&255;l+=f,o(m,l,s(m,l-f-4,f+4)),l+=4}}for(var D=0,y=0;y<t.frames.length;y++){var S=t.frames[y];u&&(o(m,l,26),l+=4,d(m,l,"fcTL"),l+=4,o(m,l,D++),l+=4,o(m,l,S.rect.width),l+=4,o(m,l,S.rect.height),l+=4,o(m,l,S.rect.x),l+=4,o(m,l,S.rect.y),l+=4,h(m,l,n[y]),l+=2,h(m,l,1e3),l+=2,m[l]=S.dispose,l++,m[l]=S.blend,l++,o(m,l,s(m,l-30,30)),l+=4);var T=S.cimg,f=T.length;o(m,l,f+(y==0?0:4)),l+=4;var M=l;d(m,l,y==0?"IDAT":"fdAT"),l+=4,y!=0&&(o(m,l,D++),l+=4),m.set(T,l),l+=f,o(m,l,s(m,M,l-M)),l+=4}return o(m,l,0),l+=4,d(m,l,"IEND"),l+=4,o(m,l,s(m,l-4,4)),l+=4,m.buffer},UPNG.encode.compressPNG=function(t,e,r){for(var n=0;n<t.frames.length;n++){var a=t.frames[n];a.rect.width;var s=a.rect.height,o=new Uint8Array(s*a.bpl+s);a.cimg=UPNG.encode._filterZero(a.img,s,a.bpp,a.bpl,o,e,r)}},UPNG.encode.compress=function(t,e,r,n,a){for(var s=a[0],o=a[1],h=a[2],d=a[3],l=a[4],u=6,p=8,g=255,f=0;f<t.length;f++)for(var v=new Uint8Array(t[f]),y=v.length,S=0;S<y;S+=4)g&=v[S+3];var m=g!=255,w=UPNG.encode.framize(t,e,r,s,o,h),R={},_=[],x=[];if(n!=0){for(var F=[],S=0;S<w.length;S++)F.push(w[S].img.buffer);for(var A=UPNG.encode.concatRGBA(F),D=UPNG.quantize(A,n),T=0,M=new Uint8Array(D.abuf),S=0;S<w.length;S++){var C=w[S].img,k=C.length;x.push(new Uint8Array(D.inds.buffer,T>>2,k>>2));for(var f=0;f<k;f+=4)C[f]=M[T+f],C[f+1]=M[T+f+1],C[f+2]=M[T+f+2],C[f+3]=M[T+f+3];T+=k}for(var S=0;S<D.plte.length;S++)_.push(D.plte[S].est.rgba)}else for(var f=0;f<w.length;f++){var O=w[f],$=new Uint32Array(O.img.buffer),K=O.rect.width,y=$.length,J=new Uint8Array(y);x.push(J);for(var S=0;S<y;S++){var Y=$[S];if(S!=0&&Y==$[S-1])J[S]=J[S-1];else if(S>K&&Y==$[S-K])J[S]=J[S-K];else{var se=R[Y];if(se==null&&(R[Y]=se=_.length,_.push(Y),_.length>=300))break;J[S]=se}}}var B=_.length;B<=256&&l==!1&&(B<=2?p=1:B<=4?p=2:B<=16?p=4:p=8,p=Math.max(p,d));for(var f=0;f<w.length;f++){var O=w[f];O.rect.x,O.rect.y;var K=O.rect.width,V=O.rect.height,Q=O.img;new Uint32Array(Q.buffer);var N=4*K,P=4;if(B<=256&&l==!1){N=Math.ceil(p*K/8);for(var E=new Uint8Array(N*V),I=x[f],z=0;z<V;z++){var S=z*N,G=z*K;if(p==8)for(var H=0;H<K;H++)E[S+H]=I[G+H];else if(p==4)for(var H=0;H<K;H++)E[S+(H>>1)]|=I[G+H]<<4-(H&1)*4;else if(p==2)for(var H=0;H<K;H++)E[S+(H>>2)]|=I[G+H]<<6-(H&3)*2;else if(p==1)for(var H=0;H<K;H++)E[S+(H>>3)]|=I[G+H]<<7-(H&7)*1}Q=E,u=3,P=1}else if(m==!1&&w.length==1){for(var E=new Uint8Array(K*V*3),ee=K*V,S=0;S<ee;S++){var C=S*3,ce=S*4;E[C]=Q[ce],E[C+1]=Q[ce+1],E[C+2]=Q[ce+2]}Q=E,u=2,P=3,N=3*K}O.img=Q,O.bpl=N,O.bpp=P}return{ctype:u,depth:p,plte:_,frames:w}},UPNG.encode.framize=function(t,e,r,n,a,s){for(var o=[],h=0;h<t.length;h++){var d=new Uint8Array(t[h]),l=new Uint32Array(d.buffer),u,p=0,g=0,f=e,v=r,y=n?1:0;if(h!=0){for(var S=s||n||h==1||o[h-2].dispose!=0?1:2,m=0,w=1e9,R=0;R<S;R++){for(var O=new Uint8Array(t[h-1-R]),_=new Uint32Array(t[h-1-R]),x=e,F=r,A=-1,D=-1,T=0;T<r;T++)for(var M=0;M<e;M++){var C=T*e+M;l[C]!=_[C]&&(M<x&&(x=M),M>A&&(A=M),T<F&&(F=T),T>D&&(D=T))}A==-1&&(x=F=A=D=0),a&&((x&1)==1&&x--,(F&1)==1&&F--);var k=(A-x+1)*(D-F+1);k<w&&(w=k,m=R,p=x,g=F,f=A-x+1,v=D-F+1)}var O=new Uint8Array(t[h-1-m]);m==1&&(o[h-1].dispose=2),u=new Uint8Array(f*v*4),UPNG._copyTile(O,e,r,u,f,v,-p,-g,0),y=UPNG._copyTile(d,e,r,u,f,v,-p,-g,3)?1:0,y==1?UPNG.encode._prepareDiff(d,e,r,u,{x:p,y:g,width:f,height:v}):UPNG._copyTile(d,e,r,u,f,v,-p,-g,0)}else u=d.slice(0);o.push({rect:{x:p,y:g,width:f,height:v},img:u,blend:y,dispose:0})}if(n)for(var h=0;h<o.length;h++){var $=o[h];if($.blend!=1){var K=$.rect,J=o[h-1].rect,Y=Math.min(K.x,J.x),se=Math.min(K.y,J.y),B=Math.max(K.x+K.width,J.x+J.width),V=Math.max(K.y+K.height,J.y+J.height),Q={x:Y,y:se,width:B-Y,height:V-se};o[h-1].dispose=1,h-1!=0&&UPNG.encode._updateFrame(t,e,r,o,h-1,Q,a),UPNG.encode._updateFrame(t,e,r,o,h,Q,a)}}var N=0;if(t.length!=1)for(var C=0;C<o.length;C++){var $=o[C];N+=$.rect.width*$.rect.height}return o},UPNG.encode._updateFrame=function(t,e,r,n,a,s,o){for(var h=Uint8Array,d=Uint32Array,l=new h(t[a-1]),u=new d(t[a-1]),p=a+1<t.length?new h(t[a+1]):null,g=new h(t[a]),f=new d(g.buffer),v=e,y=r,S=-1,m=-1,w=0;w<s.height;w++)for(var R=0;R<s.width;R++){var _=s.x+R,x=s.y+w,F=x*e+_,A=f[F];A==0||n[a-1].dispose==0&&u[F]==A&&(p==null||p[F*4+3]!=0)||(_<v&&(v=_),_>S&&(S=_),x<y&&(y=x),x>m&&(m=x))}S==-1&&(v=y=S=m=0),o&&((v&1)==1&&v--,(y&1)==1&&y--),s={x:v,y,width:S-v+1,height:m-y+1};var D=n[a];D.rect=s,D.blend=1,D.img=new Uint8Array(s.width*s.height*4),n[a-1].dispose==0?(UPNG._copyTile(l,e,r,D.img,s.width,s.height,-s.x,-s.y,0),UPNG.encode._prepareDiff(g,e,r,D.img,s)):UPNG._copyTile(g,e,r,D.img,s.width,s.height,-s.x,-s.y,0)},UPNG.encode._prepareDiff=function(t,e,r,n,a){UPNG._copyTile(t,e,r,n,a.width,a.height,-a.x,-a.y,2)},UPNG.encode._filterZero=function(t,e,r,n,a,s,o){var h=[],d=[0,1,2,3,4];s!=-1?d=[s]:(e*n>5e5||r==1)&&(d=[0]);var l;o&&(l={level:0});for(var u=o&&UZIP!=null?UZIP:pako,p=0;p<d.length;p++){for(var g=0;g<e;g++)UPNG.encode._filterLine(a,t,g,n,r,d[p]);h.push(u.deflate(a,l))}for(var f,v=1e9,p=0;p<h.length;p++)h[p].length<v&&(f=p,v=h[p].length);return h[f]},UPNG.encode._filterLine=function(t,e,r,n,a,s){var o=r*n,h=o+r,d=UPNG.decode._paeth;if(t[h]=s,h++,s==0)if(n<500)for(var l=0;l<n;l++)t[h+l]=e[o+l];else t.set(new Uint8Array(e.buffer,o,n),h);else if(s==1){for(var l=0;l<a;l++)t[h+l]=e[o+l];for(var l=a;l<n;l++)t[h+l]=e[o+l]-e[o+l-a]+256&255}else if(r==0){for(var l=0;l<a;l++)t[h+l]=e[o+l];if(s==2)for(var l=a;l<n;l++)t[h+l]=e[o+l];if(s==3)for(var l=a;l<n;l++)t[h+l]=e[o+l]-(e[o+l-a]>>1)+256&255;if(s==4)for(var l=a;l<n;l++)t[h+l]=e[o+l]-d(e[o+l-a],0,0)+256&255}else{if(s==2)for(var l=0;l<n;l++)t[h+l]=e[o+l]+256-e[o+l-n]&255;if(s==3){for(var l=0;l<a;l++)t[h+l]=e[o+l]+256-(e[o+l-n]>>1)&255;for(var l=a;l<n;l++)t[h+l]=e[o+l]+256-(e[o+l-n]+e[o+l-a]>>1)&255}if(s==4){for(var l=0;l<a;l++)t[h+l]=e[o+l]+256-d(0,e[o+l-n],0)&255;for(var l=a;l<n;l++)t[h+l]=e[o+l]+256-d(e[o+l-a],e[o+l-n],e[o+l-a-n])&255}}},UPNG.crc={table:function(){for(var t=new Uint32Array(256),e=0;e<256;e++){for(var r=e,n=0;n<8;n++)r&1?r=3988292384^r>>>1:r=r>>>1;t[e]=r}return t}(),update:function(t,e,r,n){for(var a=0;a<n;a++)t=UPNG.crc.table[(t^e[r+a])&255]^t>>>8;return t},crc:function(t,e,r){return UPNG.crc.update(4294967295,t,e,r)^4294967295}},UPNG.quantize=function(t,e){var r=new Uint8Array(t),n=r.slice(0),a=new Uint32Array(n.buffer),s=UPNG.quantize.getKDtree(n,e),o=s[0],h=s[1];UPNG.quantize.planeDst;for(var d=r,l=a,u=d.length,p=new Uint8Array(r.length>>2),g=0;g<u;g+=4){var f=d[g]*.00392156862745098,v=d[g+1]*(1/255),y=d[g+2]*(1/255),S=d[g+3]*(1/255),m=UPNG.quantize.getNearest(o,f,v,y,S);p[g>>2]=m.ind,l[g>>2]=m.est.rgba}return{abuf:n.buffer,inds:p,plte:h}},UPNG.quantize.getKDtree=function(t,e,r){r==null&&(r=1e-4);var n=new Uint32Array(t.buffer),a={i0:0,i1:t.length,bst:null,est:null,tdst:0,left:null,right:null};a.bst=UPNG.quantize.stats(t,a.i0,a.i1),a.est=UPNG.quantize.estats(a.bst);for(var s=[a];s.length<e;){for(var o=0,h=0,d=0;d<s.length;d++)s[d].est.L>o&&(o=s[d].est.L,h=d);if(o<r)break;var l=s[h],u=UPNG.quantize.splitPixels(t,n,l.i0,l.i1,l.est.e,l.est.eMq255),p=l.i0>=u||l.i1<=u;if(p){l.est.L=0;continue}var g={i0:l.i0,i1:u,bst:null,est:null,tdst:0,left:null,right:null};g.bst=UPNG.quantize.stats(t,g.i0,g.i1),g.est=UPNG.quantize.estats(g.bst);var f={i0:u,i1:l.i1,bst:null,est:null,tdst:0,left:null,right:null};f.bst={R:[],m:[],N:l.bst.N-g.bst.N};for(var d=0;d<16;d++)f.bst.R[d]=l.bst.R[d]-g.bst.R[d];for(var d=0;d<4;d++)f.bst.m[d]=l.bst.m[d]-g.bst.m[d];f.est=UPNG.quantize.estats(f.bst),l.left=g,l.right=f,s[h]=g,s.push(f)}s.sort(function(v,y){return y.bst.N-v.bst.N});for(var d=0;d<s.length;d++)s[d].ind=d;return[a,s]},UPNG.quantize.getNearest=function(t,e,r,n,a){if(t.left==null)return t.tdst=UPNG.quantize.dist(t.est.q,e,r,n,a),t;var s=UPNG.quantize.planeDst(t.est,e,r,n,a),o=t.left,h=t.right;s>0&&(o=t.right,h=t.left);var d=UPNG.quantize.getNearest(o,e,r,n,a);if(d.tdst<=s*s)return d;var l=UPNG.quantize.getNearest(h,e,r,n,a);return l.tdst<d.tdst?l:d},UPNG.quantize.planeDst=function(t,e,r,n,a){var s=t.e;return s[0]*e+s[1]*r+s[2]*n+s[3]*a-t.eMq},UPNG.quantize.dist=function(t,e,r,n,a){var s=e-t[0],o=r-t[1],h=n-t[2],d=a-t[3];return s*s+o*o+h*h+d*d},UPNG.quantize.splitPixels=function(t,e,r,n,a,s){var o=UPNG.quantize.vecDot;for(n-=4;r<n;){for(;o(t,r,a)<=s;)r+=4;for(;o(t,n,a)>s;)n-=4;if(r>=n)break;var h=e[r>>2];e[r>>2]=e[n>>2],e[n>>2]=h,r+=4,n-=4}for(;o(t,r,a)>s;)r-=4;return r+4},UPNG.quantize.vecDot=function(t,e,r){return t[e]*r[0]+t[e+1]*r[1]+t[e+2]*r[2]+t[e+3]*r[3]},UPNG.quantize.stats=function(t,e,r){for(var n=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],a=[0,0,0,0],s=r-e>>2,o=e;o<r;o+=4){var h=t[o]*.00392156862745098,d=t[o+1]*(1/255),l=t[o+2]*(1/255),u=t[o+3]*(1/255);a[0]+=h,a[1]+=d,a[2]+=l,a[3]+=u,n[0]+=h*h,n[1]+=h*d,n[2]+=h*l,n[3]+=h*u,n[5]+=d*d,n[6]+=d*l,n[7]+=d*u,n[10]+=l*l,n[11]+=l*u,n[15]+=u*u}return n[4]=n[1],n[8]=n[2],n[9]=n[6],n[12]=n[3],n[13]=n[7],n[14]=n[11],{R:n,m:a,N:s}},UPNG.quantize.estats=function(t){var e=t.R,r=t.m,n=t.N,a=r[0],s=r[1],o=r[2],h=r[3],d=n==0?0:1/n,l=[e[0]-a*a*d,e[1]-a*s*d,e[2]-a*o*d,e[3]-a*h*d,e[4]-s*a*d,e[5]-s*s*d,e[6]-s*o*d,e[7]-s*h*d,e[8]-o*a*d,e[9]-o*s*d,e[10]-o*o*d,e[11]-o*h*d,e[12]-h*a*d,e[13]-h*s*d,e[14]-h*o*d,e[15]-h*h*d],u=l,p=UPNG.M4,g=[.5,.5,.5,.5],f=0,v=0;if(n!=0)for(var y=0;y<10&&(g=p.multVec(u,g),v=Math.sqrt(p.dot(g,g)),g=p.sml(1/v,g),!(Math.abs(v-f)<1e-9));y++)f=v;var S=[a*d,s*d,o*d,h*d],m=p.dot(p.sml(255,S),g);return{Cov:l,q:S,e:g,L:f,eMq255:m,eMq:p.dot(g,S),rgba:(Math.round(255*S[3])<<24|Math.round(255*S[2])<<16|Math.round(255*S[1])<<8|Math.round(255*S[0])<<0)>>>0}},UPNG.M4={multVec:function(t,e){return[t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3],t[4]*e[0]+t[5]*e[1]+t[6]*e[2]+t[7]*e[3],t[8]*e[0]+t[9]*e[1]+t[10]*e[2]+t[11]*e[3],t[12]*e[0]+t[13]*e[1]+t[14]*e[2]+t[15]*e[3]]},dot:function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3]},sml:function(t,e){return[t*e[0],t*e[1],t*e[2],t*e[3]]}},UPNG.encode.concatRGBA=function(t){for(var e=0,r=0;r<t.length;r++)e+=t[r].byteLength;for(var n=new Uint8Array(e),a=0,r=0;r<t.length;r++){for(var s=new Uint8Array(t[r]),o=s.length,h=0;h<o;h+=4){var d=s[h],l=s[h+1],u=s[h+2],p=s[h+3];p==0&&(d=l=u=0),n[a+h]=d,n[a+h+1]=l,n[a+h+2]=u,n[a+h+3]=p}a+=o}return n.buffer};var getImageType=function(t){if(t===0)return PngType.Greyscale;if(t===2)return PngType.Truecolour;if(t===3)return PngType.IndexedColour;if(t===4)return PngType.GreyscaleWithAlpha;if(t===6)return PngType.TruecolourWithAlpha;throw new Error("Unknown color type: "+t)},splitAlphaChannel=function(t){for(var e=Math.floor(t.length/4),r=new Uint8Array(e*3),n=new Uint8Array(e*1),a=0,s=0,o=0;a<t.length;)r[s++]=t[a++],r[s++]=t[a++],r[s++]=t[a++],n[o++]=t[a++];return{rgbChannel:r,alphaChannel:n}},PngType;(function(t){t.Greyscale="Greyscale",t.Truecolour="Truecolour",t.IndexedColour="IndexedColour",t.GreyscaleWithAlpha="GreyscaleWithAlpha",t.TruecolourWithAlpha="TruecolourWithAlpha"})(PngType||(PngType={}));var PNG=function(){function t(e){var r=UPNG.decode(e),n=UPNG.toRGBA8(r);if(n.length>1)throw new Error("Animated PNGs are not supported");var a=new Uint8Array(n[0]),s=splitAlphaChannel(a),o=s.rgbChannel,h=s.alphaChannel;this.rgbChannel=o;var d=h.some(function(l){return l<255});d&&(this.alphaChannel=h),this.type=getImageType(r.ctype),this.width=r.width,this.height=r.height,this.bitsPerComponent=8}return t.load=function(e){return new t(e)},t}(),PngEmbedder=function(){function t(e){this.image=e,this.bitsPerComponent=e.bitsPerComponent,this.width=e.width,this.height=e.height,this.colorSpace="DeviceRGB"}return t.for=function(e){return __awaiter(this,void 0,void 0,function(){var r;return __generator(this,function(n){return r=PNG.load(e),[2,new t(r)]})})},t.prototype.embedIntoContext=function(e,r){return __awaiter(this,void 0,void 0,function(){var n,a;return __generator(this,function(s){return n=this.embedAlphaChannel(e),a=e.flateStream(this.image.rgbChannel,{Type:"XObject",Subtype:"Image",BitsPerComponent:this.image.bitsPerComponent,Width:this.image.width,Height:this.image.height,ColorSpace:this.colorSpace,SMask:n}),r?(e.assign(r,a),[2,r]):[2,e.register(a)]})})},t.prototype.embedAlphaChannel=function(e){if(this.image.alphaChannel){var r=e.flateStream(this.image.alphaChannel,{Type:"XObject",Subtype:"Image",Height:this.image.height,Width:this.image.width,BitsPerComponent:this.image.bitsPerComponent,ColorSpace:"DeviceGray",Decode:[0,1]});return e.register(r)}},t}(),Stream=function(){function t(e,r,n){this.bytes=e,this.start=r||0,this.pos=this.start,this.end=r&&n?r+n:this.bytes.length}return Object.defineProperty(t.prototype,"length",{get:function(){return this.end-this.start},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isEmpty",{get:function(){return this.length===0},enumerable:!1,configurable:!0}),t.prototype.getByte=function(){return this.pos>=this.end?-1:this.bytes[this.pos++]},t.prototype.getUint16=function(){var e=this.getByte(),r=this.getByte();return e===-1||r===-1?-1:(e<<8)+r},t.prototype.getInt32=function(){var e=this.getByte(),r=this.getByte(),n=this.getByte(),a=this.getByte();return(e<<24)+(r<<16)+(n<<8)+a},t.prototype.getBytes=function(e,r){r===void 0&&(r=!1);var n=this.bytes,a=this.pos,s=this.end;if(e){var h=a+e;h>s&&(h=s),this.pos=h;var o=n.subarray(a,h);return r?new Uint8ClampedArray(o):o}else{var o=n.subarray(a,s);return r?new Uint8ClampedArray(o):o}},t.prototype.peekByte=function(){var e=this.getByte();return this.pos--,e},t.prototype.peekBytes=function(e,r){r===void 0&&(r=!1);var n=this.getBytes(e,r);return this.pos-=n.length,n},t.prototype.skip=function(e){e||(e=1),this.pos+=e},t.prototype.reset=function(){this.pos=this.start},t.prototype.moveStart=function(){this.start=this.pos},t.prototype.makeSubStream=function(e,r){return new t(this.bytes,e,r)},t.prototype.decode=function(){return this.bytes},t}(),emptyBuffer=new Uint8Array(0),DecodeStream=function(){function t(e){if(this.pos=0,this.bufferLength=0,this.eof=!1,this.buffer=emptyBuffer,this.minBufferLength=512,e)for(;this.minBufferLength<e;)this.minBufferLength*=2}return Object.defineProperty(t.prototype,"isEmpty",{get:function(){for(;!this.eof&&this.bufferLength===0;)this.readBlock();return this.bufferLength===0},enumerable:!1,configurable:!0}),t.prototype.getByte=function(){for(var e=this.pos;this.bufferLength<=e;){if(this.eof)return-1;this.readBlock()}return this.buffer[this.pos++]},t.prototype.getUint16=function(){var e=this.getByte(),r=this.getByte();return e===-1||r===-1?-1:(e<<8)+r},t.prototype.getInt32=function(){var e=this.getByte(),r=this.getByte(),n=this.getByte(),a=this.getByte();return(e<<24)+(r<<16)+(n<<8)+a},t.prototype.getBytes=function(e,r){r===void 0&&(r=!1);var n,a=this.pos;if(e){for(this.ensureBuffer(a+e),n=a+e;!this.eof&&this.bufferLength<n;)this.readBlock();var s=this.bufferLength;n>s&&(n=s)}else{for(;!this.eof;)this.readBlock();n=this.bufferLength}this.pos=n;var o=this.buffer.subarray(a,n);return r&&!(o instanceof Uint8ClampedArray)?new Uint8ClampedArray(o):o},t.prototype.peekByte=function(){var e=this.getByte();return this.pos--,e},t.prototype.peekBytes=function(e,r){r===void 0&&(r=!1);var n=this.getBytes(e,r);return this.pos-=n.length,n},t.prototype.skip=function(e){e||(e=1),this.pos+=e},t.prototype.reset=function(){this.pos=0},t.prototype.makeSubStream=function(e,r){for(var n=e+r;this.bufferLength<=n&&!this.eof;)this.readBlock();return new Stream(this.buffer,e,r)},t.prototype.decode=function(){for(;!this.eof;)this.readBlock();return this.buffer.subarray(0,this.bufferLength)},t.prototype.readBlock=function(){throw new MethodNotImplementedError(this.constructor.name,"readBlock")},t.prototype.ensureBuffer=function(e){var r=this.buffer;if(e<=r.byteLength)return r;for(var n=this.minBufferLength;n<e;)n*=2;var a=new Uint8Array(n);return a.set(r),this.buffer=a},t}(),isSpace=function(t){return t===32||t===9||t===13||t===10},Ascii85Stream=function(t){__extends(e,t);function e(r,n){var a=t.call(this,n)||this;return a.stream=r,a.input=new Uint8Array(5),n&&(n=.8*n),a}return e.prototype.readBlock=function(){for(var r=126,n=122,a=-1,s=this.stream,o=s.getByte();isSpace(o);)o=s.getByte();if(o===a||o===r){this.eof=!0;return}var h=this.bufferLength,d,l;if(o===n){for(d=this.ensureBuffer(h+4),l=0;l<4;++l)d[h+l]=0;this.bufferLength+=4}else{var u=this.input;for(u[0]=o,l=1;l<5;++l){for(o=s.getByte();isSpace(o);)o=s.getByte();if(u[l]=o,o===a||o===r)break}if(d=this.ensureBuffer(h+l-1),this.bufferLength+=l-1,l<5){for(;l<5;++l)u[l]=117;this.eof=!0}var p=0;for(l=0;l<5;++l)p=p*85+(u[l]-33);for(l=3;l>=0;--l)d[h+l]=p&255,p>>=8}},e}(DecodeStream),AsciiHexStream=function(t){__extends(e,t);function e(r,n){var a=t.call(this,n)||this;return a.stream=r,a.firstDigit=-1,n&&(n=.5*n),a}return e.prototype.readBlock=function(){var r=8e3,n=this.stream.getBytes(r);if(!n.length){this.eof=!0;return}for(var a=n.length+1>>1,s=this.ensureBuffer(this.bufferLength+a),o=this.bufferLength,h=this.firstDigit,d=0,l=n.length;d<l;d++){var u=n[d],p=void 0;if(u>=48&&u<=57)p=u&15;else if(u>=65&&u<=70||u>=97&&u<=102)p=(u&15)+9;else if(u===62){this.eof=!0;break}else continue;h<0?h=p:(s[o++]=h<<4|p,h=-1)}h>=0&&this.eof&&(s[o++]=h<<4,h=-1),this.firstDigit=h,this.bufferLength=o},e}(DecodeStream),codeLenCodeMap=new Int32Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),lengthDecode=new Int32Array([3,4,5,6,7,8,9,10,65547,65549,65551,65553,131091,131095,131099,131103,196643,196651,196659,196667,262211,262227,262243,262259,327811,327843,327875,327907,258,258,258]),distDecode=new Int32Array([1,2,3,4,65541,65543,131081,131085,196625,196633,262177,262193,327745,327777,393345,393409,459009,459137,524801,525057,590849,591361,657409,658433,724993,727041,794625,798721,868353,876545]),fixedLitCodeTab=[new Int32Array([459008,524368,524304,524568,459024,524400,524336,590016,459016,524384,524320,589984,524288,524416,524352,590048,459012,524376,524312,589968,459028,524408,524344,590032,459020,524392,524328,59e4,524296,524424,524360,590064,459010,524372,524308,524572,459026,524404,524340,590024,459018,524388,524324,589992,524292,524420,524356,590056,459014,524380,524316,589976,459030,524412,524348,590040,459022,524396,524332,590008,524300,524428,524364,590072,459009,524370,524306,524570,459025,524402,524338,590020,459017,524386,524322,589988,524290,524418,524354,590052,459013,524378,524314,589972,459029,524410,524346,590036,459021,524394,524330,590004,524298,524426,524362,590068,459011,524374,524310,524574,459027,524406,524342,590028,459019,524390,524326,589996,524294,524422,524358,590060,459015,524382,524318,589980,459031,524414,524350,590044,459023,524398,524334,590012,524302,524430,524366,590076,459008,524369,524305,524569,459024,524401,524337,590018,459016,524385,524321,589986,524289,524417,524353,590050,459012,524377,524313,589970,459028,524409,524345,590034,459020,524393,524329,590002,524297,524425,524361,590066,459010,524373,524309,524573,459026,524405,524341,590026,459018,524389,524325,589994,524293,524421,524357,590058,459014,524381,524317,589978,459030,524413,524349,590042,459022,524397,524333,590010,524301,524429,524365,590074,459009,524371,524307,524571,459025,524403,524339,590022,459017,524387,524323,589990,524291,524419,524355,590054,459013,524379,524315,589974,459029,524411,524347,590038,459021,524395,524331,590006,524299,524427,524363,590070,459011,524375,524311,524575,459027,524407,524343,590030,459019,524391,524327,589998,524295,524423,524359,590062,459015,524383,524319,589982,459031,524415,524351,590046,459023,524399,524335,590014,524303,524431,524367,590078,459008,524368,524304,524568,459024,524400,524336,590017,459016,524384,524320,589985,524288,524416,524352,590049,459012,524376,524312,589969,459028,524408,524344,590033,459020,524392,524328,590001,524296,524424,524360,590065,459010,524372,524308,524572,459026,524404,524340,590025,459018,524388,524324,589993,524292,524420,524356,590057,459014,524380,524316,589977,459030,524412,524348,590041,459022,524396,524332,590009,524300,524428,524364,590073,459009,524370,524306,524570,459025,524402,524338,590021,459017,524386,524322,589989,524290,524418,524354,590053,459013,524378,524314,589973,459029,524410,524346,590037,459021,524394,524330,590005,524298,524426,524362,590069,459011,524374,524310,524574,459027,524406,524342,590029,459019,524390,524326,589997,524294,524422,524358,590061,459015,524382,524318,589981,459031,524414,524350,590045,459023,524398,524334,590013,524302,524430,524366,590077,459008,524369,524305,524569,459024,524401,524337,590019,459016,524385,524321,589987,524289,524417,524353,590051,459012,524377,524313,589971,459028,524409,524345,590035,459020,524393,524329,590003,524297,524425,524361,590067,459010,524373,524309,524573,459026,524405,524341,590027,459018,524389,524325,589995,524293,524421,524357,590059,459014,524381,524317,589979,459030,524413,524349,590043,459022,524397,524333,590011,524301,524429,524365,590075,459009,524371,524307,524571,459025,524403,524339,590023,459017,524387,524323,589991,524291,524419,524355,590055,459013,524379,524315,589975,459029,524411,524347,590039,459021,524395,524331,590007,524299,524427,524363,590071,459011,524375,524311,524575,459027,524407,524343,590031,459019,524391,524327,589999,524295,524423,524359,590063,459015,524383,524319,589983,459031,524415,524351,590047,459023,524399,524335,590015,524303,524431,524367,590079]),9],fixedDistCodeTab=[new Int32Array([327680,327696,327688,327704,327684,327700,327692,327708,327682,327698,327690,327706,327686,327702,327694,0,327681,327697,327689,327705,327685,327701,327693,327709,327683,327699,327691,327707,327687,327703,327695,0]),5],FlateStream=function(t){__extends(e,t);function e(r,n){var a=t.call(this,n)||this;a.stream=r;var s=r.getByte(),o=r.getByte();if(s===-1||o===-1)throw new Error("Invalid header in flate stream: "+s+", "+o);if((s&15)!==8)throw new Error("Unknown compression method in flate stream: "+s+", "+o);if(((s<<8)+o)%31!==0)throw new Error("Bad FCHECK in flate stream: "+s+", "+o);if(o&32)throw new Error("FDICT bit set in flate stream: "+s+", "+o);return a.codeSize=0,a.codeBuf=0,a}return e.prototype.readBlock=function(){var r,n,a=this.stream,s=this.getBits(3);if(s&1&&(this.eof=!0),s>>=1,s===0){var o=void 0;if((o=a.getByte())===-1)throw new Error("Bad block header in flate stream");var h=o;if((o=a.getByte())===-1)throw new Error("Bad block header in flate stream");if(h|=o<<8,(o=a.getByte())===-1)throw new Error("Bad block header in flate stream");var d=o;if((o=a.getByte())===-1)throw new Error("Bad block header in flate stream");if(d|=o<<8,d!==(~h&65535)&&(h!==0||d!==0))throw new Error("Bad uncompressed block length in flate stream");this.codeBuf=0,this.codeSize=0;var l=this.bufferLength;r=this.ensureBuffer(l+h);var u=l+h;if(this.bufferLength=u,h===0)a.peekByte()===-1&&(this.eof=!0);else for(var p=l;p<u;++p){if((o=a.getByte())===-1){this.eof=!0;break}r[p]=o}return}var g,f;if(s===1)g=fixedLitCodeTab,f=fixedDistCodeTab;else if(s===2){var v=this.getBits(5)+257,y=this.getBits(5)+1,S=this.getBits(4)+4,m=new Uint8Array(codeLenCodeMap.length),w=void 0;for(w=0;w<S;++w)m[codeLenCodeMap[w]]=this.getBits(3);var R=this.generateHuffmanTable(m);n=0,w=0;for(var _=v+y,x=new Uint8Array(_),F=void 0,A=void 0,D=void 0;w<_;){var T=this.getCode(R);if(T===16)F=2,A=3,D=n;else if(T===17)F=3,A=3,D=n=0;else if(T===18)F=7,A=11,D=n=0;else{x[w++]=n=T;continue}for(var M=this.getBits(F)+A;M-- >0;)x[w++]=D}g=this.generateHuffmanTable(x.subarray(0,v)),f=this.generateHuffmanTable(x.subarray(v,_))}else throw new Error("Unknown block type in flate stream");r=this.buffer;for(var C=r?r.length:0,k=this.bufferLength;;){var O=this.getCode(g);if(O<256){k+1>=C&&(r=this.ensureBuffer(k+1),C=r.length),r[k++]=O;continue}if(O===256){this.bufferLength=k;return}O-=257,O=lengthDecode[O];var $=O>>16;$>0&&($=this.getBits($)),n=(O&65535)+$,O=this.getCode(f),O=distDecode[O],$=O>>16,$>0&&($=this.getBits($));var K=(O&65535)+$;k+n>=C&&(r=this.ensureBuffer(k+n),C=r.length);for(var J=0;J<n;++J,++k)r[k]=r[k-K]}},e.prototype.getBits=function(r){for(var n=this.stream,a=this.codeSize,s=this.codeBuf,o;a<r;){if((o=n.getByte())===-1)throw new Error("Bad encoding in flate stream");s|=o<<a,a+=8}return o=s&(1<<r)-1,this.codeBuf=s>>r,this.codeSize=a-=r,o},e.prototype.getCode=function(r){for(var n=this.stream,a=r[0],s=r[1],o=this.codeSize,h=this.codeBuf,d;o<s&&(d=n.getByte())!==-1;)h|=d<<o,o+=8;var l=a[h&(1<<s)-1];typeof a=="number"&&console.log("FLATE:",l);var u=l>>16,p=l&65535;if(u<1||o<u)throw new Error("Bad encoding in flate stream");return this.codeBuf=h>>u,this.codeSize=o-u,p},e.prototype.generateHuffmanTable=function(r){var n=r.length,a=0,s;for(s=0;s<n;++s)r[s]>a&&(a=r[s]);for(var o=1<<a,h=new Int32Array(o),d=1,l=0,u=2;d<=a;++d,l<<=1,u<<=1)for(var p=0;p<n;++p)if(r[p]===d){var g=0,f=l;for(s=0;s<d;++s)g=g<<1|f&1,f>>=1;for(s=g;s<o;s+=u)h[s]=d<<16|p;++l}return[h,a]},e}(DecodeStream),LZWStream=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,n)||this;s.stream=r,s.cachedData=0,s.bitsCached=0;for(var o=4096,h={earlyChange:a,codeLength:9,nextCode:258,dictionaryValues:new Uint8Array(o),dictionaryLengths:new Uint16Array(o),dictionaryPrevCodes:new Uint16Array(o),currentSequence:new Uint8Array(o),currentSequenceLength:0},d=0;d<256;++d)h.dictionaryValues[d]=d,h.dictionaryLengths[d]=1;return s.lzwState=h,s}return e.prototype.readBlock=function(){var r=512,n=r*2,a=r,s,o,h,d=this.lzwState;if(d){var l=d.earlyChange,u=d.nextCode,p=d.dictionaryValues,g=d.dictionaryLengths,f=d.dictionaryPrevCodes,v=d.codeLength,y=d.prevCode,S=d.currentSequence,m=d.currentSequenceLength,w=0,R=this.bufferLength,_=this.ensureBuffer(this.bufferLength+n);for(s=0;s<r;s++){var x=this.readBits(v),F=m>0;if(!x||x<256)S[0]=x,m=1;else if(x>=258)if(x<u)for(m=g[x],o=m-1,h=x;o>=0;o--)S[o]=p[h],h=f[h];else S[m++]=S[0];else if(x===256){v=9,u=258,m=0;continue}else{this.eof=!0,delete this.lzwState;break}if(F&&(f[u]=y,g[u]=g[y]+1,p[u]=S[0],u++,v=u+l&u+l-1?v:Math.min(Math.log(u+l)/.6931471805599453+1,12)|0),y=x,w+=m,n<w){do n+=a;while(n<w);_=this.ensureBuffer(this.bufferLength+n)}for(o=0;o<m;o++)_[R++]=S[o]}d.nextCode=u,d.codeLength=v,d.prevCode=y,d.currentSequenceLength=m,this.bufferLength=R}},e.prototype.readBits=function(r){for(var n=this.bitsCached,a=this.cachedData;n<r;){var s=this.stream.getByte();if(s===-1)return this.eof=!0,null;a=a<<8|s,n+=8}return this.bitsCached=n-=r,this.cachedData=a,a>>>n&(1<<r)-1},e}(DecodeStream),RunLengthStream=function(t){__extends(e,t);function e(r,n){var a=t.call(this,n)||this;return a.stream=r,a}return e.prototype.readBlock=function(){var r=this.stream.getBytes(2);if(!r||r.length<2||r[0]===128){this.eof=!0;return}var n,a=this.bufferLength,s=r[0];if(s<128){if(n=this.ensureBuffer(a+s+1),n[a++]=r[1],s>0){var o=this.stream.getBytes(s);n.set(o,a),a+=s}}else{s=257-s;var h=r[1];n=this.ensureBuffer(a+s+1);for(var d=0;d<s;d++)n[a++]=h}this.bufferLength=a},e}(DecodeStream),decodeStream=function(t,e,r){if(e===PDFName.of("FlateDecode"))return new FlateStream(t);if(e===PDFName.of("LZWDecode")){var n=1;if(r instanceof PDFDict){var a=r.lookup(PDFName.of("EarlyChange"));a instanceof PDFNumber&&(n=a.asNumber())}return new LZWStream(t,void 0,n)}if(e===PDFName.of("ASCII85Decode"))return new Ascii85Stream(t);if(e===PDFName.of("ASCIIHexDecode"))return new AsciiHexStream(t);if(e===PDFName.of("RunLengthDecode"))return new RunLengthStream(t);throw new UnsupportedEncodingError(e.asString())},decodePDFRawStream=function(t){var e=t.dict,r=t.contents,n=new Stream(r),a=e.lookup(PDFName.of("Filter")),s=e.lookup(PDFName.of("DecodeParms"));if(a instanceof PDFName)n=decodeStream(n,a,s);else if(a instanceof PDFArray)for(var o=0,h=a.size();o<h;o++)n=decodeStream(n,a.lookup(o,PDFName),s&&s.lookupMaybe(o,PDFDict));else if(a)throw new UnexpectedObjectTypeError([PDFName,PDFArray],a);return n},fullPageBoundingBox=function(t){var e=t.MediaBox(),r=e.lookup(2,PDFNumber).asNumber()-e.lookup(0,PDFNumber).asNumber(),n=e.lookup(3,PDFNumber).asNumber()-e.lookup(1,PDFNumber).asNumber();return{left:0,bottom:0,right:r,top:n}},boundingBoxAdjustedMatrix=function(t){return[1,0,0,1,-t.left,-t.bottom]},PDFPageEmbedder=function(){function t(e,r,n){this.page=e;var a=r??fullPageBoundingBox(e);this.width=a.right-a.left,this.height=a.top-a.bottom,this.boundingBox=a,this.transformationMatrix=n??boundingBoxAdjustedMatrix(a)}return t.for=function(e,r,n){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(a){return[2,new t(e,r,n)]})})},t.prototype.embedIntoContext=function(e,r){return __awaiter(this,void 0,void 0,function(){var n,a,s,o,h,d,l,u,p,g;return __generator(this,function(f){if(n=this.page.normalizedEntries(),a=n.Contents,s=n.Resources,!a)throw new MissingPageContentsEmbeddingError;return o=this.decodeContents(a),h=this.boundingBox,d=h.left,l=h.bottom,u=h.right,p=h.top,g=e.flateStream(o,{Type:"XObject",Subtype:"Form",FormType:1,BBox:[d,l,u,p],Matrix:this.transformationMatrix,Resources:s}),r?(e.assign(r,g),[2,r]):[2,e.register(g)]})})},t.prototype.decodeContents=function(e){for(var r=Uint8Array.of(CharCodes.Newline),n=[],a=0,s=e.size();a<s;a++){var o=e.lookup(a,PDFStream),h=void 0;if(o instanceof PDFRawStream)h=decodePDFRawStream(o).decode();else if(o instanceof PDFContentStream)h=o.getUnencodedContents();else throw new UnrecognizedStreamTypeError(o);n.push(h,r)}return mergeIntoTypedArray.apply(void 0,n)},t}(),asEnum=function(t,e){if(t!==void 0)return e[t]},NonFullScreenPageMode;(function(t){t.UseNone="UseNone",t.UseOutlines="UseOutlines",t.UseThumbs="UseThumbs",t.UseOC="UseOC"})(NonFullScreenPageMode||(NonFullScreenPageMode={}));var ReadingDirection;(function(t){t.L2R="L2R",t.R2L="R2L"})(ReadingDirection||(ReadingDirection={}));var PrintScaling;(function(t){t.None="None",t.AppDefault="AppDefault"})(PrintScaling||(PrintScaling={}));var Duplex;(function(t){t.Simplex="Simplex",t.DuplexFlipShortEdge="DuplexFlipShortEdge",t.DuplexFlipLongEdge="DuplexFlipLongEdge"})(Duplex||(Duplex={}));var ViewerPreferences=function(){function t(e){this.dict=e}return t.prototype.lookupBool=function(e){var r=this.dict.lookup(PDFName.of(e));if(r instanceof PDFBool)return r},t.prototype.lookupName=function(e){var r=this.dict.lookup(PDFName.of(e));if(r instanceof PDFName)return r},t.prototype.HideToolbar=function(){return this.lookupBool("HideToolbar")},t.prototype.HideMenubar=function(){return this.lookupBool("HideMenubar")},t.prototype.HideWindowUI=function(){return this.lookupBool("HideWindowUI")},t.prototype.FitWindow=function(){return this.lookupBool("FitWindow")},t.prototype.CenterWindow=function(){return this.lookupBool("CenterWindow")},t.prototype.DisplayDocTitle=function(){return this.lookupBool("DisplayDocTitle")},t.prototype.NonFullScreenPageMode=function(){return this.lookupName("NonFullScreenPageMode")},t.prototype.Direction=function(){return this.lookupName("Direction")},t.prototype.PrintScaling=function(){return this.lookupName("PrintScaling")},t.prototype.Duplex=function(){return this.lookupName("Duplex")},t.prototype.PickTrayByPDFSize=function(){return this.lookupBool("PickTrayByPDFSize")},t.prototype.PrintPageRange=function(){var e=this.dict.lookup(PDFName.of("PrintPageRange"));if(e instanceof PDFArray)return e},t.prototype.NumCopies=function(){var e=this.dict.lookup(PDFName.of("NumCopies"));if(e instanceof PDFNumber)return e},t.prototype.getHideToolbar=function(){var e,r;return(r=(e=this.HideToolbar())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getHideMenubar=function(){var e,r;return(r=(e=this.HideMenubar())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getHideWindowUI=function(){var e,r;return(r=(e=this.HideWindowUI())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getFitWindow=function(){var e,r;return(r=(e=this.FitWindow())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getCenterWindow=function(){var e,r;return(r=(e=this.CenterWindow())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getDisplayDocTitle=function(){var e,r;return(r=(e=this.DisplayDocTitle())===null||e===void 0?void 0:e.asBoolean())!==null&&r!==void 0?r:!1},t.prototype.getNonFullScreenPageMode=function(){var e,r,n=(e=this.NonFullScreenPageMode())===null||e===void 0?void 0:e.decodeText();return(r=asEnum(n,NonFullScreenPageMode))!==null&&r!==void 0?r:NonFullScreenPageMode.UseNone},t.prototype.getReadingDirection=function(){var e,r,n=(e=this.Direction())===null||e===void 0?void 0:e.decodeText();return(r=asEnum(n,ReadingDirection))!==null&&r!==void 0?r:ReadingDirection.L2R},t.prototype.getPrintScaling=function(){var e,r,n=(e=this.PrintScaling())===null||e===void 0?void 0:e.decodeText();return(r=asEnum(n,PrintScaling))!==null&&r!==void 0?r:PrintScaling.AppDefault},t.prototype.getDuplex=function(){var e,r=(e=this.Duplex())===null||e===void 0?void 0:e.decodeText();return asEnum(r,Duplex)},t.prototype.getPickTrayByPDFSize=function(){var e;return(e=this.PickTrayByPDFSize())===null||e===void 0?void 0:e.asBoolean()},t.prototype.getPrintPageRange=function(){var e=this.PrintPageRange();if(!e)return[];for(var r=[],n=0;n<e.size();n+=2){var a=e.lookup(n,PDFNumber).asNumber(),s=e.lookup(n+1,PDFNumber).asNumber();r.push({start:a,end:s})}return r},t.prototype.getNumCopies=function(){var e,r;return(r=(e=this.NumCopies())===null||e===void 0?void 0:e.asNumber())!==null&&r!==void 0?r:1},t.prototype.setHideToolbar=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("HideToolbar"),r)},t.prototype.setHideMenubar=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("HideMenubar"),r)},t.prototype.setHideWindowUI=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("HideWindowUI"),r)},t.prototype.setFitWindow=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("FitWindow"),r)},t.prototype.setCenterWindow=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("CenterWindow"),r)},t.prototype.setDisplayDocTitle=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("DisplayDocTitle"),r)},t.prototype.setNonFullScreenPageMode=function(e){assertIsOneOf(e,"nonFullScreenPageMode",NonFullScreenPageMode);var r=PDFName.of(e);this.dict.set(PDFName.of("NonFullScreenPageMode"),r)},t.prototype.setReadingDirection=function(e){assertIsOneOf(e,"readingDirection",ReadingDirection);var r=PDFName.of(e);this.dict.set(PDFName.of("Direction"),r)},t.prototype.setPrintScaling=function(e){assertIsOneOf(e,"printScaling",PrintScaling);var r=PDFName.of(e);this.dict.set(PDFName.of("PrintScaling"),r)},t.prototype.setDuplex=function(e){assertIsOneOf(e,"duplex",Duplex);var r=PDFName.of(e);this.dict.set(PDFName.of("Duplex"),r)},t.prototype.setPickTrayByPDFSize=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("PickTrayByPDFSize"),r)},t.prototype.setPrintPageRange=function(e){Array.isArray(e)||(e=[e]);for(var r=[],n=0,a=e.length;n<a;n++)r.push(e[n].start),r.push(e[n].end);assertEachIs(r,"printPageRange",["number"]);var s=this.dict.context.obj(r);this.dict.set(PDFName.of("PrintPageRange"),s)},t.prototype.setNumCopies=function(e){assertRange(e,"numCopies",1,Number.MAX_VALUE),assertInteger(e,"numCopies");var r=this.dict.context.obj(e);this.dict.set(PDFName.of("NumCopies"),r)},t.fromDict=function(e){return new t(e)},t.create=function(e){var r=e.obj({});return new t(r)},t}(),tfRegex$1=/\/([^\0\t\n\f\r\ ]+)[\0\t\n\f\r\ ]*(\d*\.\d+|\d+)?[\0\t\n\f\r\ ]+Tf/,PDFAcroField=function(){function t(e,r){this.dict=e,this.ref=r}return t.prototype.T=function(){return this.dict.lookupMaybe(PDFName.of("T"),PDFString,PDFHexString)},t.prototype.Ff=function(){var e=this.getInheritableAttribute(PDFName.of("Ff"));return this.dict.context.lookupMaybe(e,PDFNumber)},t.prototype.V=function(){var e=this.getInheritableAttribute(PDFName.of("V"));return this.dict.context.lookup(e)},t.prototype.Kids=function(){return this.dict.lookupMaybe(PDFName.of("Kids"),PDFArray)},t.prototype.DA=function(){var e=this.dict.lookup(PDFName.of("DA"));if(e instanceof PDFString||e instanceof PDFHexString)return e},t.prototype.setKids=function(e){this.dict.set(PDFName.of("Kids"),this.dict.context.obj(e))},t.prototype.getParent=function(){var e=this.dict.get(PDFName.of("Parent"));if(e instanceof PDFRef){var r=this.dict.lookup(PDFName.of("Parent"),PDFDict);return new t(r,e)}},t.prototype.setParent=function(e){e?this.dict.set(PDFName.of("Parent"),e):this.dict.delete(PDFName.of("Parent"))},t.prototype.getFullyQualifiedName=function(){var e=this.getParent();return e?e.getFullyQualifiedName()+"."+this.getPartialName():this.getPartialName()},t.prototype.getPartialName=function(){var e;return(e=this.T())===null||e===void 0?void 0:e.decodeText()},t.prototype.setPartialName=function(e){e?this.dict.set(PDFName.of("T"),PDFHexString.fromText(e)):this.dict.delete(PDFName.of("T"))},t.prototype.setDefaultAppearance=function(e){this.dict.set(PDFName.of("DA"),PDFString.of(e))},t.prototype.getDefaultAppearance=function(){var e=this.DA();return e instanceof PDFHexString?e.decodeText():e==null?void 0:e.asString()},t.prototype.setFontSize=function(e){var r,n=(r=this.getFullyQualifiedName())!==null&&r!==void 0?r:"",a=this.getDefaultAppearance();if(!a)throw new MissingDAEntryError(n);var s=findLastMatch(a,tfRegex$1);if(!s.match)throw new MissingTfOperatorError(n);var o=a.slice(0,s.pos-s.match[0].length),h=s.pos<=a.length?a.slice(s.pos):"",d=s.match[1],l=o+" /"+d+" "+e+" Tf "+h;this.setDefaultAppearance(l)},t.prototype.getFlags=function(){var e,r;return(r=(e=this.Ff())===null||e===void 0?void 0:e.asNumber())!==null&&r!==void 0?r:0},t.prototype.setFlags=function(e){this.dict.set(PDFName.of("Ff"),PDFNumber.of(e))},t.prototype.hasFlag=function(e){var r=this.getFlags();return(r&e)!==0},t.prototype.setFlag=function(e){var r=this.getFlags();this.setFlags(r|e)},t.prototype.clearFlag=function(e){var r=this.getFlags();this.setFlags(r&~e)},t.prototype.setFlagTo=function(e,r){r?this.setFlag(e):this.clearFlag(e)},t.prototype.getInheritableAttribute=function(e){var r;return this.ascend(function(n){r||(r=n.dict.get(e))}),r},t.prototype.ascend=function(e){e(this);var r=this.getParent();r&&r.ascend(e)},t}(),BorderStyle=function(){function t(e){this.dict=e}return t.prototype.W=function(){var e=this.dict.lookup(PDFName.of("W"));if(e instanceof PDFNumber)return e},t.prototype.getWidth=function(){var e,r;return(r=(e=this.W())===null||e===void 0?void 0:e.asNumber())!==null&&r!==void 0?r:1},t.prototype.setWidth=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("W"),r)},t.fromDict=function(e){return new t(e)},t}(),PDFAnnotation=function(){function t(e){this.dict=e}return t.prototype.Rect=function(){return this.dict.lookup(PDFName.of("Rect"),PDFArray)},t.prototype.AP=function(){return this.dict.lookupMaybe(PDFName.of("AP"),PDFDict)},t.prototype.F=function(){var e=this.dict.lookup(PDFName.of("F"));return this.dict.context.lookupMaybe(e,PDFNumber)},t.prototype.getRectangle=function(){var e,r=this.Rect();return(e=r==null?void 0:r.asRectangle())!==null&&e!==void 0?e:{x:0,y:0,width:0,height:0}},t.prototype.setRectangle=function(e){var r=e.x,n=e.y,a=e.width,s=e.height,o=this.dict.context.obj([r,n,r+a,n+s]);this.dict.set(PDFName.of("Rect"),o)},t.prototype.getAppearanceState=function(){var e=this.dict.lookup(PDFName.of("AS"));if(e instanceof PDFName)return e},t.prototype.setAppearanceState=function(e){this.dict.set(PDFName.of("AS"),e)},t.prototype.setAppearances=function(e){this.dict.set(PDFName.of("AP"),e)},t.prototype.ensureAP=function(){var e=this.AP();return e||(e=this.dict.context.obj({}),this.dict.set(PDFName.of("AP"),e)),e},t.prototype.getNormalAppearance=function(){var e=this.ensureAP(),r=e.get(PDFName.of("N"));if(r instanceof PDFRef||r instanceof PDFDict)return r;throw new Error("Unexpected N type: "+(r==null?void 0:r.constructor.name))},t.prototype.setNormalAppearance=function(e){var r=this.ensureAP();r.set(PDFName.of("N"),e)},t.prototype.setRolloverAppearance=function(e){var r=this.ensureAP();r.set(PDFName.of("R"),e)},t.prototype.setDownAppearance=function(e){var r=this.ensureAP();r.set(PDFName.of("D"),e)},t.prototype.removeRolloverAppearance=function(){var e=this.AP();e==null||e.delete(PDFName.of("R"))},t.prototype.removeDownAppearance=function(){var e=this.AP();e==null||e.delete(PDFName.of("D"))},t.prototype.getAppearances=function(){var e=this.AP();if(e){var r=e.lookup(PDFName.of("N"),PDFDict,PDFStream),n=e.lookupMaybe(PDFName.of("R"),PDFDict,PDFStream),a=e.lookupMaybe(PDFName.of("D"),PDFDict,PDFStream);return{normal:r,rollover:n,down:a}}},t.prototype.getFlags=function(){var e,r;return(r=(e=this.F())===null||e===void 0?void 0:e.asNumber())!==null&&r!==void 0?r:0},t.prototype.setFlags=function(e){this.dict.set(PDFName.of("F"),PDFNumber.of(e))},t.prototype.hasFlag=function(e){var r=this.getFlags();return(r&e)!==0},t.prototype.setFlag=function(e){var r=this.getFlags();this.setFlags(r|e)},t.prototype.clearFlag=function(e){var r=this.getFlags();this.setFlags(r&~e)},t.prototype.setFlagTo=function(e,r){r?this.setFlag(e):this.clearFlag(e)},t.fromDict=function(e){return new t(e)},t}(),AppearanceCharacteristics=function(){function t(e){this.dict=e}return t.prototype.R=function(){var e=this.dict.lookup(PDFName.of("R"));if(e instanceof PDFNumber)return e},t.prototype.BC=function(){var e=this.dict.lookup(PDFName.of("BC"));if(e instanceof PDFArray)return e},t.prototype.BG=function(){var e=this.dict.lookup(PDFName.of("BG"));if(e instanceof PDFArray)return e},t.prototype.CA=function(){var e=this.dict.lookup(PDFName.of("CA"));if(e instanceof PDFHexString||e instanceof PDFString)return e},t.prototype.RC=function(){var e=this.dict.lookup(PDFName.of("RC"));if(e instanceof PDFHexString||e instanceof PDFString)return e},t.prototype.AC=function(){var e=this.dict.lookup(PDFName.of("AC"));if(e instanceof PDFHexString||e instanceof PDFString)return e},t.prototype.getRotation=function(){var e;return(e=this.R())===null||e===void 0?void 0:e.asNumber()},t.prototype.getBorderColor=function(){var e=this.BC();if(e){for(var r=[],n=0,a=e==null?void 0:e.size();n<a;n++){var s=e.get(n);s instanceof PDFNumber&&r.push(s.asNumber())}return r}},t.prototype.getBackgroundColor=function(){var e=this.BG();if(e){for(var r=[],n=0,a=e==null?void 0:e.size();n<a;n++){var s=e.get(n);s instanceof PDFNumber&&r.push(s.asNumber())}return r}},t.prototype.getCaptions=function(){var e=this.CA(),r=this.RC(),n=this.AC();return{normal:e==null?void 0:e.decodeText(),rollover:r==null?void 0:r.decodeText(),down:n==null?void 0:n.decodeText()}},t.prototype.setRotation=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("R"),r)},t.prototype.setBorderColor=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("BC"),r)},t.prototype.setBackgroundColor=function(e){var r=this.dict.context.obj(e);this.dict.set(PDFName.of("BG"),r)},t.prototype.setCaptions=function(e){var r=PDFHexString.fromText(e.normal);if(this.dict.set(PDFName.of("CA"),r),e.rollover){var n=PDFHexString.fromText(e.rollover);this.dict.set(PDFName.of("RC"),n)}else this.dict.delete(PDFName.of("RC"));if(e.down){var a=PDFHexString.fromText(e.down);this.dict.set(PDFName.of("AC"),a)}else this.dict.delete(PDFName.of("AC"))},t.fromDict=function(e){return new t(e)},t}(),PDFWidgetAnnotation=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.MK=function(){var r=this.dict.lookup(PDFName.of("MK"));if(r instanceof PDFDict)return r},e.prototype.BS=function(){var r=this.dict.lookup(PDFName.of("BS"));if(r instanceof PDFDict)return r},e.prototype.DA=function(){var r=this.dict.lookup(PDFName.of("DA"));if(r instanceof PDFString||r instanceof PDFHexString)return r},e.prototype.P=function(){var r=this.dict.get(PDFName.of("P"));if(r instanceof PDFRef)return r},e.prototype.setP=function(r){this.dict.set(PDFName.of("P"),r)},e.prototype.setDefaultAppearance=function(r){this.dict.set(PDFName.of("DA"),PDFString.of(r))},e.prototype.getDefaultAppearance=function(){var r=this.DA();return r instanceof PDFHexString?r.decodeText():r==null?void 0:r.asString()},e.prototype.getAppearanceCharacteristics=function(){var r=this.MK();if(r)return AppearanceCharacteristics.fromDict(r)},e.prototype.getOrCreateAppearanceCharacteristics=function(){var r=this.MK();if(r)return AppearanceCharacteristics.fromDict(r);var n=AppearanceCharacteristics.fromDict(this.dict.context.obj({}));return this.dict.set(PDFName.of("MK"),n.dict),n},e.prototype.getBorderStyle=function(){var r=this.BS();if(r)return BorderStyle.fromDict(r)},e.prototype.getOrCreateBorderStyle=function(){var r=this.BS();if(r)return BorderStyle.fromDict(r);var n=BorderStyle.fromDict(this.dict.context.obj({}));return this.dict.set(PDFName.of("BS"),n.dict),n},e.prototype.getOnValue=function(){var r,n=(r=this.getAppearances())===null||r===void 0?void 0:r.normal;if(n instanceof PDFDict)for(var a=n.keys(),s=0,o=a.length;s<o;s++){var h=a[s];if(h!==PDFName.of("Off"))return h}},e.fromDict=function(r){return new e(r)},e.create=function(r,n){var a=r.obj({Type:"Annot",Subtype:"Widget",Rect:[0,0,0,0],Parent:n});return new e(a)},e}(PDFAnnotation),PDFAcroTerminal=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.FT=function(){var r=this.getInheritableAttribute(PDFName.of("FT"));return this.dict.context.lookup(r,PDFName)},e.prototype.getWidgets=function(){var r=this.Kids();if(!r)return[PDFWidgetAnnotation.fromDict(this.dict)];for(var n=new Array(r.size()),a=0,s=r.size();a<s;a++){var o=r.lookup(a,PDFDict);n[a]=PDFWidgetAnnotation.fromDict(o)}return n},e.prototype.addWidget=function(r){var n=this.normalizedEntries().Kids;n.push(r)},e.prototype.removeWidget=function(r){var n=this.Kids();if(n){if(r<0||r>n.size())throw new IndexOutOfBoundsError(r,0,n.size());n.remove(r)}else{if(r!==0)throw new IndexOutOfBoundsError(r,0,0);this.setKids([])}},e.prototype.normalizedEntries=function(){var r=this.Kids();return r||(r=this.dict.context.obj([this.ref]),this.dict.set(PDFName.of("Kids"),r)),{Kids:r}},e.fromDict=function(r,n){return new e(r,n)},e}(PDFAcroField),PDFAcroButton=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.Opt=function(){return this.dict.lookupMaybe(PDFName.of("Opt"),PDFString,PDFHexString,PDFArray)},e.prototype.setOpt=function(r){this.dict.set(PDFName.of("Opt"),this.dict.context.obj(r))},e.prototype.getExportValues=function(){var r=this.Opt();if(r){if(r instanceof PDFString||r instanceof PDFHexString)return[r];for(var n=[],a=0,s=r.size();a<s;a++){var o=r.lookup(a);(o instanceof PDFString||o instanceof PDFHexString)&&n.push(o)}return n}},e.prototype.removeExportValue=function(r){var n=this.Opt();if(n)if(n instanceof PDFString||n instanceof PDFHexString){if(r!==0)throw new IndexOutOfBoundsError(r,0,0);this.setOpt([])}else{if(r<0||r>n.size())throw new IndexOutOfBoundsError(r,0,n.size());n.remove(r)}},e.prototype.normalizeExportValues=function(){for(var r,n,a,s,o=(r=this.getExportValues())!==null&&r!==void 0?r:[],h=[],d=this.getWidgets(),l=0,u=d.length;l<u;l++){var p=d[l],g=(n=o[l])!==null&&n!==void 0?n:PDFHexString.fromText((s=(a=p.getOnValue())===null||a===void 0?void 0:a.decodeText())!==null&&s!==void 0?s:"");h.push(g)}this.setOpt(h)},e.prototype.addOpt=function(r,n){var a;this.normalizeExportValues();var s=r.decodeText(),o;if(n)for(var h=(a=this.getExportValues())!==null&&a!==void 0?a:[],d=0,l=h.length;d<l;d++){var u=h[d];u.decodeText()===s&&(o=d)}var p=this.Opt();return p.push(r),o??p.size()-1},e.prototype.addWidgetWithOpt=function(r,n,a){var s=this.addOpt(n,a),o=PDFName.of(String(s));return this.addWidget(r),o},e}(PDFAcroTerminal),PDFAcroCheckBox=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.setValue=function(r){var n,a=(n=this.getOnValue())!==null&&n!==void 0?n:PDFName.of("Yes");if(r!==a&&r!==PDFName.of("Off"))throw new InvalidAcroFieldValueError;this.dict.set(PDFName.of("V"),r);for(var s=this.getWidgets(),o=0,h=s.length;o<h;o++){var d=s[o],l=d.getOnValue()===r?r:PDFName.of("Off");d.setAppearanceState(l)}},e.prototype.getValue=function(){var r=this.V();return r instanceof PDFName?r:PDFName.of("Off")},e.prototype.getOnValue=function(){var r=this.getWidgets()[0];return r==null?void 0:r.getOnValue()},e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Btn",Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroButton),flag$1=function(t){return 1<<t},AcroFieldFlags;(function(t){t[t.ReadOnly=flag$1(0)]="ReadOnly",t[t.Required=flag$1(1)]="Required",t[t.NoExport=flag$1(2)]="NoExport"})(AcroFieldFlags||(AcroFieldFlags={}));var AcroButtonFlags;(function(t){t[t.NoToggleToOff=flag$1(14)]="NoToggleToOff",t[t.Radio=flag$1(15)]="Radio",t[t.PushButton=flag$1(16)]="PushButton",t[t.RadiosInUnison=flag$1(25)]="RadiosInUnison"})(AcroButtonFlags||(AcroButtonFlags={}));var AcroTextFlags;(function(t){t[t.Multiline=flag$1(12)]="Multiline",t[t.Password=flag$1(13)]="Password",t[t.FileSelect=flag$1(20)]="FileSelect",t[t.DoNotSpellCheck=flag$1(22)]="DoNotSpellCheck",t[t.DoNotScroll=flag$1(23)]="DoNotScroll",t[t.Comb=flag$1(24)]="Comb",t[t.RichText=flag$1(25)]="RichText"})(AcroTextFlags||(AcroTextFlags={}));var AcroChoiceFlags;(function(t){t[t.Combo=flag$1(17)]="Combo",t[t.Edit=flag$1(18)]="Edit",t[t.Sort=flag$1(19)]="Sort",t[t.MultiSelect=flag$1(21)]="MultiSelect",t[t.DoNotSpellCheck=flag$1(22)]="DoNotSpellCheck",t[t.CommitOnSelChange=flag$1(26)]="CommitOnSelChange"})(AcroChoiceFlags||(AcroChoiceFlags={}));var PDFAcroChoice=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.setValues=function(r){if(this.hasFlag(AcroChoiceFlags.Combo)&&!this.hasFlag(AcroChoiceFlags.Edit)&&!this.valuesAreValid(r))throw new InvalidAcroFieldValueError;if(r.length===0&&this.dict.delete(PDFName.of("V")),r.length===1&&this.dict.set(PDFName.of("V"),r[0]),r.length>1){if(!this.hasFlag(AcroChoiceFlags.MultiSelect))throw new MultiSelectValueError;this.dict.set(PDFName.of("V"),this.dict.context.obj(r))}this.updateSelectedIndices(r)},e.prototype.valuesAreValid=function(r){for(var n=this.getOptions(),a=function(d,l){var u=r[d].decodeText();if(!n.find(function(p){return u===(p.display||p.value).decodeText()}))return{value:!1}},s=0,o=r.length;s<o;s++){var h=a(s);if(typeof h=="object")return h.value}return!0},e.prototype.updateSelectedIndices=function(r){if(r.length>1){for(var n=new Array(r.length),a=this.getOptions(),s=function(d,l){var u=r[d].decodeText();n[d]=a.findIndex(function(p){return u===(p.display||p.value).decodeText()})},o=0,h=r.length;o<h;o++)s(o,h);this.dict.set(PDFName.of("I"),this.dict.context.obj(n.sort()))}else this.dict.delete(PDFName.of("I"))},e.prototype.getValues=function(){var r=this.V();if(r instanceof PDFString||r instanceof PDFHexString)return[r];if(r instanceof PDFArray){for(var n=[],a=0,s=r.size();a<s;a++){var o=r.lookup(a);(o instanceof PDFString||o instanceof PDFHexString)&&n.push(o)}return n}return[]},e.prototype.Opt=function(){return this.dict.lookupMaybe(PDFName.of("Opt"),PDFString,PDFHexString,PDFArray)},e.prototype.setOptions=function(r){for(var n=new Array(r.length),a=0,s=r.length;a<s;a++){var o=r[a],h=o.value,d=o.display;n[a]=this.dict.context.obj([h,d||h])}this.dict.set(PDFName.of("Opt"),this.dict.context.obj(n))},e.prototype.getOptions=function(){var r=this.Opt();if(r instanceof PDFString||r instanceof PDFHexString)return[{value:r,display:r}];if(r instanceof PDFArray){for(var n=[],a=0,s=r.size();a<s;a++){var o=r.lookup(a);if((o instanceof PDFString||o instanceof PDFHexString)&&n.push({value:o,display:o}),o instanceof PDFArray&&o.size()>0){var h=o.lookup(0,PDFString,PDFHexString),d=o.lookupMaybe(1,PDFString,PDFHexString);n.push({value:h,display:d||h})}}return n}return[]},e}(PDFAcroTerminal),PDFAcroComboBox=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Ch",Ff:AcroChoiceFlags.Combo,Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroChoice),PDFAcroNonTerminal=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.addField=function(r){var n=this.normalizedEntries().Kids;n==null||n.push(r)},e.prototype.normalizedEntries=function(){var r=this.Kids();return r||(r=this.dict.context.obj([]),this.dict.set(PDFName.of("Kids"),r)),{Kids:r}},e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({}),a=r.register(n);return new e(n,a)},e}(PDFAcroField),PDFAcroSignature=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.fromDict=function(r,n){return new e(r,n)},e}(PDFAcroTerminal),PDFAcroText=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.MaxLen=function(){var r=this.dict.lookup(PDFName.of("MaxLen"));if(r instanceof PDFNumber)return r},e.prototype.Q=function(){var r=this.dict.lookup(PDFName.of("Q"));if(r instanceof PDFNumber)return r},e.prototype.setMaxLength=function(r){this.dict.set(PDFName.of("MaxLen"),PDFNumber.of(r))},e.prototype.removeMaxLength=function(){this.dict.delete(PDFName.of("MaxLen"))},e.prototype.getMaxLength=function(){var r;return(r=this.MaxLen())===null||r===void 0?void 0:r.asNumber()},e.prototype.setQuadding=function(r){this.dict.set(PDFName.of("Q"),PDFNumber.of(r))},e.prototype.getQuadding=function(){var r;return(r=this.Q())===null||r===void 0?void 0:r.asNumber()},e.prototype.setValue=function(r){this.dict.set(PDFName.of("V"),r)},e.prototype.removeValue=function(){this.dict.delete(PDFName.of("V"))},e.prototype.getValue=function(){var r=this.V();if(r instanceof PDFString||r instanceof PDFHexString)return r},e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Tx",Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroTerminal),PDFAcroPushButton=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Btn",Ff:AcroButtonFlags.PushButton,Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroButton),PDFAcroRadioButton=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.setValue=function(r){var n=this.getOnValues();if(!n.includes(r)&&r!==PDFName.of("Off"))throw new InvalidAcroFieldValueError;this.dict.set(PDFName.of("V"),r);for(var a=this.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s],d=h.getOnValue()===r?r:PDFName.of("Off");h.setAppearanceState(d)}},e.prototype.getValue=function(){var r=this.V();return r instanceof PDFName?r:PDFName.of("Off")},e.prototype.getOnValues=function(){for(var r=this.getWidgets(),n=[],a=0,s=r.length;a<s;a++){var o=r[a].getOnValue();o&&n.push(o)}return n},e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Btn",Ff:AcroButtonFlags.Radio,Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroButton),PDFAcroListBox=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.fromDict=function(r,n){return new e(r,n)},e.create=function(r){var n=r.obj({FT:"Ch",Kids:[]}),a=r.register(n);return new e(n,a)},e}(PDFAcroChoice),createPDFAcroFields=function(t){if(!t)return[];for(var e=[],r=0,n=t.size();r<n;r++){var a=t.get(r),s=t.lookup(r);a instanceof PDFRef&&s instanceof PDFDict&&e.push([createPDFAcroField(s,a),a])}return e},createPDFAcroField=function(t,e){var r=isNonTerminalAcroField(t);return r?PDFAcroNonTerminal.fromDict(t,e):createPDFAcroTerminal(t,e)},isNonTerminalAcroField=function(t){var e=t.lookup(PDFName.of("Kids"));if(e instanceof PDFArray)for(var r=0,n=e.size();r<n;r++){var a=e.lookup(r),s=a instanceof PDFDict&&a.has(PDFName.of("T"));if(s)return!0}return!1},createPDFAcroTerminal=function(t,e){var r=getInheritableAttribute(t,PDFName.of("FT")),n=t.context.lookup(r,PDFName);return n===PDFName.of("Btn")?createPDFAcroButton(t,e):n===PDFName.of("Ch")?createPDFAcroChoice(t,e):n===PDFName.of("Tx")?PDFAcroText.fromDict(t,e):n===PDFName.of("Sig")?PDFAcroSignature.fromDict(t,e):PDFAcroTerminal.fromDict(t,e)},createPDFAcroButton=function(t,e){var r,n=getInheritableAttribute(t,PDFName.of("Ff")),a=t.context.lookupMaybe(n,PDFNumber),s=(r=a==null?void 0:a.asNumber())!==null&&r!==void 0?r:0;return flagIsSet(s,AcroButtonFlags.PushButton)?PDFAcroPushButton.fromDict(t,e):flagIsSet(s,AcroButtonFlags.Radio)?PDFAcroRadioButton.fromDict(t,e):PDFAcroCheckBox.fromDict(t,e)},createPDFAcroChoice=function(t,e){var r,n=getInheritableAttribute(t,PDFName.of("Ff")),a=t.context.lookupMaybe(n,PDFNumber),s=(r=a==null?void 0:a.asNumber())!==null&&r!==void 0?r:0;return flagIsSet(s,AcroChoiceFlags.Combo)?PDFAcroComboBox.fromDict(t,e):PDFAcroListBox.fromDict(t,e)},flagIsSet=function(t,e){return(t&e)!==0},getInheritableAttribute=function(t,e){var r;return ascend(t,function(n){r||(r=n.get(e))}),r},ascend=function(t,e){e(t);var r=t.lookupMaybe(PDFName.of("Parent"),PDFDict);r&&ascend(r,e)},PDFAcroForm=function(){function t(e){this.dict=e}return t.prototype.Fields=function(){var e=this.dict.lookup(PDFName.of("Fields"));if(e instanceof PDFArray)return e},t.prototype.getFields=function(){for(var e=this.normalizedEntries().Fields,r=new Array(e.size()),n=0,a=e.size();n<a;n++){var s=e.get(n),o=e.lookup(n,PDFDict);r[n]=[createPDFAcroField(o,s),s]}return r},t.prototype.getAllFields=function(){var e=[],r=function(n){if(n)for(var a=0,s=n.length;a<s;a++){var o=n[a];e.push(o);var h=o[0];h instanceof PDFAcroNonTerminal&&r(createPDFAcroFields(h.Kids()))}};return r(this.getFields()),e},t.prototype.addField=function(e){var r=this.normalizedEntries().Fields;r==null||r.push(e)},t.prototype.removeField=function(e){var r=e.getParent(),n=r===void 0?this.normalizedEntries().Fields:r.Kids(),a=n==null?void 0:n.indexOf(e.ref);if(n===void 0||a===void 0)throw new Error("Tried to remove inexistent field "+e.getFullyQualifiedName());n.remove(a),r!==void 0&&n.size()===0&&this.removeField(r)},t.prototype.normalizedEntries=function(){var e=this.Fields();return e||(e=this.dict.context.obj([]),this.dict.set(PDFName.of("Fields"),e)),{Fields:e}},t.fromDict=function(e){return new t(e)},t.create=function(e){var r=e.obj({Fields:[]});return new t(r)},t}(),PDFCatalog=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.Pages=function(){return this.lookup(PDFName.of("Pages"),PDFDict)},e.prototype.AcroForm=function(){return this.lookupMaybe(PDFName.of("AcroForm"),PDFDict)},e.prototype.getAcroForm=function(){var r=this.AcroForm();if(r)return PDFAcroForm.fromDict(r)},e.prototype.getOrCreateAcroForm=function(){var r=this.getAcroForm();if(!r){r=PDFAcroForm.create(this.context);var n=this.context.register(r.dict);this.set(PDFName.of("AcroForm"),n)}return r},e.prototype.ViewerPreferences=function(){return this.lookupMaybe(PDFName.of("ViewerPreferences"),PDFDict)},e.prototype.getViewerPreferences=function(){var r=this.ViewerPreferences();if(r)return ViewerPreferences.fromDict(r)},e.prototype.getOrCreateViewerPreferences=function(){var r=this.getViewerPreferences();if(!r){r=ViewerPreferences.create(this.context);var n=this.context.register(r.dict);this.set(PDFName.of("ViewerPreferences"),n)}return r},e.prototype.insertLeafNode=function(r,n){var a=this.get(PDFName.of("Pages")),s=this.Pages().insertLeafNode(r,n);return s||a},e.prototype.removeLeafNode=function(r){this.Pages().removeLeafNode(r)},e.withContextAndPages=function(r,n){var a=new Map;return a.set(PDFName.of("Type"),PDFName.of("Catalog")),a.set(PDFName.of("Pages"),n),new e(a,r)},e.fromMapWithContext=function(r,n){return new e(r,n)},e}(PDFDict),PDFPageTree=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.Parent=function(){return this.lookup(PDFName.of("Parent"))},e.prototype.Kids=function(){return this.lookup(PDFName.of("Kids"),PDFArray)},e.prototype.Count=function(){return this.lookup(PDFName.of("Count"),PDFNumber)},e.prototype.pushTreeNode=function(r){var n=this.Kids();n.push(r)},e.prototype.pushLeafNode=function(r){var n=this.Kids();this.insertLeafKid(n.size(),r)},e.prototype.insertLeafNode=function(r,n){var a=this.Kids(),s=this.Count().asNumber();if(n>s)throw new InvalidTargetIndexError(n,s);for(var o=n,h=0,d=a.size();h<d;h++){if(o===0){this.insertLeafKid(h,r);return}var l=a.get(h),u=this.context.lookup(l);if(u instanceof e){if(u.Count().asNumber()>o)return u.insertLeafNode(r,o)||l;o-=u.Count().asNumber()}u instanceof PDFPageLeaf&&(o-=1)}if(o===0){this.insertLeafKid(a.size(),r);return}throw new CorruptPageTreeError(n,"insertLeafNode")},e.prototype.removeLeafNode=function(r,n){n===void 0&&(n=!0);var a=this.Kids(),s=this.Count().asNumber();if(r>=s)throw new InvalidTargetIndexError(r,s);for(var o=r,h=0,d=a.size();h<d;h++){var l=a.get(h),u=this.context.lookup(l);if(u instanceof e)if(u.Count().asNumber()>o){u.removeLeafNode(o,n),n&&u.Kids().size()===0&&a.remove(h);return}else o-=u.Count().asNumber();if(u instanceof PDFPageLeaf)if(o===0){this.removeKid(h);return}else o-=1}throw new CorruptPageTreeError(r,"removeLeafNode")},e.prototype.ascend=function(r){r(this);var n=this.Parent();n&&n.ascend(r)},e.prototype.traverse=function(r){for(var n=this.Kids(),a=0,s=n.size();a<s;a++){var o=n.get(a),h=this.context.lookup(o);h instanceof e&&h.traverse(r),r(h,o)}},e.prototype.insertLeafKid=function(r,n){var a=this.Kids();this.ascend(function(s){var o=s.Count().asNumber()+1;s.set(PDFName.of("Count"),PDFNumber.of(o))}),a.insert(r,n)},e.prototype.removeKid=function(r){var n=this.Kids(),a=n.lookup(r);a instanceof PDFPageLeaf&&this.ascend(function(s){var o=s.Count().asNumber()-1;s.set(PDFName.of("Count"),PDFNumber.of(o))}),n.remove(r)},e.withContext=function(r,n){var a=new Map;return a.set(PDFName.of("Type"),PDFName.of("Pages")),a.set(PDFName.of("Kids"),r.obj([])),a.set(PDFName.of("Count"),r.obj(0)),n&&a.set(PDFName.of("Parent"),n),new e(a,r)},e.fromMapWithContext=function(r,n){return new e(r,n)},e}(PDFDict),IsDigit=new Uint8Array(256);IsDigit[CharCodes.Zero]=1,IsDigit[CharCodes.One]=1,IsDigit[CharCodes.Two]=1,IsDigit[CharCodes.Three]=1,IsDigit[CharCodes.Four]=1,IsDigit[CharCodes.Five]=1,IsDigit[CharCodes.Six]=1,IsDigit[CharCodes.Seven]=1,IsDigit[CharCodes.Eight]=1,IsDigit[CharCodes.Nine]=1;var IsNumericPrefix=new Uint8Array(256);IsNumericPrefix[CharCodes.Period]=1,IsNumericPrefix[CharCodes.Plus]=1,IsNumericPrefix[CharCodes.Minus]=1;for(var IsNumeric=new Uint8Array(256),idx=0,len=256;idx<len;idx++)IsNumeric[idx]=IsDigit[idx]||IsNumericPrefix[idx]?1:0;var Newline$1=CharCodes.Newline,CarriageReturn$1=CharCodes.CarriageReturn,BaseParser=function(){function t(e,r){r===void 0&&(r=!1),this.bytes=e,this.capNumbers=r}return t.prototype.parseRawInt=function(){for(var e="";!this.bytes.done();){var r=this.bytes.peek();if(!IsDigit[r])break;e+=charFromCode(this.bytes.next())}var n=Number(e);if(!e||!isFinite(n))throw new NumberParsingError(this.bytes.position(),e);return n},t.prototype.parseRawNumber=function(){for(var e="";!this.bytes.done();){var r=this.bytes.peek();if(!IsNumeric[r]||(e+=charFromCode(this.bytes.next()),r===CharCodes.Period))break}for(;!this.bytes.done();){var r=this.bytes.peek();if(!IsDigit[r])break;e+=charFromCode(this.bytes.next())}var n=Number(e);if(!e||!isFinite(n))throw new NumberParsingError(this.bytes.position(),e);if(n>Number.MAX_SAFE_INTEGER)if(this.capNumbers){var a="Parsed number that is too large for some PDF readers: "+e+", using Number.MAX_SAFE_INTEGER instead.";return console.warn(a),Number.MAX_SAFE_INTEGER}else{var a="Parsed number that is too large for some PDF readers: "+e+", not capping.";console.warn(a)}return n},t.prototype.skipWhitespace=function(){for(;!this.bytes.done()&&IsWhitespace[this.bytes.peek()];)this.bytes.next()},t.prototype.skipLine=function(){for(;!this.bytes.done();){var e=this.bytes.peek();if(e===Newline$1||e===CarriageReturn$1)return;this.bytes.next()}},t.prototype.skipComment=function(){if(this.bytes.peek()!==CharCodes.Percent)return!1;for(;!this.bytes.done();){var e=this.bytes.peek();if(e===Newline$1||e===CarriageReturn$1)return!0;this.bytes.next()}return!0},t.prototype.skipWhitespaceAndComments=function(){for(this.skipWhitespace();this.skipComment();)this.skipWhitespace()},t.prototype.matchKeyword=function(e){for(var r=this.bytes.offset(),n=0,a=e.length;n<a;n++)if(this.bytes.done()||this.bytes.next()!==e[n])return this.bytes.moveTo(r),!1;return!0},t}(),ByteStream=function(){function t(e){this.idx=0,this.line=0,this.column=0,this.bytes=e,this.length=this.bytes.length}return t.prototype.moveTo=function(e){this.idx=e},t.prototype.next=function(){var e=this.bytes[this.idx++];return e===CharCodes.Newline?(this.line+=1,this.column=0):this.column+=1,e},t.prototype.assertNext=function(e){if(this.peek()!==e)throw new NextByteAssertionError(this.position(),e,this.peek());return this.next()},t.prototype.peek=function(){return this.bytes[this.idx]},t.prototype.peekAhead=function(e){return this.bytes[this.idx+e]},t.prototype.peekAt=function(e){return this.bytes[e]},t.prototype.done=function(){return this.idx>=this.length},t.prototype.offset=function(){return this.idx},t.prototype.slice=function(e,r){return this.bytes.slice(e,r)},t.prototype.position=function(){return{line:this.line,column:this.column,offset:this.idx}},t.of=function(e){return new t(e)},t.fromPDFRawStream=function(e){return t.of(decodePDFRawStream(e).decode())},t}(),Space=CharCodes.Space,CarriageReturn=CharCodes.CarriageReturn,Newline=CharCodes.Newline,stream=[CharCodes.s,CharCodes.t,CharCodes.r,CharCodes.e,CharCodes.a,CharCodes.m],endstream=[CharCodes.e,CharCodes.n,CharCodes.d,CharCodes.s,CharCodes.t,CharCodes.r,CharCodes.e,CharCodes.a,CharCodes.m],Keywords={header:[CharCodes.Percent,CharCodes.P,CharCodes.D,CharCodes.F,CharCodes.Dash],eof:[CharCodes.Percent,CharCodes.Percent,CharCodes.E,CharCodes.O,CharCodes.F],obj:[CharCodes.o,CharCodes.b,CharCodes.j],endobj:[CharCodes.e,CharCodes.n,CharCodes.d,CharCodes.o,CharCodes.b,CharCodes.j],xref:[CharCodes.x,CharCodes.r,CharCodes.e,CharCodes.f],trailer:[CharCodes.t,CharCodes.r,CharCodes.a,CharCodes.i,CharCodes.l,CharCodes.e,CharCodes.r],startxref:[CharCodes.s,CharCodes.t,CharCodes.a,CharCodes.r,CharCodes.t,CharCodes.x,CharCodes.r,CharCodes.e,CharCodes.f],true:[CharCodes.t,CharCodes.r,CharCodes.u,CharCodes.e],false:[CharCodes.f,CharCodes.a,CharCodes.l,CharCodes.s,CharCodes.e],null:[CharCodes.n,CharCodes.u,CharCodes.l,CharCodes.l],stream,streamEOF1:__spreadArrays(stream,[Space,CarriageReturn,Newline]),streamEOF2:__spreadArrays(stream,[CarriageReturn,Newline]),streamEOF3:__spreadArrays(stream,[CarriageReturn]),streamEOF4:__spreadArrays(stream,[Newline]),endstream,EOF1endstream:__spreadArrays([CarriageReturn,Newline],endstream),EOF2endstream:__spreadArrays([CarriageReturn],endstream),EOF3endstream:__spreadArrays([Newline],endstream)},PDFObjectParser=function(t){__extends(e,t);function e(r,n,a){a===void 0&&(a=!1);var s=t.call(this,r,a)||this;return s.context=n,s}return e.prototype.parseObject=function(){if(this.skipWhitespaceAndComments(),this.matchKeyword(Keywords.true))return PDFBool.True;if(this.matchKeyword(Keywords.false))return PDFBool.False;if(this.matchKeyword(Keywords.null))return PDFNull;var r=this.bytes.peek();if(r===CharCodes.LessThan&&this.bytes.peekAhead(1)===CharCodes.LessThan)return this.parseDictOrStream();if(r===CharCodes.LessThan)return this.parseHexString();if(r===CharCodes.LeftParen)return this.parseString();if(r===CharCodes.ForwardSlash)return this.parseName();if(r===CharCodes.LeftSquareBracket)return this.parseArray();if(IsNumeric[r])return this.parseNumberOrRef();throw new PDFObjectParsingError(this.bytes.position(),r)},e.prototype.parseNumberOrRef=function(){var r=this.parseRawNumber();this.skipWhitespaceAndComments();var n=this.bytes.offset();if(IsDigit[this.bytes.peek()]){var a=this.parseRawNumber();if(this.skipWhitespaceAndComments(),this.bytes.peek()===CharCodes.R)return this.bytes.assertNext(CharCodes.R),PDFRef.of(r,a)}return this.bytes.moveTo(n),PDFNumber.of(r)},e.prototype.parseHexString=function(){var r="";for(this.bytes.assertNext(CharCodes.LessThan);!this.bytes.done()&&this.bytes.peek()!==CharCodes.GreaterThan;)r+=charFromCode(this.bytes.next());return this.bytes.assertNext(CharCodes.GreaterThan),PDFHexString.of(r)},e.prototype.parseString=function(){for(var r=0,n=!1,a="";!this.bytes.done();){var s=this.bytes.next();if(a+=charFromCode(s),n||(s===CharCodes.LeftParen&&(r+=1),s===CharCodes.RightParen&&(r-=1)),s===CharCodes.BackSlash?n=!n:n&&(n=!1),r===0)return PDFString.of(a.substring(1,a.length-1))}throw new UnbalancedParenthesisError(this.bytes.position())},e.prototype.parseName=function(){this.bytes.assertNext(CharCodes.ForwardSlash);for(var r="";!this.bytes.done();){var n=this.bytes.peek();if(IsWhitespace[n]||IsDelimiter[n])break;r+=charFromCode(n),this.bytes.next()}return PDFName.of(r)},e.prototype.parseArray=function(){this.bytes.assertNext(CharCodes.LeftSquareBracket),this.skipWhitespaceAndComments();for(var r=PDFArray.withContext(this.context);this.bytes.peek()!==CharCodes.RightSquareBracket;){var n=this.parseObject();r.push(n),this.skipWhitespaceAndComments()}return this.bytes.assertNext(CharCodes.RightSquareBracket),r},e.prototype.parseDict=function(){this.bytes.assertNext(CharCodes.LessThan),this.bytes.assertNext(CharCodes.LessThan),this.skipWhitespaceAndComments();for(var r=new Map;!this.bytes.done()&&this.bytes.peek()!==CharCodes.GreaterThan&&this.bytes.peekAhead(1)!==CharCodes.GreaterThan;){var n=this.parseName(),a=this.parseObject();r.set(n,a),this.skipWhitespaceAndComments()}this.skipWhitespaceAndComments(),this.bytes.assertNext(CharCodes.GreaterThan),this.bytes.assertNext(CharCodes.GreaterThan);var s=r.get(PDFName.of("Type"));return s===PDFName.of("Catalog")?PDFCatalog.fromMapWithContext(r,this.context):s===PDFName.of("Pages")?PDFPageTree.fromMapWithContext(r,this.context):s===PDFName.of("Page")?PDFPageLeaf.fromMapWithContext(r,this.context):PDFDict.fromMapWithContext(r,this.context)},e.prototype.parseDictOrStream=function(){var r=this.bytes.position(),n=this.parseDict();if(this.skipWhitespaceAndComments(),!this.matchKeyword(Keywords.streamEOF1)&&!this.matchKeyword(Keywords.streamEOF2)&&!this.matchKeyword(Keywords.streamEOF3)&&!this.matchKeyword(Keywords.streamEOF4)&&!this.matchKeyword(Keywords.stream))return n;var a=this.bytes.offset(),s,o=n.get(PDFName.of("Length"));o instanceof PDFNumber?(s=a+o.asNumber(),this.bytes.moveTo(s),this.skipWhitespaceAndComments(),this.matchKeyword(Keywords.endstream)||(this.bytes.moveTo(a),s=this.findEndOfStreamFallback(r))):s=this.findEndOfStreamFallback(r);var h=this.bytes.slice(a,s);return PDFRawStream.of(n,h)},e.prototype.findEndOfStreamFallback=function(r){for(var n=1,a=this.bytes.offset();!this.bytes.done()&&(a=this.bytes.offset(),this.matchKeyword(Keywords.stream)?n+=1:this.matchKeyword(Keywords.EOF1endstream)||this.matchKeyword(Keywords.EOF2endstream)||this.matchKeyword(Keywords.EOF3endstream)||this.matchKeyword(Keywords.endstream)?n-=1:this.bytes.next(),n!==0););if(n!==0)throw new PDFStreamParsingError(r);return a},e.forBytes=function(r,n,a){return new e(ByteStream.of(r),n,a)},e.forByteStream=function(r,n,a){return a===void 0&&(a=!1),new e(r,n,a)},e}(BaseParser),PDFObjectStreamParser=function(t){__extends(e,t);function e(r,n){var a=t.call(this,ByteStream.fromPDFRawStream(r),r.dict.context)||this,s=r.dict;return a.alreadyParsed=!1,a.shouldWaitForTick=n||function(){return!1},a.firstOffset=s.lookup(PDFName.of("First"),PDFNumber).asNumber(),a.objectCount=s.lookup(PDFName.of("N"),PDFNumber).asNumber(),a}return e.prototype.parseIntoContext=function(){return __awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h,d,l;return __generator(this,function(u){switch(u.label){case 0:if(this.alreadyParsed)throw new ReparseError("PDFObjectStreamParser","parseIntoContext");this.alreadyParsed=!0,r=this.parseOffsetsAndObjectNumbers(),n=0,a=r.length,u.label=1;case 1:return n<a?(s=r[n],o=s.objectNumber,h=s.offset,this.bytes.moveTo(this.firstOffset+h),d=this.parseObject(),l=PDFRef.of(o,0),this.context.assign(l,d),this.shouldWaitForTick()?[4,waitForTick()]:[3,3]):[3,4];case 2:u.sent(),u.label=3;case 3:return n++,[3,1];case 4:return[2]}})})},e.prototype.parseOffsetsAndObjectNumbers=function(){for(var r=[],n=0,a=this.objectCount;n<a;n++){this.skipWhitespaceAndComments();var s=this.parseRawInt();this.skipWhitespaceAndComments();var o=this.parseRawInt();r.push({objectNumber:s,offset:o})}return r},e.forStream=function(r,n){return new e(r,n)},e}(PDFObjectParser),PDFXRefStreamParser=function(){function t(e){this.alreadyParsed=!1,this.dict=e.dict,this.bytes=ByteStream.fromPDFRawStream(e),this.context=this.dict.context;var r=this.dict.lookup(PDFName.of("Size"),PDFNumber),n=this.dict.lookup(PDFName.of("Index"));if(n instanceof PDFArray){this.subsections=[];for(var a=0,s=n.size();a<s;a+=2){var o=n.lookup(a+0,PDFNumber).asNumber(),h=n.lookup(a+1,PDFNumber).asNumber();this.subsections.push({firstObjectNumber:o,length:h})}}else this.subsections=[{firstObjectNumber:0,length:r.asNumber()}];var d=this.dict.lookup(PDFName.of("W"),PDFArray);this.byteWidths=[-1,-1,-1];for(var a=0,s=d.size();a<s;a++)this.byteWidths[a]=d.lookup(a,PDFNumber).asNumber()}return t.prototype.parseIntoContext=function(){if(this.alreadyParsed)throw new ReparseError("PDFXRefStreamParser","parseIntoContext");this.alreadyParsed=!0,this.context.trailerInfo={Root:this.dict.get(PDFName.of("Root")),Encrypt:this.dict.get(PDFName.of("Encrypt")),Info:this.dict.get(PDFName.of("Info")),ID:this.dict.get(PDFName.of("ID"))};var e=this.parseEntries();return e},t.prototype.parseEntries=function(){for(var e=[],r=this.byteWidths,n=r[0],a=r[1],s=r[2],o=0,h=this.subsections.length;o<h;o++)for(var d=this.subsections[o],l=d.firstObjectNumber,u=d.length,p=0;p<u;p++){for(var g=0,f=0,v=n;f<v;f++)g=g<<8|this.bytes.next();for(var y=0,f=0,v=a;f<v;f++)y=y<<8|this.bytes.next();for(var S=0,f=0,v=s;f<v;f++)S=S<<8|this.bytes.next();n===0&&(g=1);var m=l+p,w={ref:PDFRef.of(m,S),offset:y,deleted:g===0,inObjectStream:g===2};e.push(w)}return e},t.forStream=function(e){return new t(e)},t}(),PDFParser=function(t){__extends(e,t);function e(r,n,a,s){n===void 0&&(n=1/0),a===void 0&&(a=!1),s===void 0&&(s=!1);var o=t.call(this,ByteStream.of(r),PDFContext.create(),s)||this;return o.alreadyParsed=!1,o.parsedObjects=0,o.shouldWaitForTick=function(){return o.parsedObjects+=1,o.parsedObjects%o.objectsPerTick===0},o.objectsPerTick=n,o.throwOnInvalidObject=a,o}return e.prototype.parseDocument=function(){return __awaiter(this,void 0,void 0,function(){var r,n;return __generator(this,function(a){switch(a.label){case 0:if(this.alreadyParsed)throw new ReparseError("PDFParser","parseDocument");this.alreadyParsed=!0,this.context.header=this.parseHeader(),a.label=1;case 1:return this.bytes.done()?[3,3]:[4,this.parseDocumentSection()];case 2:if(a.sent(),n=this.bytes.offset(),n===r)throw new StalledParserError(this.bytes.position());return r=n,[3,1];case 3:return this.maybeRecoverRoot(),this.context.lookup(PDFRef.of(0))&&(console.warn("Removing parsed object: 0 0 R"),this.context.delete(PDFRef.of(0))),[2,this.context]}})})},e.prototype.maybeRecoverRoot=function(){var r=function(u){return u instanceof PDFDict&&u.lookup(PDFName.of("Type"))===PDFName.of("Catalog")},n=this.context.lookup(this.context.trailerInfo.Root);if(!r(n))for(var a=this.context.enumerateIndirectObjects(),s=0,o=a.length;s<o;s++){var h=a[s],d=h[0],l=h[1];r(l)&&(this.context.trailerInfo.Root=d)}},e.prototype.parseHeader=function(){for(;!this.bytes.done();){if(this.matchKeyword(Keywords.header)){var r=this.parseRawInt();this.bytes.assertNext(CharCodes.Period);var n=this.parseRawInt(),a=PDFHeader.forVersion(r,n);return this.skipBinaryHeaderComment(),a}this.bytes.next()}throw new MissingPDFHeaderError(this.bytes.position())},e.prototype.parseIndirectObjectHeader=function(){this.skipWhitespaceAndComments();var r=this.parseRawInt();this.skipWhitespaceAndComments();var n=this.parseRawInt();if(this.skipWhitespaceAndComments(),!this.matchKeyword(Keywords.obj))throw new MissingKeywordError(this.bytes.position(),Keywords.obj);return PDFRef.of(r,n)},e.prototype.matchIndirectObjectHeader=function(){var r=this.bytes.offset();try{return this.parseIndirectObjectHeader(),!0}catch{return this.bytes.moveTo(r),!1}},e.prototype.parseIndirectObject=function(){return __awaiter(this,void 0,void 0,function(){var r,n;return __generator(this,function(a){switch(a.label){case 0:return r=this.parseIndirectObjectHeader(),this.skipWhitespaceAndComments(),n=this.parseObject(),this.skipWhitespaceAndComments(),this.matchKeyword(Keywords.endobj),n instanceof PDFRawStream&&n.dict.lookup(PDFName.of("Type"))===PDFName.of("ObjStm")?[4,PDFObjectStreamParser.forStream(n,this.shouldWaitForTick).parseIntoContext()]:[3,2];case 1:return a.sent(),[3,3];case 2:n instanceof PDFRawStream&&n.dict.lookup(PDFName.of("Type"))===PDFName.of("XRef")?PDFXRefStreamParser.forStream(n).parseIntoContext():this.context.assign(r,n),a.label=3;case 3:return[2,r]}})})},e.prototype.tryToParseInvalidIndirectObject=function(){var r=this.bytes.position(),n="Trying to parse invalid object: "+JSON.stringify(r)+")";if(this.throwOnInvalidObject)throw new Error(n);console.warn(n);var a=this.parseIndirectObjectHeader();console.warn("Invalid object ref: "+a),this.skipWhitespaceAndComments();for(var s=this.bytes.offset(),o=!0;!this.bytes.done()&&(this.matchKeyword(Keywords.endobj)&&(o=!1),!!o);)this.bytes.next();if(o)throw new PDFInvalidObjectParsingError(r);var h=this.bytes.offset()-Keywords.endobj.length,d=PDFInvalidObject.of(this.bytes.slice(s,h));return this.context.assign(a,d),a},e.prototype.parseIndirectObjects=function(){return __awaiter(this,void 0,void 0,function(){var r;return __generator(this,function(n){switch(n.label){case 0:this.skipWhitespaceAndComments(),n.label=1;case 1:if(!(!this.bytes.done()&&IsDigit[this.bytes.peek()]))return[3,8];r=this.bytes.offset(),n.label=2;case 2:return n.trys.push([2,4,,5]),[4,this.parseIndirectObject()];case 3:return n.sent(),[3,5];case 4:return n.sent(),this.bytes.moveTo(r),this.tryToParseInvalidIndirectObject(),[3,5];case 5:return this.skipWhitespaceAndComments(),this.skipJibberish(),this.shouldWaitForTick()?[4,waitForTick()]:[3,7];case 6:n.sent(),n.label=7;case 7:return[3,1];case 8:return[2]}})})},e.prototype.maybeParseCrossRefSection=function(){if(this.skipWhitespaceAndComments(),!!this.matchKeyword(Keywords.xref)){this.skipWhitespaceAndComments();for(var r=-1,n=PDFCrossRefSection.createEmpty();!this.bytes.done()&&IsDigit[this.bytes.peek()];){var a=this.parseRawInt();this.skipWhitespaceAndComments();var s=this.parseRawInt();this.skipWhitespaceAndComments();var o=this.bytes.peek();if(o===CharCodes.n||o===CharCodes.f){var h=PDFRef.of(r,s);this.bytes.next()===CharCodes.n?n.addEntry(h,a):n.addDeletedEntry(h,a),r+=1}else r=a;this.skipWhitespaceAndComments()}return n}},e.prototype.maybeParseTrailerDict=function(){if(this.skipWhitespaceAndComments(),!!this.matchKeyword(Keywords.trailer)){this.skipWhitespaceAndComments();var r=this.parseDict(),n=this.context;n.trailerInfo={Root:r.get(PDFName.of("Root"))||n.trailerInfo.Root,Encrypt:r.get(PDFName.of("Encrypt"))||n.trailerInfo.Encrypt,Info:r.get(PDFName.of("Info"))||n.trailerInfo.Info,ID:r.get(PDFName.of("ID"))||n.trailerInfo.ID}}},e.prototype.maybeParseTrailer=function(){if(this.skipWhitespaceAndComments(),!!this.matchKeyword(Keywords.startxref)){this.skipWhitespaceAndComments();var r=this.parseRawInt();return this.skipWhitespace(),this.matchKeyword(Keywords.eof),this.skipWhitespaceAndComments(),this.matchKeyword(Keywords.eof),this.skipWhitespaceAndComments(),PDFTrailer.forLastCrossRefSectionOffset(r)}},e.prototype.parseDocumentSection=function(){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(r){switch(r.label){case 0:return[4,this.parseIndirectObjects()];case 1:return r.sent(),this.maybeParseCrossRefSection(),this.maybeParseTrailerDict(),this.maybeParseTrailer(),this.skipJibberish(),[2]}})})},e.prototype.skipJibberish=function(){for(this.skipWhitespaceAndComments();!this.bytes.done();){var r=this.bytes.offset(),n=this.bytes.peek(),a=n>=CharCodes.Space&&n<=CharCodes.Tilde;if(a&&(this.matchKeyword(Keywords.xref)||this.matchKeyword(Keywords.trailer)||this.matchKeyword(Keywords.startxref)||this.matchIndirectObjectHeader())){this.bytes.moveTo(r);break}this.bytes.next()}},e.prototype.skipBinaryHeaderComment=function(){this.skipWhitespaceAndComments();try{var r=this.bytes.offset();this.parseIndirectObjectHeader(),this.bytes.moveTo(r)}catch{this.bytes.next(),this.skipWhitespaceAndComments()}},e.forBytesWithOptions=function(r,n,a,s){return new e(r,n,a,s)},e}(PDFObjectParser),flag=function(t){return 1<<t},AnnotationFlags;(function(t){t[t.Invisible=flag(0)]="Invisible",t[t.Hidden=flag(1)]="Hidden",t[t.Print=flag(2)]="Print",t[t.NoZoom=flag(3)]="NoZoom",t[t.NoRotate=flag(4)]="NoRotate",t[t.NoView=flag(5)]="NoView",t[t.ReadOnly=flag(6)]="ReadOnly",t[t.Locked=flag(7)]="Locked",t[t.ToggleNoView=flag(8)]="ToggleNoView",t[t.LockedContents=flag(9)]="LockedContents"})(AnnotationFlags||(AnnotationFlags={}));var asPDFName=function(t){return t instanceof PDFName?t:PDFName.of(t)},asPDFNumber=function(t){return t instanceof PDFNumber?t:PDFNumber.of(t)},asNumber=function(t){return t instanceof PDFNumber?t.asNumber():t},RotationTypes;(function(t){t.Degrees="degrees",t.Radians="radians"})(RotationTypes||(RotationTypes={}));var degrees=function(t){return assertIs(t,"degreeAngle",["number"]),{type:RotationTypes.Degrees,angle:t}},Radians=RotationTypes.Radians,Degrees=RotationTypes.Degrees,degreesToRadians=function(t){return t*Math.PI/180},radiansToDegrees=function(t){return t*180/Math.PI},toRadians=function(t){return t.type===Radians?t.angle:t.type===Degrees?degreesToRadians(t.angle):error("Invalid rotation: "+JSON.stringify(t))},toDegrees=function(t){return t.type===Radians?radiansToDegrees(t.angle):t.type===Degrees?t.angle:error("Invalid rotation: "+JSON.stringify(t))},reduceRotation=function(t){t===void 0&&(t=0);var e=t/90%4;return e===0?0:e===1?90:e===2?180:e===3?270:0},adjustDimsForRotation=function(t,e){e===void 0&&(e=0);var r=reduceRotation(e);return r===90||r===270?{width:t.height,height:t.width}:{width:t.width,height:t.height}},rotateRectangle=function(t,e,r){e===void 0&&(e=0),r===void 0&&(r=0);var n=t.x,a=t.y,s=t.width,o=t.height,h=reduceRotation(r),d=e/2;return h===0?{x:n-d,y:a-d,width:s,height:o}:h===90?{x:n-o+d,y:a-d,width:o,height:s}:h===180?{x:n-s+d,y:a-o+d,width:s,height:o}:h===270?{x:n-d,y:a-s+d,width:o,height:s}:{x:n-d,y:a-d,width:s,height:o}},clip=function(){return PDFOperator.of(Ops.ClipNonZero)},cos=Math.cos,sin=Math.sin,tan=Math.tan,concatTransformationMatrix=function(t,e,r,n,a,s){return PDFOperator.of(Ops.ConcatTransformationMatrix,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n),asPDFNumber(a),asPDFNumber(s)])},translate=function(t,e){return concatTransformationMatrix(1,0,0,1,t,e)},scale=function(t,e){return concatTransformationMatrix(t,0,0,e,0,0)},rotateRadians=function(t){return concatTransformationMatrix(cos(asNumber(t)),sin(asNumber(t)),-sin(asNumber(t)),cos(asNumber(t)),0,0)},rotateDegrees=function(t){return rotateRadians(degreesToRadians(asNumber(t)))},skewRadians=function(t,e){return concatTransformationMatrix(1,tan(asNumber(t)),tan(asNumber(e)),1,0,0)},setDashPattern=function(t,e){return PDFOperator.of(Ops.SetLineDashPattern,["["+t.map(asPDFNumber).join(" ")+"]",asPDFNumber(e)])},LineCapStyle;(function(t){t[t.Butt=0]="Butt",t[t.Round=1]="Round",t[t.Projecting=2]="Projecting"})(LineCapStyle||(LineCapStyle={}));var setLineCap=function(t){return PDFOperator.of(Ops.SetLineCapStyle,[asPDFNumber(t)])},LineJoinStyle;(function(t){t[t.Miter=0]="Miter",t[t.Round=1]="Round",t[t.Bevel=2]="Bevel"})(LineJoinStyle||(LineJoinStyle={}));var setGraphicsState=function(t){return PDFOperator.of(Ops.SetGraphicsStateParams,[asPDFName(t)])},pushGraphicsState=function(){return PDFOperator.of(Ops.PushGraphicsState)},popGraphicsState=function(){return PDFOperator.of(Ops.PopGraphicsState)},setLineWidth=function(t){return PDFOperator.of(Ops.SetLineWidth,[asPDFNumber(t)])},appendBezierCurve=function(t,e,r,n,a,s){return PDFOperator.of(Ops.AppendBezierCurve,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n),asPDFNumber(a),asPDFNumber(s)])},appendQuadraticCurve=function(t,e,r,n){return PDFOperator.of(Ops.CurveToReplicateInitialPoint,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n)])},closePath=function(){return PDFOperator.of(Ops.ClosePath)},moveTo=function(t,e){return PDFOperator.of(Ops.MoveTo,[asPDFNumber(t),asPDFNumber(e)])},lineTo=function(t,e){return PDFOperator.of(Ops.LineTo,[asPDFNumber(t),asPDFNumber(e)])},stroke=function(){return PDFOperator.of(Ops.StrokePath)},fill=function(){return PDFOperator.of(Ops.FillNonZero)},fillAndStroke=function(){return PDFOperator.of(Ops.FillNonZeroAndStroke)},endPath=function(){return PDFOperator.of(Ops.EndPath)},nextLine=function(){return PDFOperator.of(Ops.NextLine)},showText=function(t){return PDFOperator.of(Ops.ShowText,[t])},beginText=function(){return PDFOperator.of(Ops.BeginText)},endText=function(){return PDFOperator.of(Ops.EndText)},setFontAndSize=function(t,e){return PDFOperator.of(Ops.SetFontAndSize,[asPDFName(t),asPDFNumber(e)])},setLineHeight=function(t){return PDFOperator.of(Ops.SetTextLineHeight,[asPDFNumber(t)])},TextRenderingMode;(function(t){t[t.Fill=0]="Fill",t[t.Outline=1]="Outline",t[t.FillAndOutline=2]="FillAndOutline",t[t.Invisible=3]="Invisible",t[t.FillAndClip=4]="FillAndClip",t[t.OutlineAndClip=5]="OutlineAndClip",t[t.FillAndOutlineAndClip=6]="FillAndOutlineAndClip",t[t.Clip=7]="Clip"})(TextRenderingMode||(TextRenderingMode={}));var setTextMatrix=function(t,e,r,n,a,s){return PDFOperator.of(Ops.SetTextMatrix,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n),asPDFNumber(a),asPDFNumber(s)])},rotateAndSkewTextRadiansAndTranslate=function(t,e,r,n,a){return setTextMatrix(cos(asNumber(t)),sin(asNumber(t))+tan(asNumber(e)),-sin(asNumber(t))+tan(asNumber(r)),cos(asNumber(t)),n,a)},drawObject=function(t){return PDFOperator.of(Ops.DrawObject,[asPDFName(t)])},setFillingGrayscaleColor=function(t){return PDFOperator.of(Ops.NonStrokingColorGray,[asPDFNumber(t)])},setStrokingGrayscaleColor=function(t){return PDFOperator.of(Ops.StrokingColorGray,[asPDFNumber(t)])},setFillingRgbColor=function(t,e,r){return PDFOperator.of(Ops.NonStrokingColorRgb,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r)])},setStrokingRgbColor=function(t,e,r){return PDFOperator.of(Ops.StrokingColorRgb,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r)])},setFillingCmykColor=function(t,e,r,n){return PDFOperator.of(Ops.NonStrokingColorCmyk,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n)])},setStrokingCmykColor=function(t,e,r,n){return PDFOperator.of(Ops.StrokingColorCmyk,[asPDFNumber(t),asPDFNumber(e),asPDFNumber(r),asPDFNumber(n)])},beginMarkedContent=function(t){return PDFOperator.of(Ops.BeginMarkedContent,[asPDFName(t)])},endMarkedContent=function(){return PDFOperator.of(Ops.EndMarkedContent)},ColorTypes;(function(t){t.Grayscale="Grayscale",t.RGB="RGB",t.CMYK="CMYK"})(ColorTypes||(ColorTypes={}));var grayscale=function(t){return assertRange(t,"gray",0,1),{type:ColorTypes.Grayscale,gray:t}},rgb=function(t,e,r){return assertRange(t,"red",0,1),assertRange(e,"green",0,1),assertRange(r,"blue",0,1),{type:ColorTypes.RGB,red:t,green:e,blue:r}},cmyk=function(t,e,r,n){return assertRange(t,"cyan",0,1),assertRange(e,"magenta",0,1),assertRange(r,"yellow",0,1),assertRange(n,"key",0,1),{type:ColorTypes.CMYK,cyan:t,magenta:e,yellow:r,key:n}},Grayscale=ColorTypes.Grayscale,RGB=ColorTypes.RGB,CMYK=ColorTypes.CMYK,setFillingColor=function(t){return t.type===Grayscale?setFillingGrayscaleColor(t.gray):t.type===RGB?setFillingRgbColor(t.red,t.green,t.blue):t.type===CMYK?setFillingCmykColor(t.cyan,t.magenta,t.yellow,t.key):error("Invalid color: "+JSON.stringify(t))},setStrokingColor=function(t){return t.type===Grayscale?setStrokingGrayscaleColor(t.gray):t.type===RGB?setStrokingRgbColor(t.red,t.green,t.blue):t.type===CMYK?setStrokingCmykColor(t.cyan,t.magenta,t.yellow,t.key):error("Invalid color: "+JSON.stringify(t))},componentsToColor=function(t,e){return e===void 0&&(e=1),(t==null?void 0:t.length)===1?grayscale(t[0]*e):(t==null?void 0:t.length)===3?rgb(t[0]*e,t[1]*e,t[2]*e):(t==null?void 0:t.length)===4?cmyk(t[0]*e,t[1]*e,t[2]*e,t[3]*e):void 0},colorToComponents=function(t){return t.type===Grayscale?[t.gray]:t.type===RGB?[t.red,t.green,t.blue]:t.type===CMYK?[t.cyan,t.magenta,t.yellow,t.key]:error("Invalid color: "+JSON.stringify(t))},cx=0,cy=0,px=0,py=0,sx=0,sy=0,parameters=new Map([["A",7],["a",7],["C",6],["c",6],["H",1],["h",1],["L",2],["l",2],["M",2],["m",2],["Q",4],["q",4],["S",4],["s",4],["T",2],["t",2],["V",1],["v",1],["Z",0],["z",0]]),parse=function(t){for(var e,r=[],n=[],a="",s=!1,o=0,h=0,d=t;h<d.length;h++){var l=d[h];if(parameters.has(l))o=parameters.get(l),e&&(a.length>0&&(n[n.length]=+a),r[r.length]={cmd:e,args:n},n=[],a="",s=!1),e=l;else if([" ",","].includes(l)||l==="-"&&a.length>0&&a[a.length-1]!=="e"||l==="."&&s){if(a.length===0)continue;n.length===o?(r[r.length]={cmd:e,args:n},n=[+a],e==="M"&&(e="L"),e==="m"&&(e="l")):n[n.length]=+a,s=l===".",a=["-","."].includes(l)?l:""}else a+=l,l==="."&&(s=!0)}return a.length>0&&(n.length===o?(r[r.length]={cmd:e,args:n},n=[+a],e==="M"&&(e="L"),e==="m"&&(e="l")):n[n.length]=+a),r[r.length]={cmd:e,args:n},r},apply=function(t){cx=cy=px=py=sx=sy=0;for(var e=[],r=0;r<t.length;r++){var n=t[r];if(n.cmd&&typeof runners[n.cmd]=="function"){var a=runners[n.cmd](n.args);Array.isArray(a)?e=e.concat(a):e.push(a)}}return e},runners={M:function(t){return cx=t[0],cy=t[1],px=py=null,sx=cx,sy=cy,moveTo(cx,cy)},m:function(t){return cx+=t[0],cy+=t[1],px=py=null,sx=cx,sy=cy,moveTo(cx,cy)},C:function(t){return cx=t[4],cy=t[5],px=t[2],py=t[3],appendBezierCurve(t[0],t[1],t[2],t[3],t[4],t[5])},c:function(t){var e=appendBezierCurve(t[0]+cx,t[1]+cy,t[2]+cx,t[3]+cy,t[4]+cx,t[5]+cy);return px=cx+t[2],py=cy+t[3],cx+=t[4],cy+=t[5],e},S:function(t){(px===null||py===null)&&(px=cx,py=cy);var e=appendBezierCurve(cx-(px-cx),cy-(py-cy),t[0],t[1],t[2],t[3]);return px=t[0],py=t[1],cx=t[2],cy=t[3],e},s:function(t){(px===null||py===null)&&(px=cx,py=cy);var e=appendBezierCurve(cx-(px-cx),cy-(py-cy),cx+t[0],cy+t[1],cx+t[2],cy+t[3]);return px=cx+t[0],py=cy+t[1],cx+=t[2],cy+=t[3],e},Q:function(t){return px=t[0],py=t[1],cx=t[2],cy=t[3],appendQuadraticCurve(t[0],t[1],cx,cy)},q:function(t){var e=appendQuadraticCurve(t[0]+cx,t[1]+cy,t[2]+cx,t[3]+cy);return px=cx+t[0],py=cy+t[1],cx+=t[2],cy+=t[3],e},T:function(t){px===null||py===null?(px=cx,py=cy):(px=cx-(px-cx),py=cy-(py-cy));var e=appendQuadraticCurve(px,py,t[0],t[1]);return px=cx-(px-cx),py=cy-(py-cy),cx=t[0],cy=t[1],e},t:function(t){px===null||py===null?(px=cx,py=cy):(px=cx-(px-cx),py=cy-(py-cy));var e=appendQuadraticCurve(px,py,cx+t[0],cy+t[1]);return cx+=t[0],cy+=t[1],e},A:function(t){var e=solveArc(cx,cy,t);return cx=t[5],cy=t[6],e},a:function(t){t[5]+=cx,t[6]+=cy;var e=solveArc(cx,cy,t);return cx=t[5],cy=t[6],e},L:function(t){return cx=t[0],cy=t[1],px=py=null,lineTo(cx,cy)},l:function(t){return cx+=t[0],cy+=t[1],px=py=null,lineTo(cx,cy)},H:function(t){return cx=t[0],px=py=null,lineTo(cx,cy)},h:function(t){return cx+=t[0],px=py=null,lineTo(cx,cy)},V:function(t){return cy=t[0],px=py=null,lineTo(cx,cy)},v:function(t){return cy+=t[0],px=py=null,lineTo(cx,cy)},Z:function(){var t=closePath();return cx=sx,cy=sy,t},z:function(){var t=closePath();return cx=sx,cy=sy,t}},solveArc=function(t,e,r){for(var n=r[0],a=r[1],s=r[2],o=r[3],h=r[4],d=r[5],l=r[6],u=arcToSegments(d,l,n,a,o,h,s,t,e),p=[],g=0,f=u;g<f.length;g++){var v=f[g],y=segmentToBezier.apply(void 0,v);p.push(appendBezierCurve.apply(void 0,y))}return p},arcToSegments=function(t,e,r,n,a,s,o,h,d){var l=o*(Math.PI/180),u=Math.sin(l),p=Math.cos(l);r=Math.abs(r),n=Math.abs(n),px=p*(h-t)*.5+u*(d-e)*.5,py=p*(d-e)*.5-u*(h-t)*.5;var g=px*px/(r*r)+py*py/(n*n);g>1&&(g=Math.sqrt(g),r*=g,n*=g);var f=p/r,v=u/r,y=-u/n,S=p/n,m=f*h+v*d,w=y*h+S*d,R=f*t+v*e,_=y*t+S*e,x=(R-m)*(R-m)+(_-w)*(_-w),F=1/x-.25;F<0&&(F=0);var A=Math.sqrt(F);s===a&&(A=-A);var D=.5*(m+R)-A*(_-w),T=.5*(w+_)+A*(R-m),M=Math.atan2(w-T,m-D),C=Math.atan2(_-T,R-D),k=C-M;k<0&&s===1?k+=2*Math.PI:k>0&&s===0&&(k-=2*Math.PI);for(var O=Math.ceil(Math.abs(k/(Math.PI*.5+.001))),$=[],K=0;K<O;K++){var J=M+K*k/O,Y=M+(K+1)*k/O;$[K]=[D,T,J,Y,r,n,u,p]}return $},segmentToBezier=function(t,e,r,n,a,s,o,h){var d=h*a,l=-o*s,u=o*a,p=h*s,g=.5*(n-r),f=8/3*Math.sin(g*.5)*Math.sin(g*.5)/Math.sin(g),v=t+Math.cos(r)-f*Math.sin(r),y=e+Math.sin(r)+f*Math.cos(r),S=t+Math.cos(n),m=e+Math.sin(n),w=S+f*Math.sin(n),R=m-f*Math.cos(n),_=[d*v+l*y,u*v+p*y,d*w+l*R,u*w+p*R,d*S+l*m,u*S+p*m];return _},svgPathToOperators=function(t){return apply(parse(t))},drawLinesOfText=function(t,e){for(var r=[pushGraphicsState(),e.graphicsState&&setGraphicsState(e.graphicsState),beginText(),setFillingColor(e.color),setFontAndSize(e.font,e.size),setLineHeight(e.lineHeight),rotateAndSkewTextRadiansAndTranslate(toRadians(e.rotate),toRadians(e.xSkew),toRadians(e.ySkew),e.x,e.y)].filter(Boolean),n=0,a=t.length;n<a;n++)r.push(showText(t[n]),nextLine());return r.push(endText(),popGraphicsState()),r},drawImage=function(t,e){return[pushGraphicsState(),e.graphicsState&&setGraphicsState(e.graphicsState),translate(e.x,e.y),rotateRadians(toRadians(e.rotate)),scale(e.width,e.height),skewRadians(toRadians(e.xSkew),toRadians(e.ySkew)),drawObject(t),popGraphicsState()].filter(Boolean)},drawPage=function(t,e){return[pushGraphicsState(),e.graphicsState&&setGraphicsState(e.graphicsState),translate(e.x,e.y),rotateRadians(toRadians(e.rotate)),scale(e.xScale,e.yScale),skewRadians(toRadians(e.xSkew),toRadians(e.ySkew)),drawObject(t),popGraphicsState()].filter(Boolean)},drawLine=function(t){var e,r;return[pushGraphicsState(),t.graphicsState&&setGraphicsState(t.graphicsState),t.color&&setStrokingColor(t.color),setLineWidth(t.thickness),setDashPattern((e=t.dashArray)!==null&&e!==void 0?e:[],(r=t.dashPhase)!==null&&r!==void 0?r:0),moveTo(t.start.x,t.start.y),t.lineCap&&setLineCap(t.lineCap),moveTo(t.start.x,t.start.y),lineTo(t.end.x,t.end.y),stroke(),popGraphicsState()].filter(Boolean)},drawRectangle=function(t){var e,r;return[pushGraphicsState(),t.graphicsState&&setGraphicsState(t.graphicsState),t.color&&setFillingColor(t.color),t.borderColor&&setStrokingColor(t.borderColor),setLineWidth(t.borderWidth),t.borderLineCap&&setLineCap(t.borderLineCap),setDashPattern((e=t.borderDashArray)!==null&&e!==void 0?e:[],(r=t.borderDashPhase)!==null&&r!==void 0?r:0),translate(t.x,t.y),rotateRadians(toRadians(t.rotate)),skewRadians(toRadians(t.xSkew),toRadians(t.ySkew)),moveTo(0,0),lineTo(0,t.height),lineTo(t.width,t.height),lineTo(t.width,0),closePath(),t.color&&t.borderWidth?fillAndStroke():t.color?fill():t.borderColor?stroke():closePath(),popGraphicsState()].filter(Boolean)},KAPPA=4*((Math.sqrt(2)-1)/3),drawEllipsePath=function(t){var e=asNumber(t.x),r=asNumber(t.y),n=asNumber(t.xScale),a=asNumber(t.yScale);e-=n,r-=a;var s=n*KAPPA,o=a*KAPPA,h=e+n*2,d=r+a*2,l=e+n,u=r+a;return[pushGraphicsState(),moveTo(e,u),appendBezierCurve(e,u-o,l-s,r,l,r),appendBezierCurve(l+s,r,h,u-o,h,u),appendBezierCurve(h,u+o,l+s,d,l,d),appendBezierCurve(l-s,d,e,u+o,e,u),popGraphicsState()]},drawEllipseCurves=function(t){var e=asNumber(t.x),r=asNumber(t.y),n=asNumber(t.xScale),a=asNumber(t.yScale),s=-n,o=-a,h=n*KAPPA,d=a*KAPPA,l=s+n*2,u=o+a*2,p=s+n,g=o+a;return[translate(e,r),rotateRadians(toRadians(t.rotate)),moveTo(s,g),appendBezierCurve(s,g-d,p-h,o,p,o),appendBezierCurve(p+h,o,l,g-d,l,g),appendBezierCurve(l,g+d,p+h,u,p,u),appendBezierCurve(p-h,u,s,g+d,s,g)]},drawEllipse=function(t){var e,r,n;return __spreadArrays([pushGraphicsState(),t.graphicsState&&setGraphicsState(t.graphicsState),t.color&&setFillingColor(t.color),t.borderColor&&setStrokingColor(t.borderColor),setLineWidth(t.borderWidth),t.borderLineCap&&setLineCap(t.borderLineCap),setDashPattern((e=t.borderDashArray)!==null&&e!==void 0?e:[],(r=t.borderDashPhase)!==null&&r!==void 0?r:0)],t.rotate===void 0?drawEllipsePath({x:t.x,y:t.y,xScale:t.xScale,yScale:t.yScale}):drawEllipseCurves({x:t.x,y:t.y,xScale:t.xScale,yScale:t.yScale,rotate:(n=t.rotate)!==null&&n!==void 0?n:degrees(0)}),[t.color&&t.borderWidth?fillAndStroke():t.color?fill():t.borderColor?stroke():closePath(),popGraphicsState()]).filter(Boolean)},drawSvgPath=function(t,e){var r,n,a;return __spreadArrays([pushGraphicsState(),e.graphicsState&&setGraphicsState(e.graphicsState),translate(e.x,e.y),rotateRadians(toRadians((r=e.rotate)!==null&&r!==void 0?r:degrees(0))),e.scale?scale(e.scale,-e.scale):scale(1,-1),e.color&&setFillingColor(e.color),e.borderColor&&setStrokingColor(e.borderColor),e.borderWidth&&setLineWidth(e.borderWidth),e.borderLineCap&&setLineCap(e.borderLineCap),setDashPattern((n=e.borderDashArray)!==null&&n!==void 0?n:[],(a=e.borderDashPhase)!==null&&a!==void 0?a:0)],svgPathToOperators(t),[e.color&&e.borderWidth?fillAndStroke():e.color?fill():e.borderColor?stroke():closePath(),popGraphicsState()]).filter(Boolean)},drawCheckMark=function(t){var e=asNumber(t.size),r=-1+.75,n=-1+.51,a=1-.525,s=1-.31,o=-1+.325,h=.3995/(a-n)+n;return[pushGraphicsState(),t.color&&setStrokingColor(t.color),setLineWidth(t.thickness),translate(t.x,t.y),moveTo(o*e,h*e),lineTo(r*e,n*e),lineTo(s*e,a*e),stroke(),popGraphicsState()].filter(Boolean)},rotateInPlace=function(t){return t.rotation===0?[translate(0,0),rotateDegrees(0)]:t.rotation===90?[translate(t.width,0),rotateDegrees(90)]:t.rotation===180?[translate(t.width,t.height),rotateDegrees(180)]:t.rotation===270?[translate(0,t.height),rotateDegrees(270)]:[]},drawCheckBox=function(t){var e=drawRectangle({x:t.x,y:t.y,width:t.width,height:t.height,borderWidth:t.borderWidth,color:t.color,borderColor:t.borderColor,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)});if(!t.filled)return e;var r=asNumber(t.width),n=asNumber(t.height),a=Math.min(r,n)/2,s=drawCheckMark({x:r/2,y:n/2,size:a,thickness:t.thickness,color:t.markColor});return __spreadArrays([pushGraphicsState()],e,s,[popGraphicsState()])},drawRadioButton=function(t){var e=asNumber(t.width),r=asNumber(t.height),n=Math.min(e,r)/2,a=drawEllipse({x:t.x,y:t.y,xScale:n,yScale:n,color:t.color,borderColor:t.borderColor,borderWidth:t.borderWidth});if(!t.filled)return a;var s=drawEllipse({x:t.x,y:t.y,xScale:n*.45,yScale:n*.45,color:t.dotColor,borderColor:void 0,borderWidth:0});return __spreadArrays([pushGraphicsState()],a,s,[popGraphicsState()])},drawButton=function(t){var e=asNumber(t.x),r=asNumber(t.y),n=asNumber(t.width),a=asNumber(t.height),s=drawRectangle({x:e,y:r,width:n,height:a,borderWidth:t.borderWidth,color:t.color,borderColor:t.borderColor,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}),o=drawTextLines(t.textLines,{color:t.textColor,font:t.font,size:t.fontSize,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)});return __spreadArrays([pushGraphicsState()],s,o,[popGraphicsState()])},drawTextLines=function(t,e){for(var r=[beginText(),setFillingColor(e.color),setFontAndSize(e.font,e.size)],n=0,a=t.length;n<a;n++){var s=t[n],o=s.encoded,h=s.x,d=s.y;r.push(rotateAndSkewTextRadiansAndTranslate(toRadians(e.rotate),toRadians(e.xSkew),toRadians(e.ySkew),h,d),showText(o))}return r.push(endText()),r},drawTextField=function(t){var e=asNumber(t.x),r=asNumber(t.y),n=asNumber(t.width),a=asNumber(t.height),s=asNumber(t.borderWidth),o=asNumber(t.padding),h=e+s/2+o,d=r+s/2+o,l=n-(s/2+o)*2,u=a-(s/2+o)*2,p=[moveTo(h,d),lineTo(h,d+u),lineTo(h+l,d+u),lineTo(h+l,d),closePath(),clip(),endPath()],g=drawRectangle({x:e,y:r,width:n,height:a,borderWidth:t.borderWidth,color:t.color,borderColor:t.borderColor,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}),f=drawTextLines(t.textLines,{color:t.textColor,font:t.font,size:t.fontSize,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}),v=__spreadArrays([beginMarkedContent("Tx"),pushGraphicsState()],f,[popGraphicsState(),endMarkedContent()]);return __spreadArrays([pushGraphicsState()],g,p,v,[popGraphicsState()])},drawOptionList=function(t){for(var e=asNumber(t.x),r=asNumber(t.y),n=asNumber(t.width),a=asNumber(t.height),s=asNumber(t.lineHeight),o=asNumber(t.borderWidth),h=asNumber(t.padding),d=e+o/2+h,l=r+o/2+h,u=n-(o/2+h)*2,p=a-(o/2+h)*2,g=[moveTo(d,l),lineTo(d,l+p),lineTo(d+u,l+p),lineTo(d+u,l),closePath(),clip(),endPath()],f=drawRectangle({x:e,y:r,width:n,height:a,borderWidth:t.borderWidth,color:t.color,borderColor:t.borderColor,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}),v=[],y=0,S=t.selectedLines.length;y<S;y++){var m=t.textLines[t.selectedLines[y]];v.push.apply(v,drawRectangle({x:m.x-h,y:m.y-(s-m.height)/2,width:n-o,height:m.height+(s-m.height)/2,borderWidth:0,color:t.selectedColor,borderColor:void 0,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}))}var w=drawTextLines(t.textLines,{color:t.textColor,font:t.font,size:t.fontSize,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)}),R=__spreadArrays([beginMarkedContent("Tx"),pushGraphicsState()],w,[popGraphicsState(),endMarkedContent()]);return __spreadArrays([pushGraphicsState()],f,v,g,R,[popGraphicsState()])},EncryptedPDFError=function(t){__extends(e,t);function e(){var r=this,n="Input document to `PDFDocument.load` is encrypted. You can use `PDFDocument.load(..., { ignoreEncryption: true })` if you wish to load the document anyways.";return r=t.call(this,n)||this,r}return e}(Error),FontkitNotRegisteredError=function(t){__extends(e,t);function e(){var r=this,n="Input to `PDFDocument.embedFont` was a custom font, but no `fontkit` instance was found. You must register a `fontkit` instance with `PDFDocument.registerFontkit(...)` before embedding custom fonts.";return r=t.call(this,n)||this,r}return e}(Error),ForeignPageError=function(t){__extends(e,t);function e(){var r=this,n="A `page` passed to `PDFDocument.addPage` or `PDFDocument.insertPage` was from a different (foreign) PDF document. If you want to copy pages from one PDFDocument to another, you must use `PDFDocument.copyPages(...)` to copy the pages before adding or inserting them.";return r=t.call(this,n)||this,r}return e}(Error),RemovePageFromEmptyDocumentError=function(t){__extends(e,t);function e(){var r=this,n="PDFDocument has no pages so `PDFDocument.removePage` cannot be called";return r=t.call(this,n)||this,r}return e}(Error),NoSuchFieldError=function(t){__extends(e,t);function e(r){var n=this,a='PDFDocument has no form field with the name "'+r+'"';return n=t.call(this,a)||this,n}return e}(Error),UnexpectedFieldTypeError=function(t){__extends(e,t);function e(r,n,a){var s,o,h=this,d=n==null?void 0:n.name,l=(o=(s=a==null?void 0:a.constructor)===null||s===void 0?void 0:s.name)!==null&&o!==void 0?o:a,u='Expected field "'+r+'" to be of type '+d+", "+("but it is actually of type "+l);return h=t.call(this,u)||this,h}return e}(Error);(function(t){__extends(e,t);function e(r){var n=this,a='Failed to select check box due to missing onValue: "'+r+'"';return n=t.call(this,a)||this,n}return e})(Error);var FieldAlreadyExistsError=function(t){__extends(e,t);function e(r){var n=this,a='A field already exists with the specified name: "'+r+'"';return n=t.call(this,a)||this,n}return e}(Error),InvalidFieldNamePartError=function(t){__extends(e,t);function e(r){var n=this,a='Field name contains invalid component: "'+r+'"';return n=t.call(this,a)||this,n}return e}(Error);(function(t){__extends(e,t);function e(r){var n=this,a='A non-terminal field already exists with the specified name: "'+r+'"';return n=t.call(this,a)||this,n}return e})(Error);var RichTextFieldReadError=function(t){__extends(e,t);function e(r){var n=this,a="Reading rich text fields is not supported: Attempted to read rich text field: "+r;return n=t.call(this,a)||this,n}return e}(Error),CombedTextLayoutError=function(t){__extends(e,t);function e(r,n){var a=this,s="Failed to layout combed text as lineLength="+r+" is greater than cellCount="+n;return a=t.call(this,s)||this,a}return e}(Error),ExceededMaxLengthError=function(t){__extends(e,t);function e(r,n,a){var s=this,o="Attempted to set text with length="+r+" for TextField with maxLength="+n+" and name="+a;return s=t.call(this,o)||this,s}return e}(Error),InvalidMaxLengthError=function(t){__extends(e,t);function e(r,n,a){var s=this,o="Attempted to set maxLength="+n+", which is less than "+r+", the length of this field's current value (name="+a+")";return s=t.call(this,o)||this,s}return e}(Error),TextAlignment;(function(t){t[t.Left=0]="Left",t[t.Center=1]="Center",t[t.Right=2]="Right"})(TextAlignment||(TextAlignment={}));var MIN_FONT_SIZE=4,MAX_FONT_SIZE=500,computeFontSize=function(t,e,r,n){n===void 0&&(n=!1);for(var a=MIN_FONT_SIZE;a<MAX_FONT_SIZE;){for(var s=0,o=0,h=t.length;o<h;o++){s+=1;for(var d=t[o],l=d.split(" "),u=r.width,p=0,g=l.length;p<g;p++){var f=p===g-1,v=f?l[p]:l[p]+" ",y=e.widthOfTextAtSize(v,a);u-=y,u<=0&&(s+=1,u=r.width-y)}}if(!n&&s>t.length)return a-1;var S=e.heightAtSize(a),m=S+S*.2,w=m*s;if(w>Math.abs(r.height))return a-1;a+=1}return a},computeCombedFontSize=function(t,e,r,n){for(var a=r.width/n,s=r.height,o=MIN_FONT_SIZE,h=charSplit(t);o<MAX_FONT_SIZE;){for(var d=0,l=h.length;d<l;d++){var u=h[d],p=e.widthOfTextAtSize(u,o)>a*.75;if(p)return o-1}var g=e.heightAtSize(o,{descender:!1});if(g>s)return o-1;o+=1}return o},lastIndexOfWhitespace=function(t){for(var e=t.length;e>0;e--)if(/\s/.test(t[e]))return e},splitOutLines=function(t,e,r,n){for(var a,s=t.length;s>0;){var o=t.substring(0,s),h=r.encodeText(o),d=r.widthOfTextAtSize(o,n);if(d<e){var l=t.substring(s)||void 0;return{line:o,encoded:h,width:d,remainder:l}}s=(a=lastIndexOfWhitespace(o))!==null&&a!==void 0?a:0}return{line:t,encoded:r.encodeText(t),width:r.widthOfTextAtSize(t,n),remainder:void 0}},layoutMultilineText=function(t,e){var r=e.alignment,n=e.fontSize,a=e.font,s=e.bounds,o=lineSplit(cleanText(t));(n===void 0||n===0)&&(n=computeFontSize(o,a,s,!0));for(var h=a.heightAtSize(n),d=h+h*.2,l=[],u=s.x,p=s.y,g=s.x+s.width,f=s.y+s.height,v=s.y+s.height,y=0,S=o.length;y<S;y++)for(var m=o[y];m!==void 0;){var w=splitOutLines(m,s.width,a,n),R=w.line,_=w.encoded,x=w.width,F=w.remainder,A=r===TextAlignment.Left?s.x:r===TextAlignment.Center?s.x+s.width/2-x/2:r===TextAlignment.Right?s.x+s.width-x:s.x;v-=d,A<u&&(u=A),v<p&&(p=v),A+x>g&&(g=A+x),v+h>f&&(f=v+h),l.push({text:R,encoded:_,width:x,height:h,x:A,y:v}),m=F==null?void 0:F.trim()}return{fontSize:n,lineHeight:d,lines:l,bounds:{x:u,y:p,width:g-u,height:f-p}}},layoutCombedText=function(t,e){var r=e.fontSize,n=e.font,a=e.bounds,s=e.cellCount,o=mergeLines(cleanText(t));if(o.length>s)throw new CombedTextLayoutError(o.length,s);(r===void 0||r===0)&&(r=computeCombedFontSize(o,n,a,s));for(var h=a.width/s,d=n.heightAtSize(r,{descender:!1}),l=a.y+(a.height/2-d/2),u=[],p=a.x,g=a.y,f=a.x+a.width,v=a.y+a.height,y=0,S=0;y<s;){var m=charAtIndex(o,S),w=m[0],R=m[1],_=n.encodeText(w),x=n.widthOfTextAtSize(w,r),F=a.x+(h*y+h/2),A=F-x/2;A<p&&(p=A),l<g&&(g=l),A+x>f&&(f=A+x),l+d>v&&(v=l+d),u.push({text:o,encoded:_,width:x,height:d,x:A,y:l}),y+=1,S+=R}return{fontSize:r,cells:u,bounds:{x:p,y:g,width:f-p,height:v-g}}},layoutSinglelineText=function(t,e){var r=e.alignment,n=e.fontSize,a=e.font,s=e.bounds,o=mergeLines(cleanText(t));(n===void 0||n===0)&&(n=computeFontSize([o],a,s));var h=a.encodeText(o),d=a.widthOfTextAtSize(o,n),l=a.heightAtSize(n,{descender:!1}),u=r===TextAlignment.Left?s.x:r===TextAlignment.Center?s.x+s.width/2-d/2:r===TextAlignment.Right?s.x+s.width-d:s.x,p=s.y+(s.height/2-l/2);return{fontSize:n,line:{text:o,encoded:h,width:d,height:l,x:u,y:p},bounds:{x:u,y:p,width:d,height:l}}},normalizeAppearance=function(t){return"normal"in t?t:{normal:t}},tfRegex=/\/([^\0\t\n\f\r\ ]+)[\0\t\n\f\r\ ]+(\d*\.\d+|\d+)[\0\t\n\f\r\ ]+Tf/,getDefaultFontSize=function(t){var e,r,n=(e=t.getDefaultAppearance())!==null&&e!==void 0?e:"",a=(r=findLastMatch(n,tfRegex).match)!==null&&r!==void 0?r:[],s=Number(a[2]);return isFinite(s)?s:void 0},colorRegex=/(\d*\.\d+|\d+)[\0\t\n\f\r\ ]*(\d*\.\d+|\d+)?[\0\t\n\f\r\ ]*(\d*\.\d+|\d+)?[\0\t\n\f\r\ ]*(\d*\.\d+|\d+)?[\0\t\n\f\r\ ]+(g|rg|k)/,getDefaultColor=function(t){var e,r=(e=t.getDefaultAppearance())!==null&&e!==void 0?e:"",n=findLastMatch(r,colorRegex).match,a=n??[],s=a[1],o=a[2],h=a[3],d=a[4],l=a[5];if(l==="g"&&s)return grayscale(Number(s));if(l==="rg"&&s&&o&&h)return rgb(Number(s),Number(o),Number(h));if(l==="k"&&s&&o&&h&&d)return cmyk(Number(s),Number(o),Number(h),Number(d))},updateDefaultAppearance=function(t,e,r,n){var a;n===void 0&&(n=0);var s=[setFillingColor(e).toString(),setFontAndSize((a=r==null?void 0:r.name)!==null&&a!==void 0?a:"dummy__noop",n).toString()].join(`
|
|
58
|
+
`);t.setDefaultAppearance(s)},defaultCheckBoxAppearanceProvider=function(t,e){var r,n,a,s=getDefaultColor(e),o=getDefaultColor(t.acroField),h=e.getRectangle(),d=e.getAppearanceCharacteristics(),l=e.getBorderStyle(),u=(r=l==null?void 0:l.getWidth())!==null&&r!==void 0?r:0,p=reduceRotation(d==null?void 0:d.getRotation()),g=adjustDimsForRotation(h,p),f=g.width,v=g.height,y=rotateInPlace(__assign(__assign({},h),{rotation:p})),S=rgb(0,0,0),m=(n=componentsToColor(d==null?void 0:d.getBorderColor()))!==null&&n!==void 0?n:S,w=componentsToColor(d==null?void 0:d.getBackgroundColor()),R=componentsToColor(d==null?void 0:d.getBackgroundColor(),.8),_=(a=s??o)!==null&&a!==void 0?a:S;updateDefaultAppearance(s?e:t.acroField,_);var x={x:0+u/2,y:0+u/2,width:f-u,height:v-u,thickness:1.5,borderWidth:u,borderColor:m,markColor:_};return{normal:{on:__spreadArrays(y,drawCheckBox(__assign(__assign({},x),{color:w,filled:!0}))),off:__spreadArrays(y,drawCheckBox(__assign(__assign({},x),{color:w,filled:!1})))},down:{on:__spreadArrays(y,drawCheckBox(__assign(__assign({},x),{color:R,filled:!0}))),off:__spreadArrays(y,drawCheckBox(__assign(__assign({},x),{color:R,filled:!1})))}}},defaultRadioGroupAppearanceProvider=function(t,e){var r,n,a,s=getDefaultColor(e),o=getDefaultColor(t.acroField),h=e.getRectangle(),d=e.getAppearanceCharacteristics(),l=e.getBorderStyle(),u=(r=l==null?void 0:l.getWidth())!==null&&r!==void 0?r:0,p=reduceRotation(d==null?void 0:d.getRotation()),g=adjustDimsForRotation(h,p),f=g.width,v=g.height,y=rotateInPlace(__assign(__assign({},h),{rotation:p})),S=rgb(0,0,0),m=(n=componentsToColor(d==null?void 0:d.getBorderColor()))!==null&&n!==void 0?n:S,w=componentsToColor(d==null?void 0:d.getBackgroundColor()),R=componentsToColor(d==null?void 0:d.getBackgroundColor(),.8),_=(a=s??o)!==null&&a!==void 0?a:S;updateDefaultAppearance(s?e:t.acroField,_);var x={x:f/2,y:v/2,width:f-u,height:v-u,borderWidth:u,borderColor:m,dotColor:_};return{normal:{on:__spreadArrays(y,drawRadioButton(__assign(__assign({},x),{color:w,filled:!0}))),off:__spreadArrays(y,drawRadioButton(__assign(__assign({},x),{color:w,filled:!1})))},down:{on:__spreadArrays(y,drawRadioButton(__assign(__assign({},x),{color:R,filled:!0}))),off:__spreadArrays(y,drawRadioButton(__assign(__assign({},x),{color:R,filled:!1})))}}},defaultButtonAppearanceProvider=function(t,e,r){var n,a,s,o,h,d=getDefaultColor(e),l=getDefaultColor(t.acroField),u=getDefaultFontSize(e),p=getDefaultFontSize(t.acroField),g=e.getRectangle(),f=e.getAppearanceCharacteristics(),v=e.getBorderStyle(),y=f==null?void 0:f.getCaptions(),S=(n=y==null?void 0:y.normal)!==null&&n!==void 0?n:"",m=(s=(a=y==null?void 0:y.down)!==null&&a!==void 0?a:S)!==null&&s!==void 0?s:"",w=(o=v==null?void 0:v.getWidth())!==null&&o!==void 0?o:0,R=reduceRotation(f==null?void 0:f.getRotation()),_=adjustDimsForRotation(g,R),x=_.width,F=_.height,A=rotateInPlace(__assign(__assign({},g),{rotation:R})),D=rgb(0,0,0),T=componentsToColor(f==null?void 0:f.getBorderColor()),M=componentsToColor(f==null?void 0:f.getBackgroundColor()),C=componentsToColor(f==null?void 0:f.getBackgroundColor(),.8),k={x:w,y:w,width:x-w*2,height:F-w*2},O=layoutSinglelineText(S,{alignment:TextAlignment.Center,fontSize:u??p,font:r,bounds:k}),$=layoutSinglelineText(m,{alignment:TextAlignment.Center,fontSize:u??p,font:r,bounds:k}),K=Math.min(O.fontSize,$.fontSize),J=(h=d??l)!==null&&h!==void 0?h:D;updateDefaultAppearance(d||u!==void 0?e:t.acroField,J,r,K);var Y={x:0+w/2,y:0+w/2,width:x-w,height:F-w,borderWidth:w,borderColor:T,textColor:J,font:r.name,fontSize:K};return{normal:__spreadArrays(A,drawButton(__assign(__assign({},Y),{color:M,textLines:[O.line]}))),down:__spreadArrays(A,drawButton(__assign(__assign({},Y),{color:C,textLines:[$.line]})))}},defaultTextFieldAppearanceProvider=function(t,e,r){var n,a,s,o,h=getDefaultColor(e),d=getDefaultColor(t.acroField),l=getDefaultFontSize(e),u=getDefaultFontSize(t.acroField),p=e.getRectangle(),g=e.getAppearanceCharacteristics(),f=e.getBorderStyle(),v=(n=t.getText())!==null&&n!==void 0?n:"",y=(a=f==null?void 0:f.getWidth())!==null&&a!==void 0?a:0,S=reduceRotation(g==null?void 0:g.getRotation()),m=adjustDimsForRotation(p,S),w=m.width,R=m.height,_=rotateInPlace(__assign(__assign({},p),{rotation:S})),x=rgb(0,0,0),F=componentsToColor(g==null?void 0:g.getBorderColor()),A=componentsToColor(g==null?void 0:g.getBackgroundColor()),D,T,M=t.isCombed()?0:1,C={x:y+M,y:y+M,width:w-(y+M)*2,height:R-(y+M)*2};if(t.isMultiline()){var k=layoutMultilineText(v,{alignment:t.getAlignment(),fontSize:l??u,font:r,bounds:C});D=k.lines,T=k.fontSize}else if(t.isCombed()){var k=layoutCombedText(v,{fontSize:l??u,font:r,bounds:C,cellCount:(s=t.getMaxLength())!==null&&s!==void 0?s:0});D=k.cells,T=k.fontSize}else{var k=layoutSinglelineText(v,{alignment:t.getAlignment(),fontSize:l??u,font:r,bounds:C});D=[k.line],T=k.fontSize}var O=(o=h??d)!==null&&o!==void 0?o:x;updateDefaultAppearance(h||l!==void 0?e:t.acroField,O,r,T);var $={x:0+y/2,y:0+y/2,width:w-y,height:R-y,borderWidth:y??0,borderColor:F,textColor:O,font:r.name,fontSize:T,color:A,textLines:D,padding:M};return __spreadArrays(_,drawTextField($))},defaultDropdownAppearanceProvider=function(t,e,r){var n,a,s,o=getDefaultColor(e),h=getDefaultColor(t.acroField),d=getDefaultFontSize(e),l=getDefaultFontSize(t.acroField),u=e.getRectangle(),p=e.getAppearanceCharacteristics(),g=e.getBorderStyle(),f=(n=t.getSelected()[0])!==null&&n!==void 0?n:"",v=(a=g==null?void 0:g.getWidth())!==null&&a!==void 0?a:0,y=reduceRotation(p==null?void 0:p.getRotation()),S=adjustDimsForRotation(u,y),m=S.width,w=S.height,R=rotateInPlace(__assign(__assign({},u),{rotation:y})),_=rgb(0,0,0),x=componentsToColor(p==null?void 0:p.getBorderColor()),F=componentsToColor(p==null?void 0:p.getBackgroundColor()),A=1,D={x:v+A,y:v+A,width:m-(v+A)*2,height:w-(v+A)*2},T=layoutSinglelineText(f,{alignment:TextAlignment.Left,fontSize:d??l,font:r,bounds:D}),M=T.line,C=T.fontSize,k=(s=o??h)!==null&&s!==void 0?s:_;updateDefaultAppearance(o||d!==void 0?e:t.acroField,k,r,C);var O={x:0+v/2,y:0+v/2,width:m-v,height:w-v,borderWidth:v??0,borderColor:x,textColor:k,font:r.name,fontSize:C,color:F,textLines:[M],padding:A};return __spreadArrays(R,drawTextField(O))},defaultOptionListAppearanceProvider=function(t,e,r){var n,a,s=getDefaultColor(e),o=getDefaultColor(t.acroField),h=getDefaultFontSize(e),d=getDefaultFontSize(t.acroField),l=e.getRectangle(),u=e.getAppearanceCharacteristics(),p=e.getBorderStyle(),g=(n=p==null?void 0:p.getWidth())!==null&&n!==void 0?n:0,f=reduceRotation(u==null?void 0:u.getRotation()),v=adjustDimsForRotation(l,f),y=v.width,S=v.height,m=rotateInPlace(__assign(__assign({},l),{rotation:f})),w=rgb(0,0,0),R=componentsToColor(u==null?void 0:u.getBorderColor()),_=componentsToColor(u==null?void 0:u.getBackgroundColor()),x=t.getOptions(),F=t.getSelected();t.isSorted()&&x.sort();for(var A="",D=0,T=x.length;D<T;D++)A+=x[D],D<T-1&&(A+=`
|
|
59
|
+
`);for(var M=1,C={x:g+M,y:g+M,width:y-(g+M)*2,height:S-(g+M)*2},k=layoutMultilineText(A,{alignment:TextAlignment.Left,fontSize:h??d,font:r,bounds:C}),O=k.lines,$=k.fontSize,K=k.lineHeight,J=[],D=0,T=O.length;D<T;D++){var Y=O[D];F.includes(Y.text)&&J.push(D)}var se=rgb(153/255,193/255,218/255),B=(a=s??o)!==null&&a!==void 0?a:w;return updateDefaultAppearance(s||h!==void 0?e:t.acroField,B,r,$),__spreadArrays(m,drawOptionList({x:0+g/2,y:0+g/2,width:y-g,height:S-g,borderWidth:g??0,borderColor:R,textColor:B,font:r.name,fontSize:$,color:_,textLines:O,lineHeight:K,selectedColor:se,selectedLines:J,padding:M}))},PDFEmbeddedPage=function(){function t(e,r,n){this.alreadyEmbedded=!1,assertIs(e,"ref",[[PDFRef,"PDFRef"]]),assertIs(r,"doc",[[PDFDocument,"PDFDocument"]]),assertIs(n,"embedder",[[PDFPageEmbedder,"PDFPageEmbedder"]]),this.ref=e,this.doc=r,this.width=n.width,this.height=n.height,this.embedder=n}return t.prototype.scale=function(e){return assertIs(e,"factor",["number"]),{width:this.width*e,height:this.height*e}},t.prototype.size=function(){return this.scale(1)},t.prototype.embed=function(){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return this.alreadyEmbedded?[3,2]:[4,this.embedder.embedIntoContext(this.doc.context,this.ref)];case 1:e.sent(),this.alreadyEmbedded=!0,e.label=2;case 2:return[2]}})})},t.of=function(e,r,n){return new t(e,r,n)},t}(),PDFFont=function(){function t(e,r,n){this.modified=!0,assertIs(e,"ref",[[PDFRef,"PDFRef"]]),assertIs(r,"doc",[[PDFDocument,"PDFDocument"]]),assertIs(n,"embedder",[[CustomFontEmbedder,"CustomFontEmbedder"],[StandardFontEmbedder,"StandardFontEmbedder"]]),this.ref=e,this.doc=r,this.name=n.fontName,this.embedder=n}return t.prototype.encodeText=function(e){return assertIs(e,"text",["string"]),this.modified=!0,this.embedder.encodeText(e)},t.prototype.widthOfTextAtSize=function(e,r){return assertIs(e,"text",["string"]),assertIs(r,"size",["number"]),this.embedder.widthOfTextAtSize(e,r)},t.prototype.heightAtSize=function(e,r){var n;return assertIs(e,"size",["number"]),assertOrUndefined(r==null?void 0:r.descender,"options.descender",["boolean"]),this.embedder.heightOfFontAtSize(e,{descender:(n=r==null?void 0:r.descender)!==null&&n!==void 0?n:!0})},t.prototype.sizeAtHeight=function(e){return assertIs(e,"height",["number"]),this.embedder.sizeOfFontAtHeight(e)},t.prototype.getCharacterSet=function(){return this.embedder instanceof StandardFontEmbedder?this.embedder.encoding.supportedCodePoints:this.embedder.font.characterSet},t.prototype.embed=function(){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return this.modified?[4,this.embedder.embedIntoContext(this.doc.context,this.ref)]:[3,2];case 1:e.sent(),this.modified=!1,e.label=2;case 2:return[2]}})})},t.of=function(e,r,n){return new t(e,r,n)},t}(),PDFImage=function(){function t(e,r,n){assertIs(e,"ref",[[PDFRef,"PDFRef"]]),assertIs(r,"doc",[[PDFDocument,"PDFDocument"]]),assertIs(n,"embedder",[[JpegEmbedder,"JpegEmbedder"],[PngEmbedder,"PngEmbedder"]]),this.ref=e,this.doc=r,this.width=n.width,this.height=n.height,this.embedder=n}return t.prototype.scale=function(e){return assertIs(e,"factor",["number"]),{width:this.width*e,height:this.height*e}},t.prototype.scaleToFit=function(e,r){assertIs(e,"width",["number"]),assertIs(r,"height",["number"]);var n=e/this.width,a=r/this.height,s=Math.min(n,a);return this.scale(s)},t.prototype.size=function(){return this.scale(1)},t.prototype.embed=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n;return __generator(this,function(a){switch(a.label){case 0:return this.embedder?(this.embedTask||(e=this,r=e.doc,n=e.ref,this.embedTask=this.embedder.embedIntoContext(r.context,n)),[4,this.embedTask]):[2];case 1:return a.sent(),this.embedder=void 0,[2]}})})},t.of=function(e,r,n){return new t(e,r,n)},t}(),ImageAlignment;(function(t){t[t.Left=0]="Left",t[t.Center=1]="Center",t[t.Right=2]="Right"})(ImageAlignment||(ImageAlignment={}));var assertFieldAppearanceOptions=function(t){assertOrUndefined(t==null?void 0:t.x,"options.x",["number"]),assertOrUndefined(t==null?void 0:t.y,"options.y",["number"]),assertOrUndefined(t==null?void 0:t.width,"options.width",["number"]),assertOrUndefined(t==null?void 0:t.height,"options.height",["number"]),assertOrUndefined(t==null?void 0:t.textColor,"options.textColor",[[Object,"Color"]]),assertOrUndefined(t==null?void 0:t.backgroundColor,"options.backgroundColor",[[Object,"Color"]]),assertOrUndefined(t==null?void 0:t.borderColor,"options.borderColor",[[Object,"Color"]]),assertOrUndefined(t==null?void 0:t.borderWidth,"options.borderWidth",["number"]),assertOrUndefined(t==null?void 0:t.rotate,"options.rotate",[[Object,"Rotation"]])},PDFField=function(){function t(e,r,n){assertIs(e,"acroField",[[PDFAcroTerminal,"PDFAcroTerminal"]]),assertIs(r,"ref",[[PDFRef,"PDFRef"]]),assertIs(n,"doc",[[PDFDocument,"PDFDocument"]]),this.acroField=e,this.ref=r,this.doc=n}return t.prototype.getName=function(){var e;return(e=this.acroField.getFullyQualifiedName())!==null&&e!==void 0?e:""},t.prototype.isReadOnly=function(){return this.acroField.hasFlag(AcroFieldFlags.ReadOnly)},t.prototype.enableReadOnly=function(){this.acroField.setFlagTo(AcroFieldFlags.ReadOnly,!0)},t.prototype.disableReadOnly=function(){this.acroField.setFlagTo(AcroFieldFlags.ReadOnly,!1)},t.prototype.isRequired=function(){return this.acroField.hasFlag(AcroFieldFlags.Required)},t.prototype.enableRequired=function(){this.acroField.setFlagTo(AcroFieldFlags.Required,!0)},t.prototype.disableRequired=function(){this.acroField.setFlagTo(AcroFieldFlags.Required,!1)},t.prototype.isExported=function(){return!this.acroField.hasFlag(AcroFieldFlags.NoExport)},t.prototype.enableExporting=function(){this.acroField.setFlagTo(AcroFieldFlags.NoExport,!1)},t.prototype.disableExporting=function(){this.acroField.setFlagTo(AcroFieldFlags.NoExport,!0)},t.prototype.needsAppearancesUpdate=function(){throw new MethodNotImplementedError(this.constructor.name,"needsAppearancesUpdate")},t.prototype.defaultUpdateAppearances=function(e){throw new MethodNotImplementedError(this.constructor.name,"defaultUpdateAppearances")},t.prototype.markAsDirty=function(){this.doc.getForm().markFieldAsDirty(this.ref)},t.prototype.markAsClean=function(){this.doc.getForm().markFieldAsClean(this.ref)},t.prototype.isDirty=function(){return this.doc.getForm().fieldIsDirty(this.ref)},t.prototype.createWidget=function(e){var r,n=e.textColor,a=e.backgroundColor,s=e.borderColor,o=e.borderWidth,h=toDegrees(e.rotate),d=e.caption,l=e.x,u=e.y,p=e.width+o,g=e.height+o,f=!!e.hidden,v=e.page;assertMultiple(h,"degreesAngle",90);var y=PDFWidgetAnnotation.create(this.doc.context,this.ref),S=rotateRectangle({x:l,y:u,width:p,height:g},o,h);y.setRectangle(S),v&&y.setP(v);var m=y.getOrCreateAppearanceCharacteristics();a&&m.setBackgroundColor(colorToComponents(a)),m.setRotation(h),d&&m.setCaptions({normal:d}),s&&m.setBorderColor(colorToComponents(s));var w=y.getOrCreateBorderStyle();if(o!==void 0&&w.setWidth(o),y.setFlagTo(AnnotationFlags.Print,!0),y.setFlagTo(AnnotationFlags.Hidden,f),y.setFlagTo(AnnotationFlags.Invisible,!1),n){var R=(r=this.acroField.getDefaultAppearance())!==null&&r!==void 0?r:"",_=R+`
|
|
60
|
+
`+setFillingColor(n).toString();this.acroField.setDefaultAppearance(_)}return y},t.prototype.updateWidgetAppearanceWithFont=function(e,r,n){var a=n.normal,s=n.rollover,o=n.down;this.updateWidgetAppearances(e,{normal:this.createAppearanceStream(e,a,r),rollover:s&&this.createAppearanceStream(e,s,r),down:o&&this.createAppearanceStream(e,o,r)})},t.prototype.updateOnOffWidgetAppearance=function(e,r,n){var a=n.normal,s=n.rollover,o=n.down;this.updateWidgetAppearances(e,{normal:this.createAppearanceDict(e,a,r),rollover:s&&this.createAppearanceDict(e,s,r),down:o&&this.createAppearanceDict(e,o,r)})},t.prototype.updateWidgetAppearances=function(e,r){var n=r.normal,a=r.rollover,s=r.down;e.setNormalAppearance(n),a?e.setRolloverAppearance(a):e.removeRolloverAppearance(),s?e.setDownAppearance(s):e.removeDownAppearance()},t.prototype.createAppearanceStream=function(e,r,n){var a,s=this.acroField.dict.context,o=e.getRectangle(),h=o.width,d=o.height,l=n&&{Font:(a={},a[n.name]=n.ref,a)},u=s.formXObject(r,{Resources:l,BBox:s.obj([0,0,h,d]),Matrix:s.obj([1,0,0,1,0,0])}),p=s.register(u);return p},t.prototype.createImageAppearanceStream=function(e,r,n){var a,s,o=this.acroField.dict.context,h=e.getRectangle(),d=e.getAppearanceCharacteristics(),l=e.getBorderStyle(),u=(s=l==null?void 0:l.getWidth())!==null&&s!==void 0?s:0,p=reduceRotation(d==null?void 0:d.getRotation()),g=rotateInPlace(__assign(__assign({},h),{rotation:p})),f=adjustDimsForRotation(h,p),v=r.scaleToFit(f.width-u*2,f.height-u*2),y={x:u,y:u,width:v.width,height:v.height,rotate:degrees(0),xSkew:degrees(0),ySkew:degrees(0)};n===ImageAlignment.Center?(y.x+=(f.width-u*2)/2-v.width/2,y.y+=(f.height-u*2)/2-v.height/2):n===ImageAlignment.Right&&(y.x=f.width-u-v.width,y.y=f.height-u-v.height);var S=this.doc.context.addRandomSuffix("Image",10),m=__spreadArrays(g,drawImage(S,y)),w={XObject:(a={},a[S]=r.ref,a)},R=o.formXObject(m,{Resources:w,BBox:o.obj([0,0,h.width,h.height]),Matrix:o.obj([1,0,0,1,0,0])});return o.register(R)},t.prototype.createAppearanceDict=function(e,r,n){var a=this.acroField.dict.context,s=this.createAppearanceStream(e,r.on),o=this.createAppearanceStream(e,r.off),h=a.obj({});return h.set(n,s),h.set(PDFName.of("Off"),o),h},t}(),PDFCheckBox=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroCheckBox",[[PDFAcroCheckBox,"PDFAcroCheckBox"]]),s.acroField=r,s}return e.prototype.check=function(){var r,n=(r=this.acroField.getOnValue())!==null&&r!==void 0?r:PDFName.of("Yes");this.markAsDirty(),this.acroField.setValue(n)},e.prototype.uncheck=function(){this.markAsDirty(),this.acroField.setValue(PDFName.of("Off"))},e.prototype.isChecked=function(){var r=this.acroField.getOnValue();return!!r&&r===this.acroField.getValue()},e.prototype.addToPage=function(r,n){var a,s,o,h,d,l;assertIs(r,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(n),n||(n={}),"textColor"in n||(n.textColor=rgb(0,0,0)),"backgroundColor"in n||(n.backgroundColor=rgb(1,1,1)),"borderColor"in n||(n.borderColor=rgb(0,0,0)),"borderWidth"in n||(n.borderWidth=1);var u=this.createWidget({x:(a=n.x)!==null&&a!==void 0?a:0,y:(s=n.y)!==null&&s!==void 0?s:0,width:(o=n.width)!==null&&o!==void 0?o:50,height:(h=n.height)!==null&&h!==void 0?h:50,textColor:n.textColor,backgroundColor:n.backgroundColor,borderColor:n.borderColor,borderWidth:(d=n.borderWidth)!==null&&d!==void 0?d:0,rotate:(l=n.rotate)!==null&&l!==void 0?l:degrees(0),hidden:n.hidden,page:r.ref}),p=this.doc.context.register(u.dict);this.acroField.addWidget(p),u.setAppearanceState(PDFName.of("Off")),this.updateWidgetAppearance(u,PDFName.of("Yes")),r.node.addAnnot(p)},e.prototype.needsAppearancesUpdate=function(){for(var r,n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=o.getAppearanceState(),d=(r=o.getAppearances())===null||r===void 0?void 0:r.normal;if(!(d instanceof PDFDict)||h&&!d.has(h))return!0}return!1},e.prototype.defaultUpdateAppearances=function(){this.updateAppearances()},e.prototype.updateAppearances=function(r){var n;assertOrUndefined(r,"provider",[Function]);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s],d=(n=h.getOnValue())!==null&&n!==void 0?n:PDFName.of("Yes");d&&this.updateWidgetAppearance(h,d,r)}this.markAsClean()},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultCheckBoxAppearanceProvider,o=normalizeAppearance(s(this,r));this.updateOnOffWidgetAppearance(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),PDFDropdown=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroComboBox",[[PDFAcroComboBox,"PDFAcroComboBox"]]),s.acroField=r,s}return e.prototype.getOptions=function(){for(var r=this.acroField.getOptions(),n=new Array(r.length),a=0,s=n.length;a<s;a++){var o=r[a],h=o.display,d=o.value;n[a]=(h??d).decodeText()}return n},e.prototype.getSelected=function(){for(var r=this.acroField.getValues(),n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]=r[a].decodeText();return n},e.prototype.setOptions=function(r){assertIs(r,"options",[Array]);for(var n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]={value:PDFHexString.fromText(r[a])};this.acroField.setOptions(n)},e.prototype.addOptions=function(r){assertIs(r,"options",["string",Array]);for(var n=Array.isArray(r)?r:[r],a=this.acroField.getOptions(),s=new Array(n.length),o=0,h=n.length;o<h;o++)s[o]={value:PDFHexString.fromText(n[o])};this.acroField.setOptions(a.concat(s))},e.prototype.select=function(r,n){n===void 0&&(n=!1),assertIs(r,"options",["string",Array]),assertIs(n,"merge",["boolean"]);var a=Array.isArray(r)?r:[r],s=this.getOptions(),o=a.find(function(p){return!s.includes(p)});o&&this.enableEditing(),this.markAsDirty(),(a.length>1||a.length===1&&n)&&this.enableMultiselect();for(var h=new Array(a.length),d=0,l=a.length;d<l;d++)h[d]=PDFHexString.fromText(a[d]);if(n){var u=this.acroField.getValues();this.acroField.setValues(u.concat(h))}else this.acroField.setValues(h)},e.prototype.clear=function(){this.markAsDirty(),this.acroField.setValues([])},e.prototype.setFontSize=function(r){assertPositive(r,"fontSize"),this.acroField.setFontSize(r),this.markAsDirty()},e.prototype.isEditable=function(){return this.acroField.hasFlag(AcroChoiceFlags.Edit)},e.prototype.enableEditing=function(){this.acroField.setFlagTo(AcroChoiceFlags.Edit,!0)},e.prototype.disableEditing=function(){this.acroField.setFlagTo(AcroChoiceFlags.Edit,!1)},e.prototype.isSorted=function(){return this.acroField.hasFlag(AcroChoiceFlags.Sort)},e.prototype.enableSorting=function(){this.acroField.setFlagTo(AcroChoiceFlags.Sort,!0)},e.prototype.disableSorting=function(){this.acroField.setFlagTo(AcroChoiceFlags.Sort,!1)},e.prototype.isMultiselect=function(){return this.acroField.hasFlag(AcroChoiceFlags.MultiSelect)},e.prototype.enableMultiselect=function(){this.acroField.setFlagTo(AcroChoiceFlags.MultiSelect,!0)},e.prototype.disableMultiselect=function(){this.acroField.setFlagTo(AcroChoiceFlags.MultiSelect,!1)},e.prototype.isSpellChecked=function(){return!this.acroField.hasFlag(AcroChoiceFlags.DoNotSpellCheck)},e.prototype.enableSpellChecking=function(){this.acroField.setFlagTo(AcroChoiceFlags.DoNotSpellCheck,!1)},e.prototype.disableSpellChecking=function(){this.acroField.setFlagTo(AcroChoiceFlags.DoNotSpellCheck,!0)},e.prototype.isSelectOnClick=function(){return this.acroField.hasFlag(AcroChoiceFlags.CommitOnSelChange)},e.prototype.enableSelectOnClick=function(){this.acroField.setFlagTo(AcroChoiceFlags.CommitOnSelChange,!0)},e.prototype.disableSelectOnClick=function(){this.acroField.setFlagTo(AcroChoiceFlags.CommitOnSelChange,!1)},e.prototype.addToPage=function(r,n){var a,s,o,h,d,l,u;assertIs(r,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(n),n||(n={}),"textColor"in n||(n.textColor=rgb(0,0,0)),"backgroundColor"in n||(n.backgroundColor=rgb(1,1,1)),"borderColor"in n||(n.borderColor=rgb(0,0,0)),"borderWidth"in n||(n.borderWidth=1);var p=this.createWidget({x:(a=n.x)!==null&&a!==void 0?a:0,y:(s=n.y)!==null&&s!==void 0?s:0,width:(o=n.width)!==null&&o!==void 0?o:200,height:(h=n.height)!==null&&h!==void 0?h:50,textColor:n.textColor,backgroundColor:n.backgroundColor,borderColor:n.borderColor,borderWidth:(d=n.borderWidth)!==null&&d!==void 0?d:0,rotate:(l=n.rotate)!==null&&l!==void 0?l:degrees(0),hidden:n.hidden,page:r.ref}),g=this.doc.context.register(p.dict);this.acroField.addWidget(g);var f=(u=n.font)!==null&&u!==void 0?u:this.doc.getForm().getDefaultFont();this.updateWidgetAppearance(p,f),r.node.addAnnot(g)},e.prototype.needsAppearancesUpdate=function(){var r;if(this.isDirty())return!0;for(var n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=((r=o.getAppearances())===null||r===void 0?void 0:r.normal)instanceof PDFStream;if(!h)return!0}return!1},e.prototype.defaultUpdateAppearances=function(r){assertIs(r,"font",[[PDFFont,"PDFFont"]]),this.updateAppearances(r)},e.prototype.updateAppearances=function(r,n){assertIs(r,"font",[[PDFFont,"PDFFont"]]),assertOrUndefined(n,"provider",[Function]);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s];this.updateWidgetAppearance(h,r,n)}this.markAsClean()},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultDropdownAppearanceProvider,o=normalizeAppearance(s(this,r,n));this.updateWidgetAppearanceWithFont(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),PDFOptionList=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroListBox",[[PDFAcroListBox,"PDFAcroListBox"]]),s.acroField=r,s}return e.prototype.getOptions=function(){for(var r=this.acroField.getOptions(),n=new Array(r.length),a=0,s=n.length;a<s;a++){var o=r[a],h=o.display,d=o.value;n[a]=(h??d).decodeText()}return n},e.prototype.getSelected=function(){for(var r=this.acroField.getValues(),n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]=r[a].decodeText();return n},e.prototype.setOptions=function(r){assertIs(r,"options",[Array]),this.markAsDirty();for(var n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]={value:PDFHexString.fromText(r[a])};this.acroField.setOptions(n)},e.prototype.addOptions=function(r){assertIs(r,"options",["string",Array]),this.markAsDirty();for(var n=Array.isArray(r)?r:[r],a=this.acroField.getOptions(),s=new Array(n.length),o=0,h=n.length;o<h;o++)s[o]={value:PDFHexString.fromText(n[o])};this.acroField.setOptions(a.concat(s))},e.prototype.select=function(r,n){n===void 0&&(n=!1),assertIs(r,"options",["string",Array]),assertIs(n,"merge",["boolean"]);var a=Array.isArray(r)?r:[r],s=this.getOptions();assertIsSubset(a,"option",s),this.markAsDirty(),(a.length>1||a.length===1&&n)&&this.enableMultiselect();for(var o=new Array(a.length),h=0,d=a.length;h<d;h++)o[h]=PDFHexString.fromText(a[h]);if(n){var l=this.acroField.getValues();this.acroField.setValues(l.concat(o))}else this.acroField.setValues(o)},e.prototype.clear=function(){this.markAsDirty(),this.acroField.setValues([])},e.prototype.setFontSize=function(r){assertPositive(r,"fontSize"),this.acroField.setFontSize(r),this.markAsDirty()},e.prototype.isSorted=function(){return this.acroField.hasFlag(AcroChoiceFlags.Sort)},e.prototype.enableSorting=function(){this.acroField.setFlagTo(AcroChoiceFlags.Sort,!0)},e.prototype.disableSorting=function(){this.acroField.setFlagTo(AcroChoiceFlags.Sort,!1)},e.prototype.isMultiselect=function(){return this.acroField.hasFlag(AcroChoiceFlags.MultiSelect)},e.prototype.enableMultiselect=function(){this.acroField.setFlagTo(AcroChoiceFlags.MultiSelect,!0)},e.prototype.disableMultiselect=function(){this.acroField.setFlagTo(AcroChoiceFlags.MultiSelect,!1)},e.prototype.isSelectOnClick=function(){return this.acroField.hasFlag(AcroChoiceFlags.CommitOnSelChange)},e.prototype.enableSelectOnClick=function(){this.acroField.setFlagTo(AcroChoiceFlags.CommitOnSelChange,!0)},e.prototype.disableSelectOnClick=function(){this.acroField.setFlagTo(AcroChoiceFlags.CommitOnSelChange,!1)},e.prototype.addToPage=function(r,n){var a,s,o,h,d,l,u;assertIs(r,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(n),n||(n={}),"textColor"in n||(n.textColor=rgb(0,0,0)),"backgroundColor"in n||(n.backgroundColor=rgb(1,1,1)),"borderColor"in n||(n.borderColor=rgb(0,0,0)),"borderWidth"in n||(n.borderWidth=1);var p=this.createWidget({x:(a=n.x)!==null&&a!==void 0?a:0,y:(s=n.y)!==null&&s!==void 0?s:0,width:(o=n.width)!==null&&o!==void 0?o:200,height:(h=n.height)!==null&&h!==void 0?h:100,textColor:n.textColor,backgroundColor:n.backgroundColor,borderColor:n.borderColor,borderWidth:(d=n.borderWidth)!==null&&d!==void 0?d:0,rotate:(l=n.rotate)!==null&&l!==void 0?l:degrees(0),hidden:n.hidden,page:r.ref}),g=this.doc.context.register(p.dict);this.acroField.addWidget(g);var f=(u=n.font)!==null&&u!==void 0?u:this.doc.getForm().getDefaultFont();this.updateWidgetAppearance(p,f),r.node.addAnnot(g)},e.prototype.needsAppearancesUpdate=function(){var r;if(this.isDirty())return!0;for(var n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=((r=o.getAppearances())===null||r===void 0?void 0:r.normal)instanceof PDFStream;if(!h)return!0}return!1},e.prototype.defaultUpdateAppearances=function(r){assertIs(r,"font",[[PDFFont,"PDFFont"]]),this.updateAppearances(r)},e.prototype.updateAppearances=function(r,n){assertIs(r,"font",[[PDFFont,"PDFFont"]]),assertOrUndefined(n,"provider",[Function]);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s];this.updateWidgetAppearance(h,r,n)}this.markAsClean()},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultOptionListAppearanceProvider,o=normalizeAppearance(s(this,r,n));this.updateWidgetAppearanceWithFont(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),PDFRadioGroup=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroRadioButton",[[PDFAcroRadioButton,"PDFAcroRadioButton"]]),s.acroField=r,s}return e.prototype.getOptions=function(){var r=this.acroField.getExportValues();if(r){for(var n=new Array(r.length),a=0,s=r.length;a<s;a++)n[a]=r[a].decodeText();return n}for(var o=this.acroField.getOnValues(),h=new Array(o.length),a=0,s=h.length;a<s;a++)h[a]=o[a].decodeText();return h},e.prototype.getSelected=function(){var r=this.acroField.getValue();if(r!==PDFName.of("Off")){var n=this.acroField.getExportValues();if(n){for(var a=this.acroField.getOnValues(),s=0,o=a.length;s<o;s++)if(a[s]===r)return n[s].decodeText()}return r.decodeText()}},e.prototype.select=function(r){assertIs(r,"option",["string"]);var n=this.getOptions();assertIsOneOf(r,"option",n),this.markAsDirty();var a=this.acroField.getOnValues(),s=this.acroField.getExportValues();if(s)for(var o=0,h=s.length;o<h;o++)s[o].decodeText()===r&&this.acroField.setValue(a[o]);else for(var o=0,h=a.length;o<h;o++){var d=a[o];d.decodeText()===r&&this.acroField.setValue(d)}},e.prototype.clear=function(){this.markAsDirty(),this.acroField.setValue(PDFName.of("Off"))},e.prototype.isOffToggleable=function(){return!this.acroField.hasFlag(AcroButtonFlags.NoToggleToOff)},e.prototype.enableOffToggling=function(){this.acroField.setFlagTo(AcroButtonFlags.NoToggleToOff,!1)},e.prototype.disableOffToggling=function(){this.acroField.setFlagTo(AcroButtonFlags.NoToggleToOff,!0)},e.prototype.isMutuallyExclusive=function(){return!this.acroField.hasFlag(AcroButtonFlags.RadiosInUnison)},e.prototype.enableMutualExclusion=function(){this.acroField.setFlagTo(AcroButtonFlags.RadiosInUnison,!1)},e.prototype.disableMutualExclusion=function(){this.acroField.setFlagTo(AcroButtonFlags.RadiosInUnison,!0)},e.prototype.addOptionToPage=function(r,n,a){var s,o,h,d,l,u,p,g,f;assertIs(r,"option",["string"]),assertIs(n,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(a);var v=this.createWidget({x:(s=a==null?void 0:a.x)!==null&&s!==void 0?s:0,y:(o=a==null?void 0:a.y)!==null&&o!==void 0?o:0,width:(h=a==null?void 0:a.width)!==null&&h!==void 0?h:50,height:(d=a==null?void 0:a.height)!==null&&d!==void 0?d:50,textColor:(l=a==null?void 0:a.textColor)!==null&&l!==void 0?l:rgb(0,0,0),backgroundColor:(u=a==null?void 0:a.backgroundColor)!==null&&u!==void 0?u:rgb(1,1,1),borderColor:(p=a==null?void 0:a.borderColor)!==null&&p!==void 0?p:rgb(0,0,0),borderWidth:(g=a==null?void 0:a.borderWidth)!==null&&g!==void 0?g:1,rotate:(f=a==null?void 0:a.rotate)!==null&&f!==void 0?f:degrees(0),hidden:a==null?void 0:a.hidden,page:n.ref}),y=this.doc.context.register(v.dict),S=this.acroField.addWidgetWithOpt(y,PDFHexString.fromText(r),!this.isMutuallyExclusive());v.setAppearanceState(PDFName.of("Off")),this.updateWidgetAppearance(v,S),n.node.addAnnot(y)},e.prototype.needsAppearancesUpdate=function(){for(var r,n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=o.getAppearanceState(),d=(r=o.getAppearances())===null||r===void 0?void 0:r.normal;if(!(d instanceof PDFDict)||h&&!d.has(h))return!0}return!1},e.prototype.defaultUpdateAppearances=function(){this.updateAppearances()},e.prototype.updateAppearances=function(r){assertOrUndefined(r,"provider",[Function]);for(var n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=o.getOnValue();h&&this.updateWidgetAppearance(o,h,r)}},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultRadioGroupAppearanceProvider,o=normalizeAppearance(s(this,r));this.updateOnOffWidgetAppearance(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),PDFSignature=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroSignature",[[PDFAcroSignature,"PDFAcroSignature"]]),s.acroField=r,s}return e.prototype.needsAppearancesUpdate=function(){return!1},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),PDFTextField=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroText",[[PDFAcroText,"PDFAcroText"]]),s.acroField=r,s}return e.prototype.getText=function(){var r=this.acroField.getValue();if(!r&&this.isRichFormatted())throw new RichTextFieldReadError(this.getName());return r==null?void 0:r.decodeText()},e.prototype.setText=function(r){assertOrUndefined(r,"text",["string"]);var n=this.getMaxLength();if(n!==void 0&&r&&r.length>n)throw new ExceededMaxLengthError(r.length,n,this.getName());this.markAsDirty(),this.disableRichFormatting(),r?this.acroField.setValue(PDFHexString.fromText(r)):this.acroField.removeValue()},e.prototype.getAlignment=function(){var r=this.acroField.getQuadding();return r===0?TextAlignment.Left:r===1?TextAlignment.Center:r===2?TextAlignment.Right:TextAlignment.Left},e.prototype.setAlignment=function(r){assertIsOneOf(r,"alignment",TextAlignment),this.markAsDirty(),this.acroField.setQuadding(r)},e.prototype.getMaxLength=function(){return this.acroField.getMaxLength()},e.prototype.setMaxLength=function(r){if(assertRangeOrUndefined(r,"maxLength",0,Number.MAX_SAFE_INTEGER),this.markAsDirty(),r===void 0)this.acroField.removeMaxLength();else{var n=this.getText();if(n&&n.length>r)throw new InvalidMaxLengthError(n.length,r,this.getName());this.acroField.setMaxLength(r)}},e.prototype.removeMaxLength=function(){this.markAsDirty(),this.acroField.removeMaxLength()},e.prototype.setImage=function(r){for(var n=this.getAlignment(),a=n===TextAlignment.Center?ImageAlignment.Center:n===TextAlignment.Right?ImageAlignment.Right:ImageAlignment.Left,s=this.acroField.getWidgets(),o=0,h=s.length;o<h;o++){var d=s[o],l=this.createImageAppearanceStream(d,r,a);this.updateWidgetAppearances(d,{normal:l})}this.markAsClean()},e.prototype.setFontSize=function(r){assertPositive(r,"fontSize"),this.acroField.setFontSize(r),this.markAsDirty()},e.prototype.isMultiline=function(){return this.acroField.hasFlag(AcroTextFlags.Multiline)},e.prototype.enableMultiline=function(){this.markAsDirty(),this.acroField.setFlagTo(AcroTextFlags.Multiline,!0)},e.prototype.disableMultiline=function(){this.markAsDirty(),this.acroField.setFlagTo(AcroTextFlags.Multiline,!1)},e.prototype.isPassword=function(){return this.acroField.hasFlag(AcroTextFlags.Password)},e.prototype.enablePassword=function(){this.acroField.setFlagTo(AcroTextFlags.Password,!0)},e.prototype.disablePassword=function(){this.acroField.setFlagTo(AcroTextFlags.Password,!1)},e.prototype.isFileSelector=function(){return this.acroField.hasFlag(AcroTextFlags.FileSelect)},e.prototype.enableFileSelection=function(){this.acroField.setFlagTo(AcroTextFlags.FileSelect,!0)},e.prototype.disableFileSelection=function(){this.acroField.setFlagTo(AcroTextFlags.FileSelect,!1)},e.prototype.isSpellChecked=function(){return!this.acroField.hasFlag(AcroTextFlags.DoNotSpellCheck)},e.prototype.enableSpellChecking=function(){this.acroField.setFlagTo(AcroTextFlags.DoNotSpellCheck,!1)},e.prototype.disableSpellChecking=function(){this.acroField.setFlagTo(AcroTextFlags.DoNotSpellCheck,!0)},e.prototype.isScrollable=function(){return!this.acroField.hasFlag(AcroTextFlags.DoNotScroll)},e.prototype.enableScrolling=function(){this.acroField.setFlagTo(AcroTextFlags.DoNotScroll,!1)},e.prototype.disableScrolling=function(){this.acroField.setFlagTo(AcroTextFlags.DoNotScroll,!0)},e.prototype.isCombed=function(){return this.acroField.hasFlag(AcroTextFlags.Comb)&&!this.isMultiline()&&!this.isPassword()&&!this.isFileSelector()&&this.getMaxLength()!==void 0},e.prototype.enableCombing=function(){if(this.getMaxLength()===void 0){var r="PDFTextFields must have a max length in order to be combed";console.warn(r)}this.markAsDirty(),this.disableMultiline(),this.disablePassword(),this.disableFileSelection(),this.acroField.setFlagTo(AcroTextFlags.Comb,!0)},e.prototype.disableCombing=function(){this.markAsDirty(),this.acroField.setFlagTo(AcroTextFlags.Comb,!1)},e.prototype.isRichFormatted=function(){return this.acroField.hasFlag(AcroTextFlags.RichText)},e.prototype.enableRichFormatting=function(){this.acroField.setFlagTo(AcroTextFlags.RichText,!0)},e.prototype.disableRichFormatting=function(){this.acroField.setFlagTo(AcroTextFlags.RichText,!1)},e.prototype.addToPage=function(r,n){var a,s,o,h,d,l,u;assertIs(r,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(n),n||(n={}),"textColor"in n||(n.textColor=rgb(0,0,0)),"backgroundColor"in n||(n.backgroundColor=rgb(1,1,1)),"borderColor"in n||(n.borderColor=rgb(0,0,0)),"borderWidth"in n||(n.borderWidth=1);var p=this.createWidget({x:(a=n.x)!==null&&a!==void 0?a:0,y:(s=n.y)!==null&&s!==void 0?s:0,width:(o=n.width)!==null&&o!==void 0?o:200,height:(h=n.height)!==null&&h!==void 0?h:50,textColor:n.textColor,backgroundColor:n.backgroundColor,borderColor:n.borderColor,borderWidth:(d=n.borderWidth)!==null&&d!==void 0?d:0,rotate:(l=n.rotate)!==null&&l!==void 0?l:degrees(0),hidden:n.hidden,page:r.ref}),g=this.doc.context.register(p.dict);this.acroField.addWidget(g);var f=(u=n.font)!==null&&u!==void 0?u:this.doc.getForm().getDefaultFont();this.updateWidgetAppearance(p,f),r.node.addAnnot(g)},e.prototype.needsAppearancesUpdate=function(){var r;if(this.isDirty())return!0;for(var n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=((r=o.getAppearances())===null||r===void 0?void 0:r.normal)instanceof PDFStream;if(!h)return!0}return!1},e.prototype.defaultUpdateAppearances=function(r){assertIs(r,"font",[[PDFFont,"PDFFont"]]),this.updateAppearances(r)},e.prototype.updateAppearances=function(r,n){assertIs(r,"font",[[PDFFont,"PDFFont"]]),assertOrUndefined(n,"provider",[Function]);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s];this.updateWidgetAppearance(h,r,n)}this.markAsClean()},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultTextFieldAppearanceProvider,o=normalizeAppearance(s(this,r,n));this.updateWidgetAppearanceWithFont(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField),StandardFonts;(function(t){t.Courier="Courier",t.CourierBold="Courier-Bold",t.CourierOblique="Courier-Oblique",t.CourierBoldOblique="Courier-BoldOblique",t.Helvetica="Helvetica",t.HelveticaBold="Helvetica-Bold",t.HelveticaOblique="Helvetica-Oblique",t.HelveticaBoldOblique="Helvetica-BoldOblique",t.TimesRoman="Times-Roman",t.TimesRomanBold="Times-Bold",t.TimesRomanItalic="Times-Italic",t.TimesRomanBoldItalic="Times-BoldItalic",t.Symbol="Symbol",t.ZapfDingbats="ZapfDingbats"})(StandardFonts||(StandardFonts={}));var PDFForm=function(){function t(e,r){var n=this;this.embedDefaultFont=function(){return n.doc.embedStandardFont(StandardFonts.Helvetica)},assertIs(e,"acroForm",[[PDFAcroForm,"PDFAcroForm"]]),assertIs(r,"doc",[[PDFDocument,"PDFDocument"]]),this.acroForm=e,this.doc=r,this.dirtyFields=new Set,this.defaultFontCache=Cache.populatedBy(this.embedDefaultFont)}return t.prototype.hasXFA=function(){return this.acroForm.dict.has(PDFName.of("XFA"))},t.prototype.deleteXFA=function(){this.acroForm.dict.delete(PDFName.of("XFA"))},t.prototype.getFields=function(){for(var e=this.acroForm.getAllFields(),r=[],n=0,a=e.length;n<a;n++){var s=e[n],o=s[0],h=s[1],d=convertToPDFField(o,h,this.doc);d&&r.push(d)}return r},t.prototype.getFieldMaybe=function(e){assertIs(e,"name",["string"]);for(var r=this.getFields(),n=0,a=r.length;n<a;n++){var s=r[n];if(s.getName()===e)return s}},t.prototype.getField=function(e){assertIs(e,"name",["string"]);var r=this.getFieldMaybe(e);if(r)return r;throw new NoSuchFieldError(e)},t.prototype.getButton=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFButton)return r;throw new UnexpectedFieldTypeError(e,PDFButton,r)},t.prototype.getCheckBox=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFCheckBox)return r;throw new UnexpectedFieldTypeError(e,PDFCheckBox,r)},t.prototype.getDropdown=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFDropdown)return r;throw new UnexpectedFieldTypeError(e,PDFDropdown,r)},t.prototype.getOptionList=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFOptionList)return r;throw new UnexpectedFieldTypeError(e,PDFOptionList,r)},t.prototype.getRadioGroup=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFRadioGroup)return r;throw new UnexpectedFieldTypeError(e,PDFRadioGroup,r)},t.prototype.getSignature=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFSignature)return r;throw new UnexpectedFieldTypeError(e,PDFSignature,r)},t.prototype.getTextField=function(e){assertIs(e,"name",["string"]);var r=this.getField(e);if(r instanceof PDFTextField)return r;throw new UnexpectedFieldTypeError(e,PDFTextField,r)},t.prototype.createButton=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroPushButton.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFButton.of(a,a.ref,this.doc)},t.prototype.createCheckBox=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroCheckBox.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFCheckBox.of(a,a.ref,this.doc)},t.prototype.createDropdown=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroComboBox.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFDropdown.of(a,a.ref,this.doc)},t.prototype.createOptionList=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroListBox.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFOptionList.of(a,a.ref,this.doc)},t.prototype.createRadioGroup=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroRadioButton.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFRadioGroup.of(a,a.ref,this.doc)},t.prototype.createTextField=function(e){assertIs(e,"name",["string"]);var r=splitFieldName(e),n=this.findOrCreateNonTerminals(r.nonTerminal),a=PDFAcroText.create(this.doc.context);return a.setPartialName(r.terminal),addFieldToParent(n,[a,a.ref],r.terminal),PDFTextField.of(a,a.ref,this.doc)},t.prototype.flatten=function(e){e===void 0&&(e={updateFieldAppearances:!0}),e.updateFieldAppearances&&this.updateFieldAppearances();for(var r=this.getFields(),n=0,a=r.length;n<a;n++){for(var s=r[n],o=s.acroField.getWidgets(),h=0,d=o.length;h<d;h++){var l=o[h],u=this.findWidgetPage(l),p=this.findWidgetAppearanceRef(s,l),g=u.node.newXObject("FlatWidget",p),f=l.getRectangle(),v=__spreadArrays([pushGraphicsState(),translate(f.x,f.y)],rotateInPlace(__assign(__assign({},f),{rotation:0})),[drawObject(g),popGraphicsState()]).filter(Boolean);u.pushOperators.apply(u,v)}this.removeField(s)}},t.prototype.removeField=function(e){for(var r=e.acroField.getWidgets(),n=new Set,a=0,s=r.length;a<s;a++){var o=r[a],h=this.findWidgetAppearanceRef(e,o),d=this.findWidgetPage(o);n.add(d),d.node.removeAnnot(h)}n.forEach(function(f){return f.node.removeAnnot(e.ref)}),this.acroForm.removeField(e.acroField);for(var l=e.acroField.normalizedEntries().Kids,u=l.size(),p=0;p<u;p++){var g=l.get(p);g instanceof PDFRef&&this.doc.context.delete(g)}this.doc.context.delete(e.ref)},t.prototype.updateFieldAppearances=function(e){assertOrUndefined(e,"font",[[PDFFont,"PDFFont"]]),e=e??this.getDefaultFont();for(var r=this.getFields(),n=0,a=r.length;n<a;n++){var s=r[n];s.needsAppearancesUpdate()&&s.defaultUpdateAppearances(e)}},t.prototype.markFieldAsDirty=function(e){assertOrUndefined(e,"fieldRef",[[PDFRef,"PDFRef"]]),this.dirtyFields.add(e)},t.prototype.markFieldAsClean=function(e){assertOrUndefined(e,"fieldRef",[[PDFRef,"PDFRef"]]),this.dirtyFields.delete(e)},t.prototype.fieldIsDirty=function(e){return assertOrUndefined(e,"fieldRef",[[PDFRef,"PDFRef"]]),this.dirtyFields.has(e)},t.prototype.getDefaultFont=function(){return this.defaultFontCache.access()},t.prototype.findWidgetPage=function(e){var r=e.P(),n=this.doc.getPages().find(function(s){return s.ref===r});if(n===void 0){var a=this.doc.context.getObjectRef(e.dict);if(a===void 0)throw new Error("Could not find PDFRef for PDFObject");if(n=this.doc.findPageForAnnotationRef(a),n===void 0)throw new Error("Could not find page for PDFRef "+a)}return n},t.prototype.findWidgetAppearanceRef=function(e,r){var n,a=r.getNormalAppearance();if(a instanceof PDFDict&&(e instanceof PDFCheckBox||e instanceof PDFRadioGroup)){var s=e.acroField.getValue(),o=(n=a.get(s))!==null&&n!==void 0?n:a.get(PDFName.of("Off"));o instanceof PDFRef&&(a=o)}if(!(a instanceof PDFRef)){var h=e.getName();throw new Error("Failed to extract appearance ref for: "+h)}return a},t.prototype.findOrCreateNonTerminals=function(e){for(var r=[this.acroForm],n=0,a=e.length;n<a;n++){var s=e[n];if(!s)throw new InvalidFieldNamePartError(s);var o=r[0],h=r[1],d=this.findNonTerminal(s,o);if(d)r=d;else{var l=PDFAcroNonTerminal.create(this.doc.context);l.setPartialName(s),l.setParent(h);var u=this.doc.context.register(l.dict);o.addField(u),r=[l,u]}}return r},t.prototype.findNonTerminal=function(e,r){for(var n=r instanceof PDFAcroForm?this.acroForm.getFields():createPDFAcroFields(r.Kids()),a=0,s=n.length;a<s;a++){var o=n[a],h=o[0],d=o[1];if(h.getPartialName()===e){if(h instanceof PDFAcroNonTerminal)return[h,d];throw new FieldAlreadyExistsError(e)}}},t.of=function(e,r){return new t(e,r)},t}(),convertToPDFField=function(t,e,r){if(t instanceof PDFAcroPushButton)return PDFButton.of(t,e,r);if(t instanceof PDFAcroCheckBox)return PDFCheckBox.of(t,e,r);if(t instanceof PDFAcroComboBox)return PDFDropdown.of(t,e,r);if(t instanceof PDFAcroListBox)return PDFOptionList.of(t,e,r);if(t instanceof PDFAcroText)return PDFTextField.of(t,e,r);if(t instanceof PDFAcroRadioButton)return PDFRadioGroup.of(t,e,r);if(t instanceof PDFAcroSignature)return PDFSignature.of(t,e,r)},splitFieldName=function(t){if(t.length===0)throw new Error("PDF field names must not be empty strings");for(var e=t.split("."),r=0,n=e.length;r<n;r++)if(e[r]==="")throw new Error('Periods in PDF field names must be separated by at least one character: "'+t+'"');return e.length===1?{nonTerminal:[],terminal:e[0]}:{nonTerminal:e.slice(0,e.length-1),terminal:e[e.length-1]}},addFieldToParent=function(t,e,r){for(var n=t[0],a=t[1],s=e[0],o=e[1],h=n.normalizedEntries(),d=createPDFAcroFields("Kids"in h?h.Kids:h.Fields),l=0,u=d.length;l<u;l++)if(d[l][0].getPartialName()===r)throw new FieldAlreadyExistsError(r);n.addField(o),s.setParent(a)},PageSizes={A4:[595.28,841.89]},ParseSpeeds;(function(t){t[t.Fastest=1/0]="Fastest",t[t.Fast=1500]="Fast",t[t.Medium=500]="Medium",t[t.Slow=100]="Slow"})(ParseSpeeds||(ParseSpeeds={}));var PDFEmbeddedFile=function(){function t(e,r,n){this.alreadyEmbedded=!1,this.ref=e,this.doc=r,this.embedder=n}return t.prototype.embed=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n,a,s;return __generator(this,function(o){switch(o.label){case 0:return this.alreadyEmbedded?[3,2]:[4,this.embedder.embedIntoContext(this.doc.context,this.ref)];case 1:e=o.sent(),this.doc.catalog.has(PDFName.of("Names"))||this.doc.catalog.set(PDFName.of("Names"),this.doc.context.obj({})),r=this.doc.catalog.lookup(PDFName.of("Names"),PDFDict),r.has(PDFName.of("EmbeddedFiles"))||r.set(PDFName.of("EmbeddedFiles"),this.doc.context.obj({})),n=r.lookup(PDFName.of("EmbeddedFiles"),PDFDict),n.has(PDFName.of("Names"))||n.set(PDFName.of("Names"),this.doc.context.obj([])),a=n.lookup(PDFName.of("Names"),PDFArray),a.push(PDFHexString.fromText(this.embedder.fileName)),a.push(e),this.doc.catalog.has(PDFName.of("AF"))||this.doc.catalog.set(PDFName.of("AF"),this.doc.context.obj([])),s=this.doc.catalog.lookup(PDFName.of("AF"),PDFArray),s.push(e),this.alreadyEmbedded=!0,o.label=2;case 2:return[2]}})})},t.of=function(e,r,n){return new t(e,r,n)},t}(),PDFJavaScript=function(){function t(e,r,n){this.alreadyEmbedded=!1,this.ref=e,this.doc=r,this.embedder=n}return t.prototype.embed=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n,a,s,o,h;return __generator(this,function(d){switch(d.label){case 0:return this.alreadyEmbedded?[3,2]:(e=this.doc,r=e.catalog,n=e.context,[4,this.embedder.embedIntoContext(this.doc.context,this.ref)]);case 1:a=d.sent(),r.has(PDFName.of("Names"))||r.set(PDFName.of("Names"),n.obj({})),s=r.lookup(PDFName.of("Names"),PDFDict),s.has(PDFName.of("JavaScript"))||s.set(PDFName.of("JavaScript"),n.obj({})),o=s.lookup(PDFName.of("JavaScript"),PDFDict),o.has(PDFName.of("Names"))||o.set(PDFName.of("Names"),n.obj([])),h=o.lookup(PDFName.of("Names"),PDFArray),h.push(PDFHexString.fromText(this.embedder.scriptName)),h.push(a),this.alreadyEmbedded=!0,d.label=2;case 2:return[2]}})})},t.of=function(e,r,n){return new t(e,r,n)},t}(),JavaScriptEmbedder=function(){function t(e,r){this.script=e,this.scriptName=r}return t.for=function(e,r){return new t(e,r)},t.prototype.embedIntoContext=function(e,r){return __awaiter(this,void 0,void 0,function(){var n;return __generator(this,function(a){return n=e.obj({Type:"Action",S:"JavaScript",JS:PDFHexString.fromText(this.script)}),r?(e.assign(r,n),[2,r]):[2,e.register(n)]})})},t}(),PDFDocument=function(){function t(e,r,n){var a=this;if(this.defaultWordBreaks=[" "],this.computePages=function(){var s=[];return a.catalog.Pages().traverse(function(o,h){if(o instanceof PDFPageLeaf){var d=a.pageMap.get(o);d||(d=PDFPage.of(o,h,a),a.pageMap.set(o,d)),s.push(d)}}),s},this.getOrCreateForm=function(){var s=a.catalog.getOrCreateAcroForm();return PDFForm.of(s,a)},assertIs(e,"context",[[PDFContext,"PDFContext"]]),assertIs(r,"ignoreEncryption",["boolean"]),this.context=e,this.catalog=e.lookup(e.trailerInfo.Root),this.isEncrypted=!!e.lookup(e.trailerInfo.Encrypt),this.pageCache=Cache.populatedBy(this.computePages),this.pageMap=new Map,this.formCache=Cache.populatedBy(this.getOrCreateForm),this.fonts=[],this.images=[],this.embeddedPages=[],this.embeddedFiles=[],this.javaScripts=[],!r&&this.isEncrypted)throw new EncryptedPDFError;n&&this.updateInfoDict()}return t.load=function(e,r){return r===void 0&&(r={}),__awaiter(this,void 0,void 0,function(){var n,a,s,o,h,d,l,u,p,g,f,v;return __generator(this,function(y){switch(y.label){case 0:return n=r.ignoreEncryption,a=n===void 0?!1:n,s=r.parseSpeed,o=s===void 0?ParseSpeeds.Slow:s,h=r.throwOnInvalidObject,d=h===void 0?!1:h,l=r.updateMetadata,u=l===void 0?!0:l,p=r.capNumbers,g=p===void 0?!1:p,assertIs(e,"pdf",["string",Uint8Array,ArrayBuffer]),assertIs(a,"ignoreEncryption",["boolean"]),assertIs(o,"parseSpeed",["number"]),assertIs(d,"throwOnInvalidObject",["boolean"]),f=toUint8Array(e),[4,PDFParser.forBytesWithOptions(f,o,d,g).parseDocument()];case 1:return v=y.sent(),[2,new t(v,a,u)]}})})},t.create=function(e){return e===void 0&&(e={}),__awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h;return __generator(this,function(d){return r=e.updateMetadata,n=r===void 0?!0:r,a=PDFContext.create(),s=PDFPageTree.withContext(a),o=a.register(s),h=PDFCatalog.withContextAndPages(a,o),a.trailerInfo.Root=a.register(h),[2,new t(a,!1,n)]})})},t.prototype.registerFontkit=function(e){this.fontkit=e},t.prototype.getForm=function(){var e=this.formCache.access();return e.hasXFA()&&(console.warn("Removing XFA form data as pdf-lib does not support reading or writing XFA"),e.deleteXFA()),e},t.prototype.getTitle=function(){var e=this.getInfoDict().lookup(PDFName.Title);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getAuthor=function(){var e=this.getInfoDict().lookup(PDFName.Author);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getSubject=function(){var e=this.getInfoDict().lookup(PDFName.Subject);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getKeywords=function(){var e=this.getInfoDict().lookup(PDFName.Keywords);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getCreator=function(){var e=this.getInfoDict().lookup(PDFName.Creator);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getProducer=function(){var e=this.getInfoDict().lookup(PDFName.Producer);if(e)return assertIsLiteralOrHexString(e),e.decodeText()},t.prototype.getCreationDate=function(){var e=this.getInfoDict().lookup(PDFName.CreationDate);if(e)return assertIsLiteralOrHexString(e),e.decodeDate()},t.prototype.getModificationDate=function(){var e=this.getInfoDict().lookup(PDFName.ModDate);if(e)return assertIsLiteralOrHexString(e),e.decodeDate()},t.prototype.setTitle=function(e,r){assertIs(e,"title",["string"]);var n=PDFName.of("Title");if(this.getInfoDict().set(n,PDFHexString.fromText(e)),r!=null&&r.showInWindowTitleBar){var a=this.catalog.getOrCreateViewerPreferences();a.setDisplayDocTitle(!0)}},t.prototype.setAuthor=function(e){assertIs(e,"author",["string"]);var r=PDFName.of("Author");this.getInfoDict().set(r,PDFHexString.fromText(e))},t.prototype.setSubject=function(e){assertIs(e,"author",["string"]);var r=PDFName.of("Subject");this.getInfoDict().set(r,PDFHexString.fromText(e))},t.prototype.setKeywords=function(e){assertIs(e,"keywords",[Array]);var r=PDFName.of("Keywords");this.getInfoDict().set(r,PDFHexString.fromText(e.join(" ")))},t.prototype.setCreator=function(e){assertIs(e,"creator",["string"]);var r=PDFName.of("Creator");this.getInfoDict().set(r,PDFHexString.fromText(e))},t.prototype.setProducer=function(e){assertIs(e,"creator",["string"]);var r=PDFName.of("Producer");this.getInfoDict().set(r,PDFHexString.fromText(e))},t.prototype.setLanguage=function(e){assertIs(e,"language",["string"]);var r=PDFName.of("Lang");this.catalog.set(r,PDFString.of(e))},t.prototype.setCreationDate=function(e){assertIs(e,"creationDate",[[Date,"Date"]]);var r=PDFName.of("CreationDate");this.getInfoDict().set(r,PDFString.fromDate(e))},t.prototype.setModificationDate=function(e){assertIs(e,"modificationDate",[[Date,"Date"]]);var r=PDFName.of("ModDate");this.getInfoDict().set(r,PDFString.fromDate(e))},t.prototype.getPageCount=function(){return this.pageCount===void 0&&(this.pageCount=this.getPages().length),this.pageCount},t.prototype.getPages=function(){return this.pageCache.access()},t.prototype.getPage=function(e){var r=this.getPages();return assertRange(e,"index",0,r.length-1),r[e]},t.prototype.getPageIndices=function(){return range(0,this.getPageCount())},t.prototype.removePage=function(e){var r=this.getPageCount();if(this.pageCount===0)throw new RemovePageFromEmptyDocumentError;assertRange(e,"index",0,r-1),this.catalog.removeLeafNode(e),this.pageCount=r-1},t.prototype.addPage=function(e){return assertIs(e,"page",["undefined",[PDFPage,"PDFPage"],Array]),this.insertPage(this.getPageCount(),e)},t.prototype.insertPage=function(e,r){var n=this.getPageCount();if(assertRange(e,"index",0,n),assertIs(r,"page",["undefined",[PDFPage,"PDFPage"],Array]),!r||Array.isArray(r)){var a=Array.isArray(r)?r:PageSizes.A4;r=PDFPage.create(this),r.setSize.apply(r,a)}else if(r.doc!==this)throw new ForeignPageError;var s=this.catalog.insertLeafNode(r.ref,e);return r.node.setParent(s),this.pageMap.set(r.node,r),this.pageCache.invalidate(),this.pageCount=n+1,r},t.prototype.copyPages=function(e,r){return __awaiter(this,void 0,void 0,function(){var n,a,s,o,h,d,l,u;return __generator(this,function(p){switch(p.label){case 0:return assertIs(e,"srcDoc",[[t,"PDFDocument"]]),assertIs(r,"indices",[Array]),[4,e.flush()];case 1:for(p.sent(),n=PDFObjectCopier.for(e.context,this.context),a=e.getPages(),s=new Array(r.length),o=0,h=r.length;o<h;o++)d=a[r[o]],l=n.copy(d.node),u=this.context.register(l),s[o]=PDFPage.of(l,u,this);return[2,s]}})})},t.prototype.copy=function(){return __awaiter(this,void 0,void 0,function(){var e,r,n,a;return __generator(this,function(s){switch(s.label){case 0:return[4,t.create()];case 1:return e=s.sent(),[4,e.copyPages(this,this.getPageIndices())];case 2:for(r=s.sent(),n=0,a=r.length;n<a;n++)e.addPage(r[n]);return this.getAuthor()!==void 0&&e.setAuthor(this.getAuthor()),this.getCreationDate()!==void 0&&e.setCreationDate(this.getCreationDate()),this.getCreator()!==void 0&&e.setCreator(this.getCreator()),this.getModificationDate()!==void 0&&e.setModificationDate(this.getModificationDate()),this.getProducer()!==void 0&&e.setProducer(this.getProducer()),this.getSubject()!==void 0&&e.setSubject(this.getSubject()),this.getTitle()!==void 0&&e.setTitle(this.getTitle()),e.defaultWordBreaks=this.defaultWordBreaks,[2,e]}})})},t.prototype.addJavaScript=function(e,r){assertIs(e,"name",["string"]),assertIs(r,"script",["string"]);var n=JavaScriptEmbedder.for(r,e),a=this.context.nextRef(),s=PDFJavaScript.of(a,this,n);this.javaScripts.push(s)},t.prototype.attach=function(e,r,n){return n===void 0&&(n={}),__awaiter(this,void 0,void 0,function(){var a,s,o,h;return __generator(this,function(d){return assertIs(e,"attachment",["string",Uint8Array,ArrayBuffer]),assertIs(r,"name",["string"]),assertOrUndefined(n.mimeType,"mimeType",["string"]),assertOrUndefined(n.description,"description",["string"]),assertOrUndefined(n.creationDate,"options.creationDate",[Date]),assertOrUndefined(n.modificationDate,"options.modificationDate",[Date]),assertIsOneOfOrUndefined(n.afRelationship,"options.afRelationship",AFRelationship),a=toUint8Array(e),s=FileEmbedder.for(a,r,n),o=this.context.nextRef(),h=PDFEmbeddedFile.of(o,this,s),this.embeddedFiles.push(h),[2]})})},t.prototype.embedFont=function(e,r){return r===void 0&&(r={}),__awaiter(this,void 0,void 0,function(){var n,a,s,o,h,d,l,u,p,g;return __generator(this,function(f){switch(f.label){case 0:return n=r.subset,a=n===void 0?!1:n,s=r.customName,o=r.features,assertIs(e,"font",["string",Uint8Array,ArrayBuffer]),assertIs(a,"subset",["boolean"]),isStandardFont(e)?(h=StandardFontEmbedder.for(e,s),[3,7]):[3,1];case 1:return canBeConvertedToUint8Array(e)?(d=toUint8Array(e),l=this.assertFontkit(),a?[4,CustomFontSubsetEmbedder.for(l,d,s,o)]:[3,3]):[3,6];case 2:return u=f.sent(),[3,5];case 3:return[4,CustomFontEmbedder.for(l,d,s,o)];case 4:u=f.sent(),f.label=5;case 5:return h=u,[3,7];case 6:throw new TypeError("`font` must be one of `StandardFonts | string | Uint8Array | ArrayBuffer`");case 7:return p=this.context.nextRef(),g=PDFFont.of(p,this,h),this.fonts.push(g),[2,g]}})})},t.prototype.embedStandardFont=function(e,r){if(assertIs(e,"font",["string"]),!isStandardFont(e))throw new TypeError("`font` must be one of type `StandardFonts`");var n=StandardFontEmbedder.for(e,r),a=this.context.nextRef(),s=PDFFont.of(a,this,n);return this.fonts.push(s),s},t.prototype.embedJpg=function(e){return __awaiter(this,void 0,void 0,function(){var r,n,a,s;return __generator(this,function(o){switch(o.label){case 0:return assertIs(e,"jpg",["string",Uint8Array,ArrayBuffer]),r=toUint8Array(e),[4,JpegEmbedder.for(r)];case 1:return n=o.sent(),a=this.context.nextRef(),s=PDFImage.of(a,this,n),this.images.push(s),[2,s]}})})},t.prototype.embedPng=function(e){return __awaiter(this,void 0,void 0,function(){var r,n,a,s;return __generator(this,function(o){switch(o.label){case 0:return assertIs(e,"png",["string",Uint8Array,ArrayBuffer]),r=toUint8Array(e),[4,PngEmbedder.for(r)];case 1:return n=o.sent(),a=this.context.nextRef(),s=PDFImage.of(a,this,n),this.images.push(s),[2,s]}})})},t.prototype.embedPdf=function(e,r){return r===void 0&&(r=[0]),__awaiter(this,void 0,void 0,function(){var n,a,s;return __generator(this,function(o){switch(o.label){case 0:return assertIs(e,"pdf",["string",Uint8Array,ArrayBuffer,[t,"PDFDocument"]]),assertIs(r,"indices",[Array]),e instanceof t?(a=e,[3,3]):[3,1];case 1:return[4,t.load(e)];case 2:a=o.sent(),o.label=3;case 3:return n=a,s=pluckIndices(n.getPages(),r),[2,this.embedPages(s)]}})})},t.prototype.embedPage=function(e,r,n){return __awaiter(this,void 0,void 0,function(){var a;return __generator(this,function(s){switch(s.label){case 0:return assertIs(e,"page",[[PDFPage,"PDFPage"]]),[4,this.embedPages([e],[r],[n])];case 1:return a=s.sent()[0],[2,a]}})})},t.prototype.embedPages=function(e,r,n){return r===void 0&&(r=[]),n===void 0&&(n=[]),__awaiter(this,void 0,void 0,function(){var l,u,a,s,o,h,d,l,u,p,g,f,v,y,S;return __generator(this,function(m){switch(m.label){case 0:if(e.length===0)return[2,[]];for(l=0,u=e.length-1;l<u;l++)if(a=e[l],s=e[l+1],a.node.context!==s.node.context)throw new PageEmbeddingMismatchedContextError;o=e[0].node.context,h=o===this.context?function(w){return w}:PDFObjectCopier.for(o,this.context).copy,d=new Array(e.length),l=0,u=e.length,m.label=1;case 1:return l<u?(p=h(e[l].node),g=r[l],f=n[l],[4,PDFPageEmbedder.for(p,g,f)]):[3,4];case 2:v=m.sent(),y=this.context.nextRef(),d[l]=PDFEmbeddedPage.of(y,this,v),m.label=3;case 3:return l++,[3,1];case 4:return(S=this.embeddedPages).push.apply(S,d),[2,d]}})})},t.prototype.flush=function(){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return[4,this.embedAll(this.fonts)];case 1:return e.sent(),[4,this.embedAll(this.images)];case 2:return e.sent(),[4,this.embedAll(this.embeddedPages)];case 3:return e.sent(),[4,this.embedAll(this.embeddedFiles)];case 4:return e.sent(),[4,this.embedAll(this.javaScripts)];case 5:return e.sent(),[2]}})})},t.prototype.save=function(e){return e===void 0&&(e={}),__awaiter(this,void 0,void 0,function(){var r,n,a,s,o,h,d,l,u,p;return __generator(this,function(g){switch(g.label){case 0:return r=e.useObjectStreams,n=r===void 0?!0:r,a=e.addDefaultPage,s=a===void 0?!0:a,o=e.objectsPerTick,h=o===void 0?50:o,d=e.updateFieldAppearances,l=d===void 0?!0:d,assertIs(n,"useObjectStreams",["boolean"]),assertIs(s,"addDefaultPage",["boolean"]),assertIs(h,"objectsPerTick",["number"]),assertIs(l,"updateFieldAppearances",["boolean"]),s&&this.getPageCount()===0&&this.addPage(),l&&(u=this.formCache.getValue(),u&&u.updateFieldAppearances()),[4,this.flush()];case 1:return g.sent(),p=n?PDFStreamWriter:PDFWriter,[2,p.forContext(this.context,h).serializeToBuffer()]}})})},t.prototype.saveAsBase64=function(e){return e===void 0&&(e={}),__awaiter(this,void 0,void 0,function(){var r,n,a,s,o;return __generator(this,function(h){switch(h.label){case 0:return r=e.dataUri,n=r===void 0?!1:r,a=__rest(e,["dataUri"]),assertIs(n,"dataUri",["boolean"]),[4,this.save(a)];case 1:return s=h.sent(),o=encodeToBase64(s),[2,n?"data:application/pdf;base64,"+o:o]}})})},t.prototype.findPageForAnnotationRef=function(e){for(var r=this.getPages(),n=0,a=r.length;n<a;n++){var s=r[n],o=s.node.Annots();if((o==null?void 0:o.indexOf(e))!==void 0)return s}},t.prototype.embedAll=function(e){return __awaiter(this,void 0,void 0,function(){var r,n;return __generator(this,function(a){switch(a.label){case 0:r=0,n=e.length,a.label=1;case 1:return r<n?[4,e[r].embed()]:[3,4];case 2:a.sent(),a.label=3;case 3:return r++,[3,1];case 4:return[2]}})})},t.prototype.updateInfoDict=function(){var e="pdf-lib (https://github.com/Hopding/pdf-lib)",r=new Date,n=this.getInfoDict();this.setProducer(e),this.setModificationDate(r),n.get(PDFName.of("Creator"))||this.setCreator(e),n.get(PDFName.of("CreationDate"))||this.setCreationDate(r)},t.prototype.getInfoDict=function(){var e=this.context.lookup(this.context.trailerInfo.Info);if(e instanceof PDFDict)return e;var r=this.context.obj({});return this.context.trailerInfo.Info=this.context.register(r),r},t.prototype.assertFontkit=function(){if(!this.fontkit)throw new FontkitNotRegisteredError;return this.fontkit},t}();function assertIsLiteralOrHexString(t){if(!(t instanceof PDFHexString)&&!(t instanceof PDFString))throw new UnexpectedObjectTypeError([PDFHexString,PDFString],t)}var BlendMode;(function(t){t.Normal="Normal",t.Multiply="Multiply",t.Screen="Screen",t.Overlay="Overlay",t.Darken="Darken",t.Lighten="Lighten",t.ColorDodge="ColorDodge",t.ColorBurn="ColorBurn",t.HardLight="HardLight",t.SoftLight="SoftLight",t.Difference="Difference",t.Exclusion="Exclusion"})(BlendMode||(BlendMode={}));var PDFPage=function(){function t(e,r,n){this.fontSize=24,this.fontColor=rgb(0,0,0),this.lineHeight=24,this.x=0,this.y=0,assertIs(e,"leafNode",[[PDFPageLeaf,"PDFPageLeaf"]]),assertIs(r,"ref",[[PDFRef,"PDFRef"]]),assertIs(n,"doc",[[PDFDocument,"PDFDocument"]]),this.node=e,this.ref=r,this.doc=n}return t.prototype.setRotation=function(e){var r=toDegrees(e);assertMultiple(r,"degreesAngle",90),this.node.set(PDFName.of("Rotate"),this.doc.context.obj(r))},t.prototype.getRotation=function(){var e=this.node.Rotate();return degrees(e?e.asNumber():0)},t.prototype.setSize=function(e,r){assertIs(e,"width",["number"]),assertIs(r,"height",["number"]);var n=this.getMediaBox();this.setMediaBox(n.x,n.y,e,r);var a=this.getCropBox(),s=this.getBleedBox(),o=this.getTrimBox(),h=this.getArtBox(),d=this.node.CropBox(),l=this.node.BleedBox(),u=this.node.TrimBox(),p=this.node.ArtBox();d&&rectanglesAreEqual(a,n)&&this.setCropBox(n.x,n.y,e,r),l&&rectanglesAreEqual(s,n)&&this.setBleedBox(n.x,n.y,e,r),u&&rectanglesAreEqual(o,n)&&this.setTrimBox(n.x,n.y,e,r),p&&rectanglesAreEqual(h,n)&&this.setArtBox(n.x,n.y,e,r)},t.prototype.setWidth=function(e){assertIs(e,"width",["number"]),this.setSize(e,this.getSize().height)},t.prototype.setHeight=function(e){assertIs(e,"height",["number"]),this.setSize(this.getSize().width,e)},t.prototype.setMediaBox=function(e,r,n,a){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),assertIs(n,"width",["number"]),assertIs(a,"height",["number"]);var s=this.doc.context.obj([e,r,e+n,r+a]);this.node.set(PDFName.MediaBox,s)},t.prototype.setCropBox=function(e,r,n,a){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),assertIs(n,"width",["number"]),assertIs(a,"height",["number"]);var s=this.doc.context.obj([e,r,e+n,r+a]);this.node.set(PDFName.CropBox,s)},t.prototype.setBleedBox=function(e,r,n,a){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),assertIs(n,"width",["number"]),assertIs(a,"height",["number"]);var s=this.doc.context.obj([e,r,e+n,r+a]);this.node.set(PDFName.BleedBox,s)},t.prototype.setTrimBox=function(e,r,n,a){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),assertIs(n,"width",["number"]),assertIs(a,"height",["number"]);var s=this.doc.context.obj([e,r,e+n,r+a]);this.node.set(PDFName.TrimBox,s)},t.prototype.setArtBox=function(e,r,n,a){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),assertIs(n,"width",["number"]),assertIs(a,"height",["number"]);var s=this.doc.context.obj([e,r,e+n,r+a]);this.node.set(PDFName.ArtBox,s)},t.prototype.getSize=function(){var e=this.getMediaBox(),r=e.width,n=e.height;return{width:r,height:n}},t.prototype.getWidth=function(){return this.getSize().width},t.prototype.getHeight=function(){return this.getSize().height},t.prototype.getMediaBox=function(){var e=this.node.MediaBox();return e.asRectangle()},t.prototype.getCropBox=function(){var e,r=this.node.CropBox();return(e=r==null?void 0:r.asRectangle())!==null&&e!==void 0?e:this.getMediaBox()},t.prototype.getBleedBox=function(){var e,r=this.node.BleedBox();return(e=r==null?void 0:r.asRectangle())!==null&&e!==void 0?e:this.getCropBox()},t.prototype.getTrimBox=function(){var e,r=this.node.TrimBox();return(e=r==null?void 0:r.asRectangle())!==null&&e!==void 0?e:this.getCropBox()},t.prototype.getArtBox=function(){var e,r=this.node.ArtBox();return(e=r==null?void 0:r.asRectangle())!==null&&e!==void 0?e:this.getCropBox()},t.prototype.translateContent=function(e,r){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),this.node.normalize(),this.getContentStream();var n=this.createContentStream(pushGraphicsState(),translate(e,r)),a=this.doc.context.register(n),s=this.createContentStream(popGraphicsState()),o=this.doc.context.register(s);this.node.wrapContentStreams(a,o)},t.prototype.scale=function(e,r){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),this.setSize(this.getWidth()*e,this.getHeight()*r),this.scaleContent(e,r),this.scaleAnnotations(e,r)},t.prototype.scaleContent=function(e,r){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),this.node.normalize(),this.getContentStream();var n=this.createContentStream(pushGraphicsState(),scale(e,r)),a=this.doc.context.register(n),s=this.createContentStream(popGraphicsState()),o=this.doc.context.register(s);this.node.wrapContentStreams(a,o)},t.prototype.scaleAnnotations=function(e,r){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]);var n=this.node.Annots();if(n)for(var a=0;a<n.size();a++){var s=n.lookup(a);s instanceof PDFDict&&this.scaleAnnot(s,e,r)}},t.prototype.resetPosition=function(){this.getContentStream(!1),this.x=0,this.y=0},t.prototype.setFont=function(e){assertIs(e,"font",[[PDFFont,"PDFFont"]]),this.font=e,this.fontKey=this.node.newFontDictionary(this.font.name,this.font.ref)},t.prototype.setFontSize=function(e){assertIs(e,"fontSize",["number"]),this.fontSize=e},t.prototype.setFontColor=function(e){assertIs(e,"fontColor",[[Object,"Color"]]),this.fontColor=e},t.prototype.setLineHeight=function(e){assertIs(e,"lineHeight",["number"]),this.lineHeight=e},t.prototype.getPosition=function(){return{x:this.x,y:this.y}},t.prototype.getX=function(){return this.x},t.prototype.getY=function(){return this.y},t.prototype.moveTo=function(e,r){assertIs(e,"x",["number"]),assertIs(r,"y",["number"]),this.x=e,this.y=r},t.prototype.moveDown=function(e){assertIs(e,"yDecrease",["number"]),this.y-=e},t.prototype.moveUp=function(e){assertIs(e,"yIncrease",["number"]),this.y+=e},t.prototype.moveLeft=function(e){assertIs(e,"xDecrease",["number"]),this.x-=e},t.prototype.moveRight=function(e){assertIs(e,"xIncrease",["number"]),this.x+=e},t.prototype.pushOperators=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];assertEachIs(e,"operator",[[PDFOperator,"PDFOperator"]]);var n=this.getContentStream();n.push.apply(n,e)},t.prototype.drawText=function(e,r){var n,a,s,o,h,d,l;r===void 0&&(r={}),assertIs(e,"text",["string"]),assertOrUndefined(r.color,"options.color",[[Object,"Color"]]),assertRangeOrUndefined(r.opacity,"opacity.opacity",0,1),assertOrUndefined(r.font,"options.font",[[PDFFont,"PDFFont"]]),assertOrUndefined(r.size,"options.size",["number"]),assertOrUndefined(r.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(r.xSkew,"options.xSkew",[[Object,"Rotation"]]),assertOrUndefined(r.ySkew,"options.ySkew",[[Object,"Rotation"]]),assertOrUndefined(r.x,"options.x",["number"]),assertOrUndefined(r.y,"options.y",["number"]),assertOrUndefined(r.lineHeight,"options.lineHeight",["number"]),assertOrUndefined(r.maxWidth,"options.maxWidth",["number"]),assertOrUndefined(r.wordBreaks,"options.wordBreaks",[Array]),assertIsOneOfOrUndefined(r.blendMode,"options.blendMode",BlendMode);for(var u=this.setOrEmbedFont(r.font),p=u.oldFont,g=u.newFont,f=u.newFontKey,v=r.size||this.fontSize,y=r.wordBreaks||this.doc.defaultWordBreaks,S=function(A){return g.widthOfTextAtSize(A,v)},m=r.maxWidth===void 0?lineSplit(cleanText(e)):breakTextIntoLines(e,y,r.maxWidth,S),w=new Array(m.length),R=0,_=m.length;R<_;R++)w[R]=g.encodeText(m[R]);var x=this.maybeEmbedGraphicsState({opacity:r.opacity,blendMode:r.blendMode}),F=this.getContentStream();F.push.apply(F,drawLinesOfText(w,{color:(n=r.color)!==null&&n!==void 0?n:this.fontColor,font:f,size:v,rotate:(a=r.rotate)!==null&&a!==void 0?a:degrees(0),xSkew:(s=r.xSkew)!==null&&s!==void 0?s:degrees(0),ySkew:(o=r.ySkew)!==null&&o!==void 0?o:degrees(0),x:(h=r.x)!==null&&h!==void 0?h:this.x,y:(d=r.y)!==null&&d!==void 0?d:this.y,lineHeight:(l=r.lineHeight)!==null&&l!==void 0?l:this.lineHeight,graphicsState:x})),r.font&&(p?this.setFont(p):this.resetFont())},t.prototype.drawImage=function(e,r){var n,a,s,o,h,d,l;r===void 0&&(r={}),assertIs(e,"image",[[PDFImage,"PDFImage"]]),assertOrUndefined(r.x,"options.x",["number"]),assertOrUndefined(r.y,"options.y",["number"]),assertOrUndefined(r.width,"options.width",["number"]),assertOrUndefined(r.height,"options.height",["number"]),assertOrUndefined(r.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(r.xSkew,"options.xSkew",[[Object,"Rotation"]]),assertOrUndefined(r.ySkew,"options.ySkew",[[Object,"Rotation"]]),assertRangeOrUndefined(r.opacity,"opacity.opacity",0,1),assertIsOneOfOrUndefined(r.blendMode,"options.blendMode",BlendMode);var u=this.node.newXObject("Image",e.ref),p=this.maybeEmbedGraphicsState({opacity:r.opacity,blendMode:r.blendMode}),g=this.getContentStream();g.push.apply(g,drawImage(u,{x:(n=r.x)!==null&&n!==void 0?n:this.x,y:(a=r.y)!==null&&a!==void 0?a:this.y,width:(s=r.width)!==null&&s!==void 0?s:e.size().width,height:(o=r.height)!==null&&o!==void 0?o:e.size().height,rotate:(h=r.rotate)!==null&&h!==void 0?h:degrees(0),xSkew:(d=r.xSkew)!==null&&d!==void 0?d:degrees(0),ySkew:(l=r.ySkew)!==null&&l!==void 0?l:degrees(0),graphicsState:p}))},t.prototype.drawPage=function(e,r){var n,a,s,o,h;r===void 0&&(r={}),assertIs(e,"embeddedPage",[[PDFEmbeddedPage,"PDFEmbeddedPage"]]),assertOrUndefined(r.x,"options.x",["number"]),assertOrUndefined(r.y,"options.y",["number"]),assertOrUndefined(r.xScale,"options.xScale",["number"]),assertOrUndefined(r.yScale,"options.yScale",["number"]),assertOrUndefined(r.width,"options.width",["number"]),assertOrUndefined(r.height,"options.height",["number"]),assertOrUndefined(r.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(r.xSkew,"options.xSkew",[[Object,"Rotation"]]),assertOrUndefined(r.ySkew,"options.ySkew",[[Object,"Rotation"]]),assertRangeOrUndefined(r.opacity,"opacity.opacity",0,1),assertIsOneOfOrUndefined(r.blendMode,"options.blendMode",BlendMode);var d=this.node.newXObject("EmbeddedPdfPage",e.ref),l=this.maybeEmbedGraphicsState({opacity:r.opacity,blendMode:r.blendMode}),u=r.width!==void 0?r.width/e.width:r.xScale!==void 0?r.xScale:1,p=r.height!==void 0?r.height/e.height:r.yScale!==void 0?r.yScale:1,g=this.getContentStream();g.push.apply(g,drawPage(d,{x:(n=r.x)!==null&&n!==void 0?n:this.x,y:(a=r.y)!==null&&a!==void 0?a:this.y,xScale:u,yScale:p,rotate:(s=r.rotate)!==null&&s!==void 0?s:degrees(0),xSkew:(o=r.xSkew)!==null&&o!==void 0?o:degrees(0),ySkew:(h=r.ySkew)!==null&&h!==void 0?h:degrees(0),graphicsState:l}))},t.prototype.drawSvgPath=function(e,r){var n,a,s,o,h,d,l,u,p;r===void 0&&(r={}),assertIs(e,"path",["string"]),assertOrUndefined(r.x,"options.x",["number"]),assertOrUndefined(r.y,"options.y",["number"]),assertOrUndefined(r.scale,"options.scale",["number"]),assertOrUndefined(r.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(r.borderWidth,"options.borderWidth",["number"]),assertOrUndefined(r.color,"options.color",[[Object,"Color"]]),assertRangeOrUndefined(r.opacity,"opacity.opacity",0,1),assertOrUndefined(r.borderColor,"options.borderColor",[[Object,"Color"]]),assertOrUndefined(r.borderDashArray,"options.borderDashArray",[Array]),assertOrUndefined(r.borderDashPhase,"options.borderDashPhase",["number"]),assertIsOneOfOrUndefined(r.borderLineCap,"options.borderLineCap",LineCapStyle),assertRangeOrUndefined(r.borderOpacity,"options.borderOpacity",0,1),assertIsOneOfOrUndefined(r.blendMode,"options.blendMode",BlendMode);var g=this.maybeEmbedGraphicsState({opacity:r.opacity,borderOpacity:r.borderOpacity,blendMode:r.blendMode});!("color"in r)&&!("borderColor"in r)&&(r.borderColor=rgb(0,0,0));var f=this.getContentStream();f.push.apply(f,drawSvgPath(e,{x:(n=r.x)!==null&&n!==void 0?n:this.x,y:(a=r.y)!==null&&a!==void 0?a:this.y,scale:r.scale,rotate:(s=r.rotate)!==null&&s!==void 0?s:degrees(0),color:(o=r.color)!==null&&o!==void 0?o:void 0,borderColor:(h=r.borderColor)!==null&&h!==void 0?h:void 0,borderWidth:(d=r.borderWidth)!==null&&d!==void 0?d:0,borderDashArray:(l=r.borderDashArray)!==null&&l!==void 0?l:void 0,borderDashPhase:(u=r.borderDashPhase)!==null&&u!==void 0?u:void 0,borderLineCap:(p=r.borderLineCap)!==null&&p!==void 0?p:void 0,graphicsState:g}))},t.prototype.drawLine=function(e){var r,n,a,s,o;assertIs(e.start,"options.start",[[Object,"{ x: number, y: number }"]]),assertIs(e.end,"options.end",[[Object,"{ x: number, y: number }"]]),assertIs(e.start.x,"options.start.x",["number"]),assertIs(e.start.y,"options.start.y",["number"]),assertIs(e.end.x,"options.end.x",["number"]),assertIs(e.end.y,"options.end.y",["number"]),assertOrUndefined(e.thickness,"options.thickness",["number"]),assertOrUndefined(e.color,"options.color",[[Object,"Color"]]),assertOrUndefined(e.dashArray,"options.dashArray",[Array]),assertOrUndefined(e.dashPhase,"options.dashPhase",["number"]),assertIsOneOfOrUndefined(e.lineCap,"options.lineCap",LineCapStyle),assertRangeOrUndefined(e.opacity,"opacity.opacity",0,1),assertIsOneOfOrUndefined(e.blendMode,"options.blendMode",BlendMode);var h=this.maybeEmbedGraphicsState({borderOpacity:e.opacity,blendMode:e.blendMode});"color"in e||(e.color=rgb(0,0,0));var d=this.getContentStream();d.push.apply(d,drawLine({start:e.start,end:e.end,thickness:(r=e.thickness)!==null&&r!==void 0?r:1,color:(n=e.color)!==null&&n!==void 0?n:void 0,dashArray:(a=e.dashArray)!==null&&a!==void 0?a:void 0,dashPhase:(s=e.dashPhase)!==null&&s!==void 0?s:void 0,lineCap:(o=e.lineCap)!==null&&o!==void 0?o:void 0,graphicsState:h}))},t.prototype.drawRectangle=function(e){var r,n,a,s,o,h,d,l,u,p,g,f,v;e===void 0&&(e={}),assertOrUndefined(e.x,"options.x",["number"]),assertOrUndefined(e.y,"options.y",["number"]),assertOrUndefined(e.width,"options.width",["number"]),assertOrUndefined(e.height,"options.height",["number"]),assertOrUndefined(e.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(e.xSkew,"options.xSkew",[[Object,"Rotation"]]),assertOrUndefined(e.ySkew,"options.ySkew",[[Object,"Rotation"]]),assertOrUndefined(e.borderWidth,"options.borderWidth",["number"]),assertOrUndefined(e.color,"options.color",[[Object,"Color"]]),assertRangeOrUndefined(e.opacity,"opacity.opacity",0,1),assertOrUndefined(e.borderColor,"options.borderColor",[[Object,"Color"]]),assertOrUndefined(e.borderDashArray,"options.borderDashArray",[Array]),assertOrUndefined(e.borderDashPhase,"options.borderDashPhase",["number"]),assertIsOneOfOrUndefined(e.borderLineCap,"options.borderLineCap",LineCapStyle),assertRangeOrUndefined(e.borderOpacity,"options.borderOpacity",0,1),assertIsOneOfOrUndefined(e.blendMode,"options.blendMode",BlendMode);var y=this.maybeEmbedGraphicsState({opacity:e.opacity,borderOpacity:e.borderOpacity,blendMode:e.blendMode});!("color"in e)&&!("borderColor"in e)&&(e.color=rgb(0,0,0));var S=this.getContentStream();S.push.apply(S,drawRectangle({x:(r=e.x)!==null&&r!==void 0?r:this.x,y:(n=e.y)!==null&&n!==void 0?n:this.y,width:(a=e.width)!==null&&a!==void 0?a:150,height:(s=e.height)!==null&&s!==void 0?s:100,rotate:(o=e.rotate)!==null&&o!==void 0?o:degrees(0),xSkew:(h=e.xSkew)!==null&&h!==void 0?h:degrees(0),ySkew:(d=e.ySkew)!==null&&d!==void 0?d:degrees(0),borderWidth:(l=e.borderWidth)!==null&&l!==void 0?l:0,color:(u=e.color)!==null&&u!==void 0?u:void 0,borderColor:(p=e.borderColor)!==null&&p!==void 0?p:void 0,borderDashArray:(g=e.borderDashArray)!==null&&g!==void 0?g:void 0,borderDashPhase:(f=e.borderDashPhase)!==null&&f!==void 0?f:void 0,graphicsState:y,borderLineCap:(v=e.borderLineCap)!==null&&v!==void 0?v:void 0}))},t.prototype.drawSquare=function(e){e===void 0&&(e={});var r=e.size;assertOrUndefined(r,"size",["number"]),this.drawRectangle(__assign(__assign({},e),{width:r,height:r}))},t.prototype.drawEllipse=function(e){var r,n,a,s,o,h,d,l,u,p,g;e===void 0&&(e={}),assertOrUndefined(e.x,"options.x",["number"]),assertOrUndefined(e.y,"options.y",["number"]),assertOrUndefined(e.xScale,"options.xScale",["number"]),assertOrUndefined(e.yScale,"options.yScale",["number"]),assertOrUndefined(e.rotate,"options.rotate",[[Object,"Rotation"]]),assertOrUndefined(e.color,"options.color",[[Object,"Color"]]),assertRangeOrUndefined(e.opacity,"opacity.opacity",0,1),assertOrUndefined(e.borderColor,"options.borderColor",[[Object,"Color"]]),assertRangeOrUndefined(e.borderOpacity,"options.borderOpacity",0,1),assertOrUndefined(e.borderWidth,"options.borderWidth",["number"]),assertOrUndefined(e.borderDashArray,"options.borderDashArray",[Array]),assertOrUndefined(e.borderDashPhase,"options.borderDashPhase",["number"]),assertIsOneOfOrUndefined(e.borderLineCap,"options.borderLineCap",LineCapStyle),assertIsOneOfOrUndefined(e.blendMode,"options.blendMode",BlendMode);var f=this.maybeEmbedGraphicsState({opacity:e.opacity,borderOpacity:e.borderOpacity,blendMode:e.blendMode});!("color"in e)&&!("borderColor"in e)&&(e.color=rgb(0,0,0));var v=this.getContentStream();v.push.apply(v,drawEllipse({x:(r=e.x)!==null&&r!==void 0?r:this.x,y:(n=e.y)!==null&&n!==void 0?n:this.y,xScale:(a=e.xScale)!==null&&a!==void 0?a:100,yScale:(s=e.yScale)!==null&&s!==void 0?s:100,rotate:(o=e.rotate)!==null&&o!==void 0?o:void 0,color:(h=e.color)!==null&&h!==void 0?h:void 0,borderColor:(d=e.borderColor)!==null&&d!==void 0?d:void 0,borderWidth:(l=e.borderWidth)!==null&&l!==void 0?l:0,borderDashArray:(u=e.borderDashArray)!==null&&u!==void 0?u:void 0,borderDashPhase:(p=e.borderDashPhase)!==null&&p!==void 0?p:void 0,borderLineCap:(g=e.borderLineCap)!==null&&g!==void 0?g:void 0,graphicsState:f}))},t.prototype.drawCircle=function(e){e===void 0&&(e={});var r=e.size,n=r===void 0?100:r;assertOrUndefined(n,"size",["number"]),this.drawEllipse(__assign(__assign({},e),{xScale:n,yScale:n}))},t.prototype.setOrEmbedFont=function(e){var r=this.font,n=this.fontKey;e?this.setFont(e):this.getFont();var a=this.font,s=this.fontKey;return{oldFont:r,oldFontKey:n,newFont:a,newFontKey:s}},t.prototype.getFont=function(){if(!this.font||!this.fontKey){var e=this.doc.embedStandardFont(StandardFonts.Helvetica);this.setFont(e)}return[this.font,this.fontKey]},t.prototype.resetFont=function(){this.font=void 0,this.fontKey=void 0},t.prototype.getContentStream=function(e){return e===void 0&&(e=!0),e&&this.contentStream?this.contentStream:(this.contentStream=this.createContentStream(),this.contentStreamRef=this.doc.context.register(this.contentStream),this.node.addContentStream(this.contentStreamRef),this.contentStream)},t.prototype.createContentStream=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];var n=this.doc.context.obj({}),a=PDFContentStream.of(n,e);return a},t.prototype.maybeEmbedGraphicsState=function(e){var r=e.opacity,n=e.borderOpacity,a=e.blendMode;if(!(r===void 0&&n===void 0&&a===void 0)){var s=this.doc.context.obj({Type:"ExtGState",ca:r,CA:n,BM:a}),o=this.node.newExtGState("GS",s);return o}},t.prototype.scaleAnnot=function(e,r,n){for(var a=["RD","CL","Vertices","QuadPoints","L","Rect"],s=0,o=a.length;s<o;s++){var h=e.lookup(PDFName.of(a[s]));h instanceof PDFArray&&h.scalePDFNumbers(r,n)}var d=e.lookup(PDFName.of("InkList"));if(d instanceof PDFArray)for(var s=0,o=d.size();s<o;s++){var l=d.lookup(s);l instanceof PDFArray&&l.scalePDFNumbers(r,n)}},t.of=function(e,r,n){return new t(e,r,n)},t.create=function(e){assertIs(e,"doc",[[PDFDocument,"PDFDocument"]]);var r=PDFRef.of(-1),n=PDFPageLeaf.withContextAndParent(e.context,r),a=e.context.register(n);return new t(n,a,e)},t}(),PDFButton=function(t){__extends(e,t);function e(r,n,a){var s=t.call(this,r,n,a)||this;return assertIs(r,"acroButton",[[PDFAcroPushButton,"PDFAcroPushButton"]]),s.acroField=r,s}return e.prototype.setImage=function(r,n){n===void 0&&(n=ImageAlignment.Center);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s],d=this.createImageAppearanceStream(h,r,n);this.updateWidgetAppearances(h,{normal:d})}this.markAsClean()},e.prototype.setFontSize=function(r){assertPositive(r,"fontSize"),this.acroField.setFontSize(r),this.markAsDirty()},e.prototype.addToPage=function(r,n,a){var s,o,h,d,l,u,p,g,f,v,y;assertOrUndefined(r,"text",["string"]),assertOrUndefined(n,"page",[[PDFPage,"PDFPage"]]),assertFieldAppearanceOptions(a);var S=this.createWidget({x:((s=a==null?void 0:a.x)!==null&&s!==void 0?s:0)-((o=a==null?void 0:a.borderWidth)!==null&&o!==void 0?o:0)/2,y:((h=a==null?void 0:a.y)!==null&&h!==void 0?h:0)-((d=a==null?void 0:a.borderWidth)!==null&&d!==void 0?d:0)/2,width:(l=a==null?void 0:a.width)!==null&&l!==void 0?l:100,height:(u=a==null?void 0:a.height)!==null&&u!==void 0?u:50,textColor:(p=a==null?void 0:a.textColor)!==null&&p!==void 0?p:rgb(0,0,0),backgroundColor:(g=a==null?void 0:a.backgroundColor)!==null&&g!==void 0?g:rgb(.75,.75,.75),borderColor:a==null?void 0:a.borderColor,borderWidth:(f=a==null?void 0:a.borderWidth)!==null&&f!==void 0?f:0,rotate:(v=a==null?void 0:a.rotate)!==null&&v!==void 0?v:degrees(0),caption:r,hidden:a==null?void 0:a.hidden,page:n.ref}),m=this.doc.context.register(S.dict);this.acroField.addWidget(m);var w=(y=a==null?void 0:a.font)!==null&&y!==void 0?y:this.doc.getForm().getDefaultFont();this.updateWidgetAppearance(S,w),n.node.addAnnot(m)},e.prototype.needsAppearancesUpdate=function(){var r;if(this.isDirty())return!0;for(var n=this.acroField.getWidgets(),a=0,s=n.length;a<s;a++){var o=n[a],h=((r=o.getAppearances())===null||r===void 0?void 0:r.normal)instanceof PDFStream;if(!h)return!0}return!1},e.prototype.defaultUpdateAppearances=function(r){assertIs(r,"font",[[PDFFont,"PDFFont"]]),this.updateAppearances(r)},e.prototype.updateAppearances=function(r,n){assertIs(r,"font",[[PDFFont,"PDFFont"]]),assertOrUndefined(n,"provider",[Function]);for(var a=this.acroField.getWidgets(),s=0,o=a.length;s<o;s++){var h=a[s];this.updateWidgetAppearance(h,r,n)}},e.prototype.updateWidgetAppearance=function(r,n,a){var s=a??defaultButtonAppearanceProvider,o=normalizeAppearance(s(this,r,n));this.updateWidgetAppearanceWithFont(r,n,o)},e.of=function(r,n,a){return new e(r,n,a)},e}(PDFField);pdfExports.GlobalWorkerOptions.workerSrc="https://cdnjs.cloudflare.com/ajax/libs/pdf.js/3.11.174/pdf.worker.min.js";const ANNOTATION_METADATA_SUBJECT_PREFIX="PDF_ANNOTATOR_DATA::",safeGetAnnotationData=(t,e,r)=>{try{return JSON.stringify(e),{annotations:t,historyState:e,pageRotations:r}}catch(n){return console.warn("Full history state has circular references or is too large, using current state only",n),{annotations:t,historyState:{history:[t],index:0},pageRotations:r}}},PdfViewer=react.forwardRef(({fileUrl:t,fileName:e,readonly:r=!1,onAnnotationsChange:n,initialAnnotations:a,initialHistoryState:s,onSave:o,onPrint:h,onGetAnnotationData:d},l)=>{const[u,p]=react.useState(null),[g,f]=react.useState(0),[v,y]=react.useState(1),[S,m]=react.useState(1),[w,R]=react.useState("SELECT"),[_,x]=react.useState(DEFAULT_COLOR),[F,A]=react.useState(DEFAULT_STROKE_WIDTH),[D,T]=react.useState(DEFAULT_FONT_SIZE),[M,C]=react.useState(!1),[k,O]=react.useState(null),[$,K]=react.useState(null),[J,Y]=react.useState(null),[se,B]=react.useState(null),[V,Q]=react.useState("APPROVED"),[N,P]=react.useState({}),{annotations:E,addAnnotation:I,deleteAnnotation:z,updateAnnotation:G,clearAnnotations:H,undo:ee,redo:ce,canUndo:ve,canRedo:me,setAnnotations:xe,historyState:Se,setHistoryState:Ce}=useAnnotationHistory(),ne=react.useRef(null),le=react.useRef([]),[L,Z]=react.useState(!1),[re,he]=react.useState({x:0,y:0}),ye=react.useCallback((Ee,Ie)=>{P(ze=>{const ae=(((ze[Ee]||0)+(Ie==="cw"?90:-90))%360+360)%360;return{...ze,[Ee]:ae}})},[]);react.useEffect(()=>{if(!ne.current||g===0)return;const Ee=new IntersectionObserver(Ie=>{let ze=0,be=0;Ie.forEach(oe=>{const ae=Number(oe.target.getAttribute("data-page-number"));ae&&oe.intersectionRatio>be&&(ze=ae,be=oe.intersectionRatio)}),ze>0&&y(ze)},{root:ne.current,threshold:[0,.25,.5,.75,1]});return le.current.forEach(Ie=>{Ie&&Ee.observe(Ie)}),()=>Ee.disconnect()},[g]),react.useEffect(()=>{n&&n(E)},[E,n]);const Fe=react.useRef(!1);react.useEffect(()=>{s?(Ce(s),Fe.current=!0):a?(xe(a),Fe.current=!0):Fe.current=!1},[a,s,xe,Ce]),react.useEffect(()=>{(async()=>{try{const ze=await pdfExports.getDocument(t).promise;if(p(ze),f(ze.numPages),le.current=Array(ze.numPages).fill(null),y(1),!Fe.current){const be=await fetch(t).then(Re=>Re.arrayBuffer()),ae=(await PDFDocument.load(be)).getSubject();if(ae&&ae.startsWith(ANNOTATION_METADATA_SUBJECT_PREFIX))try{const Re=ae.substring(ANNOTATION_METADATA_SUBJECT_PREFIX.length),We=JSON.parse(Re);We.pageRotations&&P(We.pageRotations),Ce({history:We.history,index:We.index})}catch(Re){console.error("Failed to parse annotation metadata:",Re)}}}catch(Ie){console.error("Error loading PDF:",Ie)}})()},[t]);const Pe=Ee=>{if(Ee>0&&Ee<=g){y(Ee);const Ie=le.current[Ee-1];if(Ie&&ne.current){const ze=ne.current.scrollTop,be=ne.current.getBoundingClientRect(),ae=Ie.getBoundingClientRect().top-be.top+ze;ne.current.scrollTo({top:ae,behavior:"smooth"})}}},ie=react.useCallback(()=>{if(k)for(const Ee in E){const Ie=parseInt(Ee,10);if(E[Ie].some(ze=>ze.id===k)){z(Ie,k),O(null);break}}},[k,E,z]);react.useEffect(()=>{const Ee=Ie=>{(Ie.key==="Delete"||Ie.key==="Backspace")&&k&&(Ie.preventDefault(),ie()),(Ie.ctrlKey||Ie.metaKey)&&Ie.key==="z"&&(Ie.preventDefault(),ee()),(Ie.ctrlKey||Ie.metaKey)&&Ie.key==="y"&&(Ie.preventDefault(),ce())};return window.addEventListener("keydown",Ee),()=>window.removeEventListener("keydown",Ee)},[k,ie,ee,ce]);const _e=react.useCallback(async(Ee=!1)=>{if(!u)return null;const Ie=await fetch(t).then(We=>We.arrayBuffer()),ze=await PDFDocument.load(Ie);try{const We={...Se,pageRotations:N},Ve=JSON.stringify(We),X=ANNOTATION_METADATA_SUBJECT_PREFIX+Ve;if(X.length>32e3){const ke=JSON.stringify({history:[E],index:0,pageRotations:N});ze.setSubject(ANNOTATION_METADATA_SUBJECT_PREFIX+ke)}else ze.setSubject(X)}catch(We){console.error("Failed to serialize history state:",We);try{const X=JSON.stringify({history:[E],index:0,pageRotations:N});ze.setSubject(ANNOTATION_METADATA_SUBJECT_PREFIX+X)}catch(Ve){console.error("Failed to serialize even current annotations:",Ve)}}const be=ze.getPages();for(let We=1;We<=be.length;We++){const Ve=N[We]||0;if(Ve!==0){const X=be[We-1].getRotation().angle;be[We-1].setRotation(degrees((X+Ve)%360))}}if(!Ee)return await ze.save();console.log("Rendering annotations onto PDF");const oe=await ze.embedFont(StandardFonts.Helvetica),ae=await ze.embedFont(StandardFonts.HelveticaBold),Re={};for(const We in E){const Ve=parseInt(We,10);if(Ve<1||Ve>be.length)continue;const X=E[Ve],ge=be[Ve-1],{width:ke,height:Be}=ge.getSize(),Ne=(await u.getPage(Ve)).getViewport({scale:1}),U=ke/Ne.width,j=Be/Ne.height;for(const W of X){const fe=rgb(parseInt(W.color.slice(1,3),16)/255,parseInt(W.color.slice(3,5),16)/255,parseInt(W.color.slice(5,7),16)/255),pe=Ae=>Be-Ae*j;switch(W.type){case"PEN":if(W.points.length>1)for(let De=0;De<W.points.length-1;De++){const Ge=W.points[De],Oe=W.points[De+1];ge.drawLine({start:{x:Ge.x*U,y:pe(Ge.y)},end:{x:Oe.x*U,y:pe(Oe.y)},thickness:W.strokeWidth*U,color:fe,opacity:1})}break;case"UNDERLINE":case"STRIKETHROUGH":if(W.points.length>1)for(let De=0;De<W.points.length-1;De++){const Ge=W.points[De],Oe=W.points[De+1];ge.drawLine({start:{x:Ge.x*U,y:pe(Ge.y)},end:{x:Oe.x*U,y:pe(Oe.y)},thickness:W.strokeWidth*U,color:fe,opacity:1})}break;case"SQUIGGLY":if(W.points.length>1){let De=`M ${W.points[0].x*U} ${pe(W.points[0].y)}`;for(let Ge=1;Ge<W.points.length;Ge++){const Oe=W.points[Ge];De+=` Q ${(Oe.x-2.5)*U} ${pe(Oe.y+(Ge%2===0?-1:1)*2)}, ${Oe.x*U} ${pe(Oe.y)}`}ge.drawSvgPath(De,{borderColor:fe,borderWidth:W.strokeWidth})}break;case"HIGHLIGHTER":if(W.points.length>1)for(let De=0;De<W.points.length-1;De++){const Ge=W.points[De],Oe=W.points[De+1];ge.drawLine({start:{x:Ge.x*U,y:pe(Ge.y)},end:{x:Oe.x*U,y:pe(Oe.y)},thickness:W.strokeWidth*5*U,color:fe,opacity:.4})}break;case"RECTANGLE":ge.drawRectangle({x:W.x*U,y:pe(W.y+W.height),width:W.width*U,height:W.height*j,borderColor:fe,borderWidth:W.strokeWidth});break;case"CIRCLE":ge.drawEllipse({x:W.cx*U,y:pe(W.cy),xScale:W.rx*U,yScale:W.ry*j,borderColor:fe,borderWidth:W.strokeWidth});break;case"TEXT":W.content.split(`
|
|
61
|
+
`).forEach((De,Ge)=>{ge.drawText(De,{x:W.x*U,y:pe(W.y+W.fontSize+Ge*W.fontSize*1.2),size:W.fontSize*j,font:oe,color:fe})});break;case"STAMP":ge.drawRectangle({x:W.x*U,y:pe(W.y+W.height),width:W.width*U,height:W.height*j,borderColor:fe,borderWidth:2,borderOpacity:.8});const we=W.text,je=ae.widthOfTextAtSize(we,W.fontSize*j);if(ge.drawText(we,{x:(W.x+W.width/2)*U-je/2,y:pe(W.y+W.height*.35),font:ae,size:W.fontSize*j,color:fe,opacity:.8}),W.timestamp){const De=W.fontSize*.45*j,Ge=oe.widthOfTextAtSize(W.timestamp,De);ge.drawText(W.timestamp,{x:(W.x+W.width/2)*U-Ge/2,y:pe(W.y+W.height*.7),font:oe,size:De,color:fe,opacity:.7})}break;case"SIGNATURE":case"INITIALS":Re[W.imageData]||(Re[W.imageData]=await ze.embedPng(W.imageData));const Le=Re[W.imageData];ge.drawImage(Le,{x:W.x*U,y:pe(W.y+W.height),width:W.width*U,height:W.height*j});break}}}return await ze.save()},[u,t,E,Se,N]);react.useImperativeHandle(l,()=>({getAnnotatedDocument:async()=>{try{const Ee=await _e();return Ee?new Blob([Ee],{type:"application/pdf"}):null}catch(Ee){return console.error("Failed to generate annotated document:",Ee),null}},getAnnotatedDocumentUrl:async()=>{try{const Ee=await _e();if(!Ee)return null;const Ie=new Blob([Ee],{type:"application/pdf"});return URL.createObjectURL(Ie)}catch(Ee){return console.error("Failed to generate annotated document URL:",Ee),null}},getAnnotationData:()=>{const Ee=safeGetAnnotationData(E,Se,N);return d&&d(Ee),Ee}}),[_e,E,Se,N,d]);const Te=react.useCallback(async Ee=>{C(!0);try{const ze=await _e(Ee==="print");if(!ze){C(!1);return}const be=safeGetAnnotationData(E,Se,N),oe=new Blob([ze],{type:"application/pdf"}),ae=URL.createObjectURL(oe);if(Ee==="download"){o&&o(be);const Re=document.createElement("a");Re.href=ae,Re.download=`${e.replace(".pdf","")}-annotated.pdf`,document.body.appendChild(Re),Re.click(),document.body.removeChild(Re),URL.revokeObjectURL(ae)}else{h&&h(be);const Re=document.createElement("iframe");Re.style.display="none",Re.src=ae,document.body.appendChild(Re),Re.onload=()=>{setTimeout(()=>{var We,Ve;try{(We=Re.contentWindow)==null||We.focus(),(Ve=Re.contentWindow)==null||Ve.print()}catch(X){console.error("Printing failed:",X),alert("Could not print the document. Your browser might be blocking it.")}setTimeout(()=>{document.body.contains(Re)&&(document.body.removeChild(Re),URL.revokeObjectURL(ae))},1e3)},1)}}}catch(Ie){console.error(`Failed to ${Ee} annotated PDF:`,Ie)}finally{C(!1)}},[_e,e,E,Se,N,o,h]),Ke=Ee=>{w==="PAN"&&ne.current&&(Z(!0),he({x:Ee.clientX+ne.current.scrollLeft,y:Ee.clientY+ne.current.scrollTop}),ne.current&&(ne.current.style.cursor="grabbing"))},qe=Ee=>{if(L&&ne.current&&w==="PAN"){const Ie=re.x-Ee.clientX,ze=re.y-Ee.clientY;ne.current.scrollLeft=Ie,ne.current.scrollTop=ze}},Ye=()=>{L&&(Z(!1),ne.current&&(ne.current.style.cursor="grab"))},Me=()=>{if(!u)return null;const Ee=[];for(let Ie=1;Ie<=g;Ie++)Ee.push(jsxRuntime.jsx("div",{ref:ze=>{le.current[Ie-1]=ze},"data-page-number":Ie,className:"mb-4",children:jsxRuntime.jsx(PdfPage,{pdf:u,pageNumber:Ie,zoom:S,rotation:N[Ie]||0,activeTool:w,toolColor:_,strokeWidth:F,fontSize:D,annotations:E[Ie]||[],addAnnotation:ze=>I(Ie,ze),deleteAnnotation:ze=>z(Ie,ze),updateAnnotation:G,selectedAnnotationId:k,setSelectedAnnotationId:O,signatureData:$,initialsData:J,activeStamp:V,readonly:r})},Ie));return Ee};return jsxRuntime.jsxs("div",{className:"react-pdf-annotator-container flex flex-col h-full w-full overflow-hidden",children:[se&&jsxRuntime.jsx(SignatureModal,{title:se==="SIGNATURE"?"Create Signature":"Create Initials",onClose:()=>B(null),onSave:Ee=>{se==="SIGNATURE"?K(Ee):Y(Ee)}}),jsxRuntime.jsx(Toolbar,{fileName:e,currentPage:v,totalPages:g,zoom:S,setZoom:m,setCurrentPage:Pe,activeTool:w,setActiveTool:R,toolColor:_,setToolColor:x,strokeWidth:F,setStrokeWidth:A,fontSize:D,setFontSize:T,onDownload:()=>Te("download"),onPrint:()=>Te("print"),isProcessing:M,onDelete:ie,selectedAnnotationId:k,undo:ee,redo:ce,canUndo:ve,canRedo:me,onSignatureClick:()=>B("SIGNATURE"),onInitialsClick:()=>B("INITIALS"),activeStamp:V,setActiveStamp:Q,onRotate:()=>ye(v,"cw"),readonly:r}),jsxRuntime.jsx("div",{ref:ne,className:"bg-gray-50 p-4 overflow-auto flex-1",style:{cursor:w==="PAN"?L?"grabbing":"grab":"default",userSelect:w==="PAN"?"none":"text"},onMouseDown:Ke,onMouseMove:qe,onMouseUp:Ye,onMouseLeave:Ye,children:jsxRuntime.jsx("div",{id:"pdf-print-area",className:"mx-auto",children:u?Me():jsxRuntime.jsx("div",{className:"flex items-center justify-center h-full",children:jsxRuntime.jsx("p",{className:"text-xl",children:"Loading PDF..."})})})})]})});PdfViewer.displayName="PdfViewer",exports.AnnotationLayer=AnnotationLayer,exports.CircleIcon=CircleIcon,exports.DEFAULT_COLOR=DEFAULT_COLOR,exports.DEFAULT_FONT_SIZE=DEFAULT_FONT_SIZE,exports.DEFAULT_STROKE_WIDTH=DEFAULT_STROKE_WIDTH,exports.DownloadIcon=DownloadIcon,exports.EraserIcon=EraserIcon,exports.FONT_SIZES=FONT_SIZES,exports.FreeTextIcon=FreeTextIcon,exports.HighlighterIcon=HighlighterIcon,exports.InitialsIcon=InitialsIcon,exports.MoreIcon=MoreIcon,exports.PanIcon=PanIcon,exports.PdfPage=PdfPage,exports.PdfViewer=PdfViewer,exports.PenIcon=PenIcon,exports.PrintIcon=PrintIcon,exports.RectangleIcon=RectangleIcon,exports.RedoIcon=RedoIcon,exports.RotateIcon=RotateIcon,exports.STAMPS=STAMPS,exports.STROKE_WIDTHS=STROKE_WIDTHS,exports.SelectIcon=SelectIcon,exports.SignatureIcon=SignatureIcon,exports.SignatureModal=SignatureModal,exports.SquigglyIcon=SquigglyIcon,exports.StampIcon=StampIcon,exports.StrikeoutIcon=StrikeoutIcon,exports.Toolbar=Toolbar,exports.TrashIcon=TrashIcon,exports.UnderlineIcon=UnderlineIcon,exports.UndoIcon=UndoIcon,exports.UploadIcon=UploadIcon,exports.ZoomInIcon=ZoomInIcon,exports.ZoomOutIcon=ZoomOutIcon,exports.useAnnotationHistory=useAnnotationHistory,Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"})});
|
|
62
62
|
//# sourceMappingURL=react-pdf-annotator.umd.js.map
|