@kne-components/react-file 0.1.35 → 0.1.36
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.
- package/build/asset-manifest.json +22 -20
- package/build/index.html +1 -1
- package/build/remoteEntry.js +1 -1
- package/build/remoteEntry.js.map +1 -1
- package/build/static/css/{511.901a4718.chunk.css → 776.e7e6d018.chunk.css} +2 -2
- package/build/static/css/776.e7e6d018.chunk.css.map +1 -0
- package/build/static/js/151.b276c881.chunk.js +3 -0
- package/build/static/js/151.b276c881.chunk.js.map +1 -0
- package/build/static/js/258.b3ee8f02.chunk.js +2 -0
- package/build/static/js/258.b3ee8f02.chunk.js.map +1 -0
- package/build/static/js/{72.4bacf538.chunk.js → 72.5c6903b0.chunk.js} +2 -2
- package/build/static/js/{72.4bacf538.chunk.js.map → 72.5c6903b0.chunk.js.map} +1 -1
- package/build/static/js/776.d98d1437.chunk.js +9 -0
- package/build/static/js/776.d98d1437.chunk.js.map +1 -0
- package/build/static/js/{784.bb2153da.chunk.js → 784.aeeb864e.chunk.js} +2 -2
- package/build/static/js/{784.bb2153da.chunk.js.map → 784.aeeb864e.chunk.js.map} +1 -1
- package/build/static/js/872.a5a26e7d.chunk.js +2 -0
- package/build/static/js/872.a5a26e7d.chunk.js.map +1 -0
- package/build/static/js/main.caa69af7.js +2 -0
- package/build/static/js/main.caa69af7.js.map +1 -0
- package/build/static/media/check~elxgVvVe.d6bb9a199bf3a5853749ecea3ce6a127.svg +3 -0
- package/build/static/media/collapse~vphRLfPi.378d83c01100d172e79c04ba3179be58.svg +6 -0
- package/build/static/media/copy~drOLfxzP.5880fbbaf59db852794c06f32786d138.svg +4 -0
- package/build/static/media/expand~blSbUwvt.8a0d1f9fb3339d7da34c3117df14b545.svg +6 -0
- package/package.json +1 -1
- package/build/static/css/511.901a4718.chunk.css.map +0 -1
- package/build/static/css/892.901a4718.chunk.css +0 -2
- package/build/static/css/892.901a4718.chunk.css.map +0 -1
- package/build/static/js/151.ba88b4c8.chunk.js +0 -3
- package/build/static/js/151.ba88b4c8.chunk.js.map +0 -1
- package/build/static/js/258.26b6de58.chunk.js +0 -2
- package/build/static/js/258.26b6de58.chunk.js.map +0 -1
- package/build/static/js/418.0e897104.chunk.js +0 -9
- package/build/static/js/418.0e897104.chunk.js.map +0 -1
- package/build/static/js/872.47e0183e.chunk.js +0 -2
- package/build/static/js/872.47e0183e.chunk.js.map +0 -1
- package/build/static/js/main.882fe1b6.js +0 -2
- package/build/static/js/main.882fe1b6.js.map +0 -1
- /package/build/static/js/{151.ba88b4c8.chunk.js.LICENSE.txt → 151.b276c881.chunk.js.LICENSE.txt} +0 -0
- /package/build/static/js/{418.0e897104.chunk.js.LICENSE.txt → 776.d98d1437.chunk.js.LICENSE.txt} +0 -0
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/*! For license information please see 776.d98d1437.chunk.js.LICENSE.txt */
|
|
2
|
+
(globalThis.webpackChunk_kne_components_react_file=globalThis.webpackChunk_kne_components_react_file||[]).push([[776],{80036(e,t,n){"use strict";n.d(t,{A:()=>ke});var r=n(68102),i=n(3141);function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}function a(e){var t=function(e,t){if("object"!=s(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=s(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==s(t)?t:t+""}function o(e,t,n){return(t=a(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(r=0;r<s.length;r++)n=s[r],-1===t.indexOf(n)&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}var c=n(94922),h=n(54159),d=n.n(h);const u=Math.round;function p(e,t){const n=e.replace(/^[^(]*\((.*)/,"$1").replace(/\).*/,"").match(/\d*\.?\d+%?/g)||[],r=n.map(e=>parseFloat(e));for(let i=0;i<3;i+=1)r[i]=t(r[i]||0,n[i]||"",i);return n[3]?r[3]=n[3].includes("%")?r[3]/100:r[3]:r[3]=1,r}const f=(e,t,n)=>0===n?e:e/100;function m(e,t){const n=t||255;return e>n?n:e<0?0:e}class g{constructor(e){function t(t){return t[0]in e&&t[1]in e&&t[2]in e}if(o(this,"isValid",!0),o(this,"r",0),o(this,"g",0),o(this,"b",0),o(this,"a",1),o(this,"_h",void 0),o(this,"_s",void 0),o(this,"_l",void 0),o(this,"_v",void 0),o(this,"_max",void 0),o(this,"_min",void 0),o(this,"_brightness",void 0),e)if("string"===typeof e){const n=e.trim();function r(e){return n.startsWith(e)}/^#?[A-F\d]{3,8}$/i.test(n)?this.fromHexString(n):r("rgb")?this.fromRgbString(n):r("hsl")?this.fromHslString(n):(r("hsv")||r("hsb"))&&this.fromHsvString(n)}else if(e instanceof g)this.r=e.r,this.g=e.g,this.b=e.b,this.a=e.a,this._h=e._h,this._s=e._s,this._l=e._l,this._v=e._v;else if(t("rgb"))this.r=m(e.r),this.g=m(e.g),this.b=m(e.b),this.a="number"===typeof e.a?m(e.a,1):1;else if(t("hsl"))this.fromHsl(e);else{if(!t("hsv"))throw new Error("@ant-design/fast-color: unsupported input "+JSON.stringify(e));this.fromHsv(e)}else;}setR(e){return this._sc("r",e)}setG(e){return this._sc("g",e)}setB(e){return this._sc("b",e)}setA(e){return this._sc("a",e,1)}setHue(e){const t=this.toHsv();return t.h=e,this._c(t)}getLuminance(){function e(e){const t=e/255;return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)}return.2126*e(this.r)+.7152*e(this.g)+.0722*e(this.b)}getHue(){if("undefined"===typeof this._h){const e=this.getMax()-this.getMin();this._h=0===e?0:u(60*(this.r===this.getMax()?(this.g-this.b)/e+(this.g<this.b?6:0):this.g===this.getMax()?(this.b-this.r)/e+2:(this.r-this.g)/e+4))}return this._h}getSaturation(){if("undefined"===typeof this._s){const e=this.getMax()-this.getMin();this._s=0===e?0:e/this.getMax()}return this._s}getLightness(){return"undefined"===typeof this._l&&(this._l=(this.getMax()+this.getMin())/510),this._l}getValue(){return"undefined"===typeof this._v&&(this._v=this.getMax()/255),this._v}getBrightness(){return"undefined"===typeof this._brightness&&(this._brightness=(299*this.r+587*this.g+114*this.b)/1e3),this._brightness}darken(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10;const t=this.getHue(),n=this.getSaturation();let r=this.getLightness()-e/100;return r<0&&(r=0),this._c({h:t,s:n,l:r,a:this.a})}lighten(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10;const t=this.getHue(),n=this.getSaturation();let r=this.getLightness()+e/100;return r>1&&(r=1),this._c({h:t,s:n,l:r,a:this.a})}mix(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:50;const n=this._c(e),r=t/100,i=e=>(n[e]-this[e])*r+this[e],s={r:u(i("r")),g:u(i("g")),b:u(i("b")),a:u(100*i("a"))/100};return this._c(s)}tint(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10;return this.mix({r:255,g:255,b:255,a:1},e)}shade(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10;return this.mix({r:0,g:0,b:0,a:1},e)}onBackground(e){const t=this._c(e),n=this.a+t.a*(1-this.a),r=e=>u((this[e]*this.a+t[e]*t.a*(1-this.a))/n);return this._c({r:r("r"),g:r("g"),b:r("b"),a:n})}isDark(){return this.getBrightness()<128}isLight(){return this.getBrightness()>=128}equals(e){return this.r===e.r&&this.g===e.g&&this.b===e.b&&this.a===e.a}clone(){return this._c(this)}toHexString(){let e="#";const t=(this.r||0).toString(16);e+=2===t.length?t:"0"+t;const n=(this.g||0).toString(16);e+=2===n.length?n:"0"+n;const r=(this.b||0).toString(16);if(e+=2===r.length?r:"0"+r,"number"===typeof this.a&&this.a>=0&&this.a<1){const t=u(255*this.a).toString(16);e+=2===t.length?t:"0"+t}return e}toHsl(){return{h:this.getHue(),s:this.getSaturation(),l:this.getLightness(),a:this.a}}toHslString(){const e=this.getHue(),t=u(100*this.getSaturation()),n=u(100*this.getLightness());return 1!==this.a?`hsla(${e},${t}%,${n}%,${this.a})`:`hsl(${e},${t}%,${n}%)`}toHsv(){return{h:this.getHue(),s:this.getSaturation(),v:this.getValue(),a:this.a}}toRgb(){return{r:this.r,g:this.g,b:this.b,a:this.a}}toRgbString(){return 1!==this.a?`rgba(${this.r},${this.g},${this.b},${this.a})`:`rgb(${this.r},${this.g},${this.b})`}toString(){return this.toRgbString()}_sc(e,t,n){const r=this.clone();return r[e]=m(t,n),r}_c(e){return new this.constructor(e)}getMax(){return"undefined"===typeof this._max&&(this._max=Math.max(this.r,this.g,this.b)),this._max}getMin(){return"undefined"===typeof this._min&&(this._min=Math.min(this.r,this.g,this.b)),this._min}fromHexString(e){const t=e.replace("#","");function n(e,n){return parseInt(t[e]+t[n||e],16)}t.length<6?(this.r=n(0),this.g=n(1),this.b=n(2),this.a=t[3]?n(3)/255:1):(this.r=n(0,1),this.g=n(2,3),this.b=n(4,5),this.a=t[6]?n(6,7)/255:1)}fromHsl(e){let{h:t,s:n,l:r,a:i}=e;if(this._h=t%360,this._s=n,this._l=r,this.a="number"===typeof i?i:1,n<=0){const e=u(255*r);this.r=e,this.g=e,this.b=e}let s=0,a=0,o=0;const l=t/60,c=(1-Math.abs(2*r-1))*n,h=c*(1-Math.abs(l%2-1));l>=0&&l<1?(s=c,a=h):l>=1&&l<2?(s=h,a=c):l>=2&&l<3?(a=c,o=h):l>=3&&l<4?(a=h,o=c):l>=4&&l<5?(s=h,o=c):l>=5&&l<6&&(s=c,o=h);const d=r-c/2;this.r=u(255*(s+d)),this.g=u(255*(a+d)),this.b=u(255*(o+d))}fromHsv(e){let{h:t,s:n,v:r,a:i}=e;this._h=t%360,this._s=n,this._v=r,this.a="number"===typeof i?i:1;const s=u(255*r);if(this.r=s,this.g=s,this.b=s,n<=0)return;const a=t/60,o=Math.floor(a),l=a-o,c=u(r*(1-n)*255),h=u(r*(1-n*l)*255),d=u(r*(1-n*(1-l))*255);switch(o){case 0:this.g=d,this.b=c;break;case 1:this.r=h,this.b=c;break;case 2:this.r=c,this.b=d;break;case 3:this.r=c,this.g=h;break;case 4:this.r=d,this.g=c;break;default:this.g=c,this.b=h}}fromHsvString(e){const t=p(e,f);this.fromHsv({h:t[0],s:t[1],v:t[2],a:t[3]})}fromHslString(e){const t=p(e,f);this.fromHsl({h:t[0],s:t[1],l:t[2],a:t[3]})}fromRgbString(e){const t=p(e,(e,t)=>t.includes("%")?u(e/100*255):e);this.r=t[0],this.g=t[1],this.b=t[2],this.a=t[3]}}var v=[{index:7,amount:15},{index:6,amount:25},{index:5,amount:30},{index:5,amount:45},{index:5,amount:65},{index:5,amount:85},{index:4,amount:90},{index:3,amount:95},{index:2,amount:97},{index:1,amount:98}];function y(e,t,n){var r;return(r=Math.round(e.h)>=60&&Math.round(e.h)<=240?n?Math.round(e.h)-2*t:Math.round(e.h)+2*t:n?Math.round(e.h)+2*t:Math.round(e.h)-2*t)<0?r+=360:r>=360&&(r-=360),r}function b(e,t,n){return 0===e.h&&0===e.s?e.s:((r=n?e.s-.16*t:4===t?e.s+.16:e.s+.05*t)>1&&(r=1),n&&5===t&&r>.1&&(r=.1),r<.06&&(r=.06),Math.round(100*r)/100);var r}function w(e,t,n){var r;return r=n?e.v+.05*t:e.v-.15*t,r=Math.max(0,Math.min(1,r)),Math.round(100*r)/100}var _=["#fff1f0","#ffccc7","#ffa39e","#ff7875","#ff4d4f","#f5222d","#cf1322","#a8071a","#820014","#5c0011"];_.primary=_[5];var A=["#fff2e8","#ffd8bf","#ffbb96","#ff9c6e","#ff7a45","#fa541c","#d4380d","#ad2102","#871400","#610b00"];A.primary=A[5];var x=["#fff7e6","#ffe7ba","#ffd591","#ffc069","#ffa940","#fa8c16","#d46b08","#ad4e00","#873800","#612500"];x.primary=x[5];var E=["#fffbe6","#fff1b8","#ffe58f","#ffd666","#ffc53d","#faad14","#d48806","#ad6800","#874d00","#613400"];E.primary=E[5];var C=["#feffe6","#ffffb8","#fffb8f","#fff566","#ffec3d","#fadb14","#d4b106","#ad8b00","#876800","#614700"];C.primary=C[5];var k=["#fcffe6","#f4ffb8","#eaff8f","#d3f261","#bae637","#a0d911","#7cb305","#5b8c00","#3f6600","#254000"];k.primary=k[5];var S=["#f6ffed","#d9f7be","#b7eb8f","#95de64","#73d13d","#52c41a","#389e0d","#237804","#135200","#092b00"];S.primary=S[5];var T=["#e6fffb","#b5f5ec","#87e8de","#5cdbd3","#36cfc9","#13c2c2","#08979c","#006d75","#00474f","#002329"];T.primary=T[5];var D=["#e6f4ff","#bae0ff","#91caff","#69b1ff","#4096ff","#1677ff","#0958d9","#003eb3","#002c8c","#001d66"];D.primary=D[5];var M=["#f0f5ff","#d6e4ff","#adc6ff","#85a5ff","#597ef7","#2f54eb","#1d39c4","#10239e","#061178","#030852"];M.primary=M[5];var P=["#f9f0ff","#efdbff","#d3adf7","#b37feb","#9254de","#722ed1","#531dab","#391085","#22075e","#120338"];P.primary=P[5];var I=["#fff0f6","#ffd6e7","#ffadd2","#ff85c0","#f759ab","#eb2f96","#c41d7f","#9e1068","#780650","#520339"];I.primary=I[5];var F=["#a6a6a6","#999999","#8c8c8c","#808080","#737373","#666666","#404040","#1a1a1a","#000000","#000000"];F.primary=F[5];var R=["#2a1215","#431418","#58181c","#791a1f","#a61d24","#d32029","#e84749","#f37370","#f89f9a","#fac8c3"];R.primary=R[5];var N=["#2b1611","#441d12","#592716","#7c3118","#aa3e19","#d84a1b","#e87040","#f3956a","#f8b692","#fad4bc"];N.primary=N[5];var L=["#2b1d11","#442a11","#593815","#7c4a15","#aa6215","#d87a16","#e89a3c","#f3b765","#f8cf8d","#fae3b7"];L.primary=L[5];var O=["#2b2111","#443111","#594214","#7c5914","#aa7714","#d89614","#e8b339","#f3cc62","#f8df8b","#faedb5"];O.primary=O[5];var B=["#2b2611","#443b11","#595014","#7c6e14","#aa9514","#d8bd14","#e8d639","#f3ea62","#f8f48b","#fafab5"];B.primary=B[5];var $=["#1f2611","#2e3c10","#3e4f13","#536d13","#6f9412","#8bbb11","#a9d134","#c9e75d","#e4f88b","#f0fab5"];$.primary=$[5];var z=["#162312","#1d3712","#274916","#306317","#3c8618","#49aa19","#6abe39","#8fd460","#b2e58b","#d5f2bb"];z.primary=z[5];var j=["#112123","#113536","#144848","#146262","#138585","#13a8a8","#33bcb7","#58d1c9","#84e2d8","#b2f1e8"];j.primary=j[5];var U=["#111a2c","#112545","#15325b","#15417e","#1554ad","#1668dc","#3c89e8","#65a9f3","#8dc5f8","#b7dcfa"];U.primary=U[5];var H=["#131629","#161d40","#1c2755","#203175","#263ea0","#2b4acb","#5273e0","#7f9ef3","#a8c1f8","#d2e0fa"];H.primary=H[5];var V=["#1a1325","#24163a","#301c4d","#3e2069","#51258f","#642ab5","#854eca","#ab7ae0","#cda8f0","#ebd7fa"];V.primary=V[5];var q=["#291321","#40162f","#551c3b","#75204f","#a02669","#cb2b83","#e0529c","#f37fb7","#f8a8cc","#fad2e3"];q.primary=q[5];var W=["#151515","#1f1f1f","#2d2d2d","#393939","#494949","#5a5a5a","#6a6a6a","#7b7b7b","#888888","#969696"];W.primary=W[5];const G=(0,c.createContext)({});function K(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function X(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?K(Object(n),!0).forEach(function(t){o(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):K(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var Y="data-rc-order",Z="data-rc-priority",J=new Map;function Q(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).mark;return e?e.startsWith("data-")?e:"data-".concat(e):"rc-util-key"}function ee(e){return e.attachTo?e.attachTo:document.querySelector("head")||document.body}function te(e){return Array.from((J.get(e)||e).children).filter(function(e){return"STYLE"===e.tagName})}function ne(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if("undefined"===typeof window||!window.document||!window.document.createElement)return null;var n=t.csp,r=t.prepend,i=t.priority,s=void 0===i?0:i,a=function(e){return"queue"===e?"prependQueue":e?"prepend":"append"}(r),o="prependQueue"===a,l=document.createElement("style");l.setAttribute(Y,a),o&&s&&l.setAttribute(Z,"".concat(s)),null!==n&&void 0!==n&&n.nonce&&(l.nonce=null===n||void 0===n?void 0:n.nonce),l.innerHTML=e;var c=ee(t),h=c.firstChild;if(r){if(o){var d=(t.styles||te(c)).filter(function(e){if(!["prepend","prependQueue"].includes(e.getAttribute(Y)))return!1;var t=Number(e.getAttribute(Z)||0);return s>=t});if(d.length)return c.insertBefore(l,d[d.length-1].nextSibling),l}c.insertBefore(l,h)}else c.appendChild(l);return l}function re(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=ee(t);return(t.styles||te(n)).find(function(n){return n.getAttribute(Q(t))===e})}function ie(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=ee(n),i=te(r),s=X(X({},n),{},{styles:i});!function(e,t){var n=J.get(e);if(!n||!function(e,t){if(!e)return!1;if(e.contains)return e.contains(t);for(var n=t;n;){if(n===e)return!0;n=n.parentNode}return!1}(document,n)){var r=ne("",t),i=r.parentNode;J.set(e,i),e.removeChild(r)}}(r,s);var a=re(t,s);if(a){var o,l,c;if(null!==(o=s.csp)&&void 0!==o&&o.nonce&&a.nonce!==(null===(l=s.csp)||void 0===l?void 0:l.nonce))a.nonce=null===(c=s.csp)||void 0===c?void 0:c.nonce;return a.innerHTML!==e&&(a.innerHTML=e),a}var h=ne(e,s);return h.setAttribute(Q(s),t),h}function se(e){var t;return null===e||void 0===e||null===(t=e.getRootNode)||void 0===t?void 0:t.call(e)}function ae(e){return function(e){return se(e)instanceof ShadowRoot}(e)?se(e):null}var oe={},le=[];function ce(e,t){}function he(e,t){}function de(e,t,n){t||oe[n]||(e(!1,n),oe[n]=!0)}function ue(e,t){de(ce,e,t)}ue.preMessage=function(e){le.push(e)},ue.resetWarned=function(){oe={}},ue.noteOnce=function(e,t){de(he,e,t)};const pe=ue;function fe(e){return"object"===s(e)&&"string"===typeof e.name&&"string"===typeof e.theme&&("object"===s(e.icon)||"function"===typeof e.icon)}function me(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(e).reduce(function(t,n){var r,i=e[n];if("class"===n)t.className=i,delete t.class;else delete t[n],t[r=n,r.replace(/-(.)/g,function(e,t){return t.toUpperCase()})]=i;return t},{})}function ge(e,t,n){return n?c.createElement(e.tag,X(X({key:t},me(e.attrs)),n),(e.children||[]).map(function(n,r){return ge(n,"".concat(t,"-").concat(e.tag,"-").concat(r))})):c.createElement(e.tag,X({key:t},me(e.attrs)),(e.children||[]).map(function(n,r){return ge(n,"".concat(t,"-").concat(e.tag,"-").concat(r))}))}function ve(e){return function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=[],r=new g(e),i=r.toHsv(),s=5;s>0;s-=1){var a=new g({h:y(i,s,!0),s:b(i,s,!0),v:w(i,s,!0)});n.push(a)}n.push(r);for(var o=1;o<=4;o+=1){var l=new g({h:y(i,o),s:b(i,o),v:w(i,o)});n.push(l)}return"dark"===t.theme?v.map(function(e){var r=e.index,i=e.amount;return new g(t.backgroundColor||"#141414").mix(n[r],i).toHexString()}):n.map(function(e){return e.toHexString()})}(e)[0]}function ye(e){return e?Array.isArray(e)?e:[e]:[]}var be=["icon","className","onClick","style","primaryColor","secondaryColor"],we={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1};var _e=function(e){var t,n,r=e.icon,i=e.className,s=e.onClick,a=e.style,o=e.primaryColor,h=e.secondaryColor,d=l(e,be),u=c.useRef(),p=we;if(o&&(p={primaryColor:o,secondaryColor:h||ve(o)}),function(e){var t=(0,c.useContext)(G),n=t.csp,r=t.prefixCls,i=t.layer,s="\n.anticon {\n display: inline-flex;\n align-items: center;\n color: inherit;\n font-style: normal;\n line-height: 0;\n text-align: center;\n text-transform: none;\n vertical-align: -0.125em;\n text-rendering: optimizeLegibility;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n.anticon > * {\n line-height: 1;\n}\n\n.anticon svg {\n display: inline-block;\n}\n\n.anticon::before {\n display: none;\n}\n\n.anticon .anticon-icon {\n display: block;\n}\n\n.anticon[tabindex] {\n cursor: pointer;\n}\n\n.anticon-spin::before,\n.anticon-spin {\n display: inline-block;\n -webkit-animation: loadingCircle 1s infinite linear;\n animation: loadingCircle 1s infinite linear;\n}\n\n@-webkit-keyframes loadingCircle {\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n\n@keyframes loadingCircle {\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n";r&&(s=s.replace(/anticon/g,r)),i&&(s="@layer ".concat(i," {\n").concat(s,"\n}")),(0,c.useEffect)(function(){var t=ae(e.current);ie(s,"@ant-design-icons",{prepend:!i,csp:n,attachTo:t})},[])}(u),t=fe(r),n="icon should be icon definiton, but got ".concat(r),pe(t,"[@ant-design/icons] ".concat(n)),!fe(r))return null;var f=r;return f&&"function"===typeof f.icon&&(f=X(X({},f),{},{icon:f.icon(p.primaryColor,p.secondaryColor)})),ge(f.icon,"svg-".concat(f.name),X(X({className:i,onClick:s,style:a,"data-icon":f.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true"},d),{},{ref:u}))};_e.displayName="IconReact",_e.getTwoToneColors=function(){return X({},we)},_e.setTwoToneColors=function(e){var t=e.primaryColor,n=e.secondaryColor;we.primaryColor=t,we.secondaryColor=n||ve(t),we.calculated=!!n};const Ae=_e;function xe(e){var t=ye(e),n=(0,i.A)(t,2),r=n[0],s=n[1];return Ae.setTwoToneColors({primaryColor:r,secondaryColor:s})}var Ee=["className","icon","spin","rotate","tabIndex","onClick","twoToneColor"];xe(D.primary);var Ce=c.forwardRef(function(e,t){var n=e.className,s=e.icon,a=e.spin,h=e.rotate,u=e.tabIndex,p=e.onClick,f=e.twoToneColor,m=l(e,Ee),g=c.useContext(G),v=g.prefixCls,y=void 0===v?"anticon":v,b=g.rootClassName,w=d()(b,y,o(o({},"".concat(y,"-").concat(s.name),!!s.name),"".concat(y,"-spin"),!!a||"loading"===s.name),n),_=u;void 0===_&&p&&(_=-1);var A=h?{msTransform:"rotate(".concat(h,"deg)"),transform:"rotate(".concat(h,"deg)")}:void 0,x=ye(f),E=(0,i.A)(x,2),C=E[0],k=E[1];return c.createElement("span",(0,r.A)({role:"img","aria-label":s.name},m,{ref:t,tabIndex:_,onClick:p,className:w}),c.createElement(Ae,{icon:s,primaryColor:C,secondaryColor:k,style:A}))});Ce.displayName="AntdIcon",Ce.getTwoToneColor=function(){var e=Ae.getTwoToneColors();return e.calculated?[e.primaryColor,e.secondaryColor]:e.primaryColor},Ce.setTwoToneColor=xe;const ke=Ce},79111(e,t,n){"use strict";n.d(t,{A:()=>o});var r=n(68102),i=n(94922);const s={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"};var a=n(80036);const o=i.forwardRef(function(e,t){return i.createElement(a.A,(0,r.A)({},e,{ref:t,icon:s}))})},12791(e,t,n){"use strict";n.d(t,{A:()=>o});var r=n(68102),i=n(94922);const s={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M505.7 661a8 8 0 0012.6 0l112-141.7c4.1-5.2.4-12.9-6.3-12.9h-74.1V168c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v338.3H400c-6.7 0-10.4 7.7-6.3 12.9l112 141.8zM878 626h-60c-4.4 0-8 3.6-8 8v154H214V634c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v198c0 17.7 14.3 32 32 32h684c17.7 0 32-14.3 32-32V634c0-4.4-3.6-8-8-8z"}}]},name:"download",theme:"outlined"};var a=n(80036);const o=i.forwardRef(function(e,t){return i.createElement(a.A,(0,r.A)({},e,{ref:t,icon:s}))})},15032(e,t,n){"use strict";n.d(t,{A:()=>o});var r=n(68102),i=n(94922);const s={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M257.7 752c2 0 4-.2 6-.5L431.9 722c2-.4 3.9-1.3 5.3-2.8l423.9-423.9a9.96 9.96 0 000-14.1L694.9 114.9c-1.9-1.9-4.4-2.9-7.1-2.9s-5.2 1-7.1 2.9L256.8 538.8c-1.5 1.5-2.4 3.3-2.8 5.3l-29.5 168.2a33.5 33.5 0 009.4 29.8c6.6 6.4 14.9 9.9 23.8 9.9zm67.4-174.4L687.8 215l73.3 73.3-362.7 362.6-88.9 15.7 15.6-89zM880 836H144c-17.7 0-32 14.3-32 32v36c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-36c0-17.7-14.3-32-32-32z"}}]},name:"edit",theme:"outlined"};var a=n(80036);const o=i.forwardRef(function(e,t){return i.createElement(a.A,(0,r.A)({},e,{ref:t,icon:s}))})},56859(e,t,n){"use strict";n.d(t,{A:()=>o});var r=n(68102),i=n(94922);const s={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}}]},name:"eye",theme:"outlined"};var a=n(80036);const o=i.forwardRef(function(e,t){return i.createElement(a.A,(0,r.A)({},e,{ref:t,icon:s}))})},2683(e,t,n){"use strict";n.d(t,{A:()=>o});var r=n(68102),i=n(94922);const s={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M574 665.4a8.03 8.03 0 00-11.3 0L446.5 781.6c-53.8 53.8-144.6 59.5-204 0-59.5-59.5-53.8-150.2 0-204l116.2-116.2c3.1-3.1 3.1-8.2 0-11.3l-39.8-39.8a8.03 8.03 0 00-11.3 0L191.4 526.5c-84.6 84.6-84.6 221.5 0 306s221.5 84.6 306 0l116.2-116.2c3.1-3.1 3.1-8.2 0-11.3L574 665.4zm258.6-474c-84.6-84.6-221.5-84.6-306 0L410.3 307.6a8.03 8.03 0 000 11.3l39.7 39.7c3.1 3.1 8.2 3.1 11.3 0l116.2-116.2c53.8-53.8 144.6-59.5 204 0 59.5 59.5 53.8 150.2 0 204L665.3 562.6a8.03 8.03 0 000 11.3l39.8 39.8c3.1 3.1 8.2 3.1 11.3 0l116.2-116.2c84.5-84.6 84.5-221.5 0-306.1zM610.1 372.3a8.03 8.03 0 00-11.3 0L372.3 598.7a8.03 8.03 0 000 11.3l39.6 39.6c3.1 3.1 8.2 3.1 11.3 0l226.4-226.4c3.1-3.1 3.1-8.2 0-11.3l-39.5-39.6z"}}]},name:"link",theme:"outlined"};var a=n(80036);const o=i.forwardRef(function(e,t){return i.createElement(a.A,(0,r.A)({},e,{ref:t,icon:s}))})},45816(e,t,n){"use strict";n.d(t,{A:()=>o});var r=n(68102),i=n(94922);const s={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M820 436h-40c-4.4 0-8 3.6-8 8v40c0 4.4 3.6 8 8 8h40c4.4 0 8-3.6 8-8v-40c0-4.4-3.6-8-8-8zm32-104H732V120c0-4.4-3.6-8-8-8H300c-4.4 0-8 3.6-8 8v212H172c-44.2 0-80 35.8-80 80v328c0 17.7 14.3 32 32 32h168v132c0 4.4 3.6 8 8 8h424c4.4 0 8-3.6 8-8V772h168c17.7 0 32-14.3 32-32V412c0-44.2-35.8-80-80-80zM360 180h304v152H360V180zm304 664H360V568h304v276zm200-140H732V500H292v204H160V412c0-6.6 5.4-12 12-12h680c6.6 0 12 5.4 12 12v292z"}}]},name:"printer",theme:"outlined"};var a=n(80036);const o=i.forwardRef(function(e,t){return i.createElement(a.A,(0,r.A)({},e,{ref:t,icon:s}))})},58882(e,t,n){"use strict";n.d(t,{A:()=>o});var r=n(68102),i=n(94922);const s={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M400 317.7h73.9V656c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V317.7H624c6.7 0 10.4-7.7 6.3-12.9L518.3 163a8 8 0 00-12.6 0l-112 141.7c-4.1 5.3-.4 13 6.3 13zM878 626h-60c-4.4 0-8 3.6-8 8v154H214V634c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v198c0 17.7 14.3 32 32 32h684c17.7 0 32-14.3 32-32V634c0-4.4-3.6-8-8-8z"}}]},name:"upload",theme:"outlined"};var a=n(80036);const o=i.forwardRef(function(e,t){return i.createElement(a.A,(0,r.A)({},e,{ref:t,icon:s}))})},38930(e,t,n){"use strict";n.d(t,{ZF:()=>N,lV:()=>k});var r=n(94922),i=n(55199),s=n(78678),a=n(68102);const o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"info-circle",theme:"filled"};var l=n(80036);const c=r.forwardRef(function(e,t){return r.createElement(l.A,(0,a.A)({},e,{ref:t,icon:o}))});const h={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M176 511a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0z"}}]},name:"ellipsis",theme:"outlined"};const d=r.forwardRef(function(e,t){return r.createElement(l.A,(0,a.A)({},e,{ref:t,icon:h}))});const u={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"};const p=r.forwardRef(function(e,t){return r.createElement(l.A,(0,a.A)({},e,{ref:t,icon:u}))});var f=n(54159),m=n.n(f),g=n(20274),v=(n(16052),n(50805)),y=n(26938),b=n.n(y),w=n(73075),_=n.n(w);n(85714),n(98771);function A(){return A=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},A.apply(null,arguments)}function x(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}const E=["onClick","children","loading"],C=e=>{const[t,n]=(0,r.useState)(!1),i=(0,s.A)(function(){return n(!0),Promise.resolve(e&&e(...arguments)).then(()=>{n(!1)}).catch(e=>{n(!1),console.error(e)})});return{isLoading:t,setIsLoading:n,callback:i}},k=e=>{let{onClick:t,children:n,loading:s}=e,a=x(e,E);const{isLoading:o,callback:l}=C(t);return r.createElement(i.Button,A({},a,{loading:s||o,onClick:l}),"function"===typeof n?n(s||o):n)};var S="_zIHFy",T="_R-IrF",D="_F1kMl",M="_Iee0d",P="_aGBVE",I="_0oW1K";const F={message:"\u786e\u5b9a\u8981\u5220\u9664\u5417\uff1f",confirm:"\u786e\u5b9a",delete:"\u5220\u9664",cancel:"\u53d6\u6d88",more:"\u66f4\u591a"},R=["title","message","isDelete","showCancel","cancelText","onCancel","isModal","okText","placement","children","onClick","getContainer","renderModal"],N=(0,g.createWithIntlProvider)("zh-CN",F,"button-group")(e=>{const{formatMessage:t}=(0,g.useIntl)(),n=Object.assign({},e),{title:a,message:o,isDelete:l,showCancel:h,cancelText:d,onCancel:u,isModal:p,okText:f,placement:v,children:y,onClick:b,getContainer:w,renderModal:_}=n,E=x(n,R),[k,F]=(0,r.useState)(!1),{isLoading:N,callback:L}=C(b),O=(0,s.A)(()=>{F(!0)}),B=r.createElement(i.Flex,{className:D,vertical:!0,gap:8,onClick:e=>{e.stopPropagation()}},a&&r.createElement(i.Flex,{align:"flex-start",gap:8,className:M},l&&r.createElement(c,{className:"title-icon"}),a),r.createElement(i.Flex,{align:"flex-start",gap:8,className:m()(P,{[I]:a})},!a&&l?r.createElement(c,{className:"title-icon"}):null,o||t({id:"message"}))),$=()=>"function"===typeof y?y(A({},E,{onClick:O},l&&{style:A({color:"#ff4d4f"},E.style)})):r.createElement(i.Button,A({},E,{loading:N,onClick:()=>{O()}}),y);if(p){const e={open:k,onCancel:()=>{F(!1),u&&u()},wrapClassName:T,okText:f||t(l?{id:"delete"}:{id:"confirm"}),cancelText:d||t({id:"cancel"}),onOk:e=>(F(!1),L(e)),closable:!1,okButtonProps:{danger:l},getContainer:w,children:B};return r.createElement(r.Fragment,null,"function"===typeof _?_(e):r.createElement(i.Modal,e),$())}return r.createElement(i.Popconfirm,{overlayClassName:m()(S),okButtonProps:{danger:l},title:B,open:k,getPopupContainer:w,onCancel:u,placement:v,showCancel:h,okText:f||t(l?{id:"delete"}:{id:"confirm"}),cancelText:d||t({id:"cancel"}),onOpenChange:F,onConfirm:e=>{L(e)}},$())}),L=_()(e=>{let{amountWidth:t,moreBtnWidth:n,buttonWidthList:r,spaceProps:i,compact:s}=e;const a=s?0:["small","middle","large"].indexOf(i.size)>-1?8*(["small","middle","large"].indexOf(i.size)+1):Number.isInteger(i.size)?i.size:8;let o=0,l=0;for(;t>=l+r[o]+o*a&&o<r.length;)l+=r[o],o+=1;for(;t<l+(o-1)*a+(o<r.length?n+a:0)&&o>0;)l-=r[o-1],o-=1;return o},e=>{let{amountWidth:t,moreBtnWidth:n,buttonWidthList:r,spaceProps:i,compact:s}=e;return`${t}${n}${r.join(",")}${Object.values(i).join(",")}${s&&s.toString()}`});var O={"width-container":"_V58ju","hidden-container":"_XN3o6","hidden-inner":"_-depB","more-link-btn":"_Hh4Wb","menu-list":"_juFTd"};const B=["list","more","moreType","compact","showLength","getPopupContainer","trigger","itemClassName"],$=["className","confirm","buttonComponent","tooltipProps","hidden","isDelete","isModal"];(0,g.createWithIntlProvider)("zh-CN",F,"button-group")(e=>{const{formatMessage:t}=(0,g.useIntl)(),n=Object.assign({},e),{list:a,more:o,moreType:l,compact:c,showLength:h,getPopupContainer:u,trigger:f,itemClassName:y}=n,w=x(n,B),_=(0,r.useMemo)(()=>a.filter(e=>!(null!=e&&e.hidden)),[a]),E=b()(w,["size","split","align","style"]),[C,S]=(0,r.useState)(_.length&&1),T=Number.isInteger(h)?h:C,D=(0,s.A)(()=>{const e=P.current,t=I.current,n=M.current;if(!e)return;const i=e.querySelectorAll(".button-group-item");if(!i)return;if(0===i.length)return;const s=n.clientWidth,a=t.clientWidth,o=[].map.call(i,e=>e.offsetWidth),l=L({amountWidth:s,moreBtnWidth:a,buttonWidthList:o,spaceProps:E,compact:c});(0,r.startTransition)(()=>{S(l)})}),M=(0,v.A)(D),P=(0,v.A)(D),I=(0,v.A)(D),F=_.slice(T),R=(e,t,n)=>{if("function"===typeof e)return e({key:t,className:m()("button-group-item",O["btn-item"],y)},{isDropdown:n});const{className:s,confirm:a,buttonComponent:o,tooltipProps:l,isDelete:c,isModal:h}=e,d=x(e,$),u=a||!!d.message||c,p=o||(u?N:k),f=r.createElement(p,A({danger:u&&!1!==c,isDelete:!(u&&!1===c)},Object.assign({},d,u&&(h||n)?{isModal:!0}:{},n?{type:"default"}:{}),{key:t,className:m()("button-group-item",s,y)}));return l?r.createElement(i.Tooltip,l,f):f},z=o||("link"===l?r.createElement(i.Button,{type:"link",className:m()("button-group-item",y,O["more-link-btn"])},r.createElement(d,{style:{fontSize:"16px"}})):r.createElement(i.Button,null,t({id:"more"}),r.createElement(p,null))),j=c?i.Space.Compact:i.Space;return r.createElement(r.Fragment,null,r.createElement("div",{className:O["width-container"],ref:M}),r.createElement("div",{className:O["hidden-container"]},r.createElement("div",{className:O["hidden-inner"],ref:I},z),r.createElement("div",{className:O["hidden-inner"],ref:P},r.createElement(j,E,_.map((e,t)=>r.createElement(r.Fragment,{key:t},R(e,t,!1)))))),r.createElement(j,E,_.slice(0,T).map((e,t)=>r.createElement(r.Fragment,{key:t},R(e,t,!1))),F.length>0&&r.createElement(i.Dropdown,{getPopupContainer:u,trigger:f,rootClassName:O["menu-list"],menu:{items:F.map((e,t)=>({key:t,label:R(e,t,!0)}))}},z)))})},79461(e,t,n){"use strict";n.d(t,{A:()=>r});const r=e=>{const t=[];let n=0;const r=()=>{if(0!==t.length){if(n<e){const e=t.shift();n+=1,e().finally(()=>{n-=1,r()})}}else n=0};return e=>new Promise(n=>{t.push(()=>{const t=Promise.resolve().then(()=>e());return n(t),t}),r()})}},36580(e,t,n){"use strict";n.d(t,{A:()=>z});var r,i=0,s=!1,a=!1,o="[iFrameSizer]",l=null,c=window.requestAnimationFrame,h=Object.freeze({max:1,scroll:1,bodyScroll:1,documentElementScroll:1}),d={},u=null,p=Object.freeze({autoResize:!0,bodyBackground:null,bodyMargin:null,bodyMarginV1:8,bodyPadding:null,checkOrigin:!0,inPageLinks:!1,enablePublicMethods:!0,heightCalculationMethod:"bodyOffset",id:"iFrameResizer",interval:32,license:"1jqr0si6pnt",log:!1,maxHeight:1/0,maxWidth:1/0,minHeight:0,minWidth:0,mouseEvents:!0,resizeFrom:"parent",scrolling:!1,sizeHeight:!0,sizeWidth:!1,warningTimeout:5e3,tolerance:0,widthCalculationMethod:"scroll",onClose:function(){return!0},onClosed:function(){},onInit:function(){},onMessage:function(){w("onMessage function not defined")},onMouseEnter:function(){},onMouseLeave:function(){},onResized:function(){},onScroll:function(){return!0}});function f(){return window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver}function m(e,t,n){e.addEventListener(t,n,!1)}function g(e,t,n){e.removeEventListener(t,n,!1)}function v(e){return o+"["+function(e){var t="Host page: "+e;return window.top!==window.self&&(t=window.parentIFrame&&window.parentIFrame.getId?window.parentIFrame.getId()+": "+e:"Nested host page: "+e),t}(e)+"]"}function y(e){return d[e]?d[e].log:s}function b(e,t){_("log",e,t,y(e))}function w(e,t){_("warn",e,t,!0)}function _(e,t,n,r){!0===r&&"object"===typeof window.console&&console[e](v(t),n)}function A(e){function t(){i("Height"),i("Width"),P(function(){M(A),S(E),f("onResized",A)},A,"init")}function n(e){return"border-box"!==e.boxSizing?0:(e.paddingTop?parseInt(e.paddingTop,10):0)+(e.paddingBottom?parseInt(e.paddingBottom,10):0)}function r(e){return"border-box"!==e.boxSizing?0:(e.borderTopWidth?parseInt(e.borderTopWidth,10):0)+(e.borderBottomWidth?parseInt(e.borderBottomWidth,10):0)}function i(e){var t=Number(d[E]["max"+e]),n=Number(d[E]["min"+e]),r=e.toLowerCase(),i=Number(A[r]);b(E,"Checking "+r+" is in range "+n+"-"+t),i<n&&(i=n,b(E,"Set "+r+" to min value")),i>t&&(i=t,b(E,"Set "+r+" to max value")),A[r]=""+i}function s(e){return v.slice(v.indexOf(":")+7+e)}function a(e,t){var n,r,i;n=function(){I("Send Page Info","pageInfo:"+function(){var e=document.body.getBoundingClientRect(),t=A.iframe.getBoundingClientRect();return JSON.stringify({iframeHeight:t.height,iframeWidth:t.width,clientHeight:Math.max(document.documentElement.clientHeight,window.innerHeight||0),clientWidth:Math.max(document.documentElement.clientWidth,window.innerWidth||0),offsetTop:parseInt(t.top-e.top,10),offsetLeft:parseInt(t.left-e.left,10),scrollTop:window.pageYOffset,scrollLeft:window.pageXOffset,documentHeight:document.documentElement.clientHeight,documentWidth:document.documentElement.clientWidth,windowHeight:window.innerHeight,windowWidth:window.innerWidth})}(),e,t)},r=32,L[i=t]||(L[i]=setTimeout(function(){L[i]=null,n()},r))}function c(e){var t=e.getBoundingClientRect();return k(E),{x:Math.floor(Number(t.left)+Number(l.x)),y:Math.floor(Number(t.top)+Number(l.y))}}function h(e){var t=e?c(A.iframe):{x:0,y:0},n={x:Number(A.width)+t.x,y:Number(A.height)+t.y};b(E,"Reposition requested from iFrame (offset x:"+t.x+" y:"+t.y+")"),window.top===window.self?(l=n,u(),b(E,"--")):window.parentIFrame?window.parentIFrame["scrollTo"+(e?"Offset":"")](n.x,n.y):w(E,"Unable to scroll to requested position, window.parentIFrame not found")}function u(){!1===f("onScroll",l)?T():S(E)}function p(e){var t={};if(0===Number(A.width)&&0===Number(A.height)){var n=s(9).split(":");t={x:n[1],y:n[0]}}else t={x:A.width,y:A.height};f(e,{iframe:A.iframe,screenX:Number(t.x),screenY:Number(t.y),type:A.type})}function f(e,t){return x(E,e,t)}var v=e.data,A={},E=null;"[iFrameResizerChild]Ready"===v?function(){for(var e in d)I("iFrame requested init",F(e),d[e].iframe,e)}():o===(""+v).slice(0,13)&&v.slice(13).split(":")[0]in d?(A=function(){var e=v.slice(13).split(":"),t=e[1]?parseInt(e[1],10):0,i=d[e[0]]&&d[e[0]].iframe,s=getComputedStyle(i);return{iframe:i,id:e[0],height:t+n(s)+r(s),width:e[2],type:e[3]}}(),E=A.id,d[E]&&(d[E].loaded=!0),!function(){var e=A.type in{true:1,false:1,undefined:1};return e&&b(E,"Ignoring init message from meta parent page"),e}()&&function(e){var t=!0;return d[e]||(t=!1,w(A.type+" No settings for "+e+". Message was: "+v)),t}(E)&&(b(E,"Received: "+v),function(){var e=!0;return null===A.iframe&&(w(E,"IFrame ("+A.id+") not found"),e=!1),e}()&&function(){var t=e.origin,n=d[E]&&d[E].checkOrigin;if(n&&""+t!=="null"&&!(n.constructor===Array?function(){var e=0,r=!1;for(b(E,"Checking connection is from allowed list of origins: "+n);e<n.length;e++)if(n[e]===t){r=!0;break}return r}():function(){var e=d[E]&&d[E].remoteHost;return b(E,"Checking connection is from: "+e),t===e}()))throw new Error("Unexpected message received from: "+t+" for "+A.iframe.id+". Message was: "+e.data+". This error can be disabled by setting the checkOrigin: false option or by providing of array of trusted domains.");return!0}()&&function(){switch(d[E]&&d[E].firstRun&&d[E]&&(d[E].firstRun=!1),A.type){case"close":C(A.iframe);break;case"message":e=s(6),b(E,"onMessage passed: {iframe: "+A.iframe.id+", message: "+e+"}"),f("onMessage",{iframe:A.iframe,message:JSON.parse(e)}),b(E,"--");break;case"mouseenter":p("onMouseEnter");break;case"mouseleave":p("onMouseLeave");break;case"autoResize":d[E].autoResize=JSON.parse(s(9));break;case"scrollTo":h(!1);break;case"scrollToOffset":h(!0);break;case"pageInfo":a(d[E]&&d[E].iframe,E),function(){function e(e,r){function i(){d[n]?a(d[n].iframe,n):t()}["scroll","resize"].forEach(function(t){b(n,e+t+" listener for sendPageInfo"),r(window,t,i)})}function t(){e("Remove ",g)}var n=E;e("Add ",m),d[n]&&(d[n].stopPageInfo=t)}();break;case"pageInfoStop":d[E]&&d[E].stopPageInfo&&(d[E].stopPageInfo(),delete d[E].stopPageInfo);break;case"inPageLink":!function(e){var t=e.split("#")[1]||"",n=decodeURIComponent(t),r=document.getElementById(n)||document.getElementsByName(n)[0];r?function(){var e=c(r);b(E,"Moving to in page link (#"+t+") at x: "+e.x+" y: "+e.y),l={x:e.x,y:e.y},u(),b(E,"--")}():window.top===window.self?b(E,"In page link #"+t+" not found"):window.parentIFrame?window.parentIFrame.moveToAnchor(t):b(E,"In page link #"+t+" not found and window.parentIFrame not found")}(s(9));break;case"reset":D(A);break;case"init":t(),f("onInit",A.iframe);break;default:0===Number(A.width)&&0===Number(A.height)?w("Unsupported message received ("+A.type+"), this is likely due to the iframe containing a later version of iframe-resizer than the parent page"):t()}var e}())):function(e,t){_("info",e,t,y(e))}(E,"Ignored: "+v)}function x(e,t,n){var r=null,i=null;if(d[e]){if("function"!==typeof(r=d[e][t]))throw new TypeError(t+" on iFrame["+e+"] is not a function");i=r(n)}return i}function E(e){var t=e.id;delete d[t]}function C(e){var t=e.id;if(!1!==x(t,"onClose",t)){b(t,"Removing iFrame: "+t);try{e.parentNode&&e.parentNode.removeChild(e)}catch(n){w(n)}x(t,"onClosed",t),b(t,"--"),E(e),r&&(r.disconnect(),r=null)}else b(t,"Close iframe cancelled by onClose event")}function k(e){null===l&&b(e,"Get page position: "+(l={x:void 0===window.pageXOffset?document.documentElement.scrollLeft:window.pageXOffset,y:void 0===window.pageYOffset?document.documentElement.scrollTop:window.pageYOffset}).x+","+l.y)}function S(e){null!==l&&(window.scrollTo(l.x,l.y),b(e,"Set page position: "+l.x+","+l.y),T())}function T(){l=null}function D(e){b(e.id,"Size reset requested by "+("init"===e.type?"host page":"iFrame")),k(e.id),P(function(){M(e),I("reset","reset",e.iframe,e.id)},e,"reset")}function M(e){function t(t){a||"0"!==e[t]||(a=!0,b(r,"Hidden iFrame detected, creating visibility listener"),function(){function e(){function e(e){function t(t){return"0px"===(d[e]&&d[e].iframe.style[t])}function n(e){return null!==e.offsetParent}d[e]&&n(d[e].iframe)&&(t("height")||t("width"))&&I("Visibility change","resize",d[e].iframe,e)}Object.keys(d).forEach(function(t){e(t)})}function t(t){b("window","Mutation observed: "+t[0].target+" "+t[0].type),N(e,16)}function n(){var e=document.querySelector("body"),n={attributes:!0,attributeOldValue:!1,characterData:!0,characterDataOldValue:!1,childList:!0,subtree:!0};new r(t).observe(e,n)}var r=f();r&&n()}())}function n(n){!function(t){e.id?(e.iframe.style[t]=e[t]+"px",b(e.id,"IFrame ("+r+") "+t+" set to "+e[t]+"px")):b("undefined","messageData id not set")}(n),t(n)}var r=e.iframe.id;d[r]&&(d[r].sizeHeight&&n("height"),d[r].sizeWidth&&n("width"))}function P(e,t,n){n!==t.type&&c&&!window.jasmine?(b(t.id,"Requesting animation frame"),c(e)):e()}function I(e,t,n,r,i){var s=!1;r=r||n.id,d[r]&&(n&&"contentWindow"in n&&null!==n.contentWindow?function(){var i=d[r]&&d[r].targetOrigin;b(r,"["+e+"] Sending msg to iframe["+r+"] ("+t+") targetOrigin: "+i),n.contentWindow.postMessage(o+t,i)}():w(r,"["+e+"] IFrame("+r+") not found"),i&&d[r]&&d[r].warningTimeout&&(d[r].msgTimeout=setTimeout(function(){!d[r]||d[r].loaded||s||(s=!0,w(r,"IFrame has not responded within "+d[r].warningTimeout/1e3+" seconds. Check iFrameResizer.contentWindow.js has been loaded in iFrame. This message can be ignored if everything is working, or you can set the warningTimeout option to a higher value or zero to suppress this warning."))},d[r].warningTimeout)))}function F(e){return e+":"+d[e].bodyMarginV1+":"+d[e].sizeWidth+":"+d[e].log+":"+d[e].interval+":"+d[e].enablePublicMethods+":"+d[e].autoResize+":"+d[e].bodyMargin+":"+d[e].heightCalculationMethod+":"+d[e].bodyBackground+":"+d[e].bodyPadding+":"+d[e].tolerance+":"+d[e].inPageLinks+":"+d[e].resizeFrom+":"+d[e].widthCalculationMethod+":"+d[e].mouseEvents}function R(e,t){function n(e){var t=e.split("Callback");if(2===t.length){var n="on"+t[0].charAt(0).toUpperCase()+t[0].slice(1);this[n]=this[e],delete this[e],w(a,"Deprecated: '"+e+"' has been renamed '"+n+"'. The old method will be removed in the next major version.")}}var a=function(n){if("string"!==typeof n)throw new TypeError("Invaild id for iFrame. Expected String");return""===n&&(e.id=n=function(){var e=t&&t.id||p.id+i++;return null!==document.getElementById(e)&&(e+=i++),e}(),s=(t||{}).log,b(n,"Added missing iframe ID: "+n+" ("+e.src+")")),n}(e.id);a in d&&"iFrameResizer"in e?w(a,"Ignored iFrame, already setup."):(!function(t){var r;t=t||{},d[a]=Object.create(null),d[a].iframe=e,d[a].firstRun=!0,d[a].remoteHost=e.src&&e.src.split("/").slice(0,3).join("/"),function(e){if("object"!==typeof e)throw new TypeError("Options is not an object")}(t),Object.keys(t).forEach(n,t),function(e){for(var t in p)Object.prototype.hasOwnProperty.call(p,t)&&(d[a][t]=Object.prototype.hasOwnProperty.call(e,t)?e[t]:p[t])}(t),d[a]&&(d[a].targetOrigin=!0===d[a].checkOrigin?""===(r=d[a].remoteHost)||null!==r.match(/^(about:blank|javascript:|file:\/\/)/)?"*":r:"*")}(t),function(){switch(b(a,"IFrame scrolling "+(d[a]&&d[a].scrolling?"enabled":"disabled")+" for "+a),e.style.overflow=!1===(d[a]&&d[a].scrolling)?"hidden":"auto",d[a]&&d[a].scrolling){case"omit":break;case!0:e.scrolling="yes";break;case!1:e.scrolling="no";break;default:e.scrolling=d[a]?d[a].scrolling:"no"}}(),function(){function t(t){var n=d[a][t];1/0!==n&&0!==n&&(e.style[t]="number"===typeof n?n+"px":n,b(a,"Set "+t+" = "+e.style[t]))}function n(e){if(d[a]["min"+e]>d[a]["max"+e])throw new Error("Value for min"+e+" can not be greater than max"+e)}n("Height"),n("Width"),t("maxHeight"),t("minHeight"),t("maxWidth"),t("minWidth")}(),"number"!==typeof(d[a]&&d[a].bodyMargin)&&"0"!==(d[a]&&d[a].bodyMargin)||(d[a].bodyMarginV1=d[a].bodyMargin,d[a].bodyMargin=d[a].bodyMargin+"px"),function(t){var n=f();n&&(r=function(t){if(!e.parentNode)return null;var n=new t(function(t){t.forEach(function(t){Array.prototype.slice.call(t.removedNodes).forEach(function(t){t===e&&C(e)})})});return n.observe(e.parentNode,{childList:!0}),n}(n)),m(e,"load",function(){I("iFrame.onload",t,e,void 0,!0),function(){var t=d[a]&&d[a].firstRun,n=d[a]&&d[a].heightCalculationMethod in h;!t&&n&&D({iframe:e,height:0,width:0,type:"init"})}()}),I("init",t,e,void 0,!0)}(F(a)),d[a]&&(d[a].iframe.iFrameResizer={close:C.bind(null,d[a].iframe),removeListeners:E.bind(null,d[a].iframe),resize:I.bind(null,"Window resize","resize",d[a].iframe),moveToAnchor:function(e){I("Move to anchor","moveToAnchor:"+e,d[a].iframe,a)},sendMessage:function(e){I("Send Message","message:"+(e=JSON.stringify(e)),d[a].iframe,a)}}))}function N(e,t){null===u&&(u=setTimeout(function(){u=null,e()},t))}var L={};function O(){"hidden"!==document.visibilityState&&(b("document","Trigger event: Visibility change"),N(function(){B("Tab Visible","resize")},16))}function B(e,t){Object.keys(d).forEach(function(n){(function(e){return d[e]&&"parent"===d[e].resizeFrom&&d[e].autoResize&&!d[e].firstRun})(n)&&I(e,t,d[n].iframe,n)})}function $(){m(window,"message",A),m(window,"resize",function(){var e;b("window","Trigger event: "+(e="resize")),N(function(){B("Window "+e,"resize")},16)}),m(document,"visibilitychange",O),m(document,"-webkit-visibilitychange",O)}var z=function(){function e(e,n){n&&(!function(){if(!n.tagName)throw new TypeError("Object is not a valid DOM element");if("IFRAME"!==n.tagName.toUpperCase())throw new TypeError("Expected <IFRAME> tag, found <"+n.tagName+">")}(),R(n,e),t.push(n))}var t;return function(){var e,t=["moz","webkit","o","ms"];for(e=0;e<t.length&&!c;e+=1)c=window[t[e]+"RequestAnimationFrame"];c?c=c.bind(window):b("setup","RequestAnimationFrame not supported")}(),$(),function(n,r){switch(t=[],function(e){e&&e.enablePublicMethods&&w("enablePublicMethods option has been removed, public methods are now always available in the iFrame")}(n),typeof r){case"undefined":case"string":Array.prototype.forEach.call(document.querySelectorAll(r||"iframe"),e.bind(void 0,n));break;case"object":e(n,r);break;default:throw new TypeError("Unexpected data type ("+typeof r+")")}return t}}()},79690(e,t,n){"use strict";n.d(t,{A:()=>Pe});var r=n(20274),i=n(94922),s=n(54159),a=n.n(s);function o(e){return Array.isArray?Array.isArray(e):"[object Array]"===f(e)}function l(e){return"string"===typeof e}function c(e){return"number"===typeof e}function h(e){return!0===e||!1===e||function(e){return d(e)&&null!==e}(e)&&"[object Boolean]"==f(e)}function d(e){return"object"===typeof e}function u(e){return void 0!==e&&null!==e}function p(e){return!e.trim().length}function f(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const m=Object.prototype.hasOwnProperty;class g{constructor(e){this._keys=[],this._keyMap={};let t=0;e.forEach(e=>{let n=v(e);this._keys.push(n),this._keyMap[n.id]=n,t+=n.weight}),this._keys.forEach(e=>{e.weight/=t})}get(e){return this._keyMap[e]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}}function v(e){let t=null,n=null,r=null,i=1,s=null;if(l(e)||o(e))r=e,t=y(e),n=b(e);else{if(!m.call(e,"name"))throw new Error((e=>`Missing ${e} property in key`)("name"));const a=e.name;if(r=a,m.call(e,"weight")&&(i=e.weight,i<=0))throw new Error((e=>`Property 'weight' in key '${e}' must be a positive integer`)(a));t=y(a),n=b(a),s=e.getFn}return{path:t,id:n,weight:i,src:r,getFn:s}}function y(e){return o(e)?e:e.split(".")}function b(e){return o(e)?e.join("."):e}var w={isCaseSensitive:!1,ignoreDiacritics:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,t)=>e.score===t.score?e.idx<t.idx?-1:1:e.score<t.score?-1:1,includeMatches:!1,findAllMatches:!1,minMatchCharLength:1,location:0,threshold:.6,distance:100,...{useExtendedSearch:!1,getFn:function(e,t){let n=[],r=!1;const i=(e,t,s)=>{if(u(e))if(t[s]){const a=e[t[s]];if(!u(a))return;if(s===t.length-1&&(l(a)||c(a)||h(a)))n.push(function(e){return null==e?"":function(e){if("string"==typeof e)return e;let t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(e)}(a));else if(o(a)){r=!0;for(let e=0,n=a.length;e<n;e+=1)i(a[e],t,s+1)}else t.length&&i(a,t,s+1)}else n.push(e)};return i(e,l(t)?t.split("."):t,0),r?n:n[0]},ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1}};const _=/[^ ]+/g;class A{constructor(){let{getFn:e=w.getFn,fieldNormWeight:t=w.fieldNormWeight}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.norm=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3;const n=new Map,r=Math.pow(10,t);return{get(t){const i=t.match(_).length;if(n.has(i))return n.get(i);const s=1/Math.pow(i,.5*e),a=parseFloat(Math.round(s*r)/r);return n.set(i,a),a},clear(){n.clear()}}}(t,3),this.getFn=e,this.isCreated=!1,this.setIndexRecords()}setSources(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];this.docs=e}setIndexRecords(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];this.records=e}setKeys(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];this.keys=e,this._keysMap={},e.forEach((e,t)=>{this._keysMap[e.id]=t})}create(){!this.isCreated&&this.docs.length&&(this.isCreated=!0,l(this.docs[0])?this.docs.forEach((e,t)=>{this._addString(e,t)}):this.docs.forEach((e,t)=>{this._addObject(e,t)}),this.norm.clear())}add(e){const t=this.size();l(e)?this._addString(e,t):this._addObject(e,t)}removeAt(e){this.records.splice(e,1);for(let t=e,n=this.size();t<n;t+=1)this.records[t].i-=1}getValueForItemAtKeyId(e,t){return e[this._keysMap[t]]}size(){return this.records.length}_addString(e,t){if(!u(e)||p(e))return;let n={v:e,i:t,n:this.norm.get(e)};this.records.push(n)}_addObject(e,t){let n={i:t,$:{}};this.keys.forEach((t,r)=>{let i=t.getFn?t.getFn(e):this.getFn(e,t.path);if(u(i))if(o(i)){let e=[];const t=[{nestedArrIndex:-1,value:i}];for(;t.length;){const{nestedArrIndex:n,value:r}=t.pop();if(u(r))if(l(r)&&!p(r)){let t={v:r,i:n,n:this.norm.get(r)};e.push(t)}else o(r)&&r.forEach((e,n)=>{t.push({nestedArrIndex:n,value:e})})}n.$[r]=e}else if(l(i)&&!p(i)){let e={v:i,n:this.norm.get(i)};n.$[r]=e}}),this.records.push(n)}toJSON(){return{keys:this.keys,records:this.records}}}function x(e,t){let{getFn:n=w.getFn,fieldNormWeight:r=w.fieldNormWeight}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const i=new A({getFn:n,fieldNormWeight:r});return i.setKeys(e.map(v)),i.setSources(t),i.create(),i}function E(e){let{errors:t=0,currentLocation:n=0,expectedLocation:r=0,distance:i=w.distance,ignoreLocation:s=w.ignoreLocation}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const a=t/e.length;if(s)return a;const o=Math.abs(r-n);return i?a+o/i:o?1:a}const C=32;function k(e,t,n){let{location:r=w.location,distance:i=w.distance,threshold:s=w.threshold,findAllMatches:a=w.findAllMatches,minMatchCharLength:o=w.minMatchCharLength,includeMatches:l=w.includeMatches,ignoreLocation:c=w.ignoreLocation}=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};if(t.length>C)throw new Error(`Pattern length exceeds max of ${C}.`);const h=t.length,d=e.length,u=Math.max(0,Math.min(r,d));let p=s,f=u;const m=o>1||l,g=m?Array(d):[];let v;for(;(v=e.indexOf(t,f))>-1;){let e=E(t,{currentLocation:v,expectedLocation:u,distance:i,ignoreLocation:c});if(p=Math.min(e,p),f=v+h,m){let e=0;for(;e<h;)g[v+e]=1,e+=1}}f=-1;let y=[],b=1,_=h+d;const A=1<<h-1;for(let w=0;w<h;w+=1){let r=0,s=_;for(;r<s;){E(t,{errors:w,currentLocation:u+s,expectedLocation:u,distance:i,ignoreLocation:c})<=p?r=s:_=s,s=Math.floor((_-r)/2+r)}_=s;let o=Math.max(1,u-s+1),l=a?d:Math.min(u+s,d)+h,v=Array(l+2);v[l+1]=(1<<w)-1;for(let a=l;a>=o;a-=1){let r=a-1,s=n[e.charAt(r)];if(m&&(g[r]=+!!s),v[a]=(v[a+1]<<1|1)&s,w&&(v[a]|=(y[a+1]|y[a])<<1|1|y[a+1]),v[a]&A&&(b=E(t,{errors:w,currentLocation:r,expectedLocation:u,distance:i,ignoreLocation:c}),b<=p)){if(p=b,f=r,f<=u)break;o=Math.max(1,2*u-f)}}if(E(t,{errors:w+1,currentLocation:u,expectedLocation:u,distance:i,ignoreLocation:c})>p)break;y=v}const x={isMatch:f>=0,score:Math.max(.001,b)};if(m){const e=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:w.minMatchCharLength,n=[],r=-1,i=-1,s=0;for(let a=e.length;s<a;s+=1){let a=e[s];a&&-1===r?r=s:a||-1===r||(i=s-1,i-r+1>=t&&n.push([r,i]),r=-1)}return e[s-1]&&s-r>=t&&n.push([r,s-1]),n}(g,o);e.length?l&&(x.indices=e):x.isMatch=!1}return x}function S(e){let t={};for(let n=0,r=e.length;n<r;n+=1){const i=e.charAt(n);t[i]=(t[i]||0)|1<<r-n-1}return t}const T=String.prototype.normalize?e=>e.normalize("NFD").replace(/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F]/g,""):e=>e;class D{constructor(e){let{location:t=w.location,threshold:n=w.threshold,distance:r=w.distance,includeMatches:i=w.includeMatches,findAllMatches:s=w.findAllMatches,minMatchCharLength:a=w.minMatchCharLength,isCaseSensitive:o=w.isCaseSensitive,ignoreDiacritics:l=w.ignoreDiacritics,ignoreLocation:c=w.ignoreLocation}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(this.options={location:t,threshold:n,distance:r,includeMatches:i,findAllMatches:s,minMatchCharLength:a,isCaseSensitive:o,ignoreDiacritics:l,ignoreLocation:c},e=o?e:e.toLowerCase(),e=l?T(e):e,this.pattern=e,this.chunks=[],!this.pattern.length)return;const h=(e,t)=>{this.chunks.push({pattern:e,alphabet:S(e),startIndex:t})},d=this.pattern.length;if(d>C){let e=0;const t=d%C,n=d-t;for(;e<n;)h(this.pattern.substr(e,C),e),e+=C;if(t){const e=d-C;h(this.pattern.substr(e),e)}}else h(this.pattern,0)}searchIn(e){const{isCaseSensitive:t,ignoreDiacritics:n,includeMatches:r}=this.options;if(e=t?e:e.toLowerCase(),e=n?T(e):e,this.pattern===e){let t={isMatch:!0,score:0};return r&&(t.indices=[[0,e.length-1]]),t}const{location:i,distance:s,threshold:a,findAllMatches:o,minMatchCharLength:l,ignoreLocation:c}=this.options;let h=[],d=0,u=!1;this.chunks.forEach(t=>{let{pattern:n,alphabet:p,startIndex:f}=t;const{isMatch:m,score:g,indices:v}=k(e,n,p,{location:i+f,distance:s,threshold:a,findAllMatches:o,minMatchCharLength:l,includeMatches:r,ignoreLocation:c});m&&(u=!0),d+=g,m&&v&&(h=[...h,...v])});let p={isMatch:u,score:u?d/this.chunks.length:1};return u&&r&&(p.indices=h),p}}class M{constructor(e){this.pattern=e}static isMultiMatch(e){return P(e,this.multiRegex)}static isSingleMatch(e){return P(e,this.singleRegex)}search(){}}function P(e,t){const n=e.match(t);return n?n[1]:null}class I extends M{constructor(e){let{location:t=w.location,threshold:n=w.threshold,distance:r=w.distance,includeMatches:i=w.includeMatches,findAllMatches:s=w.findAllMatches,minMatchCharLength:a=w.minMatchCharLength,isCaseSensitive:o=w.isCaseSensitive,ignoreDiacritics:l=w.ignoreDiacritics,ignoreLocation:c=w.ignoreLocation}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};super(e),this._bitapSearch=new D(e,{location:t,threshold:n,distance:r,includeMatches:i,findAllMatches:s,minMatchCharLength:a,isCaseSensitive:o,ignoreDiacritics:l,ignoreLocation:c})}static get type(){return"fuzzy"}static get multiRegex(){return/^"(.*)"$/}static get singleRegex(){return/^(.*)$/}search(e){return this._bitapSearch.searchIn(e)}}class F extends M{constructor(e){super(e)}static get type(){return"include"}static get multiRegex(){return/^'"(.*)"$/}static get singleRegex(){return/^'(.*)$/}search(e){let t,n=0;const r=[],i=this.pattern.length;for(;(t=e.indexOf(this.pattern,n))>-1;)n=t+i,r.push([t,n-1]);const s=!!r.length;return{isMatch:s,score:s?0:1,indices:r}}}const R=[class extends M{constructor(e){super(e)}static get type(){return"exact"}static get multiRegex(){return/^="(.*)"$/}static get singleRegex(){return/^=(.*)$/}search(e){const t=e===this.pattern;return{isMatch:t,score:t?0:1,indices:[0,this.pattern.length-1]}}},F,class extends M{constructor(e){super(e)}static get type(){return"prefix-exact"}static get multiRegex(){return/^\^"(.*)"$/}static get singleRegex(){return/^\^(.*)$/}search(e){const t=e.startsWith(this.pattern);return{isMatch:t,score:t?0:1,indices:[0,this.pattern.length-1]}}},class extends M{constructor(e){super(e)}static get type(){return"inverse-prefix-exact"}static get multiRegex(){return/^!\^"(.*)"$/}static get singleRegex(){return/^!\^(.*)$/}search(e){const t=!e.startsWith(this.pattern);return{isMatch:t,score:t?0:1,indices:[0,e.length-1]}}},class extends M{constructor(e){super(e)}static get type(){return"inverse-suffix-exact"}static get multiRegex(){return/^!"(.*)"\$$/}static get singleRegex(){return/^!(.*)\$$/}search(e){const t=!e.endsWith(this.pattern);return{isMatch:t,score:t?0:1,indices:[0,e.length-1]}}},class extends M{constructor(e){super(e)}static get type(){return"suffix-exact"}static get multiRegex(){return/^"(.*)"\$$/}static get singleRegex(){return/^(.*)\$$/}search(e){const t=e.endsWith(this.pattern);return{isMatch:t,score:t?0:1,indices:[e.length-this.pattern.length,e.length-1]}}},class extends M{constructor(e){super(e)}static get type(){return"inverse-exact"}static get multiRegex(){return/^!"(.*)"$/}static get singleRegex(){return/^!(.*)$/}search(e){const t=-1===e.indexOf(this.pattern);return{isMatch:t,score:t?0:1,indices:[0,e.length-1]}}},I],N=R.length,L=/ +(?=(?:[^\"]*\"[^\"]*\")*[^\"]*$)/;const O=new Set([I.type,F.type]);class B{constructor(e){let{isCaseSensitive:t=w.isCaseSensitive,ignoreDiacritics:n=w.ignoreDiacritics,includeMatches:r=w.includeMatches,minMatchCharLength:i=w.minMatchCharLength,ignoreLocation:s=w.ignoreLocation,findAllMatches:a=w.findAllMatches,location:o=w.location,threshold:l=w.threshold,distance:c=w.distance}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.query=null,this.options={isCaseSensitive:t,ignoreDiacritics:n,includeMatches:r,minMatchCharLength:i,findAllMatches:a,ignoreLocation:s,location:o,threshold:l,distance:c},e=t?e:e.toLowerCase(),e=n?T(e):e,this.pattern=e,this.query=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e.split("|").map(e=>{let n=e.trim().split(L).filter(e=>e&&!!e.trim()),r=[];for(let i=0,s=n.length;i<s;i+=1){const e=n[i];let s=!1,a=-1;for(;!s&&++a<N;){const n=R[a];let i=n.isMultiMatch(e);i&&(r.push(new n(i,t)),s=!0)}if(!s)for(a=-1;++a<N;){const n=R[a];let i=n.isSingleMatch(e);if(i){r.push(new n(i,t));break}}}return r})}(this.pattern,this.options)}static condition(e,t){return t.useExtendedSearch}searchIn(e){const t=this.query;if(!t)return{isMatch:!1,score:1};const{includeMatches:n,isCaseSensitive:r,ignoreDiacritics:i}=this.options;e=r?e:e.toLowerCase(),e=i?T(e):e;let s=0,a=[],o=0;for(let l=0,c=t.length;l<c;l+=1){const r=t[l];a.length=0,s=0;for(let t=0,i=r.length;t<i;t+=1){const i=r[t],{isMatch:l,indices:c,score:h}=i.search(e);if(!l){o=0,s=0,a.length=0;break}if(s+=1,o+=h,n){const e=i.constructor.type;O.has(e)?a=[...a,...c]:a.push(c)}}if(s){let e={isMatch:!0,score:o/s};return n&&(e.indices=a),e}}return{isMatch:!1,score:1}}}const $=[];function z(e,t){for(let n=0,r=$.length;n<r;n+=1){let r=$[n];if(r.condition(e,t))return new r(e,t)}return new D(e,t)}const j="$and",U="$or",H="$path",V="$val",q=e=>!(!e[j]&&!e[U]),W=e=>({[j]:Object.keys(e).map(t=>({[t]:e[t]}))});function G(e,t){let{auto:n=!0}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const r=e=>{let i=Object.keys(e);const s=(e=>!!e[H])(e);if(!s&&i.length>1&&!q(e))return r(W(e));if((e=>!o(e)&&d(e)&&!q(e))(e)){const r=s?e[H]:i[0],a=s?e[V]:e[r];if(!l(a))throw new Error((e=>`Invalid value for key ${e}`)(r));const o={keyId:b(r),pattern:a};return n&&(o.searcher=z(a,t)),o}let a={children:[],operator:i[0]};return i.forEach(t=>{const n=e[t];o(n)&&n.forEach(e=>{a.children.push(r(e))})}),a};return q(e)||(e=W(e)),r(e)}function K(e,t){const n=e.matches;t.matches=[],u(n)&&n.forEach(e=>{if(!u(e.indices)||!e.indices.length)return;const{indices:n,value:r}=e;let i={indices:n,value:r};e.key&&(i.key=e.key.src),e.idx>-1&&(i.refIndex=e.idx),t.matches.push(i)})}function X(e,t){t.score=e.score}class Y{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;this.options={...w,...t},this.options.useExtendedSearch,this._keyStore=new g(this.options.keys),this.setCollection(e,n)}setCollection(e,t){if(this._docs=e,t&&!(t instanceof A))throw new Error("Incorrect 'index' type");this._myIndex=t||x(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight})}add(e){u(e)&&(this._docs.push(e),this._myIndex.add(e))}remove(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:()=>!1;const t=[];for(let n=0,r=this._docs.length;n<r;n+=1){const i=this._docs[n];e(i,n)&&(this.removeAt(n),n-=1,r-=1,t.push(i))}return t}removeAt(e){this._docs.splice(e,1),this._myIndex.removeAt(e)}getIndex(){return this._myIndex}search(e){let{limit:t=-1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{includeMatches:n,includeScore:r,shouldSort:i,sortFn:s,ignoreFieldNorm:a}=this.options;let o=l(e)?l(this._docs[0])?this._searchStringList(e):this._searchObjectList(e):this._searchLogical(e);return function(e,t){let{ignoreFieldNorm:n=w.ignoreFieldNorm}=t;e.forEach(e=>{let t=1;e.matches.forEach(e=>{let{key:r,norm:i,score:s}=e;const a=r?r.weight:null;t*=Math.pow(0===s&&a?Number.EPSILON:s,(a||1)*(n?1:i))}),e.score=t})}(o,{ignoreFieldNorm:a}),i&&o.sort(s),c(t)&&t>-1&&(o=o.slice(0,t)),function(e,t){let{includeMatches:n=w.includeMatches,includeScore:r=w.includeScore}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const i=[];return n&&i.push(K),r&&i.push(X),e.map(e=>{const{idx:n}=e,r={item:t[n],refIndex:n};return i.length&&i.forEach(t=>{t(e,r)}),r})}(o,this._docs,{includeMatches:n,includeScore:r})}_searchStringList(e){const t=z(e,this.options),{records:n}=this._myIndex,r=[];return n.forEach(e=>{let{v:n,i:i,n:s}=e;if(!u(n))return;const{isMatch:a,score:o,indices:l}=t.searchIn(n);a&&r.push({item:n,idx:i,matches:[{score:o,value:n,norm:s,indices:l}]})}),r}_searchLogical(e){const t=G(e,this.options),n=(e,t,r)=>{if(!e.children){const{keyId:n,searcher:i}=e,s=this._findMatches({key:this._keyStore.get(n),value:this._myIndex.getValueForItemAtKeyId(t,n),searcher:i});return s&&s.length?[{idx:r,item:t,matches:s}]:[]}const i=[];for(let s=0,a=e.children.length;s<a;s+=1){const a=e.children[s],o=n(a,t,r);if(o.length)i.push(...o);else if(e.operator===j)return[]}return i},r=this._myIndex.records,i={},s=[];return r.forEach(e=>{let{$:r,i:a}=e;if(u(r)){let e=n(t,r,a);e.length&&(i[a]||(i[a]={idx:a,item:r,matches:[]},s.push(i[a])),e.forEach(e=>{let{matches:t}=e;i[a].matches.push(...t)}))}}),s}_searchObjectList(e){const t=z(e,this.options),{keys:n,records:r}=this._myIndex,i=[];return r.forEach(e=>{let{$:r,i:s}=e;if(!u(r))return;let a=[];n.forEach((e,n)=>{a.push(...this._findMatches({key:e,value:r[n],searcher:t}))}),a.length&&i.push({idx:s,item:r,matches:a})}),i}_findMatches(e){let{key:t,value:n,searcher:r}=e;if(!u(n))return[];let i=[];if(o(n))n.forEach(e=>{let{v:n,i:s,n:a}=e;if(!u(n))return;const{isMatch:o,score:l,indices:c}=r.searchIn(n);o&&i.push({score:l,key:t,value:n,idx:s,norm:a,indices:c})});else{const{v:e,n:s}=n,{isMatch:a,score:o,indices:l}=r.searchIn(e);a&&i.push({score:o,key:t,value:e,norm:s,indices:l})}return i}}Y.version="7.1.0",Y.createIndex=x,Y.parseIndex=function(e){let{getFn:t=w.getFn,fieldNormWeight:n=w.fieldNormWeight}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{keys:r,records:i}=e,s=new A({getFn:t,fieldNormWeight:n});return s.setKeys(r),s.setIndexRecords(i),s},Y.config=w,Y.parseQuery=G,function(){$.push(...arguments)}(B);var Z,J,Q=n(89261);function ee(){return ee=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ee.apply(null,arguments)}function te(e,t){let{title:n,titleId:r,...s}=e;return i.createElement("svg",ee({width:16,height:16,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round",ref:t,"aria-labelledby":r},s),n?i.createElement("title",{id:r},n):null,Z||(Z=i.createElement("rect",{x:9,y:9,width:13,height:13,rx:2,ry:2})),J||(J=i.createElement("path",{d:"M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"})))}const ne=i.forwardRef(te);n.p;var re;function ie(){return ie=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ie.apply(null,arguments)}function se(e,t){let{title:n,titleId:r,...s}=e;return i.createElement("svg",ie({width:16,height:16,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round",ref:t,"aria-labelledby":r},s),n?i.createElement("title",{id:r},n):null,re||(re=i.createElement("polyline",{points:"20 6 9 17 4 12"})))}const ae=i.forwardRef(se);n.p;var oe,le,ce,he;function de(){return de=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},de.apply(null,arguments)}function ue(e,t){let{title:n,titleId:r,...s}=e;return i.createElement("svg",de({width:16,height:16,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round",ref:t,"aria-labelledby":r},s),n?i.createElement("title",{id:r},n):null,oe||(oe=i.createElement("polyline",{points:"15 3 21 3 21 9"})),le||(le=i.createElement("polyline",{points:"9 21 3 21 3 15"})),ce||(ce=i.createElement("line",{x1:21,y1:3,x2:14,y2:10})),he||(he=i.createElement("line",{x1:3,y1:21,x2:10,y2:14})))}const pe=i.forwardRef(ue);n.p;var fe,me,ge,ve;function ye(){return ye=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ye.apply(null,arguments)}function be(e,t){let{title:n,titleId:r,...s}=e;return i.createElement("svg",ye({width:16,height:16,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round",ref:t,"aria-labelledby":r},s),n?i.createElement("title",{id:r},n):null,fe||(fe=i.createElement("polyline",{points:"4 14 10 14 10 20"})),me||(me=i.createElement("polyline",{points:"20 10 14 10 14 4"})),ge||(ge=i.createElement("line",{x1:14,y1:10,x2:21,y2:3})),ve||(ve=i.createElement("line",{x1:3,y1:21,x2:10,y2:14})))}const we=i.forwardRef(be),_e=(n.p,(0,r.createWithIntlProvider)({defaultLocale:"zh-CN",messages:{"zh-CN":{"JsonView.label":"JSON \u67e5\u770b\u5668","JsonView.searchPlaceholder":"\u641c\u7d22...","JsonView.expand":"\u5c55\u5f00","JsonView.collapse":"\u6536\u8d77","JsonView.expandAll":"\u5c55\u5f00\u5168\u90e8","JsonView.collapseAll":"\u6536\u8d77\u5168\u90e8","JsonView.items":"\u9879","JsonView.keys":"\u4e2a\u952e","JsonView.copy":"\u590d\u5236","JsonView.copied":"\u5df2\u590d\u5236"},"en-US":{"JsonView.label":"JSON Viewer","JsonView.searchPlaceholder":"Search...","JsonView.expand":"Expand","JsonView.collapse":"Collapse","JsonView.expandAll":"Expand All","JsonView.collapseAll":"Collapse All","JsonView.items":"items","JsonView.keys":"keys","JsonView.copy":"Copy","JsonView.copied":"Copied"}},namespace:"json-view"})),Ae=e=>null===e?"null":Array.isArray(e)?"array":typeof e,xe=e=>{const t=Ae(e);if("array"!==t&&"object"!==t)return 1;if("array"===t)return 0===e.length?1:1+e.reduce((e,t)=>e+xe(t),0)+1;if("object"===t){const t=Object.keys(e);return 0===t.length?1:1+t.reduce((t,n)=>t+xe(e[n]),0)+1}return 1},Ee=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:["root"],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;const i=new Set,s=Ae(e);return"array"!==s&&"object"!==s||(r>=t&&i.add(n.join(".")),"array"===s?e.forEach((e,s)=>{Ee(e,t,[...n,s],r+1).forEach(e=>i.add(e))}):"object"===s&&Object.entries(e).forEach(e=>{let[s,a]=e;Ee(a,t,[...n,s],r+1).forEach(e=>i.add(e))})),i},Ce=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["root"];const n=[],r=Ae(e),i=t.join(".");return n.push({path:i,value:e,type:r}),"array"===r?e.forEach((e,r)=>{n.push(...Ce(e,[...t,r]))}):"object"===r&&null!==e&&Object.entries(e).forEach(e=>{let[r,i]=e;n.push(...Ce(i,[...t,r]))}),n},ke=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["root"];const n=new Set,r=Ae(e);return"array"!==r&&"object"!==r||"array"===r&&0===e.length||"object"===r&&0===Object.keys(e).length||(n.add(t.join(".")),"array"===r?e.forEach((e,r)=>{ke(e,[...t,r]).forEach(e=>n.add(e))}):Object.entries(e).forEach(e=>{let[r,i]=e;ke(i,[...t,r]).forEach(e=>n.add(e))})),n};var Se={wrapper:"_Gah47",toolbar:"_oesko","toolbar-right":"_QwxDF","search-wrapper":"_qC3rr","search-input":"_zHTh7","clear-btn":"_dc0JP","action-btn":"_mLgqh","button-group":"_pC1Lu",container:"_AIhaC","show-line-numbers":"_U5LlB",line:"_60jp6","close-line":"_Ilatn",highlight:"_zuXAP",matched:"_QVax6","theme-light":"_zDNAx",toggle:"_Tnz1N",arrow:"_Ktfhg",bracket:"_Z-pL9",preview:"_tIMOh",content:"_XZmmG",key:"_7jiBE",colon:"_KtY8d",comma:"_A0uZ4",string:"_gs9ka",number:"_EiXo7",boolean:"_ku2F-",null:"_nRonT","open-line":"_F5rST","theme-dark":"_Vozlg",collapsible:"_3UbHF",expanded:"_4RR-f"};const Te=e=>{let{text:t,highlight:n}=e;if(!n)return(0,Q.jsx)(Q.Fragment,{children:t});const r=new RegExp(`(${n.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")})`,"gi"),i=t.split(r);return(0,Q.jsx)(Q.Fragment,{children:i.map((e,t)=>r.test(e)?(0,Q.jsx)("span",{className:Se.highlight,children:e},t):(0,Q.jsx)("span",{children:e},t))})},De=e=>{let{data:t,path:n,onToggle:s,collapsedKeys:o,highlight:l,matchedPaths:c,indentWidth:h,showComma:d}=e;const{formatMessage:u}=(0,r.useIntl)(),p=Ae(t),f=n.join("."),m=o.has(f),g=c.has(f),v=(0,i.useCallback)(()=>{s(f)},[f,s]);if("null"===p)return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)("span",{className:a()(Se.null,{[Se.matched]:g}),children:"null"}),d&&(0,Q.jsx)("span",{className:Se.comma,children:","})]});if("undefined"===p)return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)("span",{className:a()(Se.null,{[Se.matched]:g}),children:"undefined"}),d&&(0,Q.jsx)("span",{className:Se.comma,children:","})]});if("boolean"===p)return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)("span",{className:a()(Se.boolean,{[Se.matched]:g}),children:(0,Q.jsx)(Te,{text:t?"true":"false",highlight:l})}),d&&(0,Q.jsx)("span",{className:Se.comma,children:","})]});if("number"===p)return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)("span",{className:a()(Se.number,{[Se.matched]:g}),children:(0,Q.jsx)(Te,{text:String(t),highlight:l})}),d&&(0,Q.jsx)("span",{className:Se.comma,children:","})]});if("string"===p)return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsxs)("span",{className:a()(Se.string,{[Se.matched]:g}),children:['"',(0,Q.jsx)(Te,{text:t,highlight:l}),'"']}),d&&(0,Q.jsx)("span",{className:Se.comma,children:","})]});if("array"===p||"object"===p){const e="array"===p?t.map((e,t)=>[t,e]):Object.entries(t),r=0===e.length,i="array"===p?"[":"{",f="array"===p?"]":"}";return r?(0,Q.jsxs)("span",{className:Se.bracket,children:[i,f]}):(0,Q.jsxs)("span",{className:Se.collapsible,children:[(0,Q.jsx)("span",{className:Se["open-line"],children:(0,Q.jsxs)("span",{className:Se.toggle,onClick:v,children:[(0,Q.jsx)("span",{className:a()(Se.arrow,{[Se.expanded]:!m}),children:"\u25b6"}),(0,Q.jsx)("span",{className:Se.bracket,children:i})]})}),m&&(0,Q.jsxs)("span",{className:Se.preview,children:["...",e.length," ",u({id:"JsonView."+("array"===p?"items":"keys")})]}),m&&(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)("span",{className:Se.bracket,children:f}),d&&(0,Q.jsx)("span",{className:Se.comma,children:","})]}),!m&&(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)("span",{className:Se.content,style:{paddingLeft:`${h}px`},children:e.map((t,r)=>{let[i,a]=t;const d=[...n,i],u=Ae(a),f=d.join("."),m=o.has(f),g="array"===u||"object"===u?xe(a):1,v=m&&g>1;return(0,Q.jsxs)("div",{className:Se.line,style:v?{"--line-count":g}:void 0,children:[(0,Q.jsx)("span",{className:Se.key,children:"object"===p?`"${i}"`:i}),(0,Q.jsx)("span",{className:Se.colon,children:":"}),(0,Q.jsx)(De,{data:a,path:d,onToggle:s,collapsedKeys:o,highlight:l,matchedPaths:c,indentWidth:h,showComma:r<e.length-1})]},i)})}),(0,Q.jsxs)("span",{className:Se["close-line"],children:[(0,Q.jsx)("span",{className:Se.bracket,children:f}),d&&(0,Q.jsx)("span",{className:Se.comma,children:","})]})]})]})}return(0,Q.jsx)("span",{children:String(t)})},Me=e=>{let{searchQuery:t,onSearchChange:n,onToggleExpand:s,isAllExpanded:o,theme:l,searchable:c,collapsable:h,data:d}=e;const{formatMessage:u}=(0,r.useIntl)(),[p,f]=(0,i.useState)(!1);return(0,Q.jsxs)("div",{className:a()(Se.toolbar,Se[`theme-${l}`],{[Se["toolbar-right"]]:!c&&h}),children:[c&&(0,Q.jsxs)("div",{className:Se["search-wrapper"],children:[(0,Q.jsx)("input",{type:"text",value:t,onChange:e=>n(e.target.value),placeholder:u({id:"JsonView.searchPlaceholder"}),className:Se["search-input"]}),t&&(0,Q.jsx)("button",{className:Se["clear-btn"],onClick:()=>n(""),children:"\xd7"})]}),(0,Q.jsxs)("div",{className:Se["button-group"],children:[(0,Q.jsx)("button",{className:Se["action-btn"],onClick:async()=>{try{const e=JSON.stringify(d,null,2);await navigator.clipboard.writeText(e),f(!0),setTimeout(()=>f(!1),2e3)}catch(e){console.error("Failed to copy:",e)}},title:u({id:p?"JsonView.copied":"JsonView.copy"}),children:p?(0,Q.jsx)(ae,{}):(0,Q.jsx)(ne,{})}),h&&(0,Q.jsx)("button",{className:Se["action-btn"],onClick:s,title:u({id:o?"JsonView.collapseAll":"JsonView.expandAll"}),children:o?(0,Q.jsx)(we,{}):(0,Q.jsx)(pe,{})})]})]})},Pe=_e(e=>{let{data:t,collapsedFrom:n=1/0,theme:r="dark",searchable:s=!0,collapsable:o=!0,indentWidth:l=20,showLineNumbers:c=!0,className:h}=e;const[d,u]=(0,i.useState)(""),p=(0,i.useMemo)(()=>void 0===t||n===1/0?new Set:Ee(t,n),[t,n]),[f,m]=(0,i.useState)(p),g=(0,i.useMemo)(()=>void 0===t?new Set:ke(t),[t]),v=(0,i.useMemo)(()=>void 0===t?[]:Ce(t),[t]),y=(0,i.useMemo)(()=>new Y(v,{keys:["value"],includeMatches:!0,threshold:.3,ignoreLocation:!0,minMatchCharLength:1}),[v]),b=(0,i.useMemo)(()=>((e,t)=>{if(!t||!e)return new Set;const n=e.search(t),r=new Set;return n.forEach(e=>{const t=e.item.path;r.add(t);const n=t.split(".");for(let i=1;i<n.length;i++)r.add(n.slice(0,i).join("."))}),r})(y,d),[y,d]);(0,i.useEffect)(()=>{d&&b.size>0&&m(e=>{const t=new Set(e);return b.forEach(e=>{t.has(e)&&t.delete(e)}),t})},[d,b]);const w=(0,i.useCallback)(e=>{m(t=>{const n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})},[]),_=(0,i.useCallback)(()=>{m(new Set)},[]),A=(0,i.useCallback)(()=>{m(new Set(g))},[g]),x=0===f.size,E=(0,i.useMemo)(()=>void 0===t?1:xe(t),[t]),C=(0,i.useMemo)(()=>{const e=Ae(t);return"array"!==e&&"object"!==e?1:f.has("root")?E:1},[t,f,E]),k=(0,i.useMemo)(()=>{const e=String(E).length;return Math.max(32,Math.ceil(7.5*e+12))},[E]),S=(0,i.useCallback)(()=>{x?A():_()},[x,_,A]);return void 0===t?(0,Q.jsx)("div",{className:a()(Se.container,Se[`theme-${r}`],h),children:(0,Q.jsx)("span",{className:Se.null,children:"undefined"})}):(0,Q.jsxs)("div",{className:a()(Se.wrapper,Se[`theme-${r}`],h),children:[(s||o)&&(0,Q.jsx)(Me,{searchQuery:d,onSearchChange:u,onToggleExpand:S,isAllExpanded:x,theme:r,searchable:s,collapsable:o,data:t}),(0,Q.jsx)("div",{className:a()(Se.container,{[Se["show-line-numbers"]]:c}),style:c?{"--line-number-width":`${k}px`}:void 0,children:(0,Q.jsx)("div",{className:Se.line,style:C>1?{"--line-count":C}:void 0,children:(0,Q.jsx)(De,{data:t,path:["root"],onToggle:w,collapsedKeys:f,highlight:d,matchedPaths:b,indentWidth:l})})})]})})},62064(e,t,n){"use strict";n.d(t,{Ay:()=>$i});var r={};n.r(r),n.d(r,{decode:()=>h,encode:()=>p,format:()=>f,parse:()=>S});var i={};n.r(i),n.d(i,{Any:()=>M,Cc:()=>P,Cf:()=>I,P:()=>T,S:()=>D,Z:()=>F});var s={};n.r(s),n.d(s,{arrayReplaceAt:()=>oe,assign:()=>ae,escapeHtml:()=>be,escapeRE:()=>_e,fromCodePoint:()=>ce,has:()=>se,isMdAsciiPunct:()=>Ce,isPunctChar:()=>Ee,isSpace:()=>Ae,isString:()=>re,isValidEntityCode:()=>le,isWhiteSpace:()=>xe,lib:()=>Se,normalizeReference:()=>ke,unescapeAll:()=>fe,unescapeMd:()=>pe});var a={};n.r(a),n.d(a,{parseLinkDestination:()=>De,parseLinkLabel:()=>Te,parseLinkTitle:()=>Me});var o=n(94922);const l={};function c(e,t){"string"!==typeof t&&(t=c.defaultChars);const n=function(e){let t=l[e];if(t)return t;t=l[e]=[];for(let n=0;n<128;n++){const e=String.fromCharCode(n);t.push(e)}for(let n=0;n<e.length;n++){const r=e.charCodeAt(n);t[r]="%"+("0"+r.toString(16).toUpperCase()).slice(-2)}return t}(t);return e.replace(/(%[a-f0-9]{2})+/gi,function(e){let t="";for(let r=0,i=e.length;r<i;r+=3){const s=parseInt(e.slice(r+1,r+3),16);if(s<128)t+=n[s];else{if(192===(224&s)&&r+3<i){const n=parseInt(e.slice(r+4,r+6),16);if(128===(192&n)){const e=s<<6&1984|63&n;t+=e<128?"\ufffd\ufffd":String.fromCharCode(e),r+=3;continue}}if(224===(240&s)&&r+6<i){const n=parseInt(e.slice(r+4,r+6),16),i=parseInt(e.slice(r+7,r+9),16);if(128===(192&n)&&128===(192&i)){const e=s<<12&61440|n<<6&4032|63&i;t+=e<2048||e>=55296&&e<=57343?"\ufffd\ufffd\ufffd":String.fromCharCode(e),r+=6;continue}}if(240===(248&s)&&r+9<i){const n=parseInt(e.slice(r+4,r+6),16),i=parseInt(e.slice(r+7,r+9),16),a=parseInt(e.slice(r+10,r+12),16);if(128===(192&n)&&128===(192&i)&&128===(192&a)){let e=s<<18&1835008|n<<12&258048|i<<6&4032|63&a;e<65536||e>1114111?t+="\ufffd\ufffd\ufffd\ufffd":(e-=65536,t+=String.fromCharCode(55296+(e>>10),56320+(1023&e))),r+=9;continue}}t+="\ufffd"}}return t})}c.defaultChars=";/?:@&=+$,#",c.componentChars="";const h=c,d={};function u(e,t,n){"string"!==typeof t&&(n=t,t=u.defaultChars),"undefined"===typeof n&&(n=!0);const r=function(e){let t=d[e];if(t)return t;t=d[e]=[];for(let n=0;n<128;n++){const e=String.fromCharCode(n);/^[0-9a-z]$/i.test(e)?t.push(e):t.push("%"+("0"+n.toString(16).toUpperCase()).slice(-2))}for(let n=0;n<e.length;n++)t[e.charCodeAt(n)]=e[n];return t}(t);let i="";for(let s=0,a=e.length;s<a;s++){const t=e.charCodeAt(s);if(n&&37===t&&s+2<a&&/^[0-9a-f]{2}$/i.test(e.slice(s+1,s+3)))i+=e.slice(s,s+3),s+=2;else if(t<128)i+=r[t];else if(t>=55296&&t<=57343){if(t>=55296&&t<=56319&&s+1<a){const t=e.charCodeAt(s+1);if(t>=56320&&t<=57343){i+=encodeURIComponent(e[s]+e[s+1]),s++;continue}}i+="%EF%BF%BD"}else i+=encodeURIComponent(e[s])}return i}u.defaultChars=";/?:@&=+$,-_.!~*'()#",u.componentChars="-_.!~*'()";const p=u;function f(e){let t="";return t+=e.protocol||"",t+=e.slashes?"//":"",t+=e.auth?e.auth+"@":"",e.hostname&&-1!==e.hostname.indexOf(":")?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||"",t}function m(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}const g=/^([a-z0-9.+-]+:)/i,v=/:[0-9]*$/,y=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,b=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),w=["'"].concat(b),_=["%","/","?",";","#"].concat(w),A=["/","?","#"],x=/^[+a-z0-9A-Z_-]{0,63}$/,E=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,C={javascript:!0,"javascript:":!0},k={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};m.prototype.parse=function(e,t){let n,r,i,s=e;if(s=s.trim(),!t&&1===e.split("#").length){const e=y.exec(s);if(e)return this.pathname=e[1],e[2]&&(this.search=e[2]),this}let a=g.exec(s);if(a&&(a=a[0],n=a.toLowerCase(),this.protocol=a,s=s.substr(a.length)),(t||a||s.match(/^\/\/[^@\/]+@[^@\/]+/))&&(i="//"===s.substr(0,2),!i||a&&C[a]||(s=s.substr(2),this.slashes=!0)),!C[a]&&(i||a&&!k[a])){let e,t,n=-1;for(let o=0;o<A.length;o++)r=s.indexOf(A[o]),-1!==r&&(-1===n||r<n)&&(n=r);t=-1===n?s.lastIndexOf("@"):s.lastIndexOf("@",n),-1!==t&&(e=s.slice(0,t),s=s.slice(t+1),this.auth=e),n=-1;for(let o=0;o<_.length;o++)r=s.indexOf(_[o]),-1!==r&&(-1===n||r<n)&&(n=r);-1===n&&(n=s.length),":"===s[n-1]&&n--;const i=s.slice(0,n);s=s.slice(n),this.parseHost(i),this.hostname=this.hostname||"";const a="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!a){const e=this.hostname.split(/\./);for(let t=0,n=e.length;t<n;t++){const n=e[t];if(n&&!n.match(x)){let r="";for(let e=0,t=n.length;e<t;e++)n.charCodeAt(e)>127?r+="x":r+=n[e];if(!r.match(x)){const r=e.slice(0,t),i=e.slice(t+1),a=n.match(E);a&&(r.push(a[1]),i.unshift(a[2])),i.length&&(s=i.join(".")+s),this.hostname=r.join(".");break}}}}this.hostname.length>255&&(this.hostname=""),a&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}const o=s.indexOf("#");-1!==o&&(this.hash=s.substr(o),s=s.slice(0,o));const l=s.indexOf("?");return-1!==l&&(this.search=s.substr(l),s=s.slice(0,l)),s&&(this.pathname=s),k[n]&&this.hostname&&!this.pathname&&(this.pathname=""),this},m.prototype.parseHost=function(e){let t=v.exec(e);t&&(t=t[0],":"!==t&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)};const S=function(e,t){if(e&&e instanceof m)return e;const n=new m;return n.parse(e,t),n},T=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDEAD\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/,D=/[\$\+<->\^`\|~\xA2-\xA6\xA8\xA9\xAC\xAE-\xB1\xB4\xB8\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0384\u0385\u03F6\u0482\u058D-\u058F\u0606-\u0608\u060B\u060E\u060F\u06DE\u06E9\u06FD\u06FE\u07F6\u07FE\u07FF\u0888\u09F2\u09F3\u09FA\u09FB\u0AF1\u0B70\u0BF3-\u0BFA\u0C7F\u0D4F\u0D79\u0E3F\u0F01-\u0F03\u0F13\u0F15-\u0F17\u0F1A-\u0F1F\u0F34\u0F36\u0F38\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE\u0FCF\u0FD5-\u0FD8\u109E\u109F\u1390-\u1399\u166D\u17DB\u1940\u19DE-\u19FF\u1B61-\u1B6A\u1B74-\u1B7C\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2044\u2052\u207A-\u207C\u208A-\u208C\u20A0-\u20C0\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F\u218A\u218B\u2190-\u2307\u230C-\u2328\u232B-\u2426\u2440-\u244A\u249C-\u24E9\u2500-\u2767\u2794-\u27C4\u27C7-\u27E5\u27F0-\u2982\u2999-\u29D7\u29DC-\u29FB\u29FE-\u2B73\u2B76-\u2B95\u2B97-\u2BFF\u2CE5-\u2CEA\u2E50\u2E51\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3004\u3012\u3013\u3020\u3036\u3037\u303E\u303F\u309B\u309C\u3190\u3191\u3196-\u319F\u31C0-\u31E3\u31EF\u3200-\u321E\u322A-\u3247\u3250\u3260-\u327F\u328A-\u32B0\u32C0-\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA700-\uA716\uA720\uA721\uA789\uA78A\uA828-\uA82B\uA836-\uA839\uAA77-\uAA79\uAB5B\uAB6A\uAB6B\uFB29\uFBB2-\uFBC2\uFD40-\uFD4F\uFDCF\uFDFC-\uFDFF\uFE62\uFE64-\uFE66\uFE69\uFF04\uFF0B\uFF1C-\uFF1E\uFF3E\uFF40\uFF5C\uFF5E\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFFC\uFFFD]|\uD800[\uDD37-\uDD3F\uDD79-\uDD89\uDD8C-\uDD8E\uDD90-\uDD9C\uDDA0\uDDD0-\uDDFC]|\uD802[\uDC77\uDC78\uDEC8]|\uD805\uDF3F|\uD807[\uDFD5-\uDFF1]|\uD81A[\uDF3C-\uDF3F\uDF45]|\uD82F\uDC9C|\uD833[\uDF50-\uDFC3]|\uD834[\uDC00-\uDCF5\uDD00-\uDD26\uDD29-\uDD64\uDD6A-\uDD6C\uDD83\uDD84\uDD8C-\uDDA9\uDDAE-\uDDEA\uDE00-\uDE41\uDE45\uDF00-\uDF56]|\uD835[\uDEC1\uDEDB\uDEFB\uDF15\uDF35\uDF4F\uDF6F\uDF89\uDFA9\uDFC3]|\uD836[\uDC00-\uDDFF\uDE37-\uDE3A\uDE6D-\uDE74\uDE76-\uDE83\uDE85\uDE86]|\uD838[\uDD4F\uDEFF]|\uD83B[\uDCAC\uDCB0\uDD2E\uDEF0\uDEF1]|\uD83C[\uDC00-\uDC2B\uDC30-\uDC93\uDCA0-\uDCAE\uDCB1-\uDCBF\uDCC1-\uDCCF\uDCD1-\uDCF5\uDD0D-\uDDAD\uDDE6-\uDE02\uDE10-\uDE3B\uDE40-\uDE48\uDE50\uDE51\uDE60-\uDE65\uDF00-\uDFFF]|\uD83D[\uDC00-\uDED7\uDEDC-\uDEEC\uDEF0-\uDEFC\uDF00-\uDF76\uDF7B-\uDFD9\uDFE0-\uDFEB\uDFF0]|\uD83E[\uDC00-\uDC0B\uDC10-\uDC47\uDC50-\uDC59\uDC60-\uDC87\uDC90-\uDCAD\uDCB0\uDCB1\uDD00-\uDE53\uDE60-\uDE6D\uDE70-\uDE7C\uDE80-\uDE88\uDE90-\uDEBD\uDEBF-\uDEC5\uDECE-\uDEDB\uDEE0-\uDEE8\uDEF0-\uDEF8\uDF00-\uDF92\uDF94-\uDFCA]/,M=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,P=/[\0-\x1F\x7F-\x9F]/,I=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/,F=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/,R=new Uint16Array('\u1d41<\xd5\u0131\u028a\u049d\u057b\u05d0\u0675\u06de\u07a2\u07d6\u080f\u0a4a\u0a91\u0da1\u0e6d\u0f09\u0f26\u10ca\u1228\u12e1\u1415\u149d\u14c3\u14df\u1525\0\0\0\0\0\0\u156b\u16cd\u198d\u1c12\u1ddd\u1f7e\u2060\u21b0\u228d\u23c0\u23fb\u2442\u2824\u2912\u2d08\u2e48\u2fce\u3016\u32ba\u3639\u37ac\u38fe\u3a28\u3a71\u3ae0\u3b2e\u0800EMabcfglmnoprstu\\bfms\x7f\x84\x8b\x90\x95\x98\xa6\xb3\xb9\xc8\xcflig\u803b\xc6\u40c6P\u803b&\u4026cute\u803b\xc1\u40c1reve;\u4102\u0100iyx}rc\u803b\xc2\u40c2;\u4410r;\uc000\ud835\udd04rave\u803b\xc0\u40c0pha;\u4391acr;\u4100d;\u6a53\u0100gp\x9d\xa1on;\u4104f;\uc000\ud835\udd38plyFunction;\u6061ing\u803b\xc5\u40c5\u0100cs\xbe\xc3r;\uc000\ud835\udc9cign;\u6254ilde\u803b\xc3\u40c3ml\u803b\xc4\u40c4\u0400aceforsu\xe5\xfb\xfe\u0117\u011c\u0122\u0127\u012a\u0100cr\xea\xf2kslash;\u6216\u0176\xf6\xf8;\u6ae7ed;\u6306y;\u4411\u0180crt\u0105\u010b\u0114ause;\u6235noullis;\u612ca;\u4392r;\uc000\ud835\udd05pf;\uc000\ud835\udd39eve;\u42d8c\xf2\u0113mpeq;\u624e\u0700HOacdefhilorsu\u014d\u0151\u0156\u0180\u019e\u01a2\u01b5\u01b7\u01ba\u01dc\u0215\u0273\u0278\u027ecy;\u4427PY\u803b\xa9\u40a9\u0180cpy\u015d\u0162\u017aute;\u4106\u0100;i\u0167\u0168\u62d2talDifferentialD;\u6145leys;\u612d\u0200aeio\u0189\u018e\u0194\u0198ron;\u410cdil\u803b\xc7\u40c7rc;\u4108nint;\u6230ot;\u410a\u0100dn\u01a7\u01adilla;\u40b8terDot;\u40b7\xf2\u017fi;\u43a7rcle\u0200DMPT\u01c7\u01cb\u01d1\u01d6ot;\u6299inus;\u6296lus;\u6295imes;\u6297o\u0100cs\u01e2\u01f8kwiseContourIntegral;\u6232eCurly\u0100DQ\u0203\u020foubleQuote;\u601duote;\u6019\u0200lnpu\u021e\u0228\u0247\u0255on\u0100;e\u0225\u0226\u6237;\u6a74\u0180git\u022f\u0236\u023aruent;\u6261nt;\u622fourIntegral;\u622e\u0100fr\u024c\u024e;\u6102oduct;\u6210nterClockwiseContourIntegral;\u6233oss;\u6a2fcr;\uc000\ud835\udc9ep\u0100;C\u0284\u0285\u62d3ap;\u624d\u0580DJSZacefios\u02a0\u02ac\u02b0\u02b4\u02b8\u02cb\u02d7\u02e1\u02e6\u0333\u048d\u0100;o\u0179\u02a5trahd;\u6911cy;\u4402cy;\u4405cy;\u440f\u0180grs\u02bf\u02c4\u02c7ger;\u6021r;\u61a1hv;\u6ae4\u0100ay\u02d0\u02d5ron;\u410e;\u4414l\u0100;t\u02dd\u02de\u6207a;\u4394r;\uc000\ud835\udd07\u0100af\u02eb\u0327\u0100cm\u02f0\u0322ritical\u0200ADGT\u0300\u0306\u0316\u031ccute;\u40b4o\u0174\u030b\u030d;\u42d9bleAcute;\u42ddrave;\u4060ilde;\u42dcond;\u62c4ferentialD;\u6146\u0470\u033d\0\0\0\u0342\u0354\0\u0405f;\uc000\ud835\udd3b\u0180;DE\u0348\u0349\u034d\u40a8ot;\u60dcqual;\u6250ble\u0300CDLRUV\u0363\u0372\u0382\u03cf\u03e2\u03f8ontourIntegra\xec\u0239o\u0274\u0379\0\0\u037b\xbb\u0349nArrow;\u61d3\u0100eo\u0387\u03a4ft\u0180ART\u0390\u0396\u03a1rrow;\u61d0ightArrow;\u61d4e\xe5\u02cang\u0100LR\u03ab\u03c4eft\u0100AR\u03b3\u03b9rrow;\u67f8ightArrow;\u67faightArrow;\u67f9ight\u0100AT\u03d8\u03derrow;\u61d2ee;\u62a8p\u0241\u03e9\0\0\u03efrrow;\u61d1ownArrow;\u61d5erticalBar;\u6225n\u0300ABLRTa\u0412\u042a\u0430\u045e\u047f\u037crrow\u0180;BU\u041d\u041e\u0422\u6193ar;\u6913pArrow;\u61f5reve;\u4311eft\u02d2\u043a\0\u0446\0\u0450ightVector;\u6950eeVector;\u695eector\u0100;B\u0459\u045a\u61bdar;\u6956ight\u01d4\u0467\0\u0471eeVector;\u695fector\u0100;B\u047a\u047b\u61c1ar;\u6957ee\u0100;A\u0486\u0487\u62a4rrow;\u61a7\u0100ct\u0492\u0497r;\uc000\ud835\udc9frok;\u4110\u0800NTacdfglmopqstux\u04bd\u04c0\u04c4\u04cb\u04de\u04e2\u04e7\u04ee\u04f5\u0521\u052f\u0536\u0552\u055d\u0560\u0565G;\u414aH\u803b\xd0\u40d0cute\u803b\xc9\u40c9\u0180aiy\u04d2\u04d7\u04dcron;\u411arc\u803b\xca\u40ca;\u442dot;\u4116r;\uc000\ud835\udd08rave\u803b\xc8\u40c8ement;\u6208\u0100ap\u04fa\u04fecr;\u4112ty\u0253\u0506\0\0\u0512mallSquare;\u65fberySmallSquare;\u65ab\u0100gp\u0526\u052aon;\u4118f;\uc000\ud835\udd3csilon;\u4395u\u0100ai\u053c\u0549l\u0100;T\u0542\u0543\u6a75ilde;\u6242librium;\u61cc\u0100ci\u0557\u055ar;\u6130m;\u6a73a;\u4397ml\u803b\xcb\u40cb\u0100ip\u056a\u056fsts;\u6203onentialE;\u6147\u0280cfios\u0585\u0588\u058d\u05b2\u05ccy;\u4424r;\uc000\ud835\udd09lled\u0253\u0597\0\0\u05a3mallSquare;\u65fcerySmallSquare;\u65aa\u0370\u05ba\0\u05bf\0\0\u05c4f;\uc000\ud835\udd3dAll;\u6200riertrf;\u6131c\xf2\u05cb\u0600JTabcdfgorst\u05e8\u05ec\u05ef\u05fa\u0600\u0612\u0616\u061b\u061d\u0623\u066c\u0672cy;\u4403\u803b>\u403emma\u0100;d\u05f7\u05f8\u4393;\u43dcreve;\u411e\u0180eiy\u0607\u060c\u0610dil;\u4122rc;\u411c;\u4413ot;\u4120r;\uc000\ud835\udd0a;\u62d9pf;\uc000\ud835\udd3eeater\u0300EFGLST\u0635\u0644\u064e\u0656\u065b\u0666qual\u0100;L\u063e\u063f\u6265ess;\u62dbullEqual;\u6267reater;\u6aa2ess;\u6277lantEqual;\u6a7eilde;\u6273cr;\uc000\ud835\udca2;\u626b\u0400Aacfiosu\u0685\u068b\u0696\u069b\u069e\u06aa\u06be\u06caRDcy;\u442a\u0100ct\u0690\u0694ek;\u42c7;\u405eirc;\u4124r;\u610clbertSpace;\u610b\u01f0\u06af\0\u06b2f;\u610dizontalLine;\u6500\u0100ct\u06c3\u06c5\xf2\u06a9rok;\u4126mp\u0144\u06d0\u06d8ownHum\xf0\u012fqual;\u624f\u0700EJOacdfgmnostu\u06fa\u06fe\u0703\u0707\u070e\u071a\u071e\u0721\u0728\u0744\u0778\u078b\u078f\u0795cy;\u4415lig;\u4132cy;\u4401cute\u803b\xcd\u40cd\u0100iy\u0713\u0718rc\u803b\xce\u40ce;\u4418ot;\u4130r;\u6111rave\u803b\xcc\u40cc\u0180;ap\u0720\u072f\u073f\u0100cg\u0734\u0737r;\u412ainaryI;\u6148lie\xf3\u03dd\u01f4\u0749\0\u0762\u0100;e\u074d\u074e\u622c\u0100gr\u0753\u0758ral;\u622bsection;\u62c2isible\u0100CT\u076c\u0772omma;\u6063imes;\u6062\u0180gpt\u077f\u0783\u0788on;\u412ef;\uc000\ud835\udd40a;\u4399cr;\u6110ilde;\u4128\u01eb\u079a\0\u079ecy;\u4406l\u803b\xcf\u40cf\u0280cfosu\u07ac\u07b7\u07bc\u07c2\u07d0\u0100iy\u07b1\u07b5rc;\u4134;\u4419r;\uc000\ud835\udd0dpf;\uc000\ud835\udd41\u01e3\u07c7\0\u07ccr;\uc000\ud835\udca5rcy;\u4408kcy;\u4404\u0380HJacfos\u07e4\u07e8\u07ec\u07f1\u07fd\u0802\u0808cy;\u4425cy;\u440cppa;\u439a\u0100ey\u07f6\u07fbdil;\u4136;\u441ar;\uc000\ud835\udd0epf;\uc000\ud835\udd42cr;\uc000\ud835\udca6\u0580JTaceflmost\u0825\u0829\u082c\u0850\u0863\u09b3\u09b8\u09c7\u09cd\u0a37\u0a47cy;\u4409\u803b<\u403c\u0280cmnpr\u0837\u083c\u0841\u0844\u084dute;\u4139bda;\u439bg;\u67ealacetrf;\u6112r;\u619e\u0180aey\u0857\u085c\u0861ron;\u413ddil;\u413b;\u441b\u0100fs\u0868\u0970t\u0500ACDFRTUVar\u087e\u08a9\u08b1\u08e0\u08e6\u08fc\u092f\u095b\u0390\u096a\u0100nr\u0883\u088fgleBracket;\u67e8row\u0180;BR\u0899\u089a\u089e\u6190ar;\u61e4ightArrow;\u61c6eiling;\u6308o\u01f5\u08b7\0\u08c3bleBracket;\u67e6n\u01d4\u08c8\0\u08d2eeVector;\u6961ector\u0100;B\u08db\u08dc\u61c3ar;\u6959loor;\u630aight\u0100AV\u08ef\u08f5rrow;\u6194ector;\u694e\u0100er\u0901\u0917e\u0180;AV\u0909\u090a\u0910\u62a3rrow;\u61a4ector;\u695aiangle\u0180;BE\u0924\u0925\u0929\u62b2ar;\u69cfqual;\u62b4p\u0180DTV\u0937\u0942\u094cownVector;\u6951eeVector;\u6960ector\u0100;B\u0956\u0957\u61bfar;\u6958ector\u0100;B\u0965\u0966\u61bcar;\u6952ight\xe1\u039cs\u0300EFGLST\u097e\u098b\u0995\u099d\u09a2\u09adqualGreater;\u62daullEqual;\u6266reater;\u6276ess;\u6aa1lantEqual;\u6a7dilde;\u6272r;\uc000\ud835\udd0f\u0100;e\u09bd\u09be\u62d8ftarrow;\u61daidot;\u413f\u0180npw\u09d4\u0a16\u0a1bg\u0200LRlr\u09de\u09f7\u0a02\u0a10eft\u0100AR\u09e6\u09ecrrow;\u67f5ightArrow;\u67f7ightArrow;\u67f6eft\u0100ar\u03b3\u0a0aight\xe1\u03bfight\xe1\u03caf;\uc000\ud835\udd43er\u0100LR\u0a22\u0a2ceftArrow;\u6199ightArrow;\u6198\u0180cht\u0a3e\u0a40\u0a42\xf2\u084c;\u61b0rok;\u4141;\u626a\u0400acefiosu\u0a5a\u0a5d\u0a60\u0a77\u0a7c\u0a85\u0a8b\u0a8ep;\u6905y;\u441c\u0100dl\u0a65\u0a6fiumSpace;\u605flintrf;\u6133r;\uc000\ud835\udd10nusPlus;\u6213pf;\uc000\ud835\udd44c\xf2\u0a76;\u439c\u0480Jacefostu\u0aa3\u0aa7\u0aad\u0ac0\u0b14\u0b19\u0d91\u0d97\u0d9ecy;\u440acute;\u4143\u0180aey\u0ab4\u0ab9\u0aberon;\u4147dil;\u4145;\u441d\u0180gsw\u0ac7\u0af0\u0b0eative\u0180MTV\u0ad3\u0adf\u0ae8ediumSpace;\u600bhi\u0100cn\u0ae6\u0ad8\xeb\u0ad9eryThi\xee\u0ad9ted\u0100GL\u0af8\u0b06reaterGreate\xf2\u0673essLes\xf3\u0a48Line;\u400ar;\uc000\ud835\udd11\u0200Bnpt\u0b22\u0b28\u0b37\u0b3areak;\u6060BreakingSpace;\u40a0f;\u6115\u0680;CDEGHLNPRSTV\u0b55\u0b56\u0b6a\u0b7c\u0ba1\u0beb\u0c04\u0c5e\u0c84\u0ca6\u0cd8\u0d61\u0d85\u6aec\u0100ou\u0b5b\u0b64ngruent;\u6262pCap;\u626doubleVerticalBar;\u6226\u0180lqx\u0b83\u0b8a\u0b9bement;\u6209ual\u0100;T\u0b92\u0b93\u6260ilde;\uc000\u2242\u0338ists;\u6204reater\u0380;EFGLST\u0bb6\u0bb7\u0bbd\u0bc9\u0bd3\u0bd8\u0be5\u626fqual;\u6271ullEqual;\uc000\u2267\u0338reater;\uc000\u226b\u0338ess;\u6279lantEqual;\uc000\u2a7e\u0338ilde;\u6275ump\u0144\u0bf2\u0bfdownHump;\uc000\u224e\u0338qual;\uc000\u224f\u0338e\u0100fs\u0c0a\u0c27tTriangle\u0180;BE\u0c1a\u0c1b\u0c21\u62eaar;\uc000\u29cf\u0338qual;\u62ecs\u0300;EGLST\u0c35\u0c36\u0c3c\u0c44\u0c4b\u0c58\u626equal;\u6270reater;\u6278ess;\uc000\u226a\u0338lantEqual;\uc000\u2a7d\u0338ilde;\u6274ested\u0100GL\u0c68\u0c79reaterGreater;\uc000\u2aa2\u0338essLess;\uc000\u2aa1\u0338recedes\u0180;ES\u0c92\u0c93\u0c9b\u6280qual;\uc000\u2aaf\u0338lantEqual;\u62e0\u0100ei\u0cab\u0cb9verseElement;\u620cghtTriangle\u0180;BE\u0ccb\u0ccc\u0cd2\u62ebar;\uc000\u29d0\u0338qual;\u62ed\u0100qu\u0cdd\u0d0cuareSu\u0100bp\u0ce8\u0cf9set\u0100;E\u0cf0\u0cf3\uc000\u228f\u0338qual;\u62e2erset\u0100;E\u0d03\u0d06\uc000\u2290\u0338qual;\u62e3\u0180bcp\u0d13\u0d24\u0d4eset\u0100;E\u0d1b\u0d1e\uc000\u2282\u20d2qual;\u6288ceeds\u0200;EST\u0d32\u0d33\u0d3b\u0d46\u6281qual;\uc000\u2ab0\u0338lantEqual;\u62e1ilde;\uc000\u227f\u0338erset\u0100;E\u0d58\u0d5b\uc000\u2283\u20d2qual;\u6289ilde\u0200;EFT\u0d6e\u0d6f\u0d75\u0d7f\u6241qual;\u6244ullEqual;\u6247ilde;\u6249erticalBar;\u6224cr;\uc000\ud835\udca9ilde\u803b\xd1\u40d1;\u439d\u0700Eacdfgmoprstuv\u0dbd\u0dc2\u0dc9\u0dd5\u0ddb\u0de0\u0de7\u0dfc\u0e02\u0e20\u0e22\u0e32\u0e3f\u0e44lig;\u4152cute\u803b\xd3\u40d3\u0100iy\u0dce\u0dd3rc\u803b\xd4\u40d4;\u441eblac;\u4150r;\uc000\ud835\udd12rave\u803b\xd2\u40d2\u0180aei\u0dee\u0df2\u0df6cr;\u414cga;\u43a9cron;\u439fpf;\uc000\ud835\udd46enCurly\u0100DQ\u0e0e\u0e1aoubleQuote;\u601cuote;\u6018;\u6a54\u0100cl\u0e27\u0e2cr;\uc000\ud835\udcaaash\u803b\xd8\u40d8i\u016c\u0e37\u0e3cde\u803b\xd5\u40d5es;\u6a37ml\u803b\xd6\u40d6er\u0100BP\u0e4b\u0e60\u0100ar\u0e50\u0e53r;\u603eac\u0100ek\u0e5a\u0e5c;\u63deet;\u63b4arenthesis;\u63dc\u0480acfhilors\u0e7f\u0e87\u0e8a\u0e8f\u0e92\u0e94\u0e9d\u0eb0\u0efcrtialD;\u6202y;\u441fr;\uc000\ud835\udd13i;\u43a6;\u43a0usMinus;\u40b1\u0100ip\u0ea2\u0eadncareplan\xe5\u069df;\u6119\u0200;eio\u0eb9\u0eba\u0ee0\u0ee4\u6abbcedes\u0200;EST\u0ec8\u0ec9\u0ecf\u0eda\u627aqual;\u6aaflantEqual;\u627cilde;\u627eme;\u6033\u0100dp\u0ee9\u0eeeuct;\u620fortion\u0100;a\u0225\u0ef9l;\u621d\u0100ci\u0f01\u0f06r;\uc000\ud835\udcab;\u43a8\u0200Ufos\u0f11\u0f16\u0f1b\u0f1fOT\u803b"\u4022r;\uc000\ud835\udd14pf;\u611acr;\uc000\ud835\udcac\u0600BEacefhiorsu\u0f3e\u0f43\u0f47\u0f60\u0f73\u0fa7\u0faa\u0fad\u1096\u10a9\u10b4\u10bearr;\u6910G\u803b\xae\u40ae\u0180cnr\u0f4e\u0f53\u0f56ute;\u4154g;\u67ebr\u0100;t\u0f5c\u0f5d\u61a0l;\u6916\u0180aey\u0f67\u0f6c\u0f71ron;\u4158dil;\u4156;\u4420\u0100;v\u0f78\u0f79\u611cerse\u0100EU\u0f82\u0f99\u0100lq\u0f87\u0f8eement;\u620builibrium;\u61cbpEquilibrium;\u696fr\xbb\u0f79o;\u43a1ght\u0400ACDFTUVa\u0fc1\u0feb\u0ff3\u1022\u1028\u105b\u1087\u03d8\u0100nr\u0fc6\u0fd2gleBracket;\u67e9row\u0180;BL\u0fdc\u0fdd\u0fe1\u6192ar;\u61e5eftArrow;\u61c4eiling;\u6309o\u01f5\u0ff9\0\u1005bleBracket;\u67e7n\u01d4\u100a\0\u1014eeVector;\u695dector\u0100;B\u101d\u101e\u61c2ar;\u6955loor;\u630b\u0100er\u102d\u1043e\u0180;AV\u1035\u1036\u103c\u62a2rrow;\u61a6ector;\u695biangle\u0180;BE\u1050\u1051\u1055\u62b3ar;\u69d0qual;\u62b5p\u0180DTV\u1063\u106e\u1078ownVector;\u694feeVector;\u695cector\u0100;B\u1082\u1083\u61bear;\u6954ector\u0100;B\u1091\u1092\u61c0ar;\u6953\u0100pu\u109b\u109ef;\u611dndImplies;\u6970ightarrow;\u61db\u0100ch\u10b9\u10bcr;\u611b;\u61b1leDelayed;\u69f4\u0680HOacfhimoqstu\u10e4\u10f1\u10f7\u10fd\u1119\u111e\u1151\u1156\u1161\u1167\u11b5\u11bb\u11bf\u0100Cc\u10e9\u10eeHcy;\u4429y;\u4428FTcy;\u442ccute;\u415a\u0280;aeiy\u1108\u1109\u110e\u1113\u1117\u6abcron;\u4160dil;\u415erc;\u415c;\u4421r;\uc000\ud835\udd16ort\u0200DLRU\u112a\u1134\u113e\u1149ownArrow\xbb\u041eeftArrow\xbb\u089aightArrow\xbb\u0fddpArrow;\u6191gma;\u43a3allCircle;\u6218pf;\uc000\ud835\udd4a\u0272\u116d\0\0\u1170t;\u621aare\u0200;ISU\u117b\u117c\u1189\u11af\u65a1ntersection;\u6293u\u0100bp\u118f\u119eset\u0100;E\u1197\u1198\u628fqual;\u6291erset\u0100;E\u11a8\u11a9\u6290qual;\u6292nion;\u6294cr;\uc000\ud835\udcaear;\u62c6\u0200bcmp\u11c8\u11db\u1209\u120b\u0100;s\u11cd\u11ce\u62d0et\u0100;E\u11cd\u11d5qual;\u6286\u0100ch\u11e0\u1205eeds\u0200;EST\u11ed\u11ee\u11f4\u11ff\u627bqual;\u6ab0lantEqual;\u627dilde;\u627fTh\xe1\u0f8c;\u6211\u0180;es\u1212\u1213\u1223\u62d1rset\u0100;E\u121c\u121d\u6283qual;\u6287et\xbb\u1213\u0580HRSacfhiors\u123e\u1244\u1249\u1255\u125e\u1271\u1276\u129f\u12c2\u12c8\u12d1ORN\u803b\xde\u40deADE;\u6122\u0100Hc\u124e\u1252cy;\u440by;\u4426\u0100bu\u125a\u125c;\u4009;\u43a4\u0180aey\u1265\u126a\u126fron;\u4164dil;\u4162;\u4422r;\uc000\ud835\udd17\u0100ei\u127b\u1289\u01f2\u1280\0\u1287efore;\u6234a;\u4398\u0100cn\u128e\u1298kSpace;\uc000\u205f\u200aSpace;\u6009lde\u0200;EFT\u12ab\u12ac\u12b2\u12bc\u623cqual;\u6243ullEqual;\u6245ilde;\u6248pf;\uc000\ud835\udd4bipleDot;\u60db\u0100ct\u12d6\u12dbr;\uc000\ud835\udcafrok;\u4166\u0ae1\u12f7\u130e\u131a\u1326\0\u132c\u1331\0\0\0\0\0\u1338\u133d\u1377\u1385\0\u13ff\u1404\u140a\u1410\u0100cr\u12fb\u1301ute\u803b\xda\u40dar\u0100;o\u1307\u1308\u619fcir;\u6949r\u01e3\u1313\0\u1316y;\u440eve;\u416c\u0100iy\u131e\u1323rc\u803b\xdb\u40db;\u4423blac;\u4170r;\uc000\ud835\udd18rave\u803b\xd9\u40d9acr;\u416a\u0100di\u1341\u1369er\u0100BP\u1348\u135d\u0100ar\u134d\u1350r;\u405fac\u0100ek\u1357\u1359;\u63dfet;\u63b5arenthesis;\u63ddon\u0100;P\u1370\u1371\u62c3lus;\u628e\u0100gp\u137b\u137fon;\u4172f;\uc000\ud835\udd4c\u0400ADETadps\u1395\u13ae\u13b8\u13c4\u03e8\u13d2\u13d7\u13f3rrow\u0180;BD\u1150\u13a0\u13a4ar;\u6912ownArrow;\u61c5ownArrow;\u6195quilibrium;\u696eee\u0100;A\u13cb\u13cc\u62a5rrow;\u61a5own\xe1\u03f3er\u0100LR\u13de\u13e8eftArrow;\u6196ightArrow;\u6197i\u0100;l\u13f9\u13fa\u43d2on;\u43a5ing;\u416ecr;\uc000\ud835\udcb0ilde;\u4168ml\u803b\xdc\u40dc\u0480Dbcdefosv\u1427\u142c\u1430\u1433\u143e\u1485\u148a\u1490\u1496ash;\u62abar;\u6aeby;\u4412ash\u0100;l\u143b\u143c\u62a9;\u6ae6\u0100er\u1443\u1445;\u62c1\u0180bty\u144c\u1450\u147aar;\u6016\u0100;i\u144f\u1455cal\u0200BLST\u1461\u1465\u146a\u1474ar;\u6223ine;\u407ceparator;\u6758ilde;\u6240ThinSpace;\u600ar;\uc000\ud835\udd19pf;\uc000\ud835\udd4dcr;\uc000\ud835\udcb1dash;\u62aa\u0280cefos\u14a7\u14ac\u14b1\u14b6\u14bcirc;\u4174dge;\u62c0r;\uc000\ud835\udd1apf;\uc000\ud835\udd4ecr;\uc000\ud835\udcb2\u0200fios\u14cb\u14d0\u14d2\u14d8r;\uc000\ud835\udd1b;\u439epf;\uc000\ud835\udd4fcr;\uc000\ud835\udcb3\u0480AIUacfosu\u14f1\u14f5\u14f9\u14fd\u1504\u150f\u1514\u151a\u1520cy;\u442fcy;\u4407cy;\u442ecute\u803b\xdd\u40dd\u0100iy\u1509\u150drc;\u4176;\u442br;\uc000\ud835\udd1cpf;\uc000\ud835\udd50cr;\uc000\ud835\udcb4ml;\u4178\u0400Hacdefos\u1535\u1539\u153f\u154b\u154f\u155d\u1560\u1564cy;\u4416cute;\u4179\u0100ay\u1544\u1549ron;\u417d;\u4417ot;\u417b\u01f2\u1554\0\u155boWidt\xe8\u0ad9a;\u4396r;\u6128pf;\u6124cr;\uc000\ud835\udcb5\u0be1\u1583\u158a\u1590\0\u15b0\u15b6\u15bf\0\0\0\0\u15c6\u15db\u15eb\u165f\u166d\0\u1695\u169b\u16b2\u16b9\0\u16becute\u803b\xe1\u40e1reve;\u4103\u0300;Ediuy\u159c\u159d\u15a1\u15a3\u15a8\u15ad\u623e;\uc000\u223e\u0333;\u623frc\u803b\xe2\u40e2te\u80bb\xb4\u0306;\u4430lig\u803b\xe6\u40e6\u0100;r\xb2\u15ba;\uc000\ud835\udd1erave\u803b\xe0\u40e0\u0100ep\u15ca\u15d6\u0100fp\u15cf\u15d4sym;\u6135\xe8\u15d3ha;\u43b1\u0100ap\u15dfc\u0100cl\u15e4\u15e7r;\u4101g;\u6a3f\u0264\u15f0\0\0\u160a\u0280;adsv\u15fa\u15fb\u15ff\u1601\u1607\u6227nd;\u6a55;\u6a5clope;\u6a58;\u6a5a\u0380;elmrsz\u1618\u1619\u161b\u161e\u163f\u164f\u1659\u6220;\u69a4e\xbb\u1619sd\u0100;a\u1625\u1626\u6221\u0461\u1630\u1632\u1634\u1636\u1638\u163a\u163c\u163e;\u69a8;\u69a9;\u69aa;\u69ab;\u69ac;\u69ad;\u69ae;\u69aft\u0100;v\u1645\u1646\u621fb\u0100;d\u164c\u164d\u62be;\u699d\u0100pt\u1654\u1657h;\u6222\xbb\xb9arr;\u637c\u0100gp\u1663\u1667on;\u4105f;\uc000\ud835\udd52\u0380;Eaeiop\u12c1\u167b\u167d\u1682\u1684\u1687\u168a;\u6a70cir;\u6a6f;\u624ad;\u624bs;\u4027rox\u0100;e\u12c1\u1692\xf1\u1683ing\u803b\xe5\u40e5\u0180cty\u16a1\u16a6\u16a8r;\uc000\ud835\udcb6;\u402amp\u0100;e\u12c1\u16af\xf1\u0288ilde\u803b\xe3\u40e3ml\u803b\xe4\u40e4\u0100ci\u16c2\u16c8onin\xf4\u0272nt;\u6a11\u0800Nabcdefiklnoprsu\u16ed\u16f1\u1730\u173c\u1743\u1748\u1778\u177d\u17e0\u17e6\u1839\u1850\u170d\u193d\u1948\u1970ot;\u6aed\u0100cr\u16f6\u171ek\u0200ceps\u1700\u1705\u170d\u1713ong;\u624cpsilon;\u43f6rime;\u6035im\u0100;e\u171a\u171b\u623dq;\u62cd\u0176\u1722\u1726ee;\u62bded\u0100;g\u172c\u172d\u6305e\xbb\u172drk\u0100;t\u135c\u1737brk;\u63b6\u0100oy\u1701\u1741;\u4431quo;\u601e\u0280cmprt\u1753\u175b\u1761\u1764\u1768aus\u0100;e\u010a\u0109ptyv;\u69b0s\xe9\u170cno\xf5\u0113\u0180ahw\u176f\u1771\u1773;\u43b2;\u6136een;\u626cr;\uc000\ud835\udd1fg\u0380costuvw\u178d\u179d\u17b3\u17c1\u17d5\u17db\u17de\u0180aiu\u1794\u1796\u179a\xf0\u0760rc;\u65efp\xbb\u1371\u0180dpt\u17a4\u17a8\u17adot;\u6a00lus;\u6a01imes;\u6a02\u0271\u17b9\0\0\u17becup;\u6a06ar;\u6605riangle\u0100du\u17cd\u17d2own;\u65bdp;\u65b3plus;\u6a04e\xe5\u1444\xe5\u14adarow;\u690d\u0180ako\u17ed\u1826\u1835\u0100cn\u17f2\u1823k\u0180lst\u17fa\u05ab\u1802ozenge;\u69ebriangle\u0200;dlr\u1812\u1813\u1818\u181d\u65b4own;\u65beeft;\u65c2ight;\u65b8k;\u6423\u01b1\u182b\0\u1833\u01b2\u182f\0\u1831;\u6592;\u65914;\u6593ck;\u6588\u0100eo\u183e\u184d\u0100;q\u1843\u1846\uc000=\u20e5uiv;\uc000\u2261\u20e5t;\u6310\u0200ptwx\u1859\u185e\u1867\u186cf;\uc000\ud835\udd53\u0100;t\u13cb\u1863om\xbb\u13cctie;\u62c8\u0600DHUVbdhmptuv\u1885\u1896\u18aa\u18bb\u18d7\u18db\u18ec\u18ff\u1905\u190a\u1910\u1921\u0200LRlr\u188e\u1890\u1892\u1894;\u6557;\u6554;\u6556;\u6553\u0280;DUdu\u18a1\u18a2\u18a4\u18a6\u18a8\u6550;\u6566;\u6569;\u6564;\u6567\u0200LRlr\u18b3\u18b5\u18b7\u18b9;\u655d;\u655a;\u655c;\u6559\u0380;HLRhlr\u18ca\u18cb\u18cd\u18cf\u18d1\u18d3\u18d5\u6551;\u656c;\u6563;\u6560;\u656b;\u6562;\u655fox;\u69c9\u0200LRlr\u18e4\u18e6\u18e8\u18ea;\u6555;\u6552;\u6510;\u650c\u0280;DUdu\u06bd\u18f7\u18f9\u18fb\u18fd;\u6565;\u6568;\u652c;\u6534inus;\u629flus;\u629eimes;\u62a0\u0200LRlr\u1919\u191b\u191d\u191f;\u655b;\u6558;\u6518;\u6514\u0380;HLRhlr\u1930\u1931\u1933\u1935\u1937\u1939\u193b\u6502;\u656a;\u6561;\u655e;\u653c;\u6524;\u651c\u0100ev\u0123\u1942bar\u803b\xa6\u40a6\u0200ceio\u1951\u1956\u195a\u1960r;\uc000\ud835\udcb7mi;\u604fm\u0100;e\u171a\u171cl\u0180;bh\u1968\u1969\u196b\u405c;\u69c5sub;\u67c8\u016c\u1974\u197el\u0100;e\u1979\u197a\u6022t\xbb\u197ap\u0180;Ee\u012f\u1985\u1987;\u6aae\u0100;q\u06dc\u06db\u0ce1\u19a7\0\u19e8\u1a11\u1a15\u1a32\0\u1a37\u1a50\0\0\u1ab4\0\0\u1ac1\0\0\u1b21\u1b2e\u1b4d\u1b52\0\u1bfd\0\u1c0c\u0180cpr\u19ad\u19b2\u19ddute;\u4107\u0300;abcds\u19bf\u19c0\u19c4\u19ca\u19d5\u19d9\u6229nd;\u6a44rcup;\u6a49\u0100au\u19cf\u19d2p;\u6a4bp;\u6a47ot;\u6a40;\uc000\u2229\ufe00\u0100eo\u19e2\u19e5t;\u6041\xee\u0693\u0200aeiu\u19f0\u19fb\u1a01\u1a05\u01f0\u19f5\0\u19f8s;\u6a4don;\u410ddil\u803b\xe7\u40e7rc;\u4109ps\u0100;s\u1a0c\u1a0d\u6a4cm;\u6a50ot;\u410b\u0180dmn\u1a1b\u1a20\u1a26il\u80bb\xb8\u01adptyv;\u69b2t\u8100\xa2;e\u1a2d\u1a2e\u40a2r\xe4\u01b2r;\uc000\ud835\udd20\u0180cei\u1a3d\u1a40\u1a4dy;\u4447ck\u0100;m\u1a47\u1a48\u6713ark\xbb\u1a48;\u43c7r\u0380;Ecefms\u1a5f\u1a60\u1a62\u1a6b\u1aa4\u1aaa\u1aae\u65cb;\u69c3\u0180;el\u1a69\u1a6a\u1a6d\u42c6q;\u6257e\u0261\u1a74\0\0\u1a88rrow\u0100lr\u1a7c\u1a81eft;\u61baight;\u61bb\u0280RSacd\u1a92\u1a94\u1a96\u1a9a\u1a9f\xbb\u0f47;\u64c8st;\u629birc;\u629aash;\u629dnint;\u6a10id;\u6aefcir;\u69c2ubs\u0100;u\u1abb\u1abc\u6663it\xbb\u1abc\u02ec\u1ac7\u1ad4\u1afa\0\u1b0aon\u0100;e\u1acd\u1ace\u403a\u0100;q\xc7\xc6\u026d\u1ad9\0\0\u1ae2a\u0100;t\u1ade\u1adf\u402c;\u4040\u0180;fl\u1ae8\u1ae9\u1aeb\u6201\xee\u1160e\u0100mx\u1af1\u1af6ent\xbb\u1ae9e\xf3\u024d\u01e7\u1afe\0\u1b07\u0100;d\u12bb\u1b02ot;\u6a6dn\xf4\u0246\u0180fry\u1b10\u1b14\u1b17;\uc000\ud835\udd54o\xe4\u0254\u8100\xa9;s\u0155\u1b1dr;\u6117\u0100ao\u1b25\u1b29rr;\u61b5ss;\u6717\u0100cu\u1b32\u1b37r;\uc000\ud835\udcb8\u0100bp\u1b3c\u1b44\u0100;e\u1b41\u1b42\u6acf;\u6ad1\u0100;e\u1b49\u1b4a\u6ad0;\u6ad2dot;\u62ef\u0380delprvw\u1b60\u1b6c\u1b77\u1b82\u1bac\u1bd4\u1bf9arr\u0100lr\u1b68\u1b6a;\u6938;\u6935\u0270\u1b72\0\0\u1b75r;\u62dec;\u62dfarr\u0100;p\u1b7f\u1b80\u61b6;\u693d\u0300;bcdos\u1b8f\u1b90\u1b96\u1ba1\u1ba5\u1ba8\u622arcap;\u6a48\u0100au\u1b9b\u1b9ep;\u6a46p;\u6a4aot;\u628dr;\u6a45;\uc000\u222a\ufe00\u0200alrv\u1bb5\u1bbf\u1bde\u1be3rr\u0100;m\u1bbc\u1bbd\u61b7;\u693cy\u0180evw\u1bc7\u1bd4\u1bd8q\u0270\u1bce\0\0\u1bd2re\xe3\u1b73u\xe3\u1b75ee;\u62ceedge;\u62cfen\u803b\xa4\u40a4earrow\u0100lr\u1bee\u1bf3eft\xbb\u1b80ight\xbb\u1bbde\xe4\u1bdd\u0100ci\u1c01\u1c07onin\xf4\u01f7nt;\u6231lcty;\u632d\u0980AHabcdefhijlorstuwz\u1c38\u1c3b\u1c3f\u1c5d\u1c69\u1c75\u1c8a\u1c9e\u1cac\u1cb7\u1cfb\u1cff\u1d0d\u1d7b\u1d91\u1dab\u1dbb\u1dc6\u1dcdr\xf2\u0381ar;\u6965\u0200glrs\u1c48\u1c4d\u1c52\u1c54ger;\u6020eth;\u6138\xf2\u1133h\u0100;v\u1c5a\u1c5b\u6010\xbb\u090a\u016b\u1c61\u1c67arow;\u690fa\xe3\u0315\u0100ay\u1c6e\u1c73ron;\u410f;\u4434\u0180;ao\u0332\u1c7c\u1c84\u0100gr\u02bf\u1c81r;\u61catseq;\u6a77\u0180glm\u1c91\u1c94\u1c98\u803b\xb0\u40b0ta;\u43b4ptyv;\u69b1\u0100ir\u1ca3\u1ca8sht;\u697f;\uc000\ud835\udd21ar\u0100lr\u1cb3\u1cb5\xbb\u08dc\xbb\u101e\u0280aegsv\u1cc2\u0378\u1cd6\u1cdc\u1ce0m\u0180;os\u0326\u1cca\u1cd4nd\u0100;s\u0326\u1cd1uit;\u6666amma;\u43ddin;\u62f2\u0180;io\u1ce7\u1ce8\u1cf8\u40f7de\u8100\xf7;o\u1ce7\u1cf0ntimes;\u62c7n\xf8\u1cf7cy;\u4452c\u026f\u1d06\0\0\u1d0arn;\u631eop;\u630d\u0280lptuw\u1d18\u1d1d\u1d22\u1d49\u1d55lar;\u4024f;\uc000\ud835\udd55\u0280;emps\u030b\u1d2d\u1d37\u1d3d\u1d42q\u0100;d\u0352\u1d33ot;\u6251inus;\u6238lus;\u6214quare;\u62a1blebarwedg\xe5\xfan\u0180adh\u112e\u1d5d\u1d67ownarrow\xf3\u1c83arpoon\u0100lr\u1d72\u1d76ef\xf4\u1cb4igh\xf4\u1cb6\u0162\u1d7f\u1d85karo\xf7\u0f42\u026f\u1d8a\0\0\u1d8ern;\u631fop;\u630c\u0180cot\u1d98\u1da3\u1da6\u0100ry\u1d9d\u1da1;\uc000\ud835\udcb9;\u4455l;\u69f6rok;\u4111\u0100dr\u1db0\u1db4ot;\u62f1i\u0100;f\u1dba\u1816\u65bf\u0100ah\u1dc0\u1dc3r\xf2\u0429a\xf2\u0fa6angle;\u69a6\u0100ci\u1dd2\u1dd5y;\u445fgrarr;\u67ff\u0900Dacdefglmnopqrstux\u1e01\u1e09\u1e19\u1e38\u0578\u1e3c\u1e49\u1e61\u1e7e\u1ea5\u1eaf\u1ebd\u1ee1\u1f2a\u1f37\u1f44\u1f4e\u1f5a\u0100Do\u1e06\u1d34o\xf4\u1c89\u0100cs\u1e0e\u1e14ute\u803b\xe9\u40e9ter;\u6a6e\u0200aioy\u1e22\u1e27\u1e31\u1e36ron;\u411br\u0100;c\u1e2d\u1e2e\u6256\u803b\xea\u40ealon;\u6255;\u444dot;\u4117\u0100Dr\u1e41\u1e45ot;\u6252;\uc000\ud835\udd22\u0180;rs\u1e50\u1e51\u1e57\u6a9aave\u803b\xe8\u40e8\u0100;d\u1e5c\u1e5d\u6a96ot;\u6a98\u0200;ils\u1e6a\u1e6b\u1e72\u1e74\u6a99nters;\u63e7;\u6113\u0100;d\u1e79\u1e7a\u6a95ot;\u6a97\u0180aps\u1e85\u1e89\u1e97cr;\u4113ty\u0180;sv\u1e92\u1e93\u1e95\u6205et\xbb\u1e93p\u01001;\u1e9d\u1ea4\u0133\u1ea1\u1ea3;\u6004;\u6005\u6003\u0100gs\u1eaa\u1eac;\u414bp;\u6002\u0100gp\u1eb4\u1eb8on;\u4119f;\uc000\ud835\udd56\u0180als\u1ec4\u1ece\u1ed2r\u0100;s\u1eca\u1ecb\u62d5l;\u69e3us;\u6a71i\u0180;lv\u1eda\u1edb\u1edf\u43b5on\xbb\u1edb;\u43f5\u0200csuv\u1eea\u1ef3\u1f0b\u1f23\u0100io\u1eef\u1e31rc\xbb\u1e2e\u0269\u1ef9\0\0\u1efb\xed\u0548ant\u0100gl\u1f02\u1f06tr\xbb\u1e5dess\xbb\u1e7a\u0180aei\u1f12\u1f16\u1f1als;\u403dst;\u625fv\u0100;D\u0235\u1f20D;\u6a78parsl;\u69e5\u0100Da\u1f2f\u1f33ot;\u6253rr;\u6971\u0180cdi\u1f3e\u1f41\u1ef8r;\u612fo\xf4\u0352\u0100ah\u1f49\u1f4b;\u43b7\u803b\xf0\u40f0\u0100mr\u1f53\u1f57l\u803b\xeb\u40ebo;\u60ac\u0180cip\u1f61\u1f64\u1f67l;\u4021s\xf4\u056e\u0100eo\u1f6c\u1f74ctatio\xee\u0559nential\xe5\u0579\u09e1\u1f92\0\u1f9e\0\u1fa1\u1fa7\0\0\u1fc6\u1fcc\0\u1fd3\0\u1fe6\u1fea\u2000\0\u2008\u205allingdotse\xf1\u1e44y;\u4444male;\u6640\u0180ilr\u1fad\u1fb3\u1fc1lig;\u8000\ufb03\u0269\u1fb9\0\0\u1fbdg;\u8000\ufb00ig;\u8000\ufb04;\uc000\ud835\udd23lig;\u8000\ufb01lig;\uc000fj\u0180alt\u1fd9\u1fdc\u1fe1t;\u666dig;\u8000\ufb02ns;\u65b1of;\u4192\u01f0\u1fee\0\u1ff3f;\uc000\ud835\udd57\u0100ak\u05bf\u1ff7\u0100;v\u1ffc\u1ffd\u62d4;\u6ad9artint;\u6a0d\u0100ao\u200c\u2055\u0100cs\u2011\u2052\u03b1\u201a\u2030\u2038\u2045\u2048\0\u2050\u03b2\u2022\u2025\u2027\u202a\u202c\0\u202e\u803b\xbd\u40bd;\u6153\u803b\xbc\u40bc;\u6155;\u6159;\u615b\u01b3\u2034\0\u2036;\u6154;\u6156\u02b4\u203e\u2041\0\0\u2043\u803b\xbe\u40be;\u6157;\u615c5;\u6158\u01b6\u204c\0\u204e;\u615a;\u615d8;\u615el;\u6044wn;\u6322cr;\uc000\ud835\udcbb\u0880Eabcdefgijlnorstv\u2082\u2089\u209f\u20a5\u20b0\u20b4\u20f0\u20f5\u20fa\u20ff\u2103\u2112\u2138\u0317\u213e\u2152\u219e\u0100;l\u064d\u2087;\u6a8c\u0180cmp\u2090\u2095\u209dute;\u41f5ma\u0100;d\u209c\u1cda\u43b3;\u6a86reve;\u411f\u0100iy\u20aa\u20aerc;\u411d;\u4433ot;\u4121\u0200;lqs\u063e\u0642\u20bd\u20c9\u0180;qs\u063e\u064c\u20c4lan\xf4\u0665\u0200;cdl\u0665\u20d2\u20d5\u20e5c;\u6aa9ot\u0100;o\u20dc\u20dd\u6a80\u0100;l\u20e2\u20e3\u6a82;\u6a84\u0100;e\u20ea\u20ed\uc000\u22db\ufe00s;\u6a94r;\uc000\ud835\udd24\u0100;g\u0673\u061bmel;\u6137cy;\u4453\u0200;Eaj\u065a\u210c\u210e\u2110;\u6a92;\u6aa5;\u6aa4\u0200Eaes\u211b\u211d\u2129\u2134;\u6269p\u0100;p\u2123\u2124\u6a8arox\xbb\u2124\u0100;q\u212e\u212f\u6a88\u0100;q\u212e\u211bim;\u62e7pf;\uc000\ud835\udd58\u0100ci\u2143\u2146r;\u610am\u0180;el\u066b\u214e\u2150;\u6a8e;\u6a90\u8300>;cdlqr\u05ee\u2160\u216a\u216e\u2173\u2179\u0100ci\u2165\u2167;\u6aa7r;\u6a7aot;\u62d7Par;\u6995uest;\u6a7c\u0280adels\u2184\u216a\u2190\u0656\u219b\u01f0\u2189\0\u218epro\xf8\u209er;\u6978q\u0100lq\u063f\u2196les\xf3\u2088i\xed\u066b\u0100en\u21a3\u21adrtneqq;\uc000\u2269\ufe00\xc5\u21aa\u0500Aabcefkosy\u21c4\u21c7\u21f1\u21f5\u21fa\u2218\u221d\u222f\u2268\u227dr\xf2\u03a0\u0200ilmr\u21d0\u21d4\u21d7\u21dbrs\xf0\u1484f\xbb\u2024il\xf4\u06a9\u0100dr\u21e0\u21e4cy;\u444a\u0180;cw\u08f4\u21eb\u21efir;\u6948;\u61adar;\u610firc;\u4125\u0180alr\u2201\u220e\u2213rts\u0100;u\u2209\u220a\u6665it\xbb\u220alip;\u6026con;\u62b9r;\uc000\ud835\udd25s\u0100ew\u2223\u2229arow;\u6925arow;\u6926\u0280amopr\u223a\u223e\u2243\u225e\u2263rr;\u61fftht;\u623bk\u0100lr\u2249\u2253eftarrow;\u61a9ightarrow;\u61aaf;\uc000\ud835\udd59bar;\u6015\u0180clt\u226f\u2274\u2278r;\uc000\ud835\udcbdas\xe8\u21f4rok;\u4127\u0100bp\u2282\u2287ull;\u6043hen\xbb\u1c5b\u0ae1\u22a3\0\u22aa\0\u22b8\u22c5\u22ce\0\u22d5\u22f3\0\0\u22f8\u2322\u2367\u2362\u237f\0\u2386\u23aa\u23b4cute\u803b\xed\u40ed\u0180;iy\u0771\u22b0\u22b5rc\u803b\xee\u40ee;\u4438\u0100cx\u22bc\u22bfy;\u4435cl\u803b\xa1\u40a1\u0100fr\u039f\u22c9;\uc000\ud835\udd26rave\u803b\xec\u40ec\u0200;ino\u073e\u22dd\u22e9\u22ee\u0100in\u22e2\u22e6nt;\u6a0ct;\u622dfin;\u69dcta;\u6129lig;\u4133\u0180aop\u22fe\u231a\u231d\u0180cgt\u2305\u2308\u2317r;\u412b\u0180elp\u071f\u230f\u2313in\xe5\u078ear\xf4\u0720h;\u4131f;\u62b7ed;\u41b5\u0280;cfot\u04f4\u232c\u2331\u233d\u2341are;\u6105in\u0100;t\u2338\u2339\u621eie;\u69dddo\xf4\u2319\u0280;celp\u0757\u234c\u2350\u235b\u2361al;\u62ba\u0100gr\u2355\u2359er\xf3\u1563\xe3\u234darhk;\u6a17rod;\u6a3c\u0200cgpt\u236f\u2372\u2376\u237by;\u4451on;\u412ff;\uc000\ud835\udd5aa;\u43b9uest\u803b\xbf\u40bf\u0100ci\u238a\u238fr;\uc000\ud835\udcben\u0280;Edsv\u04f4\u239b\u239d\u23a1\u04f3;\u62f9ot;\u62f5\u0100;v\u23a6\u23a7\u62f4;\u62f3\u0100;i\u0777\u23aelde;\u4129\u01eb\u23b8\0\u23bccy;\u4456l\u803b\xef\u40ef\u0300cfmosu\u23cc\u23d7\u23dc\u23e1\u23e7\u23f5\u0100iy\u23d1\u23d5rc;\u4135;\u4439r;\uc000\ud835\udd27ath;\u4237pf;\uc000\ud835\udd5b\u01e3\u23ec\0\u23f1r;\uc000\ud835\udcbfrcy;\u4458kcy;\u4454\u0400acfghjos\u240b\u2416\u2422\u2427\u242d\u2431\u2435\u243bppa\u0100;v\u2413\u2414\u43ba;\u43f0\u0100ey\u241b\u2420dil;\u4137;\u443ar;\uc000\ud835\udd28reen;\u4138cy;\u4445cy;\u445cpf;\uc000\ud835\udd5ccr;\uc000\ud835\udcc0\u0b80ABEHabcdefghjlmnoprstuv\u2470\u2481\u2486\u248d\u2491\u250e\u253d\u255a\u2580\u264e\u265e\u2665\u2679\u267d\u269a\u26b2\u26d8\u275d\u2768\u278b\u27c0\u2801\u2812\u0180art\u2477\u247a\u247cr\xf2\u09c6\xf2\u0395ail;\u691barr;\u690e\u0100;g\u0994\u248b;\u6a8bar;\u6962\u0963\u24a5\0\u24aa\0\u24b1\0\0\0\0\0\u24b5\u24ba\0\u24c6\u24c8\u24cd\0\u24f9ute;\u413amptyv;\u69b4ra\xee\u084cbda;\u43bbg\u0180;dl\u088e\u24c1\u24c3;\u6991\xe5\u088e;\u6a85uo\u803b\xab\u40abr\u0400;bfhlpst\u0899\u24de\u24e6\u24e9\u24eb\u24ee\u24f1\u24f5\u0100;f\u089d\u24e3s;\u691fs;\u691d\xeb\u2252p;\u61abl;\u6939im;\u6973l;\u61a2\u0180;ae\u24ff\u2500\u2504\u6aabil;\u6919\u0100;s\u2509\u250a\u6aad;\uc000\u2aad\ufe00\u0180abr\u2515\u2519\u251drr;\u690crk;\u6772\u0100ak\u2522\u252cc\u0100ek\u2528\u252a;\u407b;\u405b\u0100es\u2531\u2533;\u698bl\u0100du\u2539\u253b;\u698f;\u698d\u0200aeuy\u2546\u254b\u2556\u2558ron;\u413e\u0100di\u2550\u2554il;\u413c\xec\u08b0\xe2\u2529;\u443b\u0200cqrs\u2563\u2566\u256d\u257da;\u6936uo\u0100;r\u0e19\u1746\u0100du\u2572\u2577har;\u6967shar;\u694bh;\u61b2\u0280;fgqs\u258b\u258c\u0989\u25f3\u25ff\u6264t\u0280ahlrt\u2598\u25a4\u25b7\u25c2\u25e8rrow\u0100;t\u0899\u25a1a\xe9\u24f6arpoon\u0100du\u25af\u25b4own\xbb\u045ap\xbb\u0966eftarrows;\u61c7ight\u0180ahs\u25cd\u25d6\u25derrow\u0100;s\u08f4\u08a7arpoon\xf3\u0f98quigarro\xf7\u21f0hreetimes;\u62cb\u0180;qs\u258b\u0993\u25falan\xf4\u09ac\u0280;cdgs\u09ac\u260a\u260d\u261d\u2628c;\u6aa8ot\u0100;o\u2614\u2615\u6a7f\u0100;r\u261a\u261b\u6a81;\u6a83\u0100;e\u2622\u2625\uc000\u22da\ufe00s;\u6a93\u0280adegs\u2633\u2639\u263d\u2649\u264bppro\xf8\u24c6ot;\u62d6q\u0100gq\u2643\u2645\xf4\u0989gt\xf2\u248c\xf4\u099bi\xed\u09b2\u0180ilr\u2655\u08e1\u265asht;\u697c;\uc000\ud835\udd29\u0100;E\u099c\u2663;\u6a91\u0161\u2669\u2676r\u0100du\u25b2\u266e\u0100;l\u0965\u2673;\u696alk;\u6584cy;\u4459\u0280;acht\u0a48\u2688\u268b\u2691\u2696r\xf2\u25c1orne\xf2\u1d08ard;\u696bri;\u65fa\u0100io\u269f\u26a4dot;\u4140ust\u0100;a\u26ac\u26ad\u63b0che\xbb\u26ad\u0200Eaes\u26bb\u26bd\u26c9\u26d4;\u6268p\u0100;p\u26c3\u26c4\u6a89rox\xbb\u26c4\u0100;q\u26ce\u26cf\u6a87\u0100;q\u26ce\u26bbim;\u62e6\u0400abnoptwz\u26e9\u26f4\u26f7\u271a\u272f\u2741\u2747\u2750\u0100nr\u26ee\u26f1g;\u67ecr;\u61fdr\xeb\u08c1g\u0180lmr\u26ff\u270d\u2714eft\u0100ar\u09e6\u2707ight\xe1\u09f2apsto;\u67fcight\xe1\u09fdparrow\u0100lr\u2725\u2729ef\xf4\u24edight;\u61ac\u0180afl\u2736\u2739\u273dr;\u6985;\uc000\ud835\udd5dus;\u6a2dimes;\u6a34\u0161\u274b\u274fst;\u6217\xe1\u134e\u0180;ef\u2757\u2758\u1800\u65cange\xbb\u2758ar\u0100;l\u2764\u2765\u4028t;\u6993\u0280achmt\u2773\u2776\u277c\u2785\u2787r\xf2\u08a8orne\xf2\u1d8car\u0100;d\u0f98\u2783;\u696d;\u600eri;\u62bf\u0300achiqt\u2798\u279d\u0a40\u27a2\u27ae\u27bbquo;\u6039r;\uc000\ud835\udcc1m\u0180;eg\u09b2\u27aa\u27ac;\u6a8d;\u6a8f\u0100bu\u252a\u27b3o\u0100;r\u0e1f\u27b9;\u601arok;\u4142\u8400<;cdhilqr\u082b\u27d2\u2639\u27dc\u27e0\u27e5\u27ea\u27f0\u0100ci\u27d7\u27d9;\u6aa6r;\u6a79re\xe5\u25f2mes;\u62c9arr;\u6976uest;\u6a7b\u0100Pi\u27f5\u27f9ar;\u6996\u0180;ef\u2800\u092d\u181b\u65c3r\u0100du\u2807\u280dshar;\u694ahar;\u6966\u0100en\u2817\u2821rtneqq;\uc000\u2268\ufe00\xc5\u281e\u0700Dacdefhilnopsu\u2840\u2845\u2882\u288e\u2893\u28a0\u28a5\u28a8\u28da\u28e2\u28e4\u0a83\u28f3\u2902Dot;\u623a\u0200clpr\u284e\u2852\u2863\u287dr\u803b\xaf\u40af\u0100et\u2857\u2859;\u6642\u0100;e\u285e\u285f\u6720se\xbb\u285f\u0100;s\u103b\u2868to\u0200;dlu\u103b\u2873\u2877\u287bow\xee\u048cef\xf4\u090f\xf0\u13d1ker;\u65ae\u0100oy\u2887\u288cmma;\u6a29;\u443cash;\u6014asuredangle\xbb\u1626r;\uc000\ud835\udd2ao;\u6127\u0180cdn\u28af\u28b4\u28c9ro\u803b\xb5\u40b5\u0200;acd\u1464\u28bd\u28c0\u28c4s\xf4\u16a7ir;\u6af0ot\u80bb\xb7\u01b5us\u0180;bd\u28d2\u1903\u28d3\u6212\u0100;u\u1d3c\u28d8;\u6a2a\u0163\u28de\u28e1p;\u6adb\xf2\u2212\xf0\u0a81\u0100dp\u28e9\u28eeels;\u62a7f;\uc000\ud835\udd5e\u0100ct\u28f8\u28fdr;\uc000\ud835\udcc2pos\xbb\u159d\u0180;lm\u2909\u290a\u290d\u43bctimap;\u62b8\u0c00GLRVabcdefghijlmoprstuvw\u2942\u2953\u297e\u2989\u2998\u29da\u29e9\u2a15\u2a1a\u2a58\u2a5d\u2a83\u2a95\u2aa4\u2aa8\u2b04\u2b07\u2b44\u2b7f\u2bae\u2c34\u2c67\u2c7c\u2ce9\u0100gt\u2947\u294b;\uc000\u22d9\u0338\u0100;v\u2950\u0bcf\uc000\u226b\u20d2\u0180elt\u295a\u2972\u2976ft\u0100ar\u2961\u2967rrow;\u61cdightarrow;\u61ce;\uc000\u22d8\u0338\u0100;v\u297b\u0c47\uc000\u226a\u20d2ightarrow;\u61cf\u0100Dd\u298e\u2993ash;\u62afash;\u62ae\u0280bcnpt\u29a3\u29a7\u29ac\u29b1\u29ccla\xbb\u02deute;\u4144g;\uc000\u2220\u20d2\u0280;Eiop\u0d84\u29bc\u29c0\u29c5\u29c8;\uc000\u2a70\u0338d;\uc000\u224b\u0338s;\u4149ro\xf8\u0d84ur\u0100;a\u29d3\u29d4\u666el\u0100;s\u29d3\u0b38\u01f3\u29df\0\u29e3p\u80bb\xa0\u0b37mp\u0100;e\u0bf9\u0c00\u0280aeouy\u29f4\u29fe\u2a03\u2a10\u2a13\u01f0\u29f9\0\u29fb;\u6a43on;\u4148dil;\u4146ng\u0100;d\u0d7e\u2a0aot;\uc000\u2a6d\u0338p;\u6a42;\u443dash;\u6013\u0380;Aadqsx\u0b92\u2a29\u2a2d\u2a3b\u2a41\u2a45\u2a50rr;\u61d7r\u0100hr\u2a33\u2a36k;\u6924\u0100;o\u13f2\u13f0ot;\uc000\u2250\u0338ui\xf6\u0b63\u0100ei\u2a4a\u2a4ear;\u6928\xed\u0b98ist\u0100;s\u0ba0\u0b9fr;\uc000\ud835\udd2b\u0200Eest\u0bc5\u2a66\u2a79\u2a7c\u0180;qs\u0bbc\u2a6d\u0be1\u0180;qs\u0bbc\u0bc5\u2a74lan\xf4\u0be2i\xed\u0bea\u0100;r\u0bb6\u2a81\xbb\u0bb7\u0180Aap\u2a8a\u2a8d\u2a91r\xf2\u2971rr;\u61aear;\u6af2\u0180;sv\u0f8d\u2a9c\u0f8c\u0100;d\u2aa1\u2aa2\u62fc;\u62facy;\u445a\u0380AEadest\u2ab7\u2aba\u2abe\u2ac2\u2ac5\u2af6\u2af9r\xf2\u2966;\uc000\u2266\u0338rr;\u619ar;\u6025\u0200;fqs\u0c3b\u2ace\u2ae3\u2aeft\u0100ar\u2ad4\u2ad9rro\xf7\u2ac1ightarro\xf7\u2a90\u0180;qs\u0c3b\u2aba\u2aealan\xf4\u0c55\u0100;s\u0c55\u2af4\xbb\u0c36i\xed\u0c5d\u0100;r\u0c35\u2afei\u0100;e\u0c1a\u0c25i\xe4\u0d90\u0100pt\u2b0c\u2b11f;\uc000\ud835\udd5f\u8180\xac;in\u2b19\u2b1a\u2b36\u40acn\u0200;Edv\u0b89\u2b24\u2b28\u2b2e;\uc000\u22f9\u0338ot;\uc000\u22f5\u0338\u01e1\u0b89\u2b33\u2b35;\u62f7;\u62f6i\u0100;v\u0cb8\u2b3c\u01e1\u0cb8\u2b41\u2b43;\u62fe;\u62fd\u0180aor\u2b4b\u2b63\u2b69r\u0200;ast\u0b7b\u2b55\u2b5a\u2b5flle\xec\u0b7bl;\uc000\u2afd\u20e5;\uc000\u2202\u0338lint;\u6a14\u0180;ce\u0c92\u2b70\u2b73u\xe5\u0ca5\u0100;c\u0c98\u2b78\u0100;e\u0c92\u2b7d\xf1\u0c98\u0200Aait\u2b88\u2b8b\u2b9d\u2ba7r\xf2\u2988rr\u0180;cw\u2b94\u2b95\u2b99\u619b;\uc000\u2933\u0338;\uc000\u219d\u0338ghtarrow\xbb\u2b95ri\u0100;e\u0ccb\u0cd6\u0380chimpqu\u2bbd\u2bcd\u2bd9\u2b04\u0b78\u2be4\u2bef\u0200;cer\u0d32\u2bc6\u0d37\u2bc9u\xe5\u0d45;\uc000\ud835\udcc3ort\u026d\u2b05\0\0\u2bd6ar\xe1\u2b56m\u0100;e\u0d6e\u2bdf\u0100;q\u0d74\u0d73su\u0100bp\u2beb\u2bed\xe5\u0cf8\xe5\u0d0b\u0180bcp\u2bf6\u2c11\u2c19\u0200;Ees\u2bff\u2c00\u0d22\u2c04\u6284;\uc000\u2ac5\u0338et\u0100;e\u0d1b\u2c0bq\u0100;q\u0d23\u2c00c\u0100;e\u0d32\u2c17\xf1\u0d38\u0200;Ees\u2c22\u2c23\u0d5f\u2c27\u6285;\uc000\u2ac6\u0338et\u0100;e\u0d58\u2c2eq\u0100;q\u0d60\u2c23\u0200gilr\u2c3d\u2c3f\u2c45\u2c47\xec\u0bd7lde\u803b\xf1\u40f1\xe7\u0c43iangle\u0100lr\u2c52\u2c5ceft\u0100;e\u0c1a\u2c5a\xf1\u0c26ight\u0100;e\u0ccb\u2c65\xf1\u0cd7\u0100;m\u2c6c\u2c6d\u43bd\u0180;es\u2c74\u2c75\u2c79\u4023ro;\u6116p;\u6007\u0480DHadgilrs\u2c8f\u2c94\u2c99\u2c9e\u2ca3\u2cb0\u2cb6\u2cd3\u2ce3ash;\u62adarr;\u6904p;\uc000\u224d\u20d2ash;\u62ac\u0100et\u2ca8\u2cac;\uc000\u2265\u20d2;\uc000>\u20d2nfin;\u69de\u0180Aet\u2cbd\u2cc1\u2cc5rr;\u6902;\uc000\u2264\u20d2\u0100;r\u2cca\u2ccd\uc000<\u20d2ie;\uc000\u22b4\u20d2\u0100At\u2cd8\u2cdcrr;\u6903rie;\uc000\u22b5\u20d2im;\uc000\u223c\u20d2\u0180Aan\u2cf0\u2cf4\u2d02rr;\u61d6r\u0100hr\u2cfa\u2cfdk;\u6923\u0100;o\u13e7\u13e5ear;\u6927\u1253\u1a95\0\0\0\0\0\0\0\0\0\0\0\0\0\u2d2d\0\u2d38\u2d48\u2d60\u2d65\u2d72\u2d84\u1b07\0\0\u2d8d\u2dab\0\u2dc8\u2dce\0\u2ddc\u2e19\u2e2b\u2e3e\u2e43\u0100cs\u2d31\u1a97ute\u803b\xf3\u40f3\u0100iy\u2d3c\u2d45r\u0100;c\u1a9e\u2d42\u803b\xf4\u40f4;\u443e\u0280abios\u1aa0\u2d52\u2d57\u01c8\u2d5alac;\u4151v;\u6a38old;\u69bclig;\u4153\u0100cr\u2d69\u2d6dir;\u69bf;\uc000\ud835\udd2c\u036f\u2d79\0\0\u2d7c\0\u2d82n;\u42dbave\u803b\xf2\u40f2;\u69c1\u0100bm\u2d88\u0df4ar;\u69b5\u0200acit\u2d95\u2d98\u2da5\u2da8r\xf2\u1a80\u0100ir\u2d9d\u2da0r;\u69beoss;\u69bbn\xe5\u0e52;\u69c0\u0180aei\u2db1\u2db5\u2db9cr;\u414dga;\u43c9\u0180cdn\u2dc0\u2dc5\u01cdron;\u43bf;\u69b6pf;\uc000\ud835\udd60\u0180ael\u2dd4\u2dd7\u01d2r;\u69b7rp;\u69b9\u0380;adiosv\u2dea\u2deb\u2dee\u2e08\u2e0d\u2e10\u2e16\u6228r\xf2\u1a86\u0200;efm\u2df7\u2df8\u2e02\u2e05\u6a5dr\u0100;o\u2dfe\u2dff\u6134f\xbb\u2dff\u803b\xaa\u40aa\u803b\xba\u40bagof;\u62b6r;\u6a56lope;\u6a57;\u6a5b\u0180clo\u2e1f\u2e21\u2e27\xf2\u2e01ash\u803b\xf8\u40f8l;\u6298i\u016c\u2e2f\u2e34de\u803b\xf5\u40f5es\u0100;a\u01db\u2e3as;\u6a36ml\u803b\xf6\u40f6bar;\u633d\u0ae1\u2e5e\0\u2e7d\0\u2e80\u2e9d\0\u2ea2\u2eb9\0\0\u2ecb\u0e9c\0\u2f13\0\0\u2f2b\u2fbc\0\u2fc8r\u0200;ast\u0403\u2e67\u2e72\u0e85\u8100\xb6;l\u2e6d\u2e6e\u40b6le\xec\u0403\u0269\u2e78\0\0\u2e7bm;\u6af3;\u6afdy;\u443fr\u0280cimpt\u2e8b\u2e8f\u2e93\u1865\u2e97nt;\u4025od;\u402eil;\u6030enk;\u6031r;\uc000\ud835\udd2d\u0180imo\u2ea8\u2eb0\u2eb4\u0100;v\u2ead\u2eae\u43c6;\u43d5ma\xf4\u0a76ne;\u660e\u0180;tv\u2ebf\u2ec0\u2ec8\u43c0chfork\xbb\u1ffd;\u43d6\u0100au\u2ecf\u2edfn\u0100ck\u2ed5\u2eddk\u0100;h\u21f4\u2edb;\u610e\xf6\u21f4s\u0480;abcdemst\u2ef3\u2ef4\u1908\u2ef9\u2efd\u2f04\u2f06\u2f0a\u2f0e\u402bcir;\u6a23ir;\u6a22\u0100ou\u1d40\u2f02;\u6a25;\u6a72n\u80bb\xb1\u0e9dim;\u6a26wo;\u6a27\u0180ipu\u2f19\u2f20\u2f25ntint;\u6a15f;\uc000\ud835\udd61nd\u803b\xa3\u40a3\u0500;Eaceinosu\u0ec8\u2f3f\u2f41\u2f44\u2f47\u2f81\u2f89\u2f92\u2f7e\u2fb6;\u6ab3p;\u6ab7u\xe5\u0ed9\u0100;c\u0ece\u2f4c\u0300;acens\u0ec8\u2f59\u2f5f\u2f66\u2f68\u2f7eppro\xf8\u2f43urlye\xf1\u0ed9\xf1\u0ece\u0180aes\u2f6f\u2f76\u2f7approx;\u6ab9qq;\u6ab5im;\u62e8i\xed\u0edfme\u0100;s\u2f88\u0eae\u6032\u0180Eas\u2f78\u2f90\u2f7a\xf0\u2f75\u0180dfp\u0eec\u2f99\u2faf\u0180als\u2fa0\u2fa5\u2faalar;\u632eine;\u6312urf;\u6313\u0100;t\u0efb\u2fb4\xef\u0efbrel;\u62b0\u0100ci\u2fc0\u2fc5r;\uc000\ud835\udcc5;\u43c8ncsp;\u6008\u0300fiopsu\u2fda\u22e2\u2fdf\u2fe5\u2feb\u2ff1r;\uc000\ud835\udd2epf;\uc000\ud835\udd62rime;\u6057cr;\uc000\ud835\udcc6\u0180aeo\u2ff8\u3009\u3013t\u0100ei\u2ffe\u3005rnion\xf3\u06b0nt;\u6a16st\u0100;e\u3010\u3011\u403f\xf1\u1f19\xf4\u0f14\u0a80ABHabcdefhilmnoprstux\u3040\u3051\u3055\u3059\u30e0\u310e\u312b\u3147\u3162\u3172\u318e\u3206\u3215\u3224\u3229\u3258\u326e\u3272\u3290\u32b0\u32b7\u0180art\u3047\u304a\u304cr\xf2\u10b3\xf2\u03ddail;\u691car\xf2\u1c65ar;\u6964\u0380cdenqrt\u3068\u3075\u3078\u307f\u308f\u3094\u30cc\u0100eu\u306d\u3071;\uc000\u223d\u0331te;\u4155i\xe3\u116emptyv;\u69b3g\u0200;del\u0fd1\u3089\u308b\u308d;\u6992;\u69a5\xe5\u0fd1uo\u803b\xbb\u40bbr\u0580;abcfhlpstw\u0fdc\u30ac\u30af\u30b7\u30b9\u30bc\u30be\u30c0\u30c3\u30c7\u30cap;\u6975\u0100;f\u0fe0\u30b4s;\u6920;\u6933s;\u691e\xeb\u225d\xf0\u272el;\u6945im;\u6974l;\u61a3;\u619d\u0100ai\u30d1\u30d5il;\u691ao\u0100;n\u30db\u30dc\u6236al\xf3\u0f1e\u0180abr\u30e7\u30ea\u30eer\xf2\u17e5rk;\u6773\u0100ak\u30f3\u30fdc\u0100ek\u30f9\u30fb;\u407d;\u405d\u0100es\u3102\u3104;\u698cl\u0100du\u310a\u310c;\u698e;\u6990\u0200aeuy\u3117\u311c\u3127\u3129ron;\u4159\u0100di\u3121\u3125il;\u4157\xec\u0ff2\xe2\u30fa;\u4440\u0200clqs\u3134\u3137\u313d\u3144a;\u6937dhar;\u6969uo\u0100;r\u020e\u020dh;\u61b3\u0180acg\u314e\u315f\u0f44l\u0200;ips\u0f78\u3158\u315b\u109cn\xe5\u10bbar\xf4\u0fa9t;\u65ad\u0180ilr\u3169\u1023\u316esht;\u697d;\uc000\ud835\udd2f\u0100ao\u3177\u3186r\u0100du\u317d\u317f\xbb\u047b\u0100;l\u1091\u3184;\u696c\u0100;v\u318b\u318c\u43c1;\u43f1\u0180gns\u3195\u31f9\u31fcht\u0300ahlrst\u31a4\u31b0\u31c2\u31d8\u31e4\u31eerrow\u0100;t\u0fdc\u31ada\xe9\u30c8arpoon\u0100du\u31bb\u31bfow\xee\u317ep\xbb\u1092eft\u0100ah\u31ca\u31d0rrow\xf3\u0feaarpoon\xf3\u0551ightarrows;\u61c9quigarro\xf7\u30cbhreetimes;\u62ccg;\u42daingdotse\xf1\u1f32\u0180ahm\u320d\u3210\u3213r\xf2\u0feaa\xf2\u0551;\u600foust\u0100;a\u321e\u321f\u63b1che\xbb\u321fmid;\u6aee\u0200abpt\u3232\u323d\u3240\u3252\u0100nr\u3237\u323ag;\u67edr;\u61fer\xeb\u1003\u0180afl\u3247\u324a\u324er;\u6986;\uc000\ud835\udd63us;\u6a2eimes;\u6a35\u0100ap\u325d\u3267r\u0100;g\u3263\u3264\u4029t;\u6994olint;\u6a12ar\xf2\u31e3\u0200achq\u327b\u3280\u10bc\u3285quo;\u603ar;\uc000\ud835\udcc7\u0100bu\u30fb\u328ao\u0100;r\u0214\u0213\u0180hir\u3297\u329b\u32a0re\xe5\u31f8mes;\u62cai\u0200;efl\u32aa\u1059\u1821\u32ab\u65b9tri;\u69celuhar;\u6968;\u611e\u0d61\u32d5\u32db\u32df\u332c\u3338\u3371\0\u337a\u33a4\0\0\u33ec\u33f0\0\u3428\u3448\u345a\u34ad\u34b1\u34ca\u34f1\0\u3616\0\0\u3633cute;\u415bqu\xef\u27ba\u0500;Eaceinpsy\u11ed\u32f3\u32f5\u32ff\u3302\u330b\u330f\u331f\u3326\u3329;\u6ab4\u01f0\u32fa\0\u32fc;\u6ab8on;\u4161u\xe5\u11fe\u0100;d\u11f3\u3307il;\u415frc;\u415d\u0180Eas\u3316\u3318\u331b;\u6ab6p;\u6abaim;\u62e9olint;\u6a13i\xed\u1204;\u4441ot\u0180;be\u3334\u1d47\u3335\u62c5;\u6a66\u0380Aacmstx\u3346\u334a\u3357\u335b\u335e\u3363\u336drr;\u61d8r\u0100hr\u3350\u3352\xeb\u2228\u0100;o\u0a36\u0a34t\u803b\xa7\u40a7i;\u403bwar;\u6929m\u0100in\u3369\xf0nu\xf3\xf1t;\u6736r\u0100;o\u3376\u2055\uc000\ud835\udd30\u0200acoy\u3382\u3386\u3391\u33a0rp;\u666f\u0100hy\u338b\u338fcy;\u4449;\u4448rt\u026d\u3399\0\0\u339ci\xe4\u1464ara\xec\u2e6f\u803b\xad\u40ad\u0100gm\u33a8\u33b4ma\u0180;fv\u33b1\u33b2\u33b2\u43c3;\u43c2\u0400;deglnpr\u12ab\u33c5\u33c9\u33ce\u33d6\u33de\u33e1\u33e6ot;\u6a6a\u0100;q\u12b1\u12b0\u0100;E\u33d3\u33d4\u6a9e;\u6aa0\u0100;E\u33db\u33dc\u6a9d;\u6a9fe;\u6246lus;\u6a24arr;\u6972ar\xf2\u113d\u0200aeit\u33f8\u3408\u340f\u3417\u0100ls\u33fd\u3404lsetm\xe9\u336ahp;\u6a33parsl;\u69e4\u0100dl\u1463\u3414e;\u6323\u0100;e\u341c\u341d\u6aaa\u0100;s\u3422\u3423\u6aac;\uc000\u2aac\ufe00\u0180flp\u342e\u3433\u3442tcy;\u444c\u0100;b\u3438\u3439\u402f\u0100;a\u343e\u343f\u69c4r;\u633ff;\uc000\ud835\udd64a\u0100dr\u344d\u0402es\u0100;u\u3454\u3455\u6660it\xbb\u3455\u0180csu\u3460\u3479\u349f\u0100au\u3465\u346fp\u0100;s\u1188\u346b;\uc000\u2293\ufe00p\u0100;s\u11b4\u3475;\uc000\u2294\ufe00u\u0100bp\u347f\u348f\u0180;es\u1197\u119c\u3486et\u0100;e\u1197\u348d\xf1\u119d\u0180;es\u11a8\u11ad\u3496et\u0100;e\u11a8\u349d\xf1\u11ae\u0180;af\u117b\u34a6\u05b0r\u0165\u34ab\u05b1\xbb\u117car\xf2\u1148\u0200cemt\u34b9\u34be\u34c2\u34c5r;\uc000\ud835\udcc8tm\xee\xf1i\xec\u3415ar\xe6\u11be\u0100ar\u34ce\u34d5r\u0100;f\u34d4\u17bf\u6606\u0100an\u34da\u34edight\u0100ep\u34e3\u34eapsilo\xee\u1ee0h\xe9\u2eafs\xbb\u2852\u0280bcmnp\u34fb\u355e\u1209\u358b\u358e\u0480;Edemnprs\u350e\u350f\u3511\u3515\u351e\u3523\u352c\u3531\u3536\u6282;\u6ac5ot;\u6abd\u0100;d\u11da\u351aot;\u6ac3ult;\u6ac1\u0100Ee\u3528\u352a;\u6acb;\u628alus;\u6abfarr;\u6979\u0180eiu\u353d\u3552\u3555t\u0180;en\u350e\u3545\u354bq\u0100;q\u11da\u350feq\u0100;q\u352b\u3528m;\u6ac7\u0100bp\u355a\u355c;\u6ad5;\u6ad3c\u0300;acens\u11ed\u356c\u3572\u3579\u357b\u3326ppro\xf8\u32faurlye\xf1\u11fe\xf1\u11f3\u0180aes\u3582\u3588\u331bppro\xf8\u331aq\xf1\u3317g;\u666a\u0680123;Edehlmnps\u35a9\u35ac\u35af\u121c\u35b2\u35b4\u35c0\u35c9\u35d5\u35da\u35df\u35e8\u35ed\u803b\xb9\u40b9\u803b\xb2\u40b2\u803b\xb3\u40b3;\u6ac6\u0100os\u35b9\u35bct;\u6abeub;\u6ad8\u0100;d\u1222\u35c5ot;\u6ac4s\u0100ou\u35cf\u35d2l;\u67c9b;\u6ad7arr;\u697bult;\u6ac2\u0100Ee\u35e4\u35e6;\u6acc;\u628blus;\u6ac0\u0180eiu\u35f4\u3609\u360ct\u0180;en\u121c\u35fc\u3602q\u0100;q\u1222\u35b2eq\u0100;q\u35e7\u35e4m;\u6ac8\u0100bp\u3611\u3613;\u6ad4;\u6ad6\u0180Aan\u361c\u3620\u362drr;\u61d9r\u0100hr\u3626\u3628\xeb\u222e\u0100;o\u0a2b\u0a29war;\u692alig\u803b\xdf\u40df\u0be1\u3651\u365d\u3660\u12ce\u3673\u3679\0\u367e\u36c2\0\0\0\0\0\u36db\u3703\0\u3709\u376c\0\0\0\u3787\u0272\u3656\0\0\u365bget;\u6316;\u43c4r\xeb\u0e5f\u0180aey\u3666\u366b\u3670ron;\u4165dil;\u4163;\u4442lrec;\u6315r;\uc000\ud835\udd31\u0200eiko\u3686\u369d\u36b5\u36bc\u01f2\u368b\0\u3691e\u01004f\u1284\u1281a\u0180;sv\u3698\u3699\u369b\u43b8ym;\u43d1\u0100cn\u36a2\u36b2k\u0100as\u36a8\u36aeppro\xf8\u12c1im\xbb\u12acs\xf0\u129e\u0100as\u36ba\u36ae\xf0\u12c1rn\u803b\xfe\u40fe\u01ec\u031f\u36c6\u22e7es\u8180\xd7;bd\u36cf\u36d0\u36d8\u40d7\u0100;a\u190f\u36d5r;\u6a31;\u6a30\u0180eps\u36e1\u36e3\u3700\xe1\u2a4d\u0200;bcf\u0486\u36ec\u36f0\u36f4ot;\u6336ir;\u6af1\u0100;o\u36f9\u36fc\uc000\ud835\udd65rk;\u6ada\xe1\u3362rime;\u6034\u0180aip\u370f\u3712\u3764d\xe5\u1248\u0380adempst\u3721\u374d\u3740\u3751\u3757\u375c\u375fngle\u0280;dlqr\u3730\u3731\u3736\u3740\u3742\u65b5own\xbb\u1dbbeft\u0100;e\u2800\u373e\xf1\u092e;\u625cight\u0100;e\u32aa\u374b\xf1\u105aot;\u65ecinus;\u6a3alus;\u6a39b;\u69cdime;\u6a3bezium;\u63e2\u0180cht\u3772\u377d\u3781\u0100ry\u3777\u377b;\uc000\ud835\udcc9;\u4446cy;\u445brok;\u4167\u0100io\u378b\u378ex\xf4\u1777head\u0100lr\u3797\u37a0eftarro\xf7\u084fightarrow\xbb\u0f5d\u0900AHabcdfghlmoprstuw\u37d0\u37d3\u37d7\u37e4\u37f0\u37fc\u380e\u381c\u3823\u3834\u3851\u385d\u386b\u38a9\u38cc\u38d2\u38ea\u38f6r\xf2\u03edar;\u6963\u0100cr\u37dc\u37e2ute\u803b\xfa\u40fa\xf2\u1150r\u01e3\u37ea\0\u37edy;\u445eve;\u416d\u0100iy\u37f5\u37farc\u803b\xfb\u40fb;\u4443\u0180abh\u3803\u3806\u380br\xf2\u13adlac;\u4171a\xf2\u13c3\u0100ir\u3813\u3818sht;\u697e;\uc000\ud835\udd32rave\u803b\xf9\u40f9\u0161\u3827\u3831r\u0100lr\u382c\u382e\xbb\u0957\xbb\u1083lk;\u6580\u0100ct\u3839\u384d\u026f\u383f\0\0\u384arn\u0100;e\u3845\u3846\u631cr\xbb\u3846op;\u630fri;\u65f8\u0100al\u3856\u385acr;\u416b\u80bb\xa8\u0349\u0100gp\u3862\u3866on;\u4173f;\uc000\ud835\udd66\u0300adhlsu\u114b\u3878\u387d\u1372\u3891\u38a0own\xe1\u13b3arpoon\u0100lr\u3888\u388cef\xf4\u382digh\xf4\u382fi\u0180;hl\u3899\u389a\u389c\u43c5\xbb\u13faon\xbb\u389aparrows;\u61c8\u0180cit\u38b0\u38c4\u38c8\u026f\u38b6\0\0\u38c1rn\u0100;e\u38bc\u38bd\u631dr\xbb\u38bdop;\u630eng;\u416fri;\u65f9cr;\uc000\ud835\udcca\u0180dir\u38d9\u38dd\u38e2ot;\u62f0lde;\u4169i\u0100;f\u3730\u38e8\xbb\u1813\u0100am\u38ef\u38f2r\xf2\u38a8l\u803b\xfc\u40fcangle;\u69a7\u0780ABDacdeflnoprsz\u391c\u391f\u3929\u392d\u39b5\u39b8\u39bd\u39df\u39e4\u39e8\u39f3\u39f9\u39fd\u3a01\u3a20r\xf2\u03f7ar\u0100;v\u3926\u3927\u6ae8;\u6ae9as\xe8\u03e1\u0100nr\u3932\u3937grt;\u699c\u0380eknprst\u34e3\u3946\u394b\u3952\u395d\u3964\u3996app\xe1\u2415othin\xe7\u1e96\u0180hir\u34eb\u2ec8\u3959op\xf4\u2fb5\u0100;h\u13b7\u3962\xef\u318d\u0100iu\u3969\u396dgm\xe1\u33b3\u0100bp\u3972\u3984setneq\u0100;q\u397d\u3980\uc000\u228a\ufe00;\uc000\u2acb\ufe00setneq\u0100;q\u398f\u3992\uc000\u228b\ufe00;\uc000\u2acc\ufe00\u0100hr\u399b\u399fet\xe1\u369ciangle\u0100lr\u39aa\u39afeft\xbb\u0925ight\xbb\u1051y;\u4432ash\xbb\u1036\u0180elr\u39c4\u39d2\u39d7\u0180;be\u2dea\u39cb\u39cfar;\u62bbq;\u625alip;\u62ee\u0100bt\u39dc\u1468a\xf2\u1469r;\uc000\ud835\udd33tr\xe9\u39aesu\u0100bp\u39ef\u39f1\xbb\u0d1c\xbb\u0d59pf;\uc000\ud835\udd67ro\xf0\u0efbtr\xe9\u39b4\u0100cu\u3a06\u3a0br;\uc000\ud835\udccb\u0100bp\u3a10\u3a18n\u0100Ee\u3980\u3a16\xbb\u397en\u0100Ee\u3992\u3a1e\xbb\u3990igzag;\u699a\u0380cefoprs\u3a36\u3a3b\u3a56\u3a5b\u3a54\u3a61\u3a6airc;\u4175\u0100di\u3a40\u3a51\u0100bg\u3a45\u3a49ar;\u6a5fe\u0100;q\u15fa\u3a4f;\u6259erp;\u6118r;\uc000\ud835\udd34pf;\uc000\ud835\udd68\u0100;e\u1479\u3a66at\xe8\u1479cr;\uc000\ud835\udccc\u0ae3\u178e\u3a87\0\u3a8b\0\u3a90\u3a9b\0\0\u3a9d\u3aa8\u3aab\u3aaf\0\0\u3ac3\u3ace\0\u3ad8\u17dc\u17dftr\xe9\u17d1r;\uc000\ud835\udd35\u0100Aa\u3a94\u3a97r\xf2\u03c3r\xf2\u09f6;\u43be\u0100Aa\u3aa1\u3aa4r\xf2\u03b8r\xf2\u09eba\xf0\u2713is;\u62fb\u0180dpt\u17a4\u3ab5\u3abe\u0100fl\u3aba\u17a9;\uc000\ud835\udd69im\xe5\u17b2\u0100Aa\u3ac7\u3acar\xf2\u03cer\xf2\u0a01\u0100cq\u3ad2\u17b8r;\uc000\ud835\udccd\u0100pt\u17d6\u3adcr\xe9\u17d4\u0400acefiosu\u3af0\u3afd\u3b08\u3b0c\u3b11\u3b15\u3b1b\u3b21c\u0100uy\u3af6\u3afbte\u803b\xfd\u40fd;\u444f\u0100iy\u3b02\u3b06rc;\u4177;\u444bn\u803b\xa5\u40a5r;\uc000\ud835\udd36cy;\u4457pf;\uc000\ud835\udd6acr;\uc000\ud835\udcce\u0100cm\u3b26\u3b29y;\u444el\u803b\xff\u40ff\u0500acdefhiosw\u3b42\u3b48\u3b54\u3b58\u3b64\u3b69\u3b6d\u3b74\u3b7a\u3b80cute;\u417a\u0100ay\u3b4d\u3b52ron;\u417e;\u4437ot;\u417c\u0100et\u3b5d\u3b61tr\xe6\u155fa;\u43b6r;\uc000\ud835\udd37cy;\u4436grarr;\u61ddpf;\uc000\ud835\udd6bcr;\uc000\ud835\udccf\u0100jn\u3b85\u3b87;\u600dj;\u600c'.split("").map(e=>e.charCodeAt(0))),N=new Uint16Array("\u0200aglq\t\x15\x18\x1b\u026d\x0f\0\0\x12p;\u4026os;\u4027t;\u403et;\u403cuot;\u4022".split("").map(e=>e.charCodeAt(0)));var L;const O=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]),B=null!==(L=String.fromCodePoint)&&void 0!==L?L:function(e){let t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|1023&e),t+=String.fromCharCode(e),t};function $(e){var t;return e>=55296&&e<=57343||e>1114111?65533:null!==(t=O.get(e))&&void 0!==t?t:e}var z;!function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"}(z||(z={}));var j,U,H;function V(e){return e>=z.ZERO&&e<=z.NINE}function q(e){return e>=z.UPPER_A&&e<=z.UPPER_F||e>=z.LOWER_A&&e<=z.LOWER_F}function W(e){return e===z.EQUALS||function(e){return e>=z.UPPER_A&&e<=z.UPPER_Z||e>=z.LOWER_A&&e<=z.LOWER_Z||V(e)}(e)}!function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"}(j||(j={})),function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"}(U||(U={})),function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"}(H||(H={}));class G{constructor(e,t,n){this.decodeTree=e,this.emitCodePoint=t,this.errors=n,this.state=U.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=H.Strict}startEntity(e){this.decodeMode=e,this.state=U.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(e,t){switch(this.state){case U.EntityStart:return e.charCodeAt(t)===z.NUM?(this.state=U.NumericStart,this.consumed+=1,this.stateNumericStart(e,t+1)):(this.state=U.NamedEntity,this.stateNamedEntity(e,t));case U.NumericStart:return this.stateNumericStart(e,t);case U.NumericDecimal:return this.stateNumericDecimal(e,t);case U.NumericHex:return this.stateNumericHex(e,t);case U.NamedEntity:return this.stateNamedEntity(e,t)}}stateNumericStart(e,t){return t>=e.length?-1:(32|e.charCodeAt(t))===z.LOWER_X?(this.state=U.NumericHex,this.consumed+=1,this.stateNumericHex(e,t+1)):(this.state=U.NumericDecimal,this.stateNumericDecimal(e,t))}addToNumericResult(e,t,n,r){if(t!==n){const i=n-t;this.result=this.result*Math.pow(r,i)+parseInt(e.substr(t,i),r),this.consumed+=i}}stateNumericHex(e,t){const n=t;for(;t<e.length;){const r=e.charCodeAt(t);if(!V(r)&&!q(r))return this.addToNumericResult(e,n,t,16),this.emitNumericEntity(r,3);t+=1}return this.addToNumericResult(e,n,t,16),-1}stateNumericDecimal(e,t){const n=t;for(;t<e.length;){const r=e.charCodeAt(t);if(!V(r))return this.addToNumericResult(e,n,t,10),this.emitNumericEntity(r,2);t+=1}return this.addToNumericResult(e,n,t,10),-1}emitNumericEntity(e,t){var n;if(this.consumed<=t)return null===(n=this.errors)||void 0===n||n.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(e===z.SEMI)this.consumed+=1;else if(this.decodeMode===H.Strict)return 0;return this.emitCodePoint($(this.result),this.consumed),this.errors&&(e!==z.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(e,t){const{decodeTree:n}=this;let r=n[this.treeIndex],i=(r&j.VALUE_LENGTH)>>14;for(;t<e.length;t++,this.excess++){const s=e.charCodeAt(t);if(this.treeIndex=X(n,r,this.treeIndex+Math.max(1,i),s),this.treeIndex<0)return 0===this.result||this.decodeMode===H.Attribute&&(0===i||W(s))?0:this.emitNotTerminatedNamedEntity();if(r=n[this.treeIndex],i=(r&j.VALUE_LENGTH)>>14,0!==i){if(s===z.SEMI)return this.emitNamedEntityData(this.treeIndex,i,this.consumed+this.excess);this.decodeMode!==H.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var e;const{result:t,decodeTree:n}=this,r=(n[t]&j.VALUE_LENGTH)>>14;return this.emitNamedEntityData(t,r,this.consumed),null===(e=this.errors)||void 0===e||e.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(e,t,n){const{decodeTree:r}=this;return this.emitCodePoint(1===t?r[e]&~j.VALUE_LENGTH:r[e+1],n),3===t&&this.emitCodePoint(r[e+2],n),n}end(){var e;switch(this.state){case U.NamedEntity:return 0===this.result||this.decodeMode===H.Attribute&&this.result!==this.treeIndex?0:this.emitNotTerminatedNamedEntity();case U.NumericDecimal:return this.emitNumericEntity(0,2);case U.NumericHex:return this.emitNumericEntity(0,3);case U.NumericStart:return null===(e=this.errors)||void 0===e||e.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case U.EntityStart:return 0}}}function K(e){let t="";const n=new G(e,e=>t+=B(e));return function(e,r){let i=0,s=0;for(;(s=e.indexOf("&",s))>=0;){t+=e.slice(i,s),n.startEntity(r);const a=n.write(e,s+1);if(a<0){i=s+n.end();break}i=s+a,s=0===a?i+1:i}const a=t+e.slice(i);return t="",a}}function X(e,t,n,r){const i=(t&j.BRANCH_LENGTH)>>7,s=t&j.JUMP_TABLE;if(0===i)return 0!==s&&r===s?n:-1;if(s){const t=r-s;return t<0||t>=i?-1:e[n+t]-1}let a=n,o=a+i-1;for(;a<=o;){const t=a+o>>>1,n=e[t];if(n<r)a=t+1;else{if(!(n>r))return e[t+i];o=t-1}}return-1}const Y=K(R);K(N);function Z(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:H.Legacy;return Y(e,t)}function J(e){for(let t=1;t<e.length;t++)e[t][0]+=e[t-1][0]+1;return e}new Map(J([[9,"	"],[0,"
"],[22,"!"],[0,"""],[0,"#"],[0,"$"],[0,"%"],[0,"&"],[0,"'"],[0,"("],[0,")"],[0,"*"],[0,"+"],[0,","],[1,"."],[0,"/"],[10,":"],[0,";"],[0,{v:"<",n:8402,o:"<⃒"}],[0,{v:"=",n:8421,o:"=⃥"}],[0,{v:">",n:8402,o:">⃒"}],[0,"?"],[0,"@"],[26,"["],[0,"\"],[0,"]"],[0,"^"],[0,"_"],[0,"`"],[5,{n:106,o:"fj"}],[20,"{"],[0,"|"],[0,"}"],[34," "],[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,"Ā"],[0,"ā"],[0,"Ă"],[0,"ă"],[0,"Ą"],[0,"ą"],[0,"Ć"],[0,"ć"],[0,"Ĉ"],[0,"ĉ"],[0,"Ċ"],[0,"ċ"],[0,"Č"],[0,"č"],[0,"Ď"],[0,"ď"],[0,"Đ"],[0,"đ"],[0,"Ē"],[0,"ē"],[2,"Ė"],[0,"ė"],[0,"Ę"],[0,"ę"],[0,"Ě"],[0,"ě"],[0,"Ĝ"],[0,"ĝ"],[0,"Ğ"],[0,"ğ"],[0,"Ġ"],[0,"ġ"],[0,"Ģ"],[1,"Ĥ"],[0,"ĥ"],[0,"Ħ"],[0,"ħ"],[0,"Ĩ"],[0,"ĩ"],[0,"Ī"],[0,"ī"],[2,"Į"],[0,"į"],[0,"İ"],[0,"ı"],[0,"IJ"],[0,"ij"],[0,"Ĵ"],[0,"ĵ"],[0,"Ķ"],[0,"ķ"],[0,"ĸ"],[0,"Ĺ"],[0,"ĺ"],[0,"Ļ"],[0,"ļ"],[0,"Ľ"],[0,"ľ"],[0,"Ŀ"],[0,"ŀ"],[0,"Ł"],[0,"ł"],[0,"Ń"],[0,"ń"],[0,"Ņ"],[0,"ņ"],[0,"Ň"],[0,"ň"],[0,"ʼn"],[0,"Ŋ"],[0,"ŋ"],[0,"Ō"],[0,"ō"],[2,"Ő"],[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,"ž"],[19,"ƒ"],[34,"Ƶ"],[63,"ǵ"],[65,"ȷ"],[142,"ˆ"],[0,"ˇ"],[16,"˘"],[0,"˙"],[0,"˚"],[0,"˛"],[0,"˜"],[0,"˝"],[51,"̑"],[127,"Α"],[0,"Β"],[0,"Γ"],[0,"Δ"],[0,"Ε"],[0,"Ζ"],[0,"Η"],[0,"Θ"],[0,"Ι"],[0,"Κ"],[0,"Λ"],[0,"Μ"],[0,"Ν"],[0,"Ξ"],[0,"Ο"],[0,"Π"],[0,"Ρ"],[1,"Σ"],[0,"Τ"],[0,"Υ"],[0,"Φ"],[0,"Χ"],[0,"Ψ"],[0,"Ω"],[7,"α"],[0,"β"],[0,"γ"],[0,"δ"],[0,"ε"],[0,"ζ"],[0,"η"],[0,"θ"],[0,"ι"],[0,"κ"],[0,"λ"],[0,"μ"],[0,"ν"],[0,"ξ"],[0,"ο"],[0,"π"],[0,"ρ"],[0,"ς"],[0,"σ"],[0,"τ"],[0,"υ"],[0,"φ"],[0,"χ"],[0,"ψ"],[0,"ω"],[7,"ϑ"],[0,"ϒ"],[2,"ϕ"],[0,"ϖ"],[5,"Ϝ"],[0,"ϝ"],[18,"ϰ"],[0,"ϱ"],[3,"ϵ"],[0,"϶"],[10,"Ё"],[0,"Ђ"],[0,"Ѓ"],[0,"Є"],[0,"Ѕ"],[0,"І"],[0,"Ї"],[0,"Ј"],[0,"Љ"],[0,"Њ"],[0,"Ћ"],[0,"Ќ"],[1,"Ў"],[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,"я"],[1,"ё"],[0,"ђ"],[0,"ѓ"],[0,"є"],[0,"ѕ"],[0,"і"],[0,"ї"],[0,"ј"],[0,"љ"],[0,"њ"],[0,"ћ"],[0,"ќ"],[1,"ў"],[0,"џ"],[7074," "],[0," "],[0," "],[0," "],[1," "],[0," "],[0," "],[0," "],[0,"​"],[0,"‌"],[0,"‍"],[0,"‎"],[0,"‏"],[0,"‐"],[2,"–"],[0,"—"],[0,"―"],[0,"‖"],[1,"‘"],[0,"’"],[0,"‚"],[1,"“"],[0,"”"],[0,"„"],[1,"†"],[0,"‡"],[0,"•"],[2,"‥"],[0,"…"],[9,"‰"],[0,"‱"],[0,"′"],[0,"″"],[0,"‴"],[0,"‵"],[3,"‹"],[0,"›"],[3,"‾"],[2,"⁁"],[1,"⁃"],[0,"⁄"],[10,"⁏"],[7,"⁗"],[7,{v:" ",n:8202,o:"  "}],[0,"⁠"],[0,"⁡"],[0,"⁢"],[0,"⁣"],[72,"€"],[46,"⃛"],[0,"⃜"],[37,"ℂ"],[2,"℅"],[4,"ℊ"],[0,"ℋ"],[0,"ℌ"],[0,"ℍ"],[0,"ℎ"],[0,"ℏ"],[0,"ℐ"],[0,"ℑ"],[0,"ℒ"],[0,"ℓ"],[1,"ℕ"],[0,"№"],[0,"℗"],[0,"℘"],[0,"ℙ"],[0,"ℚ"],[0,"ℛ"],[0,"ℜ"],[0,"ℝ"],[0,"℞"],[3,"™"],[1,"ℤ"],[2,"℧"],[0,"ℨ"],[0,"℩"],[2,"ℬ"],[0,"ℭ"],[1,"ℯ"],[0,"ℰ"],[0,"ℱ"],[1,"ℳ"],[0,"ℴ"],[0,"ℵ"],[0,"ℶ"],[0,"ℷ"],[0,"ℸ"],[12,"ⅅ"],[0,"ⅆ"],[0,"ⅇ"],[0,"ⅈ"],[10,"⅓"],[0,"⅔"],[0,"⅕"],[0,"⅖"],[0,"⅗"],[0,"⅘"],[0,"⅙"],[0,"⅚"],[0,"⅛"],[0,"⅜"],[0,"⅝"],[0,"⅞"],[49,"←"],[0,"↑"],[0,"→"],[0,"↓"],[0,"↔"],[0,"↕"],[0,"↖"],[0,"↗"],[0,"↘"],[0,"↙"],[0,"↚"],[0,"↛"],[1,{v:"↝",n:824,o:"↝̸"}],[0,"↞"],[0,"↟"],[0,"↠"],[0,"↡"],[0,"↢"],[0,"↣"],[0,"↤"],[0,"↥"],[0,"↦"],[0,"↧"],[1,"↩"],[0,"↪"],[0,"↫"],[0,"↬"],[0,"↭"],[0,"↮"],[1,"↰"],[0,"↱"],[0,"↲"],[0,"↳"],[1,"↵"],[0,"↶"],[0,"↷"],[2,"↺"],[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,"⇛"],[1,"⇝"],[6,"⇤"],[0,"⇥"],[15,"⇵"],[7,"⇽"],[0,"⇾"],[0,"⇿"],[0,"∀"],[0,"∁"],[0,{v:"∂",n:824,o:"∂̸"}],[0,"∃"],[0,"∄"],[0,"∅"],[1,"∇"],[0,"∈"],[0,"∉"],[1,"∋"],[0,"∌"],[2,"∏"],[0,"∐"],[0,"∑"],[0,"−"],[0,"∓"],[0,"∔"],[1,"∖"],[0,"∗"],[0,"∘"],[1,"√"],[2,"∝"],[0,"∞"],[0,"∟"],[0,{v:"∠",n:8402,o:"∠⃒"}],[0,"∡"],[0,"∢"],[0,"∣"],[0,"∤"],[0,"∥"],[0,"∦"],[0,"∧"],[0,"∨"],[0,{v:"∩",n:65024,o:"∩︀"}],[0,{v:"∪",n:65024,o:"∪︀"}],[0,"∫"],[0,"∬"],[0,"∭"],[0,"∮"],[0,"∯"],[0,"∰"],[0,"∱"],[0,"∲"],[0,"∳"],[0,"∴"],[0,"∵"],[0,"∶"],[0,"∷"],[0,"∸"],[1,"∺"],[0,"∻"],[0,{v:"∼",n:8402,o:"∼⃒"}],[0,{v:"∽",n:817,o:"∽̱"}],[0,{v:"∾",n:819,o:"∾̳"}],[0,"∿"],[0,"≀"],[0,"≁"],[0,{v:"≂",n:824,o:"≂̸"}],[0,"≃"],[0,"≄"],[0,"≅"],[0,"≆"],[0,"≇"],[0,"≈"],[0,"≉"],[0,"≊"],[0,{v:"≋",n:824,o:"≋̸"}],[0,"≌"],[0,{v:"≍",n:8402,o:"≍⃒"}],[0,{v:"≎",n:824,o:"≎̸"}],[0,{v:"≏",n:824,o:"≏̸"}],[0,{v:"≐",n:824,o:"≐̸"}],[0,"≑"],[0,"≒"],[0,"≓"],[0,"≔"],[0,"≕"],[0,"≖"],[0,"≗"],[1,"≙"],[0,"≚"],[1,"≜"],[2,"≟"],[0,"≠"],[0,{v:"≡",n:8421,o:"≡⃥"}],[0,"≢"],[1,{v:"≤",n:8402,o:"≤⃒"}],[0,{v:"≥",n:8402,o:"≥⃒"}],[0,{v:"≦",n:824,o:"≦̸"}],[0,{v:"≧",n:824,o:"≧̸"}],[0,{v:"≨",n:65024,o:"≨︀"}],[0,{v:"≩",n:65024,o:"≩︀"}],[0,{v:"≪",n:new Map(J([[824,"≪̸"],[7577,"≪⃒"]]))}],[0,{v:"≫",n:new Map(J([[824,"≫̸"],[7577,"≫⃒"]]))}],[0,"≬"],[0,"≭"],[0,"≮"],[0,"≯"],[0,"≰"],[0,"≱"],[0,"≲"],[0,"≳"],[0,"≴"],[0,"≵"],[0,"≶"],[0,"≷"],[0,"≸"],[0,"≹"],[0,"≺"],[0,"≻"],[0,"≼"],[0,"≽"],[0,"≾"],[0,{v:"≿",n:824,o:"≿̸"}],[0,"⊀"],[0,"⊁"],[0,{v:"⊂",n:8402,o:"⊂⃒"}],[0,{v:"⊃",n:8402,o:"⊃⃒"}],[0,"⊄"],[0,"⊅"],[0,"⊆"],[0,"⊇"],[0,"⊈"],[0,"⊉"],[0,{v:"⊊",n:65024,o:"⊊︀"}],[0,{v:"⊋",n:65024,o:"⊋︀"}],[1,"⊍"],[0,"⊎"],[0,{v:"⊏",n:824,o:"⊏̸"}],[0,{v:"⊐",n:824,o:"⊐̸"}],[0,"⊑"],[0,"⊒"],[0,{v:"⊓",n:65024,o:"⊓︀"}],[0,{v:"⊔",n:65024,o:"⊔︀"}],[0,"⊕"],[0,"⊖"],[0,"⊗"],[0,"⊘"],[0,"⊙"],[0,"⊚"],[0,"⊛"],[1,"⊝"],[0,"⊞"],[0,"⊟"],[0,"⊠"],[0,"⊡"],[0,"⊢"],[0,"⊣"],[0,"⊤"],[0,"⊥"],[1,"⊧"],[0,"⊨"],[0,"⊩"],[0,"⊪"],[0,"⊫"],[0,"⊬"],[0,"⊭"],[0,"⊮"],[0,"⊯"],[0,"⊰"],[1,"⊲"],[0,"⊳"],[0,{v:"⊴",n:8402,o:"⊴⃒"}],[0,{v:"⊵",n:8402,o:"⊵⃒"}],[0,"⊶"],[0,"⊷"],[0,"⊸"],[0,"⊹"],[0,"⊺"],[0,"⊻"],[1,"⊽"],[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,{v:"⋘",n:824,o:"⋘̸"}],[0,{v:"⋙",n:824,o:"⋙̸"}],[0,{v:"⋚",n:65024,o:"⋚︀"}],[0,{v:"⋛",n:65024,o:"⋛︀"}],[2,"⋞"],[0,"⋟"],[0,"⋠"],[0,"⋡"],[0,"⋢"],[0,"⋣"],[2,"⋦"],[0,"⋧"],[0,"⋨"],[0,"⋩"],[0,"⋪"],[0,"⋫"],[0,"⋬"],[0,"⋭"],[0,"⋮"],[0,"⋯"],[0,"⋰"],[0,"⋱"],[0,"⋲"],[0,"⋳"],[0,"⋴"],[0,{v:"⋵",n:824,o:"⋵̸"}],[0,"⋶"],[0,"⋷"],[1,{v:"⋹",n:824,o:"⋹̸"}],[0,"⋺"],[0,"⋻"],[0,"⋼"],[0,"⋽"],[0,"⋾"],[6,"⌅"],[0,"⌆"],[1,"⌈"],[0,"⌉"],[0,"⌊"],[0,"⌋"],[0,"⌌"],[0,"⌍"],[0,"⌎"],[0,"⌏"],[0,"⌐"],[1,"⌒"],[0,"⌓"],[1,"⌕"],[0,"⌖"],[5,"⌜"],[0,"⌝"],[0,"⌞"],[0,"⌟"],[2,"⌢"],[0,"⌣"],[9,"⌭"],[0,"⌮"],[7,"⌶"],[6,"⌽"],[1,"⌿"],[60,"⍼"],[51,"⎰"],[0,"⎱"],[2,"⎴"],[0,"⎵"],[0,"⎶"],[37,"⏜"],[0,"⏝"],[0,"⏞"],[0,"⏟"],[2,"⏢"],[4,"⏧"],[59,"␣"],[164,"Ⓢ"],[55,"─"],[1,"│"],[9,"┌"],[3,"┐"],[3,"└"],[3,"┘"],[3,"├"],[7,"┤"],[7,"┬"],[7,"┴"],[7,"┼"],[19,"═"],[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,"╬"],[19,"▀"],[3,"▄"],[3,"█"],[8,"░"],[0,"▒"],[0,"▓"],[13,"□"],[8,"▪"],[0,"▫"],[1,"▭"],[0,"▮"],[2,"▱"],[1,"△"],[0,"▴"],[0,"▵"],[2,"▸"],[0,"▹"],[3,"▽"],[0,"▾"],[0,"▿"],[2,"◂"],[0,"◃"],[6,"◊"],[0,"○"],[32,"◬"],[2,"◯"],[8,"◸"],[0,"◹"],[0,"◺"],[0,"◻"],[0,"◼"],[8,"★"],[0,"☆"],[7,"☎"],[49,"♀"],[1,"♂"],[29,"♠"],[2,"♣"],[1,"♥"],[0,"♦"],[3,"♪"],[2,"♭"],[0,"♮"],[0,"♯"],[163,"✓"],[3,"✗"],[8,"✠"],[21,"✶"],[33,"❘"],[25,"❲"],[0,"❳"],[84,"⟈"],[0,"⟉"],[28,"⟦"],[0,"⟧"],[0,"⟨"],[0,"⟩"],[0,"⟪"],[0,"⟫"],[0,"⟬"],[0,"⟭"],[7,"⟵"],[0,"⟶"],[0,"⟷"],[0,"⟸"],[0,"⟹"],[0,"⟺"],[1,"⟼"],[2,"⟿"],[258,"⤂"],[0,"⤃"],[0,"⤄"],[0,"⤅"],[6,"⤌"],[0,"⤍"],[0,"⤎"],[0,"⤏"],[0,"⤐"],[0,"⤑"],[0,"⤒"],[0,"⤓"],[2,"⤖"],[2,"⤙"],[0,"⤚"],[0,"⤛"],[0,"⤜"],[0,"⤝"],[0,"⤞"],[0,"⤟"],[0,"⤠"],[2,"⤣"],[0,"⤤"],[0,"⤥"],[0,"⤦"],[0,"⤧"],[0,"⤨"],[0,"⤩"],[0,"⤪"],[8,{v:"⤳",n:824,o:"⤳̸"}],[1,"⤵"],[0,"⤶"],[0,"⤷"],[0,"⤸"],[0,"⤹"],[2,"⤼"],[0,"⤽"],[7,"⥅"],[2,"⥈"],[0,"⥉"],[0,"⥊"],[0,"⥋"],[2,"⥎"],[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,"⥶"],[1,"⥸"],[0,"⥹"],[1,"⥻"],[0,"⥼"],[0,"⥽"],[0,"⥾"],[0,"⥿"],[5,"⦅"],[0,"⦆"],[4,"⦋"],[0,"⦌"],[0,"⦍"],[0,"⦎"],[0,"⦏"],[0,"⦐"],[0,"⦑"],[0,"⦒"],[0,"⦓"],[0,"⦔"],[0,"⦕"],[0,"⦖"],[3,"⦚"],[1,"⦜"],[0,"⦝"],[6,"⦤"],[0,"⦥"],[0,"⦦"],[0,"⦧"],[0,"⦨"],[0,"⦩"],[0,"⦪"],[0,"⦫"],[0,"⦬"],[0,"⦭"],[0,"⦮"],[0,"⦯"],[0,"⦰"],[0,"⦱"],[0,"⦲"],[0,"⦳"],[0,"⦴"],[0,"⦵"],[0,"⦶"],[0,"⦷"],[1,"⦹"],[1,"⦻"],[0,"⦼"],[1,"⦾"],[0,"⦿"],[0,"⧀"],[0,"⧁"],[0,"⧂"],[0,"⧃"],[0,"⧄"],[0,"⧅"],[3,"⧉"],[3,"⧍"],[0,"⧎"],[0,{v:"⧏",n:824,o:"⧏̸"}],[0,{v:"⧐",n:824,o:"⧐̸"}],[11,"⧜"],[0,"⧝"],[0,"⧞"],[4,"⧣"],[0,"⧤"],[0,"⧥"],[5,"⧫"],[8,"⧴"],[1,"⧶"],[9,"⨀"],[0,"⨁"],[0,"⨂"],[1,"⨄"],[1,"⨆"],[5,"⨌"],[0,"⨍"],[2,"⨐"],[0,"⨑"],[0,"⨒"],[0,"⨓"],[0,"⨔"],[0,"⨕"],[0,"⨖"],[0,"⨗"],[10,"⨢"],[0,"⨣"],[0,"⨤"],[0,"⨥"],[0,"⨦"],[0,"⨧"],[1,"⨩"],[0,"⨪"],[2,"⨭"],[0,"⨮"],[0,"⨯"],[0,"⨰"],[0,"⨱"],[1,"⨳"],[0,"⨴"],[0,"⨵"],[0,"⨶"],[0,"⨷"],[0,"⨸"],[0,"⨹"],[0,"⨺"],[0,"⨻"],[0,"⨼"],[2,"⨿"],[0,"⩀"],[1,"⩂"],[0,"⩃"],[0,"⩄"],[0,"⩅"],[0,"⩆"],[0,"⩇"],[0,"⩈"],[0,"⩉"],[0,"⩊"],[0,"⩋"],[0,"⩌"],[0,"⩍"],[2,"⩐"],[2,"⩓"],[0,"⩔"],[0,"⩕"],[0,"⩖"],[0,"⩗"],[0,"⩘"],[1,"⩚"],[0,"⩛"],[0,"⩜"],[0,"⩝"],[1,"⩟"],[6,"⩦"],[3,"⩪"],[2,{v:"⩭",n:824,o:"⩭̸"}],[0,"⩮"],[0,"⩯"],[0,{v:"⩰",n:824,o:"⩰̸"}],[0,"⩱"],[0,"⩲"],[0,"⩳"],[0,"⩴"],[0,"⩵"],[1,"⩷"],[0,"⩸"],[0,"⩹"],[0,"⩺"],[0,"⩻"],[0,"⩼"],[0,{v:"⩽",n:824,o:"⩽̸"}],[0,{v:"⩾",n:824,o:"⩾̸"}],[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,"⪚"],[2,"⪝"],[0,"⪞"],[0,"⪟"],[0,"⪠"],[0,{v:"⪡",n:824,o:"⪡̸"}],[0,{v:"⪢",n:824,o:"⪢̸"}],[1,"⪤"],[0,"⪥"],[0,"⪦"],[0,"⪧"],[0,"⪨"],[0,"⪩"],[0,"⪪"],[0,"⪫"],[0,{v:"⪬",n:65024,o:"⪬︀"}],[0,{v:"⪭",n:65024,o:"⪭︀"}],[0,"⪮"],[0,{v:"⪯",n:824,o:"⪯̸"}],[0,{v:"⪰",n:824,o:"⪰̸"}],[2,"⪳"],[0,"⪴"],[0,"⪵"],[0,"⪶"],[0,"⪷"],[0,"⪸"],[0,"⪹"],[0,"⪺"],[0,"⪻"],[0,"⪼"],[0,"⪽"],[0,"⪾"],[0,"⪿"],[0,"⫀"],[0,"⫁"],[0,"⫂"],[0,"⫃"],[0,"⫄"],[0,{v:"⫅",n:824,o:"⫅̸"}],[0,{v:"⫆",n:824,o:"⫆̸"}],[0,"⫇"],[0,"⫈"],[2,{v:"⫋",n:65024,o:"⫋︀"}],[0,{v:"⫌",n:65024,o:"⫌︀"}],[2,"⫏"],[0,"⫐"],[0,"⫑"],[0,"⫒"],[0,"⫓"],[0,"⫔"],[0,"⫕"],[0,"⫖"],[0,"⫗"],[0,"⫘"],[0,"⫙"],[0,"⫚"],[0,"⫛"],[8,"⫤"],[1,"⫦"],[0,"⫧"],[0,"⫨"],[0,"⫩"],[1,"⫫"],[0,"⫬"],[0,"⫭"],[0,"⫮"],[0,"⫯"],[0,"⫰"],[0,"⫱"],[0,"⫲"],[0,"⫳"],[9,{v:"⫽",n:8421,o:"⫽⃥"}],[44343,{n:new Map(J([[56476,"𝒜"],[1,"𝒞"],[0,"𝒟"],[2,"𝒢"],[2,"𝒥"],[0,"𝒦"],[2,"𝒩"],[0,"𝒪"],[0,"𝒫"],[0,"𝒬"],[1,"𝒮"],[0,"𝒯"],[0,"𝒰"],[0,"𝒱"],[0,"𝒲"],[0,"𝒳"],[0,"𝒴"],[0,"𝒵"],[0,"𝒶"],[0,"𝒷"],[0,"𝒸"],[0,"𝒹"],[1,"𝒻"],[1,"𝒽"],[0,"𝒾"],[0,"𝒿"],[0,"𝓀"],[0,"𝓁"],[0,"𝓂"],[0,"𝓃"],[1,"𝓅"],[0,"𝓆"],[0,"𝓇"],[0,"𝓈"],[0,"𝓉"],[0,"𝓊"],[0,"𝓋"],[0,"𝓌"],[0,"𝓍"],[0,"𝓎"],[0,"𝓏"],[52,"𝔄"],[0,"𝔅"],[1,"𝔇"],[0,"𝔈"],[0,"𝔉"],[0,"𝔊"],[2,"𝔍"],[0,"𝔎"],[0,"𝔏"],[0,"𝔐"],[0,"𝔑"],[0,"𝔒"],[0,"𝔓"],[0,"𝔔"],[1,"𝔖"],[0,"𝔗"],[0,"𝔘"],[0,"𝔙"],[0,"𝔚"],[0,"𝔛"],[0,"𝔜"],[1,"𝔞"],[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,"𝔹"],[1,"𝔻"],[0,"𝔼"],[0,"𝔽"],[0,"𝔾"],[1,"𝕀"],[0,"𝕁"],[0,"𝕂"],[0,"𝕃"],[0,"𝕄"],[1,"𝕆"],[3,"𝕊"],[0,"𝕋"],[0,"𝕌"],[0,"𝕍"],[0,"𝕎"],[0,"𝕏"],[0,"𝕐"],[1,"𝕒"],[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,"𝕫"]]))}],[8906,"ff"],[0,"fi"],[0,"fl"],[0,"ffi"],[0,"ffl"]]));const Q=new Map([[34,"""],[38,"&"],[39,"'"],[60,"<"],[62,">"]]);String.prototype.codePointAt;function ee(e,t){return function(n){let r,i=0,s="";for(;r=e.exec(n);)i!==r.index&&(s+=n.substring(i,r.index)),s+=t.get(r[0].charCodeAt(0)),i=r.index+1;return s+n.substring(i)}}ee(/[&<>'"]/g,Q),ee(/["&\u00A0]/g,new Map([[34,"""],[38,"&"],[160," "]])),ee(/[&<>\u00A0]/g,new Map([[38,"&"],[60,"<"],[62,">"],[160," "]]));var te,ne;function re(e){return"[object String]"===function(e){return Object.prototype.toString.call(e)}(e)}!function(e){e[e.XML=0]="XML",e[e.HTML=1]="HTML"}(te||(te={})),function(e){e[e.UTF8=0]="UTF8",e[e.ASCII=1]="ASCII",e[e.Extensive=2]="Extensive",e[e.Attribute=3]="Attribute",e[e.Text=4]="Text"}(ne||(ne={}));const ie=Object.prototype.hasOwnProperty;function se(e,t){return ie.call(e,t)}function ae(e){return Array.prototype.slice.call(arguments,1).forEach(function(t){if(t){if("object"!==typeof t)throw new TypeError(t+"must be object");Object.keys(t).forEach(function(n){e[n]=t[n]})}}),e}function oe(e,t,n){return[].concat(e.slice(0,t),n,e.slice(t+1))}function le(e){return!(e>=55296&&e<=57343)&&(!(e>=64976&&e<=65007)&&(65535!==(65535&e)&&65534!==(65535&e)&&(!(e>=0&&e<=8)&&(11!==e&&(!(e>=14&&e<=31)&&(!(e>=127&&e<=159)&&!(e>1114111)))))))}function ce(e){if(e>65535){const t=55296+((e-=65536)>>10),n=56320+(1023&e);return String.fromCharCode(t,n)}return String.fromCharCode(e)}const he=/\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g,de=new RegExp(he.source+"|"+/&([a-z#][a-z0-9]{1,31});/gi.source,"gi"),ue=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))$/i;function pe(e){return e.indexOf("\\")<0?e:e.replace(he,"$1")}function fe(e){return e.indexOf("\\")<0&&e.indexOf("&")<0?e:e.replace(de,function(e,t,n){return t||function(e,t){if(35===t.charCodeAt(0)&&ue.test(t)){const n="x"===t[1].toLowerCase()?parseInt(t.slice(2),16):parseInt(t.slice(1),10);return le(n)?ce(n):e}const n=Z(e);return n!==e?n:e}(e,n)})}const me=/[&<>"]/,ge=/[&<>"]/g,ve={"&":"&","<":"<",">":">",'"':"""};function ye(e){return ve[e]}function be(e){return me.test(e)?e.replace(ge,ye):e}const we=/[.?*+^$[\]\\(){}|-]/g;function _e(e){return e.replace(we,"\\$&")}function Ae(e){switch(e){case 9:case 32:return!0}return!1}function xe(e){if(e>=8192&&e<=8202)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1}function Ee(e){return T.test(e)||D.test(e)}function Ce(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}}function ke(e){return e=e.trim().replace(/\s+/g," "),"\u1e7e"==="\u1e9e".toLowerCase()&&(e=e.replace(/\u1e9e/g,"\xdf")),e.toLowerCase().toUpperCase()}const Se={mdurl:r,ucmicro:i};function Te(e,t,n){let r,i,s,a;const o=e.posMax,l=e.pos;for(e.pos=t+1,r=1;e.pos<o;){if(s=e.src.charCodeAt(e.pos),93===s&&(r--,0===r)){i=!0;break}if(a=e.pos,e.md.inline.skipToken(e),91===s)if(a===e.pos-1)r++;else if(n)return e.pos=l,-1}let c=-1;return i&&(c=e.pos),e.pos=l,c}function De(e,t,n){let r,i=t;const s={ok:!1,pos:0,str:""};if(60===e.charCodeAt(i)){for(i++;i<n;){if(r=e.charCodeAt(i),10===r)return s;if(60===r)return s;if(62===r)return s.pos=i+1,s.str=fe(e.slice(t+1,i)),s.ok=!0,s;92===r&&i+1<n?i+=2:i++}return s}let a=0;for(;i<n&&(r=e.charCodeAt(i),32!==r)&&!(r<32||127===r);)if(92===r&&i+1<n){if(32===e.charCodeAt(i+1))break;i+=2}else{if(40===r&&(a++,a>32))return s;if(41===r){if(0===a)break;a--}i++}return t===i||0!==a||(s.str=fe(e.slice(t,i)),s.pos=i,s.ok=!0),s}function Me(e,t,n,r){let i,s=t;const a={ok:!1,can_continue:!1,pos:0,str:"",marker:0};if(r)a.str=r.str,a.marker=r.marker;else{if(s>=n)return a;let r=e.charCodeAt(s);if(34!==r&&39!==r&&40!==r)return a;t++,s++,40===r&&(r=41),a.marker=r}for(;s<n;){if(i=e.charCodeAt(s),i===a.marker)return a.pos=s+1,a.str+=fe(e.slice(t,s)),a.ok=!0,a;if(40===i&&41===a.marker)return a;92===i&&s+1<n&&s++,s++}return a.can_continue=!0,a.str+=fe(e.slice(t,s)),a}const Pe={};function Ie(){this.rules=ae({},Pe)}Pe.code_inline=function(e,t,n,r,i){const s=e[t];return"<code"+i.renderAttrs(s)+">"+be(s.content)+"</code>"},Pe.code_block=function(e,t,n,r,i){const s=e[t];return"<pre"+i.renderAttrs(s)+"><code>"+be(e[t].content)+"</code></pre>\n"},Pe.fence=function(e,t,n,r,i){const s=e[t],a=s.info?fe(s.info).trim():"";let o,l="",c="";if(a){const e=a.split(/(\s+)/g);l=e[0],c=e.slice(2).join("")}if(o=n.highlight&&n.highlight(s.content,l,c)||be(s.content),0===o.indexOf("<pre"))return o+"\n";if(a){const e=s.attrIndex("class"),t=s.attrs?s.attrs.slice():[];e<0?t.push(["class",n.langPrefix+l]):(t[e]=t[e].slice(),t[e][1]+=" "+n.langPrefix+l);const r={attrs:t};return`<pre><code${i.renderAttrs(r)}>${o}</code></pre>\n`}return`<pre><code${i.renderAttrs(s)}>${o}</code></pre>\n`},Pe.image=function(e,t,n,r,i){const s=e[t];return s.attrs[s.attrIndex("alt")][1]=i.renderInlineAsText(s.children,n,r),i.renderToken(e,t,n)},Pe.hardbreak=function(e,t,n){return n.xhtmlOut?"<br />\n":"<br>\n"},Pe.softbreak=function(e,t,n){return n.breaks?n.xhtmlOut?"<br />\n":"<br>\n":"\n"},Pe.text=function(e,t){return be(e[t].content)},Pe.html_block=function(e,t){return e[t].content},Pe.html_inline=function(e,t){return e[t].content},Ie.prototype.renderAttrs=function(e){let t,n,r;if(!e.attrs)return"";for(r="",t=0,n=e.attrs.length;t<n;t++)r+=" "+be(e.attrs[t][0])+'="'+be(e.attrs[t][1])+'"';return r},Ie.prototype.renderToken=function(e,t,n){const r=e[t];let i="";if(r.hidden)return"";r.block&&-1!==r.nesting&&t&&e[t-1].hidden&&(i+="\n"),i+=(-1===r.nesting?"</":"<")+r.tag,i+=this.renderAttrs(r),0===r.nesting&&n.xhtmlOut&&(i+=" /");let s=!1;if(r.block&&(s=!0,1===r.nesting&&t+1<e.length)){const n=e[t+1];("inline"===n.type||n.hidden||-1===n.nesting&&n.tag===r.tag)&&(s=!1)}return i+=s?">\n":">",i},Ie.prototype.renderInline=function(e,t,n){let r="";const i=this.rules;for(let s=0,a=e.length;s<a;s++){const a=e[s].type;"undefined"!==typeof i[a]?r+=i[a](e,s,t,n,this):r+=this.renderToken(e,s,t)}return r},Ie.prototype.renderInlineAsText=function(e,t,n){let r="";for(let i=0,s=e.length;i<s;i++)switch(e[i].type){case"text":case"html_inline":case"html_block":r+=e[i].content;break;case"image":r+=this.renderInlineAsText(e[i].children,t,n);break;case"softbreak":case"hardbreak":r+="\n"}return r},Ie.prototype.render=function(e,t,n){let r="";const i=this.rules;for(let s=0,a=e.length;s<a;s++){const a=e[s].type;"inline"===a?r+=this.renderInline(e[s].children,t,n):"undefined"!==typeof i[a]?r+=i[a](e,s,t,n,this):r+=this.renderToken(e,s,t,n)}return r};const Fe=Ie;function Re(){this.__rules__=[],this.__cache__=null}Re.prototype.__find__=function(e){for(let t=0;t<this.__rules__.length;t++)if(this.__rules__[t].name===e)return t;return-1},Re.prototype.__compile__=function(){const e=this,t=[""];e.__rules__.forEach(function(e){e.enabled&&e.alt.forEach(function(e){t.indexOf(e)<0&&t.push(e)})}),e.__cache__={},t.forEach(function(t){e.__cache__[t]=[],e.__rules__.forEach(function(n){n.enabled&&(t&&n.alt.indexOf(t)<0||e.__cache__[t].push(n.fn))})})},Re.prototype.at=function(e,t,n){const r=this.__find__(e),i=n||{};if(-1===r)throw new Error("Parser rule not found: "+e);this.__rules__[r].fn=t,this.__rules__[r].alt=i.alt||[],this.__cache__=null},Re.prototype.before=function(e,t,n,r){const i=this.__find__(e),s=r||{};if(-1===i)throw new Error("Parser rule not found: "+e);this.__rules__.splice(i,0,{name:t,enabled:!0,fn:n,alt:s.alt||[]}),this.__cache__=null},Re.prototype.after=function(e,t,n,r){const i=this.__find__(e),s=r||{};if(-1===i)throw new Error("Parser rule not found: "+e);this.__rules__.splice(i+1,0,{name:t,enabled:!0,fn:n,alt:s.alt||[]}),this.__cache__=null},Re.prototype.push=function(e,t,n){const r=n||{};this.__rules__.push({name:e,enabled:!0,fn:t,alt:r.alt||[]}),this.__cache__=null},Re.prototype.enable=function(e,t){Array.isArray(e)||(e=[e]);const n=[];return e.forEach(function(e){const r=this.__find__(e);if(r<0){if(t)return;throw new Error("Rules manager: invalid rule name "+e)}this.__rules__[r].enabled=!0,n.push(e)},this),this.__cache__=null,n},Re.prototype.enableOnly=function(e,t){Array.isArray(e)||(e=[e]),this.__rules__.forEach(function(e){e.enabled=!1}),this.enable(e,t)},Re.prototype.disable=function(e,t){Array.isArray(e)||(e=[e]);const n=[];return e.forEach(function(e){const r=this.__find__(e);if(r<0){if(t)return;throw new Error("Rules manager: invalid rule name "+e)}this.__rules__[r].enabled=!1,n.push(e)},this),this.__cache__=null,n},Re.prototype.getRules=function(e){return null===this.__cache__&&this.__compile__(),this.__cache__[e]||[]};const Ne=Re;function Le(e,t,n){this.type=e,this.tag=t,this.attrs=null,this.map=null,this.nesting=n,this.level=0,this.children=null,this.content="",this.markup="",this.info="",this.meta=null,this.block=!1,this.hidden=!1}Le.prototype.attrIndex=function(e){if(!this.attrs)return-1;const t=this.attrs;for(let n=0,r=t.length;n<r;n++)if(t[n][0]===e)return n;return-1},Le.prototype.attrPush=function(e){this.attrs?this.attrs.push(e):this.attrs=[e]},Le.prototype.attrSet=function(e,t){const n=this.attrIndex(e),r=[e,t];n<0?this.attrPush(r):this.attrs[n]=r},Le.prototype.attrGet=function(e){const t=this.attrIndex(e);let n=null;return t>=0&&(n=this.attrs[t][1]),n},Le.prototype.attrJoin=function(e,t){const n=this.attrIndex(e);n<0?this.attrPush([e,t]):this.attrs[n][1]=this.attrs[n][1]+" "+t};const Oe=Le;function Be(e,t,n){this.src=e,this.env=n,this.tokens=[],this.inlineMode=!1,this.md=t}Be.prototype.Token=Oe;const $e=Be,ze=/\r\n?|\n/g,je=/\0/g;function Ue(e){return/^<a[>\s]/i.test(e)}function He(e){return/^<\/a\s*>/i.test(e)}const Ve=/\+-|\.\.|\?\?\?\?|!!!!|,,|--/,qe=/\((c|tm|r)\)/i,We=/\((c|tm|r)\)/gi,Ge={c:"\xa9",r:"\xae",tm:"\u2122"};function Ke(e,t){return Ge[t.toLowerCase()]}function Xe(e){let t=0;for(let n=e.length-1;n>=0;n--){const r=e[n];"text"!==r.type||t||(r.content=r.content.replace(We,Ke)),"link_open"===r.type&&"auto"===r.info&&t--,"link_close"===r.type&&"auto"===r.info&&t++}}function Ye(e){let t=0;for(let n=e.length-1;n>=0;n--){const r=e[n];"text"!==r.type||t||Ve.test(r.content)&&(r.content=r.content.replace(/\+-/g,"\xb1").replace(/\.{2,}/g,"\u2026").replace(/([?!])\u2026/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---(?=[^-]|$)/gm,"$1\u2014").replace(/(^|\s)--(?=\s|$)/gm,"$1\u2013").replace(/(^|[^-\s])--(?=[^-\s]|$)/gm,"$1\u2013")),"link_open"===r.type&&"auto"===r.info&&t--,"link_close"===r.type&&"auto"===r.info&&t++}}const Ze=/['"]/,Je=/['"]/g;function Qe(e,t,n){return e.slice(0,t)+n+e.slice(t+1)}function et(e,t){let n;const r=[];for(let i=0;i<e.length;i++){const s=e[i],a=e[i].level;for(n=r.length-1;n>=0&&!(r[n].level<=a);n--);if(r.length=n+1,"text"!==s.type)continue;let o=s.content,l=0,c=o.length;e:for(;l<c;){Je.lastIndex=l;const h=Je.exec(o);if(!h)break;let d=!0,u=!0;l=h.index+1;const p="'"===h[0];let f=32;if(h.index-1>=0)f=o.charCodeAt(h.index-1);else for(n=i-1;n>=0&&("softbreak"!==e[n].type&&"hardbreak"!==e[n].type);n--)if(e[n].content){f=e[n].content.charCodeAt(e[n].content.length-1);break}let m=32;if(l<c)m=o.charCodeAt(l);else for(n=i+1;n<e.length&&("softbreak"!==e[n].type&&"hardbreak"!==e[n].type);n++)if(e[n].content){m=e[n].content.charCodeAt(0);break}const g=Ce(f)||Ee(String.fromCharCode(f)),v=Ce(m)||Ee(String.fromCharCode(m)),y=xe(f),b=xe(m);if(b?d=!1:v&&(y||g||(d=!1)),y?u=!1:g&&(b||v||(u=!1)),34===m&&'"'===h[0]&&f>=48&&f<=57&&(u=d=!1),d&&u&&(d=g,u=v),d||u){if(u)for(n=r.length-1;n>=0;n--){let d=r[n];if(r[n].level<a)break;if(d.single===p&&r[n].level===a){let a,u;d=r[n],p?(a=t.md.options.quotes[2],u=t.md.options.quotes[3]):(a=t.md.options.quotes[0],u=t.md.options.quotes[1]),s.content=Qe(s.content,h.index,u),e[d.token].content=Qe(e[d.token].content,d.pos,a),l+=u.length-1,d.token===i&&(l+=a.length-1),o=s.content,c=o.length,r.length=n;continue e}}d?r.push({token:i,pos:h.index,single:p,level:a}):u&&p&&(s.content=Qe(s.content,h.index,"\u2019"))}else p&&(s.content=Qe(s.content,h.index,"\u2019"))}}}const tt=[["normalize",function(e){let t;t=e.src.replace(ze,"\n"),t=t.replace(je,"\ufffd"),e.src=t}],["block",function(e){let t;e.inlineMode?(t=new e.Token("inline","",0),t.content=e.src,t.map=[0,1],t.children=[],e.tokens.push(t)):e.md.block.parse(e.src,e.md,e.env,e.tokens)}],["inline",function(e){const t=e.tokens;for(let n=0,r=t.length;n<r;n++){const r=t[n];"inline"===r.type&&e.md.inline.parse(r.content,e.md,e.env,r.children)}}],["linkify",function(e){const t=e.tokens;if(e.md.options.linkify)for(let n=0,r=t.length;n<r;n++){if("inline"!==t[n].type||!e.md.linkify.pretest(t[n].content))continue;let r=t[n].children,i=0;for(let s=r.length-1;s>=0;s--){const a=r[s];if("link_close"!==a.type){if("html_inline"===a.type&&(Ue(a.content)&&i>0&&i--,He(a.content)&&i++),!(i>0)&&"text"===a.type&&e.md.linkify.test(a.content)){const i=a.content;let o=e.md.linkify.match(i);const l=[];let c=a.level,h=0;o.length>0&&0===o[0].index&&s>0&&"text_special"===r[s-1].type&&(o=o.slice(1));for(let t=0;t<o.length;t++){const n=o[t].url,r=e.md.normalizeLink(n);if(!e.md.validateLink(r))continue;let s=o[t].text;s=o[t].schema?"mailto:"!==o[t].schema||/^mailto:/i.test(s)?e.md.normalizeLinkText(s):e.md.normalizeLinkText("mailto:"+s).replace(/^mailto:/,""):e.md.normalizeLinkText("http://"+s).replace(/^http:\/\//,"");const a=o[t].index;if(a>h){const t=new e.Token("text","",0);t.content=i.slice(h,a),t.level=c,l.push(t)}const d=new e.Token("link_open","a",1);d.attrs=[["href",r]],d.level=c++,d.markup="linkify",d.info="auto",l.push(d);const u=new e.Token("text","",0);u.content=s,u.level=c,l.push(u);const p=new e.Token("link_close","a",-1);p.level=--c,p.markup="linkify",p.info="auto",l.push(p),h=o[t].lastIndex}if(h<i.length){const t=new e.Token("text","",0);t.content=i.slice(h),t.level=c,l.push(t)}t[n].children=r=oe(r,s,l)}}else for(s--;r[s].level!==a.level&&"link_open"!==r[s].type;)s--}}}],["replacements",function(e){let t;if(e.md.options.typographer)for(t=e.tokens.length-1;t>=0;t--)"inline"===e.tokens[t].type&&(qe.test(e.tokens[t].content)&&Xe(e.tokens[t].children),Ve.test(e.tokens[t].content)&&Ye(e.tokens[t].children))}],["smartquotes",function(e){if(e.md.options.typographer)for(let t=e.tokens.length-1;t>=0;t--)"inline"===e.tokens[t].type&&Ze.test(e.tokens[t].content)&&et(e.tokens[t].children,e)}],["text_join",function(e){let t,n;const r=e.tokens,i=r.length;for(let s=0;s<i;s++){if("inline"!==r[s].type)continue;const e=r[s].children,i=e.length;for(t=0;t<i;t++)"text_special"===e[t].type&&(e[t].type="text");for(t=n=0;t<i;t++)"text"===e[t].type&&t+1<i&&"text"===e[t+1].type?e[t+1].content=e[t].content+e[t+1].content:(t!==n&&(e[n]=e[t]),n++);t!==n&&(e.length=n)}}]];function nt(){this.ruler=new Ne;for(let e=0;e<tt.length;e++)this.ruler.push(tt[e][0],tt[e][1])}nt.prototype.process=function(e){const t=this.ruler.getRules("");for(let n=0,r=t.length;n<r;n++)t[n](e)},nt.prototype.State=$e;const rt=nt;function it(e,t,n,r){this.src=e,this.md=t,this.env=n,this.tokens=r,this.bMarks=[],this.eMarks=[],this.tShift=[],this.sCount=[],this.bsCount=[],this.blkIndent=0,this.line=0,this.lineMax=0,this.tight=!1,this.ddIndent=-1,this.listIndent=-1,this.parentType="root",this.level=0;const i=this.src;for(let s=0,a=0,o=0,l=0,c=i.length,h=!1;a<c;a++){const e=i.charCodeAt(a);if(!h){if(Ae(e)){o++,9===e?l+=4-l%4:l++;continue}h=!0}10!==e&&a!==c-1||(10!==e&&a++,this.bMarks.push(s),this.eMarks.push(a),this.tShift.push(o),this.sCount.push(l),this.bsCount.push(0),h=!1,o=0,l=0,s=a+1)}this.bMarks.push(i.length),this.eMarks.push(i.length),this.tShift.push(0),this.sCount.push(0),this.bsCount.push(0),this.lineMax=this.bMarks.length-1}it.prototype.push=function(e,t,n){const r=new Oe(e,t,n);return r.block=!0,n<0&&this.level--,r.level=this.level,n>0&&this.level++,this.tokens.push(r),r},it.prototype.isEmpty=function(e){return this.bMarks[e]+this.tShift[e]>=this.eMarks[e]},it.prototype.skipEmptyLines=function(e){for(let t=this.lineMax;e<t&&!(this.bMarks[e]+this.tShift[e]<this.eMarks[e]);e++);return e},it.prototype.skipSpaces=function(e){for(let t=this.src.length;e<t;e++){if(!Ae(this.src.charCodeAt(e)))break}return e},it.prototype.skipSpacesBack=function(e,t){if(e<=t)return e;for(;e>t;)if(!Ae(this.src.charCodeAt(--e)))return e+1;return e},it.prototype.skipChars=function(e,t){for(let n=this.src.length;e<n&&this.src.charCodeAt(e)===t;e++);return e},it.prototype.skipCharsBack=function(e,t,n){if(e<=n)return e;for(;e>n;)if(t!==this.src.charCodeAt(--e))return e+1;return e},it.prototype.getLines=function(e,t,n,r){if(e>=t)return"";const i=new Array(t-e);for(let s=0,a=e;a<t;a++,s++){let e=0;const o=this.bMarks[a];let l,c=o;for(l=a+1<t||r?this.eMarks[a]+1:this.eMarks[a];c<l&&e<n;){const t=this.src.charCodeAt(c);if(Ae(t))9===t?e+=4-(e+this.bsCount[a])%4:e++;else{if(!(c-o<this.tShift[a]))break;e++}c++}i[s]=e>n?new Array(e-n+1).join(" ")+this.src.slice(c,l):this.src.slice(c,l)}return i.join("")},it.prototype.Token=Oe;const st=it;function at(e,t){const n=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];return e.src.slice(n,r)}function ot(e){const t=[],n=e.length;let r=0,i=e.charCodeAt(r),s=!1,a=0,o="";for(;r<n;)124===i&&(s?(o+=e.substring(a,r-1),a=r):(t.push(o+e.substring(a,r)),o="",a=r+1)),s=92===i,r++,i=e.charCodeAt(r);return t.push(o+e.substring(a)),t}function lt(e,t){const n=e.eMarks[t];let r=e.bMarks[t]+e.tShift[t];const i=e.src.charCodeAt(r++);if(42!==i&&45!==i&&43!==i)return-1;if(r<n){if(!Ae(e.src.charCodeAt(r)))return-1}return r}function ct(e,t){const n=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];let i=n;if(i+1>=r)return-1;let s=e.src.charCodeAt(i++);if(s<48||s>57)return-1;for(;;){if(i>=r)return-1;if(s=e.src.charCodeAt(i++),!(s>=48&&s<=57)){if(41===s||46===s)break;return-1}if(i-n>=10)return-1}return i<r&&(s=e.src.charCodeAt(i),!Ae(s))?-1:i}const ht="<[A-Za-z][A-Za-z0-9\\-]*(?:\\s+[a-zA-Z_:][a-zA-Z0-9:._-]*(?:\\s*=\\s*(?:[^\"'=<>`\\x00-\\x20]+|'[^']*'|\"[^\"]*\"))?)*\\s*\\/?>",dt="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",ut=new RegExp("^(?:"+ht+"|"+dt+"|\x3c!---?>|\x3c!--(?:[^-]|-[^-]|--[^>])*--\x3e|<[?][\\s\\S]*?[?]>|<![A-Za-z][^>]*>|<!\\[CDATA\\[[\\s\\S]*?\\]\\]>)"),pt=new RegExp("^(?:"+ht+"|"+dt+")"),ft=[[/^<(script|pre|style|textarea)(?=(\s|>|$))/i,/<\/(script|pre|style|textarea)>/i,!0],[/^<!--/,/-->/,!0],[/^<\?/,/\?>/,!0],[/^<![A-Z]/,/>/,!0],[/^<!\[CDATA\[/,/\]\]>/,!0],[new RegExp("^</?("+["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"].join("|")+")(?=(\\s|/?>|$))","i"),/^$/,!0],[new RegExp(pt.source+"\\s*$"),/^$/,!1]];const mt=[["table",function(e,t,n,r){if(t+2>n)return!1;let i=t+1;if(e.sCount[i]<e.blkIndent)return!1;if(e.sCount[i]-e.blkIndent>=4)return!1;let s=e.bMarks[i]+e.tShift[i];if(s>=e.eMarks[i])return!1;const a=e.src.charCodeAt(s++);if(124!==a&&45!==a&&58!==a)return!1;if(s>=e.eMarks[i])return!1;const o=e.src.charCodeAt(s++);if(124!==o&&45!==o&&58!==o&&!Ae(o))return!1;if(45===a&&Ae(o))return!1;for(;s<e.eMarks[i];){const t=e.src.charCodeAt(s);if(124!==t&&45!==t&&58!==t&&!Ae(t))return!1;s++}let l=at(e,t+1),c=l.split("|");const h=[];for(let v=0;v<c.length;v++){const e=c[v].trim();if(!e){if(0===v||v===c.length-1)continue;return!1}if(!/^:?-+:?$/.test(e))return!1;58===e.charCodeAt(e.length-1)?h.push(58===e.charCodeAt(0)?"center":"right"):58===e.charCodeAt(0)?h.push("left"):h.push("")}if(l=at(e,t).trim(),-1===l.indexOf("|"))return!1;if(e.sCount[t]-e.blkIndent>=4)return!1;c=ot(l),c.length&&""===c[0]&&c.shift(),c.length&&""===c[c.length-1]&&c.pop();const d=c.length;if(0===d||d!==h.length)return!1;if(r)return!0;const u=e.parentType;e.parentType="table";const p=e.md.block.ruler.getRules("blockquote"),f=[t,0];e.push("table_open","table",1).map=f,e.push("thead_open","thead",1).map=[t,t+1],e.push("tr_open","tr",1).map=[t,t+1];for(let v=0;v<c.length;v++){const t=e.push("th_open","th",1);h[v]&&(t.attrs=[["style","text-align:"+h[v]]]);const n=e.push("inline","",0);n.content=c[v].trim(),n.children=[],e.push("th_close","th",-1)}let m;e.push("tr_close","tr",-1),e.push("thead_close","thead",-1);let g=0;for(i=t+2;i<n&&!(e.sCount[i]<e.blkIndent);i++){let r=!1;for(let t=0,s=p.length;t<s;t++)if(p[t](e,i,n,!0)){r=!0;break}if(r)break;if(l=at(e,i).trim(),!l)break;if(e.sCount[i]-e.blkIndent>=4)break;if(c=ot(l),c.length&&""===c[0]&&c.shift(),c.length&&""===c[c.length-1]&&c.pop(),g+=d-c.length,g>65536)break;if(i===t+2){e.push("tbody_open","tbody",1).map=m=[t+2,0]}e.push("tr_open","tr",1).map=[i,i+1];for(let t=0;t<d;t++){const n=e.push("td_open","td",1);h[t]&&(n.attrs=[["style","text-align:"+h[t]]]);const r=e.push("inline","",0);r.content=c[t]?c[t].trim():"",r.children=[],e.push("td_close","td",-1)}e.push("tr_close","tr",-1)}return m&&(e.push("tbody_close","tbody",-1),m[1]=i),e.push("table_close","table",-1),f[1]=i,e.parentType=u,e.line=i,!0},["paragraph","reference"]],["code",function(e,t,n){if(e.sCount[t]-e.blkIndent<4)return!1;let r=t+1,i=r;for(;r<n;)if(e.isEmpty(r))r++;else{if(!(e.sCount[r]-e.blkIndent>=4))break;r++,i=r}e.line=i;const s=e.push("code_block","code",0);return s.content=e.getLines(t,i,4+e.blkIndent,!1)+"\n",s.map=[t,e.line],!0}],["fence",function(e,t,n,r){let i=e.bMarks[t]+e.tShift[t],s=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(i+3>s)return!1;const a=e.src.charCodeAt(i);if(126!==a&&96!==a)return!1;let o=i;i=e.skipChars(i,a);let l=i-o;if(l<3)return!1;const c=e.src.slice(o,i),h=e.src.slice(i,s);if(96===a&&h.indexOf(String.fromCharCode(a))>=0)return!1;if(r)return!0;let d=t,u=!1;for(;(d++,!(d>=n))&&(i=o=e.bMarks[d]+e.tShift[d],s=e.eMarks[d],!(i<s&&e.sCount[d]<e.blkIndent));)if(e.src.charCodeAt(i)===a&&!(e.sCount[d]-e.blkIndent>=4)&&(i=e.skipChars(i,a),!(i-o<l)&&(i=e.skipSpaces(i),!(i<s)))){u=!0;break}l=e.sCount[t],e.line=d+(u?1:0);const p=e.push("fence","code",0);return p.info=h,p.content=e.getLines(t+1,d,l,!0),p.markup=c,p.map=[t,e.line],!0},["paragraph","reference","blockquote","list"]],["blockquote",function(e,t,n,r){let i=e.bMarks[t]+e.tShift[t],s=e.eMarks[t];const a=e.lineMax;if(e.sCount[t]-e.blkIndent>=4)return!1;if(62!==e.src.charCodeAt(i))return!1;if(r)return!0;const o=[],l=[],c=[],h=[],d=e.md.block.ruler.getRules("blockquote"),u=e.parentType;e.parentType="blockquote";let p,f=!1;for(p=t;p<n;p++){const t=e.sCount[p]<e.blkIndent;if(i=e.bMarks[p]+e.tShift[p],s=e.eMarks[p],i>=s)break;if(62===e.src.charCodeAt(i++)&&!t){let t,n,r=e.sCount[p]+1;32===e.src.charCodeAt(i)?(i++,r++,n=!1,t=!0):9===e.src.charCodeAt(i)?(t=!0,(e.bsCount[p]+r)%4===3?(i++,r++,n=!1):n=!0):t=!1;let a=r;for(o.push(e.bMarks[p]),e.bMarks[p]=i;i<s;){const t=e.src.charCodeAt(i);if(!Ae(t))break;9===t?a+=4-(a+e.bsCount[p]+(n?1:0))%4:a++,i++}f=i>=s,l.push(e.bsCount[p]),e.bsCount[p]=e.sCount[p]+1+(t?1:0),c.push(e.sCount[p]),e.sCount[p]=a-r,h.push(e.tShift[p]),e.tShift[p]=i-e.bMarks[p];continue}if(f)break;let r=!1;for(let i=0,s=d.length;i<s;i++)if(d[i](e,p,n,!0)){r=!0;break}if(r){e.lineMax=p,0!==e.blkIndent&&(o.push(e.bMarks[p]),l.push(e.bsCount[p]),h.push(e.tShift[p]),c.push(e.sCount[p]),e.sCount[p]-=e.blkIndent);break}o.push(e.bMarks[p]),l.push(e.bsCount[p]),h.push(e.tShift[p]),c.push(e.sCount[p]),e.sCount[p]=-1}const m=e.blkIndent;e.blkIndent=0;const g=e.push("blockquote_open","blockquote",1);g.markup=">";const v=[t,0];g.map=v,e.md.block.tokenize(e,t,p),e.push("blockquote_close","blockquote",-1).markup=">",e.lineMax=a,e.parentType=u,v[1]=e.line;for(let y=0;y<h.length;y++)e.bMarks[y+t]=o[y],e.tShift[y+t]=h[y],e.sCount[y+t]=c[y],e.bsCount[y+t]=l[y];return e.blkIndent=m,!0},["paragraph","reference","blockquote","list"]],["hr",function(e,t,n,r){const i=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;let s=e.bMarks[t]+e.tShift[t];const a=e.src.charCodeAt(s++);if(42!==a&&45!==a&&95!==a)return!1;let o=1;for(;s<i;){const t=e.src.charCodeAt(s++);if(t!==a&&!Ae(t))return!1;t===a&&o++}if(o<3)return!1;if(r)return!0;e.line=t+1;const l=e.push("hr","hr",0);return l.map=[t,e.line],l.markup=Array(o+1).join(String.fromCharCode(a)),!0},["paragraph","reference","blockquote","list"]],["list",function(e,t,n,r){let i,s,a,o,l=t,c=!0;if(e.sCount[l]-e.blkIndent>=4)return!1;if(e.listIndent>=0&&e.sCount[l]-e.listIndent>=4&&e.sCount[l]<e.blkIndent)return!1;let h,d,u,p=!1;if(r&&"paragraph"===e.parentType&&e.sCount[l]>=e.blkIndent&&(p=!0),(u=ct(e,l))>=0){if(h=!0,a=e.bMarks[l]+e.tShift[l],d=Number(e.src.slice(a,u-1)),p&&1!==d)return!1}else{if(!((u=lt(e,l))>=0))return!1;h=!1}if(p&&e.skipSpaces(u)>=e.eMarks[l])return!1;if(r)return!0;const f=e.src.charCodeAt(u-1),m=e.tokens.length;h?(o=e.push("ordered_list_open","ol",1),1!==d&&(o.attrs=[["start",d]])):o=e.push("bullet_list_open","ul",1);const g=[l,0];o.map=g,o.markup=String.fromCharCode(f);let v=!1;const y=e.md.block.ruler.getRules("list"),b=e.parentType;for(e.parentType="list";l<n;){s=u,i=e.eMarks[l];const t=e.sCount[l]+u-(e.bMarks[l]+e.tShift[l]);let r=t;for(;s<i;){const t=e.src.charCodeAt(s);if(9===t)r+=4-(r+e.bsCount[l])%4;else{if(32!==t)break;r++}s++}const d=s;let p;p=d>=i?1:r-t,p>4&&(p=1);const m=t+p;o=e.push("list_item_open","li",1),o.markup=String.fromCharCode(f);const g=[l,0];o.map=g,h&&(o.info=e.src.slice(a,u-1));const b=e.tight,w=e.tShift[l],_=e.sCount[l],A=e.listIndent;if(e.listIndent=e.blkIndent,e.blkIndent=m,e.tight=!0,e.tShift[l]=d-e.bMarks[l],e.sCount[l]=r,d>=i&&e.isEmpty(l+1)?e.line=Math.min(e.line+2,n):e.md.block.tokenize(e,l,n,!0),e.tight&&!v||(c=!1),v=e.line-l>1&&e.isEmpty(e.line-1),e.blkIndent=e.listIndent,e.listIndent=A,e.tShift[l]=w,e.sCount[l]=_,e.tight=b,o=e.push("list_item_close","li",-1),o.markup=String.fromCharCode(f),l=e.line,g[1]=l,l>=n)break;if(e.sCount[l]<e.blkIndent)break;if(e.sCount[l]-e.blkIndent>=4)break;let x=!1;for(let i=0,s=y.length;i<s;i++)if(y[i](e,l,n,!0)){x=!0;break}if(x)break;if(h){if(u=ct(e,l),u<0)break;a=e.bMarks[l]+e.tShift[l]}else if(u=lt(e,l),u<0)break;if(f!==e.src.charCodeAt(u-1))break}return o=h?e.push("ordered_list_close","ol",-1):e.push("bullet_list_close","ul",-1),o.markup=String.fromCharCode(f),g[1]=l,e.line=l,e.parentType=b,c&&function(e,t){const n=e.level+2;for(let r=t+2,i=e.tokens.length-2;r<i;r++)e.tokens[r].level===n&&"paragraph_open"===e.tokens[r].type&&(e.tokens[r+2].hidden=!0,e.tokens[r].hidden=!0,r+=2)}(e,m),!0},["paragraph","reference","blockquote"]],["reference",function(e,t,n,r){let i=e.bMarks[t]+e.tShift[t],s=e.eMarks[t],a=t+1;if(e.sCount[t]-e.blkIndent>=4)return!1;if(91!==e.src.charCodeAt(i))return!1;function o(t){const n=e.lineMax;if(t>=n||e.isEmpty(t))return null;let r=!1;if(e.sCount[t]-e.blkIndent>3&&(r=!0),e.sCount[t]<0&&(r=!0),!r){const r=e.md.block.ruler.getRules("reference"),i=e.parentType;e.parentType="reference";let s=!1;for(let a=0,o=r.length;a<o;a++)if(r[a](e,t,n,!0)){s=!0;break}if(e.parentType=i,s)return null}const i=e.bMarks[t]+e.tShift[t],s=e.eMarks[t];return e.src.slice(i,s+1)}let l=e.src.slice(i,s+1);s=l.length;let c=-1;for(i=1;i<s;i++){const e=l.charCodeAt(i);if(91===e)return!1;if(93===e){c=i;break}if(10===e){const e=o(a);null!==e&&(l+=e,s=l.length,a++)}else if(92===e&&(i++,i<s&&10===l.charCodeAt(i))){const e=o(a);null!==e&&(l+=e,s=l.length,a++)}}if(c<0||58!==l.charCodeAt(c+1))return!1;for(i=c+2;i<s;i++){const e=l.charCodeAt(i);if(10===e){const e=o(a);null!==e&&(l+=e,s=l.length,a++)}else if(!Ae(e))break}const h=e.md.helpers.parseLinkDestination(l,i,s);if(!h.ok)return!1;const d=e.md.normalizeLink(h.str);if(!e.md.validateLink(d))return!1;i=h.pos;const u=i,p=a,f=i;for(;i<s;i++){const e=l.charCodeAt(i);if(10===e){const e=o(a);null!==e&&(l+=e,s=l.length,a++)}else if(!Ae(e))break}let m,g=e.md.helpers.parseLinkTitle(l,i,s);for(;g.can_continue;){const t=o(a);if(null===t)break;l+=t,i=s,s=l.length,a++,g=e.md.helpers.parseLinkTitle(l,i,s,g)}for(i<s&&f!==i&&g.ok?(m=g.str,i=g.pos):(m="",i=u,a=p);i<s;){if(!Ae(l.charCodeAt(i)))break;i++}if(i<s&&10!==l.charCodeAt(i)&&m)for(m="",i=u,a=p;i<s;){if(!Ae(l.charCodeAt(i)))break;i++}if(i<s&&10!==l.charCodeAt(i))return!1;const v=ke(l.slice(1,c));return!!v&&(r||("undefined"===typeof e.env.references&&(e.env.references={}),"undefined"===typeof e.env.references[v]&&(e.env.references[v]={title:m,href:d}),e.line=a),!0)}],["html_block",function(e,t,n,r){let i=e.bMarks[t]+e.tShift[t],s=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(!e.md.options.html)return!1;if(60!==e.src.charCodeAt(i))return!1;let a=e.src.slice(i,s),o=0;for(;o<ft.length&&!ft[o][0].test(a);o++);if(o===ft.length)return!1;if(r)return ft[o][2];let l=t+1;if(!ft[o][1].test(a))for(;l<n&&!(e.sCount[l]<e.blkIndent);l++)if(i=e.bMarks[l]+e.tShift[l],s=e.eMarks[l],a=e.src.slice(i,s),ft[o][1].test(a)){0!==a.length&&l++;break}e.line=l;const c=e.push("html_block","",0);return c.map=[t,l],c.content=e.getLines(t,l,e.blkIndent,!0),!0},["paragraph","reference","blockquote"]],["heading",function(e,t,n,r){let i=e.bMarks[t]+e.tShift[t],s=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;let a=e.src.charCodeAt(i);if(35!==a||i>=s)return!1;let o=1;for(a=e.src.charCodeAt(++i);35===a&&i<s&&o<=6;)o++,a=e.src.charCodeAt(++i);if(o>6||i<s&&!Ae(a))return!1;if(r)return!0;s=e.skipSpacesBack(s,i);const l=e.skipCharsBack(s,35,i);l>i&&Ae(e.src.charCodeAt(l-1))&&(s=l),e.line=t+1;const c=e.push("heading_open","h"+String(o),1);c.markup="########".slice(0,o),c.map=[t,e.line];const h=e.push("inline","",0);return h.content=e.src.slice(i,s).trim(),h.map=[t,e.line],h.children=[],e.push("heading_close","h"+String(o),-1).markup="########".slice(0,o),!0},["paragraph","reference","blockquote"]],["lheading",function(e,t,n){const r=e.md.block.ruler.getRules("paragraph");if(e.sCount[t]-e.blkIndent>=4)return!1;const i=e.parentType;e.parentType="paragraph";let s,a=0,o=t+1;for(;o<n&&!e.isEmpty(o);o++){if(e.sCount[o]-e.blkIndent>3)continue;if(e.sCount[o]>=e.blkIndent){let t=e.bMarks[o]+e.tShift[o];const n=e.eMarks[o];if(t<n&&(s=e.src.charCodeAt(t),(45===s||61===s)&&(t=e.skipChars(t,s),t=e.skipSpaces(t),t>=n))){a=61===s?1:2;break}}if(e.sCount[o]<0)continue;let t=!1;for(let i=0,s=r.length;i<s;i++)if(r[i](e,o,n,!0)){t=!0;break}if(t)break}if(!a)return!1;const l=e.getLines(t,o,e.blkIndent,!1).trim();e.line=o+1;const c=e.push("heading_open","h"+String(a),1);c.markup=String.fromCharCode(s),c.map=[t,e.line];const h=e.push("inline","",0);return h.content=l,h.map=[t,e.line-1],h.children=[],e.push("heading_close","h"+String(a),-1).markup=String.fromCharCode(s),e.parentType=i,!0}],["paragraph",function(e,t,n){const r=e.md.block.ruler.getRules("paragraph"),i=e.parentType;let s=t+1;for(e.parentType="paragraph";s<n&&!e.isEmpty(s);s++){if(e.sCount[s]-e.blkIndent>3)continue;if(e.sCount[s]<0)continue;let t=!1;for(let i=0,a=r.length;i<a;i++)if(r[i](e,s,n,!0)){t=!0;break}if(t)break}const a=e.getLines(t,s,e.blkIndent,!1).trim();e.line=s,e.push("paragraph_open","p",1).map=[t,e.line];const o=e.push("inline","",0);return o.content=a,o.map=[t,e.line],o.children=[],e.push("paragraph_close","p",-1),e.parentType=i,!0}]];function gt(){this.ruler=new Ne;for(let e=0;e<mt.length;e++)this.ruler.push(mt[e][0],mt[e][1],{alt:(mt[e][2]||[]).slice()})}gt.prototype.tokenize=function(e,t,n){const r=this.ruler.getRules(""),i=r.length,s=e.md.options.maxNesting;let a=t,o=!1;for(;a<n&&(e.line=a=e.skipEmptyLines(a),!(a>=n))&&!(e.sCount[a]<e.blkIndent);){if(e.level>=s){e.line=n;break}const t=e.line;let l=!1;for(let s=0;s<i;s++)if(l=r[s](e,a,n,!1),l){if(t>=e.line)throw new Error("block rule didn't increment state.line");break}if(!l)throw new Error("none of the block rules matched");e.tight=!o,e.isEmpty(e.line-1)&&(o=!0),a=e.line,a<n&&e.isEmpty(a)&&(o=!0,a++,e.line=a)}},gt.prototype.parse=function(e,t,n,r){if(!e)return;const i=new this.State(e,t,n,r);this.tokenize(i,i.line,i.lineMax)},gt.prototype.State=st;const vt=gt;function yt(e,t,n,r){this.src=e,this.env=n,this.md=t,this.tokens=r,this.tokens_meta=Array(r.length),this.pos=0,this.posMax=this.src.length,this.level=0,this.pending="",this.pendingLevel=0,this.cache={},this.delimiters=[],this._prev_delimiters=[],this.backticks={},this.backticksScanned=!1,this.linkLevel=0}yt.prototype.pushPending=function(){const e=new Oe("text","",0);return e.content=this.pending,e.level=this.pendingLevel,this.tokens.push(e),this.pending="",e},yt.prototype.push=function(e,t,n){this.pending&&this.pushPending();const r=new Oe(e,t,n);let i=null;return n<0&&(this.level--,this.delimiters=this._prev_delimiters.pop()),r.level=this.level,n>0&&(this.level++,this._prev_delimiters.push(this.delimiters),this.delimiters=[],i={delimiters:this.delimiters}),this.pendingLevel=this.level,this.tokens.push(r),this.tokens_meta.push(i),r},yt.prototype.scanDelims=function(e,t){const n=this.posMax,r=this.src.charCodeAt(e),i=e>0?this.src.charCodeAt(e-1):32;let s=e;for(;s<n&&this.src.charCodeAt(s)===r;)s++;const a=s-e,o=s<n?this.src.charCodeAt(s):32,l=Ce(i)||Ee(String.fromCharCode(i)),c=Ce(o)||Ee(String.fromCharCode(o)),h=xe(i),d=xe(o),u=!d&&(!c||h||l),p=!h&&(!l||d||c);return{can_open:u&&(t||!p||l),can_close:p&&(t||!u||c),length:a}},yt.prototype.Token=Oe;const bt=yt;function wt(e){switch(e){case 10:case 33:case 35:case 36:case 37:case 38:case 42:case 43:case 45:case 58:case 60:case 61:case 62:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 125:case 126:return!0;default:return!1}}const _t=/(?:^|[^a-z0-9.+-])([a-z][a-z0-9.+-]*)$/i;const At=[];for(let zi=0;zi<256;zi++)At.push(0);function xt(e,t){let n;const r=[],i=t.length;for(let s=0;s<i;s++){const i=t[s];if(126!==i.marker)continue;if(-1===i.end)continue;const a=t[i.end];n=e.tokens[i.token],n.type="s_open",n.tag="s",n.nesting=1,n.markup="~~",n.content="",n=e.tokens[a.token],n.type="s_close",n.tag="s",n.nesting=-1,n.markup="~~",n.content="","text"===e.tokens[a.token-1].type&&"~"===e.tokens[a.token-1].content&&r.push(a.token-1)}for(;r.length;){const t=r.pop();let i=t+1;for(;i<e.tokens.length&&"s_close"===e.tokens[i].type;)i++;i--,t!==i&&(n=e.tokens[i],e.tokens[i]=e.tokens[t],e.tokens[t]=n)}}"\\!\"#$%&'()*+,./:;<=>?@[]^_`{|}~-".split("").forEach(function(e){At[e.charCodeAt(0)]=1});const Et={tokenize:function(e,t){const n=e.pos,r=e.src.charCodeAt(n);if(t)return!1;if(126!==r)return!1;const i=e.scanDelims(e.pos,!0);let s=i.length;const a=String.fromCharCode(r);if(s<2)return!1;let o;s%2&&(o=e.push("text","",0),o.content=a,s--);for(let l=0;l<s;l+=2)o=e.push("text","",0),o.content=a+a,e.delimiters.push({marker:r,length:0,token:e.tokens.length-1,end:-1,open:i.can_open,close:i.can_close});return e.pos+=i.length,!0},postProcess:function(e){const t=e.tokens_meta,n=e.tokens_meta.length;xt(e,e.delimiters);for(let r=0;r<n;r++)t[r]&&t[r].delimiters&&xt(e,t[r].delimiters)}};function Ct(e,t){for(let n=t.length-1;n>=0;n--){const r=t[n];if(95!==r.marker&&42!==r.marker)continue;if(-1===r.end)continue;const i=t[r.end],s=n>0&&t[n-1].end===r.end+1&&t[n-1].marker===r.marker&&t[n-1].token===r.token-1&&t[r.end+1].token===i.token+1,a=String.fromCharCode(r.marker),o=e.tokens[r.token];o.type=s?"strong_open":"em_open",o.tag=s?"strong":"em",o.nesting=1,o.markup=s?a+a:a,o.content="";const l=e.tokens[i.token];l.type=s?"strong_close":"em_close",l.tag=s?"strong":"em",l.nesting=-1,l.markup=s?a+a:a,l.content="",s&&(e.tokens[t[n-1].token].content="",e.tokens[t[r.end+1].token].content="",n--)}}const kt={tokenize:function(e,t){const n=e.pos,r=e.src.charCodeAt(n);if(t)return!1;if(95!==r&&42!==r)return!1;const i=e.scanDelims(e.pos,42===r);for(let s=0;s<i.length;s++){e.push("text","",0).content=String.fromCharCode(r),e.delimiters.push({marker:r,length:i.length,token:e.tokens.length-1,end:-1,open:i.can_open,close:i.can_close})}return e.pos+=i.length,!0},postProcess:function(e){const t=e.tokens_meta,n=e.tokens_meta.length;Ct(e,e.delimiters);for(let r=0;r<n;r++)t[r]&&t[r].delimiters&&Ct(e,t[r].delimiters)}};const St=/^([a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)$/,Tt=/^([a-zA-Z][a-zA-Z0-9+.-]{1,31}):([^<>\x00-\x20]*)$/;const Dt=/^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i,Mt=/^&([a-z][a-z0-9]{1,31});/i;function Pt(e){const t={},n=e.length;if(!n)return;let r=0,i=-2;const s=[];for(let a=0;a<n;a++){const n=e[a];if(s.push(0),e[r].marker===n.marker&&i===n.token-1||(r=a),i=n.token,n.length=n.length||0,!n.close)continue;t.hasOwnProperty(n.marker)||(t[n.marker]=[-1,-1,-1,-1,-1,-1]);const o=t[n.marker][(n.open?3:0)+n.length%3];let l=r-s[r]-1,c=l;for(;l>o;l-=s[l]+1){const t=e[l];if(t.marker===n.marker&&(t.open&&t.end<0)){let r=!1;if((t.close||n.open)&&(t.length+n.length)%3===0&&(t.length%3===0&&n.length%3===0||(r=!0)),!r){const r=l>0&&!e[l-1].open?s[l-1]+1:0;s[a]=a-l+r,s[l]=r,n.open=!1,t.end=a,t.close=!1,c=-1,i=-2;break}}}-1!==c&&(t[n.marker][(n.open?3:0)+(n.length||0)%3]=c)}}const It=[["text",function(e,t){let n=e.pos;for(;n<e.posMax&&!wt(e.src.charCodeAt(n));)n++;return n!==e.pos&&(t||(e.pending+=e.src.slice(e.pos,n)),e.pos=n,!0)}],["linkify",function(e,t){if(!e.md.options.linkify)return!1;if(e.linkLevel>0)return!1;const n=e.pos;if(n+3>e.posMax)return!1;if(58!==e.src.charCodeAt(n))return!1;if(47!==e.src.charCodeAt(n+1))return!1;if(47!==e.src.charCodeAt(n+2))return!1;const r=e.pending.match(_t);if(!r)return!1;const i=r[1],s=e.md.linkify.matchAtStart(e.src.slice(n-i.length));if(!s)return!1;let a=s.url;if(a.length<=i.length)return!1;let o=a.length;for(;o>0&&42===a.charCodeAt(o-1);)o--;o!==a.length&&(a=a.slice(0,o));const l=e.md.normalizeLink(a);if(!e.md.validateLink(l))return!1;if(!t){e.pending=e.pending.slice(0,-i.length);const t=e.push("link_open","a",1);t.attrs=[["href",l]],t.markup="linkify",t.info="auto";e.push("text","",0).content=e.md.normalizeLinkText(a);const n=e.push("link_close","a",-1);n.markup="linkify",n.info="auto"}return e.pos+=a.length-i.length,!0}],["newline",function(e,t){let n=e.pos;if(10!==e.src.charCodeAt(n))return!1;const r=e.pending.length-1,i=e.posMax;if(!t)if(r>=0&&32===e.pending.charCodeAt(r))if(r>=1&&32===e.pending.charCodeAt(r-1)){let t=r-1;for(;t>=1&&32===e.pending.charCodeAt(t-1);)t--;e.pending=e.pending.slice(0,t),e.push("hardbreak","br",0)}else e.pending=e.pending.slice(0,-1),e.push("softbreak","br",0);else e.push("softbreak","br",0);for(n++;n<i&&Ae(e.src.charCodeAt(n));)n++;return e.pos=n,!0}],["escape",function(e,t){let n=e.pos;const r=e.posMax;if(92!==e.src.charCodeAt(n))return!1;if(n++,n>=r)return!1;let i=e.src.charCodeAt(n);if(10===i){for(t||e.push("hardbreak","br",0),n++;n<r&&(i=e.src.charCodeAt(n),Ae(i));)n++;return e.pos=n,!0}let s=e.src[n];if(i>=55296&&i<=56319&&n+1<r){const t=e.src.charCodeAt(n+1);t>=56320&&t<=57343&&(s+=e.src[n+1],n++)}const a="\\"+s;if(!t){const t=e.push("text_special","",0);i<256&&0!==At[i]?t.content=s:t.content=a,t.markup=a,t.info="escape"}return e.pos=n+1,!0}],["backticks",function(e,t){let n=e.pos;if(96!==e.src.charCodeAt(n))return!1;const r=n;n++;const i=e.posMax;for(;n<i&&96===e.src.charCodeAt(n);)n++;const s=e.src.slice(r,n),a=s.length;if(e.backticksScanned&&(e.backticks[a]||0)<=r)return t||(e.pending+=s),e.pos+=a,!0;let o,l=n;for(;-1!==(o=e.src.indexOf("`",l));){for(l=o+1;l<i&&96===e.src.charCodeAt(l);)l++;const r=l-o;if(r===a){if(!t){const t=e.push("code_inline","code",0);t.markup=s,t.content=e.src.slice(n,o).replace(/\n/g," ").replace(/^ (.+) $/,"$1")}return e.pos=l,!0}e.backticks[r]=o}return e.backticksScanned=!0,t||(e.pending+=s),e.pos+=a,!0}],["strikethrough",Et.tokenize],["emphasis",kt.tokenize],["link",function(e,t){let n,r,i,s,a="",o="",l=e.pos,c=!0;if(91!==e.src.charCodeAt(e.pos))return!1;const h=e.pos,d=e.posMax,u=e.pos+1,p=e.md.helpers.parseLinkLabel(e,e.pos,!0);if(p<0)return!1;let f=p+1;if(f<d&&40===e.src.charCodeAt(f)){for(c=!1,f++;f<d&&(n=e.src.charCodeAt(f),Ae(n)||10===n);f++);if(f>=d)return!1;if(l=f,i=e.md.helpers.parseLinkDestination(e.src,f,e.posMax),i.ok){for(a=e.md.normalizeLink(i.str),e.md.validateLink(a)?f=i.pos:a="",l=f;f<d&&(n=e.src.charCodeAt(f),Ae(n)||10===n);f++);if(i=e.md.helpers.parseLinkTitle(e.src,f,e.posMax),f<d&&l!==f&&i.ok)for(o=i.str,f=i.pos;f<d&&(n=e.src.charCodeAt(f),Ae(n)||10===n);f++);}(f>=d||41!==e.src.charCodeAt(f))&&(c=!0),f++}if(c){if("undefined"===typeof e.env.references)return!1;if(f<d&&91===e.src.charCodeAt(f)?(l=f+1,f=e.md.helpers.parseLinkLabel(e,f),f>=0?r=e.src.slice(l,f++):f=p+1):f=p+1,r||(r=e.src.slice(u,p)),s=e.env.references[ke(r)],!s)return e.pos=h,!1;a=s.href,o=s.title}if(!t){e.pos=u,e.posMax=p;const t=[["href",a]];e.push("link_open","a",1).attrs=t,o&&t.push(["title",o]),e.linkLevel++,e.md.inline.tokenize(e),e.linkLevel--,e.push("link_close","a",-1)}return e.pos=f,e.posMax=d,!0}],["image",function(e,t){let n,r,i,s,a,o,l,c,h="";const d=e.pos,u=e.posMax;if(33!==e.src.charCodeAt(e.pos))return!1;if(91!==e.src.charCodeAt(e.pos+1))return!1;const p=e.pos+2,f=e.md.helpers.parseLinkLabel(e,e.pos+1,!1);if(f<0)return!1;if(s=f+1,s<u&&40===e.src.charCodeAt(s)){for(s++;s<u&&(n=e.src.charCodeAt(s),Ae(n)||10===n);s++);if(s>=u)return!1;for(c=s,o=e.md.helpers.parseLinkDestination(e.src,s,e.posMax),o.ok&&(h=e.md.normalizeLink(o.str),e.md.validateLink(h)?s=o.pos:h=""),c=s;s<u&&(n=e.src.charCodeAt(s),Ae(n)||10===n);s++);if(o=e.md.helpers.parseLinkTitle(e.src,s,e.posMax),s<u&&c!==s&&o.ok)for(l=o.str,s=o.pos;s<u&&(n=e.src.charCodeAt(s),Ae(n)||10===n);s++);else l="";if(s>=u||41!==e.src.charCodeAt(s))return e.pos=d,!1;s++}else{if("undefined"===typeof e.env.references)return!1;if(s<u&&91===e.src.charCodeAt(s)?(c=s+1,s=e.md.helpers.parseLinkLabel(e,s),s>=0?i=e.src.slice(c,s++):s=f+1):s=f+1,i||(i=e.src.slice(p,f)),a=e.env.references[ke(i)],!a)return e.pos=d,!1;h=a.href,l=a.title}if(!t){r=e.src.slice(p,f);const t=[];e.md.inline.parse(r,e.md,e.env,t);const n=e.push("image","img",0),i=[["src",h],["alt",""]];n.attrs=i,n.children=t,n.content=r,l&&i.push(["title",l])}return e.pos=s,e.posMax=u,!0}],["autolink",function(e,t){let n=e.pos;if(60!==e.src.charCodeAt(n))return!1;const r=e.pos,i=e.posMax;for(;;){if(++n>=i)return!1;const t=e.src.charCodeAt(n);if(60===t)return!1;if(62===t)break}const s=e.src.slice(r+1,n);if(Tt.test(s)){const n=e.md.normalizeLink(s);if(!e.md.validateLink(n))return!1;if(!t){const t=e.push("link_open","a",1);t.attrs=[["href",n]],t.markup="autolink",t.info="auto";e.push("text","",0).content=e.md.normalizeLinkText(s);const r=e.push("link_close","a",-1);r.markup="autolink",r.info="auto"}return e.pos+=s.length+2,!0}if(St.test(s)){const n=e.md.normalizeLink("mailto:"+s);if(!e.md.validateLink(n))return!1;if(!t){const t=e.push("link_open","a",1);t.attrs=[["href",n]],t.markup="autolink",t.info="auto";e.push("text","",0).content=e.md.normalizeLinkText(s);const r=e.push("link_close","a",-1);r.markup="autolink",r.info="auto"}return e.pos+=s.length+2,!0}return!1}],["html_inline",function(e,t){if(!e.md.options.html)return!1;const n=e.posMax,r=e.pos;if(60!==e.src.charCodeAt(r)||r+2>=n)return!1;const i=e.src.charCodeAt(r+1);if(33!==i&&63!==i&&47!==i&&!function(e){const t=32|e;return t>=97&&t<=122}(i))return!1;const s=e.src.slice(r).match(ut);if(!s)return!1;if(!t){const t=e.push("html_inline","",0);t.content=s[0],function(e){return/^<a[>\s]/i.test(e)}(t.content)&&e.linkLevel++,function(e){return/^<\/a\s*>/i.test(e)}(t.content)&&e.linkLevel--}return e.pos+=s[0].length,!0}],["entity",function(e,t){const n=e.pos,r=e.posMax;if(38!==e.src.charCodeAt(n))return!1;if(n+1>=r)return!1;if(35===e.src.charCodeAt(n+1)){const r=e.src.slice(n).match(Dt);if(r){if(!t){const t="x"===r[1][0].toLowerCase()?parseInt(r[1].slice(1),16):parseInt(r[1],10),n=e.push("text_special","",0);n.content=le(t)?ce(t):ce(65533),n.markup=r[0],n.info="entity"}return e.pos+=r[0].length,!0}}else{const r=e.src.slice(n).match(Mt);if(r){const n=Z(r[0]);if(n!==r[0]){if(!t){const t=e.push("text_special","",0);t.content=n,t.markup=r[0],t.info="entity"}return e.pos+=r[0].length,!0}}}return!1}]],Ft=[["balance_pairs",function(e){const t=e.tokens_meta,n=e.tokens_meta.length;Pt(e.delimiters);for(let r=0;r<n;r++)t[r]&&t[r].delimiters&&Pt(t[r].delimiters)}],["strikethrough",Et.postProcess],["emphasis",kt.postProcess],["fragments_join",function(e){let t,n,r=0;const i=e.tokens,s=e.tokens.length;for(t=n=0;t<s;t++)i[t].nesting<0&&r--,i[t].level=r,i[t].nesting>0&&r++,"text"===i[t].type&&t+1<s&&"text"===i[t+1].type?i[t+1].content=i[t].content+i[t+1].content:(t!==n&&(i[n]=i[t]),n++);t!==n&&(i.length=n)}]];function Rt(){this.ruler=new Ne;for(let e=0;e<It.length;e++)this.ruler.push(It[e][0],It[e][1]);this.ruler2=new Ne;for(let e=0;e<Ft.length;e++)this.ruler2.push(Ft[e][0],Ft[e][1])}Rt.prototype.skipToken=function(e){const t=e.pos,n=this.ruler.getRules(""),r=n.length,i=e.md.options.maxNesting,s=e.cache;if("undefined"!==typeof s[t])return void(e.pos=s[t]);let a=!1;if(e.level<i){for(let o=0;o<r;o++)if(e.level++,a=n[o](e,!0),e.level--,a){if(t>=e.pos)throw new Error("inline rule didn't increment state.pos");break}}else e.pos=e.posMax;a||e.pos++,s[t]=e.pos},Rt.prototype.tokenize=function(e){const t=this.ruler.getRules(""),n=t.length,r=e.posMax,i=e.md.options.maxNesting;for(;e.pos<r;){const s=e.pos;let a=!1;if(e.level<i)for(let r=0;r<n;r++)if(a=t[r](e,!1),a){if(s>=e.pos)throw new Error("inline rule didn't increment state.pos");break}if(a){if(e.pos>=r)break}else e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},Rt.prototype.parse=function(e,t,n,r){const i=new this.State(e,t,n,r);this.tokenize(i);const s=this.ruler2.getRules(""),a=s.length;for(let o=0;o<a;o++)s[o](i)},Rt.prototype.State=bt;const Nt=Rt;function Lt(e){return Array.prototype.slice.call(arguments,1).forEach(function(t){t&&Object.keys(t).forEach(function(n){e[n]=t[n]})}),e}function Ot(e){return Object.prototype.toString.call(e)}function Bt(e){return"[object Function]"===Ot(e)}function $t(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}const zt={fuzzyLink:!0,fuzzyEmail:!0,fuzzyIP:!1};const jt={"http:":{validate:function(e,t,n){const r=e.slice(t);return n.re.http||(n.re.http=new RegExp("^\\/\\/"+n.re.src_auth+n.re.src_host_port_strict+n.re.src_path,"i")),n.re.http.test(r)?r.match(n.re.http)[0].length:0}},"https:":"http:","ftp:":"http:","//":{validate:function(e,t,n){const r=e.slice(t);return n.re.no_http||(n.re.no_http=new RegExp("^"+n.re.src_auth+"(?:localhost|(?:(?:"+n.re.src_domain+")\\.)+"+n.re.src_domain_root+")"+n.re.src_port+n.re.src_host_terminator+n.re.src_path,"i")),n.re.no_http.test(r)?t>=3&&":"===e[t-3]||t>=3&&"/"===e[t-3]?0:r.match(n.re.no_http)[0].length:0}},"mailto:":{validate:function(e,t,n){const r=e.slice(t);return n.re.mailto||(n.re.mailto=new RegExp("^"+n.re.src_email_name+"@"+n.re.src_host_strict,"i")),n.re.mailto.test(r)?r.match(n.re.mailto)[0].length:0}}},Ut="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|\u0440\u0444".split("|");function Ht(e){const t=e.re=function(e){const t={};e=e||{},t.src_Any=M.source,t.src_Cc=P.source,t.src_Z=F.source,t.src_P=T.source,t.src_ZPCc=[t.src_Z,t.src_P,t.src_Cc].join("|"),t.src_ZCc=[t.src_Z,t.src_Cc].join("|");const n="[><\uff5c]";return t.src_pseudo_letter="(?:(?![><\uff5c]|"+t.src_ZPCc+")"+t.src_Any+")",t.src_ip4="(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)",t.src_auth="(?:(?:(?!"+t.src_ZCc+"|[@/\\[\\]()]).)+@)?",t.src_port="(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?",t.src_host_terminator="(?=$|[><\uff5c]|"+t.src_ZPCc+")(?!"+(e["---"]?"-(?!--)|":"-|")+"_|:\\d|\\.-|\\.(?!$|"+t.src_ZPCc+"))",t.src_path="(?:[/?#](?:(?!"+t.src_ZCc+"|"+n+"|[()[\\]{}.,\"'?!\\-;]).|\\[(?:(?!"+t.src_ZCc+"|\\]).)*\\]|\\((?:(?!"+t.src_ZCc+"|[)]).)*\\)|\\{(?:(?!"+t.src_ZCc+'|[}]).)*\\}|\\"(?:(?!'+t.src_ZCc+'|["]).)+\\"|\\\'(?:(?!'+t.src_ZCc+"|[']).)+\\'|\\'(?="+t.src_pseudo_letter+"|[-])|\\.{2,}[a-zA-Z0-9%/&]|\\.(?!"+t.src_ZCc+"|[.]|$)|"+(e["---"]?"\\-(?!--(?:[^-]|$))(?:-*)|":"\\-+|")+",(?!"+t.src_ZCc+"|$)|;(?!"+t.src_ZCc+"|$)|\\!+(?!"+t.src_ZCc+"|[!]|$)|\\?(?!"+t.src_ZCc+"|[?]|$))+|\\/)?",t.src_email_name='[\\-;:&=\\+\\$,\\.a-zA-Z0-9_][\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]*',t.src_xn="xn--[a-z0-9\\-]{1,59}",t.src_domain_root="(?:"+t.src_xn+"|"+t.src_pseudo_letter+"{1,63})",t.src_domain="(?:"+t.src_xn+"|(?:"+t.src_pseudo_letter+")|(?:"+t.src_pseudo_letter+"(?:-|"+t.src_pseudo_letter+"){0,61}"+t.src_pseudo_letter+"))",t.src_host="(?:(?:(?:(?:"+t.src_domain+")\\.)*"+t.src_domain+"))",t.tpl_host_fuzzy="(?:"+t.src_ip4+"|(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%)))",t.tpl_host_no_ip_fuzzy="(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%))",t.src_host_strict=t.src_host+t.src_host_terminator,t.tpl_host_fuzzy_strict=t.tpl_host_fuzzy+t.src_host_terminator,t.src_host_port_strict=t.src_host+t.src_port+t.src_host_terminator,t.tpl_host_port_fuzzy_strict=t.tpl_host_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_port_no_ip_fuzzy_strict=t.tpl_host_no_ip_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_fuzzy_test="localhost|www\\.|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:"+t.src_ZPCc+"|>|$))",t.tpl_email_fuzzy='(^|[><\uff5c]|"|\\(|'+t.src_ZCc+")("+t.src_email_name+"@"+t.tpl_host_fuzzy_strict+")",t.tpl_link_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`|\uff5c]|"+t.src_ZPCc+"))((?![$+<=>^`|\uff5c])"+t.tpl_host_port_fuzzy_strict+t.src_path+")",t.tpl_link_no_ip_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`|\uff5c]|"+t.src_ZPCc+"))((?![$+<=>^`|\uff5c])"+t.tpl_host_port_no_ip_fuzzy_strict+t.src_path+")",t}(e.__opts__),n=e.__tlds__.slice();function r(e){return e.replace("%TLDS%",t.src_tlds)}e.onCompile(),e.__tlds_replaced__||n.push("a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]"),n.push(t.src_xn),t.src_tlds=n.join("|"),t.email_fuzzy=RegExp(r(t.tpl_email_fuzzy),"i"),t.link_fuzzy=RegExp(r(t.tpl_link_fuzzy),"i"),t.link_no_ip_fuzzy=RegExp(r(t.tpl_link_no_ip_fuzzy),"i"),t.host_fuzzy_test=RegExp(r(t.tpl_host_fuzzy_test),"i");const i=[];function s(e,t){throw new Error('(LinkifyIt) Invalid schema "'+e+'": '+t)}e.__compiled__={},Object.keys(e.__schemas__).forEach(function(t){const n=e.__schemas__[t];if(null===n)return;const r={validate:null,link:null};if(e.__compiled__[t]=r,"[object Object]"===Ot(n))return!function(e){return"[object RegExp]"===Ot(e)}(n.validate)?Bt(n.validate)?r.validate=n.validate:s(t,n):r.validate=function(e){return function(t,n){const r=t.slice(n);return e.test(r)?r.match(e)[0].length:0}}(n.validate),void(Bt(n.normalize)?r.normalize=n.normalize:n.normalize?s(t,n):r.normalize=function(e,t){t.normalize(e)});!function(e){return"[object String]"===Ot(e)}(n)?s(t,n):i.push(t)}),i.forEach(function(t){e.__compiled__[e.__schemas__[t]]&&(e.__compiled__[t].validate=e.__compiled__[e.__schemas__[t]].validate,e.__compiled__[t].normalize=e.__compiled__[e.__schemas__[t]].normalize)}),e.__compiled__[""]={validate:null,normalize:function(e,t){t.normalize(e)}};const a=Object.keys(e.__compiled__).filter(function(t){return t.length>0&&e.__compiled__[t]}).map($t).join("|");e.re.schema_test=RegExp("(^|(?!_)(?:[><\uff5c]|"+t.src_ZPCc+"))("+a+")","i"),e.re.schema_search=RegExp("(^|(?!_)(?:[><\uff5c]|"+t.src_ZPCc+"))("+a+")","ig"),e.re.schema_at_start=RegExp("^"+e.re.schema_search.source,"i"),e.re.pretest=RegExp("("+e.re.schema_test.source+")|("+e.re.host_fuzzy_test.source+")|@","i"),function(e){e.__index__=-1,e.__text_cache__=""}(e)}function Vt(e,t){const n=e.__index__,r=e.__last_index__,i=e.__text_cache__.slice(n,r);this.schema=e.__schema__.toLowerCase(),this.index=n+t,this.lastIndex=r+t,this.raw=i,this.text=i,this.url=i}function qt(e,t){const n=new Vt(e,t);return e.__compiled__[n.schema].normalize(n,e),n}function Wt(e,t){if(!(this instanceof Wt))return new Wt(e,t);var n;t||(n=e,Object.keys(n||{}).reduce(function(e,t){return e||zt.hasOwnProperty(t)},!1)&&(t=e,e={})),this.__opts__=Lt({},zt,t),this.__index__=-1,this.__last_index__=-1,this.__schema__="",this.__text_cache__="",this.__schemas__=Lt({},jt,e),this.__compiled__={},this.__tlds__=Ut,this.__tlds_replaced__=!1,this.re={},Ht(this)}Wt.prototype.add=function(e,t){return this.__schemas__[e]=t,Ht(this),this},Wt.prototype.set=function(e){return this.__opts__=Lt(this.__opts__,e),this},Wt.prototype.test=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return!1;let t,n,r,i,s,a,o,l,c;if(this.re.schema_test.test(e))for(o=this.re.schema_search,o.lastIndex=0;null!==(t=o.exec(e));)if(i=this.testSchemaAt(e,t[2],o.lastIndex),i){this.__schema__=t[2],this.__index__=t.index+t[1].length,this.__last_index__=t.index+t[0].length+i;break}return this.__opts__.fuzzyLink&&this.__compiled__["http:"]&&(l=e.search(this.re.host_fuzzy_test),l>=0&&(this.__index__<0||l<this.__index__)&&null!==(n=e.match(this.__opts__.fuzzyIP?this.re.link_fuzzy:this.re.link_no_ip_fuzzy))&&(s=n.index+n[1].length,(this.__index__<0||s<this.__index__)&&(this.__schema__="",this.__index__=s,this.__last_index__=n.index+n[0].length))),this.__opts__.fuzzyEmail&&this.__compiled__["mailto:"]&&(c=e.indexOf("@"),c>=0&&null!==(r=e.match(this.re.email_fuzzy))&&(s=r.index+r[1].length,a=r.index+r[0].length,(this.__index__<0||s<this.__index__||s===this.__index__&&a>this.__last_index__)&&(this.__schema__="mailto:",this.__index__=s,this.__last_index__=a))),this.__index__>=0},Wt.prototype.pretest=function(e){return this.re.pretest.test(e)},Wt.prototype.testSchemaAt=function(e,t,n){return this.__compiled__[t.toLowerCase()]?this.__compiled__[t.toLowerCase()].validate(e,n,this):0},Wt.prototype.match=function(e){const t=[];let n=0;this.__index__>=0&&this.__text_cache__===e&&(t.push(qt(this,n)),n=this.__last_index__);let r=n?e.slice(n):e;for(;this.test(r);)t.push(qt(this,n)),r=r.slice(this.__last_index__),n+=this.__last_index__;return t.length?t:null},Wt.prototype.matchAtStart=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return null;const t=this.re.schema_at_start.exec(e);if(!t)return null;const n=this.testSchemaAt(e,t[2],t[0].length);return n?(this.__schema__=t[2],this.__index__=t.index+t[1].length,this.__last_index__=t.index+t[0].length+n,qt(this,0)):null},Wt.prototype.tlds=function(e,t){return e=Array.isArray(e)?e:[e],t?(this.__tlds__=this.__tlds__.concat(e).sort().filter(function(e,t,n){return e!==n[t-1]}).reverse(),Ht(this),this):(this.__tlds__=e.slice(),this.__tlds_replaced__=!0,Ht(this),this)},Wt.prototype.normalize=function(e){e.schema||(e.url="http://"+e.url),"mailto:"!==e.schema||/^mailto:/i.test(e.url)||(e.url="mailto:"+e.url)},Wt.prototype.onCompile=function(){};const Gt=Wt,Kt=2147483647,Xt=36,Yt=/^xn--/,Zt=/[^\0-\x7F]/,Jt=/[\x2E\u3002\uFF0E\uFF61]/g,Qt={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},en=Math.floor,tn=String.fromCharCode;function nn(e){throw new RangeError(Qt[e])}function rn(e,t){const n=e.split("@");let r="";n.length>1&&(r=n[0]+"@",e=n[1]);const i=function(e,t){const n=[];let r=e.length;for(;r--;)n[r]=t(e[r]);return n}((e=e.replace(Jt,".")).split("."),t).join(".");return r+i}function sn(e){const t=[];let n=0;const r=e.length;for(;n<r;){const i=e.charCodeAt(n++);if(i>=55296&&i<=56319&&n<r){const r=e.charCodeAt(n++);56320==(64512&r)?t.push(((1023&i)<<10)+(1023&r)+65536):(t.push(i),n--)}else t.push(i)}return t}const an=function(e){return e>=48&&e<58?e-48+26:e>=65&&e<91?e-65:e>=97&&e<123?e-97:Xt},on=function(e,t){return e+22+75*(e<26)-((0!=t)<<5)},ln=function(e,t,n){let r=0;for(e=n?en(e/700):e>>1,e+=en(e/t);e>455;r+=Xt)e=en(e/35);return en(r+36*e/(e+38))},cn=function(e){const t=[],n=e.length;let r=0,i=128,s=72,a=e.lastIndexOf("-");a<0&&(a=0);for(let o=0;o<a;++o)e.charCodeAt(o)>=128&&nn("not-basic"),t.push(e.charCodeAt(o));for(let o=a>0?a+1:0;o<n;){const a=r;for(let t=1,i=Xt;;i+=Xt){o>=n&&nn("invalid-input");const a=an(e.charCodeAt(o++));a>=Xt&&nn("invalid-input"),a>en((Kt-r)/t)&&nn("overflow"),r+=a*t;const l=i<=s?1:i>=s+26?26:i-s;if(a<l)break;const c=Xt-l;t>en(Kt/c)&&nn("overflow"),t*=c}const l=t.length+1;s=ln(r-a,l,0==a),en(r/l)>Kt-i&&nn("overflow"),i+=en(r/l),r%=l,t.splice(r++,0,i)}return String.fromCodePoint(...t)},hn=function(e){const t=[],n=(e=sn(e)).length;let r=128,i=0,s=72;for(const l of e)l<128&&t.push(tn(l));const a=t.length;let o=a;for(a&&t.push("-");o<n;){let n=Kt;for(const t of e)t>=r&&t<n&&(n=t);const l=o+1;n-r>en((Kt-i)/l)&&nn("overflow"),i+=(n-r)*l,r=n;for(const c of e)if(c<r&&++i>Kt&&nn("overflow"),c===r){let e=i;for(let n=Xt;;n+=Xt){const r=n<=s?1:n>=s+26?26:n-s;if(e<r)break;const i=e-r,a=Xt-r;t.push(tn(on(r+i%a,0))),e=en(i/a)}t.push(tn(on(e,0))),s=ln(i,l,o===a),i=0,++o}++i,++r}return t.join("")},dn={version:"2.3.1",ucs2:{decode:sn,encode:e=>String.fromCodePoint(...e)},decode:cn,encode:hn,toASCII:function(e){return rn(e,function(e){return Zt.test(e)?"xn--"+hn(e):e})},toUnicode:function(e){return rn(e,function(e){return Yt.test(e)?cn(e.slice(4).toLowerCase()):e})}},un={default:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:100},components:{core:{},block:{},inline:{}}},zero:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline","text_join"]},block:{rules:["paragraph"]},inline:{rules:["text"],rules2:["balance_pairs","fragments_join"]}}},commonmark:{options:{html:!0,xhtmlOut:!0,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline","text_join"]},block:{rules:["blockquote","code","fence","heading","hr","html_block","lheading","list","reference","paragraph"]},inline:{rules:["autolink","backticks","emphasis","entity","escape","html_inline","image","link","newline","text"],rules2:["balance_pairs","emphasis","fragments_join"]}}}},pn=/^(vbscript|javascript|file|data):/,fn=/^data:image\/(gif|png|jpeg|webp);/;function mn(e){const t=e.trim().toLowerCase();return!pn.test(t)||fn.test(t)}const gn=["http:","https:","mailto:"];function vn(e){const t=S(e,!0);if(t.hostname&&(!t.protocol||gn.indexOf(t.protocol)>=0))try{t.hostname=dn.toASCII(t.hostname)}catch(n){}return p(f(t))}function yn(e){const t=S(e,!0);if(t.hostname&&(!t.protocol||gn.indexOf(t.protocol)>=0))try{t.hostname=dn.toUnicode(t.hostname)}catch(n){}return h(f(t),h.defaultChars+"%")}function bn(e,t){if(!(this instanceof bn))return new bn(e,t);t||re(e)||(t=e||{},e="default"),this.inline=new Nt,this.block=new vt,this.core=new rt,this.renderer=new Fe,this.linkify=new Gt,this.validateLink=mn,this.normalizeLink=vn,this.normalizeLinkText=yn,this.utils=s,this.helpers=ae({},a),this.options={},this.configure(e),t&&this.set(t)}bn.prototype.set=function(e){return ae(this.options,e),this},bn.prototype.configure=function(e){const t=this;if(re(e)){const t=e;if(!(e=un[t]))throw new Error('Wrong `markdown-it` preset "'+t+'", check name')}if(!e)throw new Error("Wrong `markdown-it` preset, can't be empty");return e.options&&t.set(e.options),e.components&&Object.keys(e.components).forEach(function(n){e.components[n].rules&&t[n].ruler.enableOnly(e.components[n].rules),e.components[n].rules2&&t[n].ruler2.enableOnly(e.components[n].rules2)}),this},bn.prototype.enable=function(e,t){let n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(t){n=n.concat(this[t].ruler.enable(e,!0))},this),n=n.concat(this.inline.ruler2.enable(e,!0));const r=e.filter(function(e){return n.indexOf(e)<0});if(r.length&&!t)throw new Error("MarkdownIt. Failed to enable unknown rule(s): "+r);return this},bn.prototype.disable=function(e,t){let n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(t){n=n.concat(this[t].ruler.disable(e,!0))},this),n=n.concat(this.inline.ruler2.disable(e,!0));const r=e.filter(function(e){return n.indexOf(e)<0});if(r.length&&!t)throw new Error("MarkdownIt. Failed to disable unknown rule(s): "+r);return this},bn.prototype.use=function(e){const t=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,t),this},bn.prototype.parse=function(e,t){if("string"!==typeof e)throw new Error("Input data should be a String");const n=new this.core.State(e,this,t);return this.core.process(n),n.tokens},bn.prototype.render=function(e,t){return t=t||{},this.renderer.render(this.parse(e,t),this.options,t)},bn.prototype.parseInline=function(e,t){const n=new this.core.State(e,this,t);return n.inlineMode=!0,this.core.process(n),n.tokens},bn.prototype.renderInline=function(e,t){return t=t||{},this.renderer.render(this.parseInline(e,t),this.options,t)};const wn=bn;function _n(e){return"undefined"===typeof e||null===e}var An={isNothing:_n,isObject:function(e){return"object"===typeof e&&null!==e},toArray:function(e){return Array.isArray(e)?e:_n(e)?[]:[e]},repeat:function(e,t){var n,r="";for(n=0;n<t;n+=1)r+=e;return r},isNegativeZero:function(e){return 0===e&&Number.NEGATIVE_INFINITY===1/e},extend:function(e,t){var n,r,i,s;if(t)for(n=0,r=(s=Object.keys(t)).length;n<r;n+=1)e[i=s[n]]=t[i];return e}};function xn(e,t){var n="",r=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(n+='in "'+e.mark.name+'" '),n+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!t&&e.mark.snippet&&(n+="\n\n"+e.mark.snippet),r+" "+n):r}function En(e,t){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=t,this.message=xn(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack||""}En.prototype=Object.create(Error.prototype),En.prototype.constructor=En,En.prototype.toString=function(e){return this.name+": "+xn(this,e)};var Cn=En;function kn(e,t,n,r,i){var s="",a="",o=Math.floor(i/2)-1;return r-t>o&&(t=r-o+(s=" ... ").length),n-r>o&&(n=r+o-(a=" ...").length),{str:s+e.slice(t,n).replace(/\t/g,"\u2192")+a,pos:r-t+s.length}}function Sn(e,t){return An.repeat(" ",t-e.length)+e}var Tn=function(e,t){if(t=Object.create(t||null),!e.buffer)return null;t.maxLength||(t.maxLength=79),"number"!==typeof t.indent&&(t.indent=1),"number"!==typeof t.linesBefore&&(t.linesBefore=3),"number"!==typeof t.linesAfter&&(t.linesAfter=2);for(var n,r=/\r?\n|\r|\0/g,i=[0],s=[],a=-1;n=r.exec(e.buffer);)s.push(n.index),i.push(n.index+n[0].length),e.position<=n.index&&a<0&&(a=i.length-2);a<0&&(a=i.length-1);var o,l,c="",h=Math.min(e.line+t.linesAfter,s.length).toString().length,d=t.maxLength-(t.indent+h+3);for(o=1;o<=t.linesBefore&&!(a-o<0);o++)l=kn(e.buffer,i[a-o],s[a-o],e.position-(i[a]-i[a-o]),d),c=An.repeat(" ",t.indent)+Sn((e.line-o+1).toString(),h)+" | "+l.str+"\n"+c;for(l=kn(e.buffer,i[a],s[a],e.position,d),c+=An.repeat(" ",t.indent)+Sn((e.line+1).toString(),h)+" | "+l.str+"\n",c+=An.repeat("-",t.indent+h+3+l.pos)+"^\n",o=1;o<=t.linesAfter&&!(a+o>=s.length);o++)l=kn(e.buffer,i[a+o],s[a+o],e.position-(i[a]-i[a+o]),d),c+=An.repeat(" ",t.indent)+Sn((e.line+o+1).toString(),h)+" | "+l.str+"\n";return c.replace(/\n$/,"")},Dn=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],Mn=["scalar","sequence","mapping"];var Pn=function(e,t){if(t=t||{},Object.keys(t).forEach(function(t){if(-1===Dn.indexOf(t))throw new Cn('Unknown option "'+t+'" is met in definition of "'+e+'" YAML type.')}),this.options=t,this.tag=e,this.kind=t.kind||null,this.resolve=t.resolve||function(){return!0},this.construct=t.construct||function(e){return e},this.instanceOf=t.instanceOf||null,this.predicate=t.predicate||null,this.represent=t.represent||null,this.representName=t.representName||null,this.defaultStyle=t.defaultStyle||null,this.multi=t.multi||!1,this.styleAliases=function(e){var t={};return null!==e&&Object.keys(e).forEach(function(n){e[n].forEach(function(e){t[String(e)]=n})}),t}(t.styleAliases||null),-1===Mn.indexOf(this.kind))throw new Cn('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')};function In(e,t){var n=[];return e[t].forEach(function(e){var t=n.length;n.forEach(function(n,r){n.tag===e.tag&&n.kind===e.kind&&n.multi===e.multi&&(t=r)}),n[t]=e}),n}function Fn(e){return this.extend(e)}Fn.prototype.extend=function(e){var t=[],n=[];if(e instanceof Pn)n.push(e);else if(Array.isArray(e))n=n.concat(e);else{if(!e||!Array.isArray(e.implicit)&&!Array.isArray(e.explicit))throw new Cn("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");e.implicit&&(t=t.concat(e.implicit)),e.explicit&&(n=n.concat(e.explicit))}t.forEach(function(e){if(!(e instanceof Pn))throw new Cn("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(e.loadKind&&"scalar"!==e.loadKind)throw new Cn("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(e.multi)throw new Cn("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),n.forEach(function(e){if(!(e instanceof Pn))throw new Cn("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var r=Object.create(Fn.prototype);return r.implicit=(this.implicit||[]).concat(t),r.explicit=(this.explicit||[]).concat(n),r.compiledImplicit=In(r,"implicit"),r.compiledExplicit=In(r,"explicit"),r.compiledTypeMap=function(){var e,t,n={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function r(e){e.multi?(n.multi[e.kind].push(e),n.multi.fallback.push(e)):n[e.kind][e.tag]=n.fallback[e.tag]=e}for(e=0,t=arguments.length;e<t;e+=1)arguments[e].forEach(r);return n}(r.compiledImplicit,r.compiledExplicit),r};var Rn=Fn,Nn=new Pn("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return null!==e?e:""}}),Ln=new Pn("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return null!==e?e:[]}}),On=new Pn("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return null!==e?e:{}}}),Bn=new Rn({explicit:[Nn,Ln,On]});var $n=new Pn("tag:yaml.org,2002:null",{kind:"scalar",resolve:function(e){if(null===e)return!0;var t=e.length;return 1===t&&"~"===e||4===t&&("null"===e||"Null"===e||"NULL"===e)},construct:function(){return null},predicate:function(e){return null===e},represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"});var zn=new Pn("tag:yaml.org,2002:bool",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t=e.length;return 4===t&&("true"===e||"True"===e||"TRUE"===e)||5===t&&("false"===e||"False"===e||"FALSE"===e)},construct:function(e){return"true"===e||"True"===e||"TRUE"===e},predicate:function(e){return"[object Boolean]"===Object.prototype.toString.call(e)},represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"});function jn(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function Un(e){return 48<=e&&e<=55}function Hn(e){return 48<=e&&e<=57}var Vn=new Pn("tag:yaml.org,2002:int",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t,n=e.length,r=0,i=!1;if(!n)return!1;if("-"!==(t=e[r])&&"+"!==t||(t=e[++r]),"0"===t){if(r+1===n)return!0;if("b"===(t=e[++r])){for(r++;r<n;r++)if("_"!==(t=e[r])){if("0"!==t&&"1"!==t)return!1;i=!0}return i&&"_"!==t}if("x"===t){for(r++;r<n;r++)if("_"!==(t=e[r])){if(!jn(e.charCodeAt(r)))return!1;i=!0}return i&&"_"!==t}if("o"===t){for(r++;r<n;r++)if("_"!==(t=e[r])){if(!Un(e.charCodeAt(r)))return!1;i=!0}return i&&"_"!==t}}if("_"===t)return!1;for(;r<n;r++)if("_"!==(t=e[r])){if(!Hn(e.charCodeAt(r)))return!1;i=!0}return!(!i||"_"===t)},construct:function(e){var t,n=e,r=1;if(-1!==n.indexOf("_")&&(n=n.replace(/_/g,"")),"-"!==(t=n[0])&&"+"!==t||("-"===t&&(r=-1),t=(n=n.slice(1))[0]),"0"===n)return 0;if("0"===t){if("b"===n[1])return r*parseInt(n.slice(2),2);if("x"===n[1])return r*parseInt(n.slice(2),16);if("o"===n[1])return r*parseInt(n.slice(2),8)}return r*parseInt(n,10)},predicate:function(e){return"[object Number]"===Object.prototype.toString.call(e)&&e%1===0&&!An.isNegativeZero(e)},represent:{binary:function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},octal:function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),qn=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");var Wn=/^[-+]?[0-9]+e/;var Gn=new Pn("tag:yaml.org,2002:float",{kind:"scalar",resolve:function(e){return null!==e&&!(!qn.test(e)||"_"===e[e.length-1])},construct:function(e){var t,n;return n="-"===(t=e.replace(/_/g,"").toLowerCase())[0]?-1:1,"+-".indexOf(t[0])>=0&&(t=t.slice(1)),".inf"===t?1===n?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:".nan"===t?NaN:n*parseFloat(t,10)},predicate:function(e){return"[object Number]"===Object.prototype.toString.call(e)&&(e%1!==0||An.isNegativeZero(e))},represent:function(e,t){var n;if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(An.isNegativeZero(e))return"-0.0";return n=e.toString(10),Wn.test(n)?n.replace("e",".e"):n},defaultStyle:"lowercase"}),Kn=Bn.extend({implicit:[$n,zn,Vn,Gn]}),Xn=Kn,Yn=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Zn=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");var Jn=new Pn("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:function(e){return null!==e&&(null!==Yn.exec(e)||null!==Zn.exec(e))},construct:function(e){var t,n,r,i,s,a,o,l,c=0,h=null;if(null===(t=Yn.exec(e))&&(t=Zn.exec(e)),null===t)throw new Error("Date resolve error");if(n=+t[1],r=+t[2]-1,i=+t[3],!t[4])return new Date(Date.UTC(n,r,i));if(s=+t[4],a=+t[5],o=+t[6],t[7]){for(c=t[7].slice(0,3);c.length<3;)c+="0";c=+c}return t[9]&&(h=6e4*(60*+t[10]+ +(t[11]||0)),"-"===t[9]&&(h=-h)),l=new Date(Date.UTC(n,r,i,s,a,o,c)),h&&l.setTime(l.getTime()-h),l},instanceOf:Date,represent:function(e){return e.toISOString()}});var Qn=new Pn("tag:yaml.org,2002:merge",{kind:"scalar",resolve:function(e){return"<<"===e||null===e}}),er="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r";var tr=new Pn("tag:yaml.org,2002:binary",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t,n,r=0,i=e.length,s=er;for(n=0;n<i;n++)if(!((t=s.indexOf(e.charAt(n)))>64)){if(t<0)return!1;r+=6}return r%8===0},construct:function(e){var t,n,r=e.replace(/[\r\n=]/g,""),i=r.length,s=er,a=0,o=[];for(t=0;t<i;t++)t%4===0&&t&&(o.push(a>>16&255),o.push(a>>8&255),o.push(255&a)),a=a<<6|s.indexOf(r.charAt(t));return 0===(n=i%4*6)?(o.push(a>>16&255),o.push(a>>8&255),o.push(255&a)):18===n?(o.push(a>>10&255),o.push(a>>2&255)):12===n&&o.push(a>>4&255),new Uint8Array(o)},predicate:function(e){return"[object Uint8Array]"===Object.prototype.toString.call(e)},represent:function(e){var t,n,r="",i=0,s=e.length,a=er;for(t=0;t<s;t++)t%3===0&&t&&(r+=a[i>>18&63],r+=a[i>>12&63],r+=a[i>>6&63],r+=a[63&i]),i=(i<<8)+e[t];return 0===(n=s%3)?(r+=a[i>>18&63],r+=a[i>>12&63],r+=a[i>>6&63],r+=a[63&i]):2===n?(r+=a[i>>10&63],r+=a[i>>4&63],r+=a[i<<2&63],r+=a[64]):1===n&&(r+=a[i>>2&63],r+=a[i<<4&63],r+=a[64],r+=a[64]),r}}),nr=Object.prototype.hasOwnProperty,rr=Object.prototype.toString;var ir=new Pn("tag:yaml.org,2002:omap",{kind:"sequence",resolve:function(e){if(null===e)return!0;var t,n,r,i,s,a=[],o=e;for(t=0,n=o.length;t<n;t+=1){if(r=o[t],s=!1,"[object Object]"!==rr.call(r))return!1;for(i in r)if(nr.call(r,i)){if(s)return!1;s=!0}if(!s)return!1;if(-1!==a.indexOf(i))return!1;a.push(i)}return!0},construct:function(e){return null!==e?e:[]}}),sr=Object.prototype.toString;var ar=new Pn("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:function(e){if(null===e)return!0;var t,n,r,i,s,a=e;for(s=new Array(a.length),t=0,n=a.length;t<n;t+=1){if(r=a[t],"[object Object]"!==sr.call(r))return!1;if(1!==(i=Object.keys(r)).length)return!1;s[t]=[i[0],r[i[0]]]}return!0},construct:function(e){if(null===e)return[];var t,n,r,i,s,a=e;for(s=new Array(a.length),t=0,n=a.length;t<n;t+=1)r=a[t],i=Object.keys(r),s[t]=[i[0],r[i[0]]];return s}}),or=Object.prototype.hasOwnProperty;var lr=new Pn("tag:yaml.org,2002:set",{kind:"mapping",resolve:function(e){if(null===e)return!0;var t,n=e;for(t in n)if(or.call(n,t)&&null!==n[t])return!1;return!0},construct:function(e){return null!==e?e:{}}}),cr=Xn.extend({implicit:[Jn,Qn],explicit:[tr,ir,ar,lr]}),hr=Object.prototype.hasOwnProperty,dr=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,ur=/[\x85\u2028\u2029]/,pr=/[,\[\]\{\}]/,fr=/^(?:!|!!|![a-z\-]+!)$/i,mr=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function gr(e){return Object.prototype.toString.call(e)}function vr(e){return 10===e||13===e}function yr(e){return 9===e||32===e}function br(e){return 9===e||32===e||10===e||13===e}function wr(e){return 44===e||91===e||93===e||123===e||125===e}function _r(e){var t;return 48<=e&&e<=57?e-48:97<=(t=32|e)&&t<=102?t-97+10:-1}function Ar(e){return 120===e?2:117===e?4:85===e?8:0}function xr(e){return 48<=e&&e<=57?e-48:-1}function Er(e){return 48===e?"\0":97===e?"\x07":98===e?"\b":116===e||9===e?"\t":110===e?"\n":118===e?"\v":102===e?"\f":114===e?"\r":101===e?"\x1b":32===e?" ":34===e?'"':47===e?"/":92===e?"\\":78===e?"\x85":95===e?"\xa0":76===e?"\u2028":80===e?"\u2029":""}function Cr(e){return e<=65535?String.fromCharCode(e):String.fromCharCode(55296+(e-65536>>10),56320+(e-65536&1023))}function kr(e,t,n){"__proto__"===t?Object.defineProperty(e,t,{configurable:!0,enumerable:!0,writable:!0,value:n}):e[t]=n}for(var Sr=new Array(256),Tr=new Array(256),Dr=0;Dr<256;Dr++)Sr[Dr]=Er(Dr)?1:0,Tr[Dr]=Er(Dr);function Mr(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||cr,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function Pr(e,t){var n={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return n.snippet=Tn(n),new Cn(t,n)}function Ir(e,t){throw Pr(e,t)}function Fr(e,t){e.onWarning&&e.onWarning.call(null,Pr(e,t))}var Rr={YAML:function(e,t,n){var r,i,s;null!==e.version&&Ir(e,"duplication of %YAML directive"),1!==n.length&&Ir(e,"YAML directive accepts exactly one argument"),null===(r=/^([0-9]+)\.([0-9]+)$/.exec(n[0]))&&Ir(e,"ill-formed argument of the YAML directive"),i=parseInt(r[1],10),s=parseInt(r[2],10),1!==i&&Ir(e,"unacceptable YAML version of the document"),e.version=n[0],e.checkLineBreaks=s<2,1!==s&&2!==s&&Fr(e,"unsupported YAML version of the document")},TAG:function(e,t,n){var r,i;2!==n.length&&Ir(e,"TAG directive accepts exactly two arguments"),r=n[0],i=n[1],fr.test(r)||Ir(e,"ill-formed tag handle (first argument) of the TAG directive"),hr.call(e.tagMap,r)&&Ir(e,'there is a previously declared suffix for "'+r+'" tag handle'),mr.test(i)||Ir(e,"ill-formed tag prefix (second argument) of the TAG directive");try{i=decodeURIComponent(i)}catch(s){Ir(e,"tag prefix is malformed: "+i)}e.tagMap[r]=i}};function Nr(e,t,n,r){var i,s,a,o;if(t<n){if(o=e.input.slice(t,n),r)for(i=0,s=o.length;i<s;i+=1)9===(a=o.charCodeAt(i))||32<=a&&a<=1114111||Ir(e,"expected valid JSON character");else dr.test(o)&&Ir(e,"the stream contains non-printable characters");e.result+=o}}function Lr(e,t,n,r){var i,s,a,o;for(An.isObject(n)||Ir(e,"cannot merge mappings; the provided source object is unacceptable"),a=0,o=(i=Object.keys(n)).length;a<o;a+=1)s=i[a],hr.call(t,s)||(kr(t,s,n[s]),r[s]=!0)}function Or(e,t,n,r,i,s,a,o,l){var c,h;if(Array.isArray(i))for(c=0,h=(i=Array.prototype.slice.call(i)).length;c<h;c+=1)Array.isArray(i[c])&&Ir(e,"nested arrays are not supported inside keys"),"object"===typeof i&&"[object Object]"===gr(i[c])&&(i[c]="[object Object]");if("object"===typeof i&&"[object Object]"===gr(i)&&(i="[object Object]"),i=String(i),null===t&&(t={}),"tag:yaml.org,2002:merge"===r)if(Array.isArray(s))for(c=0,h=s.length;c<h;c+=1)Lr(e,t,s[c],n);else Lr(e,t,s,n);else e.json||hr.call(n,i)||!hr.call(t,i)||(e.line=a||e.line,e.lineStart=o||e.lineStart,e.position=l||e.position,Ir(e,"duplicated mapping key")),kr(t,i,s),delete n[i];return t}function Br(e){var t;10===(t=e.input.charCodeAt(e.position))?e.position++:13===t?(e.position++,10===e.input.charCodeAt(e.position)&&e.position++):Ir(e,"a line break is expected"),e.line+=1,e.lineStart=e.position,e.firstTabInLine=-1}function $r(e,t,n){for(var r=0,i=e.input.charCodeAt(e.position);0!==i;){for(;yr(i);)9===i&&-1===e.firstTabInLine&&(e.firstTabInLine=e.position),i=e.input.charCodeAt(++e.position);if(t&&35===i)do{i=e.input.charCodeAt(++e.position)}while(10!==i&&13!==i&&0!==i);if(!vr(i))break;for(Br(e),i=e.input.charCodeAt(e.position),r++,e.lineIndent=0;32===i;)e.lineIndent++,i=e.input.charCodeAt(++e.position)}return-1!==n&&0!==r&&e.lineIndent<n&&Fr(e,"deficient indentation"),r}function zr(e){var t,n=e.position;return!(45!==(t=e.input.charCodeAt(n))&&46!==t||t!==e.input.charCodeAt(n+1)||t!==e.input.charCodeAt(n+2)||(n+=3,0!==(t=e.input.charCodeAt(n))&&!br(t)))}function jr(e,t){1===t?e.result+=" ":t>1&&(e.result+=An.repeat("\n",t-1))}function Ur(e,t){var n,r,i=e.tag,s=e.anchor,a=[],o=!1;if(-1!==e.firstTabInLine)return!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=a),r=e.input.charCodeAt(e.position);0!==r&&(-1!==e.firstTabInLine&&(e.position=e.firstTabInLine,Ir(e,"tab characters must not be used in indentation")),45===r)&&br(e.input.charCodeAt(e.position+1));)if(o=!0,e.position++,$r(e,!0,-1)&&e.lineIndent<=t)a.push(null),r=e.input.charCodeAt(e.position);else if(n=e.line,qr(e,t,3,!1,!0),a.push(e.result),$r(e,!0,-1),r=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>t)&&0!==r)Ir(e,"bad indentation of a sequence entry");else if(e.lineIndent<t)break;return!!o&&(e.tag=i,e.anchor=s,e.kind="sequence",e.result=a,!0)}function Hr(e){var t,n,r,i,s=!1,a=!1;if(33!==(i=e.input.charCodeAt(e.position)))return!1;if(null!==e.tag&&Ir(e,"duplication of a tag property"),60===(i=e.input.charCodeAt(++e.position))?(s=!0,i=e.input.charCodeAt(++e.position)):33===i?(a=!0,n="!!",i=e.input.charCodeAt(++e.position)):n="!",t=e.position,s){do{i=e.input.charCodeAt(++e.position)}while(0!==i&&62!==i);e.position<e.length?(r=e.input.slice(t,e.position),i=e.input.charCodeAt(++e.position)):Ir(e,"unexpected end of the stream within a verbatim tag")}else{for(;0!==i&&!br(i);)33===i&&(a?Ir(e,"tag suffix cannot contain exclamation marks"):(n=e.input.slice(t-1,e.position+1),fr.test(n)||Ir(e,"named tag handle cannot contain such characters"),a=!0,t=e.position+1)),i=e.input.charCodeAt(++e.position);r=e.input.slice(t,e.position),pr.test(r)&&Ir(e,"tag suffix cannot contain flow indicator characters")}r&&!mr.test(r)&&Ir(e,"tag name cannot contain such characters: "+r);try{r=decodeURIComponent(r)}catch(o){Ir(e,"tag name is malformed: "+r)}return s?e.tag=r:hr.call(e.tagMap,n)?e.tag=e.tagMap[n]+r:"!"===n?e.tag="!"+r:"!!"===n?e.tag="tag:yaml.org,2002:"+r:Ir(e,'undeclared tag handle "'+n+'"'),!0}function Vr(e){var t,n;if(38!==(n=e.input.charCodeAt(e.position)))return!1;for(null!==e.anchor&&Ir(e,"duplication of an anchor property"),n=e.input.charCodeAt(++e.position),t=e.position;0!==n&&!br(n)&&!wr(n);)n=e.input.charCodeAt(++e.position);return e.position===t&&Ir(e,"name of an anchor node must contain at least one character"),e.anchor=e.input.slice(t,e.position),!0}function qr(e,t,n,r,i){var s,a,o,l,c,h,d,u,p,f=1,m=!1,g=!1;if(null!==e.listener&&e.listener("open",e),e.tag=null,e.anchor=null,e.kind=null,e.result=null,s=a=o=4===n||3===n,r&&$r(e,!0,-1)&&(m=!0,e.lineIndent>t?f=1:e.lineIndent===t?f=0:e.lineIndent<t&&(f=-1)),1===f)for(;Hr(e)||Vr(e);)$r(e,!0,-1)?(m=!0,o=s,e.lineIndent>t?f=1:e.lineIndent===t?f=0:e.lineIndent<t&&(f=-1)):o=!1;if(o&&(o=m||i),1!==f&&4!==n||(u=1===n||2===n?t:t+1,p=e.position-e.lineStart,1===f?o&&(Ur(e,p)||function(e,t,n){var r,i,s,a,o,l,c,h=e.tag,d=e.anchor,u={},p=Object.create(null),f=null,m=null,g=null,v=!1,y=!1;if(-1!==e.firstTabInLine)return!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=u),c=e.input.charCodeAt(e.position);0!==c;){if(v||-1===e.firstTabInLine||(e.position=e.firstTabInLine,Ir(e,"tab characters must not be used in indentation")),r=e.input.charCodeAt(e.position+1),s=e.line,63!==c&&58!==c||!br(r)){if(a=e.line,o=e.lineStart,l=e.position,!qr(e,n,2,!1,!0))break;if(e.line===s){for(c=e.input.charCodeAt(e.position);yr(c);)c=e.input.charCodeAt(++e.position);if(58===c)br(c=e.input.charCodeAt(++e.position))||Ir(e,"a whitespace character is expected after the key-value separator within a block mapping"),v&&(Or(e,u,p,f,m,null,a,o,l),f=m=g=null),y=!0,v=!1,i=!1,f=e.tag,m=e.result;else{if(!y)return e.tag=h,e.anchor=d,!0;Ir(e,"can not read an implicit mapping pair; a colon is missed")}}else{if(!y)return e.tag=h,e.anchor=d,!0;Ir(e,"can not read a block mapping entry; a multiline key may not be an implicit key")}}else 63===c?(v&&(Or(e,u,p,f,m,null,a,o,l),f=m=g=null),y=!0,v=!0,i=!0):v?(v=!1,i=!0):Ir(e,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),e.position+=1,c=r;if((e.line===s||e.lineIndent>t)&&(v&&(a=e.line,o=e.lineStart,l=e.position),qr(e,t,4,!0,i)&&(v?m=e.result:g=e.result),v||(Or(e,u,p,f,m,g,a,o,l),f=m=g=null),$r(e,!0,-1),c=e.input.charCodeAt(e.position)),(e.line===s||e.lineIndent>t)&&0!==c)Ir(e,"bad indentation of a mapping entry");else if(e.lineIndent<t)break}return v&&Or(e,u,p,f,m,null,a,o,l),y&&(e.tag=h,e.anchor=d,e.kind="mapping",e.result=u),y}(e,p,u))||function(e,t){var n,r,i,s,a,o,l,c,h,d,u,p,f=!0,m=e.tag,g=e.anchor,v=Object.create(null);if(91===(p=e.input.charCodeAt(e.position)))a=93,c=!1,s=[];else{if(123!==p)return!1;a=125,c=!0,s={}}for(null!==e.anchor&&(e.anchorMap[e.anchor]=s),p=e.input.charCodeAt(++e.position);0!==p;){if($r(e,!0,t),(p=e.input.charCodeAt(e.position))===a)return e.position++,e.tag=m,e.anchor=g,e.kind=c?"mapping":"sequence",e.result=s,!0;f?44===p&&Ir(e,"expected the node content, but found ','"):Ir(e,"missed comma between flow collection entries"),u=null,o=l=!1,63===p&&br(e.input.charCodeAt(e.position+1))&&(o=l=!0,e.position++,$r(e,!0,t)),n=e.line,r=e.lineStart,i=e.position,qr(e,t,1,!1,!0),d=e.tag,h=e.result,$r(e,!0,t),p=e.input.charCodeAt(e.position),!l&&e.line!==n||58!==p||(o=!0,p=e.input.charCodeAt(++e.position),$r(e,!0,t),qr(e,t,1,!1,!0),u=e.result),c?Or(e,s,v,d,h,u,n,r,i):o?s.push(Or(e,null,v,d,h,u,n,r,i)):s.push(h),$r(e,!0,t),44===(p=e.input.charCodeAt(e.position))?(f=!0,p=e.input.charCodeAt(++e.position)):f=!1}Ir(e,"unexpected end of the stream within a flow collection")}(e,u)?g=!0:(a&&function(e,t){var n,r,i,s,a=1,o=!1,l=!1,c=t,h=0,d=!1;if(124===(s=e.input.charCodeAt(e.position)))r=!1;else{if(62!==s)return!1;r=!0}for(e.kind="scalar",e.result="";0!==s;)if(43===(s=e.input.charCodeAt(++e.position))||45===s)1===a?a=43===s?3:2:Ir(e,"repeat of a chomping mode identifier");else{if(!((i=xr(s))>=0))break;0===i?Ir(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):l?Ir(e,"repeat of an indentation width identifier"):(c=t+i-1,l=!0)}if(yr(s)){do{s=e.input.charCodeAt(++e.position)}while(yr(s));if(35===s)do{s=e.input.charCodeAt(++e.position)}while(!vr(s)&&0!==s)}for(;0!==s;){for(Br(e),e.lineIndent=0,s=e.input.charCodeAt(e.position);(!l||e.lineIndent<c)&&32===s;)e.lineIndent++,s=e.input.charCodeAt(++e.position);if(!l&&e.lineIndent>c&&(c=e.lineIndent),vr(s))h++;else{if(e.lineIndent<c){3===a?e.result+=An.repeat("\n",o?1+h:h):1===a&&o&&(e.result+="\n");break}for(r?yr(s)?(d=!0,e.result+=An.repeat("\n",o?1+h:h)):d?(d=!1,e.result+=An.repeat("\n",h+1)):0===h?o&&(e.result+=" "):e.result+=An.repeat("\n",h):e.result+=An.repeat("\n",o?1+h:h),o=!0,l=!0,h=0,n=e.position;!vr(s)&&0!==s;)s=e.input.charCodeAt(++e.position);Nr(e,n,e.position,!1)}}return!0}(e,u)||function(e,t){var n,r,i;if(39!==(n=e.input.charCodeAt(e.position)))return!1;for(e.kind="scalar",e.result="",e.position++,r=i=e.position;0!==(n=e.input.charCodeAt(e.position));)if(39===n){if(Nr(e,r,e.position,!0),39!==(n=e.input.charCodeAt(++e.position)))return!0;r=e.position,e.position++,i=e.position}else vr(n)?(Nr(e,r,i,!0),jr(e,$r(e,!1,t)),r=i=e.position):e.position===e.lineStart&&zr(e)?Ir(e,"unexpected end of the document within a single quoted scalar"):(e.position++,i=e.position);Ir(e,"unexpected end of the stream within a single quoted scalar")}(e,u)||function(e,t){var n,r,i,s,a,o;if(34!==(o=e.input.charCodeAt(e.position)))return!1;for(e.kind="scalar",e.result="",e.position++,n=r=e.position;0!==(o=e.input.charCodeAt(e.position));){if(34===o)return Nr(e,n,e.position,!0),e.position++,!0;if(92===o){if(Nr(e,n,e.position,!0),vr(o=e.input.charCodeAt(++e.position)))$r(e,!1,t);else if(o<256&&Sr[o])e.result+=Tr[o],e.position++;else if((a=Ar(o))>0){for(i=a,s=0;i>0;i--)(a=_r(o=e.input.charCodeAt(++e.position)))>=0?s=(s<<4)+a:Ir(e,"expected hexadecimal character");e.result+=Cr(s),e.position++}else Ir(e,"unknown escape sequence");n=r=e.position}else vr(o)?(Nr(e,n,r,!0),jr(e,$r(e,!1,t)),n=r=e.position):e.position===e.lineStart&&zr(e)?Ir(e,"unexpected end of the document within a double quoted scalar"):(e.position++,r=e.position)}Ir(e,"unexpected end of the stream within a double quoted scalar")}(e,u)?g=!0:!function(e){var t,n,r;if(42!==(r=e.input.charCodeAt(e.position)))return!1;for(r=e.input.charCodeAt(++e.position),t=e.position;0!==r&&!br(r)&&!wr(r);)r=e.input.charCodeAt(++e.position);return e.position===t&&Ir(e,"name of an alias node must contain at least one character"),n=e.input.slice(t,e.position),hr.call(e.anchorMap,n)||Ir(e,'unidentified alias "'+n+'"'),e.result=e.anchorMap[n],$r(e,!0,-1),!0}(e)?function(e,t,n){var r,i,s,a,o,l,c,h,d=e.kind,u=e.result;if(br(h=e.input.charCodeAt(e.position))||wr(h)||35===h||38===h||42===h||33===h||124===h||62===h||39===h||34===h||37===h||64===h||96===h)return!1;if((63===h||45===h)&&(br(r=e.input.charCodeAt(e.position+1))||n&&wr(r)))return!1;for(e.kind="scalar",e.result="",i=s=e.position,a=!1;0!==h;){if(58===h){if(br(r=e.input.charCodeAt(e.position+1))||n&&wr(r))break}else if(35===h){if(br(e.input.charCodeAt(e.position-1)))break}else{if(e.position===e.lineStart&&zr(e)||n&&wr(h))break;if(vr(h)){if(o=e.line,l=e.lineStart,c=e.lineIndent,$r(e,!1,-1),e.lineIndent>=t){a=!0,h=e.input.charCodeAt(e.position);continue}e.position=s,e.line=o,e.lineStart=l,e.lineIndent=c;break}}a&&(Nr(e,i,s,!1),jr(e,e.line-o),i=s=e.position,a=!1),yr(h)||(s=e.position+1),h=e.input.charCodeAt(++e.position)}return Nr(e,i,s,!1),!!e.result||(e.kind=d,e.result=u,!1)}(e,u,1===n)&&(g=!0,null===e.tag&&(e.tag="?")):(g=!0,null===e.tag&&null===e.anchor||Ir(e,"alias node should not have any properties")),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):0===f&&(g=o&&Ur(e,p))),null===e.tag)null!==e.anchor&&(e.anchorMap[e.anchor]=e.result);else if("?"===e.tag){for(null!==e.result&&"scalar"!==e.kind&&Ir(e,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+e.kind+'"'),l=0,c=e.implicitTypes.length;l<c;l+=1)if((d=e.implicitTypes[l]).resolve(e.result)){e.result=d.construct(e.result),e.tag=d.tag,null!==e.anchor&&(e.anchorMap[e.anchor]=e.result);break}}else if("!"!==e.tag){if(hr.call(e.typeMap[e.kind||"fallback"],e.tag))d=e.typeMap[e.kind||"fallback"][e.tag];else for(d=null,l=0,c=(h=e.typeMap.multi[e.kind||"fallback"]).length;l<c;l+=1)if(e.tag.slice(0,h[l].tag.length)===h[l].tag){d=h[l];break}d||Ir(e,"unknown tag !<"+e.tag+">"),null!==e.result&&d.kind!==e.kind&&Ir(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+d.kind+'", not "'+e.kind+'"'),d.resolve(e.result,e.tag)?(e.result=d.construct(e.result,e.tag),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):Ir(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")}return null!==e.listener&&e.listener("close",e),null!==e.tag||null!==e.anchor||g}function Wr(e){var t,n,r,i,s=e.position,a=!1;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);0!==(i=e.input.charCodeAt(e.position))&&($r(e,!0,-1),i=e.input.charCodeAt(e.position),!(e.lineIndent>0||37!==i));){for(a=!0,i=e.input.charCodeAt(++e.position),t=e.position;0!==i&&!br(i);)i=e.input.charCodeAt(++e.position);for(r=[],(n=e.input.slice(t,e.position)).length<1&&Ir(e,"directive name must not be less than one character in length");0!==i;){for(;yr(i);)i=e.input.charCodeAt(++e.position);if(35===i){do{i=e.input.charCodeAt(++e.position)}while(0!==i&&!vr(i));break}if(vr(i))break;for(t=e.position;0!==i&&!br(i);)i=e.input.charCodeAt(++e.position);r.push(e.input.slice(t,e.position))}0!==i&&Br(e),hr.call(Rr,n)?Rr[n](e,n,r):Fr(e,'unknown document directive "'+n+'"')}$r(e,!0,-1),0===e.lineIndent&&45===e.input.charCodeAt(e.position)&&45===e.input.charCodeAt(e.position+1)&&45===e.input.charCodeAt(e.position+2)?(e.position+=3,$r(e,!0,-1)):a&&Ir(e,"directives end mark is expected"),qr(e,e.lineIndent-1,4,!1,!0),$r(e,!0,-1),e.checkLineBreaks&&ur.test(e.input.slice(s,e.position))&&Fr(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&zr(e)?46===e.input.charCodeAt(e.position)&&(e.position+=3,$r(e,!0,-1)):e.position<e.length-1&&Ir(e,"end of the stream or a document separator is expected")}function Gr(e,t){t=t||{},0!==(e=String(e)).length&&(10!==e.charCodeAt(e.length-1)&&13!==e.charCodeAt(e.length-1)&&(e+="\n"),65279===e.charCodeAt(0)&&(e=e.slice(1)));var n=new Mr(e,t),r=e.indexOf("\0");for(-1!==r&&(n.position=r,Ir(n,"null byte is not allowed in input")),n.input+="\0";32===n.input.charCodeAt(n.position);)n.lineIndent+=1,n.position+=1;for(;n.position<n.length-1;)Wr(n);return n.documents}var Kr={loadAll:function(e,t,n){null!==t&&"object"===typeof t&&"undefined"===typeof n&&(n=t,t=null);var r=Gr(e,n);if("function"!==typeof t)return r;for(var i=0,s=r.length;i<s;i+=1)t(r[i])},load:function(e,t){var n=Gr(e,t);if(0!==n.length){if(1===n.length)return n[0];throw new Cn("expected a single document in the stream, but found more")}}},Xr=Object.prototype.toString,Yr=Object.prototype.hasOwnProperty,Zr=65279,Jr={0:"\\0",7:"\\a",8:"\\b",9:"\\t",10:"\\n",11:"\\v",12:"\\f",13:"\\r",27:"\\e",34:'\\"',92:"\\\\",133:"\\N",160:"\\_",8232:"\\L",8233:"\\P"},Qr=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],ei=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function ti(e){var t,n,r;if(t=e.toString(16).toUpperCase(),e<=255)n="x",r=2;else if(e<=65535)n="u",r=4;else{if(!(e<=4294967295))throw new Cn("code point within a string may not be greater than 0xFFFFFFFF");n="U",r=8}return"\\"+n+An.repeat("0",r-t.length)+t}function ni(e){this.schema=e.schema||cr,this.indent=Math.max(1,e.indent||2),this.noArrayIndent=e.noArrayIndent||!1,this.skipInvalid=e.skipInvalid||!1,this.flowLevel=An.isNothing(e.flowLevel)?-1:e.flowLevel,this.styleMap=function(e,t){var n,r,i,s,a,o,l;if(null===t)return{};for(n={},i=0,s=(r=Object.keys(t)).length;i<s;i+=1)a=r[i],o=String(t[a]),"!!"===a.slice(0,2)&&(a="tag:yaml.org,2002:"+a.slice(2)),(l=e.compiledTypeMap.fallback[a])&&Yr.call(l.styleAliases,o)&&(o=l.styleAliases[o]),n[a]=o;return n}(this.schema,e.styles||null),this.sortKeys=e.sortKeys||!1,this.lineWidth=e.lineWidth||80,this.noRefs=e.noRefs||!1,this.noCompatMode=e.noCompatMode||!1,this.condenseFlow=e.condenseFlow||!1,this.quotingType='"'===e.quotingType?2:1,this.forceQuotes=e.forceQuotes||!1,this.replacer="function"===typeof e.replacer?e.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function ri(e,t){for(var n,r=An.repeat(" ",t),i=0,s=-1,a="",o=e.length;i<o;)-1===(s=e.indexOf("\n",i))?(n=e.slice(i),i=o):(n=e.slice(i,s+1),i=s+1),n.length&&"\n"!==n&&(a+=r),a+=n;return a}function ii(e,t){return"\n"+An.repeat(" ",e.indent*t)}function si(e){return 32===e||9===e}function ai(e){return 32<=e&&e<=126||161<=e&&e<=55295&&8232!==e&&8233!==e||57344<=e&&e<=65533&&e!==Zr||65536<=e&&e<=1114111}function oi(e){return ai(e)&&e!==Zr&&13!==e&&10!==e}function li(e,t,n){var r=oi(e),i=r&&!si(e);return(n?r:r&&44!==e&&91!==e&&93!==e&&123!==e&&125!==e)&&35!==e&&!(58===t&&!i)||oi(t)&&!si(t)&&35===e||58===t&&i}function ci(e,t){var n,r=e.charCodeAt(t);return r>=55296&&r<=56319&&t+1<e.length&&(n=e.charCodeAt(t+1))>=56320&&n<=57343?1024*(r-55296)+n-56320+65536:r}function hi(e){return/^\n* /.test(e)}function di(e,t,n,r,i,s,a,o){var l,c,h=0,d=null,u=!1,p=!1,f=-1!==r,m=-1,g=ai(c=ci(e,0))&&c!==Zr&&!si(c)&&45!==c&&63!==c&&58!==c&&44!==c&&91!==c&&93!==c&&123!==c&&125!==c&&35!==c&&38!==c&&42!==c&&33!==c&&124!==c&&61!==c&&62!==c&&39!==c&&34!==c&&37!==c&&64!==c&&96!==c&&function(e){return!si(e)&&58!==e}(ci(e,e.length-1));if(t||a)for(l=0;l<e.length;h>=65536?l+=2:l++){if(!ai(h=ci(e,l)))return 5;g=g&&li(h,d,o),d=h}else{for(l=0;l<e.length;h>=65536?l+=2:l++){if(10===(h=ci(e,l)))u=!0,f&&(p=p||l-m-1>r&&" "!==e[m+1],m=l);else if(!ai(h))return 5;g=g&&li(h,d,o),d=h}p=p||f&&l-m-1>r&&" "!==e[m+1]}return u||p?n>9&&hi(e)?5:a?2===s?5:2:p?4:3:!g||a||i(e)?2===s?5:2:1}function ui(e,t,n,r,i){e.dump=function(){if(0===t.length)return 2===e.quotingType?'""':"''";if(!e.noCompatMode&&(-1!==Qr.indexOf(t)||ei.test(t)))return 2===e.quotingType?'"'+t+'"':"'"+t+"'";var s=e.indent*Math.max(1,n),a=-1===e.lineWidth?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-s),o=r||e.flowLevel>-1&&n>=e.flowLevel;switch(di(t,o,e.indent,a,function(t){return function(e,t){var n,r;for(n=0,r=e.implicitTypes.length;n<r;n+=1)if(e.implicitTypes[n].resolve(t))return!0;return!1}(e,t)},e.quotingType,e.forceQuotes&&!r,i)){case 1:return t;case 2:return"'"+t.replace(/'/g,"''")+"'";case 3:return"|"+pi(t,e.indent)+fi(ri(t,s));case 4:return">"+pi(t,e.indent)+fi(ri(function(e,t){var n,r,i=/(\n+)([^\n]*)/g,s=function(){var n=e.indexOf("\n");return n=-1!==n?n:e.length,i.lastIndex=n,mi(e.slice(0,n),t)}(),a="\n"===e[0]||" "===e[0];for(;r=i.exec(e);){var o=r[1],l=r[2];n=" "===l[0],s+=o+(a||n||""===l?"":"\n")+mi(l,t),a=n}return s}(t,a),s));case 5:return'"'+function(e){for(var t,n="",r=0,i=0;i<e.length;r>=65536?i+=2:i++)r=ci(e,i),!(t=Jr[r])&&ai(r)?(n+=e[i],r>=65536&&(n+=e[i+1])):n+=t||ti(r);return n}(t)+'"';default:throw new Cn("impossible error: invalid scalar style")}}()}function pi(e,t){var n=hi(e)?String(t):"",r="\n"===e[e.length-1];return n+(r&&("\n"===e[e.length-2]||"\n"===e)?"+":r?"":"-")+"\n"}function fi(e){return"\n"===e[e.length-1]?e.slice(0,-1):e}function mi(e,t){if(""===e||" "===e[0])return e;for(var n,r,i=/ [^ ]/g,s=0,a=0,o=0,l="";n=i.exec(e);)(o=n.index)-s>t&&(r=a>s?a:o,l+="\n"+e.slice(s,r),s=r+1),a=o;return l+="\n",e.length-s>t&&a>s?l+=e.slice(s,a)+"\n"+e.slice(a+1):l+=e.slice(s),l.slice(1)}function gi(e,t,n,r){var i,s,a,o="",l=e.tag;for(i=0,s=n.length;i<s;i+=1)a=n[i],e.replacer&&(a=e.replacer.call(n,String(i),a)),(yi(e,t+1,a,!0,!0,!1,!0)||"undefined"===typeof a&&yi(e,t+1,null,!0,!0,!1,!0))&&(r&&""===o||(o+=ii(e,t)),e.dump&&10===e.dump.charCodeAt(0)?o+="-":o+="- ",o+=e.dump);e.tag=l,e.dump=o||"[]"}function vi(e,t,n){var r,i,s,a,o,l;for(s=0,a=(i=n?e.explicitTypes:e.implicitTypes).length;s<a;s+=1)if(((o=i[s]).instanceOf||o.predicate)&&(!o.instanceOf||"object"===typeof t&&t instanceof o.instanceOf)&&(!o.predicate||o.predicate(t))){if(n?o.multi&&o.representName?e.tag=o.representName(t):e.tag=o.tag:e.tag="?",o.represent){if(l=e.styleMap[o.tag]||o.defaultStyle,"[object Function]"===Xr.call(o.represent))r=o.represent(t,l);else{if(!Yr.call(o.represent,l))throw new Cn("!<"+o.tag+'> tag resolver accepts not "'+l+'" style');r=o.represent[l](t,l)}e.dump=r}return!0}return!1}function yi(e,t,n,r,i,s,a){e.tag=null,e.dump=n,vi(e,n,!1)||vi(e,n,!0);var o,l=Xr.call(e.dump),c=r;r&&(r=e.flowLevel<0||e.flowLevel>t);var h,d,u="[object Object]"===l||"[object Array]"===l;if(u&&(d=-1!==(h=e.duplicates.indexOf(n))),(null!==e.tag&&"?"!==e.tag||d||2!==e.indent&&t>0)&&(i=!1),d&&e.usedDuplicates[h])e.dump="*ref_"+h;else{if(u&&d&&!e.usedDuplicates[h]&&(e.usedDuplicates[h]=!0),"[object Object]"===l)r&&0!==Object.keys(e.dump).length?(!function(e,t,n,r){var i,s,a,o,l,c,h="",d=e.tag,u=Object.keys(n);if(!0===e.sortKeys)u.sort();else if("function"===typeof e.sortKeys)u.sort(e.sortKeys);else if(e.sortKeys)throw new Cn("sortKeys must be a boolean or a function");for(i=0,s=u.length;i<s;i+=1)c="",r&&""===h||(c+=ii(e,t)),o=n[a=u[i]],e.replacer&&(o=e.replacer.call(n,a,o)),yi(e,t+1,a,!0,!0,!0)&&((l=null!==e.tag&&"?"!==e.tag||e.dump&&e.dump.length>1024)&&(e.dump&&10===e.dump.charCodeAt(0)?c+="?":c+="? "),c+=e.dump,l&&(c+=ii(e,t)),yi(e,t+1,o,!0,l)&&(e.dump&&10===e.dump.charCodeAt(0)?c+=":":c+=": ",h+=c+=e.dump));e.tag=d,e.dump=h||"{}"}(e,t,e.dump,i),d&&(e.dump="&ref_"+h+e.dump)):(!function(e,t,n){var r,i,s,a,o,l="",c=e.tag,h=Object.keys(n);for(r=0,i=h.length;r<i;r+=1)o="",""!==l&&(o+=", "),e.condenseFlow&&(o+='"'),a=n[s=h[r]],e.replacer&&(a=e.replacer.call(n,s,a)),yi(e,t,s,!1,!1)&&(e.dump.length>1024&&(o+="? "),o+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" "),yi(e,t,a,!1,!1)&&(l+=o+=e.dump));e.tag=c,e.dump="{"+l+"}"}(e,t,e.dump),d&&(e.dump="&ref_"+h+" "+e.dump));else if("[object Array]"===l)r&&0!==e.dump.length?(e.noArrayIndent&&!a&&t>0?gi(e,t-1,e.dump,i):gi(e,t,e.dump,i),d&&(e.dump="&ref_"+h+e.dump)):(!function(e,t,n){var r,i,s,a="",o=e.tag;for(r=0,i=n.length;r<i;r+=1)s=n[r],e.replacer&&(s=e.replacer.call(n,String(r),s)),(yi(e,t,s,!1,!1)||"undefined"===typeof s&&yi(e,t,null,!1,!1))&&(""!==a&&(a+=","+(e.condenseFlow?"":" ")),a+=e.dump);e.tag=o,e.dump="["+a+"]"}(e,t,e.dump),d&&(e.dump="&ref_"+h+" "+e.dump));else{if("[object String]"!==l){if("[object Undefined]"===l)return!1;if(e.skipInvalid)return!1;throw new Cn("unacceptable kind of an object to dump "+l)}"?"!==e.tag&&ui(e,e.dump,t,s,c)}null!==e.tag&&"?"!==e.tag&&(o=encodeURI("!"===e.tag[0]?e.tag.slice(1):e.tag).replace(/!/g,"%21"),o="!"===e.tag[0]?"!"+o:"tag:yaml.org,2002:"===o.slice(0,18)?"!!"+o.slice(18):"!<"+o+">",e.dump=o+" "+e.dump)}return!0}function bi(e,t){var n,r,i=[],s=[];for(wi(e,i,s),n=0,r=s.length;n<r;n+=1)t.duplicates.push(i[s[n]]);t.usedDuplicates=new Array(r)}function wi(e,t,n){var r,i,s;if(null!==e&&"object"===typeof e)if(-1!==(i=t.indexOf(e)))-1===n.indexOf(i)&&n.push(i);else if(t.push(e),Array.isArray(e))for(i=0,s=e.length;i<s;i+=1)wi(e[i],t,n);else for(i=0,s=(r=Object.keys(e)).length;i<s;i+=1)wi(e[r[i]],t,n)}function _i(e,t){return function(){throw new Error("Function yaml."+e+" is removed in js-yaml 4. Use yaml."+t+" instead, which is now safe by default.")}}var Ai={Type:Pn,Schema:Rn,FAILSAFE_SCHEMA:Bn,JSON_SCHEMA:Kn,CORE_SCHEMA:Xn,DEFAULT_SCHEMA:cr,load:Kr.load,loadAll:Kr.loadAll,dump:{dump:function(e,t){var n=new ni(t=t||{});n.noRefs||bi(e,n);var r=e;return n.replacer&&(r=n.replacer.call({"":r},"",r)),yi(n,0,r,!0,!0)?n.dump+"\n":""}}.dump,YAMLException:Cn,types:{binary:tr,float:Gn,map:On,null:$n,pairs:ar,set:lr,timestamp:Jn,bool:zn,int:Vn,merge:Qn,omap:ir,seq:Ln,str:Nn},safeLoad:_i("safeLoad","load"),safeLoadAll:_i("safeLoadAll","loadAll"),safeDump:_i("safeDump","dump")},xi=n(14225),Ei=n.n(xi),Ci=n(59107);const ki=Ci.default||Ci;var Si=n(78678),Ti=n(64755),Di=n.n(Ti);function Mi(){return Mi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Mi.apply(null,arguments)}const Pi=(new(Ei())).compile({type:"object",properties:{"md-components":{type:"object",properties:{type:{type:"string"},props:{type:"object"}},required:["type","props"]}},required:["md-components"]}),Ii=function(e){const t=e.renderer.rules.fence,n=e.renderer.rules.code_inline;e.renderer.rules.code_inline=function(e,t,r,i,s){const a=e[t];try{if(/^md-components/.test(a.content)){const e=/md-components:(\w+)\{([^}]+)}/g;let t;const n=[];for(;null!==(t=e.exec(a.content));)n.push({componentsType:t[1],props:t[2]});if(n.length>0)return n.map(e=>{let{componentsType:t,props:n}=e;const r={"md-components":{type:t,props:JSON.parse(`{${n}}`)}};if(Pi(r)){const e=document.createElement("code");return e.setAttribute("class","md-components"),e.dataset.components=JSON.stringify(r),e.outerHTML}return""}).join("")}}catch(o){console.warn(o)}return n(e,t,r,i,s)},e.renderer.rules.fence=function(e,n,r,i,s){const a=e[n];if("yml"===a.info.trim())try{const e=Ai.load(a.content);if(Pi(e)){const t=document.createElement("pre");return t.setAttribute("class","md-components"),t.dataset.components=JSON.stringify(e),t.outerHTML}}catch(o){console.warn(o)}return t(e,n,r,i,s)}},Fi=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(Array.isArray(e))return e.map(e=>Fi(e,t));if(e&&"[object Object]"===e.toString()&&Object.keys(e).length>0){const n={};return Object.keys(e).forEach(r=>{n[r]=Fi(e[r],t)}),n}return e&&"string"===typeof e&&"$"===e.charAt(0)&&t&&t[e.substring(1)]?t[e.substring(1)]:e};var Ri=function(e){var t={exports:{}};return e(t,t.exports),t.exports}(function(e){!function(){var t={}.hasOwnProperty;function n(){for(var e="",t=0;t<arguments.length;t++){var n=arguments[t];n&&(e=i(e,r(n)))}return e}function r(e){if("string"===typeof e||"number"===typeof e)return e;if("object"!==typeof e)return"";if(Array.isArray(e))return n.apply(null,e);if(e.toString!==Object.prototype.toString&&!e.toString.toString().includes("[native code]"))return e.toString();var r="";for(var s in e)t.call(e,s)&&e[s]&&(r=i(r,s));return r}function i(e,t){return t?e?e+" "+t:e+t:e}e.exports?(n.default=n,e.exports=n):window.classNames=n}()}),Ni="_wcble";const Li=e=>{let{className:t,html:n,variables:r,components:i={}}=e;return o.createElement("div",{className:Ri(Ni,t)},ki(n,{replace(e){if(e.attribs&&"md-components"===e.attribs.class&&e.attribs["data-components"]){const t=JSON.parse(e.attribs["data-components"]);if(!t["md-components"])return null;const{type:n,props:s}=t["md-components"],a=i[n];if(!a)return null;const l=Fi(s,r);if(l.children&&Array.isArray(l.children)){const e=((e,t,n)=>e?Array.isArray(e)?e.map((e,r)=>{if(e&&"object"===typeof e&&e.type&&e.props){const i=n[e.type];if(i){const n=Fi(e.props,t);return o.createElement(i,Mi({key:r},n))}}return e}):e:null)(l.children,r,i);return o.createElement(a,l,e)}return o.createElement(a,l)}return e}}))},Oi={};const Bi=["children","render"],$i=e=>{let{children:t="",render:n}=e,r=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}(e,Bi);const{htmlTransform:i,components:s={},variables:a={},options:l}=Di()({},Oi,r),c=(0,Si.A)(e=>{const{config:t,plugins:n}=Object.assign({},l,{config:{},plugins:[]}),r=wn(t);n.forEach(e=>{const t=Array.isArray(e)?e:[e];r.use(...t)}),r.use(Ii);const c=r.render(e);return o.createElement(Li,{html:"function"===typeof i?i(c):c,variables:a,components:s})}),h=(0,o.useMemo)(()=>c(t),[t,c]);return"function"===typeof n?n(h):h}},88406(e,t,n){"use strict";n.d(t,{A:()=>a});var r=n(94922);function i(){return i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},i.apply(this,arguments)}var s={doc:e=>r.createElement("svg",i({t:1646123881490,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":1408,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":1409}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":1410}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":1411}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#2C97FF","p-id":1412}),r.createElement("path",{d:"M192 544h-48a16 16 0 0 0-16 16v192a16 16 0 0 0 16 16h48a64 64 0 0 0 64-64v-96a64 64 0 0 0-64-64z m0 192h-32V576h32a32 32 0 0 1 32 32v96a32 32 0 0 1-32 32z m160-192a64 64 0 0 0-64 64v96a64 64 0 0 0 64 64 64 64 0 0 0 64-64v-96a64 64 0 0 0-64-64z m32 160a32 32 0 0 1-32 32 32 32 0 0 1-32-32v-96a32 32 0 0 1 32-32 32 32 0 0 1 32 32z m128 32a32 32 0 0 1-32-32v-96a32 32 0 0 1 32-32 32 32 0 0 1 32 32h32a64 64 0 0 0-64-64 64 64 0 0 0-64 64v96a64 64 0 0 0 64 64 64 64 0 0 0 64-64h-32a32 32 0 0 1-32 32z",fill:"#FFFFFF","p-id":1413})),docx:e=>r.createElement("svg",i({t:1646123881490,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":1408,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":1409}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":1410}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":1411}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#2C97FF","p-id":1412}),r.createElement("path",{d:"M192 544h-48a16 16 0 0 0-16 16v192a16 16 0 0 0 16 16h48a64 64 0 0 0 64-64v-96a64 64 0 0 0-64-64z m0 192h-32V576h32a32 32 0 0 1 32 32v96a32 32 0 0 1-32 32z m160-192a64 64 0 0 0-64 64v96a64 64 0 0 0 64 64 64 64 0 0 0 64-64v-96a64 64 0 0 0-64-64z m32 160a32 32 0 0 1-32 32 32 32 0 0 1-32-32v-96a32 32 0 0 1 32-32 32 32 0 0 1 32 32z m128 32a32 32 0 0 1-32-32v-96a32 32 0 0 1 32-32 32 32 0 0 1 32 32h32a64 64 0 0 0-64-64 64 64 0 0 0-64 64v96a64 64 0 0 0 64 64 64 64 0 0 0 64-64h-32a32 32 0 0 1-32 32z",fill:"#FFFFFF","p-id":1413})),gif:e=>r.createElement("svg",i({t:1646123917228,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":1827,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":1828}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":1829}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":1830}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#CC7598","p-id":1831}),r.createElement("path",{d:"M288 672h-80a16 16 0 0 0 0 32h48a32 32 0 0 1-32 32h-32a32 32 0 0 1-32-32v-96a32 32 0 0 1 32-32h32a32 32 0 0 1 32 32 16 16 0 0 0 32 0 64 64 0 0 0-64-64h-32a64 64 0 0 0-64 64v96a64 64 0 0 0 64 64h32a64 64 0 0 0 64-64 16 16 0 0 0 0-32z m96 80a16 16 0 0 1-16 16 16 16 0 0 1-16-16V560a16 16 0 0 1 16-16 16 16 0 0 1 16 16z m176-208h-96a16 16 0 0 0-16 16v192a16 16 0 0 0 32 0v-80h48a16 16 0 0 0 0-32h-48v-64h80a16 16 0 0 0 0-32z",fill:"#FFFFFF","p-id":1832})),html:e=>r.createElement("svg",i({t:1646123902e3,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":9201,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":9202}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":9203}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":9204}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#009688","p-id":9205}),r.createElement("text",{x:352,y:700,fontSize:240,fontWeight:"bold",fill:"#FFFFFF",fontFamily:"Arial, sans-serif",textAnchor:"middle",dominantBaseline:"middle"},"HTML")),jpg:e=>r.createElement("svg",i({t:1646123877293,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":1269,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":1270}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":1271}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":1272}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#BAF1CD","p-id":1273}),r.createElement("path",{d:"M320 544h-48a16 16 0 0 0-16 16v192a16 16 0 0 0 32 0v-80h32a64 64 0 0 0 0-128z m0 96h-32v-64h32a32 32 0 0 1 0 64z m256 32h-80a16 16 0 0 0 0 32h48a32 32 0 0 1-32 32h-32a32 32 0 0 1-32-32v-96a32 32 0 0 1 32-32h32a32 32 0 0 1 32 32 16 16 0 0 0 32 0 64 64 0 0 0-64-64h-32a64 64 0 0 0-64 64v96a64 64 0 0 0 64 64h32a64 64 0 0 0 64-64 16 16 0 0 0 0-32zM208 544a16 16 0 0 0-16 16v144a32 32 0 0 1-64 0v-16a16 16 0 0 0-32 0v16a64 64 0 0 0 128 0V560a16 16 0 0 0-16-16z",fill:"#FFFFFF","p-id":1274})),md:e=>r.createElement("svg",i({t:16461239e5,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":9001,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":9002}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":9003}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":9004}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#000000","p-id":9005}),r.createElement("text",{x:352,y:700,fontSize:240,fontWeight:"bold",fill:"#FFFFFF",fontFamily:"Arial, sans-serif",textAnchor:"middle",dominantBaseline:"middle"},"MD")),mp4:e=>r.createElement("svg",i({t:1646123927989,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":1966,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192c-35.328 0-64 28.672-64 64v320h576c35.328 0 64 28.672 64 64v415.744c0 35.328-28.672 64-64 64H128v31.744c0 35.328 28.672 64 64 64h768c35.328 0 64-28.672 64-64v-640L704 0z",fill:"#EAEAEA","p-id":1967}),r.createElement("path",{d:"M704 0v256c0 35.328 28.672 64 64 64h256L704 0z",fill:"#434854","p-id":1968}),r.createElement("path",{d:"M768 320l256 256V320z",opacity:.1,"p-id":1969}),r.createElement("path",{d:"M704 832c0 17.92-14.336 31.744-31.744 31.744H31.744C13.824 863.744 0 849.408 0 832V480.256c0-17.92 14.336-31.744 31.744-31.744h640c17.92 0 31.744 14.336 31.744 31.744V832z",fill:"#724AE2","p-id":1970}),r.createElement("path",{d:"M537.088 547.84c9.728 0 14.336 4.608 14.336 13.824v132.608h18.944c9.728 0.512 14.336 4.608 14.336 13.312s-5.12 13.312-15.36 13.312h-18.432v37.888c-0.512 9.728-5.12 14.336-13.824 14.336s-13.312-5.12-13.312-15.36v-36.864h-79.36c-12.8-0.512-19.456-4.096-19.456-11.776 0-4.096 1.536-7.68 4.096-11.776l94.208-141.312 0.512-1.024c3.584-4.608 8.192-7.168 13.312-7.168z m-302.592-1.536c7.168 0 11.264 5.12 11.264 15.872v193.536c0 10.752-4.608 15.872-11.264 15.872s-11.264-5.12-11.264-15.872V622.08l-44.544 140.8c-2.048 6.144-8.192 8.704-12.288 8.704s-10.24-3.072-12.288-8.704l-46.08-140.8v133.632c0 10.752-6.144 15.872-12.8 15.872s-12.8-5.12-12.8-15.872V562.176c0-10.752 5.632-15.872 12.8-15.872 4.608 0 10.752 3.072 12.8 8.704L166.4 728.064l56.832-173.056c2.048-6.144 6.144-8.704 11.264-8.704z m121.856 0c35.328 0 63.488 28.672 63.488 64 0 34.816-27.648 62.976-62.464 64h-33.28v79.872c0 8.704-7.168 15.872-15.872 15.872-8.192 0-15.36-6.656-15.872-14.848V562.176c0-8.192 6.656-15.36 14.848-15.872h49.152z m166.912 58.368l-59.904 90.112h59.904v-90.112z m-166.912-26.624h-31.744v64h31.744c17.92 0 31.744-14.848 31.744-32.256s-13.824-31.744-31.744-31.744z",fill:"#FFFFFF","p-id":1971})),pdf:e=>r.createElement("svg",i({t:1646123842588,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":1304,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192c-35.328 0-64 28.672-64 64v320h576c35.328 0 64 28.672 64 64v415.744c0 35.328-28.672 64-64 64H128v31.744c0 35.328 28.672 64 64 64h768c35.328 0 64-28.672 64-64v-640L704 0z",fill:"#EAEAEA","p-id":1305}),r.createElement("path",{d:"M704 0v256c0 35.328 28.672 64 64 64h256L704 0z",fill:"#434854","p-id":1306}),r.createElement("path",{d:"M768 320l256 256V320z",opacity:.1,"p-id":1307}),r.createElement("path",{d:"M704 832c0 17.92-14.336 31.744-31.744 31.744H31.744C13.824 863.744 0 849.408 0 832V480.256c0-17.92 14.336-31.744 31.744-31.744h640c17.92 0 31.744 14.336 31.744 31.744V832z",fill:"#CD4050","p-id":1308}),r.createElement("path",{d:"M192 544.256h-48.128c-8.704 0-15.872 7.168-15.872 15.872v192c0 8.704 7.168 15.872 15.872 15.872s15.872-7.168 15.872-15.872v-79.872h31.744c35.328 0 64-28.672 64-64s-28.16-64-63.488-64z m158.72 0c34.816 0 62.976 27.648 64 62.464v97.792c0 34.816-27.648 62.976-62.464 64h-49.664c-8.704 0-15.36-6.656-15.872-14.848V560.64c0-8.704 6.656-15.36 14.848-15.872h49.152z m227.328 0c8.704 0 15.872 7.168 15.872 15.872S586.752 576 578.048 576h-80.384v64h48.128c8.704 0 15.872 7.168 15.872 15.872s-7.168 15.872-15.872 15.872h-48.128v79.872c0 8.704-7.168 15.872-15.872 15.872s-15.872-7.168-15.872-15.872v-192c0-8.704 7.168-15.872 15.872-15.872h96.256zM350.72 576h-31.744v159.744h31.744c17.408 0 31.232-13.824 31.744-30.72v-97.28C382.976 590.336 368.64 576 350.72 576zM192 576c17.92 0 31.744 14.336 31.744 31.744S209.92 640 192 640h-31.744v-64H192z",fill:"#FFFFFF","p-id":1309})),png:e=>r.createElement("svg",i({t:1646123868693,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":1130,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":1131}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":1132}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":1133}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#BAF1CD","p-id":1134}),r.createElement("path",{d:"M160 544h-48a16 16 0 0 0-16 16v192a16 16 0 0 0 32 0v-80h32a64 64 0 0 0 0-128z m0 96h-32v-64h32a32 32 0 0 1 0 64z m448 32h-80a16 16 0 0 0 0 32h48a32 32 0 0 1-32 32h-32a32 32 0 0 1-32-32v-96a32 32 0 0 1 32-32h32a32 32 0 0 1 32 32 16 16 0 0 0 32 0 64 64 0 0 0-64-64h-32a64 64 0 0 0-64 64v96a64 64 0 0 0 64 64h32a64 64 0 0 0 64-64 16 16 0 0 0 0-32zM400 544a16 16 0 0 0-16 16v137.6l-98.88-146.56a7.36 7.36 0 0 0-2.24-2.24l-2.56-1.6h-16l-2.56 2.24v5.12a13.76 13.76 0 0 0 0 3.52v192a16 16 0 0 0 32 0v-137.6l96 142.08a15.68 15.68 0 0 0 32-3.2v-192A16 16 0 0 0 400 544z",fill:"#FFFFFF","p-id":1135})),ppt:e=>r.createElement("svg",i({t:1646123861524,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":991,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":992}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":993}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":994}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#F05264","p-id":995}),r.createElement("path",{d:"M192 544h-48a16 16 0 0 0-16 16v192a16 16 0 0 0 32 0v-80h32a64 64 0 0 0 0-128z m0 96h-32v-64h32a32 32 0 0 1 0 64z m160-96h-48a16 16 0 0 0-16 16v192a16 16 0 0 0 32 0v-80h32a64 64 0 0 0 0-128z m0 96h-32v-64h32a32 32 0 0 1 0 64z m240-96H464a16 16 0 0 0 0 32h48v176a16 16 0 0 0 32 0V576h48a16 16 0 0 0 0-32z",fill:"#FFFFFF","p-id":996})),pptx:e=>r.createElement("svg",i({t:1646123861524,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":991,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":992}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":993}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":994}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#F05264","p-id":995}),r.createElement("path",{d:"M192 544h-48a16 16 0 0 0-16 16v192a16 16 0 0 0 32 0v-80h32a64 64 0 0 0 0-128z m0 96h-32v-64h32a32 32 0 0 1 0 64z m160-96h-48a16 16 0 0 0-16 16v192a16 16 0 0 0 32 0v-80h32a64 64 0 0 0 0-128z m0 96h-32v-64h32a32 32 0 0 1 0 64z m240-96H464a16 16 0 0 0 0 32h48v176a16 16 0 0 0 32 0V576h48a16 16 0 0 0 0-32z",fill:"#FFFFFF","p-id":996})),rar:e=>r.createElement("svg",i({t:1646123940344,className:"icon",viewBox:"0 0 1056 1024",xmlns:"http://www.w3.org/2000/svg","p-id":2245,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M1.248 0h1024v1024h-1024z",fillOpacity:0,"p-id":2246}),r.createElement("path",{d:"M849.248 1024h-672c-41.6 0-76.8-35.2-73.6-80V80c0-41.6 32-76.8 73.6-80h521.6l224 236.8v710.4c0 41.6-32 76.8-73.6 76.8z",fill:"#F5F1EC","p-id":2247}),r.createElement("path",{d:"M922.848 313.6h-819.2V80c0-41.6 32-76.8 73.6-80h521.6l224 236.8v76.8z",fill:"#E0B773","p-id":2248}),r.createElement("path",{d:"M244.448 252.8v-57.6h25.6l25.6 54.4h25.6l-32-54.4c19.2-6.4 25.6-19.2 25.6-35.2 0-12.8-3.2-22.4-12.8-28.8-6.4-6.4-16-9.6-25.6-9.6h-51.2v131.2h19.2z m32-73.6h-32v-38.4h32c6.4 0 9.6 0 16 3.2 3.2 3.2 3.2 6.4 3.2 16 0 6.4-3.2 9.6-6.4 12.8 0 3.2-6.4 6.4-12.8 6.4z m83.2 73.6l9.6-28.8h48l9.6 28.8h22.4l-48-131.2h-16l-48 131.2h22.4z m54.4-48h-38.4l19.2-57.6 19.2 57.6z m86.4 48v-57.6h25.6l25.6 54.4h22.4l-28.8-54.4c16-6.4 25.6-19.2 25.6-35.2 0-12.8-3.2-22.4-12.8-28.8-6.4-6.4-16-9.6-25.6-9.6h-51.2v131.2h19.2z m28.8-73.6h-28.8v-38.4h32c6.4 0 9.6 0 16 3.2 3.2 3.2 6.4 6.4 6.4 16 0 6.4-3.2 9.6-6.4 12.8-6.4 3.2-12.8 6.4-19.2 6.4z",fill:"#FFFFFF","p-id":2249}),r.createElement("path",{d:"M922.848 236.8h-150.4c-41.6 0-76.8-35.2-73.6-80V0l112 118.4 112 118.4z",fill:"#F5F1EC","p-id":2250}),r.createElement("path",{d:"M426.848 464v409.6h172.8V464h-172.8z m150.4 140.8h-64v41.6h64v44.8h-64v41.6h64v44.8h-64v44.8h-64v-44.8h64v-44.8h-64v-41.6h64v-44.8h-64v-41.6h64v-41.6h-64v-44.8h64v44.8h64v41.6z",fill:"#E0B773","p-id":2251})),svg:e=>r.createElement("svg",i({t:1646123950101,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":2385,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":2386}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":2387}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":2388}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#BAF1CD","p-id":2389}),r.createElement("path",{d:"M160 640a32 32 0 0 1 0-64h48a16 16 0 0 0 0-32h-48a64 64 0 0 0 0 128 32 32 0 0 1 0 64h-48a16 16 0 0 0 0 32h48a64 64 0 0 0 0-128z m246.08-96a16 16 0 0 0-20.8 8.96l-64 155.84-64-155.84a16 16 0 1 0-29.44 11.84l77.76 192a24.96 24.96 0 0 0 3.2 4.8 12.8 12.8 0 0 0 4.8 3.2 12.8 12.8 0 0 0 4.8 0h5.76l3.2-2.24a13.12 13.12 0 0 0 5.44-6.4l77.76-192a15.68 15.68 0 0 0-4.48-20.16zM576 672h-80a16 16 0 0 0 0 32h48a32 32 0 0 1-32 32h-32a32 32 0 0 1-32-32v-96a32 32 0 0 1 32-32h32a32 32 0 0 1 32 32 16 16 0 0 0 32 0 64 64 0 0 0-64-64h-32a64 64 0 0 0-64 64v96a64 64 0 0 0 64 64h32a64 64 0 0 0 64-64 16 16 0 0 0 0-32z",fill:"#FFFFFF","p-id":2390})),txt:e=>r.createElement("svg",i({t:1646123901e3,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":9101,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":9102}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":9103}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":9104}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#999999","p-id":9105}),r.createElement("text",{x:352,y:700,fontSize:240,fontWeight:"bold",fill:"#FFFFFF",fontFamily:"Arial, sans-serif",textAnchor:"middle",dominantBaseline:"middle"},"TXT")),unknow:e=>r.createElement("svg",i({t:1646123889587,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":1551,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M914.92 287.344L697.718 81.474v128.338c0 43.554 34.968 79.189 77.706 79.189h141.99l-2.494-1.657z",fill:"#027AFF","p-id":1552}),r.createElement("path",{d:"M768.284 316.733c-54.48 0-99.056-48.997-99.056-108.882V66.223h-373.35c-30.593 0-55.624 27-55.624 60v348.869h490.802c37.476 0 68.137 33.073 68.137 73.496v207.894c0 40.424-30.661 73.497-68.137 73.497H240.254v70.128c0 33 25.031 60 55.625 60h563.637c30.594 0 55.625-27 55.625-60V316.733H768.284z",fill:"#027AFF","p-id":1553}),r.createElement("path",{d:"M699.302 519.057H156.028c-31.109 0-56.561 25.381-56.561 56.403v153.038c0 31.021 25.452 56.402 56.561 56.402h543.274c31.11 0 56.562-25.38 56.562-56.402V575.46c0-31.022-25.453-56.403-56.562-56.403z m-444.857 211.51c-4.902 4.135-10.558 6.203-16.874 6.203-6.41 0-12.066-2.068-16.874-6.204-4.902-4.042-7.353-9.118-7.353-15.417 0-6.204 2.451-11.468 7.353-15.604 4.902-4.042 10.558-6.016 16.874-6.016 6.41 0 12.16 1.974 17.157 6.016 4.902 4.136 7.353 9.4 7.353 15.604-0.094 6.11-2.545 11.28-7.636 15.417z m29.884-89.775c-2.263 2.068-9.993 6.957-23.379 14.571-3.865 2.256-6.222 4.136-7.07 5.64-0.566 0.846-0.849 2.82-0.849 6.016 0 4.7-1.508 8.367-4.619 10.81-2.828 2.539-6.222 3.761-10.464 3.761-4.43 0-8.107-1.128-10.84-3.29-3.489-2.632-5.186-6.392-5.186-11.28v-10.247c0-7.896 3.583-14.477 10.841-19.553 6.976-3.572 13.764-7.238 20.457-10.81 7.259-3.854 10.84-8.367 10.84-13.349 0-10.998-8.578-16.45-25.735-16.45-7.824 0-13.952 1.88-18.57 5.64-2.357 2.068-5.94 6.486-10.653 13.348-4.148 6.017-9.05 8.93-14.612 8.93-4.336 0-7.918-1.503-10.84-4.605-2.923-2.82-4.431-6.487-4.431-10.999 0-7.238 4.43-15.229 13.197-24.159 11.69-12.126 27.055-18.143 45.91-18.143 16.874 0 30.637 4.418 41.384 13.349 10.18 8.46 15.271 18.989 15.271 31.68 0 12.69-3.488 22.372-10.652 29.14zM442.7 730.566c-4.902 4.136-10.558 6.204-16.874 6.204-6.41 0-12.066-2.068-16.874-6.204-4.902-4.042-7.353-9.118-7.353-15.417 0-6.204 2.45-11.468 7.353-15.604 4.902-4.042 10.558-6.016 16.874-6.016 6.41 0 12.16 1.974 17.157 6.016 4.902 4.136 7.353 9.4 7.353 15.604-0.094 6.11-2.64 11.28-7.636 15.417z m29.884-89.774c-2.263 2.068-9.993 6.957-23.38 14.571-3.864 2.256-6.221 4.136-7.07 5.64-0.565 0.846-0.848 2.82-0.848 6.016 0 4.7-1.508 8.367-4.619 10.81-2.828 2.539-6.222 3.761-10.464 3.761-4.43 0-8.107-1.128-10.84-3.29-3.489-2.632-5.186-6.392-5.186-11.28v-10.247c0-7.896 3.583-14.477 10.841-19.553 6.976-3.572 13.764-7.238 20.457-10.81 7.258-3.854 10.84-8.367 10.84-13.349 0-10.998-8.578-16.45-25.735-16.45-7.824 0-13.952 1.88-18.57 5.64-2.358 2.068-5.94 6.486-10.653 13.348-4.148 6.017-9.05 8.93-14.612 8.93-4.336 0-7.919-1.503-10.841-4.605-2.922-2.82-4.43-6.487-4.43-10.999 0-7.238 4.43-15.229 13.197-24.159 11.69-12.126 27.055-18.143 45.91-18.143 16.873 0 30.637 4.418 41.383 13.349 10.181 8.46 15.272 18.989 15.272 31.68 0 12.69-3.582 22.372-10.652 29.14z m158.372 89.774c-4.902 4.136-10.558 6.204-16.874 6.204-6.41 0-12.067-2.068-16.874-6.204-4.902-4.042-7.353-9.118-7.353-15.417 0-6.204 2.45-11.468 7.353-15.604 4.902-4.042 10.558-6.016 16.874-6.016 6.41 0 12.16 1.974 17.157 6.016 4.902 4.136 7.353 9.4 7.353 15.604-0.094 6.11-2.64 11.28-7.636 15.417z m29.883-89.774c-2.262 2.068-9.992 6.957-23.378 14.571-3.865 2.256-6.222 4.136-7.07 5.64-0.566 0.846-0.85 2.82-0.85 6.016 0 4.7-1.507 8.367-4.618 10.81-2.828 2.539-6.222 3.761-10.464 3.761-4.43 0-8.107-1.128-10.841-3.29-3.488-2.632-5.185-6.392-5.185-11.28v-10.247c0-7.896 3.582-14.477 10.841-19.553 6.976-3.572 13.763-7.238 20.456-10.81 7.26-3.854 10.841-8.367 10.841-13.349 0-10.998-8.578-16.45-25.735-16.45-7.824 0-13.952 1.88-18.571 5.64-2.357 2.068-5.94 6.486-10.653 13.348-4.147 6.017-9.05 8.93-14.611 8.93-4.337 0-7.919-1.503-10.841-4.605-2.923-2.82-4.43-6.487-4.43-10.999 0-7.238 4.43-15.229 13.197-24.159 11.69-12.126 27.055-18.143 45.909-18.143 16.874 0 30.637 4.418 41.384 13.349 10.181 8.46 15.272 18.989 15.272 31.68 0 12.69-3.582 22.372-10.653 29.14z",fill:"#027AFF","p-id":1554})),xls:e=>r.createElement("svg",i({t:1646123896342,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":1688,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":1689}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":1690}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":1691}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#009688","p-id":1692}),r.createElement("path",{d:"M512 640a32 32 0 0 1 0-64h48a16 16 0 0 0 0-32h-48a64 64 0 0 0 0 128 32 32 0 0 1 0 64h-48a16 16 0 0 0 0 32h48a64 64 0 0 0 0-128z m-112 96h-80V560a16 16 0 0 0-32 0v192a16 16 0 0 0 16 16h96a16 16 0 0 0 0-32z m-146.88 8.32l-57.6-91.84 52.8-84.16a15.36 15.36 0 0 0-6.08-21.76 18.56 18.56 0 0 0-23.68 5.76l-42.88 68.8-42.88-68.8a18.56 18.56 0 0 0-23.68-5.76 15.36 15.36 0 0 0-6.4 21.76l53.12 84.16-57.6 91.84a15.36 15.36 0 0 0 6.4 21.76A17.92 17.92 0 0 0 128 760l47.68-75.84L224 760a18.56 18.56 0 0 0 23.68 6.08 15.36 15.36 0 0 0 5.44-21.76z",fill:"#FFFFFF","p-id":1693})),xlsx:e=>r.createElement("svg",i({t:1646123896342,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":1688,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M704 0H192a64 64 0 0 0-64 64v320h576a64 64 0 0 1 64 64v416a64 64 0 0 1-64 64H128v32a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V320z",fill:"#EAEAEA","p-id":1689}),r.createElement("path",{d:"M704 0v256a64 64 0 0 0 64 64h256z",fill:"#434854","p-id":1690}),r.createElement("path",{d:"M768 320l256 256V320H768z",opacity:.1,"p-id":1691}),r.createElement("path",{d:"M704 832a32 32 0 0 1-32 32H32a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32z",fill:"#009688","p-id":1692}),r.createElement("path",{d:"M512 640a32 32 0 0 1 0-64h48a16 16 0 0 0 0-32h-48a64 64 0 0 0 0 128 32 32 0 0 1 0 64h-48a16 16 0 0 0 0 32h48a64 64 0 0 0 0-128z m-112 96h-80V560a16 16 0 0 0-32 0v192a16 16 0 0 0 16 16h96a16 16 0 0 0 0-32z m-146.88 8.32l-57.6-91.84 52.8-84.16a15.36 15.36 0 0 0-6.08-21.76 18.56 18.56 0 0 0-23.68 5.76l-42.88 68.8-42.88-68.8a18.56 18.56 0 0 0-23.68-5.76 15.36 15.36 0 0 0-6.4 21.76l53.12 84.16-57.6 91.84a15.36 15.36 0 0 0 6.4 21.76A17.92 17.92 0 0 0 128 760l47.68-75.84L224 760a18.56 18.56 0 0 0 23.68 6.08 15.36 15.36 0 0 0 5.44-21.76z",fill:"#FFFFFF","p-id":1693})),zip:e=>r.createElement("svg",i({t:1646123936994,className:"icon",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg","p-id":2105,xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em"},e),r.createElement("defs",null,r.createElement("style",{type:"text/css"})),r.createElement("path",{d:"M0 0h1024v1024H0z",fillOpacity:0,"p-id":2106}),r.createElement("path",{d:"M848 1024H176c-41.6 0-76.8-35.2-73.6-80V80c0-41.6 32-76.8 73.6-80h521.6l224 236.8v710.4c0 41.6-32 76.8-73.6 76.8z",fill:"#F5ECEC","p-id":2107}),r.createElement("path",{d:"M921.6 313.6H102.4V80c0-41.6 32-76.8 73.6-80h521.6l224 236.8v76.8z",fill:"#BC8585","p-id":2108}),r.createElement("path",{d:"M300.8 252.8v-19.2H240l57.6-96v-16h-80v16h57.6l-57.6 96v16h83.2z m70.4 0V121.6H352v131.2h19.2z m80 0v-51.2H480c12.8 0 22.4-3.2 32-12.8 6.4-6.4 9.6-16 9.6-25.6 0-6.4 0-12.8-3.2-19.2-3.2-6.4-6.4-9.6-9.6-12.8-6.4-3.2-9.6-6.4-16-6.4h-64V256h22.4z m28.8-70.4h-28.8v-41.6H480c6.4 0 9.6 0 12.8 3.2 3.2 0 3.2 3.2 6.4 6.4 0 3.2 3.2 6.4 3.2 9.6 0 6.4-3.2 9.6-6.4 12.8-3.2 6.4-9.6 9.6-16 9.6z",fill:"#FFFFFF","p-id":2109}),r.createElement("path",{d:"M921.6 236.8H771.2c-41.6 0-76.8-35.2-73.6-80V0l112 118.4 112 118.4z",fill:"#F5ECEC","p-id":2110}),r.createElement("path",{d:"M425.6 464v409.6h172.8V464H425.6zM576 604.8h-64v41.6h64v44.8h-64v41.6h64v44.8h-64v44.8h-64v-44.8h64v-44.8h-64v-41.6h64v-44.8h-64v-41.6h64v-41.6h-64v-44.8h64v44.8h64v41.6z",fill:"#BC8585","p-id":2111}))};const a=e=>{const{size:t,type:n}=Object.assign({},{size:40,type:"unknow"},e),i=s[n]||s.unknow;return r.createElement(i,{width:t,height:t})}},7717(e,t,n){"use strict";n.d(t,{A:()=>a});var r=n(3141),i=n(94922),s=n(78678);const a=function(e,t){t=Object.assign({},{defaultValue:"defaultValue",value:"value",onChange:"onChange"},t);var n=(0,i.useRef)(t.value in e),a=(0,i.useState)(e[t.defaultValue]),o=(0,r.A)(a,2),l=o[0],c=o[1],h=n.current?e[t.value]:l;return[h,(0,s.A)(function(r){for(var i="function"===typeof r?h=r(h):r,s=arguments.length,a=new Array(s>1?s-1:0),o=1;o<s;o++)a[o-1]=arguments[o];e[t.onChange]&&e[t.onChange].apply(e,[i].concat(a)),n.current||c(i)})]}},78678(e,t,n){"use strict";n.d(t,{A:()=>i});var r=n(94922);const i=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const n=(0,r.useRef)(e);return t||(n.current=e),(0,r.useCallback)(function(){return n.current&&n.current(...arguments)},[])}},50805(e,t,n){"use strict";n.d(t,{A:()=>c});var r=n(94922),i=n(98771),s=n.n(i),a=n(95600),o=n.n(a),l=n(78678);const c=(e,t)=>{const n=(0,r.useRef)(null);n.current=Object.assign({},{time:500,isDebounce:!1},t);const i=(0,r.useRef)(null),a=(0,l.A)(e);return(0,r.useLayoutEffect)(()=>{const e=i.current,t=()=>window.requestAnimationFrame(()=>{e&&a(e)});t();const r=new ResizeObserver((n.current.isDebounce?o():s())(t,n.current.time));return e&&r.observe(e),()=>{r.disconnect()}},[a]),i}},14225(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const r=n(13575),i=n(97279),s=n(55e3),a=n(70211),o=["/properties"],l="http://json-schema.org/draft-07/schema";class c extends r.default{_addVocabularies(){super._addVocabularies(),i.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(s.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const e=this.opts.$data?this.$dataMetaSchema(a,o):a;this.addMetaSchema(e,l,!1),this.refs["http://json-schema.org/schema"]=l}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(l)?l:void 0)}}t.Ajv=c,e.exports=t=c,e.exports.Ajv=c,Object.defineProperty(t,"__esModule",{value:!0}),t.default=c;var h=n(80031);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return h.KeywordCxt}});var d=n(13578);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return d._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return d.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return d.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return d.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return d.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return d.CodeGen}});var u=n(3351);Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return u.default}});var p=n(19252);Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return p.default}})},26061(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.regexpCode=t.getEsmExportName=t.getProperty=t.safeStringify=t.stringify=t.strConcat=t.addCodeArg=t.str=t._=t.nil=t._Code=t.Name=t.IDENTIFIER=t._CodeOrName=void 0;class n{}t._CodeOrName=n,t.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class r extends n{constructor(e){if(super(),!t.IDENTIFIER.test(e))throw new Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}t.Name=r;class i extends n{constructor(e){super(),this._items="string"===typeof e?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const e=this._items[0];return""===e||'""'===e}get str(){var e;return null!==(e=this._str)&&void 0!==e?e:this._str=this._items.reduce((e,t)=>`${e}${t}`,"")}get names(){var e;return null!==(e=this._names)&&void 0!==e?e:this._names=this._items.reduce((e,t)=>(t instanceof r&&(e[t.str]=(e[t.str]||0)+1),e),{})}}function s(e){const t=[e[0]];let n=0;for(var r=arguments.length,s=new Array(r>1?r-1:0),a=1;a<r;a++)s[a-1]=arguments[a];for(;n<s.length;)l(t,s[n]),t.push(e[++n]);return new i(t)}t._Code=i,t.nil=new i(""),t._=s;const a=new i("+");function o(e){const t=[h(e[0])];let n=0;for(var r=arguments.length,s=new Array(r>1?r-1:0),o=1;o<r;o++)s[o-1]=arguments[o];for(;n<s.length;)t.push(a),l(t,s[n]),t.push(a,h(e[++n]));return function(e){let t=1;for(;t<e.length-1;){if(e[t]===a){const n=c(e[t-1],e[t+1]);if(void 0!==n){e.splice(t-1,3,n);continue}e[t++]="+"}t++}}(t),new i(t)}function l(e,t){var n;t instanceof i?e.push(...t._items):t instanceof r?e.push(t):e.push("number"==typeof(n=t)||"boolean"==typeof n||null===n?n:h(Array.isArray(n)?n.join(","):n))}function c(e,t){if('""'===t)return e;if('""'===e)return t;if("string"==typeof e){if(t instanceof r||'"'!==e[e.length-1])return;return"string"!=typeof t?`${e.slice(0,-1)}${t}"`:'"'===t[0]?e.slice(0,-1)+t.slice(1):void 0}return"string"!=typeof t||'"'!==t[0]||e instanceof r?void 0:`"${e}${t.slice(1)}`}function h(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}t.str=o,t.addCodeArg=l,t.strConcat=function(e,t){return t.emptyStr()?e:e.emptyStr()?t:o`${e}${t}`},t.stringify=function(e){return new i(h(e))},t.safeStringify=h,t.getProperty=function(e){return"string"==typeof e&&t.IDENTIFIER.test(e)?new i(`.${e}`):s`[${e}]`},t.getEsmExportName=function(e){if("string"==typeof e&&t.IDENTIFIER.test(e))return new i(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)},t.regexpCode=function(e){return new i(e.toString())}},13578(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.or=t.and=t.not=t.CodeGen=t.operators=t.varKinds=t.ValueScopeName=t.ValueScope=t.Scope=t.Name=t.regexpCode=t.stringify=t.getProperty=t.nil=t.strConcat=t.str=t._=void 0;const r=n(26061),i=n(60930);var s=n(26061);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return s._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return s.str}}),Object.defineProperty(t,"strConcat",{enumerable:!0,get:function(){return s.strConcat}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return s.nil}}),Object.defineProperty(t,"getProperty",{enumerable:!0,get:function(){return s.getProperty}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return s.stringify}}),Object.defineProperty(t,"regexpCode",{enumerable:!0,get:function(){return s.regexpCode}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return s.Name}});var a=n(60930);Object.defineProperty(t,"Scope",{enumerable:!0,get:function(){return a.Scope}}),Object.defineProperty(t,"ValueScope",{enumerable:!0,get:function(){return a.ValueScope}}),Object.defineProperty(t,"ValueScopeName",{enumerable:!0,get:function(){return a.ValueScopeName}}),Object.defineProperty(t,"varKinds",{enumerable:!0,get:function(){return a.varKinds}}),t.operators={GT:new r._Code(">"),GTE:new r._Code(">="),LT:new r._Code("<"),LTE:new r._Code("<="),EQ:new r._Code("==="),NEQ:new r._Code("!=="),NOT:new r._Code("!"),OR:new r._Code("||"),AND:new r._Code("&&"),ADD:new r._Code("+")};class o{optimizeNodes(){return this}optimizeNames(e,t){return this}}class l extends o{constructor(e,t,n){super(),this.varKind=e,this.name=t,this.rhs=n}render(e){let{es5:t,_n:n}=e;const r=t?i.varKinds.var:this.varKind,s=void 0===this.rhs?"":` = ${this.rhs}`;return`${r} ${this.name}${s};`+n}optimizeNames(e,t){if(e[this.name.str])return this.rhs&&(this.rhs=P(this.rhs,e,t)),this}get names(){return this.rhs instanceof r._CodeOrName?this.rhs.names:{}}}class c extends o{constructor(e,t,n){super(),this.lhs=e,this.rhs=t,this.sideEffects=n}render(e){let{_n:t}=e;return`${this.lhs} = ${this.rhs};`+t}optimizeNames(e,t){if(!(this.lhs instanceof r.Name)||e[this.lhs.str]||this.sideEffects)return this.rhs=P(this.rhs,e,t),this}get names(){return M(this.lhs instanceof r.Name?{}:{...this.lhs.names},this.rhs)}}class h extends c{constructor(e,t,n,r){super(e,n,r),this.op=t}render(e){let{_n:t}=e;return`${this.lhs} ${this.op}= ${this.rhs};`+t}}class d extends o{constructor(e){super(),this.label=e,this.names={}}render(e){let{_n:t}=e;return`${this.label}:`+t}}class u extends o{constructor(e){super(),this.label=e,this.names={}}render(e){let{_n:t}=e;return`break${this.label?` ${this.label}`:""};`+t}}class p extends o{constructor(e){super(),this.error=e}render(e){let{_n:t}=e;return`throw ${this.error};`+t}get names(){return this.error.names}}class f extends o{constructor(e){super(),this.code=e}render(e){let{_n:t}=e;return`${this.code};`+t}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,t){return this.code=P(this.code,e,t),this}get names(){return this.code instanceof r._CodeOrName?this.code.names:{}}}class m extends o{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];super(),this.nodes=e}render(e){return this.nodes.reduce((t,n)=>t+n.render(e),"")}optimizeNodes(){const{nodes:e}=this;let t=e.length;for(;t--;){const n=e[t].optimizeNodes();Array.isArray(n)?e.splice(t,1,...n):n?e[t]=n:e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){const{nodes:n}=this;let r=n.length;for(;r--;){const i=n[r];i.optimizeNames(e,t)||(I(e,i.names),n.splice(r,1))}return n.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>D(e,t.names),{})}}class g extends m{render(e){return"{"+e._n+super.render(e)+"}"+e._n}}class v extends m{}class y extends g{}y.kind="else";class b extends g{constructor(e,t){super(t),this.condition=e}render(e){let t=`if(${this.condition})`+super.render(e);return this.else&&(t+="else "+this.else.render(e)),t}optimizeNodes(){super.optimizeNodes();const e=this.condition;if(!0===e)return this.nodes;let t=this.else;if(t){const e=t.optimizeNodes();t=this.else=Array.isArray(e)?new y(e):e}return t?!1===e?t instanceof b?t:t.nodes:this.nodes.length?this:new b(F(e),t instanceof b?[t]:t.nodes):!1!==e&&this.nodes.length?this:void 0}optimizeNames(e,t){var n;if(this.else=null===(n=this.else)||void 0===n?void 0:n.optimizeNames(e,t),super.optimizeNames(e,t)||this.else)return this.condition=P(this.condition,e,t),this}get names(){const e=super.names;return M(e,this.condition),this.else&&D(e,this.else.names),e}}b.kind="if";class w extends g{}w.kind="for";class _ extends w{constructor(e){super(),this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,t){if(super.optimizeNames(e,t))return this.iteration=P(this.iteration,e,t),this}get names(){return D(super.names,this.iteration.names)}}class A extends w{constructor(e,t,n,r){super(),this.varKind=e,this.name=t,this.from=n,this.to=r}render(e){const t=e.es5?i.varKinds.var:this.varKind,{name:n,from:r,to:s}=this;return`for(${t} ${n}=${r}; ${n}<${s}; ${n}++)`+super.render(e)}get names(){const e=M(super.names,this.from);return M(e,this.to)}}class x extends w{constructor(e,t,n,r){super(),this.loop=e,this.varKind=t,this.name=n,this.iterable=r}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,t){if(super.optimizeNames(e,t))return this.iterable=P(this.iterable,e,t),this}get names(){return D(super.names,this.iterable.names)}}class E extends g{constructor(e,t,n){super(),this.name=e,this.args=t,this.async=n}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}}E.kind="func";class C extends m{render(e){return"return "+super.render(e)}}C.kind="return";class k extends g{render(e){let t="try"+super.render(e);return this.catch&&(t+=this.catch.render(e)),this.finally&&(t+=this.finally.render(e)),t}optimizeNodes(){var e,t;return super.optimizeNodes(),null===(e=this.catch)||void 0===e||e.optimizeNodes(),null===(t=this.finally)||void 0===t||t.optimizeNodes(),this}optimizeNames(e,t){var n,r;return super.optimizeNames(e,t),null===(n=this.catch)||void 0===n||n.optimizeNames(e,t),null===(r=this.finally)||void 0===r||r.optimizeNames(e,t),this}get names(){const e=super.names;return this.catch&&D(e,this.catch.names),this.finally&&D(e,this.finally.names),e}}class S extends g{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}S.kind="catch";class T extends g{render(e){return"finally"+super.render(e)}}T.kind="finally";function D(e,t){for(const n in t)e[n]=(e[n]||0)+(t[n]||0);return e}function M(e,t){return t instanceof r._CodeOrName?D(e,t.names):e}function P(e,t,n){return e instanceof r.Name?s(e):(i=e)instanceof r._Code&&i._items.some(e=>e instanceof r.Name&&1===t[e.str]&&void 0!==n[e.str])?new r._Code(e._items.reduce((e,t)=>(t instanceof r.Name&&(t=s(t)),t instanceof r._Code?e.push(...t._items):e.push(t),e),[])):e;var i;function s(e){const r=n[e.str];return void 0===r||1!==t[e.str]?e:(delete t[e.str],r)}}function I(e,t){for(const n in t)e[n]=(e[n]||0)-(t[n]||0)}function F(e){return"boolean"==typeof e||"number"==typeof e||null===e?!e:r._`!${O(e)}`}t.CodeGen=class{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?"\n":""},this._extScope=e,this._scope=new i.Scope({parent:e}),this._nodes=[new v]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,t){const n=this._extScope.value(e,t);return(this._values[n.prefix]||(this._values[n.prefix]=new Set)).add(n),n}getScopeValue(e,t){return this._extScope.getValue(e,t)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,t,n,r){const i=this._scope.toName(t);return void 0!==n&&r&&(this._constants[i.str]=n),this._leafNode(new l(e,i,n)),i}const(e,t,n){return this._def(i.varKinds.const,e,t,n)}let(e,t,n){return this._def(i.varKinds.let,e,t,n)}var(e,t,n){return this._def(i.varKinds.var,e,t,n)}assign(e,t,n){return this._leafNode(new c(e,t,n))}add(e,n){return this._leafNode(new h(e,t.operators.ADD,n))}code(e){return"function"==typeof e?e():e!==r.nil&&this._leafNode(new f(e)),this}object(){const e=["{"];for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];for(const[s,a]of n)e.length>1&&e.push(","),e.push(s),(s!==a||this.opts.es5)&&(e.push(":"),(0,r.addCodeArg)(e,a));return e.push("}"),new r._Code(e)}if(e,t,n){if(this._blockNode(new b(e)),t&&n)this.code(t).else().code(n).endIf();else if(t)this.code(t).endIf();else if(n)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new b(e))}else(){return this._elseNode(new y)}endIf(){return this._endBlockNode(b,y)}_for(e,t){return this._blockNode(e),t&&this.code(t).endFor(),this}for(e,t){return this._for(new _(e),t)}forRange(e,t,n,r){let s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:this.opts.es5?i.varKinds.var:i.varKinds.let;const a=this._scope.toName(e);return this._for(new A(s,a,t,n),()=>r(a))}forOf(e,t,n){let s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:i.varKinds.const;const a=this._scope.toName(e);if(this.opts.es5){const e=t instanceof r.Name?t:this.var("_arr",t);return this.forRange("_i",0,r._`${e}.length`,t=>{this.var(a,r._`${e}[${t}]`),n(a)})}return this._for(new x("of",s,a,t),()=>n(a))}forIn(e,t,n){let s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:this.opts.es5?i.varKinds.var:i.varKinds.const;if(this.opts.ownProperties)return this.forOf(e,r._`Object.keys(${t})`,n);const a=this._scope.toName(e);return this._for(new x("in",s,a,t),()=>n(a))}endFor(){return this._endBlockNode(w)}label(e){return this._leafNode(new d(e))}break(e){return this._leafNode(new u(e))}return(e){const t=new C;if(this._blockNode(t),this.code(e),1!==t.nodes.length)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(C)}try(e,t,n){if(!t&&!n)throw new Error('CodeGen: "try" without "catch" and "finally"');const r=new k;if(this._blockNode(r),this.code(e),t){const e=this.name("e");this._currNode=r.catch=new S(e),t(e)}return n&&(this._currNode=r.finally=new T,this.code(n)),this._endBlockNode(S,T)}throw(e){return this._leafNode(new p(e))}block(e,t){return this._blockStarts.push(this._nodes.length),e&&this.code(e).endBlock(t),this}endBlock(e){const t=this._blockStarts.pop();if(void 0===t)throw new Error("CodeGen: not in self-balancing block");const n=this._nodes.length-t;if(n<0||void 0!==e&&n!==e)throw new Error(`CodeGen: wrong number of nodes: ${n} vs ${e} expected`);return this._nodes.length=t,this}func(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:r.nil,n=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0;return this._blockNode(new E(e,t,n)),i&&this.code(i).endFunc(),this}endFunc(){return this._endBlockNode(E)}optimize(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1;for(;e-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,t){const n=this._currNode;if(n instanceof e||t&&n instanceof t)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){const t=this._currNode;if(!(t instanceof b))throw new Error('CodeGen: "else" without "if"');return this._currNode=t.else=e,this}get _root(){return this._nodes[0]}get _currNode(){const e=this._nodes;return e[e.length-1]}set _currNode(e){const t=this._nodes;t[t.length-1]=e}},t.not=F;const R=L(t.operators.AND);t.and=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce(R)};const N=L(t.operators.OR);function L(e){return(t,n)=>t===r.nil?n:n===r.nil?t:r._`${O(t)} ${e} ${O(n)}`}function O(e){return e instanceof r.Name?e:r._`(${e})`}t.or=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce(N)}},60930(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ValueScope=t.ValueScopeName=t.Scope=t.varKinds=t.UsedValueState=void 0;const r=n(26061);class i extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}}var s;!function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"}(s||(t.UsedValueState=s={})),t.varKinds={const:new r.Name("const"),let:new r.Name("let"),var:new r.Name("var")};class a{constructor(){let{prefixes:e,parent:t}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this._names={},this._prefixes=e,this._parent=t}toName(e){return e instanceof r.Name?e:this.name(e)}name(e){return new r.Name(this._newName(e))}_newName(e){return`${e}${(this._names[e]||this._nameGroup(e)).index++}`}_nameGroup(e){var t,n;if((null===(n=null===(t=this._parent)||void 0===t?void 0:t._prefixes)||void 0===n?void 0:n.has(e))||this._prefixes&&!this._prefixes.has(e))throw new Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}}t.Scope=a;class o extends r.Name{constructor(e,t){super(t),this.prefix=e}setValue(e,t){let{property:n,itemIndex:i}=t;this.value=e,this.scopePath=r._`.${new r.Name(n)}[${i}]`}}t.ValueScopeName=o;const l=r._`\n`;t.ValueScope=class extends a{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?l:r.nil}}get(){return this._scope}name(e){return new o(e,this._newName(e))}value(e,t){var n;if(void 0===t.ref)throw new Error("CodeGen: ref must be passed in value");const r=this.toName(e),{prefix:i}=r,s=null!==(n=t.key)&&void 0!==n?n:t.ref;let a=this._values[i];if(a){const e=a.get(s);if(e)return e}else a=this._values[i]=new Map;a.set(s,r);const o=this._scope[i]||(this._scope[i]=[]),l=o.length;return o[l]=t.ref,r.setValue(t,{property:i,itemIndex:l}),r}getValue(e,t){const n=this._values[e];if(n)return n.get(t)}scopeRefs(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this._values;return this._reduceValues(t,t=>{if(void 0===t.scopePath)throw new Error(`CodeGen: name "${t}" has no value`);return r._`${e}${t.scopePath}`})}scopeCode(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this._values,t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0;return this._reduceValues(e,e=>{if(void 0===e.value)throw new Error(`CodeGen: name "${e}" has no value`);return e.value.code},t,n)}_reduceValues(e,n){let a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=arguments.length>3?arguments[3]:void 0,l=r.nil;for(const c in e){const h=e[c];if(!h)continue;const d=a[c]=a[c]||new Map;h.forEach(e=>{if(d.has(e))return;d.set(e,s.Started);let a=n(e);if(a){const n=this.opts.es5?t.varKinds.var:t.varKinds.const;l=r._`${l}${n} ${e} = ${a};${this.opts._n}`}else{if(!(a=null===o||void 0===o?void 0:o(e)))throw new i(e);l=r._`${l}${a}${this.opts._n}`}d.set(e,s.Completed)})}return l}}},7009(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.extendErrors=t.resetErrorsCount=t.reportExtraError=t.reportError=t.keyword$DataError=t.keywordError=void 0;const r=n(13578),i=n(14426),s=n(81500);function a(e,t){const n=e.const("err",t);e.if(r._`${s.default.vErrors} === null`,()=>e.assign(s.default.vErrors,r._`[${n}]`),r._`${s.default.vErrors}.push(${n})`),e.code(r._`${s.default.errors}++`)}function o(e,t){const{gen:n,validateName:i,schemaEnv:s}=e;s.$async?n.throw(r._`new ${e.ValidationError}(${t})`):(n.assign(r._`${i}.errors`,t),n.return(!1))}t.keywordError={message:e=>{let{keyword:t}=e;return r.str`must pass "${t}" keyword validation`}},t.keyword$DataError={message:e=>{let{keyword:t,schemaType:n}=e;return n?r.str`"${t}" keyword must be ${n} ($data)`:r.str`"${t}" keyword is invalid ($data)`}},t.reportError=function(e){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t.keywordError,i=arguments.length>2?arguments[2]:void 0,s=arguments.length>3?arguments[3]:void 0;const{it:l}=e,{gen:h,compositeRule:d,allErrors:u}=l,p=c(e,n,i);(null!==s&&void 0!==s?s:d||u)?a(h,p):o(l,r._`[${p}]`)},t.reportExtraError=function(e){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t.keywordError,r=arguments.length>2?arguments[2]:void 0;const{it:i}=e,{gen:l,compositeRule:h,allErrors:d}=i;a(l,c(e,n,r)),h||d||o(i,s.default.vErrors)},t.resetErrorsCount=function(e,t){e.assign(s.default.errors,t),e.if(r._`${s.default.vErrors} !== null`,()=>e.if(t,()=>e.assign(r._`${s.default.vErrors}.length`,t),()=>e.assign(s.default.vErrors,null)))},t.extendErrors=function(e){let{gen:t,keyword:n,schemaValue:i,data:a,errsCount:o,it:l}=e;if(void 0===o)throw new Error("ajv implementation error");const c=t.name("err");t.forRange("i",o,s.default.errors,e=>{t.const(c,r._`${s.default.vErrors}[${e}]`),t.if(r._`${c}.instancePath === undefined`,()=>t.assign(r._`${c}.instancePath`,(0,r.strConcat)(s.default.instancePath,l.errorPath))),t.assign(r._`${c}.schemaPath`,r.str`${l.errSchemaPath}/${n}`),l.opts.verbose&&(t.assign(r._`${c}.schema`,i),t.assign(r._`${c}.data`,a))})};const l={keyword:new r.Name("keyword"),schemaPath:new r.Name("schemaPath"),params:new r.Name("params"),propertyName:new r.Name("propertyName"),message:new r.Name("message"),schema:new r.Name("schema"),parentSchema:new r.Name("parentSchema")};function c(e,t,n){const{createErrors:i}=e.it;return!1===i?r._`{}`:function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const{gen:i,it:a}=e,o=[h(a,n),d(e,n)];return function(e,t,n){let{params:i,message:a}=t;const{keyword:o,data:c,schemaValue:h,it:d}=e,{opts:u,propertyName:p,topSchemaRef:f,schemaPath:m}=d;n.push([l.keyword,o],[l.params,"function"==typeof i?i(e):i||r._`{}`]),u.messages&&n.push([l.message,"function"==typeof a?a(e):a]);u.verbose&&n.push([l.schema,h],[l.parentSchema,r._`${f}${m}`],[s.default.data,c]);p&&n.push([l.propertyName,p])}(e,t,o),i.object(...o)}(e,t,n)}function h(e,t){let{errorPath:n}=e,{instancePath:a}=t;const o=a?r.str`${n}${(0,i.getErrorPath)(a,i.Type.Str)}`:n;return[s.default.instancePath,(0,r.strConcat)(s.default.instancePath,o)]}function d(e,t){let{keyword:n,it:{errSchemaPath:s}}=e,{schemaPath:a,parentSchema:o}=t,c=o?s:r.str`${s}/${n}`;return a&&(c=r.str`${c}${(0,i.getErrorPath)(a,i.Type.Str)}`),[l.schemaPath,c]}},28208(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.resolveSchema=t.getCompilingSchema=t.resolveRef=t.compileSchema=t.SchemaEnv=void 0;const r=n(13578),i=n(3351),s=n(81500),a=n(48904),o=n(14426),l=n(80031);class c{constructor(e){var t;let n;this.refs={},this.dynamicAnchors={},"object"==typeof e.schema&&(n=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=null!==(t=e.baseId)&&void 0!==t?t:(0,a.normalizeId)(null===n||void 0===n?void 0:n[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=null===n||void 0===n?void 0:n.$async,this.refs={}}}function h(e){const t=u.call(this,e);if(t)return t;const n=(0,a.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:o,lines:c}=this.opts.code,{ownProperties:h}=this.opts,d=new r.CodeGen(this.scope,{es5:o,lines:c,ownProperties:h});let p;e.$async&&(p=d.scopeValue("Error",{ref:i.default,code:r._`require("ajv/dist/runtime/validation_error").default`}));const f=d.scopeName("validate");e.validateName=f;const m={gen:d,allErrors:this.opts.allErrors,data:s.default.data,parentData:s.default.parentData,parentDataProperty:s.default.parentDataProperty,dataNames:[s.default.data],dataPathArr:[r.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:d.scopeValue("schema",!0===this.opts.code.source?{ref:e.schema,code:(0,r.stringify)(e.schema)}:{ref:e.schema}),validateName:f,ValidationError:p,schema:e.schema,schemaEnv:e,rootId:n,baseId:e.baseId||n,schemaPath:r.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:r._`""`,opts:this.opts,self:this};let g;try{this._compilations.add(e),(0,l.validateFunctionCode)(m),d.optimize(this.opts.code.optimize);const t=d.toString();g=`${d.scopeRefs(s.default.scope)}return ${t}`,this.opts.code.process&&(g=this.opts.code.process(g,e));const n=new Function(`${s.default.self}`,`${s.default.scope}`,g)(this,this.scope.get());if(this.scope.value(f,{ref:n}),n.errors=null,n.schema=e.schema,n.schemaEnv=e,e.$async&&(n.$async=!0),!0===this.opts.code.source&&(n.source={validateName:f,validateCode:t,scopeValues:d._values}),this.opts.unevaluated){const{props:e,items:t}=m;n.evaluated={props:e instanceof r.Name?void 0:e,items:t instanceof r.Name?void 0:t,dynamicProps:e instanceof r.Name,dynamicItems:t instanceof r.Name},n.source&&(n.source.evaluated=(0,r.stringify)(n.evaluated))}return e.validate=n,e}catch(v){throw delete e.validate,delete e.validateName,g&&this.logger.error("Error compiling schema, function code:",g),v}finally{this._compilations.delete(e)}}function d(e){return(0,a.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:h.call(this,e)}function u(e){for(const t of this._compilations)if(p(t,e))return t}function p(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function f(e,t){let n;for(;"string"==typeof(n=this.refs[t]);)t=n;return n||this.schemas[t]||m.call(this,e,t)}function m(e,t){const n=this.opts.uriResolver.parse(t),r=(0,a._getFullPath)(this.opts.uriResolver,n);let i=(0,a.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&r===i)return v.call(this,n,e);const s=(0,a.normalizeId)(r),o=this.refs[s]||this.schemas[s];if("string"==typeof o){const t=m.call(this,e,o);if("object"!==typeof(null===t||void 0===t?void 0:t.schema))return;return v.call(this,n,t)}if("object"===typeof(null===o||void 0===o?void 0:o.schema)){if(o.validate||h.call(this,o),s===(0,a.normalizeId)(t)){const{schema:t}=o,{schemaId:n}=this.opts,r=t[n];return r&&(i=(0,a.resolveUrl)(this.opts.uriResolver,i,r)),new c({schema:t,schemaId:n,root:e,baseId:i})}return v.call(this,n,o)}}t.SchemaEnv=c,t.compileSchema=h,t.resolveRef=function(e,t,n){var r;n=(0,a.resolveUrl)(this.opts.uriResolver,t,n);const i=e.refs[n];if(i)return i;let s=f.call(this,e,n);if(void 0===s){const i=null===(r=e.localRefs)||void 0===r?void 0:r[n],{schemaId:a}=this.opts;i&&(s=new c({schema:i,schemaId:a,root:e,baseId:t}))}return void 0!==s?e.refs[n]=d.call(this,s):void 0},t.getCompilingSchema=u,t.resolveSchema=m;const g=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function v(e,t){let{baseId:n,schema:r,root:i}=t;var s;if("/"!==(null===(s=e.fragment)||void 0===s?void 0:s[0]))return;for(const c of e.fragment.slice(1).split("/")){if("boolean"===typeof r)return;const e=r[(0,o.unescapeFragment)(c)];if(void 0===e)return;r=e;const t="object"===typeof r&&r[this.opts.schemaId];!g.has(c)&&t&&(n=(0,a.resolveUrl)(this.opts.uriResolver,n,t))}let l;if("boolean"!=typeof r&&r.$ref&&!(0,o.schemaHasRulesButRef)(r,this.RULES)){const e=(0,a.resolveUrl)(this.opts.uriResolver,n,r.$ref);l=m.call(this,i,e)}const{schemaId:h}=this.opts;return l=l||new c({schema:r,schemaId:h,root:i,baseId:n}),l.schema!==l.root.schema?l:void 0}},81500(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i={data:new r.Name("data"),valCxt:new r.Name("valCxt"),instancePath:new r.Name("instancePath"),parentData:new r.Name("parentData"),parentDataProperty:new r.Name("parentDataProperty"),rootData:new r.Name("rootData"),dynamicAnchors:new r.Name("dynamicAnchors"),vErrors:new r.Name("vErrors"),errors:new r.Name("errors"),this:new r.Name("this"),self:new r.Name("self"),scope:new r.Name("scope"),json:new r.Name("json"),jsonPos:new r.Name("jsonPos"),jsonLen:new r.Name("jsonLen"),jsonPart:new r.Name("jsonPart")};t.default=i},19252(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(48904);class i extends Error{constructor(e,t,n,i){super(i||`can't resolve reference ${n} from id ${t}`),this.missingRef=(0,r.resolveUrl)(e,t,n),this.missingSchema=(0,r.normalizeId)((0,r.getFullPath)(e,this.missingRef))}}t.default=i},48904(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getSchemaRefs=t.resolveUrl=t.normalizeId=t._getFullPath=t.getFullPath=t.inlineRef=void 0;const r=n(14426),i=n(83080),s=n(69453),a=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);t.inlineRef=function(e){let t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return"boolean"==typeof e||(!0===t?!l(e):!!t&&c(e)<=t)};const o=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function l(e){for(const t in e){if(o.has(t))return!0;const n=e[t];if(Array.isArray(n)&&n.some(l))return!0;if("object"==typeof n&&l(n))return!0}return!1}function c(e){let t=0;for(const n in e){if("$ref"===n)return 1/0;if(t++,!a.has(n)&&("object"==typeof e[n]&&(0,r.eachItem)(e[n],e=>t+=c(e)),t===1/0))return 1/0}return t}function h(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";!1!==(arguments.length>2?arguments[2]:void 0)&&(t=p(t));const n=e.parse(t);return d(e,n)}function d(e,t){return e.serialize(t).split("#")[0]+"#"}t.getFullPath=h,t._getFullPath=d;const u=/#\/?$/;function p(e){return e?e.replace(u,""):""}t.normalizeId=p,t.resolveUrl=function(e,t,n){return n=p(n),e.resolve(t,n)};const f=/^[a-z_][-a-z0-9._]*$/i;t.getSchemaRefs=function(e,t){if("boolean"==typeof e)return{};const{schemaId:n,uriResolver:r}=this.opts,a=p(e[n]||t),o={"":a},l=h(r,a,!1),c={},d=new Set;return s(e,{allKeys:!0},(e,t,r,i)=>{if(void 0===i)return;const s=l+t;let a=o[i];function h(t){const n=this.opts.uriResolver.resolve;if(t=p(a?n(a,t):t),d.has(t))throw m(t);d.add(t);let r=this.refs[t];return"string"==typeof r&&(r=this.refs[r]),"object"==typeof r?u(e,r.schema,t):t!==p(s)&&("#"===t[0]?(u(e,c[t],t),c[t]=e):this.refs[t]=s),t}function g(e){if("string"==typeof e){if(!f.test(e))throw new Error(`invalid anchor "${e}"`);h.call(this,`#${e}`)}}"string"==typeof e[n]&&(a=h.call(this,e[n])),g.call(this,e.$anchor),g.call(this,e.$dynamicAnchor),o[t]=a}),c;function u(e,t,n){if(void 0!==t&&!i(e,t))throw m(n)}function m(e){return new Error(`reference "${e}" resolves to more than one schema`)}}},66223(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getRules=t.isJSONType=void 0;const n=new Set(["string","number","integer","boolean","null","object","array"]);t.isJSONType=function(e){return"string"==typeof e&&n.has(e)},t.getRules=function(){const e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}},14426(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.checkStrictMode=t.getErrorPath=t.Type=t.useFunc=t.setEvaluated=t.evaluatedPropsToName=t.mergeEvaluated=t.eachItem=t.unescapeJsonPointer=t.escapeJsonPointer=t.escapeFragment=t.unescapeFragment=t.schemaRefOrVal=t.schemaHasRulesButRef=t.schemaHasRules=t.checkUnknownRules=t.alwaysValidSchema=t.toHash=void 0;const r=n(13578),i=n(26061);function s(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.schema;const{opts:n,self:r}=e;if(!n.strictSchema)return;if("boolean"===typeof t)return;const i=r.RULES.keywords;for(const s in t)i[s]||f(e,`unknown keyword: "${s}"`)}function a(e,t){if("boolean"==typeof e)return!e;for(const n in e)if(t[n])return!0;return!1}function o(e){return"number"==typeof e?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}function l(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}function c(e){let{mergeNames:t,mergeToName:n,mergeValues:i,resultToName:s}=e;return(e,a,o,l)=>{const c=void 0===o?a:o instanceof r.Name?(a instanceof r.Name?t(e,a,o):n(e,a,o),o):a instanceof r.Name?(n(e,o,a),a):i(a,o);return l!==r.Name||c instanceof r.Name?c:s(e,c)}}function h(e,t){if(!0===t)return e.var("props",!0);const n=e.var("props",r._`{}`);return void 0!==t&&d(e,n,t),n}function d(e,t,n){Object.keys(n).forEach(n=>e.assign(r._`${t}${(0,r.getProperty)(n)}`,!0))}t.toHash=function(e){const t={};for(const n of e)t[n]=!0;return t},t.alwaysValidSchema=function(e,t){return"boolean"==typeof t?t:0===Object.keys(t).length||(s(e,t),!a(t,e.self.RULES.all))},t.checkUnknownRules=s,t.schemaHasRules=a,t.schemaHasRulesButRef=function(e,t){if("boolean"==typeof e)return!e;for(const n in e)if("$ref"!==n&&t.all[n])return!0;return!1},t.schemaRefOrVal=function(e,t,n,i){let{topSchemaRef:s,schemaPath:a}=e;if(!i){if("number"==typeof t||"boolean"==typeof t)return t;if("string"==typeof t)return r._`${t}`}return r._`${s}${a}${(0,r.getProperty)(n)}`},t.unescapeFragment=function(e){return l(decodeURIComponent(e))},t.escapeFragment=function(e){return encodeURIComponent(o(e))},t.escapeJsonPointer=o,t.unescapeJsonPointer=l,t.eachItem=function(e,t){if(Array.isArray(e))for(const n of e)t(n);else t(e)},t.mergeEvaluated={props:c({mergeNames:(e,t,n)=>e.if(r._`${n} !== true && ${t} !== undefined`,()=>{e.if(r._`${t} === true`,()=>e.assign(n,!0),()=>e.assign(n,r._`${n} || {}`).code(r._`Object.assign(${n}, ${t})`))}),mergeToName:(e,t,n)=>e.if(r._`${n} !== true`,()=>{!0===t?e.assign(n,!0):(e.assign(n,r._`${n} || {}`),d(e,n,t))}),mergeValues:(e,t)=>!0===e||{...e,...t},resultToName:h}),items:c({mergeNames:(e,t,n)=>e.if(r._`${n} !== true && ${t} !== undefined`,()=>e.assign(n,r._`${t} === true ? true : ${n} > ${t} ? ${n} : ${t}`)),mergeToName:(e,t,n)=>e.if(r._`${n} !== true`,()=>e.assign(n,!0===t||r._`${n} > ${t} ? ${n} : ${t}`)),mergeValues:(e,t)=>!0===e||Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})},t.evaluatedPropsToName=h,t.setEvaluated=d;const u={};var p;function f(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.opts.strictSchema;if(n){if(t=`strict mode: ${t}`,!0===n)throw new Error(t);e.self.logger.warn(t)}}t.useFunc=function(e,t){return e.scopeValue("func",{ref:t,code:u[t.code]||(u[t.code]=new i._Code(t.code))})},function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"}(p||(t.Type=p={})),t.getErrorPath=function(e,t,n){if(e instanceof r.Name){const i=t===p.Num;return n?i?r._`"[" + ${e} + "]"`:r._`"['" + ${e} + "']"`:i?r._`"/" + ${e}`:r._`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return n?(0,r.getProperty)(e).toString():"/"+o(e)},t.checkStrictMode=f},50886(e,t){"use strict";function n(e,t){return t.rules.some(t=>r(e,t))}function r(e,t){var n;return void 0!==e[t.keyword]||(null===(n=t.definition.implements)||void 0===n?void 0:n.some(t=>void 0!==e[t]))}Object.defineProperty(t,"__esModule",{value:!0}),t.shouldUseRule=t.shouldUseGroup=t.schemaHasRulesForType=void 0,t.schemaHasRulesForType=function(e,t){let{schema:r,self:i}=e;const s=i.RULES.types[t];return s&&!0!==s&&n(r,s)},t.shouldUseGroup=n,t.shouldUseRule=r},96716(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.boolOrEmptySchema=t.topBoolOrEmptySchema=void 0;const r=n(7009),i=n(13578),s=n(81500),a={message:"boolean schema is false"};function o(e,t){const{gen:n,data:i}=e,s={gen:n,keyword:"false schema",data:i,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,r.reportError)(s,a,void 0,t)}t.topBoolOrEmptySchema=function(e){const{gen:t,schema:n,validateName:r}=e;!1===n?o(e,!1):"object"==typeof n&&!0===n.$async?t.return(s.default.data):(t.assign(i._`${r}.errors`,null),t.return(!0))},t.boolOrEmptySchema=function(e,t){const{gen:n,schema:r}=e;!1===r?(n.var(t,!1),o(e)):n.var(t,!0)}},11915(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.reportTypeError=t.checkDataTypes=t.checkDataType=t.coerceAndCheckDataType=t.getJSONTypes=t.getSchemaTypes=t.DataType=void 0;const r=n(66223),i=n(50886),s=n(7009),a=n(13578),o=n(14426);var l;function c(e){const t=Array.isArray(e)?e:e?[e]:[];if(t.every(r.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}!function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"}(l||(t.DataType=l={})),t.getSchemaTypes=function(e){const t=c(e.type);if(t.includes("null")){if(!1===e.nullable)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&void 0!==e.nullable)throw new Error('"nullable" cannot be used without "type"');!0===e.nullable&&t.push("null")}return t},t.getJSONTypes=c,t.coerceAndCheckDataType=function(e,t){const{gen:n,data:r,opts:s}=e,o=function(e,t){return t?e.filter(e=>h.has(e)||"array"===t&&"array"===e):[]}(t,s.coerceTypes),c=t.length>0&&!(0===o.length&&1===t.length&&(0,i.schemaHasRulesForType)(e,t[0]));if(c){const i=u(t,r,s.strictNumbers,l.Wrong);n.if(i,()=>{o.length?function(e,t,n){const{gen:r,data:i,opts:s}=e,o=r.let("dataType",a._`typeof ${i}`),l=r.let("coerced",a._`undefined`);"array"===s.coerceTypes&&r.if(a._`${o} == 'object' && Array.isArray(${i}) && ${i}.length == 1`,()=>r.assign(i,a._`${i}[0]`).assign(o,a._`typeof ${i}`).if(u(t,i,s.strictNumbers),()=>r.assign(l,i)));r.if(a._`${l} !== undefined`);for(const a of n)(h.has(a)||"array"===a&&"array"===s.coerceTypes)&&c(a);function c(e){switch(e){case"string":return void r.elseIf(a._`${o} == "number" || ${o} == "boolean"`).assign(l,a._`"" + ${i}`).elseIf(a._`${i} === null`).assign(l,a._`""`);case"number":return void r.elseIf(a._`${o} == "boolean" || ${i} === null
|
|
3
|
+
|| (${o} == "string" && ${i} && ${i} == +${i})`).assign(l,a._`+${i}`);case"integer":return void r.elseIf(a._`${o} === "boolean" || ${i} === null
|
|
4
|
+
|| (${o} === "string" && ${i} && ${i} == +${i} && !(${i} % 1))`).assign(l,a._`+${i}`);case"boolean":return void r.elseIf(a._`${i} === "false" || ${i} === 0 || ${i} === null`).assign(l,!1).elseIf(a._`${i} === "true" || ${i} === 1`).assign(l,!0);case"null":return r.elseIf(a._`${i} === "" || ${i} === 0 || ${i} === false`),void r.assign(l,null);case"array":r.elseIf(a._`${o} === "string" || ${o} === "number"
|
|
5
|
+
|| ${o} === "boolean" || ${i} === null`).assign(l,a._`[${i}]`)}}r.else(),f(e),r.endIf(),r.if(a._`${l} !== undefined`,()=>{r.assign(i,l),function(e,t){let{gen:n,parentData:r,parentDataProperty:i}=e;n.if(a._`${r} !== undefined`,()=>n.assign(a._`${r}[${i}]`,t))}(e,l)})}(e,t,o):f(e)})}return c};const h=new Set(["string","number","integer","boolean","null"]);function d(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:l.Correct;const i=r===l.Correct?a.operators.EQ:a.operators.NEQ;let s;switch(e){case"null":return a._`${t} ${i} null`;case"array":s=a._`Array.isArray(${t})`;break;case"object":s=a._`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":s=o(a._`!(${t} % 1) && !isNaN(${t})`);break;case"number":s=o();break;default:return a._`typeof ${t} ${i} ${e}`}return r===l.Correct?s:(0,a.not)(s);function o(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:a.nil;return(0,a.and)(a._`typeof ${t} == "number"`,e,n?a._`isFinite(${t})`:a.nil)}}function u(e,t,n,r){if(1===e.length)return d(e[0],t,n,r);let i;const s=(0,o.toHash)(e);if(s.array&&s.object){const e=a._`typeof ${t} != "object"`;i=s.null?e:a._`!${t} || ${e}`,delete s.null,delete s.array,delete s.object}else i=a.nil;s.number&&delete s.integer;for(const o in s)i=(0,a.and)(i,d(o,t,n,r));return i}t.checkDataType=d,t.checkDataTypes=u;const p={message:e=>{let{schema:t}=e;return`must be ${t}`},params:e=>{let{schema:t,schemaValue:n}=e;return"string"==typeof t?a._`{type: ${t}}`:a._`{type: ${n}}`}};function f(e){const t=function(e){const{gen:t,data:n,schema:r}=e,i=(0,o.schemaRefOrVal)(e,r,"type");return{gen:t,keyword:"type",data:n,schema:r.type,schemaCode:i,schemaValue:i,parentSchema:r,params:{},it:e}}(e);(0,s.reportError)(t,p)}t.reportTypeError=f},49897(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.assignDefaults=void 0;const r=n(13578),i=n(14426);function s(e,t,n){const{gen:s,compositeRule:a,data:o,opts:l}=e;if(void 0===n)return;const c=r._`${o}${(0,r.getProperty)(t)}`;if(a)return void(0,i.checkStrictMode)(e,`default is ignored for: ${c}`);let h=r._`${c} === undefined`;"empty"===l.useDefaults&&(h=r._`${h} || ${c} === null || ${c} === ""`),s.if(h,r._`${c} = ${(0,r.stringify)(n)}`)}t.assignDefaults=function(e,t){const{properties:n,items:r}=e.schema;if("object"===t&&n)for(const i in n)s(e,i,n[i].default);else"array"===t&&Array.isArray(r)&&r.forEach((t,n)=>s(e,n,t.default))}},80031(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getData=t.KeywordCxt=t.validateFunctionCode=void 0;const r=n(96716),i=n(11915),s=n(50886),a=n(11915),o=n(49897),l=n(13956),c=n(55530),h=n(13578),d=n(81500),u=n(48904),p=n(14426),f=n(7009);function m(e,t){let{gen:n,validateName:r,schema:i,schemaEnv:s,opts:a}=e;a.code.es5?n.func(r,h._`${d.default.data}, ${d.default.valCxt}`,s.$async,()=>{n.code(h._`"use strict"; ${g(i,a)}`),function(e,t){e.if(d.default.valCxt,()=>{e.var(d.default.instancePath,h._`${d.default.valCxt}.${d.default.instancePath}`),e.var(d.default.parentData,h._`${d.default.valCxt}.${d.default.parentData}`),e.var(d.default.parentDataProperty,h._`${d.default.valCxt}.${d.default.parentDataProperty}`),e.var(d.default.rootData,h._`${d.default.valCxt}.${d.default.rootData}`),t.dynamicRef&&e.var(d.default.dynamicAnchors,h._`${d.default.valCxt}.${d.default.dynamicAnchors}`)},()=>{e.var(d.default.instancePath,h._`""`),e.var(d.default.parentData,h._`undefined`),e.var(d.default.parentDataProperty,h._`undefined`),e.var(d.default.rootData,d.default.data),t.dynamicRef&&e.var(d.default.dynamicAnchors,h._`{}`)})}(n,a),n.code(t)}):n.func(r,h._`${d.default.data}, ${function(e){return h._`{${d.default.instancePath}="", ${d.default.parentData}, ${d.default.parentDataProperty}, ${d.default.rootData}=${d.default.data}${e.dynamicRef?h._`, ${d.default.dynamicAnchors}={}`:h.nil}}={}`}(a)}`,s.$async,()=>n.code(g(i,a)).code(t))}function g(e,t){const n="object"==typeof e&&e[t.schemaId];return n&&(t.code.source||t.code.process)?h._`/*# sourceURL=${n} */`:h.nil}function v(e,t){b(e)&&(w(e),y(e))?function(e,t){const{schema:n,gen:r,opts:i}=e;i.$comment&&n.$comment&&A(e);(function(e){const t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,u.resolveUrl)(e.opts.uriResolver,e.baseId,t))})(e),function(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}(e);const s=r.const("_errs",d.default.errors);_(e,s),r.var(t,h._`${s} === ${d.default.errors}`)}(e,t):(0,r.boolOrEmptySchema)(e,t)}function y(e){let{schema:t,self:n}=e;if("boolean"==typeof t)return!t;for(const r in t)if(n.RULES.all[r])return!0;return!1}function b(e){return"boolean"!=typeof e.schema}function w(e){(0,p.checkUnknownRules)(e),function(e){const{schema:t,errSchemaPath:n,opts:r,self:i}=e;t.$ref&&r.ignoreKeywordsWithRef&&(0,p.schemaHasRulesButRef)(t,i.RULES)&&i.logger.warn(`$ref: keywords ignored in schema at path "${n}"`)}(e)}function _(e,t){if(e.opts.jtd)return x(e,[],!1,t);const n=(0,i.getSchemaTypes)(e.schema);x(e,n,!(0,i.coerceAndCheckDataType)(e,n),t)}function A(e){let{gen:t,schemaEnv:n,schema:r,errSchemaPath:i,opts:s}=e;const a=r.$comment;if(!0===s.$comment)t.code(h._`${d.default.self}.logger.log(${a})`);else if("function"==typeof s.$comment){const e=h.str`${i}/$comment`,r=t.scopeValue("root",{ref:n.root});t.code(h._`${d.default.self}.opts.$comment(${a}, ${e}, ${r}.schema)`)}}function x(e,t,n,r){const{gen:i,schema:o,data:l,allErrors:c,opts:u,self:f}=e,{RULES:m}=f;function g(p){(0,s.shouldUseGroup)(o,p)&&(p.type?(i.if((0,a.checkDataType)(p.type,l,u.strictNumbers)),E(e,p),1===t.length&&t[0]===p.type&&n&&(i.else(),(0,a.reportTypeError)(e)),i.endIf()):E(e,p),c||i.if(h._`${d.default.errors} === ${r||0}`))}!o.$ref||!u.ignoreKeywordsWithRef&&(0,p.schemaHasRulesButRef)(o,m)?(u.jtd||function(e,t){if(e.schemaEnv.meta||!e.opts.strictTypes)return;(function(e,t){if(!t.length)return;if(!e.dataTypes.length)return void(e.dataTypes=t);t.forEach(t=>{k(e.dataTypes,t)||S(e,`type "${t}" not allowed by context "${e.dataTypes.join(",")}"`)}),function(e,t){const n=[];for(const r of e.dataTypes)k(t,r)?n.push(r):t.includes("integer")&&"number"===r&&n.push("integer");e.dataTypes=n}(e,t)})(e,t),e.opts.allowUnionTypes||function(e,t){t.length>1&&(2!==t.length||!t.includes("null"))&&S(e,"use allowUnionTypes to allow union type keyword")}(e,t);!function(e,t){const n=e.self.RULES.all;for(const r in n){const i=n[r];if("object"==typeof i&&(0,s.shouldUseRule)(e.schema,i)){const{type:n}=i.definition;n.length&&!n.some(e=>C(t,e))&&S(e,`missing type "${n.join(",")}" for keyword "${r}"`)}}}(e,e.dataTypes)}(e,t),i.block(()=>{for(const e of m.rules)g(e);g(m.post)})):i.block(()=>D(e,"$ref",m.all.$ref.definition))}function E(e,t){const{gen:n,schema:r,opts:{useDefaults:i}}=e;i&&(0,o.assignDefaults)(e,t.type),n.block(()=>{for(const n of t.rules)(0,s.shouldUseRule)(r,n)&&D(e,n.keyword,n.definition,t.type)})}function C(e,t){return e.includes(t)||"number"===t&&e.includes("integer")}function k(e,t){return e.includes(t)||"integer"===t&&e.includes("number")}function S(e,t){t+=` at "${e.schemaEnv.baseId+e.errSchemaPath}" (strictTypes)`,(0,p.checkStrictMode)(e,t,e.opts.strictTypes)}t.validateFunctionCode=function(e){b(e)&&(w(e),y(e))?function(e){const{schema:t,opts:n,gen:r}=e;m(e,()=>{n.$comment&&t.$comment&&A(e),function(e){const{schema:t,opts:n}=e;void 0!==t.default&&n.useDefaults&&n.strictSchema&&(0,p.checkStrictMode)(e,"default is ignored in the schema root")}(e),r.let(d.default.vErrors,null),r.let(d.default.errors,0),n.unevaluated&&function(e){const{gen:t,validateName:n}=e;e.evaluated=t.const("evaluated",h._`${n}.evaluated`),t.if(h._`${e.evaluated}.dynamicProps`,()=>t.assign(h._`${e.evaluated}.props`,h._`undefined`)),t.if(h._`${e.evaluated}.dynamicItems`,()=>t.assign(h._`${e.evaluated}.items`,h._`undefined`))}(e),_(e),function(e){const{gen:t,schemaEnv:n,validateName:r,ValidationError:i,opts:s}=e;n.$async?t.if(h._`${d.default.errors} === 0`,()=>t.return(d.default.data),()=>t.throw(h._`new ${i}(${d.default.vErrors})`)):(t.assign(h._`${r}.errors`,d.default.vErrors),s.unevaluated&&function(e){let{gen:t,evaluated:n,props:r,items:i}=e;r instanceof h.Name&&t.assign(h._`${n}.props`,r);i instanceof h.Name&&t.assign(h._`${n}.items`,i)}(e),t.return(h._`${d.default.errors} === 0`))}(e)})}(e):m(e,()=>(0,r.topBoolOrEmptySchema)(e))};class T{constructor(e,t,n){if((0,l.validateKeywordUsage)(e,t,n),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=n,this.data=e.data,this.schema=e.schema[n],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,p.schemaRefOrVal)(e,this.schema,n,this.$data),this.schemaType=t.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=t,this.$data)this.schemaCode=e.gen.const("vSchema",I(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,l.validSchemaType)(this.schema,t.schemaType,t.allowUndefined))throw new Error(`${n} value must be ${JSON.stringify(t.schemaType)}`);("code"in t?t.trackErrors:!1!==t.errors)&&(this.errsCount=e.gen.const("_errs",d.default.errors))}result(e,t,n){this.failResult((0,h.not)(e),t,n)}failResult(e,t,n){this.gen.if(e),n?n():this.error(),t?(this.gen.else(),t(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(e,t){this.failResult((0,h.not)(e),void 0,t)}fail(e){if(void 0===e)return this.error(),void(this.allErrors||this.gen.if(!1));this.gen.if(e),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);const{schemaCode:t}=this;this.fail(h._`${t} !== undefined && (${(0,h.or)(this.invalid$data(),e)})`)}error(e,t,n){if(t)return this.setParams(t),this._error(e,n),void this.setParams({});this._error(e,n)}_error(e,t){(e?f.reportExtraError:f.reportError)(this,this.def.error,t)}$dataError(){(0,f.reportError)(this,this.def.$dataError||f.keyword$DataError)}reset(){if(void 0===this.errsCount)throw new Error('add "trackErrors" to keyword definition');(0,f.resetErrorsCount)(this.gen,this.errsCount)}ok(e){this.allErrors||this.gen.if(e)}setParams(e,t){t?Object.assign(this.params,e):this.params=e}block$data(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:h.nil;this.gen.block(()=>{this.check$data(e,n),t()})}check$data(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:h.nil,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:h.nil;if(!this.$data)return;const{gen:n,schemaCode:r,schemaType:i,def:s}=this;n.if((0,h.or)(h._`${r} === undefined`,t)),e!==h.nil&&n.assign(e,!0),(i.length||s.validateSchema)&&(n.elseIf(this.invalid$data()),this.$dataError(),e!==h.nil&&n.assign(e,!1)),n.else()}invalid$data(){const{gen:e,schemaCode:t,schemaType:n,def:r,it:i}=this;return(0,h.or)(function(){if(n.length){if(!(t instanceof h.Name))throw new Error("ajv implementation error");const e=Array.isArray(n)?n:[n];return h._`${(0,a.checkDataTypes)(e,t,i.opts.strictNumbers,a.DataType.Wrong)}`}return h.nil}(),function(){if(r.validateSchema){const n=e.scopeValue("validate$data",{ref:r.validateSchema});return h._`!${n}(${t})`}return h.nil}())}subschema(e,t){const n=(0,c.getSubschema)(this.it,e);(0,c.extendSubschemaData)(n,this.it,e),(0,c.extendSubschemaMode)(n,e);const r={...this.it,...n,items:void 0,props:void 0};return v(r,t),r}mergeEvaluated(e,t){const{it:n,gen:r}=this;n.opts.unevaluated&&(!0!==n.props&&void 0!==e.props&&(n.props=p.mergeEvaluated.props(r,e.props,n.props,t)),!0!==n.items&&void 0!==e.items&&(n.items=p.mergeEvaluated.items(r,e.items,n.items,t)))}mergeValidEvaluated(e,t){const{it:n,gen:r}=this;if(n.opts.unevaluated&&(!0!==n.props||!0!==n.items))return r.if(t,()=>this.mergeEvaluated(e,h.Name)),!0}}function D(e,t,n,r){const i=new T(e,n,t);"code"in n?n.code(i,r):i.$data&&n.validate?(0,l.funcKeywordCode)(i,n):"macro"in n?(0,l.macroKeywordCode)(i,n):(n.compile||n.validate)&&(0,l.funcKeywordCode)(i,n)}t.KeywordCxt=T;const M=/^\/(?:[^~]|~0|~1)*$/,P=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function I(e,t){let n,r,{dataLevel:i,dataNames:s,dataPathArr:a}=t;if(""===e)return d.default.rootData;if("/"===e[0]){if(!M.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);n=e,r=d.default.rootData}else{const t=P.exec(e);if(!t)throw new Error(`Invalid JSON-pointer: ${e}`);const o=+t[1];if(n=t[2],"#"===n){if(o>=i)throw new Error(c("property/index",o));return a[i-o]}if(o>i)throw new Error(c("data",o));if(r=s[i-o],!n)return r}let o=r;const l=n.split("/");for(const d of l)d&&(r=h._`${r}${(0,h.getProperty)((0,p.unescapeJsonPointer)(d))}`,o=h._`${o} && ${r}`);return o;function c(e,t){return`Cannot access ${e} ${t} levels up, current level is ${i}`}}t.getData=I},13956(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateKeywordUsage=t.validSchemaType=t.funcKeywordCode=t.macroKeywordCode=void 0;const r=n(13578),i=n(81500),s=n(71762),a=n(7009);function o(e){const{gen:t,data:n,it:i}=e;t.if(i.parentData,()=>t.assign(n,r._`${i.parentData}[${i.parentDataProperty}]`))}function l(e,t,n){if(void 0===n)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword","function"==typeof n?{ref:n}:{ref:n,code:(0,r.stringify)(n)})}t.macroKeywordCode=function(e,t){const{gen:n,keyword:i,schema:s,parentSchema:a,it:o}=e,c=t.macro.call(o.self,s,a,o),h=l(n,i,c);!1!==o.opts.validateSchema&&o.self.validateSchema(c,!0);const d=n.name("valid");e.subschema({schema:c,schemaPath:r.nil,errSchemaPath:`${o.errSchemaPath}/${i}`,topSchemaRef:h,compositeRule:!0},d),e.pass(d,()=>e.error(!0))},t.funcKeywordCode=function(e,t){var n;const{gen:c,keyword:h,schema:d,parentSchema:u,$data:p,it:f}=e;!function(e,t){let{schemaEnv:n}=e;if(t.async&&!n.$async)throw new Error("async keyword in sync schema")}(f,t);const m=!p&&t.compile?t.compile.call(f.self,d,u,f):t.validate,g=l(c,h,m),v=c.let("valid");function y(){let n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:t.async?r._`await `:r.nil;const a=f.opts.passContext?i.default.this:i.default.self,o=!("compile"in t&&!p||!1===t.schema);c.assign(v,r._`${n}${(0,s.callValidateCode)(e,g,a,o)}`,t.modifying)}function b(e){var n;c.if((0,r.not)(null!==(n=t.valid)&&void 0!==n?n:v),e)}e.block$data(v,function(){if(!1===t.errors)y(),t.modifying&&o(e),b(()=>e.error());else{const n=t.async?function(){const e=c.let("ruleErrs",null);return c.try(()=>y(r._`await `),t=>c.assign(v,!1).if(r._`${t} instanceof ${f.ValidationError}`,()=>c.assign(e,r._`${t}.errors`),()=>c.throw(t))),e}():function(){const e=r._`${g}.errors`;return c.assign(e,null),y(r.nil),e}();t.modifying&&o(e),b(()=>function(e,t){const{gen:n}=e;n.if(r._`Array.isArray(${t})`,()=>{n.assign(i.default.vErrors,r._`${i.default.vErrors} === null ? ${t} : ${i.default.vErrors}.concat(${t})`).assign(i.default.errors,r._`${i.default.vErrors}.length`),(0,a.extendErrors)(e)},()=>e.error())}(e,n))}}),e.ok(null!==(n=t.valid)&&void 0!==n?n:v)},t.validSchemaType=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return!t.length||t.some(t=>"array"===t?Array.isArray(e):"object"===t?e&&"object"==typeof e&&!Array.isArray(e):typeof e==t||n&&"undefined"==typeof e)},t.validateKeywordUsage=function(e,t,n){let{schema:r,opts:i,self:s,errSchemaPath:a}=e;if(Array.isArray(t.keyword)?!t.keyword.includes(n):t.keyword!==n)throw new Error("ajv implementation error");const o=t.dependencies;if(null===o||void 0===o?void 0:o.some(e=>!Object.prototype.hasOwnProperty.call(r,e)))throw new Error(`parent schema must have dependencies of ${n}: ${o.join(",")}`);if(t.validateSchema){if(!t.validateSchema(r[n])){const e=`keyword "${n}" value is invalid at path "${a}": `+s.errorsText(t.validateSchema.errors);if("log"!==i.validateSchema)throw new Error(e);s.logger.error(e)}}}},55530(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.extendSubschemaMode=t.extendSubschemaData=t.getSubschema=void 0;const r=n(13578),i=n(14426);t.getSubschema=function(e,t){let{keyword:n,schemaProp:s,schema:a,schemaPath:o,errSchemaPath:l,topSchemaRef:c}=t;if(void 0!==n&&void 0!==a)throw new Error('both "keyword" and "schema" passed, only one allowed');if(void 0!==n){const t=e.schema[n];return void 0===s?{schema:t,schemaPath:r._`${e.schemaPath}${(0,r.getProperty)(n)}`,errSchemaPath:`${e.errSchemaPath}/${n}`}:{schema:t[s],schemaPath:r._`${e.schemaPath}${(0,r.getProperty)(n)}${(0,r.getProperty)(s)}`,errSchemaPath:`${e.errSchemaPath}/${n}/${(0,i.escapeFragment)(s)}`}}if(void 0!==a){if(void 0===o||void 0===l||void 0===c)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:a,schemaPath:o,topSchemaRef:c,errSchemaPath:l}}throw new Error('either "keyword" or "schema" must be passed')},t.extendSubschemaData=function(e,t,n){let{dataProp:s,dataPropType:a,data:o,dataTypes:l,propertyName:c}=n;if(void 0!==o&&void 0!==s)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:h}=t;if(void 0!==s){const{errorPath:n,dataPathArr:o,opts:l}=t;d(h.let("data",r._`${t.data}${(0,r.getProperty)(s)}`,!0)),e.errorPath=r.str`${n}${(0,i.getErrorPath)(s,a,l.jsPropertySyntax)}`,e.parentDataProperty=r._`${s}`,e.dataPathArr=[...o,e.parentDataProperty]}if(void 0!==o){d(o instanceof r.Name?o:h.let("data",o,!0)),void 0!==c&&(e.propertyName=c)}function d(n){e.data=n,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,n]}l&&(e.dataTypes=l)},t.extendSubschemaMode=function(e,t){let{jtdDiscriminator:n,jtdMetadata:r,compositeRule:i,createErrors:s,allErrors:a}=t;void 0!==i&&(e.compositeRule=i),void 0!==s&&(e.createErrors=s),void 0!==a&&(e.allErrors=a),e.jtdDiscriminator=n,e.jtdMetadata=r}},13575(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=void 0;var r=n(80031);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return r.KeywordCxt}});var i=n(13578);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return i._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return i.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return i.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return i.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return i.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return i.CodeGen}});const s=n(3351),a=n(19252),o=n(66223),l=n(28208),c=n(13578),h=n(48904),d=n(11915),u=n(14426),p=n(99209),f=n(97759),m=(e,t)=>new RegExp(e,t);m.code="new RegExp";const g=["removeAdditional","useDefaults","coerceTypes"],v=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),y={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},b={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'};function w(e){var t,n,r,i,s,a,o,l,c,h,d,u,p,g,v,y,b,w,_,A,x,E,C,k,S;const T=e.strict,D=null===(t=e.code)||void 0===t?void 0:t.optimize,M=!0===D||void 0===D?1:D||0,P=null!==(r=null===(n=e.code)||void 0===n?void 0:n.regExp)&&void 0!==r?r:m,I=null!==(i=e.uriResolver)&&void 0!==i?i:f.default;return{strictSchema:null===(a=null!==(s=e.strictSchema)&&void 0!==s?s:T)||void 0===a||a,strictNumbers:null===(l=null!==(o=e.strictNumbers)&&void 0!==o?o:T)||void 0===l||l,strictTypes:null!==(h=null!==(c=e.strictTypes)&&void 0!==c?c:T)&&void 0!==h?h:"log",strictTuples:null!==(u=null!==(d=e.strictTuples)&&void 0!==d?d:T)&&void 0!==u?u:"log",strictRequired:null!==(g=null!==(p=e.strictRequired)&&void 0!==p?p:T)&&void 0!==g&&g,code:e.code?{...e.code,optimize:M,regExp:P}:{optimize:M,regExp:P},loopRequired:null!==(v=e.loopRequired)&&void 0!==v?v:200,loopEnum:null!==(y=e.loopEnum)&&void 0!==y?y:200,meta:null===(b=e.meta)||void 0===b||b,messages:null===(w=e.messages)||void 0===w||w,inlineRefs:null===(_=e.inlineRefs)||void 0===_||_,schemaId:null!==(A=e.schemaId)&&void 0!==A?A:"$id",addUsedSchema:null===(x=e.addUsedSchema)||void 0===x||x,validateSchema:null===(E=e.validateSchema)||void 0===E||E,validateFormats:null===(C=e.validateFormats)||void 0===C||C,unicodeRegExp:null===(k=e.unicodeRegExp)||void 0===k||k,int32range:null===(S=e.int32range)||void 0===S||S,uriResolver:I}}class _{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...w(e)};const{es5:t,lines:n}=this.opts.code;this.scope=new c.ValueScope({scope:{},prefixes:v,es5:t,lines:n}),this.logger=function(e){if(!1===e)return T;if(void 0===e)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}(e.logger);const r=e.validateFormats;e.validateFormats=!1,this.RULES=(0,o.getRules)(),A.call(this,y,e,"NOT SUPPORTED"),A.call(this,b,e,"DEPRECATED","warn"),this._metaOpts=S.call(this),e.formats&&C.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&k.call(this,e.keywords),"object"==typeof e.meta&&this.addMetaSchema(e.meta),E.call(this),e.validateFormats=r}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:e,meta:t,schemaId:n}=this.opts;let r=p;"id"===n&&(r={...p},r.id=r.$id,delete r.$id),t&&e&&this.addMetaSchema(r,r[n],!1)}defaultMeta(){const{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta="object"==typeof e?e[t]||e:void 0}validate(e,t){let n;if("string"==typeof e){if(n=this.getSchema(e),!n)throw new Error(`no schema with key or ref "${e}"`)}else n=this.compile(e);const r=n(t);return"$async"in n||(this.errors=n.errors),r}compile(e,t){const n=this._addSchema(e,t);return n.validate||this._compileSchemaEnv(n)}compileAsync(e,t){if("function"!=typeof this.opts.loadSchema)throw new Error("options.loadSchema should be a function");const{loadSchema:n}=this.opts;return r.call(this,e,t);async function r(e,t){await i.call(this,e.$schema);const n=this._addSchema(e,t);return n.validate||s.call(this,n)}async function i(e){e&&!this.getSchema(e)&&await r.call(this,{$ref:e},!0)}async function s(e){try{return this._compileSchemaEnv(e)}catch(t){if(!(t instanceof a.default))throw t;return o.call(this,t),await l.call(this,t.missingSchema),s.call(this,e)}}function o(e){let{missingSchema:t,missingRef:n}=e;if(this.refs[t])throw new Error(`AnySchema ${t} is loaded but ${n} cannot be resolved`)}async function l(e){const n=await c.call(this,e);this.refs[e]||await i.call(this,n.$schema),this.refs[e]||this.addSchema(n,e,t)}async function c(e){const t=this._loading[e];if(t)return t;try{return await(this._loading[e]=n(e))}finally{delete this._loading[e]}}}addSchema(e,t,n){let r,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:this.opts.validateSchema;if(Array.isArray(e)){for(const t of e)this.addSchema(t,void 0,n,i);return this}if("object"===typeof e){const{schemaId:t}=this.opts;if(r=e[t],void 0!==r&&"string"!=typeof r)throw new Error(`schema ${t} must be string`)}return t=(0,h.normalizeId)(t||r),this._checkUnique(t),this.schemas[t]=this._addSchema(e,n,t,i,!0),this}addMetaSchema(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.opts.validateSchema;return this.addSchema(e,t,!0,n),this}validateSchema(e,t){if("boolean"==typeof e)return!0;let n;if(n=e.$schema,void 0!==n&&"string"!=typeof n)throw new Error("$schema must be a string");if(n=n||this.opts.defaultMeta||this.defaultMeta(),!n)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const r=this.validate(n,e);if(!r&&t){const e="schema is invalid: "+this.errorsText();if("log"!==this.opts.validateSchema)throw new Error(e);this.logger.error(e)}return r}getSchema(e){let t;for(;"string"==typeof(t=x.call(this,e));)e=t;if(void 0===t){const{schemaId:n}=this.opts,r=new l.SchemaEnv({schema:{},schemaId:n});if(t=l.resolveSchema.call(this,r,e),!t)return;this.refs[e]=t}return t.validate||this._compileSchemaEnv(t)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const t=x.call(this,e);return"object"==typeof t&&this._cache.delete(t.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{const t=e;this._cache.delete(t);let n=e[this.opts.schemaId];return n&&(n=(0,h.normalizeId)(n),delete this.schemas[n],delete this.refs[n]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(const t of e)this.addKeyword(t);return this}addKeyword(e,t){let n;if("string"==typeof e)n=e,"object"==typeof t&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=n);else{if("object"!=typeof e||void 0!==t)throw new Error("invalid addKeywords parameters");if(n=(t=e).keyword,Array.isArray(n)&&!n.length)throw new Error("addKeywords: keyword must be string or non-empty array")}if(M.call(this,n,t),!t)return(0,u.eachItem)(n,e=>P.call(this,e)),this;F.call(this,t);const r={...t,type:(0,d.getJSONTypes)(t.type),schemaType:(0,d.getJSONTypes)(t.schemaType)};return(0,u.eachItem)(n,0===r.type.length?e=>P.call(this,e,r):e=>r.type.forEach(t=>P.call(this,e,r,t))),this}getKeyword(e){const t=this.RULES.all[e];return"object"==typeof t?t.definition:!!t}removeKeyword(e){const{RULES:t}=this;delete t.keywords[e],delete t.all[e];for(const n of t.rules){const t=n.rules.findIndex(t=>t.keyword===e);t>=0&&n.rules.splice(t,1)}return this}addFormat(e,t){return"string"==typeof t&&(t=new RegExp(t)),this.formats[e]=t,this}errorsText(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.errors,{separator:t=", ",dataVar:n="data"}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e&&0!==e.length?e.map(e=>`${n}${e.instancePath} ${e.message}`).reduce((e,n)=>e+t+n):"No errors"}$dataMetaSchema(e,t){const n=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(const r of t){const t=r.split("/").slice(1);let i=e;for(const e of t)i=i[e];for(const e in n){const t=n[e];if("object"!=typeof t)continue;const{$data:r}=t.definition,s=i[e];r&&s&&(i[e]=N(s))}}return e}_removeAllSchemas(e,t){for(const n in e){const r=e[n];t&&!t.test(n)||("string"==typeof r?delete e[n]:r&&!r.meta&&(this._cache.delete(r.schema),delete e[n]))}}_addSchema(e,t,n){let r,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:this.opts.validateSchema,s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:this.opts.addUsedSchema;const{schemaId:a}=this.opts;if("object"==typeof e)r=e[a];else{if(this.opts.jtd)throw new Error("schema must be object");if("boolean"!=typeof e)throw new Error("schema must be object or boolean")}let o=this._cache.get(e);if(void 0!==o)return o;n=(0,h.normalizeId)(r||n);const c=h.getSchemaRefs.call(this,e,n);return o=new l.SchemaEnv({schema:e,schemaId:a,meta:t,baseId:n,localRefs:c}),this._cache.set(o.schema,o),s&&!n.startsWith("#")&&(n&&this._checkUnique(n),this.refs[n]=o),i&&this.validateSchema(e,!0),o}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw new Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):l.compileSchema.call(this,e),!e.validate)throw new Error("ajv implementation error");return e.validate}_compileMetaSchema(e){const t=this.opts;this.opts=this._metaOpts;try{l.compileSchema.call(this,e)}finally{this.opts=t}}}function A(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"error";for(const i in e){const s=i;s in t&&this.logger[r](`${n}: option ${i}. ${e[s]}`)}}function x(e){return e=(0,h.normalizeId)(e),this.schemas[e]||this.refs[e]}function E(){const e=this.opts.schemas;if(e)if(Array.isArray(e))this.addSchema(e);else for(const t in e)this.addSchema(e[t],t)}function C(){for(const e in this.opts.formats){const t=this.opts.formats[e];t&&this.addFormat(e,t)}}function k(e){if(Array.isArray(e))this.addVocabulary(e);else{this.logger.warn("keywords option as map is deprecated, pass array");for(const t in e){const n=e[t];n.keyword||(n.keyword=t),this.addKeyword(n)}}}function S(){const e={...this.opts};for(const t of g)delete e[t];return e}_.ValidationError=s.default,_.MissingRefError=a.default,t.default=_;const T={log(){},warn(){},error(){}};const D=/^[a-z_$][a-z0-9_$:-]*$/i;function M(e,t){const{RULES:n}=this;if((0,u.eachItem)(e,e=>{if(n.keywords[e])throw new Error(`Keyword ${e} is already defined`);if(!D.test(e))throw new Error(`Keyword ${e} has invalid name`)}),t&&t.$data&&!("code"in t)&&!("validate"in t))throw new Error('$data keyword must have "code" or "validate" function')}function P(e,t,n){var r;const i=null===t||void 0===t?void 0:t.post;if(n&&i)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:s}=this;let a=i?s.post:s.rules.find(e=>{let{type:t}=e;return t===n});if(a||(a={type:n,rules:[]},s.rules.push(a)),s.keywords[e]=!0,!t)return;const o={keyword:e,definition:{...t,type:(0,d.getJSONTypes)(t.type),schemaType:(0,d.getJSONTypes)(t.schemaType)}};t.before?I.call(this,a,o,t.before):a.rules.push(o),s.all[e]=o,null===(r=t.implements)||void 0===r||r.forEach(e=>this.addKeyword(e))}function I(e,t,n){const r=e.rules.findIndex(e=>e.keyword===n);r>=0?e.rules.splice(r,0,t):(e.rules.push(t),this.logger.warn(`rule ${n} is not defined`))}function F(e){let{metaSchema:t}=e;void 0!==t&&(e.$data&&this.opts.$data&&(t=N(t)),e.validateSchema=this.compile(t,!0))}const R={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function N(e){return{anyOf:[e,R]}}},59701(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(83080);r.code='require("ajv/dist/runtime/equal").default',t.default=r},77860(e,t){"use strict";function n(e){const t=e.length;let n,r=0,i=0;for(;i<t;)r++,n=e.charCodeAt(i++),n>=55296&&n<=56319&&i<t&&(n=e.charCodeAt(i),56320===(64512&n)&&i++);return r}Object.defineProperty(t,"__esModule",{value:!0}),t.default=n,n.code='require("ajv/dist/runtime/ucs2length").default'},97759(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(89314);r.code='require("ajv/dist/runtime/uri").default',t.default=r},3351(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});class n extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}}t.default=n},88434(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateAdditionalItems=void 0;const r=n(13578),i=n(14426),s={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:e=>{let{params:{len:t}}=e;return r.str`must NOT have more than ${t} items`},params:e=>{let{params:{len:t}}=e;return r._`{limit: ${t}}`}},code(e){const{parentSchema:t,it:n}=e,{items:r}=t;Array.isArray(r)?a(e,r):(0,i.checkStrictMode)(n,'"additionalItems" is ignored when "items" is not an array of schemas')}};function a(e,t){const{gen:n,schema:s,data:a,keyword:o,it:l}=e;l.items=!0;const c=n.const("len",r._`${a}.length`);if(!1===s)e.setParams({len:t.length}),e.pass(r._`${c} <= ${t.length}`);else if("object"==typeof s&&!(0,i.alwaysValidSchema)(l,s)){const s=n.var("valid",r._`${c} <= ${t.length}`);n.if((0,r.not)(s),()=>function(s){n.forRange("i",t.length,c,t=>{e.subschema({keyword:o,dataProp:t,dataPropType:i.Type.Num},s),l.allErrors||n.if((0,r.not)(s),()=>n.break())})}(s)),e.ok(s)}}t.validateAdditionalItems=a,t.default=s},99673(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(71762),i=n(13578),s=n(81500),a=n(14426),o={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:e=>{let{params:t}=e;return i._`{additionalProperty: ${t.additionalProperty}}`}},code(e){const{gen:t,schema:n,parentSchema:o,data:l,errsCount:c,it:h}=e;if(!c)throw new Error("ajv implementation error");const{allErrors:d,opts:u}=h;if(h.props=!0,"all"!==u.removeAdditional&&(0,a.alwaysValidSchema)(h,n))return;const p=(0,r.allSchemaProperties)(o.properties),f=(0,r.allSchemaProperties)(o.patternProperties);function m(e){t.code(i._`delete ${l}[${e}]`)}function g(r){if("all"===u.removeAdditional||u.removeAdditional&&!1===n)m(r);else{if(!1===n)return e.setParams({additionalProperty:r}),e.error(),void(d||t.break());if("object"==typeof n&&!(0,a.alwaysValidSchema)(h,n)){const n=t.name("valid");"failing"===u.removeAdditional?(v(r,n,!1),t.if((0,i.not)(n),()=>{e.reset(),m(r)})):(v(r,n),d||t.if((0,i.not)(n),()=>t.break()))}}}function v(t,n,r){const i={keyword:"additionalProperties",dataProp:t,dataPropType:a.Type.Str};!1===r&&Object.assign(i,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(i,n)}t.forIn("key",l,n=>{p.length||f.length?t.if(function(n){let s;if(p.length>8){const e=(0,a.schemaRefOrVal)(h,o.properties,"properties");s=(0,r.isOwnProperty)(t,e,n)}else s=p.length?(0,i.or)(...p.map(e=>i._`${n} === ${e}`)):i.nil;return f.length&&(s=(0,i.or)(s,...f.map(t=>i._`${(0,r.usePattern)(e,t)}.test(${n})`))),(0,i.not)(s)}(n),()=>g(n)):g(n)}),e.ok(i._`${c} === ${s.default.errors}`)}};t.default=o},27739(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(14426),i={keyword:"allOf",schemaType:"array",code(e){const{gen:t,schema:n,it:i}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");const s=t.name("valid");n.forEach((t,n)=>{if((0,r.alwaysValidSchema)(i,t))return;const a=e.subschema({keyword:"allOf",schemaProp:n},s);e.ok(s),e.mergeEvaluated(a)})}};t.default=i},63686(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:n(71762).validateUnion,error:{message:"must match a schema in anyOf"}};t.default=r},9708(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i=n(14426),s={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:e=>{let{params:{min:t,max:n}}=e;return void 0===n?r.str`must contain at least ${t} valid item(s)`:r.str`must contain at least ${t} and no more than ${n} valid item(s)`},params:e=>{let{params:{min:t,max:n}}=e;return void 0===n?r._`{minContains: ${t}}`:r._`{minContains: ${t}, maxContains: ${n}}`}},code(e){const{gen:t,schema:n,parentSchema:s,data:a,it:o}=e;let l,c;const{minContains:h,maxContains:d}=s;o.opts.next?(l=void 0===h?1:h,c=d):l=1;const u=t.const("len",r._`${a}.length`);if(e.setParams({min:l,max:c}),void 0===c&&0===l)return void(0,i.checkStrictMode)(o,'"minContains" == 0 without "maxContains": "contains" keyword ignored');if(void 0!==c&&l>c)return(0,i.checkStrictMode)(o,'"minContains" > "maxContains" is always invalid'),void e.fail();if((0,i.alwaysValidSchema)(o,n)){let t=r._`${u} >= ${l}`;return void 0!==c&&(t=r._`${t} && ${u} <= ${c}`),void e.pass(t)}o.items=!0;const p=t.name("valid");function f(){const e=t.name("_valid"),n=t.let("count",0);m(e,()=>t.if(e,()=>function(e){t.code(r._`${e}++`),void 0===c?t.if(r._`${e} >= ${l}`,()=>t.assign(p,!0).break()):(t.if(r._`${e} > ${c}`,()=>t.assign(p,!1).break()),1===l?t.assign(p,!0):t.if(r._`${e} >= ${l}`,()=>t.assign(p,!0)))}(n)))}function m(n,r){t.forRange("i",0,u,t=>{e.subschema({keyword:"contains",dataProp:t,dataPropType:i.Type.Num,compositeRule:!0},n),r()})}void 0===c&&1===l?m(p,()=>t.if(p,()=>t.break())):0===l?(t.let(p,!0),void 0!==c&&t.if(r._`${a}.length > 0`,f)):(t.let(p,!1),f()),e.result(p,()=>e.reset())}};t.default=s},52924(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateSchemaDeps=t.validatePropertyDeps=t.error=void 0;const r=n(13578),i=n(14426),s=n(71762);t.error={message:e=>{let{params:{property:t,depsCount:n,deps:i}}=e;const s=1===n?"property":"properties";return r.str`must have ${s} ${i} when property ${t} is present`},params:e=>{let{params:{property:t,depsCount:n,deps:i,missingProperty:s}}=e;return r._`{property: ${t},
|
|
6
|
+
missingProperty: ${s},
|
|
7
|
+
depsCount: ${n},
|
|
8
|
+
deps: ${i}}`}};const a={keyword:"dependencies",type:"object",schemaType:"object",error:t.error,code(e){const[t,n]=function(e){let{schema:t}=e;const n={},r={};for(const i in t){if("__proto__"===i)continue;(Array.isArray(t[i])?n:r)[i]=t[i]}return[n,r]}(e);o(e,t),l(e,n)}};function o(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.schema;const{gen:n,data:i,it:a}=e;if(0===Object.keys(t).length)return;const o=n.let("missing");for(const l in t){const c=t[l];if(0===c.length)continue;const h=(0,s.propertyInData)(n,i,l,a.opts.ownProperties);e.setParams({property:l,depsCount:c.length,deps:c.join(", ")}),a.allErrors?n.if(h,()=>{for(const t of c)(0,s.checkReportMissingProp)(e,t)}):(n.if(r._`${h} && (${(0,s.checkMissingProp)(e,c,o)})`),(0,s.reportMissingProp)(e,o),n.else())}}function l(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.schema;const{gen:n,data:r,keyword:a,it:o}=e,l=n.name("valid");for(const c in t)(0,i.alwaysValidSchema)(o,t[c])||(n.if((0,s.propertyInData)(n,r,c,o.opts.ownProperties),()=>{const t=e.subschema({keyword:a,schemaProp:c},l);e.mergeValidEvaluated(t,l)},()=>n.var(l,!0)),e.ok(l))}t.validatePropertyDeps=o,t.validateSchemaDeps=l,t.default=a},2958(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i=n(14426),s={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:e=>{let{params:t}=e;return r.str`must match "${t.ifClause}" schema`},params:e=>{let{params:t}=e;return r._`{failingKeyword: ${t.ifClause}}`}},code(e){const{gen:t,parentSchema:n,it:s}=e;void 0===n.then&&void 0===n.else&&(0,i.checkStrictMode)(s,'"if" without "then" and "else" is ignored');const o=a(s,"then"),l=a(s,"else");if(!o&&!l)return;const c=t.let("valid",!0),h=t.name("_valid");if(function(){const t=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},h);e.mergeEvaluated(t)}(),e.reset(),o&&l){const n=t.let("ifClause");e.setParams({ifClause:n}),t.if(h,d("then",n),d("else",n))}else o?t.if(h,d("then")):t.if((0,r.not)(h),d("else"));function d(n,i){return()=>{const s=e.subschema({keyword:n},h);t.assign(c,h),e.mergeValidEvaluated(s,c),i?t.assign(i,r._`${n}`):e.setParams({ifClause:n})}}e.pass(c,()=>e.error(!0))}};function a(e,t){const n=e.schema[t];return void 0!==n&&!(0,i.alwaysValidSchema)(e,n)}t.default=s},95089(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(88434),i=n(55365),s=n(63545),a=n(70729),o=n(9708),l=n(52924),c=n(44702),h=n(99673),d=n(38732),u=n(69526),p=n(37372),f=n(63686),m=n(30704),g=n(27739),v=n(2958),y=n(33543);t.default=function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];const t=[p.default,f.default,m.default,g.default,v.default,y.default,c.default,h.default,l.default,d.default,u.default];return e?t.push(i.default,a.default):t.push(r.default,s.default),t.push(o.default),t}},63545(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateTuple=void 0;const r=n(13578),i=n(14426),s=n(71762),a={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){const{schema:t,it:n}=e;if(Array.isArray(t))return o(e,"additionalItems",t);n.items=!0,(0,i.alwaysValidSchema)(n,t)||e.ok((0,s.validateArray)(e))}};function o(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.schema;const{gen:s,parentSchema:a,data:o,keyword:l,it:c}=e;!function(e){const{opts:r,errSchemaPath:s}=c,a=n.length,o=a===e.minItems&&(a===e.maxItems||!1===e[t]);if(r.strictTuples&&!o){const e=`"${l}" is ${a}-tuple, but minItems or maxItems/${t} are not specified or different at path "${s}"`;(0,i.checkStrictMode)(c,e,r.strictTuples)}}(a),c.opts.unevaluated&&n.length&&!0!==c.items&&(c.items=i.mergeEvaluated.items(s,n.length,c.items));const h=s.name("valid"),d=s.const("len",r._`${o}.length`);n.forEach((t,n)=>{(0,i.alwaysValidSchema)(c,t)||(s.if(r._`${d} > ${n}`,()=>e.subschema({keyword:l,schemaProp:n,dataProp:n},h)),e.ok(h))})}t.validateTuple=o,t.default=a},70729(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i=n(14426),s=n(71762),a=n(88434),o={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:e=>{let{params:{len:t}}=e;return r.str`must NOT have more than ${t} items`},params:e=>{let{params:{len:t}}=e;return r._`{limit: ${t}}`}},code(e){const{schema:t,parentSchema:n,it:r}=e,{prefixItems:o}=n;r.items=!0,(0,i.alwaysValidSchema)(r,t)||(o?(0,a.validateAdditionalItems)(e,o):e.ok((0,s.validateArray)(e)))}};t.default=o},37372(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(14426),i={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){const{gen:t,schema:n,it:i}=e;if((0,r.alwaysValidSchema)(i,n))return void e.fail();const s=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},s),e.failResult(s,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};t.default=i},30704(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i=n(14426),s={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:e=>{let{params:t}=e;return r._`{passingSchemas: ${t.passing}}`}},code(e){const{gen:t,schema:n,parentSchema:s,it:a}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");if(a.opts.discriminator&&s.discriminator)return;const o=n,l=t.let("valid",!1),c=t.let("passing",null),h=t.name("_valid");e.setParams({passing:c}),t.block(function(){o.forEach((n,s)=>{let o;(0,i.alwaysValidSchema)(a,n)?t.var(h,!0):o=e.subschema({keyword:"oneOf",schemaProp:s,compositeRule:!0},h),s>0&&t.if(r._`${h} && ${l}`).assign(l,!1).assign(c,r._`[${c}, ${s}]`).else(),t.if(h,()=>{t.assign(l,!0),t.assign(c,s),o&&e.mergeEvaluated(o,r.Name)})})}),e.result(l,()=>e.reset(),()=>e.error(!0))}};t.default=s},69526(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(71762),i=n(13578),s=n(14426),a=n(14426),o={keyword:"patternProperties",type:"object",schemaType:"object",code(e){const{gen:t,schema:n,data:o,parentSchema:l,it:c}=e,{opts:h}=c,d=(0,r.allSchemaProperties)(n),u=d.filter(e=>(0,s.alwaysValidSchema)(c,n[e]));if(0===d.length||u.length===d.length&&(!c.opts.unevaluated||!0===c.props))return;const p=h.strictSchema&&!h.allowMatchingProperties&&l.properties,f=t.name("valid");!0===c.props||c.props instanceof i.Name||(c.props=(0,a.evaluatedPropsToName)(t,c.props));const{props:m}=c;function g(e){for(const t in p)new RegExp(e).test(t)&&(0,s.checkStrictMode)(c,`property ${t} matches pattern ${e} (use allowMatchingProperties)`)}function v(n){t.forIn("key",o,s=>{t.if(i._`${(0,r.usePattern)(e,n)}.test(${s})`,()=>{const r=u.includes(n);r||e.subschema({keyword:"patternProperties",schemaProp:n,dataProp:s,dataPropType:a.Type.Str},f),c.opts.unevaluated&&!0!==m?t.assign(i._`${m}[${s}]`,!0):r||c.allErrors||t.if((0,i.not)(f),()=>t.break())})})}!function(){for(const e of d)p&&g(e),c.allErrors?v(e):(t.var(f,!0),v(e),t.if(f))}()}};t.default=o},55365(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(63545),i={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,r.validateTuple)(e,"items")};t.default=i},38732(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(80031),i=n(71762),s=n(14426),a=n(99673),o={keyword:"properties",type:"object",schemaType:"object",code(e){const{gen:t,schema:n,parentSchema:o,data:l,it:c}=e;"all"===c.opts.removeAdditional&&void 0===o.additionalProperties&&a.default.code(new r.KeywordCxt(c,a.default,"additionalProperties"));const h=(0,i.allSchemaProperties)(n);for(const r of h)c.definedProperties.add(r);c.opts.unevaluated&&h.length&&!0!==c.props&&(c.props=s.mergeEvaluated.props(t,(0,s.toHash)(h),c.props));const d=h.filter(e=>!(0,s.alwaysValidSchema)(c,n[e]));if(0===d.length)return;const u=t.name("valid");for(const r of d)p(r)?f(r):(t.if((0,i.propertyInData)(t,l,r,c.opts.ownProperties)),f(r),c.allErrors||t.else().var(u,!0),t.endIf()),e.it.definedProperties.add(r),e.ok(u);function p(e){return c.opts.useDefaults&&!c.compositeRule&&void 0!==n[e].default}function f(t){e.subschema({keyword:"properties",schemaProp:t,dataProp:t},u)}}};t.default=o},44702(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i=n(14426),s={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:e=>{let{params:t}=e;return r._`{propertyName: ${t.propertyName}}`}},code(e){const{gen:t,schema:n,data:s,it:a}=e;if((0,i.alwaysValidSchema)(a,n))return;const o=t.name("valid");t.forIn("key",s,n=>{e.setParams({propertyName:n}),e.subschema({keyword:"propertyNames",data:n,dataTypes:["string"],propertyName:n,compositeRule:!0},o),t.if((0,r.not)(o),()=>{e.error(!0),a.allErrors||t.break()})}),e.ok(o)}};t.default=s},33543(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(14426),i={keyword:["then","else"],schemaType:["object","boolean"],code(e){let{keyword:t,parentSchema:n,it:i}=e;void 0===n.if&&(0,r.checkStrictMode)(i,`"${t}" without "if" is ignored`)}};t.default=i},71762(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateUnion=t.validateArray=t.usePattern=t.callValidateCode=t.schemaProperties=t.allSchemaProperties=t.noPropertyInData=t.propertyInData=t.isOwnProperty=t.hasPropFunc=t.reportMissingProp=t.checkMissingProp=t.checkReportMissingProp=void 0;const r=n(13578),i=n(14426),s=n(81500),a=n(14426);function o(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:r._`Object.prototype.hasOwnProperty`})}function l(e,t,n){return r._`${o(e)}.call(${t}, ${n})`}function c(e,t,n,i){const s=r._`${t}${(0,r.getProperty)(n)} === undefined`;return i?(0,r.or)(s,(0,r.not)(l(e,t,n))):s}function h(e){return e?Object.keys(e).filter(e=>"__proto__"!==e):[]}t.checkReportMissingProp=function(e,t){const{gen:n,data:i,it:s}=e;n.if(c(n,i,t,s.opts.ownProperties),()=>{e.setParams({missingProperty:r._`${t}`},!0),e.error()})},t.checkMissingProp=function(e,t,n){let{gen:i,data:s,it:{opts:a}}=e;return(0,r.or)(...t.map(e=>(0,r.and)(c(i,s,e,a.ownProperties),r._`${n} = ${e}`)))},t.reportMissingProp=function(e,t){e.setParams({missingProperty:t},!0),e.error()},t.hasPropFunc=o,t.isOwnProperty=l,t.propertyInData=function(e,t,n,i){const s=r._`${t}${(0,r.getProperty)(n)} !== undefined`;return i?r._`${s} && ${l(e,t,n)}`:s},t.noPropertyInData=c,t.allSchemaProperties=h,t.schemaProperties=function(e,t){return h(t).filter(n=>!(0,i.alwaysValidSchema)(e,t[n]))},t.callValidateCode=function(e,t,n,i){let{schemaCode:a,data:o,it:{gen:l,topSchemaRef:c,schemaPath:h,errorPath:d},it:u}=e;const p=i?r._`${a}, ${o}, ${c}${h}`:o,f=[[s.default.instancePath,(0,r.strConcat)(s.default.instancePath,d)],[s.default.parentData,u.parentData],[s.default.parentDataProperty,u.parentDataProperty],[s.default.rootData,s.default.rootData]];u.opts.dynamicRef&&f.push([s.default.dynamicAnchors,s.default.dynamicAnchors]);const m=r._`${p}, ${l.object(...f)}`;return n!==r.nil?r._`${t}.call(${n}, ${m})`:r._`${t}(${m})`};const d=r._`new RegExp`;t.usePattern=function(e,t){let{gen:n,it:{opts:i}}=e;const s=i.unicodeRegExp?"u":"",{regExp:o}=i.code,l=o(t,s);return n.scopeValue("pattern",{key:l.toString(),ref:l,code:r._`${"new RegExp"===o.code?d:(0,a.useFunc)(n,o)}(${t}, ${s})`})},t.validateArray=function(e){const{gen:t,data:n,keyword:s,it:a}=e,o=t.name("valid");if(a.allErrors){const e=t.let("valid",!0);return l(()=>t.assign(e,!1)),e}return t.var(o,!0),l(()=>t.break()),o;function l(a){const l=t.const("len",r._`${n}.length`);t.forRange("i",0,l,n=>{e.subschema({keyword:s,dataProp:n,dataPropType:i.Type.Num},o),t.if((0,r.not)(o),a)})}},t.validateUnion=function(e){const{gen:t,schema:n,keyword:s,it:a}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");if(n.some(e=>(0,i.alwaysValidSchema)(a,e))&&!a.opts.unevaluated)return;const o=t.let("valid",!1),l=t.name("_valid");t.block(()=>n.forEach((n,i)=>{const a=e.subschema({keyword:s,schemaProp:i,compositeRule:!0},l);t.assign(o,r._`${o} || ${l}`);e.mergeValidEvaluated(a,l)||t.if((0,r.not)(o))})),e.result(o,()=>e.reset(),()=>e.error(!0))}},23194(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};t.default=n},39615(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(23194),i=n(51226),s=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",r.default,i.default];t.default=s},51226(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.callRef=t.getValidate=void 0;const r=n(19252),i=n(71762),s=n(13578),a=n(81500),o=n(28208),l=n(14426),c={keyword:"$ref",schemaType:"string",code(e){const{gen:t,schema:n,it:i}=e,{baseId:a,schemaEnv:l,validateName:c,opts:u,self:p}=i,{root:f}=l;if(("#"===n||"#/"===n)&&a===f.baseId)return function(){if(l===f)return d(e,c,l,l.$async);const n=t.scopeValue("root",{ref:f});return d(e,s._`${n}.validate`,f,f.$async)}();const m=o.resolveRef.call(p,f,a,n);if(void 0===m)throw new r.default(i.opts.uriResolver,a,n);return m instanceof o.SchemaEnv?function(t){const n=h(e,t);d(e,n,t,t.$async)}(m):function(r){const i=t.scopeValue("schema",!0===u.code.source?{ref:r,code:(0,s.stringify)(r)}:{ref:r}),a=t.name("valid"),o=e.subschema({schema:r,dataTypes:[],schemaPath:s.nil,topSchemaRef:i,errSchemaPath:n},a);e.mergeEvaluated(o),e.ok(a)}(m)}};function h(e,t){const{gen:n}=e;return t.validate?n.scopeValue("validate",{ref:t.validate}):s._`${n.scopeValue("wrapper",{ref:t})}.validate`}function d(e,t,n,r){const{gen:o,it:c}=e,{allErrors:h,schemaEnv:d,opts:u}=c,p=u.passContext?a.default.this:s.nil;function f(e){const t=s._`${e}.errors`;o.assign(a.default.vErrors,s._`${a.default.vErrors} === null ? ${t} : ${a.default.vErrors}.concat(${t})`),o.assign(a.default.errors,s._`${a.default.vErrors}.length`)}function m(e){var t;if(!c.opts.unevaluated)return;const r=null===(t=null===n||void 0===n?void 0:n.validate)||void 0===t?void 0:t.evaluated;if(!0!==c.props)if(r&&!r.dynamicProps)void 0!==r.props&&(c.props=l.mergeEvaluated.props(o,r.props,c.props));else{const t=o.var("props",s._`${e}.evaluated.props`);c.props=l.mergeEvaluated.props(o,t,c.props,s.Name)}if(!0!==c.items)if(r&&!r.dynamicItems)void 0!==r.items&&(c.items=l.mergeEvaluated.items(o,r.items,c.items));else{const t=o.var("items",s._`${e}.evaluated.items`);c.items=l.mergeEvaluated.items(o,t,c.items,s.Name)}}r?function(){if(!d.$async)throw new Error("async schema referenced by sync schema");const n=o.let("valid");o.try(()=>{o.code(s._`await ${(0,i.callValidateCode)(e,t,p)}`),m(t),h||o.assign(n,!0)},e=>{o.if(s._`!(${e} instanceof ${c.ValidationError})`,()=>o.throw(e)),f(e),h||o.assign(n,!1)}),e.ok(n)}():e.result((0,i.callValidateCode)(e,t,p),()=>m(t),()=>f(t))}t.getValidate=h,t.callRef=d,t.default=c},55e3(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i=n(44381),s=n(28208),a=n(19252),o=n(14426),l={keyword:"discriminator",type:"object",schemaType:"object",error:{message:e=>{let{params:{discrError:t,tagName:n}}=e;return t===i.DiscrError.Tag?`tag "${n}" must be string`:`value of tag "${n}" must be in oneOf`},params:e=>{let{params:{discrError:t,tag:n,tagName:i}}=e;return r._`{error: ${t}, tag: ${i}, tagValue: ${n}}`}},code(e){const{gen:t,data:n,schema:l,parentSchema:c,it:h}=e,{oneOf:d}=c;if(!h.opts.discriminator)throw new Error("discriminator: requires discriminator option");const u=l.propertyName;if("string"!=typeof u)throw new Error("discriminator: requires propertyName");if(l.mapping)throw new Error("discriminator: mapping is not supported");if(!d)throw new Error("discriminator: requires oneOf keyword");const p=t.let("valid",!1),f=t.const("tag",r._`${n}${(0,r.getProperty)(u)}`);function m(n){const i=t.name("valid"),s=e.subschema({keyword:"oneOf",schemaProp:n},i);return e.mergeEvaluated(s,r.Name),i}t.if(r._`typeof ${f} == "string"`,()=>function(){const n=function(){var e;const t={},n=i(c);let r=!0;for(let c=0;c<d.length;c++){let t=d[c];if((null===t||void 0===t?void 0:t.$ref)&&!(0,o.schemaHasRulesButRef)(t,h.self.RULES)){const e=t.$ref;if(t=s.resolveRef.call(h.self,h.schemaEnv.root,h.baseId,e),t instanceof s.SchemaEnv&&(t=t.schema),void 0===t)throw new a.default(h.opts.uriResolver,h.baseId,e)}const p=null===(e=null===t||void 0===t?void 0:t.properties)||void 0===e?void 0:e[u];if("object"!=typeof p)throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${u}"`);r=r&&(n||i(t)),l(p,c)}if(!r)throw new Error(`discriminator: "${u}" must be required`);return t;function i(e){let{required:t}=e;return Array.isArray(t)&&t.includes(u)}function l(e,t){if(e.const)p(e.const,t);else{if(!e.enum)throw new Error(`discriminator: "properties/${u}" must have "const" or "enum"`);for(const n of e.enum)p(n,t)}}function p(e,n){if("string"!=typeof e||e in t)throw new Error(`discriminator: "${u}" values must be unique strings`);t[e]=n}}();t.if(!1);for(const e in n)t.elseIf(r._`${f} === ${e}`),t.assign(p,m(n[e]));t.else(),e.error(!1,{discrError:i.DiscrError.Mapping,tag:f,tagName:u}),t.endIf()}(),()=>e.error(!1,{discrError:i.DiscrError.Tag,tag:f,tagName:u})),e.ok(p)}};t.default=l},44381(e,t){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.DiscrError=void 0,function(e){e.Tag="tag",e.Mapping="mapping"}(n||(t.DiscrError=n={}))},97279(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(39615),i=n(52251),s=n(95089),a=n(92875),o=n(36450),l=[r.default,i.default,(0,s.default)(),a.default,o.metadataVocabulary,o.contentVocabulary];t.default=l},23920(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:e=>{let{schemaCode:t}=e;return r.str`must match format "${t}"`},params:e=>{let{schemaCode:t}=e;return r._`{format: ${t}}`}},code(e,t){const{gen:n,data:i,$data:s,schema:a,schemaCode:o,it:l}=e,{opts:c,errSchemaPath:h,schemaEnv:d,self:u}=l;c.validateFormats&&(s?function(){const s=n.scopeValue("formats",{ref:u.formats,code:c.code.formats}),a=n.const("fDef",r._`${s}[${o}]`),l=n.let("fType"),h=n.let("format");n.if(r._`typeof ${a} == "object" && !(${a} instanceof RegExp)`,()=>n.assign(l,r._`${a}.type || "string"`).assign(h,r._`${a}.validate`),()=>n.assign(l,r._`"string"`).assign(h,a)),e.fail$data((0,r.or)(!1===c.strictSchema?r.nil:r._`${o} && !${h}`,function(){const e=d.$async?r._`(${a}.async ? await ${h}(${i}) : ${h}(${i}))`:r._`${h}(${i})`,n=r._`(typeof ${h} == "function" ? ${e} : ${h}.test(${i}))`;return r._`${h} && ${h} !== true && ${l} === ${t} && !${n}`}()))}():function(){const s=u.formats[a];if(!s)return void function(){if(!1===c.strictSchema)return void u.logger.warn(e());throw new Error(e());function e(){return`unknown format "${a}" ignored in schema at path "${h}"`}}();if(!0===s)return;const[o,l,p]=function(e){const t=e instanceof RegExp?(0,r.regexpCode)(e):c.code.formats?r._`${c.code.formats}${(0,r.getProperty)(a)}`:void 0,i=n.scopeValue("formats",{key:a,ref:e,code:t});if("object"==typeof e&&!(e instanceof RegExp))return[e.type||"string",e.validate,r._`${i}.validate`];return["string",e,i]}(s);o===t&&e.pass(function(){if("object"==typeof s&&!(s instanceof RegExp)&&s.async){if(!d.$async)throw new Error("async format in sync schema");return r._`await ${p}(${i})`}return"function"==typeof l?r._`${p}(${i})`:r._`${p}.test(${i})`}())}())}};t.default=i},92875(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=[n(23920).default];t.default=r},36450(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.contentVocabulary=t.metadataVocabulary=void 0,t.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],t.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]},33600(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i=n(14426),s=n(59701),a={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:e=>{let{schemaCode:t}=e;return r._`{allowedValue: ${t}}`}},code(e){const{gen:t,data:n,$data:a,schemaCode:o,schema:l}=e;a||l&&"object"==typeof l?e.fail$data(r._`!${(0,i.useFunc)(t,s.default)}(${n}, ${o})`):e.fail(r._`${l} !== ${n}`)}};t.default=a},67366(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i=n(14426),s=n(59701),a={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:e=>{let{schemaCode:t}=e;return r._`{allowedValues: ${t}}`}},code(e){const{gen:t,data:n,$data:a,schema:o,schemaCode:l,it:c}=e;if(!a&&0===o.length)throw new Error("enum must have non-empty array");const h=o.length>=c.opts.loopEnum;let d;const u=()=>null!==d&&void 0!==d?d:d=(0,i.useFunc)(t,s.default);let p;if(h||a)p=t.let("valid"),e.block$data(p,function(){t.assign(p,!1),t.forOf("v",l,e=>t.if(r._`${u()}(${n}, ${e})`,()=>t.assign(p,!0).break()))});else{if(!Array.isArray(o))throw new Error("ajv implementation error");const e=t.const("vSchema",l);p=(0,r.or)(...o.map((t,i)=>function(e,t){const i=o[t];return"object"===typeof i&&null!==i?r._`${u()}(${n}, ${e}[${t}])`:r._`${n} === ${i}`}(e,i)))}e.pass(p)}};t.default=a},52251(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(46189),i=n(65486),s=n(82464),a=n(5453),o=n(25925),l=n(32858),c=n(73598),h=n(48250),d=n(33600),u=n(67366),p=[r.default,i.default,s.default,a.default,o.default,l.default,c.default,h.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},d.default,u.default];t.default=p},73598(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message(e){let{keyword:t,schemaCode:n}=e;const i="maxItems"===t?"more":"fewer";return r.str`must NOT have ${i} than ${n} items`},params:e=>{let{schemaCode:t}=e;return r._`{limit: ${t}}`}},code(e){const{keyword:t,data:n,schemaCode:i}=e,s="maxItems"===t?r.operators.GT:r.operators.LT;e.fail$data(r._`${n}.length ${s} ${i}`)}};t.default=i},82464(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i=n(14426),s=n(77860),a={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message(e){let{keyword:t,schemaCode:n}=e;const i="maxLength"===t?"more":"fewer";return r.str`must NOT have ${i} than ${n} characters`},params:e=>{let{schemaCode:t}=e;return r._`{limit: ${t}}`}},code(e){const{keyword:t,data:n,schemaCode:a,it:o}=e,l="maxLength"===t?r.operators.GT:r.operators.LT,c=!1===o.opts.unicode?r._`${n}.length`:r._`${(0,i.useFunc)(e.gen,s.default)}(${n})`;e.fail$data(r._`${c} ${l} ${a}`)}};t.default=a},46189(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i=r.operators,s={maximum:{okStr:"<=",ok:i.LTE,fail:i.GT},minimum:{okStr:">=",ok:i.GTE,fail:i.LT},exclusiveMaximum:{okStr:"<",ok:i.LT,fail:i.GTE},exclusiveMinimum:{okStr:">",ok:i.GT,fail:i.LTE}},a={message:e=>{let{keyword:t,schemaCode:n}=e;return r.str`must be ${s[t].okStr} ${n}`},params:e=>{let{keyword:t,schemaCode:n}=e;return r._`{comparison: ${s[t].okStr}, limit: ${n}}`}},o={keyword:Object.keys(s),type:"number",schemaType:"number",$data:!0,error:a,code(e){const{keyword:t,data:n,schemaCode:i}=e;e.fail$data(r._`${n} ${s[t].fail} ${i} || isNaN(${n})`)}};t.default=o},25925(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message(e){let{keyword:t,schemaCode:n}=e;const i="maxProperties"===t?"more":"fewer";return r.str`must NOT have ${i} than ${n} properties`},params:e=>{let{schemaCode:t}=e;return r._`{limit: ${t}}`}},code(e){const{keyword:t,data:n,schemaCode:i}=e,s="maxProperties"===t?r.operators.GT:r.operators.LT;e.fail$data(r._`Object.keys(${n}).length ${s} ${i}`)}};t.default=i},65486(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(13578),i={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:e=>{let{schemaCode:t}=e;return r.str`must be multiple of ${t}`},params:e=>{let{schemaCode:t}=e;return r._`{multipleOf: ${t}}`}},code(e){const{gen:t,data:n,schemaCode:i,it:s}=e,a=s.opts.multipleOfPrecision,o=t.let("res"),l=a?r._`Math.abs(Math.round(${o}) - ${o}) > 1e-${a}`:r._`${o} !== parseInt(${o})`;e.fail$data(r._`(${i} === 0 || (${o} = ${n}/${i}, ${l}))`)}};t.default=i},5453(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(71762),i=n(14426),s=n(13578),a={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:e=>{let{schemaCode:t}=e;return s.str`must match pattern "${t}"`},params:e=>{let{schemaCode:t}=e;return s._`{pattern: ${t}}`}},code(e){const{gen:t,data:n,$data:a,schema:o,schemaCode:l,it:c}=e,h=c.opts.unicodeRegExp?"u":"";if(a){const{regExp:r}=c.opts.code,a="new RegExp"===r.code?s._`new RegExp`:(0,i.useFunc)(t,r),o=t.let("valid");t.try(()=>t.assign(o,s._`${a}(${l}, ${h}).test(${n})`),()=>t.assign(o,!1)),e.fail$data(s._`!${o}`)}else{const t=(0,r.usePattern)(e,o);e.fail$data(s._`!${t}.test(${n})`)}}};t.default=a},32858(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(71762),i=n(13578),s=n(14426),a={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:e=>{let{params:{missingProperty:t}}=e;return i.str`must have required property '${t}'`},params:e=>{let{params:{missingProperty:t}}=e;return i._`{missingProperty: ${t}}`}},code(e){const{gen:t,schema:n,schemaCode:a,data:o,$data:l,it:c}=e,{opts:h}=c;if(!l&&0===n.length)return;const d=n.length>=h.loopRequired;if(c.allErrors?function(){if(d||l)e.block$data(i.nil,u);else for(const t of n)(0,r.checkReportMissingProp)(e,t)}():function(){const s=t.let("missing");if(d||l){const n=t.let("valid",!0);e.block$data(n,()=>function(n,s){e.setParams({missingProperty:n}),t.forOf(n,a,()=>{t.assign(s,(0,r.propertyInData)(t,o,n,h.ownProperties)),t.if((0,i.not)(s),()=>{e.error(),t.break()})},i.nil)}(s,n)),e.ok(n)}else t.if((0,r.checkMissingProp)(e,n,s)),(0,r.reportMissingProp)(e,s),t.else()}(),h.strictRequired){const t=e.parentSchema.properties,{definedProperties:r}=e.it;for(const e of n)if(void 0===(null===t||void 0===t?void 0:t[e])&&!r.has(e)){const t=`required property "${e}" is not defined at "${c.schemaEnv.baseId+c.errSchemaPath}" (strictRequired)`;(0,s.checkStrictMode)(c,t,c.opts.strictRequired)}}function u(){t.forOf("prop",a,n=>{e.setParams({missingProperty:n}),t.if((0,r.noPropertyInData)(t,o,n,h.ownProperties),()=>e.error())})}}};t.default=a},48250(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(11915),i=n(13578),s=n(14426),a=n(59701),o={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:e=>{let{params:{i:t,j:n}}=e;return i.str`must NOT have duplicate items (items ## ${n} and ${t} are identical)`},params:e=>{let{params:{i:t,j:n}}=e;return i._`{i: ${t}, j: ${n}}`}},code(e){const{gen:t,data:n,$data:o,schema:l,parentSchema:c,schemaCode:h,it:d}=e;if(!o&&!l)return;const u=t.let("valid"),p=c.items?(0,r.getSchemaTypes)(c.items):[];function f(s,a){const o=t.name("item"),l=(0,r.checkDataTypes)(p,o,d.opts.strictNumbers,r.DataType.Wrong),c=t.const("indices",i._`{}`);t.for(i._`;${s}--;`,()=>{t.let(o,i._`${n}[${s}]`),t.if(l,i._`continue`),p.length>1&&t.if(i._`typeof ${o} == "string"`,i._`${o} += "_"`),t.if(i._`typeof ${c}[${o}] == "number"`,()=>{t.assign(a,i._`${c}[${o}]`),e.error(),t.assign(u,!1).break()}).code(i._`${c}[${o}] = ${s}`)})}function m(r,o){const l=(0,s.useFunc)(t,a.default),c=t.name("outer");t.label(c).for(i._`;${r}--;`,()=>t.for(i._`${o} = ${r}; ${o}--;`,()=>t.if(i._`${l}(${n}[${r}], ${n}[${o}])`,()=>{e.error(),t.assign(u,!1).break(c)})))}e.block$data(u,function(){const r=t.let("i",i._`${n}.length`),s=t.let("j");e.setParams({i:r,j:s}),t.assign(u,!0),t.if(i._`${r} > 1`,()=>(p.length>0&&!p.some(e=>"object"===e||"array"===e)?f:m)(r,s))},i._`${h} === false`),e.ok(u)}};t.default=o},23770(e,t){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.Doctype=t.CDATA=t.Tag=t.Style=t.Script=t.Comment=t.Directive=t.Text=t.Root=t.isTag=t.ElementType=void 0,function(e){e.Root="root",e.Text="text",e.Directive="directive",e.Comment="comment",e.Script="script",e.Style="style",e.Tag="tag",e.CDATA="cdata",e.Doctype="doctype"}(n=t.ElementType||(t.ElementType={})),t.isTag=function(e){return e.type===n.Tag||e.type===n.Script||e.type===n.Style},t.Root=n.Root,t.Text=n.Text,t.Directive=n.Directive,t.Comment=n.Comment,t.Script=n.Script,t.Style=n.Style,t.Tag=n.Tag,t.CDATA=n.CDATA,t.Doctype=n.Doctype},12754(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.DomHandler=void 0;var s=n(23770),a=n(30504);i(n(30504),t);var o={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},l=function(){function e(e,t,n){this.dom=[],this.root=new a.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,"function"===typeof t&&(n=t,t=o),"object"===typeof e&&(t=e,e=void 0),this.callback=null!==e&&void 0!==e?e:null,this.options=null!==t&&void 0!==t?t:o,this.elementCB=null!==n&&void 0!==n?n:null}return e.prototype.onparserinit=function(e){this.parser=e},e.prototype.onreset=function(){this.dom=[],this.root=new a.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null},e.prototype.onend=function(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))},e.prototype.onerror=function(e){this.handleCallback(e)},e.prototype.onclosetag=function(){this.lastNode=null;var e=this.tagStack.pop();this.options.withEndIndices&&(e.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(e)},e.prototype.onopentag=function(e,t){var n=this.options.xmlMode?s.ElementType.Tag:void 0,r=new a.Element(e,t,void 0,n);this.addNode(r),this.tagStack.push(r)},e.prototype.ontext=function(e){var t=this.lastNode;if(t&&t.type===s.ElementType.Text)t.data+=e,this.options.withEndIndices&&(t.endIndex=this.parser.endIndex);else{var n=new a.Text(e);this.addNode(n),this.lastNode=n}},e.prototype.oncomment=function(e){if(this.lastNode&&this.lastNode.type===s.ElementType.Comment)this.lastNode.data+=e;else{var t=new a.Comment(e);this.addNode(t),this.lastNode=t}},e.prototype.oncommentend=function(){this.lastNode=null},e.prototype.oncdatastart=function(){var e=new a.Text(""),t=new a.CDATA([e]);this.addNode(t),e.parent=t,this.lastNode=e},e.prototype.oncdataend=function(){this.lastNode=null},e.prototype.onprocessinginstruction=function(e,t){var n=new a.ProcessingInstruction(e,t);this.addNode(n)},e.prototype.handleCallback=function(e){if("function"===typeof this.callback)this.callback(e,this.dom);else if(e)throw e},e.prototype.addNode=function(e){var t=this.tagStack[this.tagStack.length-1],n=t.children[t.children.length-1];this.options.withStartIndices&&(e.startIndex=this.parser.startIndex),this.options.withEndIndices&&(e.endIndex=this.parser.endIndex),t.children.push(e),n&&(e.prev=n,n.next=e),e.parent=t,this.lastNode=null},e}();t.DomHandler=l,t.default=l},30504(e,t,n){"use strict";var r=this&&this.__extends||function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if("function"!==typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.cloneNode=t.hasChildren=t.isDocument=t.isDirective=t.isComment=t.isText=t.isCDATA=t.isTag=t.Element=t.Document=t.CDATA=t.NodeWithChildren=t.ProcessingInstruction=t.Comment=t.Text=t.DataNode=t.Node=void 0;var s=n(23770),a=function(){function e(){this.parent=null,this.prev=null,this.next=null,this.startIndex=null,this.endIndex=null}return Object.defineProperty(e.prototype,"parentNode",{get:function(){return this.parent},set:function(e){this.parent=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){return this.prev},set:function(e){this.prev=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){return this.next},set:function(e){this.next=e},enumerable:!1,configurable:!0}),e.prototype.cloneNode=function(e){return void 0===e&&(e=!1),_(this,e)},e}();t.Node=a;var o=function(e){function t(t){var n=e.call(this)||this;return n.data=t,n}return r(t,e),Object.defineProperty(t.prototype,"nodeValue",{get:function(){return this.data},set:function(e){this.data=e},enumerable:!1,configurable:!0}),t}(a);t.DataNode=o;var l=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=s.ElementType.Text,t}return r(t,e),Object.defineProperty(t.prototype,"nodeType",{get:function(){return 3},enumerable:!1,configurable:!0}),t}(o);t.Text=l;var c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=s.ElementType.Comment,t}return r(t,e),Object.defineProperty(t.prototype,"nodeType",{get:function(){return 8},enumerable:!1,configurable:!0}),t}(o);t.Comment=c;var h=function(e){function t(t,n){var r=e.call(this,n)||this;return r.name=t,r.type=s.ElementType.Directive,r}return r(t,e),Object.defineProperty(t.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),t}(o);t.ProcessingInstruction=h;var d=function(e){function t(t){var n=e.call(this)||this;return n.children=t,n}return r(t,e),Object.defineProperty(t.prototype,"firstChild",{get:function(){var e;return null!==(e=this.children[0])&&void 0!==e?e:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"lastChild",{get:function(){return this.children.length>0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"childNodes",{get:function(){return this.children},set:function(e){this.children=e},enumerable:!1,configurable:!0}),t}(a);t.NodeWithChildren=d;var u=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=s.ElementType.CDATA,t}return r(t,e),Object.defineProperty(t.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),t}(d);t.CDATA=u;var p=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=s.ElementType.Root,t}return r(t,e),Object.defineProperty(t.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),t}(d);t.Document=p;var f=function(e){function t(t,n,r,i){void 0===r&&(r=[]),void 0===i&&(i="script"===t?s.ElementType.Script:"style"===t?s.ElementType.Style:s.ElementType.Tag);var a=e.call(this,r)||this;return a.name=t,a.attribs=n,a.type=i,a}return r(t,e),Object.defineProperty(t.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tagName",{get:function(){return this.name},set:function(e){this.name=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"attributes",{get:function(){var e=this;return Object.keys(this.attribs).map(function(t){var n,r;return{name:t,value:e.attribs[t],namespace:null===(n=e["x-attribsNamespace"])||void 0===n?void 0:n[t],prefix:null===(r=e["x-attribsPrefix"])||void 0===r?void 0:r[t]}})},enumerable:!1,configurable:!0}),t}(d);function m(e){return(0,s.isTag)(e)}function g(e){return e.type===s.ElementType.CDATA}function v(e){return e.type===s.ElementType.Text}function y(e){return e.type===s.ElementType.Comment}function b(e){return e.type===s.ElementType.Directive}function w(e){return e.type===s.ElementType.Root}function _(e,t){var n;if(void 0===t&&(t=!1),v(e))n=new l(e.data);else if(y(e))n=new c(e.data);else if(m(e)){var r=t?A(e.children):[],s=new f(e.name,i({},e.attribs),r);r.forEach(function(e){return e.parent=s}),null!=e.namespace&&(s.namespace=e.namespace),e["x-attribsNamespace"]&&(s["x-attribsNamespace"]=i({},e["x-attribsNamespace"])),e["x-attribsPrefix"]&&(s["x-attribsPrefix"]=i({},e["x-attribsPrefix"])),n=s}else if(g(e)){r=t?A(e.children):[];var a=new u(r);r.forEach(function(e){return e.parent=a}),n=a}else if(w(e)){r=t?A(e.children):[];var o=new p(r);r.forEach(function(e){return e.parent=o}),e["x-mode"]&&(o["x-mode"]=e["x-mode"]),n=o}else{if(!b(e))throw new Error("Not implemented yet: ".concat(e.type));var d=new h(e.name,e.data);null!=e["x-name"]&&(d["x-name"]=e["x-name"],d["x-publicId"]=e["x-publicId"],d["x-systemId"]=e["x-systemId"]),n=d}return n.startIndex=e.startIndex,n.endIndex=e.endIndex,null!=e.sourceCodeLocation&&(n.sourceCodeLocation=e.sourceCodeLocation),n}function A(e){for(var t=e.map(function(e){return _(e,!0)}),n=1;n<t.length;n++)t[n].prev=t[n-1],t[n-1].next=t[n];return t}t.Element=f,t.isTag=m,t.isCDATA=g,t.isText=v,t.isComment=y,t.isDirective=b,t.isDocument=w,t.hasChildren=function(e){return Object.prototype.hasOwnProperty.call(e,"children")},t.cloneNode=_},83080(e){"use strict";e.exports=function e(t,n){if(t===n)return!0;if(t&&n&&"object"==typeof t&&"object"==typeof n){if(t.constructor!==n.constructor)return!1;var r,i,s;if(Array.isArray(t)){if((r=t.length)!=n.length)return!1;for(i=r;0!==i--;)if(!e(t[i],n[i]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if((r=(s=Object.keys(t)).length)!==Object.keys(n).length)return!1;for(i=r;0!==i--;)if(!Object.prototype.hasOwnProperty.call(n,s[i]))return!1;for(i=r;0!==i--;){var a=s[i];if(!e(t[a],n[a]))return!1}return!0}return t!==t&&n!==n}},18261(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CARRIAGE_RETURN_PLACEHOLDER_REGEX=t.CARRIAGE_RETURN_PLACEHOLDER=t.CARRIAGE_RETURN_REGEX=t.CARRIAGE_RETURN=t.CASE_SENSITIVE_TAG_NAMES_MAP=t.CASE_SENSITIVE_TAG_NAMES=void 0,t.CASE_SENSITIVE_TAG_NAMES=["animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","linearGradient","radialGradient","textPath"],t.CASE_SENSITIVE_TAG_NAMES_MAP=t.CASE_SENSITIVE_TAG_NAMES.reduce(function(e,t){return e[t.toLowerCase()]=t,e},{}),t.CARRIAGE_RETURN="\r",t.CARRIAGE_RETURN_REGEX=new RegExp(t.CARRIAGE_RETURN,"g"),t.CARRIAGE_RETURN_PLACEHOLDER="__HTML_DOM_PARSER_CARRIAGE_RETURN_PLACEHOLDER_".concat(Date.now().toString(),"__"),t.CARRIAGE_RETURN_PLACEHOLDER_REGEX=new RegExp(t.CARRIAGE_RETURN_PLACEHOLDER,"g")},71123(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t,n,h,d,u,f;e=(0,r.escapeSpecialCharacters)(e);var g=o.exec(e),v=null===(t=null===g||void 0===g?void 0:g[1])||void 0===t?void 0:t.toLowerCase();switch(v){case i:var y=c(e);if(!(0,r.hasOpenTag)(e,s))null===(n=null===(w=y.querySelector(s))||void 0===w?void 0:w.parentNode)||void 0===n||n.removeChild(w);if(!(0,r.hasOpenTag)(e,a))null===(h=null===(w=y.querySelector(a))||void 0===w?void 0:w.parentNode)||void 0===h||h.removeChild(w);return y.querySelectorAll(i);case s:case a:var b=l(e).querySelectorAll(v);return(0,r.hasOpenTag)(e,a)&&(0,r.hasOpenTag)(e,s)?null!==(u=null===(d=b[0].parentNode)||void 0===d?void 0:d.childNodes)&&void 0!==u?u:m():b;default:return p?p(e):null!==(f=null===(w=l(e,a).querySelector(a))||void 0===w?void 0:w.childNodes)&&void 0!==f?f:m();var w}};var r=n(40116),i="html",s="head",a="body",o=/<([a-zA-Z]+[0-9]?)/,l=function(e,t){throw new Error("This browser does not support `document.implementation.createHTMLDocument`")},c=function(e,t){throw new Error("This browser does not support `DOMParser.prototype.parseFromString`")},h="object"===typeof window&&window.DOMParser;if("function"===typeof h){var d=new h;l=c=function(e,t){return t&&(e="<".concat(t,">").concat(e,"</").concat(t,">")),d.parseFromString(e,"text/html")}}if("object"===typeof document&&document.implementation){var u=document.implementation.createHTMLDocument();l=function(e,t){if(t){var n=u.documentElement.querySelector(t);return n&&(n.innerHTML=e),u}return u.documentElement.innerHTML=e,u}}var p,f="object"===typeof document&&document.createElement("template");f&&f.content&&(p=function(e){return f.innerHTML=e,f.content.childNodes});var m=function(){return document.createDocumentFragment().childNodes}},80256(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if("string"!==typeof e)throw new TypeError("First argument must be a string");if(!e)return[];var t=a.exec(e),n=t?t[1]:void 0;return(0,s.formatDOM)((0,i.default)(e),null,n)};var i=r(n(71123)),s=n(40116),a=/<(![a-zA-Z\s]+)>/},40116(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatAttributes=s,t.hasOpenTag=function(e,t){var n="<"+t,r=e.toLowerCase().indexOf(n);if(-1===r)return!1;var i=e[r+n.length];return">"===i||" "===i||"\t"===i||"\n"===i||"\r"===i||"/"===i},t.escapeSpecialCharacters=function(e){return e.replace(i.CARRIAGE_RETURN_REGEX,i.CARRIAGE_RETURN_PLACEHOLDER)},t.revertEscapedCharacters=o,t.formatDOM=function e(t,n,i){var l,c,h,d;void 0===n&&(n=null);for(var u,p=[],f=0,m=t.length;f<m;f++){var g=t[f];switch(g.nodeType){case 1:var v=a(g.nodeName);(u=new r.Element(v,s(g.attributes))).children=e("template"===v?g.content.childNodes:g.childNodes,u);break;case 3:u=new r.Text(o(null!==(l=g.nodeValue)&&void 0!==l?l:""));break;case 8:u=new r.Comment(null!==(c=g.nodeValue)&&void 0!==c?c:"");break;default:continue}var y=null!==(h=p[f-1])&&void 0!==h?h:null;y&&(y.next=u),u.parent=n,u.prev=y,u.next=null,p.push(u)}i&&((u=new r.ProcessingInstruction(i.substring(0,i.indexOf(" ")).toLowerCase(),i)).next=null!==(d=p[0])&&void 0!==d?d:null,u.parent=n,p.unshift(u),p[1]&&(p[1].prev=p[0]));return p};var r=n(12754),i=n(18261);function s(e){for(var t={},n=0,r=e.length;n<r;n++){var i=e[n];t[i.name]=i.value}return t}function a(e){var t=function(e){return i.CASE_SENSITIVE_TAG_NAMES_MAP[e]}(e=e.toLowerCase());return t||e}function o(e){return e.replace(i.CARRIAGE_RETURN_PLACEHOLDER_REGEX,i.CARRIAGE_RETURN)}},1185(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){void 0===e&&(e={});var n={},c=Boolean(e.type&&o[e.type]);for(var h in e){var d=e[h];if((0,r.isCustomAttribute)(h))n[h]=d;else{var u=h.toLowerCase(),p=l(u);if(p){var f=(0,r.getPropertyInfo)(p);switch(s.includes(p)&&a.includes(t)&&!c&&(p=l("default"+u)),n[p]=d,null===f||void 0===f?void 0:f.type){case r.BOOLEAN:n[p]=!0;break;case r.OVERLOADED_BOOLEAN:""===d&&(n[p]=!0)}}else i.PRESERVE_CUSTOM_ATTRIBUTES&&(n[h]=d)}}return(0,i.setStyleProp)(e.style,n),n};var r=n(76837),i=n(76915),s=["checked","value"],a=["input","select","textarea"],o={reset:!0,submit:!0};function l(e){return r.possibleStandardNames[e]}},98847(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t,n){var r,i,c,h,d;void 0===n&&(n={});for(var u=[],p="function"===typeof n.replace,f=null!==(r=n.transform)&&void 0!==r?r:a.returnFirstArg,m=null!==(i=n.library)&&void 0!==i?i:o,g=m.cloneElement,v=m.createElement,y=m.isValidElement,b=t.length,w=0;w<b;w++){var _=t[w];if(p){var A=null===(c=n.replace)||void 0===c?void 0:c.call(n,_,w);if(y(A)){b>1&&(A=g(A,{key:null!==(h=A.key)&&void 0!==h?h:w})),u.push(f(A,_,w));continue}}if("text"!==_.type){var x=_,E={};l(x)?((0,a.setStyleProp)(x.attribs.style,x.attribs),E=x.attribs):x.attribs&&(E=(0,s.default)(x.attribs,x.name));var C=void 0;switch(_.type){case"script":case"style":_.children[0]&&(E.dangerouslySetInnerHTML={__html:_.children[0].data});break;case"tag":"textarea"===_.name&&_.children[0]?E.defaultValue=_.children[0].data:(null===(d=_.children)||void 0===d?void 0:d.length)&&(C=e(_.children,n));break;default:continue}b>1&&(E.key=w),u.push(f(v(_.name,E,C),_,w))}else{var k=!_.data.trim().length;if(k&&_.parent&&!(0,a.canTextBeChildOfNode)(_.parent))continue;if(n.trim&&k)continue;u.push(f(_.data,_,w))}}return 1===u.length?u[0]:u};var i=n(94922),s=r(n(1185)),a=n(76915),o={cloneElement:i.cloneElement,createElement:i.createElement,isValidElement:i.isValidElement};function l(e){return a.PRESERVE_CUSTOM_ATTRIBUTES&&"tag"===e.type&&(0,a.isCustomComponent)(e.name,e.attribs)}},59107(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.htmlToDOM=t.domToReact=t.attributesToProps=t.Text=t.ProcessingInstruction=t.Element=t.Comment=void 0,t.default=function(e,t){var n;if("string"!==typeof e)throw new TypeError("First argument must be a string");if(!e)return[];return(0,a.default)((0,i.default)(e,null!==(n=null===t||void 0===t?void 0:t.htmlparser2)&&void 0!==n?n:l),t)};var i=r(n(80256));t.htmlToDOM=i.default;var s=r(n(1185));t.attributesToProps=s.default;var a=r(n(98847));t.domToReact=a.default;var o=n(12754);Object.defineProperty(t,"Comment",{enumerable:!0,get:function(){return o.Comment}}),Object.defineProperty(t,"Element",{enumerable:!0,get:function(){return o.Element}}),Object.defineProperty(t,"ProcessingInstruction",{enumerable:!0,get:function(){return o.ProcessingInstruction}}),Object.defineProperty(t,"Text",{enumerable:!0,get:function(){return o.Text}});var l={lowerCaseAttributeNames:!1}},76915(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.returnFirstArg=t.canTextBeChildOfNode=t.ELEMENTS_WITH_NO_TEXT_CHILDREN=t.PRESERVE_CUSTOM_ATTRIBUTES=void 0,t.isCustomComponent=function(e,t){if(!e.includes("-"))return Boolean(t&&"string"===typeof t.is);if(a.has(e))return!1;return!0},t.setStyleProp=function(e,t){if("string"!==typeof e)return;if(!e.trim())return void(t.style={});try{t.style=(0,s.default)(e,o)}catch(n){t.style={}}};var i=n(94922),s=r(n(71148)),a=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);var o={reactCompat:!0};t.PRESERVE_CUSTOM_ATTRIBUTES=Number(i.version.split(".")[0])>=16,t.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);t.canTextBeChildOfNode=function(e){return!t.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(e.name)};t.returnFirstArg=function(e){return e}},52808(e){"use strict";var t=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,n=/\n/g,r=/^\s*/,i=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,s=/^:\s*/,a=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,o=/^[;\s]*/,l=/^\s+|\s+$/g,c="";function h(e){return e?e.replace(l,c):c}e.exports=function(e,l){if("string"!==typeof e)throw new TypeError("First argument must be a string");if(!e)return[];l=l||{};var d=1,u=1;function p(e){var t=e.match(n);t&&(d+=t.length);var r=e.lastIndexOf("\n");u=~r?e.length-r:u+e.length}function f(){var e={line:d,column:u};return function(t){return t.position=new m(e),y(),t}}function m(e){this.start=e,this.end={line:d,column:u},this.source=l.source}function g(t){var n=new Error(l.source+":"+d+":"+u+": "+t);if(n.reason=t,n.filename=l.source,n.line=d,n.column=u,n.source=e,!l.silent)throw n}function v(t){var n=t.exec(e);if(n){var r=n[0];return p(r),e=e.slice(r.length),n}}function y(){v(r)}function b(e){var t;for(e=e||[];t=w();)!1!==t&&e.push(t);return e}function w(){var t=f();if("/"==e.charAt(0)&&"*"==e.charAt(1)){for(var n=2;c!=e.charAt(n)&&("*"!=e.charAt(n)||"/"!=e.charAt(n+1));)++n;if(n+=2,c===e.charAt(n-1))return g("End of comment missing");var r=e.slice(2,n-2);return u+=2,p(r),e=e.slice(n),u+=2,t({type:"comment",comment:r})}}function _(){var e=f(),n=v(i);if(n){if(w(),!v(s))return g("property missing ':'");var r=v(a),l=e({type:"declaration",property:h(n[0].replace(t,c)),value:r?h(r[0].replace(t,c)):c});return v(o),l}}return m.prototype.content=e,y(),function(){var e,t=[];for(b(t);e=_();)!1!==e&&(t.push(e),b(t));return t}()}},69453(e){"use strict";var t=e.exports=function(e,t,r){"function"==typeof t&&(r=t,t={}),n(t,"function"==typeof(r=t.cb||r)?r:r.pre||function(){},r.post||function(){},e,"",e)};function n(e,i,s,a,o,l,c,h,d,u){if(a&&"object"==typeof a&&!Array.isArray(a)){for(var p in i(a,o,l,c,h,d,u),a){var f=a[p];if(Array.isArray(f)){if(p in t.arrayKeywords)for(var m=0;m<f.length;m++)n(e,i,s,f[m],o+"/"+p+"/"+m,l,o,p,a,m)}else if(p in t.propsKeywords){if(f&&"object"==typeof f)for(var g in f)n(e,i,s,f[g],o+"/"+p+"/"+r(g),l,o,p,a,g)}else(p in t.keywords||e.allKeys&&!(p in t.skipKeywords))&&n(e,i,s,f,o+"/"+p,l,o,p,a)}s(a,o,l,c,h,d,u)}}function r(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}t.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0},t.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},t.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},t.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0}},81261(e){e.exports=function e(t,n,r){function i(a,o){if(!n[a]){if(!t[a]){if(s)return s(a,!0);var l=new Error("Cannot find module '"+a+"'");throw l.code="MODULE_NOT_FOUND",l}var c=n[a]={exports:{}};t[a][0].call(c.exports,function(e){return i(t[a][1][e]||e)},c,c.exports,e,t,n,r)}return n[a].exports}for(var s=void 0,a=0;a<r.length;a++)i(r[a]);return i}({1:[function(e,t,n){"use strict";var r=e("./utils"),i=e("./support"),s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";n.encode=function(e){for(var t,n,i,a,o,l,c,h=[],d=0,u=e.length,p=u,f="string"!==r.getTypeOf(e);d<e.length;)p=u-d,i=f?(t=e[d++],n=d<u?e[d++]:0,d<u?e[d++]:0):(t=e.charCodeAt(d++),n=d<u?e.charCodeAt(d++):0,d<u?e.charCodeAt(d++):0),a=t>>2,o=(3&t)<<4|n>>4,l=1<p?(15&n)<<2|i>>6:64,c=2<p?63&i:64,h.push(s.charAt(a)+s.charAt(o)+s.charAt(l)+s.charAt(c));return h.join("")},n.decode=function(e){var t,n,r,a,o,l,c=0,h=0,d="data:";if(e.substr(0,d.length)===d)throw new Error("Invalid base64 input, it looks like a data url.");var u,p=3*(e=e.replace(/[^A-Za-z0-9+/=]/g,"")).length/4;if(e.charAt(e.length-1)===s.charAt(64)&&p--,e.charAt(e.length-2)===s.charAt(64)&&p--,p%1!=0)throw new Error("Invalid base64 input, bad content length.");for(u=i.uint8array?new Uint8Array(0|p):new Array(0|p);c<e.length;)t=s.indexOf(e.charAt(c++))<<2|(a=s.indexOf(e.charAt(c++)))>>4,n=(15&a)<<4|(o=s.indexOf(e.charAt(c++)))>>2,r=(3&o)<<6|(l=s.indexOf(e.charAt(c++))),u[h++]=t,64!==o&&(u[h++]=n),64!==l&&(u[h++]=r);return u}},{"./support":30,"./utils":32}],2:[function(e,t,n){"use strict";var r=e("./external"),i=e("./stream/DataWorker"),s=e("./stream/Crc32Probe"),a=e("./stream/DataLengthProbe");function o(e,t,n,r,i){this.compressedSize=e,this.uncompressedSize=t,this.crc32=n,this.compression=r,this.compressedContent=i}o.prototype={getContentWorker:function(){var e=new i(r.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new a("data_length")),t=this;return e.on("end",function(){if(this.streamInfo.data_length!==t.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),e},getCompressedWorker:function(){return new i(r.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},o.createWorkerFrom=function(e,t,n){return e.pipe(new s).pipe(new a("uncompressedSize")).pipe(t.compressWorker(n)).pipe(new a("compressedSize")).withStreamInfo("compression",t)},t.exports=o},{"./external":6,"./stream/Crc32Probe":25,"./stream/DataLengthProbe":26,"./stream/DataWorker":27}],3:[function(e,t,n){"use strict";var r=e("./stream/GenericWorker");n.STORE={magic:"\0\0",compressWorker:function(){return new r("STORE compression")},uncompressWorker:function(){return new r("STORE decompression")}},n.DEFLATE=e("./flate")},{"./flate":7,"./stream/GenericWorker":28}],4:[function(e,t,n){"use strict";var r=e("./utils"),i=function(){for(var e,t=[],n=0;n<256;n++){e=n;for(var r=0;r<8;r++)e=1&e?3988292384^e>>>1:e>>>1;t[n]=e}return t}();t.exports=function(e,t){return void 0!==e&&e.length?"string"!==r.getTypeOf(e)?function(e,t,n,r){var s=i,a=r+n;e^=-1;for(var o=r;o<a;o++)e=e>>>8^s[255&(e^t[o])];return-1^e}(0|t,e,e.length,0):function(e,t,n,r){var s=i,a=r+n;e^=-1;for(var o=r;o<a;o++)e=e>>>8^s[255&(e^t.charCodeAt(o))];return-1^e}(0|t,e,e.length,0):0}},{"./utils":32}],5:[function(e,t,n){"use strict";n.base64=!1,n.binary=!1,n.dir=!1,n.createFolders=!0,n.date=null,n.compression=null,n.compressionOptions=null,n.comment=null,n.unixPermissions=null,n.dosPermissions=null},{}],6:[function(e,t,n){"use strict";var r=null;r="undefined"!=typeof Promise?Promise:e("lie"),t.exports={Promise:r}},{lie:37}],7:[function(e,t,n){"use strict";var r="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array,i=e("pako"),s=e("./utils"),a=e("./stream/GenericWorker"),o=r?"uint8array":"array";function l(e,t){a.call(this,"FlateWorker/"+e),this._pako=null,this._pakoAction=e,this._pakoOptions=t,this.meta={}}n.magic="\b\0",s.inherits(l,a),l.prototype.processChunk=function(e){this.meta=e.meta,null===this._pako&&this._createPako(),this._pako.push(s.transformTo(o,e.data),!1)},l.prototype.flush=function(){a.prototype.flush.call(this),null===this._pako&&this._createPako(),this._pako.push([],!0)},l.prototype.cleanUp=function(){a.prototype.cleanUp.call(this),this._pako=null},l.prototype._createPako=function(){this._pako=new i[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var e=this;this._pako.onData=function(t){e.push({data:t,meta:e.meta})}},n.compressWorker=function(e){return new l("Deflate",e)},n.uncompressWorker=function(){return new l("Inflate",{})}},{"./stream/GenericWorker":28,"./utils":32,pako:38}],8:[function(e,t,n){"use strict";function r(e,t){var n,r="";for(n=0;n<t;n++)r+=String.fromCharCode(255&e),e>>>=8;return r}function i(e,t,n,i,a,h){var d,u,p=e.file,f=e.compression,m=h!==o.utf8encode,g=s.transformTo("string",h(p.name)),v=s.transformTo("string",o.utf8encode(p.name)),y=p.comment,b=s.transformTo("string",h(y)),w=s.transformTo("string",o.utf8encode(y)),_=v.length!==p.name.length,A=w.length!==y.length,x="",E="",C="",k=p.dir,S=p.date,T={crc32:0,compressedSize:0,uncompressedSize:0};t&&!n||(T.crc32=e.crc32,T.compressedSize=e.compressedSize,T.uncompressedSize=e.uncompressedSize);var D=0;t&&(D|=8),m||!_&&!A||(D|=2048);var M=0,P=0;k&&(M|=16),"UNIX"===a?(P=798,M|=function(e,t){var n=e;return e||(n=t?16893:33204),(65535&n)<<16}(p.unixPermissions,k)):(P=20,M|=function(e){return 63&(e||0)}(p.dosPermissions)),d=S.getUTCHours(),d<<=6,d|=S.getUTCMinutes(),d<<=5,d|=S.getUTCSeconds()/2,u=S.getUTCFullYear()-1980,u<<=4,u|=S.getUTCMonth()+1,u<<=5,u|=S.getUTCDate(),_&&(E=r(1,1)+r(l(g),4)+v,x+="up"+r(E.length,2)+E),A&&(C=r(1,1)+r(l(b),4)+w,x+="uc"+r(C.length,2)+C);var I="";return I+="\n\0",I+=r(D,2),I+=f.magic,I+=r(d,2),I+=r(u,2),I+=r(T.crc32,4),I+=r(T.compressedSize,4),I+=r(T.uncompressedSize,4),I+=r(g.length,2),I+=r(x.length,2),{fileRecord:c.LOCAL_FILE_HEADER+I+g+x,dirRecord:c.CENTRAL_FILE_HEADER+r(P,2)+I+r(b.length,2)+"\0\0\0\0"+r(M,4)+r(i,4)+g+x+b}}var s=e("../utils"),a=e("../stream/GenericWorker"),o=e("../utf8"),l=e("../crc32"),c=e("../signature");function h(e,t,n,r){a.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=t,this.zipPlatform=n,this.encodeFileName=r,this.streamFiles=e,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}s.inherits(h,a),h.prototype.push=function(e){var t=e.meta.percent||0,n=this.entriesCount,r=this._sources.length;this.accumulate?this.contentBuffer.push(e):(this.bytesWritten+=e.data.length,a.prototype.push.call(this,{data:e.data,meta:{currentFile:this.currentFile,percent:n?(t+100*(n-r-1))/n:100}}))},h.prototype.openedSource=function(e){this.currentSourceOffset=this.bytesWritten,this.currentFile=e.file.name;var t=this.streamFiles&&!e.file.dir;if(t){var n=i(e,t,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:n.fileRecord,meta:{percent:0}})}else this.accumulate=!0},h.prototype.closedSource=function(e){this.accumulate=!1;var t=this.streamFiles&&!e.file.dir,n=i(e,t,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(n.dirRecord),t)this.push({data:function(e){return c.DATA_DESCRIPTOR+r(e.crc32,4)+r(e.compressedSize,4)+r(e.uncompressedSize,4)}(e),meta:{percent:100}});else for(this.push({data:n.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},h.prototype.flush=function(){for(var e=this.bytesWritten,t=0;t<this.dirRecords.length;t++)this.push({data:this.dirRecords[t],meta:{percent:100}});var n=this.bytesWritten-e,i=function(e,t,n,i,a){var o=s.transformTo("string",a(i));return c.CENTRAL_DIRECTORY_END+"\0\0\0\0"+r(e,2)+r(e,2)+r(t,4)+r(n,4)+r(o.length,2)+o}(this.dirRecords.length,n,e,this.zipComment,this.encodeFileName);this.push({data:i,meta:{percent:100}})},h.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},h.prototype.registerPrevious=function(e){this._sources.push(e);var t=this;return e.on("data",function(e){t.processChunk(e)}),e.on("end",function(){t.closedSource(t.previous.streamInfo),t._sources.length?t.prepareNextSource():t.end()}),e.on("error",function(e){t.error(e)}),this},h.prototype.resume=function(){return!!a.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},h.prototype.error=function(e){var t=this._sources;if(!a.prototype.error.call(this,e))return!1;for(var n=0;n<t.length;n++)try{t[n].error(e)}catch(e){}return!0},h.prototype.lock=function(){a.prototype.lock.call(this);for(var e=this._sources,t=0;t<e.length;t++)e[t].lock()},t.exports=h},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(e,t,n){"use strict";var r=e("../compressions"),i=e("./ZipFileWorker");n.generateWorker=function(e,t,n){var s=new i(t.streamFiles,n,t.platform,t.encodeFileName),a=0;try{e.forEach(function(e,n){a++;var i=function(e,t){var n=e||t,i=r[n];if(!i)throw new Error(n+" is not a valid compression method !");return i}(n.options.compression,t.compression),o=n.options.compressionOptions||t.compressionOptions||{},l=n.dir,c=n.date;n._compressWorker(i,o).withStreamInfo("file",{name:e,dir:l,date:c,comment:n.comment||"",unixPermissions:n.unixPermissions,dosPermissions:n.dosPermissions}).pipe(s)}),s.entriesCount=a}catch(e){s.error(e)}return s}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(e,t,n){"use strict";function r(){if(!(this instanceof r))return new r;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var e=new r;for(var t in this)"function"!=typeof this[t]&&(e[t]=this[t]);return e}}(r.prototype=e("./object")).loadAsync=e("./load"),r.support=e("./support"),r.defaults=e("./defaults"),r.version="3.10.1",r.loadAsync=function(e,t){return(new r).loadAsync(e,t)},r.external=e("./external"),t.exports=r},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(e,t,n){"use strict";var r=e("./utils"),i=e("./external"),s=e("./utf8"),a=e("./zipEntries"),o=e("./stream/Crc32Probe"),l=e("./nodejsUtils");function c(e){return new i.Promise(function(t,n){var r=e.decompressed.getContentWorker().pipe(new o);r.on("error",function(e){n(e)}).on("end",function(){r.streamInfo.crc32!==e.decompressed.crc32?n(new Error("Corrupted zip : CRC32 mismatch")):t()}).resume()})}t.exports=function(e,t){var n=this;return t=r.extend(t||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:s.utf8decode}),l.isNode&&l.isStream(e)?i.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):r.prepareContent("the loaded zip file",e,!0,t.optimizedBinaryString,t.base64).then(function(e){var n=new a(t);return n.load(e),n}).then(function(e){var n=[i.Promise.resolve(e)],r=e.files;if(t.checkCRC32)for(var s=0;s<r.length;s++)n.push(c(r[s]));return i.Promise.all(n)}).then(function(e){for(var i=e.shift(),s=i.files,a=0;a<s.length;a++){var o=s[a],l=o.fileNameStr,c=r.resolve(o.fileNameStr);n.file(c,o.decompressed,{binary:!0,optimizedBinaryString:!0,date:o.date,dir:o.dir,comment:o.fileCommentStr.length?o.fileCommentStr:null,unixPermissions:o.unixPermissions,dosPermissions:o.dosPermissions,createFolders:t.createFolders}),o.dir||(n.file(c).unsafeOriginalName=l)}return i.zipComment.length&&(n.comment=i.zipComment),n})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(e,t,n){"use strict";var r=e("../utils"),i=e("../stream/GenericWorker");function s(e,t){i.call(this,"Nodejs stream input adapter for "+e),this._upstreamEnded=!1,this._bindStream(t)}r.inherits(s,i),s.prototype._bindStream=function(e){var t=this;(this._stream=e).pause(),e.on("data",function(e){t.push({data:e,meta:{percent:0}})}).on("error",function(e){t.isPaused?this.generatedError=e:t.error(e)}).on("end",function(){t.isPaused?t._upstreamEnded=!0:t.end()})},s.prototype.pause=function(){return!!i.prototype.pause.call(this)&&(this._stream.pause(),!0)},s.prototype.resume=function(){return!!i.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)},t.exports=s},{"../stream/GenericWorker":28,"../utils":32}],13:[function(e,t,n){"use strict";var r=e("readable-stream").Readable;function i(e,t,n){r.call(this,t),this._helper=e;var i=this;e.on("data",function(e,t){i.push(e)||i._helper.pause(),n&&n(t)}).on("error",function(e){i.emit("error",e)}).on("end",function(){i.push(null)})}e("../utils").inherits(i,r),i.prototype._read=function(){this._helper.resume()},t.exports=i},{"../utils":32,"readable-stream":16}],14:[function(e,t,n){"use strict";t.exports={isNode:"undefined"!=typeof Buffer,newBufferFrom:function(e,t){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(e,t);if("number"==typeof e)throw new Error('The "data" argument must not be a number');return new Buffer(e,t)},allocBuffer:function(e){if(Buffer.alloc)return Buffer.alloc(e);var t=new Buffer(e);return t.fill(0),t},isBuffer:function(e){return Buffer.isBuffer(e)},isStream:function(e){return e&&"function"==typeof e.on&&"function"==typeof e.pause&&"function"==typeof e.resume}}},{}],15:[function(e,t,n){"use strict";function r(e,t,n){var r,i=s.getTypeOf(t),o=s.extend(n||{},l);o.date=o.date||new Date,null!==o.compression&&(o.compression=o.compression.toUpperCase()),"string"==typeof o.unixPermissions&&(o.unixPermissions=parseInt(o.unixPermissions,8)),o.unixPermissions&&16384&o.unixPermissions&&(o.dir=!0),o.dosPermissions&&16&o.dosPermissions&&(o.dir=!0),o.dir&&(e=m(e)),o.createFolders&&(r=f(e))&&g.call(this,r,!0);var d="string"===i&&!1===o.binary&&!1===o.base64;n&&void 0!==n.binary||(o.binary=!d),(t instanceof c&&0===t.uncompressedSize||o.dir||!t||0===t.length)&&(o.base64=!1,o.binary=!0,t="",o.compression="STORE",i="string");var v=null;v=t instanceof c||t instanceof a?t:u.isNode&&u.isStream(t)?new p(e,t):s.prepareContent(e,t,o.binary,o.optimizedBinaryString,o.base64);var y=new h(e,v,o);this.files[e]=y}var i=e("./utf8"),s=e("./utils"),a=e("./stream/GenericWorker"),o=e("./stream/StreamHelper"),l=e("./defaults"),c=e("./compressedObject"),h=e("./zipObject"),d=e("./generate"),u=e("./nodejsUtils"),p=e("./nodejs/NodejsStreamInputAdapter"),f=function(e){"/"===e.slice(-1)&&(e=e.substring(0,e.length-1));var t=e.lastIndexOf("/");return 0<t?e.substring(0,t):""},m=function(e){return"/"!==e.slice(-1)&&(e+="/"),e},g=function(e,t){return t=void 0!==t?t:l.createFolders,e=m(e),this.files[e]||r.call(this,e,null,{dir:!0,createFolders:t}),this.files[e]};function v(e){return"[object RegExp]"===Object.prototype.toString.call(e)}var y={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(e){var t,n,r;for(t in this.files)r=this.files[t],(n=t.slice(this.root.length,t.length))&&t.slice(0,this.root.length)===this.root&&e(n,r)},filter:function(e){var t=[];return this.forEach(function(n,r){e(n,r)&&t.push(r)}),t},file:function(e,t,n){if(1!==arguments.length)return e=this.root+e,r.call(this,e,t,n),this;if(v(e)){var i=e;return this.filter(function(e,t){return!t.dir&&i.test(e)})}var s=this.files[this.root+e];return s&&!s.dir?s:null},folder:function(e){if(!e)return this;if(v(e))return this.filter(function(t,n){return n.dir&&e.test(t)});var t=this.root+e,n=g.call(this,t),r=this.clone();return r.root=n.name,r},remove:function(e){e=this.root+e;var t=this.files[e];if(t||("/"!==e.slice(-1)&&(e+="/"),t=this.files[e]),t&&!t.dir)delete this.files[e];else for(var n=this.filter(function(t,n){return n.name.slice(0,e.length)===e}),r=0;r<n.length;r++)delete this.files[n[r].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(e){var t,n={};try{if((n=s.extend(e||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:i.utf8encode})).type=n.type.toLowerCase(),n.compression=n.compression.toUpperCase(),"binarystring"===n.type&&(n.type="string"),!n.type)throw new Error("No output type specified.");s.checkSupport(n.type),"darwin"!==n.platform&&"freebsd"!==n.platform&&"linux"!==n.platform&&"sunos"!==n.platform||(n.platform="UNIX"),"win32"===n.platform&&(n.platform="DOS");var r=n.comment||this.comment||"";t=d.generateWorker(this,n,r)}catch(e){(t=new a("error")).error(e)}return new o(t,n.type||"string",n.mimeType)},generateAsync:function(e,t){return this.generateInternalStream(e).accumulate(t)},generateNodeStream:function(e,t){return(e=e||{}).type||(e.type="nodebuffer"),this.generateInternalStream(e).toNodejsStream(t)}};t.exports=y},{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(e,t,n){"use strict";t.exports=e("stream")},{stream:void 0}],17:[function(e,t,n){"use strict";var r=e("./DataReader");function i(e){r.call(this,e);for(var t=0;t<this.data.length;t++)e[t]=255&e[t]}e("../utils").inherits(i,r),i.prototype.byteAt=function(e){return this.data[this.zero+e]},i.prototype.lastIndexOfSignature=function(e){for(var t=e.charCodeAt(0),n=e.charCodeAt(1),r=e.charCodeAt(2),i=e.charCodeAt(3),s=this.length-4;0<=s;--s)if(this.data[s]===t&&this.data[s+1]===n&&this.data[s+2]===r&&this.data[s+3]===i)return s-this.zero;return-1},i.prototype.readAndCheckSignature=function(e){var t=e.charCodeAt(0),n=e.charCodeAt(1),r=e.charCodeAt(2),i=e.charCodeAt(3),s=this.readData(4);return t===s[0]&&n===s[1]&&r===s[2]&&i===s[3]},i.prototype.readData=function(e){if(this.checkOffset(e),0===e)return[];var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=i},{"../utils":32,"./DataReader":18}],18:[function(e,t,n){"use strict";var r=e("../utils");function i(e){this.data=e,this.length=e.length,this.index=0,this.zero=0}i.prototype={checkOffset:function(e){this.checkIndex(this.index+e)},checkIndex:function(e){if(this.length<this.zero+e||e<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+e+"). Corrupted zip ?")},setIndex:function(e){this.checkIndex(e),this.index=e},skip:function(e){this.setIndex(this.index+e)},byteAt:function(){},readInt:function(e){var t,n=0;for(this.checkOffset(e),t=this.index+e-1;t>=this.index;t--)n=(n<<8)+this.byteAt(t);return this.index+=e,n},readString:function(e){return r.transformTo("string",this.readData(e))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var e=this.readInt(4);return new Date(Date.UTC(1980+(e>>25&127),(e>>21&15)-1,e>>16&31,e>>11&31,e>>5&63,(31&e)<<1))}},t.exports=i},{"../utils":32}],19:[function(e,t,n){"use strict";var r=e("./Uint8ArrayReader");function i(e){r.call(this,e)}e("../utils").inherits(i,r),i.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=i},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(e,t,n){"use strict";var r=e("./DataReader");function i(e){r.call(this,e)}e("../utils").inherits(i,r),i.prototype.byteAt=function(e){return this.data.charCodeAt(this.zero+e)},i.prototype.lastIndexOfSignature=function(e){return this.data.lastIndexOf(e)-this.zero},i.prototype.readAndCheckSignature=function(e){return e===this.readData(4)},i.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=i},{"../utils":32,"./DataReader":18}],21:[function(e,t,n){"use strict";var r=e("./ArrayReader");function i(e){r.call(this,e)}e("../utils").inherits(i,r),i.prototype.readData=function(e){if(this.checkOffset(e),0===e)return new Uint8Array(0);var t=this.data.subarray(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=i},{"../utils":32,"./ArrayReader":17}],22:[function(e,t,n){"use strict";var r=e("../utils"),i=e("../support"),s=e("./ArrayReader"),a=e("./StringReader"),o=e("./NodeBufferReader"),l=e("./Uint8ArrayReader");t.exports=function(e){var t=r.getTypeOf(e);return r.checkSupport(t),"string"!==t||i.uint8array?"nodebuffer"===t?new o(e):i.uint8array?new l(r.transformTo("uint8array",e)):new s(r.transformTo("array",e)):new a(e)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(e,t,n){"use strict";n.LOCAL_FILE_HEADER="PK\x03\x04",n.CENTRAL_FILE_HEADER="PK\x01\x02",n.CENTRAL_DIRECTORY_END="PK\x05\x06",n.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x06\x07",n.ZIP64_CENTRAL_DIRECTORY_END="PK\x06\x06",n.DATA_DESCRIPTOR="PK\x07\b"},{}],24:[function(e,t,n){"use strict";var r=e("./GenericWorker"),i=e("../utils");function s(e){r.call(this,"ConvertWorker to "+e),this.destType=e}i.inherits(s,r),s.prototype.processChunk=function(e){this.push({data:i.transformTo(this.destType,e.data),meta:e.meta})},t.exports=s},{"../utils":32,"./GenericWorker":28}],25:[function(e,t,n){"use strict";var r=e("./GenericWorker"),i=e("../crc32");function s(){r.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}e("../utils").inherits(s,r),s.prototype.processChunk=function(e){this.streamInfo.crc32=i(e.data,this.streamInfo.crc32||0),this.push(e)},t.exports=s},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(e,t,n){"use strict";var r=e("../utils"),i=e("./GenericWorker");function s(e){i.call(this,"DataLengthProbe for "+e),this.propName=e,this.withStreamInfo(e,0)}r.inherits(s,i),s.prototype.processChunk=function(e){if(e){var t=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=t+e.data.length}i.prototype.processChunk.call(this,e)},t.exports=s},{"../utils":32,"./GenericWorker":28}],27:[function(e,t,n){"use strict";var r=e("../utils"),i=e("./GenericWorker");function s(e){i.call(this,"DataWorker");var t=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,e.then(function(e){t.dataIsReady=!0,t.data=e,t.max=e&&e.length||0,t.type=r.getTypeOf(e),t.isPaused||t._tickAndRepeat()},function(e){t.error(e)})}r.inherits(s,i),s.prototype.cleanUp=function(){i.prototype.cleanUp.call(this),this.data=null},s.prototype.resume=function(){return!!i.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,r.delay(this._tickAndRepeat,[],this)),!0)},s.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(r.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},s.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var e=null,t=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":e=this.data.substring(this.index,t);break;case"uint8array":e=this.data.subarray(this.index,t);break;case"array":case"nodebuffer":e=this.data.slice(this.index,t)}return this.index=t,this.push({data:e,meta:{percent:this.max?this.index/this.max*100:0}})},t.exports=s},{"../utils":32,"./GenericWorker":28}],28:[function(e,t,n){"use strict";function r(e){this.name=e||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}r.prototype={push:function(e){this.emit("data",e)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(e){this.emit("error",e)}return!0},error:function(e){return!this.isFinished&&(this.isPaused?this.generatedError=e:(this.isFinished=!0,this.emit("error",e),this.previous&&this.previous.error(e),this.cleanUp()),!0)},on:function(e,t){return this._listeners[e].push(t),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(e,t){if(this._listeners[e])for(var n=0;n<this._listeners[e].length;n++)this._listeners[e][n].call(this,t)},pipe:function(e){return e.registerPrevious(this)},registerPrevious:function(e){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=e.streamInfo,this.mergeStreamInfo(),this.previous=e;var t=this;return e.on("data",function(e){t.processChunk(e)}),e.on("end",function(){t.end()}),e.on("error",function(e){t.error(e)}),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||this.isFinished)return!1;var e=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),e=!0),this.previous&&this.previous.resume(),!e},flush:function(){},processChunk:function(e){this.push(e)},withStreamInfo:function(e,t){return this.extraStreamInfo[e]=t,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var e in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,e)&&(this.streamInfo[e]=this.extraStreamInfo[e])},lock:function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},toString:function(){var e="Worker "+this.name;return this.previous?this.previous+" -> "+e:e}},t.exports=r},{}],29:[function(e,t,n){"use strict";var r=e("../utils"),i=e("./ConvertWorker"),s=e("./GenericWorker"),a=e("../base64"),o=e("../support"),l=e("../external"),c=null;if(o.nodestream)try{c=e("../nodejs/NodejsStreamOutputAdapter")}catch(e){}function h(e,t){return new l.Promise(function(n,i){var s=[],o=e._internalType,l=e._outputType,c=e._mimeType;e.on("data",function(e,n){s.push(e),t&&t(n)}).on("error",function(e){s=[],i(e)}).on("end",function(){try{var e=function(e,t,n){switch(e){case"blob":return r.newBlob(r.transformTo("arraybuffer",t),n);case"base64":return a.encode(t);default:return r.transformTo(e,t)}}(l,function(e,t){var n,r=0,i=null,s=0;for(n=0;n<t.length;n++)s+=t[n].length;switch(e){case"string":return t.join("");case"array":return Array.prototype.concat.apply([],t);case"uint8array":for(i=new Uint8Array(s),n=0;n<t.length;n++)i.set(t[n],r),r+=t[n].length;return i;case"nodebuffer":return Buffer.concat(t);default:throw new Error("concat : unsupported type '"+e+"'")}}(o,s),c);n(e)}catch(e){i(e)}s=[]}).resume()})}function d(e,t,n){var a=t;switch(t){case"blob":case"arraybuffer":a="uint8array";break;case"base64":a="string"}try{this._internalType=a,this._outputType=t,this._mimeType=n,r.checkSupport(a),this._worker=e.pipe(new i(a)),e.lock()}catch(e){this._worker=new s("error"),this._worker.error(e)}}d.prototype={accumulate:function(e){return h(this,e)},on:function(e,t){var n=this;return"data"===e?this._worker.on(e,function(e){t.call(n,e.data,e.meta)}):this._worker.on(e,function(){r.delay(t,arguments,n)}),this},resume:function(){return r.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(e){if(r.checkSupport("nodestream"),"nodebuffer"!==this._outputType)throw new Error(this._outputType+" is not supported by this method");return new c(this,{objectMode:"nodebuffer"!==this._outputType},e)}},t.exports=d},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(e,t,n){"use strict";if(n.base64=!0,n.array=!0,n.string=!0,n.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,n.nodebuffer="undefined"!=typeof Buffer,n.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)n.blob=!1;else{var r=new ArrayBuffer(0);try{n.blob=0===new Blob([r],{type:"application/zip"}).size}catch(e){try{var i=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);i.append(r),n.blob=0===i.getBlob("application/zip").size}catch(e){n.blob=!1}}}try{n.nodestream=!!e("readable-stream").Readable}catch(e){n.nodestream=!1}},{"readable-stream":16}],31:[function(e,t,n){"use strict";for(var r=e("./utils"),i=e("./support"),s=e("./nodejsUtils"),a=e("./stream/GenericWorker"),o=new Array(256),l=0;l<256;l++)o[l]=252<=l?6:248<=l?5:240<=l?4:224<=l?3:192<=l?2:1;function c(){a.call(this,"utf-8 decode"),this.leftOver=null}function h(){a.call(this,"utf-8 encode")}o[254]=o[254]=1,n.utf8encode=function(e){return i.nodebuffer?s.newBufferFrom(e,"utf-8"):function(e){var t,n,r,s,a,o=e.length,l=0;for(s=0;s<o;s++)55296==(64512&(n=e.charCodeAt(s)))&&s+1<o&&56320==(64512&(r=e.charCodeAt(s+1)))&&(n=65536+(n-55296<<10)+(r-56320),s++),l+=n<128?1:n<2048?2:n<65536?3:4;for(t=i.uint8array?new Uint8Array(l):new Array(l),s=a=0;a<l;s++)55296==(64512&(n=e.charCodeAt(s)))&&s+1<o&&56320==(64512&(r=e.charCodeAt(s+1)))&&(n=65536+(n-55296<<10)+(r-56320),s++),n<128?t[a++]=n:(n<2048?t[a++]=192|n>>>6:(n<65536?t[a++]=224|n>>>12:(t[a++]=240|n>>>18,t[a++]=128|n>>>12&63),t[a++]=128|n>>>6&63),t[a++]=128|63&n);return t}(e)},n.utf8decode=function(e){return i.nodebuffer?r.transformTo("nodebuffer",e).toString("utf-8"):function(e){var t,n,i,s,a=e.length,l=new Array(2*a);for(t=n=0;t<a;)if((i=e[t++])<128)l[n++]=i;else if(4<(s=o[i]))l[n++]=65533,t+=s-1;else{for(i&=2===s?31:3===s?15:7;1<s&&t<a;)i=i<<6|63&e[t++],s--;1<s?l[n++]=65533:i<65536?l[n++]=i:(i-=65536,l[n++]=55296|i>>10&1023,l[n++]=56320|1023&i)}return l.length!==n&&(l.subarray?l=l.subarray(0,n):l.length=n),r.applyFromCharCode(l)}(e=r.transformTo(i.uint8array?"uint8array":"array",e))},r.inherits(c,a),c.prototype.processChunk=function(e){var t=r.transformTo(i.uint8array?"uint8array":"array",e.data);if(this.leftOver&&this.leftOver.length){if(i.uint8array){var s=t;(t=new Uint8Array(s.length+this.leftOver.length)).set(this.leftOver,0),t.set(s,this.leftOver.length)}else t=this.leftOver.concat(t);this.leftOver=null}var a=function(e,t){var n;for((t=t||e.length)>e.length&&(t=e.length),n=t-1;0<=n&&128==(192&e[n]);)n--;return n<0||0===n?t:n+o[e[n]]>t?n:t}(t),l=t;a!==t.length&&(i.uint8array?(l=t.subarray(0,a),this.leftOver=t.subarray(a,t.length)):(l=t.slice(0,a),this.leftOver=t.slice(a,t.length))),this.push({data:n.utf8decode(l),meta:e.meta})},c.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:n.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},n.Utf8DecodeWorker=c,r.inherits(h,a),h.prototype.processChunk=function(e){this.push({data:n.utf8encode(e.data),meta:e.meta})},n.Utf8EncodeWorker=h},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(e,t,n){"use strict";var r=e("./support"),i=e("./base64"),s=e("./nodejsUtils"),a=e("./external");function o(e){return e}function l(e,t){for(var n=0;n<e.length;++n)t[n]=255&e.charCodeAt(n);return t}e("setimmediate"),n.newBlob=function(t,r){n.checkSupport("blob");try{return new Blob([t],{type:r})}catch(e){try{var i=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return i.append(t),i.getBlob(r)}catch(e){throw new Error("Bug : can't construct the Blob.")}}};var c={stringifyByChunk:function(e,t,n){var r=[],i=0,s=e.length;if(s<=n)return String.fromCharCode.apply(null,e);for(;i<s;)"array"===t||"nodebuffer"===t?r.push(String.fromCharCode.apply(null,e.slice(i,Math.min(i+n,s)))):r.push(String.fromCharCode.apply(null,e.subarray(i,Math.min(i+n,s)))),i+=n;return r.join("")},stringifyByChar:function(e){for(var t="",n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return t},applyCanBeUsed:{uint8array:function(){try{return r.uint8array&&1===String.fromCharCode.apply(null,new Uint8Array(1)).length}catch(e){return!1}}(),nodebuffer:function(){try{return r.nodebuffer&&1===String.fromCharCode.apply(null,s.allocBuffer(1)).length}catch(e){return!1}}()}};function h(e){var t=65536,r=n.getTypeOf(e),i=!0;if("uint8array"===r?i=c.applyCanBeUsed.uint8array:"nodebuffer"===r&&(i=c.applyCanBeUsed.nodebuffer),i)for(;1<t;)try{return c.stringifyByChunk(e,r,t)}catch(e){t=Math.floor(t/2)}return c.stringifyByChar(e)}function d(e,t){for(var n=0;n<e.length;n++)t[n]=e[n];return t}n.applyFromCharCode=h;var u={};u.string={string:o,array:function(e){return l(e,new Array(e.length))},arraybuffer:function(e){return u.string.uint8array(e).buffer},uint8array:function(e){return l(e,new Uint8Array(e.length))},nodebuffer:function(e){return l(e,s.allocBuffer(e.length))}},u.array={string:h,array:o,arraybuffer:function(e){return new Uint8Array(e).buffer},uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return s.newBufferFrom(e)}},u.arraybuffer={string:function(e){return h(new Uint8Array(e))},array:function(e){return d(new Uint8Array(e),new Array(e.byteLength))},arraybuffer:o,uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return s.newBufferFrom(new Uint8Array(e))}},u.uint8array={string:h,array:function(e){return d(e,new Array(e.length))},arraybuffer:function(e){return e.buffer},uint8array:o,nodebuffer:function(e){return s.newBufferFrom(e)}},u.nodebuffer={string:h,array:function(e){return d(e,new Array(e.length))},arraybuffer:function(e){return u.nodebuffer.uint8array(e).buffer},uint8array:function(e){return d(e,new Uint8Array(e.length))},nodebuffer:o},n.transformTo=function(e,t){if(t=t||"",!e)return t;n.checkSupport(e);var r=n.getTypeOf(t);return u[r][e](t)},n.resolve=function(e){for(var t=e.split("/"),n=[],r=0;r<t.length;r++){var i=t[r];"."===i||""===i&&0!==r&&r!==t.length-1||(".."===i?n.pop():n.push(i))}return n.join("/")},n.getTypeOf=function(e){return"string"==typeof e?"string":"[object Array]"===Object.prototype.toString.call(e)?"array":r.nodebuffer&&s.isBuffer(e)?"nodebuffer":r.uint8array&&e instanceof Uint8Array?"uint8array":r.arraybuffer&&e instanceof ArrayBuffer?"arraybuffer":void 0},n.checkSupport=function(e){if(!r[e.toLowerCase()])throw new Error(e+" is not supported by this platform")},n.MAX_VALUE_16BITS=65535,n.MAX_VALUE_32BITS=-1,n.pretty=function(e){var t,n,r="";for(n=0;n<(e||"").length;n++)r+="\\x"+((t=e.charCodeAt(n))<16?"0":"")+t.toString(16).toUpperCase();return r},n.delay=function(e,t,n){setImmediate(function(){e.apply(n||null,t||[])})},n.inherits=function(e,t){function n(){}n.prototype=t.prototype,e.prototype=new n},n.extend=function(){var e,t,n={};for(e=0;e<arguments.length;e++)for(t in arguments[e])Object.prototype.hasOwnProperty.call(arguments[e],t)&&void 0===n[t]&&(n[t]=arguments[e][t]);return n},n.prepareContent=function(e,t,s,o,c){return a.Promise.resolve(t).then(function(e){return r.blob&&(e instanceof Blob||-1!==["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(e)))&&"undefined"!=typeof FileReader?new a.Promise(function(t,n){var r=new FileReader;r.onload=function(e){t(e.target.result)},r.onerror=function(e){n(e.target.error)},r.readAsArrayBuffer(e)}):e}).then(function(t){var h=n.getTypeOf(t);return h?("arraybuffer"===h?t=n.transformTo("uint8array",t):"string"===h&&(c?t=i.decode(t):s&&!0!==o&&(t=function(e){return l(e,r.uint8array?new Uint8Array(e.length):new Array(e.length))}(t))),t):a.Promise.reject(new Error("Can't read the data of '"+e+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}},{"./base64":1,"./external":6,"./nodejsUtils":14,"./support":30,setimmediate:54}],33:[function(e,t,n){"use strict";var r=e("./reader/readerFor"),i=e("./utils"),s=e("./signature"),a=e("./zipEntry"),o=e("./support");function l(e){this.files=[],this.loadOptions=e}l.prototype={checkSignature:function(e){if(!this.reader.readAndCheckSignature(e)){this.reader.index-=4;var t=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+i.pretty(t)+", expected "+i.pretty(e)+")")}},isSignature:function(e,t){var n=this.reader.index;this.reader.setIndex(e);var r=this.reader.readString(4)===t;return this.reader.setIndex(n),r},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var e=this.reader.readData(this.zipCommentLength),t=o.uint8array?"uint8array":"array",n=i.transformTo(t,e);this.zipComment=this.loadOptions.decodeFileName(n)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var e,t,n,r=this.zip64EndOfCentralSize-44;0<r;)e=this.reader.readInt(2),t=this.reader.readInt(4),n=this.reader.readData(t),this.zip64ExtensibleData[e]={id:e,length:t,value:n}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var e,t;for(e=0;e<this.files.length;e++)t=this.files[e],this.reader.setIndex(t.localHeaderOffset),this.checkSignature(s.LOCAL_FILE_HEADER),t.readLocalPart(this.reader),t.handleUTF8(),t.processAttributes()},readCentralDir:function(){var e;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(s.CENTRAL_FILE_HEADER);)(e=new a({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(e);if(this.centralDirRecords!==this.files.length&&0!==this.centralDirRecords&&0===this.files.length)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var e=this.reader.lastIndexOfSignature(s.CENTRAL_DIRECTORY_END);if(e<0)throw this.isSignature(0,s.LOCAL_FILE_HEADER)?new Error("Corrupted zip: can't find end of central directory"):new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");this.reader.setIndex(e);var t=e;if(this.checkSignature(s.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===i.MAX_VALUE_16BITS||this.diskWithCentralDirStart===i.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===i.MAX_VALUE_16BITS||this.centralDirRecords===i.MAX_VALUE_16BITS||this.centralDirSize===i.MAX_VALUE_32BITS||this.centralDirOffset===i.MAX_VALUE_32BITS){if(this.zip64=!0,(e=this.reader.lastIndexOfSignature(s.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(e),this.checkSignature(s.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,s.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(s.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(s.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var n=this.centralDirOffset+this.centralDirSize;this.zip64&&(n+=20,n+=12+this.zip64EndOfCentralSize);var r=t-n;if(0<r)this.isSignature(t,s.CENTRAL_FILE_HEADER)||(this.reader.zero=r);else if(r<0)throw new Error("Corrupted zip: missing "+Math.abs(r)+" bytes.")},prepareReader:function(e){this.reader=r(e)},load:function(e){this.prepareReader(e),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},t.exports=l},{"./reader/readerFor":22,"./signature":23,"./support":30,"./utils":32,"./zipEntry":34}],34:[function(e,t,n){"use strict";var r=e("./reader/readerFor"),i=e("./utils"),s=e("./compressedObject"),a=e("./crc32"),o=e("./utf8"),l=e("./compressions"),c=e("./support");function h(e,t){this.options=e,this.loadOptions=t}h.prototype={isEncrypted:function(){return 1==(1&this.bitFlag)},useUTF8:function(){return 2048==(2048&this.bitFlag)},readLocalPart:function(e){var t,n;if(e.skip(22),this.fileNameLength=e.readInt(2),n=e.readInt(2),this.fileName=e.readData(this.fileNameLength),e.skip(n),-1===this.compressedSize||-1===this.uncompressedSize)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if(null===(t=function(e){for(var t in l)if(Object.prototype.hasOwnProperty.call(l,t)&&l[t].magic===e)return l[t];return null}(this.compressionMethod)))throw new Error("Corrupted zip : compression "+i.pretty(this.compressionMethod)+" unknown (inner file : "+i.transformTo("string",this.fileName)+")");this.decompressed=new s(this.compressedSize,this.uncompressedSize,this.crc32,t,e.readData(this.compressedSize))},readCentralPart:function(e){this.versionMadeBy=e.readInt(2),e.skip(2),this.bitFlag=e.readInt(2),this.compressionMethod=e.readString(2),this.date=e.readDate(),this.crc32=e.readInt(4),this.compressedSize=e.readInt(4),this.uncompressedSize=e.readInt(4);var t=e.readInt(2);if(this.extraFieldsLength=e.readInt(2),this.fileCommentLength=e.readInt(2),this.diskNumberStart=e.readInt(2),this.internalFileAttributes=e.readInt(2),this.externalFileAttributes=e.readInt(4),this.localHeaderOffset=e.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");e.skip(t),this.readExtraFields(e),this.parseZIP64ExtraField(e),this.fileComment=e.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var e=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),0==e&&(this.dosPermissions=63&this.externalFileAttributes),3==e&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||"/"!==this.fileNameStr.slice(-1)||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var e=r(this.extraFields[1].value);this.uncompressedSize===i.MAX_VALUE_32BITS&&(this.uncompressedSize=e.readInt(8)),this.compressedSize===i.MAX_VALUE_32BITS&&(this.compressedSize=e.readInt(8)),this.localHeaderOffset===i.MAX_VALUE_32BITS&&(this.localHeaderOffset=e.readInt(8)),this.diskNumberStart===i.MAX_VALUE_32BITS&&(this.diskNumberStart=e.readInt(4))}},readExtraFields:function(e){var t,n,r,i=e.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});e.index+4<i;)t=e.readInt(2),n=e.readInt(2),r=e.readData(n),this.extraFields[t]={id:t,length:n,value:r};e.setIndex(i)},handleUTF8:function(){var e=c.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=o.utf8decode(this.fileName),this.fileCommentStr=o.utf8decode(this.fileComment);else{var t=this.findExtraFieldUnicodePath();if(null!==t)this.fileNameStr=t;else{var n=i.transformTo(e,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(n)}var r=this.findExtraFieldUnicodeComment();if(null!==r)this.fileCommentStr=r;else{var s=i.transformTo(e,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(s)}}},findExtraFieldUnicodePath:function(){var e=this.extraFields[28789];if(e){var t=r(e.value);return 1!==t.readInt(1)||a(this.fileName)!==t.readInt(4)?null:o.utf8decode(t.readData(e.length-5))}return null},findExtraFieldUnicodeComment:function(){var e=this.extraFields[25461];if(e){var t=r(e.value);return 1!==t.readInt(1)||a(this.fileComment)!==t.readInt(4)?null:o.utf8decode(t.readData(e.length-5))}return null}},t.exports=h},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(e,t,n){"use strict";function r(e,t,n){this.name=e,this.dir=n.dir,this.date=n.date,this.comment=n.comment,this.unixPermissions=n.unixPermissions,this.dosPermissions=n.dosPermissions,this._data=t,this._dataBinary=n.binary,this.options={compression:n.compression,compressionOptions:n.compressionOptions}}var i=e("./stream/StreamHelper"),s=e("./stream/DataWorker"),a=e("./utf8"),o=e("./compressedObject"),l=e("./stream/GenericWorker");r.prototype={internalStream:function(e){var t=null,n="string";try{if(!e)throw new Error("No output type specified.");var r="string"===(n=e.toLowerCase())||"text"===n;"binarystring"!==n&&"text"!==n||(n="string"),t=this._decompressWorker();var s=!this._dataBinary;s&&!r&&(t=t.pipe(new a.Utf8EncodeWorker)),!s&&r&&(t=t.pipe(new a.Utf8DecodeWorker))}catch(e){(t=new l("error")).error(e)}return new i(t,n,"")},async:function(e,t){return this.internalStream(e).accumulate(t)},nodeStream:function(e,t){return this.internalStream(e||"nodebuffer").toNodejsStream(t)},_compressWorker:function(e,t){if(this._data instanceof o&&this._data.compression.magic===e.magic)return this._data.getCompressedWorker();var n=this._decompressWorker();return this._dataBinary||(n=n.pipe(new a.Utf8EncodeWorker)),o.createWorkerFrom(n,e,t)},_decompressWorker:function(){return this._data instanceof o?this._data.getContentWorker():this._data instanceof l?this._data:new s(this._data)}};for(var c=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],h=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},d=0;d<c.length;d++)r.prototype[c[d]]=h;t.exports=r},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(e,t,n){(function(e){"use strict";var n,r,i=e.MutationObserver||e.WebKitMutationObserver;if(i){var s=0,a=new i(h),o=e.document.createTextNode("");a.observe(o,{characterData:!0}),n=function(){o.data=s=++s%2}}else if(e.setImmediate||void 0===e.MessageChannel)n="document"in e&&"onreadystatechange"in e.document.createElement("script")?function(){var t=e.document.createElement("script");t.onreadystatechange=function(){h(),t.onreadystatechange=null,t.parentNode.removeChild(t),t=null},e.document.documentElement.appendChild(t)}:function(){setTimeout(h,0)};else{var l=new e.MessageChannel;l.port1.onmessage=h,n=function(){l.port2.postMessage(0)}}var c=[];function h(){var e,t;r=!0;for(var n=c.length;n;){for(t=c,c=[],e=-1;++e<n;)t[e]();n=c.length}r=!1}t.exports=function(e){1!==c.push(e)||r||n()}}).call(this,"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],37:[function(e,t,n){"use strict";var r=e("immediate");function i(){}var s={},a=["REJECTED"],o=["FULFILLED"],l=["PENDING"];function c(e){if("function"!=typeof e)throw new TypeError("resolver must be a function");this.state=l,this.queue=[],this.outcome=void 0,e!==i&&p(this,e)}function h(e,t,n){this.promise=e,"function"==typeof t&&(this.onFulfilled=t,this.callFulfilled=this.otherCallFulfilled),"function"==typeof n&&(this.onRejected=n,this.callRejected=this.otherCallRejected)}function d(e,t,n){r(function(){var r;try{r=t(n)}catch(r){return s.reject(e,r)}r===e?s.reject(e,new TypeError("Cannot resolve promise with itself")):s.resolve(e,r)})}function u(e){var t=e&&e.then;if(e&&("object"==typeof e||"function"==typeof e)&&"function"==typeof t)return function(){t.apply(e,arguments)}}function p(e,t){var n=!1;function r(t){n||(n=!0,s.reject(e,t))}function i(t){n||(n=!0,s.resolve(e,t))}var a=f(function(){t(i,r)});"error"===a.status&&r(a.value)}function f(e,t){var n={};try{n.value=e(t),n.status="success"}catch(e){n.status="error",n.value=e}return n}(t.exports=c).prototype.finally=function(e){if("function"!=typeof e)return this;var t=this.constructor;return this.then(function(n){return t.resolve(e()).then(function(){return n})},function(n){return t.resolve(e()).then(function(){throw n})})},c.prototype.catch=function(e){return this.then(null,e)},c.prototype.then=function(e,t){if("function"!=typeof e&&this.state===o||"function"!=typeof t&&this.state===a)return this;var n=new this.constructor(i);return this.state!==l?d(n,this.state===o?e:t,this.outcome):this.queue.push(new h(n,e,t)),n},h.prototype.callFulfilled=function(e){s.resolve(this.promise,e)},h.prototype.otherCallFulfilled=function(e){d(this.promise,this.onFulfilled,e)},h.prototype.callRejected=function(e){s.reject(this.promise,e)},h.prototype.otherCallRejected=function(e){d(this.promise,this.onRejected,e)},s.resolve=function(e,t){var n=f(u,t);if("error"===n.status)return s.reject(e,n.value);var r=n.value;if(r)p(e,r);else{e.state=o,e.outcome=t;for(var i=-1,a=e.queue.length;++i<a;)e.queue[i].callFulfilled(t)}return e},s.reject=function(e,t){e.state=a,e.outcome=t;for(var n=-1,r=e.queue.length;++n<r;)e.queue[n].callRejected(t);return e},c.resolve=function(e){return e instanceof this?e:s.resolve(new this(i),e)},c.reject=function(e){var t=new this(i);return s.reject(t,e)},c.all=function(e){var t=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,r=!1;if(!n)return this.resolve([]);for(var a=new Array(n),o=0,l=-1,c=new this(i);++l<n;)h(e[l],l);return c;function h(e,i){t.resolve(e).then(function(e){a[i]=e,++o!==n||r||(r=!0,s.resolve(c,a))},function(e){r||(r=!0,s.reject(c,e))})}},c.race=function(e){var t=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,r=!1;if(!n)return this.resolve([]);for(var a,o=-1,l=new this(i);++o<n;)a=e[o],t.resolve(a).then(function(e){r||(r=!0,s.resolve(l,e))},function(e){r||(r=!0,s.reject(l,e))});return l}},{immediate:36}],38:[function(e,t,n){"use strict";var r={};(0,e("./lib/utils/common").assign)(r,e("./lib/deflate"),e("./lib/inflate"),e("./lib/zlib/constants")),t.exports=r},{"./lib/deflate":39,"./lib/inflate":40,"./lib/utils/common":41,"./lib/zlib/constants":44}],39:[function(e,t,n){"use strict";var r=e("./zlib/deflate"),i=e("./utils/common"),s=e("./utils/strings"),a=e("./zlib/messages"),o=e("./zlib/zstream"),l=Object.prototype.toString,c=0,h=-1,d=0,u=8;function p(e){if(!(this instanceof p))return new p(e);this.options=i.assign({level:h,method:u,chunkSize:16384,windowBits:15,memLevel:8,strategy:d,to:""},e||{});var t=this.options;t.raw&&0<t.windowBits?t.windowBits=-t.windowBits:t.gzip&&0<t.windowBits&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new o,this.strm.avail_out=0;var n=r.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(n!==c)throw new Error(a[n]);if(t.header&&r.deflateSetHeader(this.strm,t.header),t.dictionary){var f;if(f="string"==typeof t.dictionary?s.string2buf(t.dictionary):"[object ArrayBuffer]"===l.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,(n=r.deflateSetDictionary(this.strm,f))!==c)throw new Error(a[n]);this._dict_set=!0}}function f(e,t){var n=new p(t);if(n.push(e,!0),n.err)throw n.msg||a[n.err];return n.result}p.prototype.push=function(e,t){var n,a,o=this.strm,h=this.options.chunkSize;if(this.ended)return!1;a=t===~~t?t:!0===t?4:0,"string"==typeof e?o.input=s.string2buf(e):"[object ArrayBuffer]"===l.call(e)?o.input=new Uint8Array(e):o.input=e,o.next_in=0,o.avail_in=o.input.length;do{if(0===o.avail_out&&(o.output=new i.Buf8(h),o.next_out=0,o.avail_out=h),1!==(n=r.deflate(o,a))&&n!==c)return this.onEnd(n),!(this.ended=!0);0!==o.avail_out&&(0!==o.avail_in||4!==a&&2!==a)||("string"===this.options.to?this.onData(s.buf2binstring(i.shrinkBuf(o.output,o.next_out))):this.onData(i.shrinkBuf(o.output,o.next_out)))}while((0<o.avail_in||0===o.avail_out)&&1!==n);return 4===a?(n=r.deflateEnd(this.strm),this.onEnd(n),this.ended=!0,n===c):2!==a||(this.onEnd(c),!(o.avail_out=0))},p.prototype.onData=function(e){this.chunks.push(e)},p.prototype.onEnd=function(e){e===c&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},n.Deflate=p,n.deflate=f,n.deflateRaw=function(e,t){return(t=t||{}).raw=!0,f(e,t)},n.gzip=function(e,t){return(t=t||{}).gzip=!0,f(e,t)}},{"./utils/common":41,"./utils/strings":42,"./zlib/deflate":46,"./zlib/messages":51,"./zlib/zstream":53}],40:[function(e,t,n){"use strict";var r=e("./zlib/inflate"),i=e("./utils/common"),s=e("./utils/strings"),a=e("./zlib/constants"),o=e("./zlib/messages"),l=e("./zlib/zstream"),c=e("./zlib/gzheader"),h=Object.prototype.toString;function d(e){if(!(this instanceof d))return new d(e);this.options=i.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options;t.raw&&0<=t.windowBits&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),!(0<=t.windowBits&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),15<t.windowBits&&t.windowBits<48&&0==(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new l,this.strm.avail_out=0;var n=r.inflateInit2(this.strm,t.windowBits);if(n!==a.Z_OK)throw new Error(o[n]);this.header=new c,r.inflateGetHeader(this.strm,this.header)}function u(e,t){var n=new d(t);if(n.push(e,!0),n.err)throw n.msg||o[n.err];return n.result}d.prototype.push=function(e,t){var n,o,l,c,d,u,p=this.strm,f=this.options.chunkSize,m=this.options.dictionary,g=!1;if(this.ended)return!1;o=t===~~t?t:!0===t?a.Z_FINISH:a.Z_NO_FLUSH,"string"==typeof e?p.input=s.binstring2buf(e):"[object ArrayBuffer]"===h.call(e)?p.input=new Uint8Array(e):p.input=e,p.next_in=0,p.avail_in=p.input.length;do{if(0===p.avail_out&&(p.output=new i.Buf8(f),p.next_out=0,p.avail_out=f),(n=r.inflate(p,a.Z_NO_FLUSH))===a.Z_NEED_DICT&&m&&(u="string"==typeof m?s.string2buf(m):"[object ArrayBuffer]"===h.call(m)?new Uint8Array(m):m,n=r.inflateSetDictionary(this.strm,u)),n===a.Z_BUF_ERROR&&!0===g&&(n=a.Z_OK,g=!1),n!==a.Z_STREAM_END&&n!==a.Z_OK)return this.onEnd(n),!(this.ended=!0);p.next_out&&(0!==p.avail_out&&n!==a.Z_STREAM_END&&(0!==p.avail_in||o!==a.Z_FINISH&&o!==a.Z_SYNC_FLUSH)||("string"===this.options.to?(l=s.utf8border(p.output,p.next_out),c=p.next_out-l,d=s.buf2string(p.output,l),p.next_out=c,p.avail_out=f-c,c&&i.arraySet(p.output,p.output,l,c,0),this.onData(d)):this.onData(i.shrinkBuf(p.output,p.next_out)))),0===p.avail_in&&0===p.avail_out&&(g=!0)}while((0<p.avail_in||0===p.avail_out)&&n!==a.Z_STREAM_END);return n===a.Z_STREAM_END&&(o=a.Z_FINISH),o===a.Z_FINISH?(n=r.inflateEnd(this.strm),this.onEnd(n),this.ended=!0,n===a.Z_OK):o!==a.Z_SYNC_FLUSH||(this.onEnd(a.Z_OK),!(p.avail_out=0))},d.prototype.onData=function(e){this.chunks.push(e)},d.prototype.onEnd=function(e){e===a.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},n.Inflate=d,n.inflate=u,n.inflateRaw=function(e,t){return(t=t||{}).raw=!0,u(e,t)},n.ungzip=u},{"./utils/common":41,"./utils/strings":42,"./zlib/constants":44,"./zlib/gzheader":47,"./zlib/inflate":49,"./zlib/messages":51,"./zlib/zstream":53}],41:[function(e,t,n){"use strict";var r="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;n.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var n=t.shift();if(n){if("object"!=typeof n)throw new TypeError(n+"must be non-object");for(var r in n)n.hasOwnProperty(r)&&(e[r]=n[r])}}return e},n.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var i={arraySet:function(e,t,n,r,i){if(t.subarray&&e.subarray)e.set(t.subarray(n,n+r),i);else for(var s=0;s<r;s++)e[i+s]=t[n+s]},flattenChunks:function(e){var t,n,r,i,s,a;for(t=r=0,n=e.length;t<n;t++)r+=e[t].length;for(a=new Uint8Array(r),t=i=0,n=e.length;t<n;t++)s=e[t],a.set(s,i),i+=s.length;return a}},s={arraySet:function(e,t,n,r,i){for(var s=0;s<r;s++)e[i+s]=t[n+s]},flattenChunks:function(e){return[].concat.apply([],e)}};n.setTyped=function(e){e?(n.Buf8=Uint8Array,n.Buf16=Uint16Array,n.Buf32=Int32Array,n.assign(n,i)):(n.Buf8=Array,n.Buf16=Array,n.Buf32=Array,n.assign(n,s))},n.setTyped(r)},{}],42:[function(e,t,n){"use strict";var r=e("./common"),i=!0,s=!0;try{String.fromCharCode.apply(null,[0])}catch(e){i=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(e){s=!1}for(var a=new r.Buf8(256),o=0;o<256;o++)a[o]=252<=o?6:248<=o?5:240<=o?4:224<=o?3:192<=o?2:1;function l(e,t){if(t<65537&&(e.subarray&&s||!e.subarray&&i))return String.fromCharCode.apply(null,r.shrinkBuf(e,t));for(var n="",a=0;a<t;a++)n+=String.fromCharCode(e[a]);return n}a[254]=a[254]=1,n.string2buf=function(e){var t,n,i,s,a,o=e.length,l=0;for(s=0;s<o;s++)55296==(64512&(n=e.charCodeAt(s)))&&s+1<o&&56320==(64512&(i=e.charCodeAt(s+1)))&&(n=65536+(n-55296<<10)+(i-56320),s++),l+=n<128?1:n<2048?2:n<65536?3:4;for(t=new r.Buf8(l),s=a=0;a<l;s++)55296==(64512&(n=e.charCodeAt(s)))&&s+1<o&&56320==(64512&(i=e.charCodeAt(s+1)))&&(n=65536+(n-55296<<10)+(i-56320),s++),n<128?t[a++]=n:(n<2048?t[a++]=192|n>>>6:(n<65536?t[a++]=224|n>>>12:(t[a++]=240|n>>>18,t[a++]=128|n>>>12&63),t[a++]=128|n>>>6&63),t[a++]=128|63&n);return t},n.buf2binstring=function(e){return l(e,e.length)},n.binstring2buf=function(e){for(var t=new r.Buf8(e.length),n=0,i=t.length;n<i;n++)t[n]=e.charCodeAt(n);return t},n.buf2string=function(e,t){var n,r,i,s,o=t||e.length,c=new Array(2*o);for(n=r=0;n<o;)if((i=e[n++])<128)c[r++]=i;else if(4<(s=a[i]))c[r++]=65533,n+=s-1;else{for(i&=2===s?31:3===s?15:7;1<s&&n<o;)i=i<<6|63&e[n++],s--;1<s?c[r++]=65533:i<65536?c[r++]=i:(i-=65536,c[r++]=55296|i>>10&1023,c[r++]=56320|1023&i)}return l(c,r)},n.utf8border=function(e,t){var n;for((t=t||e.length)>e.length&&(t=e.length),n=t-1;0<=n&&128==(192&e[n]);)n--;return n<0||0===n?t:n+a[e[n]]>t?n:t}},{"./common":41}],43:[function(e,t,n){"use strict";t.exports=function(e,t,n,r){for(var i=65535&e,s=e>>>16&65535,a=0;0!==n;){for(n-=a=2e3<n?2e3:n;s=s+(i=i+t[r++]|0)|0,--a;);i%=65521,s%=65521}return i|s<<16}},{}],44:[function(e,t,n){"use strict";t.exports={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}},{}],45:[function(e,t,n){"use strict";var r=function(){for(var e,t=[],n=0;n<256;n++){e=n;for(var r=0;r<8;r++)e=1&e?3988292384^e>>>1:e>>>1;t[n]=e}return t}();t.exports=function(e,t,n,i){var s=r,a=i+n;e^=-1;for(var o=i;o<a;o++)e=e>>>8^s[255&(e^t[o])];return-1^e}},{}],46:[function(e,t,n){"use strict";var r,i=e("../utils/common"),s=e("./trees"),a=e("./adler32"),o=e("./crc32"),l=e("./messages"),c=0,h=4,d=0,u=-2,p=-1,f=4,m=2,g=8,v=9,y=286,b=30,w=19,_=2*y+1,A=15,x=3,E=258,C=E+x+1,k=42,S=113,T=1,D=2,M=3,P=4;function I(e,t){return e.msg=l[t],t}function F(e){return(e<<1)-(4<e?9:0)}function R(e){for(var t=e.length;0<=--t;)e[t]=0}function N(e){var t=e.state,n=t.pending;n>e.avail_out&&(n=e.avail_out),0!==n&&(i.arraySet(e.output,t.pending_buf,t.pending_out,n,e.next_out),e.next_out+=n,t.pending_out+=n,e.total_out+=n,e.avail_out-=n,t.pending-=n,0===t.pending&&(t.pending_out=0))}function L(e,t){s._tr_flush_block(e,0<=e.block_start?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,N(e.strm)}function O(e,t){e.pending_buf[e.pending++]=t}function B(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t}function $(e,t){var n,r,i=e.max_chain_length,s=e.strstart,a=e.prev_length,o=e.nice_match,l=e.strstart>e.w_size-C?e.strstart-(e.w_size-C):0,c=e.window,h=e.w_mask,d=e.prev,u=e.strstart+E,p=c[s+a-1],f=c[s+a];e.prev_length>=e.good_match&&(i>>=2),o>e.lookahead&&(o=e.lookahead);do{if(c[(n=t)+a]===f&&c[n+a-1]===p&&c[n]===c[s]&&c[++n]===c[s+1]){s+=2,n++;do{}while(c[++s]===c[++n]&&c[++s]===c[++n]&&c[++s]===c[++n]&&c[++s]===c[++n]&&c[++s]===c[++n]&&c[++s]===c[++n]&&c[++s]===c[++n]&&c[++s]===c[++n]&&s<u);if(r=E-(u-s),s=u-E,a<r){if(e.match_start=t,o<=(a=r))break;p=c[s+a-1],f=c[s+a]}}}while((t=d[t&h])>l&&0!=--i);return a<=e.lookahead?a:e.lookahead}function z(e){var t,n,r,s,l,c,h,d,u,p,f=e.w_size;do{if(s=e.window_size-e.lookahead-e.strstart,e.strstart>=f+(f-C)){for(i.arraySet(e.window,e.window,f,f,0),e.match_start-=f,e.strstart-=f,e.block_start-=f,t=n=e.hash_size;r=e.head[--t],e.head[t]=f<=r?r-f:0,--n;);for(t=n=f;r=e.prev[--t],e.prev[t]=f<=r?r-f:0,--n;);s+=f}if(0===e.strm.avail_in)break;if(c=e.strm,h=e.window,d=e.strstart+e.lookahead,p=void 0,(u=s)<(p=c.avail_in)&&(p=u),n=0===p?0:(c.avail_in-=p,i.arraySet(h,c.input,c.next_in,p,d),1===c.state.wrap?c.adler=a(c.adler,h,p,d):2===c.state.wrap&&(c.adler=o(c.adler,h,p,d)),c.next_in+=p,c.total_in+=p,p),e.lookahead+=n,e.lookahead+e.insert>=x)for(l=e.strstart-e.insert,e.ins_h=e.window[l],e.ins_h=(e.ins_h<<e.hash_shift^e.window[l+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[l+x-1])&e.hash_mask,e.prev[l&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=l,l++,e.insert--,!(e.lookahead+e.insert<x)););}while(e.lookahead<C&&0!==e.strm.avail_in)}function j(e,t){for(var n,r;;){if(e.lookahead<C){if(z(e),e.lookahead<C&&t===c)return T;if(0===e.lookahead)break}if(n=0,e.lookahead>=x&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+x-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==n&&e.strstart-n<=e.w_size-C&&(e.match_length=$(e,n)),e.match_length>=x)if(r=s._tr_tally(e,e.strstart-e.match_start,e.match_length-x),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=x){for(e.match_length--;e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+x-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart,0!=--e.match_length;);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;else r=s._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(r&&(L(e,!1),0===e.strm.avail_out))return T}return e.insert=e.strstart<x-1?e.strstart:x-1,t===h?(L(e,!0),0===e.strm.avail_out?M:P):e.last_lit&&(L(e,!1),0===e.strm.avail_out)?T:D}function U(e,t){for(var n,r,i;;){if(e.lookahead<C){if(z(e),e.lookahead<C&&t===c)return T;if(0===e.lookahead)break}if(n=0,e.lookahead>=x&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+x-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=x-1,0!==n&&e.prev_length<e.max_lazy_match&&e.strstart-n<=e.w_size-C&&(e.match_length=$(e,n),e.match_length<=5&&(1===e.strategy||e.match_length===x&&4096<e.strstart-e.match_start)&&(e.match_length=x-1)),e.prev_length>=x&&e.match_length<=e.prev_length){for(i=e.strstart+e.lookahead-x,r=s._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-x),e.lookahead-=e.prev_length-1,e.prev_length-=2;++e.strstart<=i&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+x-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!=--e.prev_length;);if(e.match_available=0,e.match_length=x-1,e.strstart++,r&&(L(e,!1),0===e.strm.avail_out))return T}else if(e.match_available){if((r=s._tr_tally(e,0,e.window[e.strstart-1]))&&L(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return T}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(r=s._tr_tally(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<x-1?e.strstart:x-1,t===h?(L(e,!0),0===e.strm.avail_out?M:P):e.last_lit&&(L(e,!1),0===e.strm.avail_out)?T:D}function H(e,t,n,r,i){this.good_length=e,this.max_lazy=t,this.nice_length=n,this.max_chain=r,this.func=i}function V(){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=g,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 i.Buf16(2*_),this.dyn_dtree=new i.Buf16(2*(2*b+1)),this.bl_tree=new i.Buf16(2*(2*w+1)),R(this.dyn_ltree),R(this.dyn_dtree),R(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new i.Buf16(A+1),this.heap=new i.Buf16(2*y+1),R(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new i.Buf16(2*y+1),R(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 q(e){var t;return e&&e.state?(e.total_in=e.total_out=0,e.data_type=m,(t=e.state).pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?k:S,e.adler=2===t.wrap?0:1,t.last_flush=c,s._tr_init(t),d):I(e,u)}function W(e){var t=q(e);return t===d&&function(e){e.window_size=2*e.w_size,R(e.head),e.max_lazy_match=r[e.level].max_lazy,e.good_match=r[e.level].good_length,e.nice_match=r[e.level].nice_length,e.max_chain_length=r[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=x-1,e.match_available=0,e.ins_h=0}(e.state),t}function G(e,t,n,r,s,a){if(!e)return u;var o=1;if(t===p&&(t=6),r<0?(o=0,r=-r):15<r&&(o=2,r-=16),s<1||v<s||n!==g||r<8||15<r||t<0||9<t||a<0||f<a)return I(e,u);8===r&&(r=9);var l=new V;return(e.state=l).strm=e,l.wrap=o,l.gzhead=null,l.w_bits=r,l.w_size=1<<l.w_bits,l.w_mask=l.w_size-1,l.hash_bits=s+7,l.hash_size=1<<l.hash_bits,l.hash_mask=l.hash_size-1,l.hash_shift=~~((l.hash_bits+x-1)/x),l.window=new i.Buf8(2*l.w_size),l.head=new i.Buf16(l.hash_size),l.prev=new i.Buf16(l.w_size),l.lit_bufsize=1<<s+6,l.pending_buf_size=4*l.lit_bufsize,l.pending_buf=new i.Buf8(l.pending_buf_size),l.d_buf=1*l.lit_bufsize,l.l_buf=3*l.lit_bufsize,l.level=t,l.strategy=a,l.method=n,W(e)}r=[new H(0,0,0,0,function(e,t){var n=65535;for(n>e.pending_buf_size-5&&(n=e.pending_buf_size-5);;){if(e.lookahead<=1){if(z(e),0===e.lookahead&&t===c)return T;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var r=e.block_start+n;if((0===e.strstart||e.strstart>=r)&&(e.lookahead=e.strstart-r,e.strstart=r,L(e,!1),0===e.strm.avail_out))return T;if(e.strstart-e.block_start>=e.w_size-C&&(L(e,!1),0===e.strm.avail_out))return T}return e.insert=0,t===h?(L(e,!0),0===e.strm.avail_out?M:P):(e.strstart>e.block_start&&(L(e,!1),e.strm.avail_out),T)}),new H(4,4,8,4,j),new H(4,5,16,8,j),new H(4,6,32,32,j),new H(4,4,16,16,U),new H(8,16,32,32,U),new H(8,16,128,128,U),new H(8,32,128,256,U),new H(32,128,258,1024,U),new H(32,258,258,4096,U)],n.deflateInit=function(e,t){return G(e,t,g,15,8,0)},n.deflateInit2=G,n.deflateReset=W,n.deflateResetKeep=q,n.deflateSetHeader=function(e,t){return e&&e.state?2!==e.state.wrap?u:(e.state.gzhead=t,d):u},n.deflate=function(e,t){var n,i,a,l;if(!e||!e.state||5<t||t<0)return e?I(e,u):u;if(i=e.state,!e.output||!e.input&&0!==e.avail_in||666===i.status&&t!==h)return I(e,0===e.avail_out?-5:u);if(i.strm=e,n=i.last_flush,i.last_flush=t,i.status===k)if(2===i.wrap)e.adler=0,O(i,31),O(i,139),O(i,8),i.gzhead?(O(i,(i.gzhead.text?1:0)+(i.gzhead.hcrc?2:0)+(i.gzhead.extra?4:0)+(i.gzhead.name?8:0)+(i.gzhead.comment?16:0)),O(i,255&i.gzhead.time),O(i,i.gzhead.time>>8&255),O(i,i.gzhead.time>>16&255),O(i,i.gzhead.time>>24&255),O(i,9===i.level?2:2<=i.strategy||i.level<2?4:0),O(i,255&i.gzhead.os),i.gzhead.extra&&i.gzhead.extra.length&&(O(i,255&i.gzhead.extra.length),O(i,i.gzhead.extra.length>>8&255)),i.gzhead.hcrc&&(e.adler=o(e.adler,i.pending_buf,i.pending,0)),i.gzindex=0,i.status=69):(O(i,0),O(i,0),O(i,0),O(i,0),O(i,0),O(i,9===i.level?2:2<=i.strategy||i.level<2?4:0),O(i,3),i.status=S);else{var p=g+(i.w_bits-8<<4)<<8;p|=(2<=i.strategy||i.level<2?0:i.level<6?1:6===i.level?2:3)<<6,0!==i.strstart&&(p|=32),p+=31-p%31,i.status=S,B(i,p),0!==i.strstart&&(B(i,e.adler>>>16),B(i,65535&e.adler)),e.adler=1}if(69===i.status)if(i.gzhead.extra){for(a=i.pending;i.gzindex<(65535&i.gzhead.extra.length)&&(i.pending!==i.pending_buf_size||(i.gzhead.hcrc&&i.pending>a&&(e.adler=o(e.adler,i.pending_buf,i.pending-a,a)),N(e),a=i.pending,i.pending!==i.pending_buf_size));)O(i,255&i.gzhead.extra[i.gzindex]),i.gzindex++;i.gzhead.hcrc&&i.pending>a&&(e.adler=o(e.adler,i.pending_buf,i.pending-a,a)),i.gzindex===i.gzhead.extra.length&&(i.gzindex=0,i.status=73)}else i.status=73;if(73===i.status)if(i.gzhead.name){a=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>a&&(e.adler=o(e.adler,i.pending_buf,i.pending-a,a)),N(e),a=i.pending,i.pending===i.pending_buf_size)){l=1;break}l=i.gzindex<i.gzhead.name.length?255&i.gzhead.name.charCodeAt(i.gzindex++):0,O(i,l)}while(0!==l);i.gzhead.hcrc&&i.pending>a&&(e.adler=o(e.adler,i.pending_buf,i.pending-a,a)),0===l&&(i.gzindex=0,i.status=91)}else i.status=91;if(91===i.status)if(i.gzhead.comment){a=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>a&&(e.adler=o(e.adler,i.pending_buf,i.pending-a,a)),N(e),a=i.pending,i.pending===i.pending_buf_size)){l=1;break}l=i.gzindex<i.gzhead.comment.length?255&i.gzhead.comment.charCodeAt(i.gzindex++):0,O(i,l)}while(0!==l);i.gzhead.hcrc&&i.pending>a&&(e.adler=o(e.adler,i.pending_buf,i.pending-a,a)),0===l&&(i.status=103)}else i.status=103;if(103===i.status&&(i.gzhead.hcrc?(i.pending+2>i.pending_buf_size&&N(e),i.pending+2<=i.pending_buf_size&&(O(i,255&e.adler),O(i,e.adler>>8&255),e.adler=0,i.status=S)):i.status=S),0!==i.pending){if(N(e),0===e.avail_out)return i.last_flush=-1,d}else if(0===e.avail_in&&F(t)<=F(n)&&t!==h)return I(e,-5);if(666===i.status&&0!==e.avail_in)return I(e,-5);if(0!==e.avail_in||0!==i.lookahead||t!==c&&666!==i.status){var f=2===i.strategy?function(e,t){for(var n;;){if(0===e.lookahead&&(z(e),0===e.lookahead)){if(t===c)return T;break}if(e.match_length=0,n=s._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,n&&(L(e,!1),0===e.strm.avail_out))return T}return e.insert=0,t===h?(L(e,!0),0===e.strm.avail_out?M:P):e.last_lit&&(L(e,!1),0===e.strm.avail_out)?T:D}(i,t):3===i.strategy?function(e,t){for(var n,r,i,a,o=e.window;;){if(e.lookahead<=E){if(z(e),e.lookahead<=E&&t===c)return T;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=x&&0<e.strstart&&(r=o[i=e.strstart-1])===o[++i]&&r===o[++i]&&r===o[++i]){a=e.strstart+E;do{}while(r===o[++i]&&r===o[++i]&&r===o[++i]&&r===o[++i]&&r===o[++i]&&r===o[++i]&&r===o[++i]&&r===o[++i]&&i<a);e.match_length=E-(a-i),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=x?(n=s._tr_tally(e,1,e.match_length-x),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(n=s._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),n&&(L(e,!1),0===e.strm.avail_out))return T}return e.insert=0,t===h?(L(e,!0),0===e.strm.avail_out?M:P):e.last_lit&&(L(e,!1),0===e.strm.avail_out)?T:D}(i,t):r[i.level].func(i,t);if(f!==M&&f!==P||(i.status=666),f===T||f===M)return 0===e.avail_out&&(i.last_flush=-1),d;if(f===D&&(1===t?s._tr_align(i):5!==t&&(s._tr_stored_block(i,0,0,!1),3===t&&(R(i.head),0===i.lookahead&&(i.strstart=0,i.block_start=0,i.insert=0))),N(e),0===e.avail_out))return i.last_flush=-1,d}return t!==h?d:i.wrap<=0?1:(2===i.wrap?(O(i,255&e.adler),O(i,e.adler>>8&255),O(i,e.adler>>16&255),O(i,e.adler>>24&255),O(i,255&e.total_in),O(i,e.total_in>>8&255),O(i,e.total_in>>16&255),O(i,e.total_in>>24&255)):(B(i,e.adler>>>16),B(i,65535&e.adler)),N(e),0<i.wrap&&(i.wrap=-i.wrap),0!==i.pending?d:1)},n.deflateEnd=function(e){var t;return e&&e.state?(t=e.state.status)!==k&&69!==t&&73!==t&&91!==t&&103!==t&&t!==S&&666!==t?I(e,u):(e.state=null,t===S?I(e,-3):d):u},n.deflateSetDictionary=function(e,t){var n,r,s,o,l,c,h,p,f=t.length;if(!e||!e.state)return u;if(2===(o=(n=e.state).wrap)||1===o&&n.status!==k||n.lookahead)return u;for(1===o&&(e.adler=a(e.adler,t,f,0)),n.wrap=0,f>=n.w_size&&(0===o&&(R(n.head),n.strstart=0,n.block_start=0,n.insert=0),p=new i.Buf8(n.w_size),i.arraySet(p,t,f-n.w_size,n.w_size,0),t=p,f=n.w_size),l=e.avail_in,c=e.next_in,h=e.input,e.avail_in=f,e.next_in=0,e.input=t,z(n);n.lookahead>=x;){for(r=n.strstart,s=n.lookahead-(x-1);n.ins_h=(n.ins_h<<n.hash_shift^n.window[r+x-1])&n.hash_mask,n.prev[r&n.w_mask]=n.head[n.ins_h],n.head[n.ins_h]=r,r++,--s;);n.strstart=r,n.lookahead=x-1,z(n)}return n.strstart+=n.lookahead,n.block_start=n.strstart,n.insert=n.lookahead,n.lookahead=0,n.match_length=n.prev_length=x-1,n.match_available=0,e.next_in=c,e.input=h,e.avail_in=l,n.wrap=o,d},n.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./messages":51,"./trees":52}],47:[function(e,t,n){"use strict";t.exports=function(){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}},{}],48:[function(e,t,n){"use strict";t.exports=function(e,t){var n,r,i,s,a,o,l,c,h,d,u,p,f,m,g,v,y,b,w,_,A,x,E,C,k;n=e.state,r=e.next_in,C=e.input,i=r+(e.avail_in-5),s=e.next_out,k=e.output,a=s-(t-e.avail_out),o=s+(e.avail_out-257),l=n.dmax,c=n.wsize,h=n.whave,d=n.wnext,u=n.window,p=n.hold,f=n.bits,m=n.lencode,g=n.distcode,v=(1<<n.lenbits)-1,y=(1<<n.distbits)-1;e:do{f<15&&(p+=C[r++]<<f,f+=8,p+=C[r++]<<f,f+=8),b=m[p&v];t:for(;;){if(p>>>=w=b>>>24,f-=w,0===(w=b>>>16&255))k[s++]=65535&b;else{if(!(16&w)){if(0==(64&w)){b=m[(65535&b)+(p&(1<<w)-1)];continue t}if(32&w){n.mode=12;break e}e.msg="invalid literal/length code",n.mode=30;break e}_=65535&b,(w&=15)&&(f<w&&(p+=C[r++]<<f,f+=8),_+=p&(1<<w)-1,p>>>=w,f-=w),f<15&&(p+=C[r++]<<f,f+=8,p+=C[r++]<<f,f+=8),b=g[p&y];n:for(;;){if(p>>>=w=b>>>24,f-=w,!(16&(w=b>>>16&255))){if(0==(64&w)){b=g[(65535&b)+(p&(1<<w)-1)];continue n}e.msg="invalid distance code",n.mode=30;break e}if(A=65535&b,f<(w&=15)&&(p+=C[r++]<<f,(f+=8)<w&&(p+=C[r++]<<f,f+=8)),l<(A+=p&(1<<w)-1)){e.msg="invalid distance too far back",n.mode=30;break e}if(p>>>=w,f-=w,(w=s-a)<A){if(h<(w=A-w)&&n.sane){e.msg="invalid distance too far back",n.mode=30;break e}if(E=u,(x=0)===d){if(x+=c-w,w<_){for(_-=w;k[s++]=u[x++],--w;);x=s-A,E=k}}else if(d<w){if(x+=c+d-w,(w-=d)<_){for(_-=w;k[s++]=u[x++],--w;);if(x=0,d<_){for(_-=w=d;k[s++]=u[x++],--w;);x=s-A,E=k}}}else if(x+=d-w,w<_){for(_-=w;k[s++]=u[x++],--w;);x=s-A,E=k}for(;2<_;)k[s++]=E[x++],k[s++]=E[x++],k[s++]=E[x++],_-=3;_&&(k[s++]=E[x++],1<_&&(k[s++]=E[x++]))}else{for(x=s-A;k[s++]=k[x++],k[s++]=k[x++],k[s++]=k[x++],2<(_-=3););_&&(k[s++]=k[x++],1<_&&(k[s++]=k[x++]))}break}}break}}while(r<i&&s<o);r-=_=f>>3,p&=(1<<(f-=_<<3))-1,e.next_in=r,e.next_out=s,e.avail_in=r<i?i-r+5:5-(r-i),e.avail_out=s<o?o-s+257:257-(s-o),n.hold=p,n.bits=f}},{}],49:[function(e,t,n){"use strict";var r=e("../utils/common"),i=e("./adler32"),s=e("./crc32"),a=e("./inffast"),o=e("./inftrees"),l=1,c=2,h=0,d=-2,u=1,p=852,f=592;function m(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function g(){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 r.Buf16(320),this.work=new r.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function v(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=u,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new r.Buf32(p),t.distcode=t.distdyn=new r.Buf32(f),t.sane=1,t.back=-1,h):d}function y(e){var t;return e&&e.state?((t=e.state).wsize=0,t.whave=0,t.wnext=0,v(e)):d}function b(e,t){var n,r;return e&&e.state?(r=e.state,t<0?(n=0,t=-t):(n=1+(t>>4),t<48&&(t&=15)),t&&(t<8||15<t)?d:(null!==r.window&&r.wbits!==t&&(r.window=null),r.wrap=n,r.wbits=t,y(e))):d}function w(e,t){var n,r;return e?(r=new g,(e.state=r).window=null,(n=b(e,t))!==h&&(e.state=null),n):d}var _,A,x=!0;function E(e){if(x){var t;for(_=new r.Buf32(512),A=new r.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(o(l,e.lens,0,288,_,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;o(c,e.lens,0,32,A,0,e.work,{bits:5}),x=!1}e.lencode=_,e.lenbits=9,e.distcode=A,e.distbits=5}function C(e,t,n,i){var s,a=e.state;return null===a.window&&(a.wsize=1<<a.wbits,a.wnext=0,a.whave=0,a.window=new r.Buf8(a.wsize)),i>=a.wsize?(r.arraySet(a.window,t,n-a.wsize,a.wsize,0),a.wnext=0,a.whave=a.wsize):(i<(s=a.wsize-a.wnext)&&(s=i),r.arraySet(a.window,t,n-i,s,a.wnext),(i-=s)?(r.arraySet(a.window,t,n-i,i,0),a.wnext=i,a.whave=a.wsize):(a.wnext+=s,a.wnext===a.wsize&&(a.wnext=0),a.whave<a.wsize&&(a.whave+=s))),0}n.inflateReset=y,n.inflateReset2=b,n.inflateResetKeep=v,n.inflateInit=function(e){return w(e,15)},n.inflateInit2=w,n.inflate=function(e,t){var n,p,f,g,v,y,b,w,_,A,x,k,S,T,D,M,P,I,F,R,N,L,O,B,$=0,z=new r.Buf8(4),j=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return d;12===(n=e.state).mode&&(n.mode=13),v=e.next_out,f=e.output,b=e.avail_out,g=e.next_in,p=e.input,y=e.avail_in,w=n.hold,_=n.bits,A=y,x=b,L=h;e:for(;;)switch(n.mode){case u:if(0===n.wrap){n.mode=13;break}for(;_<16;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}if(2&n.wrap&&35615===w){z[n.check=0]=255&w,z[1]=w>>>8&255,n.check=s(n.check,z,2,0),_=w=0,n.mode=2;break}if(n.flags=0,n.head&&(n.head.done=!1),!(1&n.wrap)||(((255&w)<<8)+(w>>8))%31){e.msg="incorrect header check",n.mode=30;break}if(8!=(15&w)){e.msg="unknown compression method",n.mode=30;break}if(_-=4,N=8+(15&(w>>>=4)),0===n.wbits)n.wbits=N;else if(N>n.wbits){e.msg="invalid window size",n.mode=30;break}n.dmax=1<<N,e.adler=n.check=1,n.mode=512&w?10:12,_=w=0;break;case 2:for(;_<16;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}if(n.flags=w,8!=(255&n.flags)){e.msg="unknown compression method",n.mode=30;break}if(57344&n.flags){e.msg="unknown header flags set",n.mode=30;break}n.head&&(n.head.text=w>>8&1),512&n.flags&&(z[0]=255&w,z[1]=w>>>8&255,n.check=s(n.check,z,2,0)),_=w=0,n.mode=3;case 3:for(;_<32;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}n.head&&(n.head.time=w),512&n.flags&&(z[0]=255&w,z[1]=w>>>8&255,z[2]=w>>>16&255,z[3]=w>>>24&255,n.check=s(n.check,z,4,0)),_=w=0,n.mode=4;case 4:for(;_<16;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}n.head&&(n.head.xflags=255&w,n.head.os=w>>8),512&n.flags&&(z[0]=255&w,z[1]=w>>>8&255,n.check=s(n.check,z,2,0)),_=w=0,n.mode=5;case 5:if(1024&n.flags){for(;_<16;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}n.length=w,n.head&&(n.head.extra_len=w),512&n.flags&&(z[0]=255&w,z[1]=w>>>8&255,n.check=s(n.check,z,2,0)),_=w=0}else n.head&&(n.head.extra=null);n.mode=6;case 6:if(1024&n.flags&&(y<(k=n.length)&&(k=y),k&&(n.head&&(N=n.head.extra_len-n.length,n.head.extra||(n.head.extra=new Array(n.head.extra_len)),r.arraySet(n.head.extra,p,g,k,N)),512&n.flags&&(n.check=s(n.check,p,k,g)),y-=k,g+=k,n.length-=k),n.length))break e;n.length=0,n.mode=7;case 7:if(2048&n.flags){if(0===y)break e;for(k=0;N=p[g+k++],n.head&&N&&n.length<65536&&(n.head.name+=String.fromCharCode(N)),N&&k<y;);if(512&n.flags&&(n.check=s(n.check,p,k,g)),y-=k,g+=k,N)break e}else n.head&&(n.head.name=null);n.length=0,n.mode=8;case 8:if(4096&n.flags){if(0===y)break e;for(k=0;N=p[g+k++],n.head&&N&&n.length<65536&&(n.head.comment+=String.fromCharCode(N)),N&&k<y;);if(512&n.flags&&(n.check=s(n.check,p,k,g)),y-=k,g+=k,N)break e}else n.head&&(n.head.comment=null);n.mode=9;case 9:if(512&n.flags){for(;_<16;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}if(w!==(65535&n.check)){e.msg="header crc mismatch",n.mode=30;break}_=w=0}n.head&&(n.head.hcrc=n.flags>>9&1,n.head.done=!0),e.adler=n.check=0,n.mode=12;break;case 10:for(;_<32;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}e.adler=n.check=m(w),_=w=0,n.mode=11;case 11:if(0===n.havedict)return e.next_out=v,e.avail_out=b,e.next_in=g,e.avail_in=y,n.hold=w,n.bits=_,2;e.adler=n.check=1,n.mode=12;case 12:if(5===t||6===t)break e;case 13:if(n.last){w>>>=7&_,_-=7&_,n.mode=27;break}for(;_<3;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}switch(n.last=1&w,_-=1,3&(w>>>=1)){case 0:n.mode=14;break;case 1:if(E(n),n.mode=20,6!==t)break;w>>>=2,_-=2;break e;case 2:n.mode=17;break;case 3:e.msg="invalid block type",n.mode=30}w>>>=2,_-=2;break;case 14:for(w>>>=7&_,_-=7&_;_<32;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}if((65535&w)!=(w>>>16^65535)){e.msg="invalid stored block lengths",n.mode=30;break}if(n.length=65535&w,_=w=0,n.mode=15,6===t)break e;case 15:n.mode=16;case 16:if(k=n.length){if(y<k&&(k=y),b<k&&(k=b),0===k)break e;r.arraySet(f,p,g,k,v),y-=k,g+=k,b-=k,v+=k,n.length-=k;break}n.mode=12;break;case 17:for(;_<14;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}if(n.nlen=257+(31&w),w>>>=5,_-=5,n.ndist=1+(31&w),w>>>=5,_-=5,n.ncode=4+(15&w),w>>>=4,_-=4,286<n.nlen||30<n.ndist){e.msg="too many length or distance symbols",n.mode=30;break}n.have=0,n.mode=18;case 18:for(;n.have<n.ncode;){for(;_<3;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}n.lens[j[n.have++]]=7&w,w>>>=3,_-=3}for(;n.have<19;)n.lens[j[n.have++]]=0;if(n.lencode=n.lendyn,n.lenbits=7,O={bits:n.lenbits},L=o(0,n.lens,0,19,n.lencode,0,n.work,O),n.lenbits=O.bits,L){e.msg="invalid code lengths set",n.mode=30;break}n.have=0,n.mode=19;case 19:for(;n.have<n.nlen+n.ndist;){for(;M=($=n.lencode[w&(1<<n.lenbits)-1])>>>16&255,P=65535&$,!((D=$>>>24)<=_);){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}if(P<16)w>>>=D,_-=D,n.lens[n.have++]=P;else{if(16===P){for(B=D+2;_<B;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}if(w>>>=D,_-=D,0===n.have){e.msg="invalid bit length repeat",n.mode=30;break}N=n.lens[n.have-1],k=3+(3&w),w>>>=2,_-=2}else if(17===P){for(B=D+3;_<B;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}_-=D,N=0,k=3+(7&(w>>>=D)),w>>>=3,_-=3}else{for(B=D+7;_<B;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}_-=D,N=0,k=11+(127&(w>>>=D)),w>>>=7,_-=7}if(n.have+k>n.nlen+n.ndist){e.msg="invalid bit length repeat",n.mode=30;break}for(;k--;)n.lens[n.have++]=N}}if(30===n.mode)break;if(0===n.lens[256]){e.msg="invalid code -- missing end-of-block",n.mode=30;break}if(n.lenbits=9,O={bits:n.lenbits},L=o(l,n.lens,0,n.nlen,n.lencode,0,n.work,O),n.lenbits=O.bits,L){e.msg="invalid literal/lengths set",n.mode=30;break}if(n.distbits=6,n.distcode=n.distdyn,O={bits:n.distbits},L=o(c,n.lens,n.nlen,n.ndist,n.distcode,0,n.work,O),n.distbits=O.bits,L){e.msg="invalid distances set",n.mode=30;break}if(n.mode=20,6===t)break e;case 20:n.mode=21;case 21:if(6<=y&&258<=b){e.next_out=v,e.avail_out=b,e.next_in=g,e.avail_in=y,n.hold=w,n.bits=_,a(e,x),v=e.next_out,f=e.output,b=e.avail_out,g=e.next_in,p=e.input,y=e.avail_in,w=n.hold,_=n.bits,12===n.mode&&(n.back=-1);break}for(n.back=0;M=($=n.lencode[w&(1<<n.lenbits)-1])>>>16&255,P=65535&$,!((D=$>>>24)<=_);){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}if(M&&0==(240&M)){for(I=D,F=M,R=P;M=($=n.lencode[R+((w&(1<<I+F)-1)>>I)])>>>16&255,P=65535&$,!(I+(D=$>>>24)<=_);){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}w>>>=I,_-=I,n.back+=I}if(w>>>=D,_-=D,n.back+=D,n.length=P,0===M){n.mode=26;break}if(32&M){n.back=-1,n.mode=12;break}if(64&M){e.msg="invalid literal/length code",n.mode=30;break}n.extra=15&M,n.mode=22;case 22:if(n.extra){for(B=n.extra;_<B;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}n.length+=w&(1<<n.extra)-1,w>>>=n.extra,_-=n.extra,n.back+=n.extra}n.was=n.length,n.mode=23;case 23:for(;M=($=n.distcode[w&(1<<n.distbits)-1])>>>16&255,P=65535&$,!((D=$>>>24)<=_);){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}if(0==(240&M)){for(I=D,F=M,R=P;M=($=n.distcode[R+((w&(1<<I+F)-1)>>I)])>>>16&255,P=65535&$,!(I+(D=$>>>24)<=_);){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}w>>>=I,_-=I,n.back+=I}if(w>>>=D,_-=D,n.back+=D,64&M){e.msg="invalid distance code",n.mode=30;break}n.offset=P,n.extra=15&M,n.mode=24;case 24:if(n.extra){for(B=n.extra;_<B;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}n.offset+=w&(1<<n.extra)-1,w>>>=n.extra,_-=n.extra,n.back+=n.extra}if(n.offset>n.dmax){e.msg="invalid distance too far back",n.mode=30;break}n.mode=25;case 25:if(0===b)break e;if(k=x-b,n.offset>k){if((k=n.offset-k)>n.whave&&n.sane){e.msg="invalid distance too far back",n.mode=30;break}S=k>n.wnext?(k-=n.wnext,n.wsize-k):n.wnext-k,k>n.length&&(k=n.length),T=n.window}else T=f,S=v-n.offset,k=n.length;for(b<k&&(k=b),b-=k,n.length-=k;f[v++]=T[S++],--k;);0===n.length&&(n.mode=21);break;case 26:if(0===b)break e;f[v++]=n.length,b--,n.mode=21;break;case 27:if(n.wrap){for(;_<32;){if(0===y)break e;y--,w|=p[g++]<<_,_+=8}if(x-=b,e.total_out+=x,n.total+=x,x&&(e.adler=n.check=n.flags?s(n.check,f,x,v-x):i(n.check,f,x,v-x)),x=b,(n.flags?w:m(w))!==n.check){e.msg="incorrect data check",n.mode=30;break}_=w=0}n.mode=28;case 28:if(n.wrap&&n.flags){for(;_<32;){if(0===y)break e;y--,w+=p[g++]<<_,_+=8}if(w!==(4294967295&n.total)){e.msg="incorrect length check",n.mode=30;break}_=w=0}n.mode=29;case 29:L=1;break e;case 30:L=-3;break e;case 31:return-4;default:return d}return e.next_out=v,e.avail_out=b,e.next_in=g,e.avail_in=y,n.hold=w,n.bits=_,(n.wsize||x!==e.avail_out&&n.mode<30&&(n.mode<27||4!==t))&&C(e,e.output,e.next_out,x-e.avail_out)?(n.mode=31,-4):(A-=e.avail_in,x-=e.avail_out,e.total_in+=A,e.total_out+=x,n.total+=x,n.wrap&&x&&(e.adler=n.check=n.flags?s(n.check,f,x,e.next_out-x):i(n.check,f,x,e.next_out-x)),e.data_type=n.bits+(n.last?64:0)+(12===n.mode?128:0)+(20===n.mode||15===n.mode?256:0),(0==A&&0===x||4===t)&&L===h&&(L=-5),L)},n.inflateEnd=function(e){if(!e||!e.state)return d;var t=e.state;return t.window&&(t.window=null),e.state=null,h},n.inflateGetHeader=function(e,t){var n;return e&&e.state?0==(2&(n=e.state).wrap)?d:((n.head=t).done=!1,h):d},n.inflateSetDictionary=function(e,t){var n,r=t.length;return e&&e.state?0!==(n=e.state).wrap&&11!==n.mode?d:11===n.mode&&i(1,t,r,0)!==n.check?-3:C(e,t,r,r)?(n.mode=31,-4):(n.havedict=1,h):d},n.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./inffast":48,"./inftrees":50}],50:[function(e,t,n){"use strict";var r=e("../utils/common"),i=[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],s=[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],a=[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],o=[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];t.exports=function(e,t,n,l,c,h,d,u){var p,f,m,g,v,y,b,w,_,A=u.bits,x=0,E=0,C=0,k=0,S=0,T=0,D=0,M=0,P=0,I=0,F=null,R=0,N=new r.Buf16(16),L=new r.Buf16(16),O=null,B=0;for(x=0;x<=15;x++)N[x]=0;for(E=0;E<l;E++)N[t[n+E]]++;for(S=A,k=15;1<=k&&0===N[k];k--);if(k<S&&(S=k),0===k)return c[h++]=20971520,c[h++]=20971520,u.bits=1,0;for(C=1;C<k&&0===N[C];C++);for(S<C&&(S=C),x=M=1;x<=15;x++)if(M<<=1,(M-=N[x])<0)return-1;if(0<M&&(0===e||1!==k))return-1;for(L[1]=0,x=1;x<15;x++)L[x+1]=L[x]+N[x];for(E=0;E<l;E++)0!==t[n+E]&&(d[L[t[n+E]]++]=E);if(y=0===e?(F=O=d,19):1===e?(F=i,R-=257,O=s,B-=257,256):(F=a,O=o,-1),x=C,v=h,D=E=I=0,m=-1,g=(P=1<<(T=S))-1,1===e&&852<P||2===e&&592<P)return 1;for(;;){for(b=x-D,_=d[E]<y?(w=0,d[E]):d[E]>y?(w=O[B+d[E]],F[R+d[E]]):(w=96,0),p=1<<x-D,C=f=1<<T;c[v+(I>>D)+(f-=p)]=b<<24|w<<16|_,0!==f;);for(p=1<<x-1;I&p;)p>>=1;if(0!==p?(I&=p-1,I+=p):I=0,E++,0==--N[x]){if(x===k)break;x=t[n+d[E]]}if(S<x&&(I&g)!==m){for(0===D&&(D=S),v+=C,M=1<<(T=x-D);T+D<k&&!((M-=N[T+D])<=0);)T++,M<<=1;if(P+=1<<T,1===e&&852<P||2===e&&592<P)return 1;c[m=I&g]=S<<24|T<<16|v-h}}return 0!==I&&(c[v+I]=x-D<<24|64<<16),u.bits=S,0}},{"../utils/common":41}],51:[function(e,t,n){"use strict";t.exports={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"}},{}],52:[function(e,t,n){"use strict";var r=e("../utils/common"),i=0,s=1;function a(e){for(var t=e.length;0<=--t;)e[t]=0}var o=0,l=29,c=256,h=c+1+l,d=30,u=19,p=2*h+1,f=15,m=16,g=7,v=256,y=16,b=17,w=18,_=[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],A=[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],x=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],E=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],C=new Array(2*(h+2));a(C);var k=new Array(2*d);a(k);var S=new Array(512);a(S);var T=new Array(256);a(T);var D=new Array(l);a(D);var M,P,I,F=new Array(d);function R(e,t,n,r,i){this.static_tree=e,this.extra_bits=t,this.extra_base=n,this.elems=r,this.max_length=i,this.has_stree=e&&e.length}function N(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function L(e){return e<256?S[e]:S[256+(e>>>7)]}function O(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255}function B(e,t,n){e.bi_valid>m-n?(e.bi_buf|=t<<e.bi_valid&65535,O(e,e.bi_buf),e.bi_buf=t>>m-e.bi_valid,e.bi_valid+=n-m):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=n)}function $(e,t,n){B(e,n[2*t],n[2*t+1])}function z(e,t){for(var n=0;n|=1&e,e>>>=1,n<<=1,0<--t;);return n>>>1}function j(e,t,n){var r,i,s=new Array(f+1),a=0;for(r=1;r<=f;r++)s[r]=a=a+n[r-1]<<1;for(i=0;i<=t;i++){var o=e[2*i+1];0!==o&&(e[2*i]=z(s[o]++,o))}}function U(e){var t;for(t=0;t<h;t++)e.dyn_ltree[2*t]=0;for(t=0;t<d;t++)e.dyn_dtree[2*t]=0;for(t=0;t<u;t++)e.bl_tree[2*t]=0;e.dyn_ltree[2*v]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}function H(e){8<e.bi_valid?O(e,e.bi_buf):0<e.bi_valid&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}function V(e,t,n,r){var i=2*t,s=2*n;return e[i]<e[s]||e[i]===e[s]&&r[t]<=r[n]}function q(e,t,n){for(var r=e.heap[n],i=n<<1;i<=e.heap_len&&(i<e.heap_len&&V(t,e.heap[i+1],e.heap[i],e.depth)&&i++,!V(t,r,e.heap[i],e.depth));)e.heap[n]=e.heap[i],n=i,i<<=1;e.heap[n]=r}function W(e,t,n){var r,i,s,a,o=0;if(0!==e.last_lit)for(;r=e.pending_buf[e.d_buf+2*o]<<8|e.pending_buf[e.d_buf+2*o+1],i=e.pending_buf[e.l_buf+o],o++,0===r?$(e,i,t):($(e,(s=T[i])+c+1,t),0!==(a=_[s])&&B(e,i-=D[s],a),$(e,s=L(--r),n),0!==(a=A[s])&&B(e,r-=F[s],a)),o<e.last_lit;);$(e,v,t)}function G(e,t){var n,r,i,s=t.dyn_tree,a=t.stat_desc.static_tree,o=t.stat_desc.has_stree,l=t.stat_desc.elems,c=-1;for(e.heap_len=0,e.heap_max=p,n=0;n<l;n++)0!==s[2*n]?(e.heap[++e.heap_len]=c=n,e.depth[n]=0):s[2*n+1]=0;for(;e.heap_len<2;)s[2*(i=e.heap[++e.heap_len]=c<2?++c:0)]=1,e.depth[i]=0,e.opt_len--,o&&(e.static_len-=a[2*i+1]);for(t.max_code=c,n=e.heap_len>>1;1<=n;n--)q(e,s,n);for(i=l;n=e.heap[1],e.heap[1]=e.heap[e.heap_len--],q(e,s,1),r=e.heap[1],e.heap[--e.heap_max]=n,e.heap[--e.heap_max]=r,s[2*i]=s[2*n]+s[2*r],e.depth[i]=(e.depth[n]>=e.depth[r]?e.depth[n]:e.depth[r])+1,s[2*n+1]=s[2*r+1]=i,e.heap[1]=i++,q(e,s,1),2<=e.heap_len;);e.heap[--e.heap_max]=e.heap[1],function(e,t){var n,r,i,s,a,o,l=t.dyn_tree,c=t.max_code,h=t.stat_desc.static_tree,d=t.stat_desc.has_stree,u=t.stat_desc.extra_bits,m=t.stat_desc.extra_base,g=t.stat_desc.max_length,v=0;for(s=0;s<=f;s++)e.bl_count[s]=0;for(l[2*e.heap[e.heap_max]+1]=0,n=e.heap_max+1;n<p;n++)g<(s=l[2*l[2*(r=e.heap[n])+1]+1]+1)&&(s=g,v++),l[2*r+1]=s,c<r||(e.bl_count[s]++,a=0,m<=r&&(a=u[r-m]),o=l[2*r],e.opt_len+=o*(s+a),d&&(e.static_len+=o*(h[2*r+1]+a)));if(0!==v){do{for(s=g-1;0===e.bl_count[s];)s--;e.bl_count[s]--,e.bl_count[s+1]+=2,e.bl_count[g]--,v-=2}while(0<v);for(s=g;0!==s;s--)for(r=e.bl_count[s];0!==r;)c<(i=e.heap[--n])||(l[2*i+1]!==s&&(e.opt_len+=(s-l[2*i+1])*l[2*i],l[2*i+1]=s),r--)}}(e,t),j(s,c,e.bl_count)}function K(e,t,n){var r,i,s=-1,a=t[1],o=0,l=7,c=4;for(0===a&&(l=138,c=3),t[2*(n+1)+1]=65535,r=0;r<=n;r++)i=a,a=t[2*(r+1)+1],++o<l&&i===a||(o<c?e.bl_tree[2*i]+=o:0!==i?(i!==s&&e.bl_tree[2*i]++,e.bl_tree[2*y]++):o<=10?e.bl_tree[2*b]++:e.bl_tree[2*w]++,s=i,c=(o=0)===a?(l=138,3):i===a?(l=6,3):(l=7,4))}function X(e,t,n){var r,i,s=-1,a=t[1],o=0,l=7,c=4;for(0===a&&(l=138,c=3),r=0;r<=n;r++)if(i=a,a=t[2*(r+1)+1],!(++o<l&&i===a)){if(o<c)for(;$(e,i,e.bl_tree),0!=--o;);else 0!==i?(i!==s&&($(e,i,e.bl_tree),o--),$(e,y,e.bl_tree),B(e,o-3,2)):o<=10?($(e,b,e.bl_tree),B(e,o-3,3)):($(e,w,e.bl_tree),B(e,o-11,7));s=i,c=(o=0)===a?(l=138,3):i===a?(l=6,3):(l=7,4)}}a(F);var Y=!1;function Z(e,t,n,i){B(e,(o<<1)+(i?1:0),3),function(e,t,n,i){H(e),i&&(O(e,n),O(e,~n)),r.arraySet(e.pending_buf,e.window,t,n,e.pending),e.pending+=n}(e,t,n,!0)}n._tr_init=function(e){Y||(function(){var e,t,n,r,i,s=new Array(f+1);for(r=n=0;r<l-1;r++)for(D[r]=n,e=0;e<1<<_[r];e++)T[n++]=r;for(T[n-1]=r,r=i=0;r<16;r++)for(F[r]=i,e=0;e<1<<A[r];e++)S[i++]=r;for(i>>=7;r<d;r++)for(F[r]=i<<7,e=0;e<1<<A[r]-7;e++)S[256+i++]=r;for(t=0;t<=f;t++)s[t]=0;for(e=0;e<=143;)C[2*e+1]=8,e++,s[8]++;for(;e<=255;)C[2*e+1]=9,e++,s[9]++;for(;e<=279;)C[2*e+1]=7,e++,s[7]++;for(;e<=287;)C[2*e+1]=8,e++,s[8]++;for(j(C,h+1,s),e=0;e<d;e++)k[2*e+1]=5,k[2*e]=z(e,5);M=new R(C,_,c+1,h,f),P=new R(k,A,0,d,f),I=new R(new Array(0),x,0,u,g)}(),Y=!0),e.l_desc=new N(e.dyn_ltree,M),e.d_desc=new N(e.dyn_dtree,P),e.bl_desc=new N(e.bl_tree,I),e.bi_buf=0,e.bi_valid=0,U(e)},n._tr_stored_block=Z,n._tr_flush_block=function(e,t,n,r){var a,o,l=0;0<e.level?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t,n=4093624447;for(t=0;t<=31;t++,n>>>=1)if(1&n&&0!==e.dyn_ltree[2*t])return i;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return s;for(t=32;t<c;t++)if(0!==e.dyn_ltree[2*t])return s;return i}(e)),G(e,e.l_desc),G(e,e.d_desc),l=function(e){var t;for(K(e,e.dyn_ltree,e.l_desc.max_code),K(e,e.dyn_dtree,e.d_desc.max_code),G(e,e.bl_desc),t=u-1;3<=t&&0===e.bl_tree[2*E[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}(e),a=e.opt_len+3+7>>>3,(o=e.static_len+3+7>>>3)<=a&&(a=o)):a=o=n+5,n+4<=a&&-1!==t?Z(e,t,n,r):4===e.strategy||o===a?(B(e,2+(r?1:0),3),W(e,C,k)):(B(e,4+(r?1:0),3),function(e,t,n,r){var i;for(B(e,t-257,5),B(e,n-1,5),B(e,r-4,4),i=0;i<r;i++)B(e,e.bl_tree[2*E[i]+1],3);X(e,e.dyn_ltree,t-1),X(e,e.dyn_dtree,n-1)}(e,e.l_desc.max_code+1,e.d_desc.max_code+1,l+1),W(e,e.dyn_ltree,e.dyn_dtree)),U(e),r&&H(e)},n._tr_tally=function(e,t,n){return e.pending_buf[e.d_buf+2*e.last_lit]=t>>>8&255,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&n,e.last_lit++,0===t?e.dyn_ltree[2*n]++:(e.matches++,t--,e.dyn_ltree[2*(T[n]+c+1)]++,e.dyn_dtree[2*L(t)]++),e.last_lit===e.lit_bufsize-1},n._tr_align=function(e){B(e,2,3),$(e,v,C),function(e){16===e.bi_valid?(O(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):8<=e.bi_valid&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}(e)}},{"../utils/common":41}],53:[function(e,t,n){"use strict";t.exports=function(){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}},{}],54:[function(e,t,n){(function(e){!function(e,t){"use strict";if(!e.setImmediate){var n,r,i,s,a=1,o={},l=!1,c=e.document,h=Object.getPrototypeOf&&Object.getPrototypeOf(e);h=h&&h.setTimeout?h:e,n="[object process]"==={}.toString.call(e.process)?function(e){process.nextTick(function(){u(e)})}:function(){if(e.postMessage&&!e.importScripts){var t=!0,n=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=n,t}}()?(s="setImmediate$"+Math.random()+"$",e.addEventListener?e.addEventListener("message",p,!1):e.attachEvent("onmessage",p),function(t){e.postMessage(s+t,"*")}):e.MessageChannel?((i=new MessageChannel).port1.onmessage=function(e){u(e.data)},function(e){i.port2.postMessage(e)}):c&&"onreadystatechange"in c.createElement("script")?(r=c.documentElement,function(e){var t=c.createElement("script");t.onreadystatechange=function(){u(e),t.onreadystatechange=null,r.removeChild(t),t=null},r.appendChild(t)}):function(e){setTimeout(u,0,e)},h.setImmediate=function(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var i={callback:e,args:t};return o[a]=i,n(a),a++},h.clearImmediate=d}function d(e){delete o[e]}function u(e){if(l)setTimeout(u,0,e);else{var n=o[e];if(n){l=!0;try{!function(e){var n=e.callback,r=e.args;switch(r.length){case 0:n();break;case 1:n(r[0]);break;case 2:n(r[0],r[1]);break;case 3:n(r[0],r[1],r[2]);break;default:n.apply(t,r)}}(n)}finally{d(e),l=!1}}}}function p(t){t.source===e&&"string"==typeof t.data&&0===t.data.indexOf(s)&&u(+t.data.slice(s.length))}}("undefined"==typeof self?void 0===e?this:e:self)}).call(this,"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}]},{},[10])(10)},64579(e,t,n){var r=n(78913),i=/^\s+/;e.exports=function(e){return e?e.slice(0,r(e)+1).replace(i,""):e}},78913(e){var t=/\s/;e.exports=function(e){for(var n=e.length;n--&&t.test(e.charAt(n)););return n}},95600(e,t,n){var r=n(2316),i=n(93375),s=n(2899),a=Math.max,o=Math.min;e.exports=function(e,t,n){var l,c,h,d,u,p,f=0,m=!1,g=!1,v=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function y(t){var n=l,r=c;return l=c=void 0,f=t,d=e.apply(r,n)}function b(e){var n=e-p;return void 0===p||n>=t||n<0||g&&e-f>=h}function w(){var e=i();if(b(e))return _(e);u=setTimeout(w,function(e){var n=t-(e-p);return g?o(n,h-(e-f)):n}(e))}function _(e){return u=void 0,v&&l?y(e):(l=c=void 0,d)}function A(){var e=i(),n=b(e);if(l=arguments,c=this,p=e,n){if(void 0===u)return function(e){return f=e,u=setTimeout(w,t),m?y(e):d}(p);if(g)return clearTimeout(u),u=setTimeout(w,t),y(p)}return void 0===u&&(u=setTimeout(w,t)),d}return t=s(t)||0,r(n)&&(m=!!n.leading,h=(g="maxWait"in n)?a(s(n.maxWait)||0,t):h,v="trailing"in n?!!n.trailing:v),A.cancel=function(){void 0!==u&&clearTimeout(u),f=0,l=p=c=u=void 0},A.flush=function(){return void 0===u?d:_(i())},A}},93375(e,t,n){var r=n(36382);e.exports=function(){return r.Date.now()}},98771(e,t,n){var r=n(95600),i=n(2316);e.exports=function(e,t,n){var s=!0,a=!0;if("function"!=typeof e)throw new TypeError("Expected a function");return i(n)&&(s="leading"in n?!!n.leading:s,a="trailing"in n?!!n.trailing:a),r(e,t,{leading:s,maxWait:t,trailing:a})}},2899(e,t,n){var r=n(64579),i=n(2316),s=n(90931),a=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,l=/^0o[0-7]+$/i,c=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(s(e))return NaN;if(i(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=i(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=r(e);var n=o.test(e);return n||l.test(e)?c(e.slice(2),n?2:8):a.test(e)?NaN:+e}},57325(e,t,n){var r=n(20907),i=0;e.exports=function(e){var t=++i;return r(e)+t}},76837(e,t,n){"use strict";function r(e,t,n,r,i,s,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=a}const i={};["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"].forEach(e=>{i[e]=new r(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(e=>{let[t,n]=e;i[t]=new r(t,1,!1,n,null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(e=>{i[e]=new r(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(e=>{i[e]=new r(e,2,!1,e,null,!1,!1)}),["allowFullScreen","async","autoFocus","autoPlay","controls","default","defer","disabled","disablePictureInPicture","disableRemotePlayback","formNoValidate","hidden","loop","noModule","noValidate","open","playsInline","readOnly","required","reversed","scoped","seamless","itemScope"].forEach(e=>{i[e]=new r(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(e=>{i[e]=new r(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(e=>{i[e]=new r(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(e=>{i[e]=new r(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(e=>{i[e]=new r(e,5,!1,e.toLowerCase(),null,!1,!1)});const s=/[\-\:]([a-z])/g,a=e=>e[1].toUpperCase();["accent-height","alignment-baseline","arabic-form","baseline-shift","cap-height","clip-path","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","dominant-baseline","enable-background","fill-opacity","fill-rule","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","horiz-adv-x","horiz-origin-x","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","overline-position","overline-thickness","paint-order","panose-1","pointer-events","rendering-intent","shape-rendering","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-rendering","underline-position","underline-thickness","unicode-bidi","unicode-range","units-per-em","v-alphabetic","v-hanging","v-ideographic","v-mathematical","vector-effect","vert-adv-y","vert-origin-x","vert-origin-y","word-spacing","writing-mode","xmlns:xlink","x-height"].forEach(e=>{const t=e.replace(s,a);i[t]=new r(t,1,!1,e,null,!1,!1)}),["xlink:actuate","xlink:arcrole","xlink:role","xlink:show","xlink:title","xlink:type"].forEach(e=>{const t=e.replace(s,a);i[t]=new r(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(e=>{const t=e.replace(s,a);i[t]=new r(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(e=>{i[e]=new r(e,1,!1,e.toLowerCase(),null,!1,!1)});i.xlinkHref=new r("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(e=>{i[e]=new r(e,1,!1,e.toLowerCase(),null,!0,!0)});const{CAMELCASE:o,SAME:l,possibleStandardNames:c}=n(45858),h=RegExp.prototype.test.bind(new RegExp("^(data|aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$")),d=Object.keys(c).reduce((e,t)=>{const n=c[t];return n===l?e[t]=t:n===o?e[t.toLowerCase()]=t:e[t]=n,e},{});t.BOOLEAN=3,t.BOOLEANISH_STRING=2,t.NUMERIC=5,t.OVERLOADED_BOOLEAN=4,t.POSITIVE_NUMERIC=6,t.RESERVED=0,t.STRING=1,t.getPropertyInfo=function(e){return i.hasOwnProperty(e)?i[e]:null},t.isCustomAttribute=h,t.possibleStandardNames=d},45858(e,t){t.SAME=0;t.CAMELCASE=1,t.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":"acceptCharset",accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:"className",classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:"htmlFor",form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":"httpEquiv",icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":"accentHeight",accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":"alignmentBaseline",allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":"arabicForm",ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":"baselineShift",baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":"capHeight",clip:0,clipPath:1,"clip-path":"clipPath",clipPathUnits:1,clipRule:1,"clip-rule":"clipRule",color:0,colorInterpolation:1,"color-interpolation":"colorInterpolation",colorInterpolationFilters:1,"color-interpolation-filters":"colorInterpolationFilters",colorProfile:1,"color-profile":"colorProfile",colorRendering:1,"color-rendering":"colorRendering",contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":"dominantBaseline",dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":"enableBackground",end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":"fillOpacity",fillRule:1,"fill-rule":"fillRule",filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":"floodOpacity",floodColor:1,"flood-color":"floodColor",focusable:0,fontFamily:1,"font-family":"fontFamily",fontSize:1,"font-size":"fontSize",fontSizeAdjust:1,"font-size-adjust":"fontSizeAdjust",fontStretch:1,"font-stretch":"fontStretch",fontStyle:1,"font-style":"fontStyle",fontVariant:1,"font-variant":"fontVariant",fontWeight:1,"font-weight":"fontWeight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":"glyphName",glyphOrientationHorizontal:1,"glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphOrientationVertical:1,"glyph-orientation-vertical":"glyphOrientationVertical",glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":"horizAdvX",horizOriginX:1,"horiz-origin-x":"horizOriginX",ideographic:0,imageRendering:1,"image-rendering":"imageRendering",in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":"letterSpacing",lightingColor:1,"lighting-color":"lightingColor",limitingConeAngle:1,local:0,markerEnd:1,"marker-end":"markerEnd",markerHeight:1,markerMid:1,"marker-mid":"markerMid",markerStart:1,"marker-start":"markerStart",markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":"overlinePosition",overlineThickness:1,"overline-thickness":"overlineThickness",paintOrder:1,"paint-order":"paintOrder",panose1:0,"panose-1":"panose1",pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":"pointerEvents",points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":"renderingIntent",repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":"shapeRendering",slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":"stopColor",stopOpacity:1,"stop-opacity":"stopOpacity",strikethroughPosition:1,"strikethrough-position":"strikethroughPosition",strikethroughThickness:1,"strikethrough-thickness":"strikethroughThickness",string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":"strokeDasharray",strokeDashoffset:1,"stroke-dashoffset":"strokeDashoffset",strokeLinecap:1,"stroke-linecap":"strokeLinecap",strokeLinejoin:1,"stroke-linejoin":"strokeLinejoin",strokeMiterlimit:1,"stroke-miterlimit":"strokeMiterlimit",strokeWidth:1,"stroke-width":"strokeWidth",strokeOpacity:1,"stroke-opacity":"strokeOpacity",suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":"textAnchor",textDecoration:1,"text-decoration":"textDecoration",textLength:1,textRendering:1,"text-rendering":"textRendering",to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":"underlinePosition",underlineThickness:1,"underline-thickness":"underlineThickness",unicode:0,unicodeBidi:1,"unicode-bidi":"unicodeBidi",unicodeRange:1,"unicode-range":"unicodeRange",unitsPerEm:1,"units-per-em":"unitsPerEm",unselectable:0,vAlphabetic:1,"v-alphabetic":"vAlphabetic",values:0,vectorEffect:1,"vector-effect":"vectorEffect",version:0,vertAdvY:1,"vert-adv-y":"vertAdvY",vertOriginX:1,"vert-origin-x":"vertOriginX",vertOriginY:1,"vert-origin-y":"vertOriginY",vHanging:1,"v-hanging":"vHanging",vIdeographic:1,"v-ideographic":"vIdeographic",viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":"vMathematical",vocab:0,widths:0,wordSpacing:1,"word-spacing":"wordSpacing",writingMode:1,"writing-mode":"writingMode",x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":"xHeight",xlinkActuate:1,"xlink:actuate":"xlinkActuate",xlinkArcrole:1,"xlink:arcrole":"xlinkArcrole",xlinkHref:1,"xlink:href":"xlinkHref",xlinkRole:1,"xlink:role":"xlinkRole",xlinkShow:1,"xlink:show":"xlinkShow",xlinkTitle:1,"xlink:title":"xlinkTitle",xlinkType:1,"xlink:type":"xlinkType",xmlBase:1,"xml:base":"xmlBase",xmlLang:1,"xml:lang":"xmlLang",xmlns:0,"xml:space":"xmlSpace",xmlnsXlink:1,"xmlns:xlink":"xmlnsXlink",xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1}},74935(e,t,n){"use strict";var r=n(94922),i=Symbol.for("react.element"),s=Symbol.for("react.fragment"),a=Object.prototype.hasOwnProperty,o=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};function c(e,t,n){var r,s={},c=null,h=null;for(r in void 0!==n&&(c=""+n),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(h=t.ref),t)a.call(t,r)&&!l.hasOwnProperty(r)&&(s[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===s[r]&&(s[r]=t[r]);return{$$typeof:i,type:e,key:c,ref:h,props:s,_owner:o.current}}t.Fragment=s,t.jsx=c,t.jsxs=c},89261(e,t,n){"use strict";e.exports=n(74935)},71148(e,t,n){"use strict";var r=(this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(n(53284)),i=n(69280);function s(e,t){var n={};return e&&"string"===typeof e?((0,r.default)(e,function(e,r){e&&r&&(n[(0,i.camelCase)(e,t)]=r)}),n):n}s.default=s,e.exports=s},69280(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.camelCase=void 0;var n=/^--[a-zA-Z0-9_-]+$/,r=/-([a-z])/g,i=/^[^-]+$/,s=/^-(webkit|moz|ms|o|khtml)-/,a=/^-(ms)-/,o=function(e,t){return t.toUpperCase()},l=function(e,t){return"".concat(t,"-")};t.camelCase=function(e,t){return void 0===t&&(t={}),function(e){return!e||i.test(e)||n.test(e)}(e)?e:(e=e.toLowerCase(),(e=t.reactCompat?e.replace(a,l):e.replace(s,l)).replace(r,o))}},53284(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let n=null;if(!e||"string"!==typeof e)return n;const r=(0,i.default)(e),s="function"===typeof t;return r.forEach(e=>{if("declaration"!==e.type)return;const{property:r,value:i}=e;s?t(r,i,e):i&&(n=n||{},n[r]=i)}),n};const i=r(n(52808))},98677(e){"use strict";var t=function(){};e.exports=t},9062(){},75282(){},55351(){},70011(){},87821(){},54159(e,t){var n;!function(){"use strict";var r={}.hasOwnProperty;function i(){for(var e="",t=0;t<arguments.length;t++){var n=arguments[t];n&&(e=a(e,s(n)))}return e}function s(e){if("string"===typeof e||"number"===typeof e)return e;if("object"!==typeof e)return"";if(Array.isArray(e))return i.apply(null,e);if(e.toString!==Object.prototype.toString&&!e.toString.toString().includes("[native code]"))return e.toString();var t="";for(var n in e)r.call(e,n)&&e[n]&&(t=a(t,n));return t}function a(e,t){return t?e?e+" "+t:e+t:e}e.exports?(i.default=i,e.exports=i):void 0===(n=function(){return i}.apply(t,[]))||(e.exports=n)}()},89314(e,t,n){"use strict";const{normalizeIPv6:r,removeDotSegments:i,recomposeAuthority:s,normalizeComponentEncoding:a,isIPv4:o,nonSimpleDomain:l}=n(25527),{SCHEMES:c,getSchemeHandler:h}=n(16590);function d(e,t,n,r){const s={};return r||(e=f(u(e,n),n),t=f(u(t,n),n)),!(n=n||{}).tolerant&&t.scheme?(s.scheme=t.scheme,s.userinfo=t.userinfo,s.host=t.host,s.port=t.port,s.path=i(t.path||""),s.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(s.userinfo=t.userinfo,s.host=t.host,s.port=t.port,s.path=i(t.path||""),s.query=t.query):(t.path?("/"===t.path[0]?s.path=i(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?s.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:s.path=t.path:s.path="/"+t.path,s.path=i(s.path)),s.query=t.query):(s.path=e.path,void 0!==t.query?s.query=t.query:s.query=e.query),s.userinfo=e.userinfo,s.host=e.host,s.port=e.port),s.scheme=e.scheme),s.fragment=t.fragment,s}function u(e,t){const n={host:e.host,scheme:e.scheme,userinfo:e.userinfo,port:e.port,path:e.path,query:e.query,nid:e.nid,nss:e.nss,uuid:e.uuid,fragment:e.fragment,reference:e.reference,resourceName:e.resourceName,secure:e.secure,error:""},r=Object.assign({},t),a=[],o=h(r.scheme||n.scheme);o&&o.serialize&&o.serialize(n,r),void 0!==n.path&&(r.skipEscape?n.path=unescape(n.path):(n.path=escape(n.path),void 0!==n.scheme&&(n.path=n.path.split("%3A").join(":")))),"suffix"!==r.reference&&n.scheme&&a.push(n.scheme,":");const l=s(n);if(void 0!==l&&("suffix"!==r.reference&&a.push("//"),a.push(l),n.path&&"/"!==n.path[0]&&a.push("/")),void 0!==n.path){let e=n.path;r.absolutePath||o&&o.absolutePath||(e=i(e)),void 0===l&&"/"===e[0]&&"/"===e[1]&&(e="/%2F"+e.slice(2)),a.push(e)}return void 0!==n.query&&a.push("?",n.query),void 0!==n.fragment&&a.push("#",n.fragment),a.join("")}const p=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function f(e,t){const n=Object.assign({},t),i={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0};let s=!1;"suffix"===n.reference&&(e=n.scheme?n.scheme+":"+e:"//"+e);const a=e.match(p);if(a){if(i.scheme=a[1],i.userinfo=a[3],i.host=a[4],i.port=parseInt(a[5],10),i.path=a[6]||"",i.query=a[7],i.fragment=a[8],isNaN(i.port)&&(i.port=a[5]),i.host){if(!1===o(i.host)){const e=r(i.host);i.host=e.host.toLowerCase(),s=e.isIPV6}else s=!0}void 0!==i.scheme||void 0!==i.userinfo||void 0!==i.host||void 0!==i.port||void 0!==i.query||i.path?void 0===i.scheme?i.reference="relative":void 0===i.fragment?i.reference="absolute":i.reference="uri":i.reference="same-document",n.reference&&"suffix"!==n.reference&&n.reference!==i.reference&&(i.error=i.error||"URI is not a "+n.reference+" reference.");const t=h(n.scheme||i.scheme);if(!n.unicodeSupport&&(!t||!t.unicodeSupport)&&i.host&&(n.domainHost||t&&t.domainHost)&&!1===s&&l(i.host))try{i.host=URL.domainToASCII(i.host.toLowerCase())}catch(c){i.error=i.error||"Host's domain name can not be converted to ASCII: "+c}(!t||t&&!t.skipNormalize)&&(-1!==e.indexOf("%")&&(void 0!==i.scheme&&(i.scheme=unescape(i.scheme)),void 0!==i.host&&(i.host=unescape(i.host))),i.path&&(i.path=escape(unescape(i.path))),i.fragment&&(i.fragment=encodeURI(decodeURIComponent(i.fragment)))),t&&t.parse&&t.parse(i,n)}else i.error=i.error||"URI can not be parsed.";return i}const m={SCHEMES:c,normalize:function(e,t){return"string"===typeof e?e=u(f(e,t),t):"object"===typeof e&&(e=f(u(e,t),t)),e},resolve:function(e,t,n){const r=n?Object.assign({scheme:"null"},n):{scheme:"null"},i=d(f(e,r),f(t,r),r,!0);return r.skipEscape=!0,u(i,r)},resolveComponent:d,equal:function(e,t,n){return"string"===typeof e?(e=unescape(e),e=u(a(f(e,n),!0),{...n,skipEscape:!0})):"object"===typeof e&&(e=u(a(e,!0),{...n,skipEscape:!0})),"string"===typeof t?(t=unescape(t),t=u(a(f(t,n),!0),{...n,skipEscape:!0})):"object"===typeof t&&(t=u(a(t,!0),{...n,skipEscape:!0})),e.toLowerCase()===t.toLowerCase()},serialize:u,parse:f};e.exports=m,e.exports.default=m,e.exports.fastUri=m},16590(e,t,n){"use strict";const{isUUID:r}=n(25527),i=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,s=["http","https","ws","wss","urn","urn:uuid"];function a(e){return!0===e.secure||!1!==e.secure&&(!!e.scheme&&(3===e.scheme.length&&("w"===e.scheme[0]||"W"===e.scheme[0])&&("s"===e.scheme[1]||"S"===e.scheme[1])&&("s"===e.scheme[2]||"S"===e.scheme[2])))}function o(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function l(e){const t="https"===String(e.scheme).toLowerCase();return e.port!==(t?443:80)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}const c={scheme:"http",domainHost:!0,parse:o,serialize:l},h={scheme:"ws",domainHost:!0,parse:function(e){return e.secure=a(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e},serialize:function(e){if(e.port!==(a(e)?443:80)&&""!==e.port||(e.port=void 0),"boolean"===typeof e.secure&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),e.resourceName){const[t,n]=e.resourceName.split("?");e.path=t&&"/"!==t?t:void 0,e.query=n,e.resourceName=void 0}return e.fragment=void 0,e}},d={http:c,https:{scheme:"https",domainHost:c.domainHost,parse:o,serialize:l},ws:h,wss:{scheme:"wss",domainHost:h.domainHost,parse:h.parse,serialize:h.serialize},urn:{scheme:"urn",parse:function(e,t){if(!e.path)return e.error="URN can not be parsed",e;const n=e.path.match(i);if(n){const r=t.scheme||e.scheme||"urn";e.nid=n[1].toLowerCase(),e.nss=n[2];const i=u(`${r}:${t.nid||e.nid}`);e.path=void 0,i&&(e=i.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e},serialize:function(e,t){if(void 0===e.nid)throw new Error("URN without nid cannot be serialized");const n=t.scheme||e.scheme||"urn",r=e.nid.toLowerCase(),i=u(`${n}:${t.nid||r}`);i&&(e=i.serialize(e,t));const s=e,a=e.nss;return s.path=`${r||t.nid}:${a}`,t.skipEscape=!0,s},skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:function(e,t){const n=e;return n.uuid=n.nss,n.nss=void 0,t.tolerant||n.uuid&&r(n.uuid)||(n.error=n.error||"UUID is not valid."),n},serialize:function(e){const t=e;return t.nss=(e.uuid||"").toLowerCase(),t},skipNormalize:!0}};function u(e){return e&&(d[e]||d[e.toLowerCase()])||void 0}Object.setPrototypeOf(d,null),e.exports={wsIsSecure:a,SCHEMES:d,isValidSchemeName:function(e){return-1!==s.indexOf(e)},getSchemeHandler:u}},25527(e){"use strict";const t=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),n=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u);function r(e){let t="",n=0,r=0;for(r=0;r<e.length;r++)if(n=e[r].charCodeAt(0),48!==n){if(!(n>=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102))return"";t+=e[r];break}for(r+=1;r<e.length;r++){if(n=e[r].charCodeAt(0),!(n>=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102))return"";t+=e[r]}return t}const i=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function s(e){return e.length=0,!0}function a(e,t,n){if(e.length){const i=r(e);if(""===i)return n.error=!0,!1;t.push(i),e.length=0}return!0}function o(e){if(function(e,t){let n=0;for(let r=0;r<e.length;r++)e[r]===t&&n++;return n}(e,":")<2)return{host:e,isIPV6:!1};const t=function(e){let t=0;const n={error:!1,address:"",zone:""},i=[],o=[];let l=!1,c=!1,h=a;for(let r=0;r<e.length;r++){const a=e[r];if("["!==a&&"]"!==a)if(":"!==a)if("%"===a){if(!h(o,i,n))break;h=s}else o.push(a);else{if(!0===l&&(c=!0),!h(o,i,n))break;if(++t>7){n.error=!0;break}r>0&&":"===e[r-1]&&(l=!0),i.push(":")}}return o.length&&(h===s?n.zone=o.join(""):c?i.push(o.join("")):i.push(r(o))),n.address=i.join(""),n}(e);if(t.error)return{host:e,isIPV6:!1};{let e=t.address,n=t.address;return t.zone&&(e+="%"+t.zone,n+="%25"+t.zone),{host:e,isIPV6:!0,escapedHost:n}}}e.exports={nonSimpleDomain:i,recomposeAuthority:function(e){const t=[];if(void 0!==e.userinfo&&(t.push(e.userinfo),t.push("@")),void 0!==e.host){let r=unescape(e.host);if(!n(r)){const t=o(r);r=!0===t.isIPV6?`[${t.escapedHost}]`:e.host}t.push(r)}return"number"!==typeof e.port&&"string"!==typeof e.port||(t.push(":"),t.push(String(e.port))),t.length?t.join(""):void 0},normalizeComponentEncoding:function(e,t){const n=!0!==t?escape:unescape;return void 0!==e.scheme&&(e.scheme=n(e.scheme)),void 0!==e.userinfo&&(e.userinfo=n(e.userinfo)),void 0!==e.host&&(e.host=n(e.host)),void 0!==e.path&&(e.path=n(e.path)),void 0!==e.query&&(e.query=n(e.query)),void 0!==e.fragment&&(e.fragment=n(e.fragment)),e},removeDotSegments:function(e){let t=e;const n=[];let r=-1,i=0;for(;i=t.length;){if(1===i){if("."===t)break;if("/"===t){n.push("/");break}n.push(t);break}if(2===i){if("."===t[0]){if("."===t[1])break;if("/"===t[1]){t=t.slice(2);continue}}else if("/"===t[0]&&("."===t[1]||"/"===t[1])){n.push("/");break}}else if(3===i&&"/.."===t){0!==n.length&&n.pop(),n.push("/");break}if("."===t[0]){if("."===t[1]){if("/"===t[2]){t=t.slice(3);continue}}else if("/"===t[1]){t=t.slice(2);continue}}else if("/"===t[0]&&"."===t[1]){if("/"===t[2]){t=t.slice(2);continue}if("."===t[2]&&"/"===t[3]){t=t.slice(3),0!==n.length&&n.pop();continue}}if(-1===(r=t.indexOf("/",1))){n.push(t);break}n.push(t.slice(0,r)),t=t.slice(r)}return n.join("")},isIPv4:n,isUUID:t,normalizeIPv6:o,stringArrayToHexStripped:r}},68102(e,t,n){"use strict";function r(){return r=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},r.apply(null,arguments)}n.d(t,{A:()=>r})},3141(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function i(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,s,a,o=[],l=!0,c=!1;try{if(s=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=s.call(n)).done)&&(o.push(r.value),o.length!==t);l=!0);}catch(e){c=!0,i=e}finally{try{if(!l&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw i}}return o}}(e,t)||function(e,t){if(e){if("string"==typeof e)return r(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}n.d(t,{A:()=>i})},47215(e,t,n){"use strict";function r(e){var t,n,i="";if("string"==typeof e||"number"==typeof e)i+=e;else if("object"==typeof e)if(Array.isArray(e)){var s=e.length;for(t=0;t<s;t++)e[t]&&(n=r(e[t]))&&(i&&(i+=" "),i+=n)}else for(n in e)e[n]&&(i&&(i+=" "),i+=n);return i}n.d(t,{A:()=>i});const i=function(){for(var e,t,n=0,i="",s=arguments.length;n<s;n++)(e=arguments[n])&&(t=r(e))&&(i&&(i+=" "),i+=t);return i}},78805(e,t,n){"use strict";function r(e){let t=!1;return{promise:new Promise((n,r)=>{e.then(e=>!t&&n(e)).catch(e=>!t&&r(e))}),cancel(){t=!0}}}n.d(t,{A:()=>r})},41338(e,t,n){"use strict";n.d(t,{Ay:()=>i});const r=["onCopy","onCut","onPaste","onCompositionEnd","onCompositionStart","onCompositionUpdate","onFocus","onBlur","onInput","onInvalid","onReset","onSubmit","onLoad","onError","onKeyDown","onKeyPress","onKeyUp","onAbort","onCanPlay","onCanPlayThrough","onDurationChange","onEmptied","onEncrypted","onEnded","onError","onLoadedData","onLoadedMetadata","onLoadStart","onPause","onPlay","onPlaying","onProgress","onRateChange","onSeeked","onSeeking","onStalled","onSuspend","onTimeUpdate","onVolumeChange","onWaiting","onClick","onContextMenu","onDoubleClick","onMouseDown","onMouseEnter","onMouseLeave","onMouseMove","onMouseOut","onMouseOver","onMouseUp","onDrag","onDragEnd","onDragEnter","onDragExit","onDragLeave","onDragOver","onDragStart","onDrop","onSelect","onTouchCancel","onTouchEnd","onTouchMove","onTouchStart","onPointerDown","onPointerMove","onPointerUp","onPointerCancel","onGotPointerCapture","onLostPointerCapture","onPointerEnter","onPointerLeave","onPointerOver","onPointerOut","onScroll","onWheel","onAnimationStart","onAnimationEnd","onAnimationIteration","onTransitionEnd","onChange","onToggle"];function i(e,t){const n={};for(const i of r){const r=e[i];r&&(n[i]=t?e=>r(e,t(i)):r)}return n}},31079(e,t,n){"use strict";var r;n.d(t,{D6:()=>pr,EA:()=>Bn,Tm:()=>gr,YE:()=>fr,dU:()=>ai,ng:()=>m});const i="object"===typeof process&&process+""==="[object process]"&&!process.versions.nw&&!(process.versions.electron&&process.type&&"browser"!==process.type),s=[.001,0,0,.001,0,0],a=1.35,o=1,l=2,c=4,h=16,d=32,u=64,p=128,f=256,m={DISABLE:0,ENABLE:1,ENABLE_FORMS:2,ENABLE_STORAGE:3},g="pdfjs_internal_editor_",v={DISABLE:-1,NONE:0,FREETEXT:3,HIGHLIGHT:9,STAMP:13,INK:15,POPUP:16,SIGNATURE:101,COMMENT:102},y={RESIZE:1,CREATE:2,FREETEXT_SIZE:11,FREETEXT_COLOR:12,FREETEXT_OPACITY:13,INK_COLOR:21,INK_THICKNESS:22,INK_OPACITY:23,HIGHLIGHT_COLOR:31,HIGHLIGHT_THICKNESS:32,HIGHLIGHT_FREE:33,HIGHLIGHT_SHOW_ALL:34,DRAW_STEP:41},b=0,w=1,_=2,A=3,x=3,E=4,C={GRAYSCALE_1BPP:1,RGB_24BPP:2,RGBA_32BPP:3},k={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},S=1,T=2,D=3,M=4,P=5,I={ERRORS:0,WARNINGS:1,INFOS:5},F={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,setStrokeTransparent:92,setFillTransparent:93,rawFillPath:94},R=0,N=1,L=2,O=3;let B=I.WARNINGS;function $(e){Number.isInteger(e)&&(B=e)}function z(){return B}function j(e){B>=I.INFOS&&console.info(`Info: ${e}`)}function U(e){B>=I.WARNINGS&&console.warn(`Warning: ${e}`)}function H(e){throw new Error(e)}function V(e,t){e||H(t)}function q(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(!e)return null;if(n&&"string"===typeof e){if(n.addDefaultProtocol&&e.startsWith("www.")){const t=e.match(/\./g);t?.length>=2&&(e=`http://${e}`)}if(n.tryConvertEncoding)try{e=decodeURIComponent(escape(e))}catch{}}const r=t?URL.parse(e,t):URL.parse(e);return function(e){switch(e?.protocol){case"http:":case"https:":case"ftp:":case"mailto:":case"tel:":return!0;default:return!1}}(r)?r:null}function W(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];const r=URL.parse(e);return r?(r.hash=t,r.href):n&&q(e,"http://example.com")?e.split("#",1)[0]+""+(t?`#${t}`:""):""}function G(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];return Object.defineProperty(e,t,{value:n,enumerable:!r,configurable:!0,writable:!1}),n}const K=function(){function e(e,t){this.message=e,this.name=t}return e.prototype=new Error,e.constructor=e,e}();class X extends K{constructor(e,t){super(e,"PasswordException"),this.code=t}}class Y extends K{constructor(e,t){super(e,"UnknownErrorException"),this.details=t}}class Z extends K{constructor(e){super(e,"InvalidPDFException")}}class J extends K{constructor(e,t,n){super(e,"ResponseException"),this.status=t,this.missing=n}}class Q extends K{constructor(e){super(e,"FormatError")}}class ee extends K{constructor(e){super(e,"AbortException")}}function te(e){"object"===typeof e&&void 0!==e?.length||H("Invalid argument for bytesToString");const t=e.length,n=8192;if(t<n)return String.fromCharCode.apply(null,e);const r=[];for(let i=0;i<t;i+=n){const s=Math.min(i+n,t),a=e.subarray(i,s);r.push(String.fromCharCode.apply(null,a))}return r.join("")}function ne(e){"string"!==typeof e&&H("Invalid argument for stringToBytes");const t=e.length,n=new Uint8Array(t);for(let r=0;r<t;++r)n[r]=255&e.charCodeAt(r);return n}class re{static get isLittleEndian(){return G(this,"isLittleEndian",function(){const e=new Uint8Array(4);return e[0]=1,1===new Uint32Array(e.buffer,0,1)[0]}())}static get isEvalSupported(){return G(this,"isEvalSupported",function(){try{return new Function(""),!0}catch{return!1}}())}static get isOffscreenCanvasSupported(){return G(this,"isOffscreenCanvasSupported","undefined"!==typeof OffscreenCanvas)}static get isImageDecoderSupported(){return G(this,"isImageDecoderSupported","undefined"!==typeof ImageDecoder)}static get platform(){const{platform:e,userAgent:t}=navigator;return G(this,"platform",{isAndroid:t.includes("Android"),isLinux:e.includes("Linux"),isMac:e.includes("Mac"),isWindows:e.includes("Win"),isFirefox:t.includes("Firefox")})}static get isCSSRoundSupported(){return G(this,"isCSSRoundSupported",globalThis.CSS?.supports?.("width: round(1.5px, 1px)"))}}const ie=Array.from(Array(256).keys(),e=>e.toString(16).padStart(2,"0"));class se{static makeHexColor(e,t,n){return`#${ie[e]}${ie[t]}${ie[n]}`}static domMatrixToTransform(e){return[e.a,e.b,e.c,e.d,e.e,e.f]}static scaleMinMax(e,t){let n;e[0]?(e[0]<0&&(n=t[0],t[0]=t[2],t[2]=n),t[0]*=e[0],t[2]*=e[0],e[3]<0&&(n=t[1],t[1]=t[3],t[3]=n),t[1]*=e[3],t[3]*=e[3]):(n=t[0],t[0]=t[1],t[1]=n,n=t[2],t[2]=t[3],t[3]=n,e[1]<0&&(n=t[1],t[1]=t[3],t[3]=n),t[1]*=e[1],t[3]*=e[1],e[2]<0&&(n=t[0],t[0]=t[2],t[2]=n),t[0]*=e[2],t[2]*=e[2]),t[0]+=e[4],t[1]+=e[5],t[2]+=e[4],t[3]+=e[5]}static transform(e,t){return[e[0]*t[0]+e[2]*t[1],e[1]*t[0]+e[3]*t[1],e[0]*t[2]+e[2]*t[3],e[1]*t[2]+e[3]*t[3],e[0]*t[4]+e[2]*t[5]+e[4],e[1]*t[4]+e[3]*t[5]+e[5]]}static multiplyByDOMMatrix(e,t){return[e[0]*t.a+e[2]*t.b,e[1]*t.a+e[3]*t.b,e[0]*t.c+e[2]*t.d,e[1]*t.c+e[3]*t.d,e[0]*t.e+e[2]*t.f+e[4],e[1]*t.e+e[3]*t.f+e[5]]}static applyTransform(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;const r=e[n],i=e[n+1];e[n]=r*t[0]+i*t[2]+t[4],e[n+1]=r*t[1]+i*t[3]+t[5]}static applyTransformToBezier(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;const r=t[0],i=t[1],s=t[2],a=t[3],o=t[4],l=t[5];for(let c=0;c<6;c+=2){const t=e[n+c],h=e[n+c+1];e[n+c]=t*r+h*s+o,e[n+c+1]=t*i+h*a+l}}static applyInverseTransform(e,t){const n=e[0],r=e[1],i=t[0]*t[3]-t[1]*t[2];e[0]=(n*t[3]-r*t[2]+t[2]*t[5]-t[4]*t[3])/i,e[1]=(-n*t[1]+r*t[0]+t[4]*t[1]-t[5]*t[0])/i}static axialAlignedBoundingBox(e,t,n){const r=t[0],i=t[1],s=t[2],a=t[3],o=t[4],l=t[5],c=e[0],h=e[1],d=e[2],u=e[3];let p=r*c+o,f=p,m=r*d+o,g=m,v=a*h+l,y=v,b=a*u+l,w=b;if(0!==i||0!==s){const e=i*c,t=i*d,n=s*h,r=s*u;p+=n,g+=n,m+=r,f+=r,v+=e,w+=e,b+=t,y+=t}n[0]=Math.min(n[0],p,m,f,g),n[1]=Math.min(n[1],v,b,y,w),n[2]=Math.max(n[2],p,m,f,g),n[3]=Math.max(n[3],v,b,y,w)}static inverseTransform(e){const t=e[0]*e[3]-e[1]*e[2];return[e[3]/t,-e[1]/t,-e[2]/t,e[0]/t,(e[2]*e[5]-e[4]*e[3])/t,(e[4]*e[1]-e[5]*e[0])/t]}static singularValueDecompose2dScale(e,t){const n=e[0],r=e[1],i=e[2],s=e[3],a=n**2+r**2,o=n*i+r*s,l=i**2+s**2,c=(a+l)/2,h=Math.sqrt(c**2-(a*l-o**2));t[0]=Math.sqrt(c+h||1),t[1]=Math.sqrt(c-h||1)}static normalizeRect(e){const t=e.slice(0);return e[0]>e[2]&&(t[0]=e[2],t[2]=e[0]),e[1]>e[3]&&(t[1]=e[3],t[3]=e[1]),t}static intersect(e,t){const n=Math.max(Math.min(e[0],e[2]),Math.min(t[0],t[2])),r=Math.min(Math.max(e[0],e[2]),Math.max(t[0],t[2]));if(n>r)return null;const i=Math.max(Math.min(e[1],e[3]),Math.min(t[1],t[3])),s=Math.min(Math.max(e[1],e[3]),Math.max(t[1],t[3]));return i>s?null:[n,i,r,s]}static pointBoundingBox(e,t,n){n[0]=Math.min(n[0],e),n[1]=Math.min(n[1],t),n[2]=Math.max(n[2],e),n[3]=Math.max(n[3],t)}static rectBoundingBox(e,t,n,r,i){i[0]=Math.min(i[0],e,n),i[1]=Math.min(i[1],t,r),i[2]=Math.max(i[2],e,n),i[3]=Math.max(i[3],t,r)}static#e(e,t,n,r,i,s,a,o,l,c){if(l<=0||l>=1)return;const h=1-l,d=l*l,u=d*l,p=h*(h*(h*e+3*l*t)+3*d*n)+u*r,f=h*(h*(h*i+3*l*s)+3*d*a)+u*o;c[0]=Math.min(c[0],p),c[1]=Math.min(c[1],f),c[2]=Math.max(c[2],p),c[3]=Math.max(c[3],f)}static#t(e,t,n,r,i,s,a,o,l,c,h,d){if(Math.abs(l)<1e-12)return void(Math.abs(c)>=1e-12&&this.#e(e,t,n,r,i,s,a,o,-h/c,d));const u=c**2-4*h*l;if(u<0)return;const p=Math.sqrt(u),f=2*l;this.#e(e,t,n,r,i,s,a,o,(-c+p)/f,d),this.#e(e,t,n,r,i,s,a,o,(-c-p)/f,d)}static bezierBoundingBox(e,t,n,r,i,s,a,o,l){l[0]=Math.min(l[0],e,a),l[1]=Math.min(l[1],t,o),l[2]=Math.max(l[2],e,a),l[3]=Math.max(l[3],t,o),this.#t(e,n,i,a,t,r,s,o,3*(3*(n-i)-e+a),6*(e-2*n+i),3*(n-e),l),this.#t(e,n,i,a,t,r,s,o,3*(3*(r-s)-t+o),6*(t-2*r+s),3*(r-t),l)}}let ae=null,oe=null;function le(){if("function"===typeof crypto.randomUUID)return crypto.randomUUID();const e=new Uint8Array(32);return crypto.getRandomValues(e),te(e)}const ce="pdfjs_internal_id_";function he(e,t,n){return Math.min(Math.max(e,t),n)}function de(e){return Uint8Array.prototype.toBase64?e.toBase64():btoa(te(e))}"function"!==typeof Promise.try&&(Promise.try=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new Promise(t=>{t(e(...n))})}),"function"!==typeof Math.sumPrecise&&(Math.sumPrecise=function(e){return e.reduce((e,t)=>e+t,0)});class ue{static textContent(e){const t=[],n={items:t,styles:Object.create(null)};return function e(n){if(!n)return;let r=null;const i=n.name;if("#text"===i)r=n.value;else{if(!ue.shouldBuildText(i))return;n?.attributes?.textContent?r=n.attributes.textContent:n.value&&(r=n.value)}if(null!==r&&t.push({str:r}),n.children)for(const t of n.children)e(t)}(e),n}static shouldBuildText(e){return!("textarea"===e||"input"===e||"option"===e||"select"===e)}}class pe{static setupStorage(e,t,n,r,i){const s=r.getValue(t,{value:null});switch(n.name){case"textarea":if(null!==s.value&&(e.textContent=s.value),"print"===i)break;e.addEventListener("input",e=>{r.setValue(t,{value:e.target.value})});break;case"input":if("radio"===n.attributes.type||"checkbox"===n.attributes.type){if(s.value===n.attributes.xfaOn?e.setAttribute("checked",!0):s.value===n.attributes.xfaOff&&e.removeAttribute("checked"),"print"===i)break;e.addEventListener("change",e=>{r.setValue(t,{value:e.target.checked?e.target.getAttribute("xfaOn"):e.target.getAttribute("xfaOff")})})}else{if(null!==s.value&&e.setAttribute("value",s.value),"print"===i)break;e.addEventListener("input",e=>{r.setValue(t,{value:e.target.value})})}break;case"select":if(null!==s.value){e.setAttribute("value",s.value);for(const e of n.children)e.attributes.value===s.value?e.attributes.selected=!0:e.attributes.hasOwnProperty("selected")&&delete e.attributes.selected}e.addEventListener("input",e=>{const n=e.target.options,i=-1===n.selectedIndex?"":n[n.selectedIndex].value;r.setValue(t,{value:i})})}}static setAttributes(e){let{html:t,element:n,storage:r=null,intent:i,linkService:s}=e;const{attributes:a}=n,o=t instanceof HTMLAnchorElement;"radio"===a.type&&(a.name=`${a.name}-${i}`);for(const[l,c]of Object.entries(a))if(null!==c&&void 0!==c)switch(l){case"class":c.length&&t.setAttribute(l,c.join(" "));break;case"dataId":break;case"id":t.setAttribute("data-element-id",c);break;case"style":Object.assign(t.style,c);break;case"textContent":t.textContent=c;break;default:(!o||"href"!==l&&"newWindow"!==l)&&t.setAttribute(l,c)}o&&s.addLinkAttributes(t,a.href,a.newWindow),r&&a.dataId&&this.setupStorage(t,a.dataId,n,r)}static render(e){const t=e.annotationStorage,n=e.linkService,r=e.xfaHtml,i=e.intent||"display",s=document.createElement(r.name);r.attributes&&this.setAttributes({html:s,element:r,intent:i,linkService:n});const a="richText"!==i,o=e.div;if(o.append(s),e.viewport){const t=`matrix(${e.viewport.transform.join(",")})`;o.style.transform=t}a&&o.setAttribute("class","xfaLayer xfaFont");const l=[];if(0===r.children.length){if(r.value){const e=document.createTextNode(r.value);s.append(e),a&&ue.shouldBuildText(r.name)&&l.push(e)}return{textDivs:l}}const c=[[r,-1,s]];for(;c.length>0;){const[e,r,s]=c.at(-1);if(r+1===e.children.length){c.pop();continue}const o=e.children[++c.at(-1)[1]];if(null===o)continue;const{name:h}=o;if("#text"===h){const e=document.createTextNode(o.value);l.push(e),s.append(e);continue}const d=o?.attributes?.xmlns?document.createElementNS(o.attributes.xmlns,h):document.createElement(h);if(s.append(d),o.attributes&&this.setAttributes({html:d,element:o,storage:t,intent:i,linkService:n}),o.children?.length>0)c.push([o,-1,d]);else if(o.value){const e=document.createTextNode(o.value);a&&ue.shouldBuildText(h)&&l.push(e),d.append(e)}}for(const h of o.querySelectorAll(".xfaNonInteractive input, .xfaNonInteractive textarea"))h.setAttribute("readOnly",!0);return{textDivs:l}}static update(e){const t=`matrix(${e.viewport.transform.join(",")})`;e.div.style.transform=t,e.div.hidden=!1}}const fe="http://www.w3.org/2000/svg";class me{static CSS=96;static PDF=72;static PDF_TO_CSS_UNITS=(()=>this.CSS/this.PDF)()}async function ge(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"text";if(Ae(e,document.baseURI)){const n=await fetch(e);if(!n.ok)throw new Error(n.statusText);switch(t){case"arraybuffer":return n.arrayBuffer();case"blob":return n.blob();case"json":return n.json()}return n.text()}return new Promise((n,r)=>{const i=new XMLHttpRequest;i.open("GET",e,!0),i.responseType=t,i.onreadystatechange=()=>{if(i.readyState===XMLHttpRequest.DONE)if(200!==i.status&&0!==i.status)r(new Error(i.statusText));else{switch(t){case"arraybuffer":case"blob":case"json":return void n(i.response)}n(i.responseText)}},i.send(null)})}class ve{constructor(e){let{viewBox:t,userUnit:n,scale:r,rotation:i,offsetX:s=0,offsetY:a=0,dontFlip:o=!1}=e;this.viewBox=t,this.userUnit=n,this.scale=r,this.rotation=i,this.offsetX=s,this.offsetY=a,r*=n;const l=(t[2]+t[0])/2,c=(t[3]+t[1])/2;let h,d,u,p,f,m,g,v;switch(i%=360,i<0&&(i+=360),i){case 180:h=-1,d=0,u=0,p=1;break;case 90:h=0,d=1,u=1,p=0;break;case 270:h=0,d=-1,u=-1,p=0;break;case 0:h=1,d=0,u=0,p=-1;break;default:throw new Error("PageViewport: Invalid rotation, must be a multiple of 90 degrees.")}o&&(u=-u,p=-p),0===h?(f=Math.abs(c-t[1])*r+s,m=Math.abs(l-t[0])*r+a,g=(t[3]-t[1])*r,v=(t[2]-t[0])*r):(f=Math.abs(l-t[0])*r+s,m=Math.abs(c-t[1])*r+a,g=(t[2]-t[0])*r,v=(t[3]-t[1])*r),this.transform=[h*r,d*r,u*r,p*r,f-h*r*l-u*r*c,m-d*r*l-p*r*c],this.width=g,this.height=v}get rawDims(){const e=this.viewBox;return G(this,"rawDims",{pageWidth:e[2]-e[0],pageHeight:e[3]-e[1],pageX:e[0],pageY:e[1]})}clone(){let{scale:e=this.scale,rotation:t=this.rotation,offsetX:n=this.offsetX,offsetY:r=this.offsetY,dontFlip:i=!1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return new ve({viewBox:this.viewBox.slice(),userUnit:this.userUnit,scale:e,rotation:t,offsetX:n,offsetY:r,dontFlip:i})}convertToViewportPoint(e,t){const n=[e,t];return se.applyTransform(n,this.transform),n}convertToViewportRectangle(e){const t=[e[0],e[1]];se.applyTransform(t,this.transform);const n=[e[2],e[3]];return se.applyTransform(n,this.transform),[t[0],t[1],n[0],n[1]]}convertToPdfPoint(e,t){const n=[e,t];return se.applyInverseTransform(n,this.transform),n}}class ye extends K{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;super(e,"RenderingCancelledException"),this.extraDelay=t}}function be(e){const t=e.length;let n=0;for(;n<t&&""===e[n].trim();)n++;return"data:"===e.substring(n,n+5).toLowerCase()}function we(e){return"string"===typeof e&&/\.pdf$/i.test(e)}class _e{started=(()=>Object.create(null))();times=[];time(e){e in this.started&&U(`Timer is already running for ${e}`),this.started[e]=Date.now()}timeEnd(e){e in this.started||U(`Timer has not been started for ${e}`),this.times.push({name:e,start:this.started[e],end:Date.now()}),delete this.started[e]}toString(){const e=[];let t=0;for(const{name:n}of this.times)t=Math.max(n.length,t);for(const{name:n,start:r,end:i}of this.times)e.push(`${n.padEnd(t)} ${i-r}ms\n`);return e.join("")}}function Ae(e,t){const n=t?URL.parse(e,t):URL.parse(e);return"http:"===n?.protocol||"https:"===n?.protocol}function xe(e){e.preventDefault()}function Ee(e){e.preventDefault(),e.stopPropagation()}class Ce{static#n;static toDateObject(e){if(e instanceof Date)return e;if(!e||"string"!==typeof e)return null;this.#n||=new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?");const t=this.#n.exec(e);if(!t)return null;const n=parseInt(t[1],10);let r=parseInt(t[2],10);r=r>=1&&r<=12?r-1:0;let i=parseInt(t[3],10);i=i>=1&&i<=31?i:1;let s=parseInt(t[4],10);s=s>=0&&s<=23?s:0;let a=parseInt(t[5],10);a=a>=0&&a<=59?a:0;let o=parseInt(t[6],10);o=o>=0&&o<=59?o:0;const l=t[7]||"Z";let c=parseInt(t[8],10);c=c>=0&&c<=23?c:0;let h=parseInt(t[9],10)||0;return h=h>=0&&h<=59?h:0,"-"===l?(s+=c,a+=h):"+"===l&&(s-=c,a-=h),new Date(Date.UTC(n,r,i,s,a,o))}}function ke(e){if(e.startsWith("#")){const t=parseInt(e.slice(1),16);return[(16711680&t)>>16,(65280&t)>>8,255&t]}return e.startsWith("rgb(")?e.slice(4,-1).split(",").map(e=>parseInt(e)):e.startsWith("rgba(")?e.slice(5,-1).split(",").map(e=>parseInt(e)).slice(0,3):(U(`Not a valid color format: "${e}"`),[0,0,0])}function Se(e){const{a:t,b:n,c:r,d:i,e:s,f:a}=e.getTransform();return[t,n,r,i,s,a]}function Te(e){const{a:t,b:n,c:r,d:i,e:s,f:a}=e.getTransform().invertSelf();return[t,n,r,i,s,a]}function De(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];if(t instanceof ve){const{pageWidth:r,pageHeight:i}=t.rawDims,{style:s}=e,a=re.isCSSRoundSupported,o=`var(--total-scale-factor) * ${r}px`,l=`var(--total-scale-factor) * ${i}px`,c=a?`round(down, ${o}, var(--scale-round-x))`:`calc(${o})`,h=a?`round(down, ${l}, var(--scale-round-y))`:`calc(${l})`;n&&t.rotation%180!==0?(s.width=h,s.height=c):(s.width=c,s.height=h)}r&&e.setAttribute("data-main-rotation",t.rotation)}class Me{constructor(){const{pixelRatio:e}=Me;this.sx=e,this.sy=e}get scaled(){return 1!==this.sx||1!==this.sy}get symmetric(){return this.sx===this.sy}limitCanvas(e,t,n,r){let i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:-1,s=1/0,a=1/0,o=1/0;(n=Me.capPixels(n,i))>0&&(s=Math.sqrt(n/(e*t))),-1!==r&&(a=r/e,o=r/t);const l=Math.min(s,a,o);return(this.sx>l||this.sy>l)&&(this.sx=l,this.sy=l,!0)}static get pixelRatio(){return globalThis.devicePixelRatio||1}static capPixels(e,t){if(t>=0){const n=Math.ceil(window.screen.availWidth*window.screen.availHeight*this.pixelRatio**2*(1+t/100));return e>0?Math.min(e,n):n}return e}}const Pe=["image/apng","image/avif","image/bmp","image/gif","image/jpeg","image/png","image/svg+xml","image/webp","image/x-icon"];class Ie{static get isDarkMode(){return G(this,"isDarkMode",!!window?.matchMedia?.("(prefers-color-scheme: dark)").matches)}}function Fe(e,t){const n=e[0]/255,r=e[1]/255,i=e[2]/255,s=Math.max(n,r,i),a=Math.min(n,r,i),o=(s+a)/2;if(s===a)t[0]=t[1]=0;else{const e=s-a;switch(t[1]=o<.5?e/(s+a):e/(2-s-a),s){case n:t[0]=60*((r-i)/e+(r<i?6:0));break;case r:t[0]=60*((i-n)/e+2);break;case i:t[0]=60*((n-r)/e+4)}}t[2]=o}function Re(e,t){const n=e[0],r=e[1],i=e[2],s=(1-Math.abs(2*i-1))*r,a=s*(1-Math.abs(n/60%2-1)),o=i-s/2;switch(Math.floor(n/60)){case 0:t[0]=s+o,t[1]=a+o,t[2]=o;break;case 1:t[0]=a+o,t[1]=s+o,t[2]=o;break;case 2:t[0]=o,t[1]=s+o,t[2]=a+o;break;case 3:t[0]=o,t[1]=a+o,t[2]=s+o;break;case 4:t[0]=a+o,t[1]=o,t[2]=s+o;break;case 5:case 6:t[0]=s+o,t[1]=o,t[2]=a+o}}function Ne(e){return e<=.03928?e/12.92:((e+.055)/1.055)**2.4}function Le(e,t,n){Re(e,n),n.map(Ne);const r=.2126*n[0]+.7152*n[1]+.0722*n[2];Re(t,n),n.map(Ne);const i=.2126*n[0]+.7152*n[1]+.0722*n[2];return r>i?(r+.05)/(i+.05):(i+.05)/(r+.05)}const Oe=new Map;function Be(e,t){let{html:n,dir:r,className:i}=e;const s=document.createDocumentFragment();if("string"===typeof n){const e=document.createElement("p");e.dir=r||"auto";const t=n.split(/(?:\r\n?|\n)/);for(let n=0,r=t.length;n<r;++n){const i=t[n];e.append(document.createTextNode(i)),n<r-1&&e.append(document.createElement("br"))}s.append(e)}else pe.render({xfaHtml:n,div:s,intent:"richText"});s.firstChild.classList.add("richText",i),t.append(s)}class $e{#r=null;#i=null;#s;#a=null;#o=null;#l=null;#c=null;#h=null;static#d=null;constructor(e){this.#s=e,$e.#d||=Object.freeze({freetext:"pdfjs-editor-remove-freetext-button",highlight:"pdfjs-editor-remove-highlight-button",ink:"pdfjs-editor-remove-ink-button",stamp:"pdfjs-editor-remove-stamp-button",signature:"pdfjs-editor-remove-signature-button"})}render(){const e=this.#r=document.createElement("div");e.classList.add("editToolbar","hidden"),e.setAttribute("role","toolbar");const t=this.#s._uiManager._signal;t instanceof AbortSignal&&!t.aborted&&(e.addEventListener("contextmenu",xe,{signal:t}),e.addEventListener("pointerdown",$e.#u,{signal:t}));const n=this.#a=document.createElement("div");n.className="buttons",e.append(n);const r=this.#s.toolbarPosition;if(r){const{style:t}=e,n="ltr"===this.#s._uiManager.direction?1-r[0]:r[0];t.insetInlineEnd=100*n+"%",t.top=`calc(${100*r[1]}% + var(--editor-toolbar-vert-offset))`}return e}get div(){return this.#r}static#u(e){e.stopPropagation()}#p(e){this.#s._focusEventsAllowed=!1,Ee(e)}#f(e){this.#s._focusEventsAllowed=!0,Ee(e)}#m(e){const t=this.#s._uiManager._signal;return t instanceof AbortSignal&&!t.aborted&&(e.addEventListener("focusin",this.#p.bind(this),{capture:!0,signal:t}),e.addEventListener("focusout",this.#f.bind(this),{capture:!0,signal:t}),e.addEventListener("contextmenu",xe,{signal:t}),!0)}hide(){this.#r.classList.add("hidden"),this.#i?.hideDropdown()}show(){this.#r.classList.remove("hidden"),this.#o?.shown(),this.#l?.shown()}addDeleteButton(){const{editorType:e,_uiManager:t}=this.#s,n=document.createElement("button");n.classList.add("basic","deleteButton"),n.tabIndex=0,n.setAttribute("data-l10n-id",$e.#d[e]),this.#m(n)&&n.addEventListener("click",e=>{t.delete()},{signal:t._signal}),this.#a.append(n)}get#g(){const e=document.createElement("div");return e.className="divider",e}async addAltText(e){const t=await e.render();this.#m(t),this.#a.append(t,this.#g),this.#o=e}addComment(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(this.#l)return;const n=e.renderForToolbar();if(!n)return;this.#m(n);const r=this.#c=this.#g;t?(this.#a.insertBefore(n,t),this.#a.insertBefore(r,t)):this.#a.append(n,r),this.#l=e,e.toolbar=this}addColorPicker(e){if(this.#i)return;this.#i=e;const t=e.renderButton();this.#m(t),this.#a.append(t,this.#g)}async addEditSignatureButton(e){const t=this.#h=await e.renderEditButton(this.#s);this.#m(t),this.#a.append(t,this.#g)}removeButton(e){if("comment"===e)this.#l?.removeToolbarCommentButton(),this.#l=null,this.#c?.remove(),this.#c=null}async addButton(e,t){switch(e){case"colorPicker":this.addColorPicker(t);break;case"altText":await this.addAltText(t);break;case"editSignature":await this.addEditSignatureButton(t);break;case"delete":this.addDeleteButton();break;case"comment":this.addComment(t)}}async addButtonBefore(e,t,n){const r=this.#a.querySelector(n);r&&"comment"===e&&this.addComment(t,r)}updateEditSignatureButton(e){this.#h&&(this.#h.title=e)}remove(){this.#r.remove(),this.#i?.destroy(),this.#i=null}}class ze{#a=null;#r=null;#v;constructor(e){this.#v=e}#y(){const e=this.#r=document.createElement("div");e.className="editToolbar",e.setAttribute("role","toolbar");const t=this.#v._signal;t instanceof AbortSignal&&!t.aborted&&e.addEventListener("contextmenu",xe,{signal:t});const n=this.#a=document.createElement("div");return n.className="buttons",e.append(n),this.#v.hasCommentManager()&&this.#b("commentButton","pdfjs-comment-floating-button","pdfjs-comment-floating-button-label",()=>{this.#v.commentSelection("floating_button")}),this.#b("highlightButton","pdfjs-highlight-floating-button1","pdfjs-highlight-floating-button-label",()=>{this.#v.highlightSelection("floating_button")}),e}#w(e,t){let n=0,r=0;for(const i of e){const e=i.y+i.height;if(e<n)continue;const s=i.x+(t?i.width:0);e>n?(r=s,n=e):t?s>r&&(r=s):s<r&&(r=s)}return[t?1-r:r,n]}show(e,t,n){const[r,i]=this.#w(t,n),{style:s}=this.#r||=this.#y();e.append(this.#r),s.insetInlineEnd=100*r+"%",s.top=`calc(${100*i}% + var(--editor-toolbar-vert-offset))`}hide(){this.#r.remove()}#b(e,t,n,r){const i=document.createElement("button");i.classList.add("basic",e),i.tabIndex=0,i.setAttribute("data-l10n-id",t);const s=document.createElement("span");i.append(s),s.className="visuallyHidden",s.setAttribute("data-l10n-id",n);const a=this.#v._signal;a instanceof AbortSignal&&!a.aborted&&(i.addEventListener("contextmenu",xe,{signal:a}),i.addEventListener("click",r,{signal:a})),this.#a.append(i)}}function je(e,t,n){for(const r of n)t.addEventListener(r,e[r].bind(e))}class Ue{#_=0;get id(){return`${g}${this.#_++}`}}class He{#A=(()=>le())();#_=0;#x=null;static get _isSVGFittingCanvas(){const e=new OffscreenCanvas(1,3).getContext("2d",{willReadFrequently:!0}),t=new Image;t.src='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>';return G(this,"_isSVGFittingCanvas",t.decode().then(()=>(e.drawImage(t,0,0,1,1,0,0,1,3),0===new Uint32Array(e.getImageData(0,0,1,1).data.buffer)[0])))}async#E(e,t){this.#x||=new Map;let n=this.#x.get(e);if(null===n)return null;if(n?.bitmap)return n.refCounter+=1,n;try{let e;if(n||={bitmap:null,id:`image_${this.#A}_${this.#_++}`,refCounter:0,isSvg:!1},"string"===typeof t?(n.url=t,e=await ge(t,"blob")):t instanceof File?e=n.file=t:t instanceof Blob&&(e=t),"image/svg+xml"===e.type){const t=He._isSVGFittingCanvas,r=new FileReader,i=new Image,s=new Promise((e,s)=>{i.onload=()=>{n.bitmap=i,n.isSvg=!0,e()},r.onload=async()=>{const e=n.svgUrl=r.result;i.src=await t?`${e}#svgView(preserveAspectRatio(none))`:e},i.onerror=r.onerror=s});r.readAsDataURL(e),await s}else n.bitmap=await createImageBitmap(e);n.refCounter=1}catch(r){U(r),n=null}return this.#x.set(e,n),n&&this.#x.set(n.id,n),n}async getFromFile(e){const{lastModified:t,name:n,size:r,type:i}=e;return this.#E(`${t}_${n}_${r}_${i}`,e)}async getFromUrl(e){return this.#E(e,e)}async getFromBlob(e,t){const n=await t;return this.#E(e,n)}async getFromId(e){this.#x||=new Map;const t=this.#x.get(e);if(!t)return null;if(t.bitmap)return t.refCounter+=1,t;if(t.file)return this.getFromFile(t.file);if(t.blobPromise){const{blobPromise:e}=t;return delete t.blobPromise,this.getFromBlob(t.id,e)}return this.getFromUrl(t.url)}getFromCanvas(e,t){this.#x||=new Map;let n=this.#x.get(e);if(n?.bitmap)return n.refCounter+=1,n;const r=new OffscreenCanvas(t.width,t.height);return r.getContext("2d").drawImage(t,0,0),n={bitmap:r.transferToImageBitmap(),id:`image_${this.#A}_${this.#_++}`,refCounter:1,isSvg:!1},this.#x.set(e,n),this.#x.set(n.id,n),n}getSvgUrl(e){const t=this.#x.get(e);return t?.isSvg?t.svgUrl:null}deleteId(e){this.#x||=new Map;const t=this.#x.get(e);if(!t)return;if(t.refCounter-=1,0!==t.refCounter)return;const{bitmap:n}=t;if(!t.url&&!t.file){const e=new OffscreenCanvas(n.width,n.height);e.getContext("bitmaprenderer").transferFromImageBitmap(n),t.blobPromise=e.convertToBlob()}n.close?.(),t.bitmap=null}isValidId(e){return e.startsWith(`image_${this.#A}_`)}}class Ve{#C=[];#k=!1;#S;#T=-1;constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:128;this.#S=e}add(e){let{cmd:t,undo:n,post:r,mustExec:i,type:s=NaN,overwriteIfSameType:a=!1,keepUndo:o=!1}=e;if(i&&t(),this.#k)return;const l={cmd:t,undo:n,post:r,type:s};if(-1===this.#T)return this.#C.length>0&&(this.#C.length=0),this.#T=0,void this.#C.push(l);if(a&&this.#C[this.#T].type===s)return o&&(l.undo=this.#C[this.#T].undo),void(this.#C[this.#T]=l);const c=this.#T+1;c===this.#S?this.#C.splice(0,1):(this.#T=c,c<this.#C.length&&this.#C.splice(c)),this.#C.push(l)}undo(){if(-1===this.#T)return;this.#k=!0;const{undo:e,post:t}=this.#C[this.#T];e(),t?.(),this.#k=!1,this.#T-=1}redo(){if(this.#T<this.#C.length-1){this.#T+=1,this.#k=!0;const{cmd:e,post:t}=this.#C[this.#T];e(),t?.(),this.#k=!1}}hasSomethingToUndo(){return-1!==this.#T}hasSomethingToRedo(){return this.#T<this.#C.length-1}cleanType(e){if(-1!==this.#T){for(let t=this.#T;t>=0;t--)if(this.#C[t].type!==e)return this.#C.splice(t+1,this.#T-t),void(this.#T=t);this.#C.length=0,this.#T=-1}}destroy(){this.#C=null}}class qe{constructor(e){this.buffer=[],this.callbacks=new Map,this.allKeys=new Set;const{isMac:t}=re.platform;for(const[n,r,i={}]of e)for(const e of n){const n=e.startsWith("mac+");t&&n?(this.callbacks.set(e.slice(4),{callback:r,options:i}),this.allKeys.add(e.split("+").at(-1))):t||n||(this.callbacks.set(e,{callback:r,options:i}),this.allKeys.add(e.split("+").at(-1)))}}#D(e){e.altKey&&this.buffer.push("alt"),e.ctrlKey&&this.buffer.push("ctrl"),e.metaKey&&this.buffer.push("meta"),e.shiftKey&&this.buffer.push("shift"),this.buffer.push(e.key);const t=this.buffer.join("+");return this.buffer.length=0,t}exec(e,t){if(!this.allKeys.has(t.key))return;const n=this.callbacks.get(this.#D(t));if(!n)return;const{callback:r,options:{bubbles:i=!1,args:s=[],checker:a=null}}=n;a&&!a(e,t)||(r.bind(e,...s,t)(),i||Ee(t))}}class We{static _colorsMapping=(()=>new Map([["CanvasText",[0,0,0]],["Canvas",[255,255,255]]]))();get _colors(){const e=new Map([["CanvasText",null],["Canvas",null]]);return function(e){const t=document.createElement("span");t.style.visibility="hidden",t.style.colorScheme="only light",document.body.append(t);for(const n of e.keys()){t.style.color=n;const r=window.getComputedStyle(t).color;e.set(n,ke(r))}t.remove()}(e),G(this,"_colors",e)}convert(e){const t=ke(e);if(!window.matchMedia("(forced-colors: active)").matches)return t;for(const[n,r]of this._colors)if(r.every((e,n)=>e===t[n]))return We._colorsMapping.get(n);return t}getHexCode(e){const t=this._colors.get(e);return t?se.makeHexColor(...t):e}}class Ge{#M=(()=>new AbortController)();#P=null;#I=null;#F=(()=>new Map)();#R=(()=>new Map)();#N=null;#L=null;#O=null;#B=(()=>new Ve)();#$=null;#z=null;#j=null;#U=0;#H=(()=>new Set)();#V=null;#q=null;#W=(()=>new Set)();_editorUndoBar=null;#G=!1;#K=!1;#X=!1;#Y=null;#Z=null;#J=null;#Q=null;#ee=!1;#te=null;#ne=(()=>new Ue)();#re=!1;#ie=!1;#se=!1;#ae=null;#oe=null;#le=null;#ce=null;#he=null;#de=(()=>v.NONE)();#ue=(()=>new Set)();#pe=null;#fe=null;#me=null;#ge=null;#ve=null;#ye={isEditing:!1,isEmpty:!0,hasSomethingToUndo:!1,hasSomethingToRedo:!1,hasSelectedEditor:!1,hasSelectedText:!1};#be=[0,0];#we=null;#_e=null;#Ae=null;#xe=null;#Ee=null;static TRANSLATE_SMALL=1;static TRANSLATE_BIG=10;static get _keyboardManager(){const e=Ge.prototype,t=e=>e.#_e.contains(document.activeElement)&&"BUTTON"!==document.activeElement.tagName&&e.hasSomethingToControl(),n=(e,t)=>{let{target:n}=t;if(n instanceof HTMLInputElement){const{type:e}=n;return"text"!==e&&"number"!==e}return!0},r=this.TRANSLATE_SMALL,i=this.TRANSLATE_BIG;return G(this,"_keyboardManager",new qe([[["ctrl+a","mac+meta+a"],e.selectAll,{checker:n}],[["ctrl+z","mac+meta+z"],e.undo,{checker:n}],[["ctrl+y","ctrl+shift+z","mac+meta+shift+z","ctrl+shift+Z","mac+meta+shift+Z"],e.redo,{checker:n}],[["Backspace","alt+Backspace","ctrl+Backspace","shift+Backspace","mac+Backspace","mac+alt+Backspace","mac+ctrl+Backspace","Delete","ctrl+Delete","shift+Delete","mac+Delete"],e.delete,{checker:n}],[["Enter","mac+Enter"],e.addNewEditorFromKeyboard,{checker:(e,t)=>{let{target:n}=t;return!(n instanceof HTMLButtonElement)&&e.#_e.contains(n)&&!e.isEnterHandled}}],[[" ","mac+ "],e.addNewEditorFromKeyboard,{checker:(e,t)=>{let{target:n}=t;return!(n instanceof HTMLButtonElement)&&e.#_e.contains(document.activeElement)}}],[["Escape","mac+Escape"],e.unselectAll],[["ArrowLeft","mac+ArrowLeft"],e.translateSelectedEditors,{args:[-r,0],checker:t}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],e.translateSelectedEditors,{args:[-i,0],checker:t}],[["ArrowRight","mac+ArrowRight"],e.translateSelectedEditors,{args:[r,0],checker:t}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],e.translateSelectedEditors,{args:[i,0],checker:t}],[["ArrowUp","mac+ArrowUp"],e.translateSelectedEditors,{args:[0,-r],checker:t}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],e.translateSelectedEditors,{args:[0,-i],checker:t}],[["ArrowDown","mac+ArrowDown"],e.translateSelectedEditors,{args:[0,r],checker:t}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],e.translateSelectedEditors,{args:[0,i],checker:t}]]))}constructor(e,t,n,r,i,s,a,o,l,c,h,d,u,p,f,m){const g=this._signal=this.#M.signal;this.#_e=e,this.#Ae=t,this.#xe=n,this.#N=r,this.#$=i,this.#fe=s,this.#ve=o,this._eventBus=a,a._on("editingaction",this.onEditingAction.bind(this),{signal:g}),a._on("pagechanging",this.onPageChanging.bind(this),{signal:g}),a._on("scalechanging",this.onScaleChanging.bind(this),{signal:g}),a._on("rotationchanging",this.onRotationChanging.bind(this),{signal:g}),a._on("setpreference",this.onSetPreference.bind(this),{signal:g}),a._on("switchannotationeditorparams",e=>this.updateParams(e.type,e.value),{signal:g}),window.addEventListener("pointerdown",()=>{this.#ie=!0},{capture:!0,signal:g}),window.addEventListener("pointerup",()=>{this.#ie=!1},{capture:!0,signal:g}),this.#Ce(),this.#ke(),this.#Se(),this.#L=o.annotationStorage,this.#Y=o.filterFactory,this.#me=l,this.#Q=c||null,this.#G=h,this.#K=d,this.#X=u,this.#he=p||null,this.viewParameters={realScale:me.PDF_TO_CSS_UNITS,rotation:0},this.isShiftKeyDown=!1,this._editorUndoBar=f||null,this._supportsPinchToZoom=!1!==m,i?.setSidebarUiManager(this)}destroy(){this.#Ee?.resolve(),this.#Ee=null,this.#M?.abort(),this.#M=null,this._signal=null;for(const e of this.#R.values())e.destroy();this.#R.clear(),this.#F.clear(),this.#W.clear(),this.#ce?.clear(),this.#P=null,this.#ue.clear(),this.#B.destroy(),this.#N?.destroy(),this.#$?.destroy(),this.#fe?.destroy(),this.#te?.hide(),this.#te=null,this.#le?.destroy(),this.#le=null,this.#I=null,this.#Z&&(clearTimeout(this.#Z),this.#Z=null),this.#we&&(clearTimeout(this.#we),this.#we=null),this._editorUndoBar?.destroy(),this.#ve=null}combinedSignal(e){return AbortSignal.any([this._signal,e.signal])}get mlManager(){return this.#he}get useNewAltTextFlow(){return this.#K}get useNewAltTextWhenAddingImage(){return this.#X}get hcmFilter(){return G(this,"hcmFilter",this.#me?this.#Y.addHCMFilter(this.#me.foreground,this.#me.background):"none")}get direction(){return G(this,"direction",getComputedStyle(this.#_e).direction)}get _highlightColors(){return G(this,"_highlightColors",this.#Q?new Map(this.#Q.split(",").map(e=>((e=e.split("=").map(e=>e.trim()))[1]=e[1].toUpperCase(),e))):null)}get highlightColors(){const{_highlightColors:e}=this;if(!e)return G(this,"highlightColors",null);const t=new Map,n=!!this.#me;for(const[r,i]of e){const e=r.endsWith("_HCM");n&&e?t.set(r.replace("_HCM",""),i):n||e||t.set(r,i)}return G(this,"highlightColors",t)}get highlightColorNames(){return G(this,"highlightColorNames",this.highlightColors?new Map(Array.from(this.highlightColors,e=>e.reverse())):null)}getNonHCMColor(e){if(!this._highlightColors)return e;const t=this.highlightColorNames.get(e);return this._highlightColors.get(t)||e}getNonHCMColorName(e){return this.highlightColorNames.get(e)||e}setCurrentDrawingSession(e){e?(this.unselectAll(),this.disableUserSelect(!0)):this.disableUserSelect(!1),this.#j=e}setMainHighlightColorPicker(e){this.#le=e}editAltText(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.#N?.editAltText(this,e,t)}hasCommentManager(){return!!this.#$}editComment(e,t,n,r){this.#$?.showDialog(this,e,t,n,r)}selectComment(e,t){const n=this.#R.get(e),r=n?.getEditorByUID(t);r?.toggleComment(!0,!0)}updateComment(e){this.#$?.updateComment(e.getData())}updatePopupColor(e){this.#$?.updatePopupColor(e)}removeComment(e){this.#$?.removeComments([e.uid])}toggleComment(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0;this.#$?.toggleCommentPopup(e,t,n)}makeCommentColor(e,t){return e&&this.#$?.makeCommentColor(e,t)||null}getCommentDialogElement(){return this.#$?.dialogElement||null}async waitForEditorsRendered(e){if(this.#R.has(e-1))return;const{resolve:t,promise:n}=Promise.withResolvers(),r=n=>{n.pageNumber===e&&(this._eventBus._off("editorsrendered",r),t())};this._eventBus.on("editorsrendered",r),await n}getSignature(e){this.#fe?.getSignature({uiManager:this,editor:e})}get signatureManager(){return this.#fe}switchToMode(e,t){this._eventBus.on("annotationeditormodechanged",t,{once:!0,signal:this._signal}),this._eventBus.dispatch("showannotationeditorui",{source:this,mode:e})}setPreference(e,t){this._eventBus.dispatch("setpreference",{source:this,name:e,value:t})}onSetPreference(e){let{name:t,value:n}=e;if("enableNewAltTextWhenAddingImage"===t)this.#X=n}onPageChanging(e){let{pageNumber:t}=e;this.#U=t-1}focusMainContainer(){this.#_e.focus()}findParent(e,t){for(const n of this.#R.values()){const{x:r,y:i,width:s,height:a}=n.div.getBoundingClientRect();if(e>=r&&e<=r+s&&t>=i&&t<=i+a)return n}return null}disableUserSelect(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.#Ae.classList.toggle("noUserSelect",e)}addShouldRescale(e){this.#W.add(e)}removeShouldRescale(e){this.#W.delete(e)}onScaleChanging(e){let{scale:t}=e;this.commitOrRemove(),this.viewParameters.realScale=t*me.PDF_TO_CSS_UNITS;for(const n of this.#W)n.onScaleChanging();this.#j?.onScaleChanging()}onRotationChanging(e){let{pagesRotation:t}=e;this.commitOrRemove(),this.viewParameters.rotation=t}#Te(e){let{anchorNode:t}=e;return t.nodeType===Node.TEXT_NODE?t.parentElement:t}#De(e){const{currentLayer:t}=this;if(t.hasTextLayer(e))return t;for(const n of this.#R.values())if(n.hasTextLayer(e))return n;return null}highlightSelection(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const n=document.getSelection();if(!n||n.isCollapsed)return;const{anchorNode:r,anchorOffset:i,focusNode:s,focusOffset:a}=n,o=n.toString(),l=this.#Te(n).closest(".textLayer"),c=this.getSelectionBoxes(l);if(!c)return;n.empty();const h=this.#De(l),d=this.#de===v.NONE,u=()=>{const n=h?.createAndAddNewEditor({x:0,y:0},!1,{methodOfCreation:e,boxes:c,anchorNode:r,anchorOffset:i,focusNode:s,focusOffset:a,text:o});d&&this.showAllEditors("highlight",!0,!0),t&&n?.editComment()};d?this.switchToMode(v.HIGHLIGHT,u):u()}commentSelection(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";this.highlightSelection(e,!0)}#Me(){const e=document.getSelection();if(!e||e.isCollapsed)return;const t=this.#Te(e).closest(".textLayer"),n=this.getSelectionBoxes(t);n&&(this.#te||=new ze(this),this.#te.show(t,n,"ltr"===this.direction))}getAndRemoveDataFromAnnotationStorage(e){if(!this.#L)return null;const t=`${g}${e}`,n=this.#L.getRawValue(t);return n&&this.#L.remove(t),n}addToAnnotationStorage(e){e.isEmpty()||!this.#L||this.#L.has(e.id)||this.#L.setValue(e.id,e)}a11yAlert(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;const n=this.#xe;n&&(n.setAttribute("data-l10n-id",e),t?n.setAttribute("data-l10n-args",JSON.stringify(t)):n.removeAttribute("data-l10n-args"))}#Pe(){const e=document.getSelection();if(!e||e.isCollapsed)return void(this.#pe&&(this.#te?.hide(),this.#pe=null,this.#Ie({hasSelectedText:!1})));const{anchorNode:t}=e;if(t===this.#pe)return;const n=this.#Te(e).closest(".textLayer");if(n){if(this.#te?.hide(),this.#pe=t,this.#Ie({hasSelectedText:!0}),(this.#de===v.HIGHLIGHT||this.#de===v.NONE)&&(this.#de===v.HIGHLIGHT&&this.showAllEditors("highlight",!0,!0),this.#ee=this.isShiftKeyDown,!this.isShiftKeyDown)){const e=this.#de===v.HIGHLIGHT?this.#De(n):null;if(e?.toggleDrawing(),this.#ie){const t=new AbortController,n=this.combinedSignal(t),r=n=>{"pointerup"===n.type&&0!==n.button||(t.abort(),e?.toggleDrawing(!0),"pointerup"===n.type&&this.#Fe("main_toolbar"))};window.addEventListener("pointerup",r,{signal:n}),window.addEventListener("blur",r,{signal:n})}else e?.toggleDrawing(!0),this.#Fe("main_toolbar")}}else this.#pe&&(this.#te?.hide(),this.#pe=null,this.#Ie({hasSelectedText:!1}))}#Fe(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";this.#de===v.HIGHLIGHT?this.highlightSelection(e):this.#G&&this.#Me()}#Ce(){document.addEventListener("selectionchange",this.#Pe.bind(this),{signal:this._signal})}#Re(){if(this.#J)return;this.#J=new AbortController;const e=this.combinedSignal(this.#J);window.addEventListener("focus",this.focus.bind(this),{signal:e}),window.addEventListener("blur",this.blur.bind(this),{signal:e})}#Ne(){this.#J?.abort(),this.#J=null}blur(){if(this.isShiftKeyDown=!1,this.#ee&&(this.#ee=!1,this.#Fe("main_toolbar")),!this.hasSelection)return;const{activeElement:e}=document;for(const t of this.#ue)if(t.div.contains(e)){this.#oe=[t,e],t._focusEventsAllowed=!1;break}}focus(){if(!this.#oe)return;const[e,t]=this.#oe;this.#oe=null,t.addEventListener("focusin",()=>{e._focusEventsAllowed=!0},{once:!0,signal:this._signal}),t.focus()}#Se(){if(this.#ae)return;this.#ae=new AbortController;const e=this.combinedSignal(this.#ae);window.addEventListener("keydown",this.keydown.bind(this),{signal:e}),window.addEventListener("keyup",this.keyup.bind(this),{signal:e})}#Le(){this.#ae?.abort(),this.#ae=null}#Oe(){if(this.#z)return;this.#z=new AbortController;const e=this.combinedSignal(this.#z);document.addEventListener("copy",this.copy.bind(this),{signal:e}),document.addEventListener("cut",this.cut.bind(this),{signal:e}),document.addEventListener("paste",this.paste.bind(this),{signal:e})}#Be(){this.#z?.abort(),this.#z=null}#ke(){const e=this._signal;document.addEventListener("dragover",this.dragOver.bind(this),{signal:e}),document.addEventListener("drop",this.drop.bind(this),{signal:e})}addEditListeners(){this.#Se(),this.#Oe()}removeEditListeners(){this.#Le(),this.#Be()}dragOver(e){for(const{type:t}of e.dataTransfer.items)for(const n of this.#q)if(n.isHandlingMimeForPasting(t))return e.dataTransfer.dropEffect="copy",void e.preventDefault()}drop(e){for(const t of e.dataTransfer.items)for(const n of this.#q)if(n.isHandlingMimeForPasting(t.type))return n.paste(t,this.currentLayer),void e.preventDefault()}copy(e){if(e.preventDefault(),this.#P?.commitOrRemove(),!this.hasSelection)return;const t=[];for(const n of this.#ue){const e=n.serialize(!0);e&&t.push(e)}0!==t.length&&e.clipboardData.setData("application/pdfjs",JSON.stringify(t))}cut(e){this.copy(e),this.delete()}async paste(e){e.preventDefault();const{clipboardData:t}=e;for(const s of t.items)for(const e of this.#q)if(e.isHandlingMimeForPasting(s.type))return void e.paste(s,this.currentLayer);let n=t.getData("application/pdfjs");if(!n)return;try{n=JSON.parse(n)}catch(i){return void U(`paste: "${i.message}".`)}if(!Array.isArray(n))return;this.unselectAll();const r=this.currentLayer;try{const e=[];for(const s of n){const t=await r.deserialize(s);if(!t)return;e.push(t)}const t=()=>{for(const t of e)this.#$e(t);this.#ze(e)},i=()=>{for(const t of e)t.remove()};this.addCommands({cmd:t,undo:i,mustExec:!0})}catch(i){U(`paste: "${i.message}".`)}}keydown(e){this.isShiftKeyDown||"Shift"!==e.key||(this.isShiftKeyDown=!0),this.#de===v.NONE||this.isEditorHandlingKeyboard||Ge._keyboardManager.exec(this,e)}keyup(e){this.isShiftKeyDown&&"Shift"===e.key&&(this.isShiftKeyDown=!1,this.#ee&&(this.#ee=!1,this.#Fe("main_toolbar")))}onEditingAction(e){let{name:t}=e;switch(t){case"undo":case"redo":case"delete":case"selectAll":this[t]();break;case"highlightSelection":this.highlightSelection("context_menu");break;case"commentSelection":this.commentSelection("context_menu")}}#Ie(e){Object.entries(e).some(e=>{let[t,n]=e;return this.#ye[t]!==n})&&(this._eventBus.dispatch("annotationeditorstateschanged",{source:this,details:Object.assign(this.#ye,e)}),this.#de===v.HIGHLIGHT&&!1===e.hasSelectedEditor&&this.#je([[y.HIGHLIGHT_FREE,!0]]))}#je(e){this._eventBus.dispatch("annotationeditorparamschanged",{source:this,details:e})}setEditingState(e){e?(this.#Re(),this.#Oe(),this.#Ie({isEditing:this.#de!==v.NONE,isEmpty:this.#Ue(),hasSomethingToUndo:this.#B.hasSomethingToUndo(),hasSomethingToRedo:this.#B.hasSomethingToRedo(),hasSelectedEditor:!1})):(this.#Ne(),this.#Be(),this.#Ie({isEditing:!1}),this.disableUserSelect(!1))}registerEditorTypes(e){if(!this.#q){this.#q=e;for(const e of this.#q)this.#je(e.defaultPropertiesToUpdate)}}getId(){return this.#ne.id}get currentLayer(){return this.#R.get(this.#U)}getLayer(e){return this.#R.get(e)}get currentPageIndex(){return this.#U}addLayer(e){this.#R.set(e.pageIndex,e),this.#re?e.enable():e.disable()}removeLayer(e){this.#R.delete(e.pageIndex)}async updateMode(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],i=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(this.#de!==e&&(!this.#Ee||(await this.#Ee.promise,this.#Ee))){if(this.#Ee=Promise.withResolvers(),this.#j?.commitOrRemove(),this.#de===v.POPUP&&this.#$?.hideSidebar(),this.#$?.destroyPopup(),this.#de=e,e===v.NONE){this.setEditingState(!1),this.#He();for(const e of this.#F.values())e.hideStandaloneCommentButton();return this._editorUndoBar?.hide(),this.toggleComment(null),void this.#Ee.resolve()}for(const e of this.#F.values())e.addStandaloneCommentButton();e===v.SIGNATURE&&await(this.#fe?.loadSignatures()),this.setEditingState(!0),await this.#Ve(),this.unselectAll();for(const t of this.#R.values())t.updateMode(e);if(e===v.POPUP){this.#I||=await this.#ve.getAnnotationsByType(new Set(this.#q.map(e=>e._editorType)));const e=new Set,t=[];for(const n of this.#F.values()){const{annotationElementId:r,hasComment:i,deleted:s}=n;r&&e.add(r),i&&!s&&t.push(n.getData())}for(const n of this.#I){const{id:r,popupRef:i,contentsObj:s}=n;i&&s?.str&&!e.has(r)&&!this.#H.has(r)&&t.push(n)}this.#$?.showSidebar(t)}if(!t)return n&&this.addNewEditorFromKeyboard(),void this.#Ee.resolve();for(const e of this.#F.values())e.uid===t?(this.setSelected(e),i?e.editComment():r?e.enterInEditMode():e.focus()):e.unselect();this.#Ee.resolve()}}addNewEditorFromKeyboard(){this.currentLayer.canCreateNewEmptyEditor()&&this.currentLayer.addNewEditor()}updateToolbar(e){e.mode!==this.#de&&this._eventBus.dispatch("switchannotationeditormode",{source:this,...e})}updateParams(e,t){if(this.#q){switch(e){case y.CREATE:return void this.currentLayer.addNewEditor(t);case y.HIGHLIGHT_SHOW_ALL:this._eventBus.dispatch("reporttelemetry",{source:this,details:{type:"editing",data:{type:"highlight",action:"toggle_visibility"}}}),(this.#ge||=new Map).set(e,t),this.showAllEditors("highlight",t)}if(this.hasSelection)for(const n of this.#ue)n.updateParams(e,t);else for(const n of this.#q)n.updateDefaultParams(e,t)}}showAllEditors(e,t){for(const n of this.#F.values())n.editorType===e&&n.show(t);(this.#ge?.get(y.HIGHLIGHT_SHOW_ALL)??!0)!==t&&this.#je([[y.HIGHLIGHT_SHOW_ALL,t]])}enableWaiting(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.#se!==e){this.#se=e;for(const t of this.#R.values())e?t.disableClick():t.enableClick(),t.div.classList.toggle("waiting",e)}}async#Ve(){if(!this.#re){this.#re=!0;const e=[];for(const t of this.#R.values())e.push(t.enable());await Promise.all(e);for(const t of this.#F.values())t.enable()}}#He(){if(this.unselectAll(),this.#re){this.#re=!1;for(const e of this.#R.values())e.disable();for(const e of this.#F.values())e.disable()}}*getEditors(e){for(const t of this.#F.values())t.pageIndex===e&&(yield t)}getEditor(e){return this.#F.get(e)}addEditor(e){this.#F.set(e.id,e)}removeEditor(e){e.div.contains(document.activeElement)&&(this.#Z&&clearTimeout(this.#Z),this.#Z=setTimeout(()=>{this.focusMainContainer(),this.#Z=null},0)),this.#F.delete(e.id),e.annotationElementId&&this.#ce?.delete(e.annotationElementId),this.unselect(e),e.annotationElementId&&this.#H.has(e.annotationElementId)||this.#L?.remove(e.id)}addDeletedAnnotationElement(e){this.#H.add(e.annotationElementId),this.addChangedExistingAnnotation(e),e.deleted=!0}isDeletedAnnotationElement(e){return this.#H.has(e)}removeDeletedAnnotationElement(e){this.#H.delete(e.annotationElementId),this.removeChangedExistingAnnotation(e),e.deleted=!1}#$e(e){const t=this.#R.get(e.pageIndex);t?t.addOrRebuild(e):(this.addEditor(e),this.addToAnnotationStorage(e))}setActiveEditor(e){this.#P!==e&&(this.#P=e,e&&this.#je(e.propertiesToUpdate))}get#qe(){let e=null;for(e of this.#ue);return e}updateUI(e){this.#qe===e&&this.#je(e.propertiesToUpdate)}updateUIForDefaultProperties(e){this.#je(e.defaultPropertiesToUpdate)}toggleSelected(e){if(this.#ue.has(e))return this.#ue.delete(e),e.unselect(),void this.#Ie({hasSelectedEditor:this.hasSelection});this.#ue.add(e),e.select(),this.#je(e.propertiesToUpdate),this.#Ie({hasSelectedEditor:!0})}setSelected(e){this.updateToolbar({mode:e.mode,editId:e.id}),this.#j?.commitOrRemove();for(const t of this.#ue)t!==e&&t.unselect();this.#ue.clear(),this.#ue.add(e),e.select(),this.#je(e.propertiesToUpdate),this.#Ie({hasSelectedEditor:!0})}isSelected(e){return this.#ue.has(e)}get firstSelectedEditor(){return this.#ue.values().next().value}unselect(e){e.unselect(),this.#ue.delete(e),this.#Ie({hasSelectedEditor:this.hasSelection})}get hasSelection(){return 0!==this.#ue.size}get isEnterHandled(){return 1===this.#ue.size&&this.firstSelectedEditor.isEnterHandled}undo(){this.#B.undo(),this.#Ie({hasSomethingToUndo:this.#B.hasSomethingToUndo(),hasSomethingToRedo:!0,isEmpty:this.#Ue()}),this._editorUndoBar?.hide()}redo(){this.#B.redo(),this.#Ie({hasSomethingToUndo:!0,hasSomethingToRedo:this.#B.hasSomethingToRedo(),isEmpty:this.#Ue()})}addCommands(e){this.#B.add(e),this.#Ie({hasSomethingToUndo:!0,hasSomethingToRedo:!1,isEmpty:this.#Ue()})}cleanUndoStack(e){this.#B.cleanType(e)}#Ue(){if(0===this.#F.size)return!0;if(1===this.#F.size)for(const e of this.#F.values())return e.isEmpty();return!1}delete(){this.commitOrRemove();const e=this.currentLayer?.endDrawingSession(!0);if(!this.hasSelection&&!e)return;const t=e?[e]:[...this.#ue],n=()=>{for(const e of t)this.#$e(e)};this.addCommands({cmd:()=>{this._editorUndoBar?.show(n,1===t.length?t[0].editorType:t.length);for(const e of t)e.remove()},undo:n,mustExec:!0})}commitOrRemove(){this.#P?.commitOrRemove()}hasSomethingToControl(){return this.#P||this.hasSelection}#ze(e){for(const t of this.#ue)t.unselect();this.#ue.clear();for(const t of e)t.isEmpty()||(this.#ue.add(t),t.select());this.#Ie({hasSelectedEditor:this.hasSelection})}selectAll(){for(const e of this.#ue)e.commit();this.#ze(this.#F.values())}unselectAll(){if((!this.#P||(this.#P.commitOrRemove(),this.#de===v.NONE))&&!this.#j?.commitOrRemove()&&this.hasSelection){for(const e of this.#ue)e.unselect();this.#ue.clear(),this.#Ie({hasSelectedEditor:!1})}}translateSelectedEditors(e,t){if(arguments.length>2&&void 0!==arguments[2]&&arguments[2]||this.commitOrRemove(),!this.hasSelection)return;this.#be[0]+=e,this.#be[1]+=t;const[n,r]=this.#be,i=[...this.#ue];this.#we&&clearTimeout(this.#we),this.#we=setTimeout(()=>{this.#we=null,this.#be[0]=this.#be[1]=0,this.addCommands({cmd:()=>{for(const e of i)this.#F.has(e.id)&&(e.translateInPage(n,r),e.translationDone())},undo:()=>{for(const e of i)this.#F.has(e.id)&&(e.translateInPage(-n,-r),e.translationDone())},mustExec:!1})},1e3);for(const s of i)s.translateInPage(e,t),s.translationDone()}setUpDragSession(){if(this.hasSelection){this.disableUserSelect(!0),this.#V=new Map;for(const e of this.#ue)this.#V.set(e,{savedX:e.x,savedY:e.y,savedPageIndex:e.pageIndex,newX:0,newY:0,newPageIndex:-1})}}endDragSession(){if(!this.#V)return!1;this.disableUserSelect(!1);const e=this.#V;this.#V=null;let t=!1;for(const[{x:r,y:i,pageIndex:s},a]of e)a.newX=r,a.newY=i,a.newPageIndex=s,t||=r!==a.savedX||i!==a.savedY||s!==a.savedPageIndex;if(!t)return!1;const n=(e,t,n,r)=>{if(this.#F.has(e.id)){const i=this.#R.get(r);i?e._setParentAndPosition(i,t,n):(e.pageIndex=r,e.x=t,e.y=n)}};return this.addCommands({cmd:()=>{for(const[t,{newX:r,newY:i,newPageIndex:s}]of e)n(t,r,i,s)},undo:()=>{for(const[t,{savedX:r,savedY:i,savedPageIndex:s}]of e)n(t,r,i,s)},mustExec:!0}),!0}dragSelectedEditors(e,t){if(this.#V)for(const n of this.#V.keys())n.drag(e,t)}rebuild(e){if(null===e.parent){const t=this.getLayer(e.pageIndex);t?(t.changeParent(e),t.addOrRebuild(e)):(this.addEditor(e),this.addToAnnotationStorage(e),e.rebuild())}else e.parent.addOrRebuild(e)}get isEditorHandlingKeyboard(){return this.getActive()?.shouldGetKeyboardEvents()||1===this.#ue.size&&this.firstSelectedEditor.shouldGetKeyboardEvents()}isActive(e){return this.#P===e}getActive(){return this.#P}getMode(){return this.#de}isEditingMode(){return this.#de!==v.NONE}get imageManager(){return G(this,"imageManager",new He)}getSelectionBoxes(e){if(!e)return null;const t=document.getSelection();for(let l=0,c=t.rangeCount;l<c;l++)if(!e.contains(t.getRangeAt(l).commonAncestorContainer))return null;const{x:n,y:r,width:i,height:s}=e.getBoundingClientRect();let a;switch(e.getAttribute("data-main-rotation")){case"90":a=(e,t,a,o)=>({x:(t-r)/s,y:1-(e+a-n)/i,width:o/s,height:a/i});break;case"180":a=(e,t,a,o)=>({x:1-(e+a-n)/i,y:1-(t+o-r)/s,width:a/i,height:o/s});break;case"270":a=(e,t,a,o)=>({x:1-(t+o-r)/s,y:(e-n)/i,width:o/s,height:a/i});break;default:a=(e,t,a,o)=>({x:(e-n)/i,y:(t-r)/s,width:a/i,height:o/s})}const o=[];for(let l=0,c=t.rangeCount;l<c;l++){const e=t.getRangeAt(l);if(!e.collapsed)for(const{x:t,y:n,width:r,height:i}of e.getClientRects())0!==r&&0!==i&&o.push(a(t,n,r,i))}return 0===o.length?null:o}addChangedExistingAnnotation(e){let{annotationElementId:t,id:n}=e;(this.#O||=new Map).set(t,n)}removeChangedExistingAnnotation(e){let{annotationElementId:t}=e;this.#O?.delete(t)}renderAnnotationElement(e){const t=this.#O?.get(e.data.id);if(!t)return;const n=this.#L.getRawValue(t);n&&(this.#de!==v.NONE||n.hasBeenModified)&&n.renderAnnotationElement(e)}setMissingCanvas(e,t,n){const r=this.#ce?.get(e);r&&(r.setCanvas(t,n),this.#ce.delete(e))}addMissingCanvas(e,t){(this.#ce||=new Map).set(e,t)}}class Ke{#o=null;#We=!1;#Ge=null;#Ke=null;#Xe=null;#Ye=null;#Ze=!1;#Je=null;#s=null;#Qe=null;#et=null;#tt=!1;static#nt=null;static _l10n=null;constructor(e){this.#s=e,this.#tt=e._uiManager.useNewAltTextFlow,Ke.#nt||=Object.freeze({added:"pdfjs-editor-new-alt-text-added-button","added-label":"pdfjs-editor-new-alt-text-added-button-label",missing:"pdfjs-editor-new-alt-text-missing-button","missing-label":"pdfjs-editor-new-alt-text-missing-button-label",review:"pdfjs-editor-new-alt-text-to-review-button","review-label":"pdfjs-editor-new-alt-text-to-review-button-label"})}static initialize(e){Ke._l10n??=e}async render(){const e=this.#Ge=document.createElement("button");e.className="altText",e.tabIndex="0";const t=this.#Ke=document.createElement("span");e.append(t),this.#tt?(e.classList.add("new"),e.setAttribute("data-l10n-id",Ke.#nt.missing),t.setAttribute("data-l10n-id",Ke.#nt["missing-label"])):(e.setAttribute("data-l10n-id","pdfjs-editor-alt-text-button"),t.setAttribute("data-l10n-id","pdfjs-editor-alt-text-button-label"));const n=this.#s._uiManager._signal;e.addEventListener("contextmenu",xe,{signal:n}),e.addEventListener("pointerdown",e=>e.stopPropagation(),{signal:n});const r=e=>{e.preventDefault(),this.#s._uiManager.editAltText(this.#s),this.#tt&&this.#s._reportTelemetry({action:"pdfjs.image.alt_text.image_status_label_clicked",data:{label:this.#rt}})};return e.addEventListener("click",r,{capture:!0,signal:n}),e.addEventListener("keydown",t=>{t.target===e&&"Enter"===t.key&&(this.#Ze=!0,r(t))},{signal:n}),await this.#it(),e}get#rt(){return(this.#o?"added":null===this.#o&&this.guessedText&&"review")||"missing"}finish(){this.#Ge&&(this.#Ge.focus({focusVisible:this.#Ze}),this.#Ze=!1)}isEmpty(){return this.#tt?null===this.#o:!this.#o&&!this.#We}hasData(){return this.#tt?null!==this.#o||!!this.#Qe:this.isEmpty()}get guessedText(){return this.#Qe}async setGuessedText(e){null===this.#o&&(this.#Qe=e,this.#et=await Ke._l10n.get("pdfjs-editor-new-alt-text-generated-alt-text-with-disclaimer",{generatedAltText:e}),this.#it())}toggleAltTextBadge(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(!this.#tt||this.#o)return this.#Je?.remove(),void(this.#Je=null);if(!this.#Je){const e=this.#Je=document.createElement("div");e.className="noAltTextBadge",this.#s.div.append(e)}this.#Je.classList.toggle("hidden",!e)}serialize(e){let t=this.#o;return e||this.#Qe!==t||(t=this.#et),{altText:t,decorative:this.#We,guessedText:this.#Qe,textWithDisclaimer:this.#et}}get data(){return{altText:this.#o,decorative:this.#We}}set data(e){let{altText:t,decorative:n,guessedText:r,textWithDisclaimer:i,cancel:s=!1}=e;r&&(this.#Qe=r,this.#et=i),this.#o===t&&this.#We===n||(s||(this.#o=t,this.#We=n),this.#it())}toggle(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.#Ge&&(!e&&this.#Ye&&(clearTimeout(this.#Ye),this.#Ye=null),this.#Ge.disabled=!e)}shown(){this.#s._reportTelemetry({action:"pdfjs.image.alt_text.image_status_label_displayed",data:{label:this.#rt}})}destroy(){this.#Ge?.remove(),this.#Ge=null,this.#Ke=null,this.#Xe=null,this.#Je?.remove(),this.#Je=null}async#it(){const e=this.#Ge;if(!e)return;if(this.#tt){if(e.classList.toggle("done",!!this.#o),e.setAttribute("data-l10n-id",Ke.#nt[this.#rt]),this.#Ke?.setAttribute("data-l10n-id",Ke.#nt[`${this.#rt}-label`]),!this.#o)return void this.#Xe?.remove()}else{if(!this.#o&&!this.#We)return e.classList.remove("done"),void this.#Xe?.remove();e.classList.add("done"),e.setAttribute("data-l10n-id","pdfjs-editor-alt-text-edit-button")}let t=this.#Xe;if(!t){this.#Xe=t=document.createElement("span"),t.className="tooltip",t.setAttribute("role","tooltip"),t.id=`alt-text-tooltip-${this.#s.id}`;const n=100,r=this.#s._uiManager._signal;r.addEventListener("abort",()=>{clearTimeout(this.#Ye),this.#Ye=null},{once:!0}),e.addEventListener("mouseenter",()=>{this.#Ye=setTimeout(()=>{this.#Ye=null,this.#Xe.classList.add("show"),this.#s._reportTelemetry({action:"alt_text_tooltip"})},n)},{signal:r}),e.addEventListener("mouseleave",()=>{this.#Ye&&(clearTimeout(this.#Ye),this.#Ye=null),this.#Xe?.classList.remove("show")},{signal:r})}this.#We?t.setAttribute("data-l10n-id","pdfjs-editor-alt-text-decorative-tooltip"):(t.removeAttribute("data-l10n-id"),t.textContent=this.#o),t.parentNode||e.append(t);const n=this.#s.getElementForAltText();n?.setAttribute("aria-describedby",t.id)}}class Xe{#st=null;#at=null;#ot=!1;#s=null;#lt=null;#ct=null;#ht=null;#dt=null;#ut=!1;#pt=null;constructor(e){this.#s=e}renderForToolbar(){const e=this.#at=document.createElement("button");return e.className="comment",this.#y(e,!1)}renderForStandalone(){const e=this.#st=document.createElement("button");e.className="annotationCommentButton";const t=this.#s.commentButtonPosition;if(t){const{style:n}=e;n.insetInlineEnd=`calc(${100*("ltr"===this.#s._uiManager.direction?1-t[0]:t[0])}% - var(--comment-button-dim))`,n.top=`calc(${100*t[1]}% - var(--comment-button-dim))`;const r=this.#s.commentButtonColor;r&&(n.backgroundColor=r)}return this.#y(e,!0)}focusButton(){setTimeout(()=>{(this.#st??this.#at)?.focus()},0)}onUpdatedColor(){if(!this.#st)return;const e=this.#s.commentButtonColor;e&&(this.#st.style.backgroundColor=e),this.#s._uiManager.updatePopupColor(this.#s)}get commentButtonWidth(){return(this.#st?.getBoundingClientRect().width??0)/this.#s.parent.boundingClientRect.width}get commentPopupPositionInLayer(){if(this.#pt)return this.#pt;if(!this.#st)return null;const{x:e,y:t,height:n}=this.#st.getBoundingClientRect(),{x:r,y:i,width:s,height:a}=this.#s.parent.boundingClientRect;return[(e-r)/s,(t+n-i)/a]}set commentPopupPositionInLayer(e){this.#pt=e}hasDefaultPopupPosition(){return null===this.#pt}removeStandaloneCommentButton(){this.#st?.remove(),this.#st=null}removeToolbarCommentButton(){this.#at?.remove(),this.#at=null}setCommentButtonStates(e){let{selected:t,hasPopup:n}=e;this.#st&&(this.#st.classList.toggle("selected",t),this.#st.ariaExpanded=n)}#y(e,t){if(!this.#s._uiManager.hasCommentManager())return null;e.tabIndex="0",e.ariaHasPopup="dialog",t?(e.ariaControls="commentPopup",e.setAttribute("data-l10n-id","pdfjs-show-comment-button")):(e.ariaControlsElements=[this.#s._uiManager.getCommentDialogElement()],e.setAttribute("data-l10n-id","pdfjs-editor-edit-comment-button"));const n=this.#s._uiManager._signal;if(!(n instanceof AbortSignal)||n.aborted)return e;e.addEventListener("contextmenu",xe,{signal:n}),t&&(e.addEventListener("focusin",e=>{this.#s._focusEventsAllowed=!1,Ee(e)},{capture:!0,signal:n}),e.addEventListener("focusout",e=>{this.#s._focusEventsAllowed=!0,Ee(e)},{capture:!0,signal:n})),e.addEventListener("pointerdown",e=>e.stopPropagation(),{signal:n});const r=t=>{t.preventDefault(),e===this.#at?this.edit():this.#s.toggleComment(!0)};return e.addEventListener("click",r,{capture:!0,signal:n}),e.addEventListener("keydown",t=>{t.target===e&&"Enter"===t.key&&(this.#ot=!0,r(t))},{signal:n}),e.addEventListener("pointerenter",()=>{this.#s.toggleComment(!1,!0)},{signal:n}),e.addEventListener("pointerleave",()=>{this.#s.toggleComment(!1,!1)},{signal:n}),e}edit(e){const t=this.commentPopupPositionInLayer;let n,r;if(t)[n,r]=t;else{[n,r]=this.#s.commentButtonPosition;const{width:e,height:t,x:i,y:s}=this.#s;n=i+n*e,r=s+r*t}const i=this.#s.parent.boundingClientRect,{x:s,y:a,width:o,height:l}=i;this.#s._uiManager.editComment(this.#s,s+n*o,a+r*l,{...e,parentDimensions:i})}finish(){this.#at&&(this.#at.focus({focusVisible:this.#ot}),this.#ot=!1)}isDeleted(){return this.#ut||""===this.#ht}isEmpty(){return null===this.#ht}hasBeenEdited(){return this.isDeleted()||this.#ht!==this.#lt}serialize(){return this.data}get data(){return{text:this.#ht,richText:this.#ct,date:this.#dt,deleted:this.isDeleted()}}set data(e){if(e!==this.#ht&&(this.#ct=null),null===e)return this.#ht="",void(this.#ut=!0);this.#ht=e,this.#dt=new Date,this.#ut=!1}setInitialText(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.#lt=e,this.data=e,this.#dt=null,this.#ct=t}shown(){}destroy(){this.#at?.remove(),this.#at=null,this.#st?.remove(),this.#st=null,this.#ht="",this.#ct=null,this.#dt=null,this.#s=null,this.#ot=!1,this.#ut=!1}}class Ye{#_e;#ft=!1;#mt=null;#gt;#vt;#yt;#bt;#wt=null;#_t;#At=null;#xt;#Et=null;constructor(e){let{container:t,isPinchingDisabled:n=null,isPinchingStopped:r=null,onPinchStart:i=null,onPinching:s=null,onPinchEnd:a=null,signal:o}=e;this.#_e=t,this.#mt=r,this.#gt=n,this.#vt=i,this.#yt=s,this.#bt=a,this.#xt=new AbortController,this.#_t=AbortSignal.any([o,this.#xt.signal]),t.addEventListener("touchstart",this.#Ct.bind(this),{passive:!1,signal:this.#_t})}get MIN_TOUCH_DISTANCE_TO_PINCH(){return 35/Me.pixelRatio}#Ct(e){if(this.#gt?.())return;if(1===e.touches.length){if(this.#wt)return;const e=this.#wt=new AbortController,t=AbortSignal.any([this.#_t,e.signal]),n=this.#_e,r={capture:!0,signal:t,passive:!1},i=e=>{"touch"===e.pointerType&&(this.#wt?.abort(),this.#wt=null)};return n.addEventListener("pointerdown",e=>{"touch"===e.pointerType&&(Ee(e),i(e))},r),n.addEventListener("pointerup",i,r),void n.addEventListener("pointercancel",i,r)}if(!this.#Et){this.#Et=new AbortController;const e=AbortSignal.any([this.#_t,this.#Et.signal]),t=this.#_e,n={signal:e,capture:!1,passive:!1};t.addEventListener("touchmove",this.#kt.bind(this),n);const r=this.#St.bind(this);t.addEventListener("touchend",r,n),t.addEventListener("touchcancel",r,n),n.capture=!0,t.addEventListener("pointerdown",Ee,n),t.addEventListener("pointermove",Ee,n),t.addEventListener("pointercancel",Ee,n),t.addEventListener("pointerup",Ee,n),this.#vt?.()}if(Ee(e),2!==e.touches.length||this.#mt?.())return void(this.#At=null);let[t,n]=e.touches;t.identifier>n.identifier&&([t,n]=[n,t]),this.#At={touch0X:t.screenX,touch0Y:t.screenY,touch1X:n.screenX,touch1Y:n.screenY}}#kt(e){if(!this.#At||2!==e.touches.length)return;Ee(e);let[t,n]=e.touches;t.identifier>n.identifier&&([t,n]=[n,t]);const{screenX:r,screenY:i}=t,{screenX:s,screenY:a}=n,o=this.#At,{touch0X:l,touch0Y:c,touch1X:h,touch1Y:d}=o,u=h-l,p=d-c,f=s-r,m=a-i,g=Math.hypot(f,m)||1,v=Math.hypot(u,p)||1;if(!this.#ft&&Math.abs(v-g)<=Ye.MIN_TOUCH_DISTANCE_TO_PINCH)return;if(o.touch0X=r,o.touch0Y=i,o.touch1X=s,o.touch1Y=a,!this.#ft)return void(this.#ft=!0);const y=[(r+s)/2,(i+a)/2];this.#yt?.(y,v,g)}#St(e){e.touches.length>=2||(this.#Et&&(this.#Et.abort(),this.#Et=null,this.#bt?.()),this.#At&&(Ee(e),this.#At=null,this.#ft=!1))}destroy(){this.#xt?.abort(),this.#xt=null,this.#wt?.abort(),this.#wt=null}}class Ze{#Tt=null;#Dt=null;#o=null;#l=null;#st=null;#Mt=!1;#Pt=null;#It="";#Ft=null;#Rt=null;#Nt=null;#Lt=null;#Ot=null;#Bt="";#$t=!1;#zt=null;#jt=!1;#Ut=!1;#Ht=!1;#Vt=null;#qt=0;#Wt=0;#Gt=null;#Kt=null;isSelected=!1;_isCopy=!1;_editToolbar=null;_initialOptions=(()=>Object.create(null))();_initialData=null;_isVisible=!0;_uiManager=null;_focusEventsAllowed=!0;static _l10n=null;static _l10nResizer=null;#Xt=!1;#Yt=(()=>Ze._zIndex++)();static _borderLineWidth=-1;static _colorManager=(()=>new We)();static _zIndex=1;static _telemetryTimeout=1e3;static get _resizerKeyboardManager(){const e=Ze.prototype._resizeWithKeyboard,t=Ge.TRANSLATE_SMALL,n=Ge.TRANSLATE_BIG;return G(this,"_resizerKeyboardManager",new qe([[["ArrowLeft","mac+ArrowLeft"],e,{args:[-t,0]}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],e,{args:[-n,0]}],[["ArrowRight","mac+ArrowRight"],e,{args:[t,0]}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],e,{args:[n,0]}],[["ArrowUp","mac+ArrowUp"],e,{args:[0,-t]}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],e,{args:[0,-n]}],[["ArrowDown","mac+ArrowDown"],e,{args:[0,t]}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],e,{args:[0,n]}],[["Escape","mac+Escape"],Ze.prototype._stopResizingWithKeyboard]]))}constructor(e){this.parent=e.parent,this.id=e.id,this.width=this.height=null,this.pageIndex=e.parent.pageIndex,this.name=e.name,this.div=null,this._uiManager=e.uiManager,this.annotationElementId=null,this._willKeepAspectRatio=!1,this._initialOptions.isCentered=e.isCentered,this._structTreeParentId=null,this.annotationElementId=e.annotationElementId||null,this.creationDate=e.creationDate||new Date,this.modificationDate=e.modificationDate||null;const{rotation:t,rawDims:{pageWidth:n,pageHeight:r,pageX:i,pageY:s}}=this.parent.viewport;this.rotation=t,this.pageRotation=(360+t-this._uiManager.viewParameters.rotation)%360,this.pageDimensions=[n,r],this.pageTranslation=[i,s];const[a,o]=this.parentDimensions;this.x=e.x/a,this.y=e.y/o,this.isAttachedToDOM=!1,this.deleted=!1}get editorType(){return Object.getPrototypeOf(this).constructor._type}get mode(){return Object.getPrototypeOf(this).constructor._editorType}static get isDrawer(){return!1}static get _defaultLineColor(){return G(this,"_defaultLineColor",this._colorManager.getHexCode("CanvasText"))}static deleteAnnotationElement(e){const t=new Je({id:e.parent.getNextId(),parent:e.parent,uiManager:e._uiManager});t.annotationElementId=e.annotationElementId,t.deleted=!0,t._uiManager.addToAnnotationStorage(t)}static initialize(e,t){if(Ze._l10n??=e,Ze._l10nResizer||=Object.freeze({topLeft:"pdfjs-editor-resizer-top-left",topMiddle:"pdfjs-editor-resizer-top-middle",topRight:"pdfjs-editor-resizer-top-right",middleRight:"pdfjs-editor-resizer-middle-right",bottomRight:"pdfjs-editor-resizer-bottom-right",bottomMiddle:"pdfjs-editor-resizer-bottom-middle",bottomLeft:"pdfjs-editor-resizer-bottom-left",middleLeft:"pdfjs-editor-resizer-middle-left"}),-1!==Ze._borderLineWidth)return;const n=getComputedStyle(document.documentElement);Ze._borderLineWidth=parseFloat(n.getPropertyValue("--outline-width"))||0}static updateDefaultParams(e,t){}static get defaultPropertiesToUpdate(){return[]}static isHandlingMimeForPasting(e){return!1}static paste(e,t){H("Not implemented")}get propertiesToUpdate(){return[]}get _isDraggable(){return this.#Xt}set _isDraggable(e){this.#Xt=e,this.div?.classList.toggle("draggable",e)}get uid(){return this.annotationElementId||this.id}get isEnterHandled(){return!0}center(){const[e,t]=this.pageDimensions;switch(this.parentRotation){case 90:this.x-=this.height*t/(2*e),this.y+=this.width*e/(2*t);break;case 180:this.x+=this.width/2,this.y+=this.height/2;break;case 270:this.x+=this.height*t/(2*e),this.y-=this.width*e/(2*t);break;default:this.x-=this.width/2,this.y-=this.height/2}this.fixAndSetPosition()}addCommands(e){this._uiManager.addCommands(e)}get currentLayer(){return this._uiManager.currentLayer}setInBackground(){this.div.style.zIndex=0}setInForeground(){this.div.style.zIndex=this.#Yt}setParent(e){null!==e?(this.pageIndex=e.pageIndex,this.pageDimensions=e.pageDimensions):(this.#Zt(),this.#Lt?.remove(),this.#Lt=null),this.parent=e}focusin(e){this._focusEventsAllowed&&(this.#$t?this.#$t=!1:this.parent.setSelected(this))}focusout(e){if(!this._focusEventsAllowed)return;if(!this.isAttachedToDOM)return;const t=e.relatedTarget;t?.closest(`#${this.id}`)||(e.preventDefault(),this.parent?.isMultipleSelection||this.commitOrRemove())}commitOrRemove(){this.isEmpty()?this.remove():this.commit()}commit(){this.isInEditMode()&&this.addToAnnotationStorage()}addToAnnotationStorage(){this._uiManager.addToAnnotationStorage(this)}setAt(e,t,n,r){const[i,s]=this.parentDimensions;[n,r]=this.screenToPageTranslation(n,r),this.x=(e+n)/i,this.y=(t+r)/s,this.fixAndSetPosition()}_moveAfterPaste(e,t){const[n,r]=this.parentDimensions;this.setAt(e*n,t*r,this.width*n,this.height*r),this._onTranslated()}#Jt(e,t,n){let[r,i]=e;[t,n]=this.screenToPageTranslation(t,n),this.x+=t/r,this.y+=n/i,this._onTranslating(this.x,this.y),this.fixAndSetPosition()}translate(e,t){this.#Jt(this.parentDimensions,e,t)}translateInPage(e,t){this.#zt||=[this.x,this.y,this.width,this.height],this.#Jt(this.pageDimensions,e,t),this.div.scrollIntoView({block:"nearest"})}translationDone(){this._onTranslated(this.x,this.y)}drag(e,t){this.#zt||=[this.x,this.y,this.width,this.height];const{div:n,parentDimensions:[r,i]}=this;if(this.x+=e/r,this.y+=t/i,this.parent&&(this.x<0||this.x>1||this.y<0||this.y>1)){const{x:e,y:t}=this.div.getBoundingClientRect();this.parent.findNewParent(this,e,t)&&(this.x-=Math.floor(this.x),this.y-=Math.floor(this.y))}let{x:s,y:a}=this;const[o,l]=this.getBaseTranslation();s+=o,a+=l;const{style:c}=n;c.left=`${(100*s).toFixed(2)}%`,c.top=`${(100*a).toFixed(2)}%`,this._onTranslating(s,a),n.scrollIntoView({block:"nearest"})}_onTranslating(e,t){}_onTranslated(e,t){}get _hasBeenMoved(){return!!this.#zt&&(this.#zt[0]!==this.x||this.#zt[1]!==this.y)}get _hasBeenResized(){return!!this.#zt&&(this.#zt[2]!==this.width||this.#zt[3]!==this.height)}getBaseTranslation(){const[e,t]=this.parentDimensions,{_borderLineWidth:n}=Ze,r=n/e,i=n/t;switch(this.rotation){case 90:return[-r,i];case 180:return[r,i];case 270:return[r,-i];default:return[-r,-i]}}get _mustFixPosition(){return!0}fixAndSetPosition(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.rotation;const{div:{style:t},pageDimensions:[n,r]}=this;let{x:i,y:s,width:a,height:o}=this;if(a*=n,o*=r,i*=n,s*=r,this._mustFixPosition)switch(e){case 0:i=he(i,0,n-a),s=he(s,0,r-o);break;case 90:i=he(i,0,n-o),s=he(s,a,r);break;case 180:i=he(i,a,n),s=he(s,o,r);break;case 270:i=he(i,o,n),s=he(s,0,r-a)}this.x=i/=n,this.y=s/=r;const[l,c]=this.getBaseTranslation();i+=l,s+=c,t.left=`${(100*i).toFixed(2)}%`,t.top=`${(100*s).toFixed(2)}%`,this.moveInDOM()}static#Qt(e,t,n){switch(n){case 90:return[t,-e];case 180:return[-e,-t];case 270:return[-t,e];default:return[e,t]}}screenToPageTranslation(e,t){return Ze.#Qt(e,t,this.parentRotation)}pageTranslationToScreen(e,t){return Ze.#Qt(e,t,360-this.parentRotation)}#en(e){switch(e){case 90:{const[e,t]=this.pageDimensions;return[0,-e/t,t/e,0]}case 180:return[-1,0,0,-1];case 270:{const[e,t]=this.pageDimensions;return[0,e/t,-t/e,0]}default:return[1,0,0,1]}}get parentScale(){return this._uiManager.viewParameters.realScale}get parentRotation(){return(this._uiManager.viewParameters.rotation+this.pageRotation)%360}get parentDimensions(){const{parentScale:e,pageDimensions:[t,n]}=this;return[t*e,n*e]}setDims(){const{div:{style:e},width:t,height:n}=this;e.width=`${(100*t).toFixed(2)}%`,e.height=`${(100*n).toFixed(2)}%`}getInitialTranslation(){return[0,0]}#tn(){if(this.#Ft)return;this.#Ft=document.createElement("div"),this.#Ft.classList.add("resizers");const e=this._willKeepAspectRatio?["topLeft","topRight","bottomRight","bottomLeft"]:["topLeft","topMiddle","topRight","middleRight","bottomRight","bottomMiddle","bottomLeft","middleLeft"],t=this._uiManager._signal;for(const n of e){const e=document.createElement("div");this.#Ft.append(e),e.classList.add("resizer",n),e.setAttribute("data-resizer-name",n),e.addEventListener("pointerdown",this.#nn.bind(this,n),{signal:t}),e.addEventListener("contextmenu",xe,{signal:t}),e.tabIndex=-1}this.div.prepend(this.#Ft)}#nn(e,t){t.preventDefault();const{isMac:n}=re.platform;if(0!==t.button||t.ctrlKey&&n)return;this.#o?.toggle(!1);const r=this._isDraggable;this._isDraggable=!1,this.#Rt=[t.screenX,t.screenY];const i=new AbortController,s=this._uiManager.combinedSignal(i);this.parent.togglePointerEvents(!1),window.addEventListener("pointermove",this.#rn.bind(this,e),{passive:!0,capture:!0,signal:s}),window.addEventListener("touchmove",Ee,{passive:!1,signal:s}),window.addEventListener("contextmenu",xe,{signal:s}),this.#Nt={savedX:this.x,savedY:this.y,savedWidth:this.width,savedHeight:this.height};const a=this.parent.div.style.cursor,o=this.div.style.cursor;this.div.style.cursor=this.parent.div.style.cursor=window.getComputedStyle(t.target).cursor;const l=()=>{i.abort(),this.parent.togglePointerEvents(!0),this.#o?.toggle(!0),this._isDraggable=r,this.parent.div.style.cursor=a,this.div.style.cursor=o,this.#in()};window.addEventListener("pointerup",l,{signal:s}),window.addEventListener("blur",l,{signal:s})}#sn(e,t,n,r){this.width=n,this.height=r,this.x=e,this.y=t,this.setDims(),this.fixAndSetPosition(),this._onResized()}_onResized(){}#in(){if(!this.#Nt)return;const{savedX:e,savedY:t,savedWidth:n,savedHeight:r}=this.#Nt;this.#Nt=null;const i=this.x,s=this.y,a=this.width,o=this.height;i===e&&s===t&&a===n&&o===r||this.addCommands({cmd:this.#sn.bind(this,i,s,a,o),undo:this.#sn.bind(this,e,t,n,r),mustExec:!0})}static _round(e){return Math.round(1e4*e)/1e4}#rn(e,t){const[n,r]=this.parentDimensions,i=this.x,s=this.y,a=this.width,o=this.height,l=Ze.MIN_SIZE/n,c=Ze.MIN_SIZE/r,h=this.#en(this.rotation),d=(e,t)=>[h[0]*e+h[2]*t,h[1]*e+h[3]*t],u=this.#en(360-this.rotation);let p,f,m=!1,g=!1;switch(e){case"topLeft":m=!0,p=(e,t)=>[0,0],f=(e,t)=>[e,t];break;case"topMiddle":p=(e,t)=>[e/2,0],f=(e,t)=>[e/2,t];break;case"topRight":m=!0,p=(e,t)=>[e,0],f=(e,t)=>[0,t];break;case"middleRight":g=!0,p=(e,t)=>[e,t/2],f=(e,t)=>[0,t/2];break;case"bottomRight":m=!0,p=(e,t)=>[e,t],f=(e,t)=>[0,0];break;case"bottomMiddle":p=(e,t)=>[e/2,t],f=(e,t)=>[e/2,0];break;case"bottomLeft":m=!0,p=(e,t)=>[0,t],f=(e,t)=>[e,0];break;case"middleLeft":g=!0,p=(e,t)=>[0,t/2],f=(e,t)=>[e,t/2]}const v=p(a,o),y=f(a,o);let b=d(...y);const w=Ze._round(i+b[0]),_=Ze._round(s+b[1]);let A,x,E=1,C=1;if(t.fromKeyboard)({deltaX:A,deltaY:x}=t);else{const{screenX:e,screenY:n}=t,[r,i]=this.#Rt;[A,x]=this.screenToPageTranslation(e-r,n-i),this.#Rt[0]=e,this.#Rt[1]=n}var k,S;if([A,x]=(k=A/n,S=x/r,[u[0]*k+u[2]*S,u[1]*k+u[3]*S]),m){const e=Math.hypot(a,o);E=C=Math.max(Math.min(Math.hypot(y[0]-v[0]-A,y[1]-v[1]-x)/e,1/a,1/o),l/a,c/o)}else g?E=he(Math.abs(y[0]-v[0]-A),l,1)/a:C=he(Math.abs(y[1]-v[1]-x),c,1)/o;const T=Ze._round(a*E),D=Ze._round(o*C);b=d(...f(T,D));const M=w-b[0],P=_-b[1];this.#zt||=[this.x,this.y,this.width,this.height],this.width=T,this.height=D,this.x=M,this.y=P,this.setDims(),this.fixAndSetPosition(),this._onResizing()}_onResizing(){}altTextFinish(){this.#o?.finish()}get toolbarButtons(){return null}async addEditToolbar(){if(this._editToolbar||this.#Ut)return this._editToolbar;this._editToolbar=new $e(this),this.div.append(this._editToolbar.render());const{toolbarButtons:e}=this;if(e)for(const[t,n]of e)await this._editToolbar.addButton(t,n);return this.hasComment||this._editToolbar.addButton("comment",this.addCommentButton()),this._editToolbar.addButton("delete"),this._editToolbar}addCommentButtonInToolbar(){this._editToolbar?.addButtonBefore("comment",this.addCommentButton(),".deleteButton")}removeCommentButtonFromToolbar(){this._editToolbar?.removeButton("comment")}removeEditToolbar(){this._editToolbar?.remove(),this._editToolbar=null,this.#o?.destroy()}addContainer(e){const t=this._editToolbar?.div;t?t.before(e):this.div.append(e)}getClientDimensions(){return this.div.getBoundingClientRect()}createAltText(){return this.#o||(Ke.initialize(Ze._l10n),this.#o=new Ke(this),this.#Tt&&(this.#o.data=this.#Tt,this.#Tt=null)),this.#o}get altTextData(){return this.#o?.data}set altTextData(e){this.#o&&(this.#o.data=e)}get guessedAltText(){return this.#o?.guessedText}async setGuessedAltText(e){await(this.#o?.setGuessedText(e))}serializeAltText(e){return this.#o?.serialize(e)}hasAltText(){return!!this.#o&&!this.#o.isEmpty()}hasAltTextData(){return this.#o?.hasData()??!1}focusCommentButton(){this.#l?.focusButton()}addCommentButton(){return this.#l||=new Xe(this)}addStandaloneCommentButton(){this.#st?this._uiManager.isEditingMode()&&this.#st.classList.remove("hidden"):this.hasComment&&(this.#st=this.#l.renderForStandalone(),this.div.append(this.#st))}removeStandaloneCommentButton(){this.#l.removeStandaloneCommentButton(),this.#st=null}hideStandaloneCommentButton(){this.#st?.classList.add("hidden")}get comment(){const{data:{richText:e,text:t,date:n,deleted:r}}=this.#l;return{text:t,richText:e,date:n,deleted:r,color:this.getNonHCMColor(),opacity:this.opacity??1}}set comment(e){this.#l||=new Xe(this),this.#l.data=e,this.hasComment?(this.removeCommentButtonFromToolbar(),this.addStandaloneCommentButton(),this._uiManager.updateComment(this)):(this.addCommentButtonInToolbar(),this.removeStandaloneCommentButton(),this._uiManager.removeComment(this))}setCommentData(e){let{comment:t,popupRef:n,richText:r}=e;if(!n)return;if(this.#l||=new Xe(this),this.#l.setInitialText(t,r),!this.annotationElementId)return;const i=this._uiManager.getAndRemoveDataFromAnnotationStorage(this.annotationElementId);i&&this.updateFromAnnotationLayer(i)}get hasEditedComment(){return this.#l?.hasBeenEdited()}get hasDeletedComment(){return this.#l?.isDeleted()}get hasComment(){return!!this.#l&&!this.#l.isEmpty()&&!this.#l.isDeleted()}async editComment(e){this.#l||=new Xe(this),this.#l.edit(e)}toggleComment(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0;this.hasComment&&this._uiManager.toggleComment(this,e,t)}setSelectedCommentButton(e){this.#l.setSelectedButton(e)}addComment(e){if(this.hasEditedComment){const t=180,n=100,[,,,r]=e.rect,[i]=this.pageDimensions,[s]=this.pageTranslation,a=s+i+1,o=r-n,l=a+t;e.popup={contents:this.comment.text,deleted:this.comment.deleted,rect:[a,o,l,r]}}}updateFromAnnotationLayer(e){let{popup:{contents:t,deleted:n}}=e;this.#l.data=n?null:t}get parentBoundingClientRect(){return this.parent.boundingClientRect}render(){const e=this.div=document.createElement("div");e.setAttribute("data-editor-rotation",(360-this.rotation)%360),e.className=this.name,e.setAttribute("id",this.id),e.tabIndex=this.#Mt?-1:0,e.setAttribute("role","application"),this.defaultL10nId&&e.setAttribute("data-l10n-id",this.defaultL10nId),this._isVisible||e.classList.add("hidden"),this.setInForeground(),this.#an();const[t,n]=this.parentDimensions;this.parentRotation%180!==0&&(e.style.maxWidth=`${(100*n/t).toFixed(2)}%`,e.style.maxHeight=`${(100*t/n).toFixed(2)}%`);const[r,i]=this.getInitialTranslation();return this.translate(r,i),je(this,e,["keydown","pointerdown","dblclick"]),this.isResizable&&this._uiManager._supportsPinchToZoom&&(this.#Kt||=new Ye({container:e,isPinchingDisabled:()=>!this.isSelected,onPinchStart:this.#on.bind(this),onPinching:this.#ln.bind(this),onPinchEnd:this.#cn.bind(this),signal:this._uiManager._signal})),this.addStandaloneCommentButton(),this._uiManager._editorUndoBar?.hide(),e}#on(){this.#Nt={savedX:this.x,savedY:this.y,savedWidth:this.width,savedHeight:this.height},this.#o?.toggle(!1),this.parent.togglePointerEvents(!1)}#ln(e,t,n){let r=n/t*.7+1-.7;if(1===r)return;const i=this.#en(this.rotation),s=(e,t)=>[i[0]*e+i[2]*t,i[1]*e+i[3]*t],[a,o]=this.parentDimensions,l=this.x,c=this.y,h=this.width,d=this.height,u=Ze.MIN_SIZE/a,p=Ze.MIN_SIZE/o;r=Math.max(Math.min(r,1/h,1/d),u/h,p/d);const f=Ze._round(h*r),m=Ze._round(d*r);if(f===h&&m===d)return;this.#zt||=[l,c,h,d];const g=s(h/2,d/2),v=Ze._round(l+g[0]),y=Ze._round(c+g[1]),b=s(f/2,m/2);this.x=v-b[0],this.y=y-b[1],this.width=f,this.height=m,this.setDims(),this.fixAndSetPosition(),this._onResizing()}#cn(){this.#o?.toggle(!0),this.parent.togglePointerEvents(!0),this.#in()}pointerdown(e){const{isMac:t}=re.platform;0!==e.button||e.ctrlKey&&t?e.preventDefault():(this.#$t=!0,this._isDraggable?this.#hn(e):this.#dn(e))}#dn(e){const{isMac:t}=re.platform;e.ctrlKey&&!t||e.shiftKey||e.metaKey&&t?this.parent.toggleSelected(this):this.parent.setSelected(this)}#hn(e){const{isSelected:t}=this;this._uiManager.setUpDragSession();let n=!1;const r=new AbortController,i=this._uiManager.combinedSignal(r),s={capture:!0,passive:!1,signal:i},a=e=>{r.abort(),this.#Pt=null,this.#$t=!1,this._uiManager.endDragSession()||this.#dn(e),n&&this._onStopDragging()};t&&(this.#qt=e.clientX,this.#Wt=e.clientY,this.#Pt=e.pointerId,this.#It=e.pointerType,window.addEventListener("pointermove",e=>{n||(n=!0,this._uiManager.toggleComment(this,!0,!1),this._onStartDragging());const{clientX:t,clientY:r,pointerId:i}=e;if(i!==this.#Pt)return void Ee(e);const[s,a]=this.screenToPageTranslation(t-this.#qt,r-this.#Wt);this.#qt=t,this.#Wt=r,this._uiManager.dragSelectedEditors(s,a)},s),window.addEventListener("touchmove",Ee,s),window.addEventListener("pointerdown",e=>{e.pointerType===this.#It&&(this.#Kt||e.isPrimary)&&a(e),Ee(e)},s));const o=e=>{this.#Pt&&this.#Pt!==e.pointerId?Ee(e):a(e)};window.addEventListener("pointerup",o,{signal:i}),window.addEventListener("blur",o,{signal:i})}_onStartDragging(){}_onStopDragging(){}moveInDOM(){this.#Vt&&clearTimeout(this.#Vt),this.#Vt=setTimeout(()=>{this.#Vt=null,this.parent?.moveEditorInDOM(this)},0)}_setParentAndPosition(e,t,n){e.changeParent(this),this.x=t,this.y=n,this.fixAndSetPosition(),this._onTranslated()}getRect(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.rotation;const r=this.parentScale,[i,s]=this.pageDimensions,[a,o]=this.pageTranslation,l=e/r,c=t/r,h=this.x*i,d=this.y*s,u=this.width*i,p=this.height*s;switch(n){case 0:return[h+l+a,s-d-c-p+o,h+l+u+a,s-d-c+o];case 90:return[h+c+a,s-d+l+o,h+c+p+a,s-d+l+u+o];case 180:return[h-l-u+a,s-d+c+o,h-l+a,s-d+c+p+o];case 270:return[h-c-p+a,s-d-l-u+o,h-c+a,s-d-l+o];default:throw new Error("Invalid rotation")}}getRectInCurrentCoords(e,t){const[n,r,i,s]=e,a=i-n,o=s-r;switch(this.rotation){case 0:return[n,t-s,a,o];case 90:return[n,t-r,o,a];case 180:return[i,t-r,a,o];case 270:return[i,t-s,o,a];default:throw new Error("Invalid rotation")}}getPDFRect(){return this.getRect(0,0)}getNonHCMColor(){return this.color&&Ze._colorManager.convert(this._uiManager.getNonHCMColor(this.color))}onUpdatedColor(){this.#l?.onUpdatedColor()}getData(){const{comment:{text:e,color:t,date:n,opacity:r,deleted:i,richText:s},uid:a,pageIndex:o,creationDate:l,modificationDate:c}=this;return{id:a,pageIndex:o,rect:this.getPDFRect(),richText:s,contentsObj:{str:e},creationDate:l,modificationDate:n||c,popupRef:!i,color:t,opacity:r}}onceAdded(e){}isEmpty(){return!1}enableEditMode(){return!this.isInEditMode()&&(this.parent.setEditingState(!1),this.#Ut=!0,!0)}disableEditMode(){return!!this.isInEditMode()&&(this.parent.setEditingState(!0),this.#Ut=!1,!0)}isInEditMode(){return this.#Ut}shouldGetKeyboardEvents(){return this.#Ht}needsToBeRebuilt(){return this.div&&!this.isAttachedToDOM}get isOnScreen(){const{top:e,left:t,bottom:n,right:r}=this.getClientDimensions(),{innerHeight:i,innerWidth:s}=window;return t<s&&r>0&&e<i&&n>0}#an(){if(this.#Ot||!this.div)return;this.#Ot=new AbortController;const e=this._uiManager.combinedSignal(this.#Ot);this.div.addEventListener("focusin",this.focusin.bind(this),{signal:e}),this.div.addEventListener("focusout",this.focusout.bind(this),{signal:e})}rebuild(){this.#an()}rotate(e){}resize(){}serializeDeleted(){return{id:this.annotationElementId,deleted:!0,pageIndex:this.pageIndex,popupRef:this._initialData?.popupRef||""}}serialize(){return{annotationType:this.mode,pageIndex:this.pageIndex,rect:this.getPDFRect(),rotation:this.rotation,structTreeParentId:this._structTreeParentId,popupRef:this._initialData?.popupRef||""}}static async deserialize(e,t,n){const r=new this.prototype.constructor({parent:t,id:t.getNextId(),uiManager:n,annotationElementId:e.annotationElementId,creationDate:e.creationDate,modificationDate:e.modificationDate});r.rotation=e.rotation,r.#Tt=e.accessibilityData,r._isCopy=e.isCopy||!1;const[i,s]=r.pageDimensions,[a,o,l,c]=r.getRectInCurrentCoords(e.rect,s);return r.x=a/i,r.y=o/s,r.width=l/i,r.height=c/s,r}get hasBeenModified(){return!!this.annotationElementId&&(this.deleted||null!==this.serialize())}remove(){if(this.#Ot?.abort(),this.#Ot=null,this.isEmpty()||this.commit(),this.parent?this.parent.remove(this):this._uiManager.removeEditor(this),this.#Vt&&(clearTimeout(this.#Vt),this.#Vt=null),this.#Zt(),this.removeEditToolbar(),this.#Gt){for(const e of this.#Gt.values())clearTimeout(e);this.#Gt=null}this.parent=null,this.#Kt?.destroy(),this.#Kt=null}get isResizable(){return!1}makeResizable(){this.isResizable&&(this.#tn(),this.#Ft.classList.remove("hidden"))}get toolbarPosition(){return null}get commentButtonPosition(){return"ltr"===this._uiManager.direction?[1,0]:[0,0]}get commentButtonPositionInPage(){const{commentButtonPosition:[e,t]}=this,[n,r,i,s]=this.getPDFRect();return[Ze._round(n+(i-n)*e),Ze._round(r+(s-r)*(1-t))]}get commentButtonColor(){return this._uiManager.makeCommentColor(this.getNonHCMColor(),this.opacity)}get commentPopupPosition(){return this.#l.commentPopupPositionInLayer}set commentPopupPosition(e){this.#l.commentPopupPositionInLayer=e}hasDefaultPopupPosition(){return this.#l.hasDefaultPopupPosition()}get commentButtonWidth(){return this.#l.commentButtonWidth}get elementBeforePopup(){return this.div}setCommentButtonStates(e){this.#l.setCommentButtonStates(e)}keydown(e){if(!this.isResizable||e.target!==this.div||"Enter"!==e.key)return;this._uiManager.setSelected(this),this.#Nt={savedX:this.x,savedY:this.y,savedWidth:this.width,savedHeight:this.height};const t=this.#Ft.children;if(!this.#Dt){this.#Dt=Array.from(t);const e=this.#un.bind(this),n=this.#pn.bind(this),r=this._uiManager._signal;for(const t of this.#Dt){const i=t.getAttribute("data-resizer-name");t.setAttribute("role","spinbutton"),t.addEventListener("keydown",e,{signal:r}),t.addEventListener("blur",n,{signal:r}),t.addEventListener("focus",this.#fn.bind(this,i),{signal:r}),t.setAttribute("data-l10n-id",Ze._l10nResizer[i])}}const n=this.#Dt[0];let r=0;for(const s of t){if(s===n)break;r++}const i=(360-this.rotation+this.parentRotation)%360/90*(this.#Dt.length/4);if(i!==r){if(i<r)for(let t=0;t<r-i;t++)this.#Ft.append(this.#Ft.firstChild);else if(i>r)for(let t=0;t<i-r;t++)this.#Ft.firstChild.before(this.#Ft.lastChild);let e=0;for(const n of t){const t=this.#Dt[e++].getAttribute("data-resizer-name");n.setAttribute("data-l10n-id",Ze._l10nResizer[t])}}this.#mn(0),this.#Ht=!0,this.#Ft.firstChild.focus({focusVisible:!0}),e.preventDefault(),e.stopImmediatePropagation()}#un(e){Ze._resizerKeyboardManager.exec(this,e)}#pn(e){this.#Ht&&e.relatedTarget?.parentNode!==this.#Ft&&this.#Zt()}#fn(e){this.#Bt=this.#Ht?e:""}#mn(e){if(this.#Dt)for(const t of this.#Dt)t.tabIndex=e}_resizeWithKeyboard(e,t){this.#Ht&&this.#rn(this.#Bt,{deltaX:e,deltaY:t,fromKeyboard:!0})}#Zt(){this.#Ht=!1,this.#mn(-1),this.#in()}_stopResizingWithKeyboard(){this.#Zt(),this.div.focus()}select(){this.isSelected&&this._editToolbar?this._editToolbar.show():(this.isSelected=!0,this.makeResizable(),this.div?.classList.add("selectedEditor"),this._editToolbar?(this._editToolbar?.show(),this.#o?.toggleAltTextBadge(!1)):this.addEditToolbar().then(()=>{this.div?.classList.contains("selectedEditor")&&this._editToolbar?.show()}))}focus(){this.div&&!this.div.contains(document.activeElement)&&setTimeout(()=>this.div?.focus({preventScroll:!0}),0)}unselect(){this.isSelected&&(this.isSelected=!1,this.#Ft?.classList.add("hidden"),this.div?.classList.remove("selectedEditor"),this.div?.contains(document.activeElement)&&this._uiManager.currentLayer.div.focus({preventScroll:!0}),this._editToolbar?.hide(),this.#o?.toggleAltTextBadge(!0),this.hasComment&&this._uiManager.toggleComment(this,!1,!1))}updateParams(e,t){}disableEditing(){}enableEditing(){}get canChangeContent(){return!1}enterInEditMode(){this.canChangeContent&&(this.enableEditMode(),this.div.focus())}dblclick(e){"BUTTON"!==e.target.nodeName&&(this.enterInEditMode(),this.parent.updateToolbar({mode:this.constructor._editorType,editId:this.id}))}getElementForAltText(){return this.div}get contentDiv(){return this.div}get isEditing(){return this.#jt}set isEditing(e){this.#jt=e,this.parent&&(e?(this.parent.setSelected(this),this.parent.setActiveEditor(this)):this.parent.setActiveEditor(null))}static get MIN_SIZE(){return 16}static canCreateNewEmptyEditor(){return!0}get telemetryInitialData(){return{action:"added"}}get telemetryFinalData(){return null}_reportTelemetry(e){if(arguments.length>1&&void 0!==arguments[1]&&arguments[1]){this.#Gt||=new Map;const{action:t}=e;let n=this.#Gt.get(t);return n&&clearTimeout(n),n=setTimeout(()=>{this._reportTelemetry(e),this.#Gt.delete(t),0===this.#Gt.size&&(this.#Gt=null)},Ze._telemetryTimeout),void this.#Gt.set(t,n)}e.type||=this.editorType,this._uiManager._eventBus.dispatch("reporttelemetry",{source:this,details:{type:"editing",data:e}})}show(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this._isVisible;this.div.classList.toggle("hidden",!e),this._isVisible=e}enable(){this.div&&(this.div.tabIndex=0),this.#Mt=!1}disable(){this.div&&(this.div.tabIndex=-1),this.#Mt=!0}updateFakeAnnotationElement(e){if(this.#Lt||this.deleted)return this.deleted?(this.#Lt.remove(),void(this.#Lt=null)):void((this.hasEditedComment||this._hasBeenMoved||this._hasBeenResized)&&this.#Lt.updateEdited({rect:this.getPDFRect(),popup:this.comment}));this.#Lt=e.addFakeAnnotation(this)}renderAnnotationElement(e){if(this.deleted)return e.hide(),null;let t=e.container.querySelector(".annotationContent");if(t){if("CANVAS"===t.nodeName){const e=t;t=document.createElement("div"),t.classList.add("annotationContent",this.editorType),e.before(t)}}else t=document.createElement("div"),t.classList.add("annotationContent",this.editorType),e.container.prepend(t);return t}resetAnnotationElement(e){const{firstChild:t}=e.container;"DIV"===t?.nodeName&&t.classList.contains("annotationContent")&&t.remove()}}class Je extends Ze{constructor(e){super(e),this.annotationElementId=e.annotationElementId,this.deleted=!0}serialize(){return this.serializeDeleted()}}const Qe=3285377520,et=4294901760,tt=65535;class nt{constructor(e){this.h1=e?4294967295&e:Qe,this.h2=e?4294967295&e:Qe}update(e){let t,n;if("string"===typeof e){t=new Uint8Array(2*e.length),n=0;for(let r=0,i=e.length;r<i;r++){const i=e.charCodeAt(r);i<=255?t[n++]=i:(t[n++]=i>>>8,t[n++]=255&i)}}else{if(!ArrayBuffer.isView(e))throw new Error("Invalid data format, must be a string or TypedArray.");t=e.slice(),n=t.byteLength}const r=n>>2,i=n-4*r,s=new Uint32Array(t.buffer,0,r);let a=0,o=0,l=this.h1,c=this.h2;const h=3432918353,d=461845907,u=11601,p=13715;for(let f=0;f<r;f++)1&f?(a=s[f],a=a*h&et|a*u&tt,a=a<<15|a>>>17,a=a*d&et|a*p&tt,l^=a,l=l<<13|l>>>19,l=5*l+3864292196):(o=s[f],o=o*h&et|o*u&tt,o=o<<15|o>>>17,o=o*d&et|o*p&tt,c^=o,c=c<<13|c>>>19,c=5*c+3864292196);switch(a=0,i){case 3:a^=t[4*r+2]<<16;case 2:a^=t[4*r+1]<<8;case 1:a^=t[4*r],a=a*h&et|a*u&tt,a=a<<15|a>>>17,a=a*d&et|a*p&tt,1&r?l^=a:c^=a}this.h1=l,this.h2=c}hexdigest(){let e=this.h1,t=this.h2;return e^=t>>>1,e=3981806797*e&et|36045*e&tt,t=4283543511*t&et|(2950163797*(t<<16|e>>>16)&et)>>>16,e^=t>>>1,e=444984403*e&et|60499*e&tt,t=3301882366*t&et|(3120437893*(t<<16|e>>>16)&et)>>>16,e^=t>>>1,(e>>>0).toString(16).padStart(8,"0")+(t>>>0).toString(16).padStart(8,"0")}}const rt=Object.freeze({map:null,hash:"",transfer:void 0});class it{#gn=!1;#vn=null;#yn=null;#bn=(()=>new Map)();constructor(){this.onSetModified=null,this.onResetModified=null,this.onAnnotationEditor=null}getValue(e,t){const n=this.#bn.get(e);return void 0===n?t:Object.assign(t,n)}getRawValue(e){return this.#bn.get(e)}remove(e){const t=this.#bn.get(e);if(void 0!==t&&(t instanceof Ze&&this.#yn.delete(t.annotationElementId),this.#bn.delete(e),0===this.#bn.size&&this.resetModified(),"function"===typeof this.onAnnotationEditor)){for(const e of this.#bn.values())if(e instanceof Ze)return;this.onAnnotationEditor(null)}}setValue(e,t){const n=this.#bn.get(e);let r=!1;if(void 0!==n)for(const[i,s]of Object.entries(t))n[i]!==s&&(r=!0,n[i]=s);else r=!0,this.#bn.set(e,t);r&&this.#wn(),t instanceof Ze&&((this.#yn||=new Map).set(t.annotationElementId,t),"function"===typeof this.onAnnotationEditor&&this.onAnnotationEditor(t.constructor._type))}has(e){return this.#bn.has(e)}get size(){return this.#bn.size}#wn(){this.#gn||(this.#gn=!0,"function"===typeof this.onSetModified&&this.onSetModified())}resetModified(){this.#gn&&(this.#gn=!1,"function"===typeof this.onResetModified&&this.onResetModified())}get print(){return new st(this)}get serializable(){if(0===this.#bn.size)return rt;const e=new Map,t=new nt,n=[],r=Object.create(null);let i=!1;for(const[s,a]of this.#bn){const n=a instanceof Ze?a.serialize(!1,r):a;n&&(e.set(s,n),t.update(`${s}:${JSON.stringify(n)}`),i||=!!n.bitmap)}if(i)for(const s of e.values())s.bitmap&&n.push(s.bitmap);return e.size>0?{map:e,hash:t.hexdigest(),transfer:n}:rt}get editorStats(){let e=null;const t=new Map;let n=0,r=0;for(const i of this.#bn.values()){if(!(i instanceof Ze)){i.popup&&(i.popup.deleted?r+=1:n+=1);continue}i.isCommentDeleted?r+=1:i.hasEditedComment&&(n+=1);const s=i.telemetryFinalData;if(!s)continue;const{type:a}=s;t.has(a)||t.set(a,Object.getPrototypeOf(i).constructor),e||=Object.create(null);const o=e[a]||=new Map;for(const[e,t]of Object.entries(s)){if("type"===e)continue;let n=o.get(e);n||(n=new Map,o.set(e,n));const r=n.get(t)??0;n.set(t,r+1)}}if((r>0||n>0)&&(e||=Object.create(null),e.comments={deleted:r,edited:n}),!e)return null;for(const[i,s]of t)e[i]=s.computeTelemetryFinalData(e[i]);return e}resetModifiedIds(){this.#vn=null}updateEditor(e,t){const n=this.#yn?.get(e);return!!n&&(n.updateFromAnnotationLayer(t),!0)}getEditor(e){return this.#yn?.get(e)||null}get modifiedIds(){if(this.#vn)return this.#vn;const e=[];if(this.#yn)for(const t of this.#yn.values())t.serialize()&&e.push(t.annotationElementId);return this.#vn={ids:new Set(e),hash:e.join(",")}}[Symbol.iterator](){return this.#bn.entries()}}class st extends it{#_n;constructor(e){super();const{map:t,hash:n,transfer:r}=e.serializable,i=structuredClone(t,r?{transfer:r}:null);this.#_n={map:i,hash:n,transfer:r}}get print(){H("Should not call PrintAnnotationStorage.print")}get serializable(){return this.#_n}get modifiedIds(){return G(this,"modifiedIds",{ids:new Set,hash:""})}}class at{#An=(()=>new Set)();constructor(e){let{ownerDocument:t=globalThis.document,styleElement:n=null}=e;this._document=t,this.nativeFontFaces=new Set,this.styleElement=null,this.loadingRequests=[],this.loadTestFontId=0}addNativeFontFace(e){this.nativeFontFaces.add(e),this._document.fonts.add(e)}removeNativeFontFace(e){this.nativeFontFaces.delete(e),this._document.fonts.delete(e)}insertRule(e){this.styleElement||(this.styleElement=this._document.createElement("style"),this._document.documentElement.getElementsByTagName("head")[0].append(this.styleElement));const t=this.styleElement.sheet;t.insertRule(e,t.cssRules.length)}clear(){for(const e of this.nativeFontFaces)this._document.fonts.delete(e);this.nativeFontFaces.clear(),this.#An.clear(),this.styleElement&&(this.styleElement.remove(),this.styleElement=null)}async loadSystemFont(e){let{systemFontInfo:t,disableFontFace:n,_inspectFont:r}=e;if(t&&!this.#An.has(t.loadedName)){if(V(!n,"loadSystemFont shouldn't be called when `disableFontFace` is set."),this.isFontLoadingAPISupported){const{loadedName:e,src:n,style:i}=t,s=new FontFace(e,n,i);this.addNativeFontFace(s);try{await s.load(),this.#An.add(e),r?.(t)}catch{U(`Cannot load system font: ${t.baseFontName}, installing it could help to improve PDF rendering.`),this.removeNativeFontFace(s)}return}H("Not implemented: loadSystemFont without the Font Loading API.")}}async bind(e){if(e.attached||e.missingFile&&!e.systemFontInfo)return;if(e.attached=!0,e.systemFontInfo)return void await this.loadSystemFont(e);if(this.isFontLoadingAPISupported){const t=e.createNativeFontFace();if(t){this.addNativeFontFace(t);try{await t.loaded}catch(n){throw U(`Failed to load font '${t.family}': '${n}'.`),e.disableFontFace=!0,n}}return}const t=e.createFontFaceRule();if(t){if(this.insertRule(t),this.isSyncFontLoadingSupported)return;await new Promise(t=>{const n=this._queueLoadingCallback(t);this._prepareFontLoadEvent(e,n)})}}get isFontLoadingAPISupported(){return G(this,"isFontLoadingAPISupported",!!this._document?.fonts)}get isSyncFontLoadingSupported(){return G(this,"isSyncFontLoadingSupported",i||re.platform.isFirefox)}_queueLoadingCallback(e){const{loadingRequests:t}=this,n={done:!1,complete:function(){for(V(!n.done,"completeRequest() cannot be called twice."),n.done=!0;t.length>0&&t[0].done;){const e=t.shift();setTimeout(e.callback,0)}},callback:e};return t.push(n),n}get _loadTestFont(){return G(this,"_loadTestFont",atob("T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQAFQAABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABDQLUAAACNAAAAUJoZWFk/xVFDQAAALwAAAA2aGhlYQdkA+oAAAD0AAAAJGhtdHgD6AAAAAAEWAAAAAZtYXhwAAJQAAAAARgAAAAGbmFtZVjmdH4AAAGAAAAAsXBvc3T/hgAzAAADeAAAACAAAQAAAAEAALZRFsRfDzz1AAsD6AAAAADOBOTLAAAAAM4KHDwAAAAAA+gDIQAAAAgAAgAAAAAAAAABAAADIQAAAFoD6AAAAAAD6AABAAAAAAAAAAAAAAAAAAAAAQAAUAAAAgAAAAQD6AH0AAUAAAKKArwAAACMAooCvAAAAeAAMQECAAACAAYJAAAAAAAAAAAAAQAAAAAAAAAAAAAAAFBmRWQAwAAuAC4DIP84AFoDIQAAAAAAAQAAAAAAAAAAACAAIAABAAAADgCuAAEAAAAAAAAAAQAAAAEAAAAAAAEAAQAAAAEAAAAAAAIAAQAAAAEAAAAAAAMAAQAAAAEAAAAAAAQAAQAAAAEAAAAAAAUAAQAAAAEAAAAAAAYAAQAAAAMAAQQJAAAAAgABAAMAAQQJAAEAAgABAAMAAQQJAAIAAgABAAMAAQQJAAMAAgABAAMAAQQJAAQAAgABAAMAAQQJAAUAAgABAAMAAQQJAAYAAgABWABYAAAAAAAAAwAAAAMAAAAcAAEAAAAAADwAAwABAAAAHAAEACAAAAAEAAQAAQAAAC7//wAAAC7////TAAEAAAAAAAABBgAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAAAAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgcA/gXBIwMAYuL+nz5tQXkD5j3CBLnEQACAQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYAAABAQAADwACAQEEE/t3Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQAAAAAAAABAAAAAMmJbzEAAAAAzgTjFQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA=="))}_prepareFontLoadEvent(e,t){function n(e,t){return e.charCodeAt(t)<<24|e.charCodeAt(t+1)<<16|e.charCodeAt(t+2)<<8|255&e.charCodeAt(t+3)}function r(e,t,n,r){return e.substring(0,t)+r+e.substring(t+n)}let i,s;const a=this._document.createElement("canvas");a.width=1,a.height=1;const o=a.getContext("2d");let l=0;const c=`lt${Date.now()}${this.loadTestFontId++}`;let h=this._loadTestFont;h=r(h,976,c.length,c);const d=1482184792;let u=n(h,16);for(i=0,s=c.length-3;i<s;i+=4)u=u-d+n(c,i)|0;var p;i<c.length&&(u=u-d+n(c+"XXX",i)|0),h=r(h,16,4,(p=u,String.fromCharCode(p>>24&255,p>>16&255,p>>8&255,255&p)));const f=`@font-face {font-family:"${c}";src:${`url(data:font/opentype;base64,${btoa(h)});`}}`;this.insertRule(f);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 g of[e.loadedName,c]){const e=this._document.createElement("span");e.textContent="Hi",e.style.fontFamily=g,m.append(e)}this._document.body.append(m),function e(t,n){if(++l>30)return U("Load test font never loaded."),void n();o.font="30px "+t,o.fillText(".",0,20),o.getImageData(0,0,1,1).data[3]>0?n():setTimeout(e.bind(null,t,n))}(c,()=>{m.remove(),t.complete()})}}class ot{#xn;constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0;this.compiledGlyphs=Object.create(null),this.#xn=e,this._inspectFont=t,n&&Object.assign(this,n),r&&(this.charProcOperatorList=r)}createNativeFontFace(){if(!this.data||this.disableFontFace)return null;let e;if(this.cssFontInfo){const t={weight:this.cssFontInfo.fontWeight};this.cssFontInfo.italicAngle&&(t.style=`oblique ${this.cssFontInfo.italicAngle}deg`),e=new FontFace(this.cssFontInfo.fontFamily,this.data,t)}else e=new FontFace(this.loadedName,this.data,{});return this._inspectFont?.(this),e}createFontFaceRule(){if(!this.data||this.disableFontFace)return null;const e=`url(data:${this.mimetype};base64,${de(this.data)});`;let t;if(this.cssFontInfo){let n=`font-weight: ${this.cssFontInfo.fontWeight};`;this.cssFontInfo.italicAngle&&(n+=`font-style: oblique ${this.cssFontInfo.italicAngle}deg;`),t=`@font-face {font-family:"${this.cssFontInfo.fontFamily}";${n}src:${e}}`}else t=`@font-face {font-family:"${this.loadedName}";src:${e}}`;return this._inspectFont?.(this,e),t}getPathGenerator(e,t){if(void 0!==this.compiledGlyphs[t])return this.compiledGlyphs[t];const n=this.loadedName+"_path_"+t;let r;try{r=e.get(n)}catch(s){U(`getPathGenerator - ignoring character: "${s}".`)}const i=new Path2D(r||"");return this.fontExtraProperties||e.delete(n),this.compiledGlyphs[t]=i}get black(){return this.#xn.black}get bold(){return this.#xn.bold}get disableFontFace(){return this.#xn.disableFontFace??!1}get fontExtraProperties(){return this.#xn.fontExtraProperties??!1}get isInvalidPDFjsFont(){return this.#xn.isInvalidPDFjsFont}get isType3Font(){return this.#xn.isType3Font}get italic(){return this.#xn.italic}get missingFile(){return this.#xn.missingFile}get remeasure(){return this.#xn.remeasure}get vertical(){return this.#xn.vertical}get ascent(){return this.#xn.ascent}get defaultWidth(){return this.#xn.defaultWidth}get descent(){return this.#xn.descent}get bbox(){return this.#xn.bbox}get fontMatrix(){return this.#xn.fontMatrix}get fallbackName(){return this.#xn.fallbackName}get loadedName(){return this.#xn.loadedName}get mimetype(){return this.#xn.mimetype}get name(){return this.#xn.name}get data(){return this.#xn.data}clearData(){this.#xn.clearData()}get cssFontInfo(){return this.#xn.cssFontInfo}get systemFontInfo(){return this.#xn.systemFontInfo}get defaultVMetrics(){return this.#xn.defaultVMetrics}}function lt(e){if("string"!==typeof e)return null;if(e.endsWith("/"))return e;throw new Error(`Invalid factory url: "${e}" must include trailing slash.`)}const ct=e=>"object"===typeof e&&Number.isInteger(e?.num)&&e.num>=0&&Number.isInteger(e?.gen)&&e.gen>=0,ht=function(e,t,n){if(!Array.isArray(n)||n.length<2)return!1;const[r,i,...s]=n;if(!e(r)&&!Number.isInteger(r))return!1;if(!t(i))return!1;const a=s.length;let o=!0;switch(i.name){case"XYZ":if(a<2||a>3)return!1;break;case"Fit":case"FitB":return 0===a;case"FitH":case"FitBH":case"FitV":case"FitBV":if(a>1)return!1;break;case"FitR":if(4!==a)return!1;o=!1;break;default:return!1}for(const l of s)if(!("number"===typeof l||o&&null===l))return!1;return!0}.bind(null,ct,e=>"object"===typeof e&&"string"===typeof e?.name);class dt{#En=(()=>new Map)();#Cn=(()=>Promise.resolve())();postMessage(e,t){const n={data:structuredClone(e,t?{transfer:t}:null)};this.#Cn.then(()=>{for(const[e]of this.#En)e.call(this,n)})}addEventListener(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=null;if(n?.signal instanceof AbortSignal){const{signal:i}=n;if(i.aborted)return void U("LoopbackPort - cannot use an `aborted` signal.");const s=()=>this.removeEventListener(e,t);r=()=>i.removeEventListener("abort",s),i.addEventListener("abort",s)}this.#En.set(t,r)}removeEventListener(e,t){const n=this.#En.get(t);n?.(),this.#En.delete(t)}terminate(){for(const[,e]of this.#En)e?.();this.#En.clear()}}const ut=1,pt=2,ft=1,mt=2,gt=3,vt=4,yt=5,bt=6,wt=7,_t=8;function At(){}function xt(e){if(e instanceof ee||e instanceof Z||e instanceof X||e instanceof J||e instanceof Y)return e;switch(e instanceof Error||"object"===typeof e&&null!==e||H('wrapReason: Expected "reason" to be a (possibly cloned) Error.'),e.name){case"AbortException":return new ee(e.message);case"InvalidPDFException":return new Z(e.message);case"PasswordException":return new X(e.message,e.code);case"ResponseException":return new J(e.message,e.status,e.missing);case"UnknownErrorException":return new Y(e.message,e.details)}return new Y(e.message,e.toString())}class Et{#kn=(()=>new AbortController)();constructor(e,t,n){this.sourceName=e,this.targetName=t,this.comObj=n,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),n.addEventListener("message",this.#Sn.bind(this),{signal:this.#kn.signal})}#Sn(e){let{data:t}=e;if(t.targetName!==this.sourceName)return;if(t.stream)return void this.#Tn(t);if(t.callback){const e=t.callbackId,n=this.callbackCapabilities[e];if(!n)throw new Error(`Cannot resolve callback ${e}`);if(delete this.callbackCapabilities[e],t.callback===ut)n.resolve(t.data);else{if(t.callback!==pt)throw new Error("Unexpected callback case");n.reject(xt(t.reason))}return}const n=this.actionHandler[t.action];if(!n)throw new Error(`Unknown action from worker: ${t.action}`);if(t.callbackId){const e=this.sourceName,r=t.sourceName,i=this.comObj;return void Promise.try(n,t.data).then(function(n){i.postMessage({sourceName:e,targetName:r,callback:ut,callbackId:t.callbackId,data:n})},function(n){i.postMessage({sourceName:e,targetName:r,callback:pt,callbackId:t.callbackId,reason:xt(n)})})}t.streamId?this.#Dn(t):n(t.data)}on(e,t){const n=this.actionHandler;if(n[e])throw new Error(`There is already an actionName called "${e}"`);n[e]=t}send(e,t,n){this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:e,data:t},n)}sendWithPromise(e,t,n){const r=this.callbackId++,i=Promise.withResolvers();this.callbackCapabilities[r]=i;try{this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:e,callbackId:r,data:t},n)}catch(s){i.reject(s)}return i.promise}sendWithStream(e,t,n,r){const i=this.streamId++,s=this.sourceName,a=this.targetName,o=this.comObj;return new ReadableStream({start:n=>{const l=Promise.withResolvers();return this.streamControllers[i]={controller:n,startCall:l,pullCall:null,cancelCall:null,isClosed:!1},o.postMessage({sourceName:s,targetName:a,action:e,streamId:i,data:t,desiredSize:n.desiredSize},r),l.promise},pull:e=>{const t=Promise.withResolvers();return this.streamControllers[i].pullCall=t,o.postMessage({sourceName:s,targetName:a,stream:bt,streamId:i,desiredSize:e.desiredSize}),t.promise},cancel:e=>{V(e instanceof Error,"cancel must have a valid reason");const t=Promise.withResolvers();return this.streamControllers[i].cancelCall=t,this.streamControllers[i].isClosed=!0,o.postMessage({sourceName:s,targetName:a,stream:ft,streamId:i,reason:xt(e)}),t.promise}},n)}#Dn(e){const t=e.streamId,n=this.sourceName,r=e.sourceName,i=this.comObj,s=this,a=this.actionHandler[e.action],o={enqueue(e){let s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,a=arguments.length>2?arguments[2]:void 0;if(this.isCancelled)return;const o=this.desiredSize;this.desiredSize-=s,o>0&&this.desiredSize<=0&&(this.sinkCapability=Promise.withResolvers(),this.ready=this.sinkCapability.promise),i.postMessage({sourceName:n,targetName:r,stream:vt,streamId:t,chunk:e},a)},close(){this.isCancelled||(this.isCancelled=!0,i.postMessage({sourceName:n,targetName:r,stream:gt,streamId:t}),delete s.streamSinks[t])},error(e){V(e instanceof Error,"error must have a valid reason"),this.isCancelled||(this.isCancelled=!0,i.postMessage({sourceName:n,targetName:r,stream:yt,streamId:t,reason:xt(e)}))},sinkCapability:Promise.withResolvers(),onPull:null,onCancel:null,isCancelled:!1,desiredSize:e.desiredSize,ready:null};o.sinkCapability.resolve(),o.ready=o.sinkCapability.promise,this.streamSinks[t]=o,Promise.try(a,e.data,o).then(function(){i.postMessage({sourceName:n,targetName:r,stream:_t,streamId:t,success:!0})},function(e){i.postMessage({sourceName:n,targetName:r,stream:_t,streamId:t,reason:xt(e)})})}#Tn(e){const t=e.streamId,n=this.sourceName,r=e.sourceName,i=this.comObj,s=this.streamControllers[t],a=this.streamSinks[t];switch(e.stream){case _t:e.success?s.startCall.resolve():s.startCall.reject(xt(e.reason));break;case wt:e.success?s.pullCall.resolve():s.pullCall.reject(xt(e.reason));break;case bt:if(!a){i.postMessage({sourceName:n,targetName:r,stream:wt,streamId:t,success:!0});break}a.desiredSize<=0&&e.desiredSize>0&&a.sinkCapability.resolve(),a.desiredSize=e.desiredSize,Promise.try(a.onPull||At).then(function(){i.postMessage({sourceName:n,targetName:r,stream:wt,streamId:t,success:!0})},function(e){i.postMessage({sourceName:n,targetName:r,stream:wt,streamId:t,reason:xt(e)})});break;case vt:if(V(s,"enqueue should have stream controller"),s.isClosed)break;s.controller.enqueue(e.chunk);break;case gt:if(V(s,"close should have stream controller"),s.isClosed)break;s.isClosed=!0,s.controller.close(),this.#Mn(s,t);break;case yt:V(s,"error should have stream controller"),s.controller.error(xt(e.reason)),this.#Mn(s,t);break;case mt:e.success?s.cancelCall.resolve():s.cancelCall.reject(xt(e.reason)),this.#Mn(s,t);break;case ft:if(!a)break;const o=xt(e.reason);Promise.try(a.onCancel||At,o).then(function(){i.postMessage({sourceName:n,targetName:r,stream:mt,streamId:t,success:!0})},function(e){i.postMessage({sourceName:n,targetName:r,stream:mt,streamId:t,reason:xt(e)})}),a.sinkCapability.reject(o),a.isCancelled=!0,delete this.streamSinks[t];break;default:throw new Error("Unexpected stream case")}}async#Mn(e,t){await Promise.allSettled([e.startCall?.promise,e.pullCall?.promise,e.cancelCall?.promise]),delete this.streamControllers[t]}destroy(){this.#kn?.abort(),this.#kn=null}}class Ct{#Pn=!1;constructor(e){let{enableHWA:t=!1}=e;this.#Pn=t}create(e,t){if(e<=0||t<=0)throw new Error("Invalid canvas size");const n=this._createCanvas(e,t);return{canvas:n,context:n.getContext("2d",{willReadFrequently:!this.#Pn})}}reset(e,t,n){if(!e.canvas)throw new Error("Canvas is not specified");if(t<=0||n<=0)throw new Error("Invalid canvas size");e.canvas.width=t,e.canvas.height=n}destroy(e){if(!e.canvas)throw new Error("Canvas is not specified");e.canvas.width=0,e.canvas.height=0,e.canvas=null,e.context=null}_createCanvas(e,t){H("Abstract method `_createCanvas` called.")}}class kt extends Ct{constructor(e){let{ownerDocument:t=globalThis.document,enableHWA:n=!1}=e;super({enableHWA:n}),this._document=t}_createCanvas(e,t){const n=this._document.createElement("canvas");return n.width=e,n.height=t,n}}class St{constructor(e){let{baseUrl:t=null,isCompressed:n=!0}=e;this.baseUrl=t,this.isCompressed=n}async fetch(e){let{name:t}=e;if(!this.baseUrl)throw new Error("Ensure that the `cMapUrl` and `cMapPacked` API parameters are provided.");if(!t)throw new Error("CMap name must be specified.");const n=this.baseUrl+t+(this.isCompressed?".bcmap":"");return this._fetch(n).then(e=>({cMapData:e,isCompressed:this.isCompressed})).catch(e=>{throw new Error(`Unable to load ${this.isCompressed?"binary ":""}CMap at: ${n}`)})}async _fetch(e){H("Abstract method `_fetch` called.")}}class Tt extends St{async _fetch(e){const t=await ge(e,this.isCompressed?"arraybuffer":"text");return t instanceof ArrayBuffer?new Uint8Array(t):ne(t)}}class Dt{addFilter(e){return"none"}addHCMFilter(e,t){return"none"}addAlphaFilter(e){return"none"}addLuminosityFilter(e){return"none"}addHighlightHCMFilter(e,t,n,r,i){return"none"}destroy(){}}class Mt extends Dt{#In;#Fn;#Rn;#Nn;#Ln;#On;#_=0;constructor(e){let{docId:t,ownerDocument:n=globalThis.document}=e;super(),this.#Nn=t,this.#Ln=n}get#x(){return this.#Fn||=new Map}get#Bn(){return this.#On||=new Map}get#$n(){if(!this.#Rn){const e=this.#Ln.createElement("div"),{style:t}=e;t.visibility="hidden",t.contain="strict",t.width=t.height=0,t.position="absolute",t.top=t.left=0,t.zIndex=-1;const n=this.#Ln.createElementNS(fe,"svg");n.setAttribute("width",0),n.setAttribute("height",0),this.#Rn=this.#Ln.createElementNS(fe,"defs"),e.append(n),n.append(this.#Rn),this.#Ln.body.append(e)}return this.#Rn}#zn(e){if(1===e.length){const t=e[0],n=new Array(256);for(let e=0;e<256;e++)n[e]=t[e]/255;const r=n.join(",");return[r,r,r]}const[t,n,r]=e,i=new Array(256),s=new Array(256),a=new Array(256);for(let o=0;o<256;o++)i[o]=t[o]/255,s[o]=n[o]/255,a[o]=r[o]/255;return[i.join(","),s.join(","),a.join(",")]}#jn(e){if(void 0===this.#In){this.#In="";const e=this.#Ln.URL;e!==this.#Ln.baseURI&&(be(e)?U('#createUrl: ignore "data:"-URL for performance reasons.'):this.#In=W(e,""))}return`url(${this.#In}#${e})`}addFilter(e){if(!e)return"none";let t=this.#x.get(e);if(t)return t;const[n,r,i]=this.#zn(e),s=1===e.length?n:`${n}${r}${i}`;if(t=this.#x.get(s),t)return this.#x.set(e,t),t;const a=`g_${this.#Nn}_transfer_map_${this.#_++}`,o=this.#jn(a);this.#x.set(e,o),this.#x.set(s,o);const l=this.#Un(a);return this.#Hn(n,r,i,l),o}addHCMFilter(e,t){const n=`${e}-${t}`,r="base";let i=this.#Bn.get(r);if(i?.key===n)return i.url;if(i?(i.filter?.remove(),i.key=n,i.url="none",i.filter=null):(i={key:n,url:"none",filter:null},this.#Bn.set(r,i)),!e||!t)return i.url;const s=this.#Vn(e);e=se.makeHexColor(...s);const a=this.#Vn(t);if(t=se.makeHexColor(...a),this.#$n.style.color="","#000000"===e&&"#ffffff"===t||e===t)return i.url;const o=new Array(256);for(let u=0;u<=255;u++){const e=u/255;o[u]=e<=.03928?e/12.92:((e+.055)/1.055)**2.4}const l=o.join(","),c=`g_${this.#Nn}_hcm_filter`,h=i.filter=this.#Un(c);this.#Hn(l,l,l,h),this.#qn(h);const d=(e,t)=>{const n=s[e]/255,r=a[e]/255,i=new Array(t+1);for(let s=0;s<=t;s++)i[s]=n+s/t*(r-n);return i.join(",")};return this.#Hn(d(0,5),d(1,5),d(2,5),h),i.url=this.#jn(c),i.url}addAlphaFilter(e){let t=this.#x.get(e);if(t)return t;const[n]=this.#zn([e]),r=`alpha_${n}`;if(t=this.#x.get(r),t)return this.#x.set(e,t),t;const i=`g_${this.#Nn}_alpha_map_${this.#_++}`,s=this.#jn(i);this.#x.set(e,s),this.#x.set(r,s);const a=this.#Un(i);return this.#Wn(n,a),s}addLuminosityFilter(e){let t,n,r=this.#x.get(e||"luminosity");if(r)return r;if(e?([t]=this.#zn([e]),n=`luminosity_${t}`):n="luminosity",r=this.#x.get(n),r)return this.#x.set(e,r),r;const i=`g_${this.#Nn}_luminosity_map_${this.#_++}`,s=this.#jn(i);this.#x.set(e,s),this.#x.set(n,s);const a=this.#Un(i);return this.#Gn(a),e&&this.#Wn(t,a),s}addHighlightHCMFilter(e,t,n,r,i){const s=`${t}-${n}-${r}-${i}`;let a=this.#Bn.get(e);if(a?.key===s)return a.url;if(a?(a.filter?.remove(),a.key=s,a.url="none",a.filter=null):(a={key:s,url:"none",filter:null},this.#Bn.set(e,a)),!t||!n)return a.url;const[o,l]=[t,n].map(this.#Vn.bind(this));let c=Math.round(.2126*o[0]+.7152*o[1]+.0722*o[2]),h=Math.round(.2126*l[0]+.7152*l[1]+.0722*l[2]),[d,u]=[r,i].map(this.#Vn.bind(this));h<c&&([c,h,d,u]=[h,c,u,d]),this.#$n.style.color="";const p=(e,t,n)=>{const r=new Array(256),i=(h-c)/n,s=e/255,a=(t-e)/(255*n);let o=0;for(let l=0;l<=n;l++){const e=Math.round(c+l*i),t=s+l*a;for(let n=o;n<=e;n++)r[n]=t;o=e+1}for(let l=o;l<256;l++)r[l]=r[o-1];return r.join(",")},f=`g_${this.#Nn}_hcm_${e}_filter`,m=a.filter=this.#Un(f);return this.#qn(m),this.#Hn(p(d[0],u[0],5),p(d[1],u[1],5),p(d[2],u[2],5),m),a.url=this.#jn(f),a.url}destroy(){arguments.length>0&&void 0!==arguments[0]&&arguments[0]&&this.#On?.size||(this.#Rn?.parentNode.parentNode.remove(),this.#Rn=null,this.#Fn?.clear(),this.#Fn=null,this.#On?.clear(),this.#On=null,this.#_=0)}#Gn(e){const t=this.#Ln.createElementNS(fe,"feColorMatrix");t.setAttribute("type","matrix"),t.setAttribute("values","0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.3 0.59 0.11 0 0"),e.append(t)}#qn(e){const t=this.#Ln.createElementNS(fe,"feColorMatrix");t.setAttribute("type","matrix"),t.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"),e.append(t)}#Un(e){const t=this.#Ln.createElementNS(fe,"filter");return t.setAttribute("color-interpolation-filters","sRGB"),t.setAttribute("id",e),this.#$n.append(t),t}#Kn(e,t,n){const r=this.#Ln.createElementNS(fe,t);r.setAttribute("type","discrete"),r.setAttribute("tableValues",n),e.append(r)}#Hn(e,t,n,r){const i=this.#Ln.createElementNS(fe,"feComponentTransfer");r.append(i),this.#Kn(i,"feFuncR",e),this.#Kn(i,"feFuncG",t),this.#Kn(i,"feFuncB",n)}#Wn(e,t){const n=this.#Ln.createElementNS(fe,"feComponentTransfer");t.append(n),this.#Kn(n,"feFuncA",e)}#Vn(e){return this.#$n.style.color=e,ke(getComputedStyle(this.#$n).getPropertyValue("color"))}}class Pt{constructor(e){let{baseUrl:t=null}=e;this.baseUrl=t}async fetch(e){let{filename:t}=e;if(!this.baseUrl)throw new Error("Ensure that the `standardFontDataUrl` API parameter is provided.");if(!t)throw new Error("Font filename must be specified.");const n=`${this.baseUrl}${t}`;return this._fetch(n).catch(e=>{throw new Error(`Unable to load font data at: ${n}`)})}async _fetch(e){H("Abstract method `_fetch` called.")}}class It extends Pt{async _fetch(e){const t=await ge(e,"arraybuffer");return new Uint8Array(t)}}class Ft{constructor(e){let{baseUrl:t=null}=e;this.baseUrl=t}async fetch(e){let{filename:t}=e;if(!this.baseUrl)throw new Error("Ensure that the `wasmUrl` API parameter is provided.");if(!t)throw new Error("Wasm filename must be specified.");const n=`${this.baseUrl}${t}`;return this._fetch(n).catch(e=>{throw new Error(`Unable to load wasm data at: ${n}`)})}async _fetch(e){H("Abstract method `_fetch` called.")}}class Rt extends Ft{async _fetch(e){const t=await ge(e,"arraybuffer");return new Uint8Array(t)}}async function Nt(e){const t=process.getBuiltinModule("fs"),n=await t.promises.readFile(e);return new Uint8Array(n)}i&&U("Please use the `legacy` build in Node.js environments.");class Lt extends Dt{}class Ot extends Ct{_createCanvas(e,t){return process.getBuiltinModule("module").createRequire("file:///home/runner/work/react-file/react-file/node_modules/pdfjs-dist/build/pdf.mjs")("@napi-rs/canvas").createCanvas(e,t)}}class Bt extends St{async _fetch(e){return Nt(e)}}class $t extends Pt{async _fetch(e){return Nt(e)}}class zt extends Ft{async _fetch(e){return Nt(e)}}const jt="__forcedDependency",{floor:Ut,ceil:Ht}=Math;function Vt(e,t,n,r,i,s){e[4*t+0]=Math.min(e[4*t+0],n),e[4*t+1]=Math.min(e[4*t+1],r),e[4*t+2]=Math.max(e[4*t+2],i),e[4*t+3]=Math.max(e[4*t+3],s)}const qt=new Uint32Array(new Uint8Array([255,255,0,0]).buffer)[0];class Wt{#Xn;#Yn;constructor(e,t){this.#Xn=e,this.#Yn=t}get length(){return this.#Xn.length}isEmpty(e){return this.#Xn[e]===qt}minX(e){return this.#Yn[4*e+0]/256}minY(e){return this.#Yn[4*e+1]/256}maxX(e){return(this.#Yn[4*e+2]+1)/256}maxY(e){return(this.#Yn[4*e+3]+1)/256}}const Gt=(e,t)=>{if(!e)return;let n=e.get(t);return n||(n={dependencies:new Set,isRenderingOperation:!1},e.set(t,n)),n};class Kt{#Zn={__proto__:null};#Jn=(()=>({__proto__:null,transform:[],moveText:[],sameLineText:[],[jt]:[]}))();#Qn=(()=>new Map)();#er=[];#tr=[];#nr=[[1,0,0,1,0,0]];#rr=[-1/0,-1/0,1/0,1/0];#ir=(()=>new Float64Array([1/0,1/0,-1/0,-1/0]))();#sr=-1;#ar=(()=>new Set)();#or=(()=>new Map)();#lr=(()=>new Map)();#cr;#hr;#dr;#Xn;#ur;constructor(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this.#cr=e.width,this.#hr=e.height,this.#pr(t),n&&(this.#ur=new Map)}growOperationsCount(e){e>=this.#Xn.length&&this.#pr(e,this.#Xn)}#pr(e,t){const n=new ArrayBuffer(4*e);this.#dr=new Uint8ClampedArray(n),this.#Xn=new Uint32Array(n),t&&t.length>0?(this.#Xn.set(t),this.#Xn.fill(qt,t.length)):this.#Xn.fill(qt)}save(e){return this.#Zn={__proto__:this.#Zn},this.#Jn={__proto__:this.#Jn,transform:{__proto__:this.#Jn.transform},moveText:{__proto__:this.#Jn.moveText},sameLineText:{__proto__:this.#Jn.sameLineText},[jt]:{__proto__:this.#Jn[jt]}},this.#rr={__proto__:this.#rr},this.#er.push(e),this}restore(e){const t=Object.getPrototypeOf(this.#Zn);if(null===t)return this;this.#Zn=t,this.#Jn=Object.getPrototypeOf(this.#Jn),this.#rr=Object.getPrototypeOf(this.#rr);const n=this.#er.pop();return void 0!==n&&(Gt(this.#ur,e)?.dependencies.add(n),this.#Xn[e]=this.#Xn[n]),this}recordOpenMarker(e){return this.#er.push(e),this}getOpenMarker(){return 0===this.#er.length?null:this.#er.at(-1)}recordCloseMarker(e){const t=this.#er.pop();return void 0!==t&&(Gt(this.#ur,e)?.dependencies.add(t),this.#Xn[e]=this.#Xn[t]),this}beginMarkedContent(e){return this.#tr.push(e),this}endMarkedContent(e){const t=this.#tr.pop();return void 0!==t&&(Gt(this.#ur,e)?.dependencies.add(t),this.#Xn[e]=this.#Xn[t]),this}pushBaseTransform(e){return this.#nr.push(se.multiplyByDOMMatrix(this.#nr.at(-1),e.getTransform())),this}popBaseTransform(){return this.#nr.length>1&&this.#nr.pop(),this}recordSimpleData(e,t){return this.#Zn[e]=t,this}recordIncrementalData(e,t){return this.#Jn[e].push(t),this}resetIncrementalData(e,t){return this.#Jn[e].length=0,this}recordNamedData(e,t){return this.#Qn.set(e,t),this}recordSimpleDataFromNamed(e,t,n){this.#Zn[e]=this.#Qn.get(t)??n}recordFutureForcedDependency(e,t){return this.recordIncrementalData(jt,t),this}inheritSimpleDataAsFutureForcedDependencies(e){for(const t of e)t in this.#Zn&&this.recordFutureForcedDependency(t,this.#Zn[t]);return this}inheritPendingDependenciesAsFutureForcedDependencies(){for(const e of this.#ar)this.recordFutureForcedDependency(jt,e);return this}resetBBox(e){return this.#sr!==e&&(this.#sr=e,this.#ir[0]=1/0,this.#ir[1]=1/0,this.#ir[2]=-1/0,this.#ir[3]=-1/0),this}recordClipBox(e,t,n,r,i,s){const a=se.multiplyByDOMMatrix(this.#nr.at(-1),t.getTransform()),o=[1/0,1/0,-1/0,-1/0];se.axialAlignedBoundingBox([n,i,r,s],a,o);const l=se.intersect(this.#rr,o);return l?(this.#rr[0]=l[0],this.#rr[1]=l[1],this.#rr[2]=l[2],this.#rr[3]=l[3]):(this.#rr[0]=this.#rr[1]=1/0,this.#rr[2]=this.#rr[3]=-1/0),this}recordBBox(e,t,n,r,i,s){const a=this.#rr;if(a[0]===1/0)return this;const o=se.multiplyByDOMMatrix(this.#nr.at(-1),t.getTransform());if(a[0]===-1/0)return se.axialAlignedBoundingBox([n,i,r,s],o,this.#ir),this;const l=[1/0,1/0,-1/0,-1/0];return se.axialAlignedBoundingBox([n,i,r,s],o,l),this.#ir[0]=Math.min(this.#ir[0],Math.max(l[0],a[0])),this.#ir[1]=Math.min(this.#ir[1],Math.max(l[1],a[1])),this.#ir[2]=Math.max(this.#ir[2],Math.min(l[2],a[2])),this.#ir[3]=Math.max(this.#ir[3],Math.min(l[3],a[3])),this}recordCharacterBBox(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,a=arguments.length>6?arguments[6]:void 0;const o=n.bbox;let l,c;if(o&&(l=o[2]!==o[0]&&o[3]!==o[1]&&this.#lr.get(n),!1!==l&&(c=[0,0,0,0],se.axialAlignedBoundingBox(o,n.fontMatrix,c),1===r&&0===i&&0===s||se.scaleMinMax([r,0,0,-r,i,s],c),l)))return this.recordBBox(e,t,c[0],c[2],c[1],c[3]);if(!a)return this.recordFullPageBBox(e);const h=a();return o&&c&&void 0===l&&(l=c[0]<=i-h.actualBoundingBoxLeft&&c[2]>=i+h.actualBoundingBoxRight&&c[1]<=s-h.actualBoundingBoxAscent&&c[3]>=s+h.actualBoundingBoxDescent,this.#lr.set(n,l),l)?this.recordBBox(e,t,c[0],c[2],c[1],c[3]):this.recordBBox(e,t,i-h.actualBoundingBoxLeft,i+h.actualBoundingBoxRight,s-h.actualBoundingBoxAscent,s+h.actualBoundingBoxDescent)}recordFullPageBBox(e){return this.#ir[0]=Math.max(0,this.#rr[0]),this.#ir[1]=Math.max(0,this.#rr[1]),this.#ir[2]=Math.min(this.#cr,this.#rr[2]),this.#ir[3]=Math.min(this.#hr,this.#rr[3]),this}getSimpleIndex(e){return this.#Zn[e]}recordDependencies(e,t){const n=this.#ar,r=this.#Zn,i=this.#Jn;for(const s of t)s in this.#Zn?n.add(r[s]):s in i&&i[s].forEach(n.add,n);return this}recordNamedDependency(e,t){return this.#Qn.has(t)&&this.#ar.add(this.#Qn.get(t)),this}recordOperation(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(this.recordDependencies(e,[jt]),this.#ur){const t=Gt(this.#ur,e),{dependencies:n}=t;this.#ar.forEach(n.add,n),this.#er.forEach(n.add,n),this.#tr.forEach(n.add,n),n.delete(e),t.isRenderingOperation=!0}if(this.#sr===e){const n=Ut(256*this.#ir[0]/this.#cr),r=Ut(256*this.#ir[1]/this.#hr),i=Ht(256*this.#ir[2]/this.#cr),s=Ht(256*this.#ir[3]/this.#hr);Vt(this.#dr,e,n,r,i,s);for(const t of this.#ar)t!==e&&Vt(this.#dr,t,n,r,i,s);for(const t of this.#er)t!==e&&Vt(this.#dr,t,n,r,i,s);for(const t of this.#tr)t!==e&&Vt(this.#dr,t,n,r,i,s);t||(this.#ar.clear(),this.#sr=-1)}return this}recordShowTextOperation(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const n=Array.from(this.#ar);this.recordOperation(e,t),this.recordIncrementalData("sameLineText",e);for(const r of n)this.recordIncrementalData("sameLineText",r);return this}bboxToClipBoxDropOperation(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return this.#sr===e&&(this.#sr=-1,this.#rr[0]=Math.max(this.#rr[0],this.#ir[0]),this.#rr[1]=Math.max(this.#rr[1],this.#ir[1]),this.#rr[2]=Math.min(this.#rr[2],this.#ir[2]),this.#rr[3]=Math.min(this.#rr[3],this.#ir[3]),t||this.#ar.clear()),this}_takePendingDependencies(){const e=this.#ar;return this.#ar=new Set,e}_extractOperation(e){const t=this.#or.get(e);return this.#or.delete(e),t}_pushPendingDependencies(e){for(const t of e)this.#ar.add(t)}take(){return this.#lr.clear(),new Wt(this.#Xn,this.#dr)}takeDebugMetadata(){return this.#ur}}class Xt{#fr;#mr;#gr;#vr=0;#yr=0;constructor(e,t,n){if(e instanceof Xt&&e.#gr===!!n)return e;this.#fr=e,this.#mr=t,this.#gr=!!n}growOperationsCount(){throw new Error("Unreachable")}save(e){return this.#yr++,this.#fr.save(this.#mr),this}restore(e){return this.#yr>0&&(this.#fr.restore(this.#mr),this.#yr--),this}recordOpenMarker(e){return this.#vr++,this}getOpenMarker(){return this.#vr>0?this.#mr:this.#fr.getOpenMarker()}recordCloseMarker(e){return this.#vr--,this}beginMarkedContent(e){return this}endMarkedContent(e){return this}pushBaseTransform(e){return this.#fr.pushBaseTransform(e),this}popBaseTransform(){return this.#fr.popBaseTransform(),this}recordSimpleData(e,t){return this.#fr.recordSimpleData(e,this.#mr),this}recordIncrementalData(e,t){return this.#fr.recordIncrementalData(e,this.#mr),this}resetIncrementalData(e,t){return this.#fr.resetIncrementalData(e,this.#mr),this}recordNamedData(e,t){return this}recordSimpleDataFromNamed(e,t,n){return this.#fr.recordSimpleDataFromNamed(e,t,this.#mr),this}recordFutureForcedDependency(e,t){return this.#fr.recordFutureForcedDependency(e,this.#mr),this}inheritSimpleDataAsFutureForcedDependencies(e){return this.#fr.inheritSimpleDataAsFutureForcedDependencies(e),this}inheritPendingDependenciesAsFutureForcedDependencies(){return this.#fr.inheritPendingDependenciesAsFutureForcedDependencies(),this}resetBBox(e){return this.#gr||this.#fr.resetBBox(this.#mr),this}recordClipBox(e,t,n,r,i,s){return this.#gr||this.#fr.recordClipBox(this.#mr,t,n,r,i,s),this}recordBBox(e,t,n,r,i,s){return this.#gr||this.#fr.recordBBox(this.#mr,t,n,r,i,s),this}recordCharacterBBox(e,t,n,r,i,s,a){return this.#gr||this.#fr.recordCharacterBBox(this.#mr,t,n,r,i,s,a),this}recordFullPageBBox(e){return this.#gr||this.#fr.recordFullPageBBox(this.#mr),this}getSimpleIndex(e){return this.#fr.getSimpleIndex(e)}recordDependencies(e,t){return this.#fr.recordDependencies(this.#mr,t),this}recordNamedDependency(e,t){return this.#fr.recordNamedDependency(this.#mr,t),this}recordOperation(e){return this.#fr.recordOperation(this.#mr,!0),this}recordShowTextOperation(e){return this.#fr.recordShowTextOperation(this.#mr,!0),this}bboxToClipBoxDropOperation(e){return this.#gr||this.#fr.bboxToClipBoxDropOperation(this.#mr,!0),this}take(){throw new Error("Unreachable")}takeDebugMetadata(){throw new Error("Unreachable")}}const Yt=["path","transform","filter","strokeColor","strokeAlpha","lineWidth","lineCap","lineJoin","miterLimit","dash"],Zt=["path","transform","filter","fillColor","fillAlpha","globalCompositeOperation","SMask"],Jt=["transform","SMask","filter","fillAlpha","strokeAlpha","globalCompositeOperation"],Qt=["filter","fillColor","fillAlpha"],en=["transform","leading","charSpacing","wordSpacing","hScale","textRise","moveText","textMatrix","font","fontObj","filter","fillColor","textRenderingMode","SMask","fillAlpha","strokeAlpha","globalCompositeOperation","sameLineText"],tn=["transform"],nn=["transform","fillColor"],rn="Fill",sn="Stroke",an="Shading";function on(e,t){if(!t)return;const n=t[2]-t[0],r=t[3]-t[1],i=new Path2D;i.rect(t[0],t[1],n,r),e.clip(i)}class ln{isModifyingCurrentTransform(){return!1}getPattern(){H("Abstract method `getPattern` called.")}}class cn extends ln{constructor(e){super(),this._type=e[1],this._bbox=e[2],this._colorStops=e[3],this._p0=e[4],this._p1=e[5],this._r0=e[6],this._r1=e[7],this.matrix=null}_createGradient(e){let t;"axial"===this._type?t=e.createLinearGradient(this._p0[0],this._p0[1],this._p1[0],this._p1[1]):"radial"===this._type&&(t=e.createRadialGradient(this._p0[0],this._p0[1],this._r0,this._p1[0],this._p1[1],this._r1));for(const n of this._colorStops)t.addColorStop(n[0],n[1]);return t}getPattern(e,t,n,r){let i;if(r===sn||r===rn){const s=t.current.getClippedPathBoundingBox(r,Se(e))||[0,0,0,0],a=Math.ceil(s[2]-s[0])||1,o=Math.ceil(s[3]-s[1])||1,l=t.cachedCanvases.getCanvas("pattern",a,o),c=l.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(-s[0],-s[1]),n=se.transform(n,[1,0,0,1,s[0],s[1]]),c.transform(...t.baseTransform),this.matrix&&c.transform(...this.matrix),on(c,this._bbox),c.fillStyle=this._createGradient(c),c.fill(),i=e.createPattern(l.canvas,"no-repeat");const h=new DOMMatrix(n);i.setTransform(h)}else on(e,this._bbox),i=this._createGradient(e);return i}}function hn(e,t,n,r,i,s,a,o){const l=t.coords,c=t.colors,h=e.data,d=4*e.width;let u;l[n+1]>l[r+1]&&(u=n,n=r,r=u,u=s,s=a,a=u),l[r+1]>l[i+1]&&(u=r,r=i,i=u,u=a,a=o,o=u),l[n+1]>l[r+1]&&(u=n,n=r,r=u,u=s,s=a,a=u);const p=(l[n]+t.offsetX)*t.scaleX,f=(l[n+1]+t.offsetY)*t.scaleY,m=(l[r]+t.offsetX)*t.scaleX,g=(l[r+1]+t.offsetY)*t.scaleY,v=(l[i]+t.offsetX)*t.scaleX,y=(l[i+1]+t.offsetY)*t.scaleY;if(f>=y)return;const b=c[s],w=c[s+1],_=c[s+2],A=c[a],x=c[a+1],E=c[a+2],C=c[o],k=c[o+1],S=c[o+2],T=Math.round(f),D=Math.round(y);let M,P,I,F,R,N,L,O;for(let B=T;B<=D;B++){if(B<g){const e=B<f?0:(f-B)/(f-g);M=p-(p-m)*e,P=b-(b-A)*e,I=w-(w-x)*e,F=_-(_-E)*e}else{let e;e=B>y?1:g===y?0:(g-B)/(g-y),M=m-(m-v)*e,P=A-(A-C)*e,I=x-(x-k)*e,F=E-(E-S)*e}let e;e=B<f?0:B>y?1:(f-B)/(f-y),R=p-(p-v)*e,N=b-(b-C)*e,L=w-(w-k)*e,O=_-(_-S)*e;const t=Math.round(Math.min(M,R)),n=Math.round(Math.max(M,R));let r=d*B+4*t;for(let i=t;i<=n;i++)e=(M-i)/(M-R),e<0?e=0:e>1&&(e=1),h[r++]=P-(P-N)*e|0,h[r++]=I-(I-L)*e|0,h[r++]=F-(F-O)*e|0,h[r++]=255}}function dn(e,t,n){const r=t.coords,i=t.colors;let s,a;switch(t.type){case"lattice":const o=t.verticesPerRow,l=Math.floor(r.length/o)-1,c=o-1;for(s=0;s<l;s++){let t=s*o;for(let s=0;s<c;s++,t++)hn(e,n,r[t],r[t+1],r[t+o],i[t],i[t+1],i[t+o]),hn(e,n,r[t+o+1],r[t+1],r[t+o],i[t+o+1],i[t+1],i[t+o])}break;case"triangles":for(s=0,a=r.length;s<a;s+=3)hn(e,n,r[s],r[s+1],r[s+2],i[s],i[s+1],i[s+2]);break;default:throw new Error("illegal figure")}}class un extends ln{constructor(e){super(),this._coords=e[2],this._colors=e[3],this._figures=e[4],this._bounds=e[5],this._bbox=e[6],this._background=e[7],this.matrix=null}_createMeshCanvas(e,t,n){const r=Math.floor(this._bounds[0]),i=Math.floor(this._bounds[1]),s=Math.ceil(this._bounds[2])-r,a=Math.ceil(this._bounds[3])-i,o=Math.min(Math.ceil(Math.abs(s*e[0]*1.1)),3e3),l=Math.min(Math.ceil(Math.abs(a*e[1]*1.1)),3e3),c=s/o,h=a/l,d={coords:this._coords,colors:this._colors,offsetX:-r,offsetY:-i,scaleX:1/c,scaleY:1/h},u=o+4,p=l+4,f=n.getCanvas("mesh",u,p),m=f.context,g=m.createImageData(o,l);if(t){const e=g.data;for(let n=0,r=e.length;n<r;n+=4)e[n]=t[0],e[n+1]=t[1],e[n+2]=t[2],e[n+3]=255}for(const v of this._figures)dn(g,v,d);m.putImageData(g,2,2);return{canvas:f.canvas,offsetX:r-2*c,offsetY:i-2*h,scaleX:c,scaleY:h}}isModifyingCurrentTransform(){return!0}getPattern(e,t,n,r){on(e,this._bbox);const i=new Float32Array(2);if(r===an)se.singularValueDecompose2dScale(Se(e),i);else if(this.matrix){se.singularValueDecompose2dScale(this.matrix,i);const[e,n]=i;se.singularValueDecompose2dScale(t.baseTransform,i),i[0]*=e,i[1]*=n}else se.singularValueDecompose2dScale(t.baseTransform,i);const s=this._createMeshCanvas(i,r===an?null:this._background,t.cachedCanvases);return r!==an&&(e.setTransform(...t.baseTransform),this.matrix&&e.transform(...this.matrix)),e.translate(s.offsetX,s.offsetY),e.scale(s.scaleX,s.scaleY),e.createPattern(s.canvas,"no-repeat")}}class pn extends ln{getPattern(){return"hotpink"}}const fn=1,mn=2;class gn{static MAX_PATTERN_SIZE=3e3;constructor(e,t,n,r){this.color=e[1],this.operatorList=e[2],this.matrix=e[3],this.bbox=e[4],this.xstep=e[5],this.ystep=e[6],this.paintType=e[7],this.tilingType=e[8],this.ctx=t,this.canvasGraphicsFactory=n,this.baseTransform=r}createPatternCanvas(e,t){const{bbox:n,operatorList:r,paintType:i,tilingType:s,color:a,canvasGraphicsFactory:o}=this;let{xstep:l,ystep:c}=this;l=Math.abs(l),c=Math.abs(c),j("TilingType: "+s);const h=n[0],d=n[1],u=n[2],p=n[3],f=u-h,m=p-d,g=new Float32Array(2);se.singularValueDecompose2dScale(this.matrix,g);const[v,y]=g;se.singularValueDecompose2dScale(this.baseTransform,g);const b=v*g[0],w=y*g[1];let _=f,A=m,x=!1,E=!1;const C=Math.ceil(l*b),k=Math.ceil(c*w);C>=Math.ceil(f*b)?_=l:x=!0,k>=Math.ceil(m*w)?A=c:E=!0;const S=this.getSizeAndScale(_,this.ctx.canvas.width,b),T=this.getSizeAndScale(A,this.ctx.canvas.height,w),D=e.cachedCanvases.getCanvas("pattern",S.size,T.size),M=D.context,P=o.createCanvasGraphics(M,t);if(P.groupLevel=e.groupLevel,this.setFillAndStrokeStyleToContext(P,i,a),M.translate(-S.scale*h,-T.scale*d),P.transform(0,S.scale,0,0,T.scale,0,0),M.save(),P.dependencyTracker?.save(),this.clipBbox(P,h,d,u,p),P.baseTransform=Se(P.ctx),P.executeOperatorList(r),P.endDrawing(),P.dependencyTracker?.restore(),M.restore(),x||E){const t=D.canvas;x&&(_=l),E&&(A=c);const n=this.getSizeAndScale(_,this.ctx.canvas.width,b),r=this.getSizeAndScale(A,this.ctx.canvas.height,w),i=n.size,s=r.size,a=e.cachedCanvases.getCanvas("pattern-workaround",i,s),o=a.context,u=x?Math.floor(f/l):0,p=E?Math.floor(m/c):0;for(let e=0;e<=u;e++)for(let n=0;n<=p;n++)o.drawImage(t,i*e,s*n,i,s,0,0,i,s);return{canvas:a.canvas,scaleX:n.scale,scaleY:r.scale,offsetX:h,offsetY:d}}return{canvas:D.canvas,scaleX:S.scale,scaleY:T.scale,offsetX:h,offsetY:d}}getSizeAndScale(e,t,n){const r=Math.max(gn.MAX_PATTERN_SIZE,t);let i=Math.ceil(e*n);return i>=r?i=r:n=i/e,{scale:n,size:i}}clipBbox(e,t,n,r,i){const s=r-t,a=i-n;e.ctx.rect(t,n,s,a),se.axialAlignedBoundingBox([t,n,r,i],Se(e.ctx),e.current.minMax),e.clip(),e.endPath()}setFillAndStrokeStyleToContext(e,t,n){const r=e.ctx,i=e.current;switch(t){case fn:const{fillStyle:e,strokeStyle:s}=this.ctx;r.fillStyle=i.fillColor=e,r.strokeStyle=i.strokeColor=s;break;case mn:r.fillStyle=r.strokeStyle=n,i.fillColor=i.strokeColor=n;break;default:throw new Q(`Unsupported paint type: ${t}`)}}isModifyingCurrentTransform(){return!1}getPattern(e,t,n,r,i){let s=n;r!==an&&(s=se.transform(s,t.baseTransform),this.matrix&&(s=se.transform(s,this.matrix)));const a=this.createPatternCanvas(t,i);let o=new DOMMatrix(s);o=o.translate(a.offsetX,a.offsetY),o=o.scale(1/a.scaleX,1/a.scaleY);const l=e.createPattern(a.canvas,"repeat");return l.setTransform(o),l}}function vn(e){let{src:t,srcPos:n=0,dest:r,width:i,height:s,nonBlackColor:a=4294967295,inverseDecode:o=!1}=e;const l=re.isLittleEndian?4278190080:255,[c,h]=o?[a,l]:[l,a],d=i>>3,u=7&i,p=t.length;r=new Uint32Array(r.buffer);let f=0;for(let m=0;m<s;m++){for(const i=n+d;n<i;n++){const e=n<p?t[n]:255;r[f++]=128&e?h:c,r[f++]=64&e?h:c,r[f++]=32&e?h:c,r[f++]=16&e?h:c,r[f++]=8&e?h:c,r[f++]=4&e?h:c,r[f++]=2&e?h:c,r[f++]=1&e?h:c}if(0===u)continue;const e=n<p?t[n++]:255;for(let t=0;t<u;t++)r[f++]=e&1<<7-t?h:c}return{srcPos:n,destPos:f}}const yn=16,bn=new DOMMatrix,wn=new Float32Array(2),_n=new Float32Array([1/0,1/0,-1/0,-1/0]);class An{constructor(e){this.canvasFactory=e,this.cache=Object.create(null)}getCanvas(e,t,n){let r;return void 0!==this.cache[e]?(r=this.cache[e],this.canvasFactory.reset(r,t,n)):(r=this.canvasFactory.create(t,n),this.cache[e]=r),r}delete(e){delete this.cache[e]}clear(){for(const e in this.cache){const t=this.cache[e];this.canvasFactory.destroy(t),delete this.cache[e]}}}function xn(e,t,n,r,i,s,a,o,l,c){const[h,d,u,p,f,m]=Se(e);if(0===d&&0===u){const g=a*h+f,v=Math.round(g),y=o*p+m,b=Math.round(y),w=(a+l)*h+f,_=Math.abs(Math.round(w)-v)||1,A=(o+c)*p+m,x=Math.abs(Math.round(A)-b)||1;return e.setTransform(Math.sign(h),0,0,Math.sign(p),v,b),e.drawImage(t,n,r,i,s,0,0,_,x),e.setTransform(h,d,u,p,f,m),[_,x]}if(0===h&&0===p){const g=o*u+f,v=Math.round(g),y=a*d+m,b=Math.round(y),w=(o+c)*u+f,_=Math.abs(Math.round(w)-v)||1,A=(a+l)*d+m,x=Math.abs(Math.round(A)-b)||1;return e.setTransform(0,Math.sign(d),Math.sign(u),0,v,b),e.drawImage(t,n,r,i,s,0,0,x,_),e.setTransform(h,d,u,p,f,m),[x,_]}e.drawImage(t,n,r,i,s,a,o,l,c);return[Math.hypot(h,d)*l,Math.hypot(u,p)*c]}class En{alphaIsShape=!1;fontSize=0;fontSizeScale=1;textMatrix=null;textMatrixScale=1;fontMatrix=(()=>s)();leading=0;x=0;y=0;lineX=0;lineY=0;charSpacing=0;wordSpacing=0;textHScale=1;textRenderingMode=(()=>b)();textRise=0;fillColor="#000000";strokeColor="#000000";patternFill=!1;patternStroke=!1;fillAlpha=1;strokeAlpha=1;lineWidth=1;activeSMask=null;transferMaps="none";constructor(e,t,n){n?.(this),this.clipBox=new Float32Array([0,0,e,t]),this.minMax=_n.slice()}clone(){const e=Object.create(this);return e.clipBox=this.clipBox.slice(),e.minMax=this.minMax.slice(),e}getPathBoundingBox(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:rn,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;const n=this.minMax.slice();if(e===sn){t||H("Stroke bounding box must include transform."),se.singularValueDecompose2dScale(t,wn);const e=wn[0]*this.lineWidth/2,r=wn[1]*this.lineWidth/2;n[0]-=e,n[1]-=r,n[2]+=e,n[3]+=r}return n}updateClipFromPath(){const e=se.intersect(this.clipBox,this.getPathBoundingBox());this.startNewPathAndClipBox(e||[0,0,0,0])}isEmptyClip(){return this.minMax[0]===1/0}startNewPathAndClipBox(e){this.clipBox.set(e,0),this.minMax.set(_n,0)}getClippedPathBoundingBox(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:rn,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return se.intersect(this.clipBox,this.getPathBoundingBox(e,t))}}function Cn(e,t){if(t instanceof ImageData)return void e.putImageData(t,0,0);const n=t.height,r=t.width,i=n%yn,s=(n-i)/yn,a=0===i?s:s+1,o=e.createImageData(r,yn);let l,c=0;const h=t.data,d=o.data;let u,p,f,m;if(t.kind===C.GRAYSCALE_1BPP){const t=h.byteLength,n=new Uint32Array(d.buffer,0,d.byteLength>>2),m=n.length,g=r+7>>3,v=4294967295,y=re.isLittleEndian?4278190080:255;for(u=0;u<a;u++){for(f=u<s?yn:i,l=0,p=0;p<f;p++){const e=t-c;let i=0;const s=e>g?r:8*e-7,a=-8&s;let o=0,d=0;for(;i<a;i+=8)d=h[c++],n[l++]=128&d?v:y,n[l++]=64&d?v:y,n[l++]=32&d?v:y,n[l++]=16&d?v:y,n[l++]=8&d?v:y,n[l++]=4&d?v:y,n[l++]=2&d?v:y,n[l++]=1&d?v:y;for(;i<s;i++)0===o&&(d=h[c++],o=128),n[l++]=d&o?v:y,o>>=1}for(;l<m;)n[l++]=0;e.putImageData(o,0,u*yn)}}else if(t.kind===C.RGBA_32BPP){for(p=0,m=r*yn*4,u=0;u<s;u++)d.set(h.subarray(c,c+m)),c+=m,e.putImageData(o,0,p),p+=yn;u<a&&(m=r*i*4,d.set(h.subarray(c,c+m)),e.putImageData(o,0,p))}else{if(t.kind!==C.RGB_24BPP)throw new Error(`bad image kind: ${t.kind}`);for(f=yn,m=r*f,u=0;u<a;u++){for(u>=s&&(f=i,m=r*f),l=0,p=m;p--;)d[l++]=h[c++],d[l++]=h[c++],d[l++]=h[c++],d[l++]=255;e.putImageData(o,0,u*yn)}}}function kn(e,t){if(t.bitmap)return void e.drawImage(t.bitmap,0,0);const n=t.height,r=t.width,i=n%yn,s=(n-i)/yn,a=0===i?s:s+1,o=e.createImageData(r,yn);let l=0;const c=t.data,h=o.data;for(let d=0;d<a;d++){const t=d<s?yn:i;({srcPos:l}=vn({src:c,srcPos:l,dest:h,width:r,height:t,nonBlackColor:0})),e.putImageData(o,0,d*yn)}}function Sn(e,t){const n=["strokeStyle","fillStyle","fillRule","globalAlpha","lineWidth","lineCap","lineJoin","miterLimit","globalCompositeOperation","font","filter"];for(const r of n)void 0!==e[r]&&(t[r]=e[r]);void 0!==e.setLineDash&&(t.setLineDash(e.getLineDash()),t.lineDashOffset=e.lineDashOffset)}function Tn(e){e.strokeStyle=e.fillStyle="#000000",e.fillRule="nonzero",e.globalAlpha=1,e.lineWidth=1,e.lineCap="butt",e.lineJoin="miter",e.miterLimit=10,e.globalCompositeOperation="source-over",e.font="10px sans-serif",void 0!==e.setLineDash&&(e.setLineDash([]),e.lineDashOffset=0);const{filter:t}=e;"none"!==t&&""!==t&&(e.filter="none")}function Dn(e,t){if(t)return!0;se.singularValueDecompose2dScale(e,wn);const n=Math.fround(Me.pixelRatio*me.PDF_TO_CSS_UNITS);return wn[0]<=n&&wn[1]<=n}const Mn=["butt","round","square"],Pn=["miter","round","bevel"],In={},Fn={};class Rn{constructor(e,t,n,r,i,s,a,o,l){let{optionalContentConfig:c,markedContentStack:h=null}=s;this.ctx=e,this.current=new En(this.ctx.canvas.width,this.ctx.canvas.height),this.stateStack=[],this.pendingClip=null,this.pendingEOFill=!1,this.res=null,this.xobjs=null,this.commonObjs=t,this.objs=n,this.canvasFactory=r,this.filterFactory=i,this.groupStack=[],this.baseTransform=null,this.baseTransformStack=[],this.groupLevel=0,this.smaskStack=[],this.smaskCounter=0,this.tempSMask=null,this.suspendedCtx=null,this.contentVisible=!0,this.markedContentStack=h||[],this.optionalContentConfig=c,this.cachedCanvases=new An(this.canvasFactory),this.cachedPatterns=new Map,this.annotationCanvasMap=a,this.viewportScale=1,this.outputScaleX=1,this.outputScaleY=1,this.pageColors=o,this._cachedScaleForStroking=[-1,0],this._cachedGetSinglePixelWidth=null,this._cachedBitmapsMap=new Map,this.dependencyTracker=l??null}getObject(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return"string"===typeof t?(this.dependencyTracker?.recordNamedDependency(e,t),t.startsWith("g_")?this.commonObjs.get(t):this.objs.get(t)):n}beginDrawing(e){let{transform:t,viewport:n,transparency:r=!1,background:i=null}=e;const s=this.ctx.canvas.width,a=this.ctx.canvas.height,o=this.ctx.fillStyle;if(this.ctx.fillStyle=i||"#ffffff",this.ctx.fillRect(0,0,s,a),this.ctx.fillStyle=o,r){const e=this.cachedCanvases.getCanvas("transparent",s,a);this.compositeCtx=this.ctx,this.transparentCanvas=e.canvas,this.ctx=e.context,this.ctx.save(),this.ctx.transform(...Se(this.compositeCtx))}this.ctx.save(),Tn(this.ctx),t&&(this.ctx.transform(...t),this.outputScaleX=t[0],this.outputScaleY=t[0]),this.ctx.transform(...n.transform),this.viewportScale=n.scale,this.baseTransform=Se(this.ctx)}executeOperatorList(e,t,n,r,i){const s=e.argsArray,a=e.fnArray;let o=t||0;const l=s.length;if(l===o)return o;const c=l-o>10&&"function"===typeof n,h=c?Date.now()+15:0;let d=0;const u=this.commonObjs,p=this.objs;let f,m;for(;;){if(void 0!==r&&o===r.nextBreakPoint)return r.breakIt(o,n),o;if(!i||i(o))if(f=a[o],m=s[o]??null,f!==F.dependency)null===m?this[f](o):this[f](o,...m);else for(const e of m){this.dependencyTracker?.recordNamedData(e,o);const t=e.startsWith("g_")?u:p;if(!t.has(e))return t.get(e,n),o}if(o++,o===l)return o;if(c&&++d>10){if(Date.now()>h)return n(),o;d=0}}}#br(){for(;this.stateStack.length||this.inSMaskMode;)this.restore();this.current.activeSMask=null,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)}endDrawing(){this.#br(),this.cachedCanvases.clear(),this.cachedPatterns.clear();for(const e of this._cachedBitmapsMap.values()){for(const t of e.values())"undefined"!==typeof HTMLCanvasElement&&t instanceof HTMLCanvasElement&&(t.width=t.height=0);e.clear()}this._cachedBitmapsMap.clear(),this.#wr()}#wr(){if(this.pageColors){const e=this.filterFactory.addHCMFilter(this.pageColors.foreground,this.pageColors.background);if("none"!==e){const t=this.ctx.filter;this.ctx.filter=e,this.ctx.drawImage(this.ctx.canvas,0,0),this.ctx.filter=t}}}_scaleImage(e,t){const n=e.width??e.displayWidth,r=e.height??e.displayHeight;let i,s,a=Math.max(Math.hypot(t[0],t[1]),1),o=Math.max(Math.hypot(t[2],t[3]),1),l=n,c=r,h="prescale1";for(;a>2&&l>1||o>2&&c>1;){let t=l,n=c;a>2&&l>1&&(t=l>=16384?Math.floor(l/2)-1||1:Math.ceil(l/2),a/=l/t),o>2&&c>1&&(n=c>=16384?Math.floor(c/2)-1||1:Math.ceil(c)/2,o/=c/n),i=this.cachedCanvases.getCanvas(h,t,n),s=i.context,s.clearRect(0,0,t,n),s.drawImage(e,0,0,l,c,0,0,t,n),e=i.canvas,l=t,c=n,h="prescale1"===h?"prescale2":"prescale1"}return{img:e,paintWidth:l,paintHeight:c}}_createMaskCanvas(e,t){const n=this.ctx,{width:r,height:i}=t,s=this.current.fillColor,a=this.current.patternFill,o=Se(n);let l,c,h,d;if((t.bitmap||t.data)&&t.count>1){const n=t.bitmap||t.data.buffer;c=JSON.stringify(a?o:[o.slice(0,4),s]),l=this._cachedBitmapsMap.get(n),l||(l=new Map,this._cachedBitmapsMap.set(n,l));const r=l.get(c);if(r&&!a){const t=Math.round(Math.min(o[0],o[2])+o[4]),n=Math.round(Math.min(o[1],o[3])+o[5]);return this.dependencyTracker?.recordDependencies(e,nn),{canvas:r,offsetX:t,offsetY:n}}h=r}h||(d=this.cachedCanvases.getCanvas("maskCanvas",r,i),kn(d.context,t));let u=se.transform(o,[1/r,0,0,-1/i,0,0]);u=se.transform(u,[1,0,0,1,0,-i]);const p=_n.slice();se.axialAlignedBoundingBox([0,0,r,i],u,p);const[f,m,g,v]=p,y=Math.round(g-f)||1,b=Math.round(v-m)||1,w=this.cachedCanvases.getCanvas("fillCanvas",y,b),_=w.context,A=f,x=m;_.translate(-A,-x),_.transform(...u),h||(h=this._scaleImage(d.canvas,Te(_)),h=h.img,l&&a&&l.set(c,h)),_.imageSmoothingEnabled=Dn(Se(_),t.interpolate),xn(_,h,0,0,h.width,h.height,0,0,r,i),_.globalCompositeOperation="source-in";const E=se.transform(Te(_),[1,0,0,1,-A,-x]);return _.fillStyle=a?s.getPattern(n,this,E,rn,e):s,_.fillRect(0,0,r,i),l&&!a&&(this.cachedCanvases.delete("fillCanvas"),l.set(c,w.canvas)),this.dependencyTracker?.recordDependencies(e,nn),{canvas:w.canvas,offsetX:Math.round(A),offsetY:Math.round(x)}}setLineWidth(e,t){this.dependencyTracker?.recordSimpleData("lineWidth",e),t!==this.current.lineWidth&&(this._cachedScaleForStroking[0]=-1),this.current.lineWidth=t,this.ctx.lineWidth=t}setLineCap(e,t){this.dependencyTracker?.recordSimpleData("lineCap",e),this.ctx.lineCap=Mn[t]}setLineJoin(e,t){this.dependencyTracker?.recordSimpleData("lineJoin",e),this.ctx.lineJoin=Pn[t]}setMiterLimit(e,t){this.dependencyTracker?.recordSimpleData("miterLimit",e),this.ctx.miterLimit=t}setDash(e,t,n){this.dependencyTracker?.recordSimpleData("dash",e);const r=this.ctx;void 0!==r.setLineDash&&(r.setLineDash(t),r.lineDashOffset=n)}setRenderingIntent(e,t){}setFlatness(e,t){}setGState(e,t){for(const[n,r]of t)switch(n){case"LW":this.setLineWidth(e,r);break;case"LC":this.setLineCap(e,r);break;case"LJ":this.setLineJoin(e,r);break;case"ML":this.setMiterLimit(e,r);break;case"D":this.setDash(e,r[0],r[1]);break;case"RI":this.setRenderingIntent(e,r);break;case"FL":this.setFlatness(e,r);break;case"Font":this.setFont(e,r[0],r[1]);break;case"CA":this.dependencyTracker?.recordSimpleData("strokeAlpha",e),this.current.strokeAlpha=r;break;case"ca":this.dependencyTracker?.recordSimpleData("fillAlpha",e),this.ctx.globalAlpha=this.current.fillAlpha=r;break;case"BM":this.dependencyTracker?.recordSimpleData("globalCompositeOperation",e),this.ctx.globalCompositeOperation=r;break;case"SMask":this.dependencyTracker?.recordSimpleData("SMask",e),this.current.activeSMask=r?this.tempSMask:null,this.tempSMask=null,this.checkSMaskState();break;case"TR":this.dependencyTracker?.recordSimpleData("filter",e),this.ctx.filter=this.current.transferMaps=this.filterFactory.addFilter(r)}}get inSMaskMode(){return!!this.suspendedCtx}checkSMaskState(){const e=this.inSMaskMode;this.current.activeSMask&&!e?this.beginSMaskMode():!this.current.activeSMask&&e&&this.endSMaskMode()}beginSMaskMode(e){if(this.inSMaskMode)throw new Error("beginSMaskMode called while already in smask mode");const t=this.ctx.canvas.width,n=this.ctx.canvas.height,r="smaskGroupAt"+this.groupLevel,i=this.cachedCanvases.getCanvas(r,t,n);this.suspendedCtx=this.ctx;const s=this.ctx=i.context;s.setTransform(this.suspendedCtx.getTransform()),Sn(this.suspendedCtx,s),function(e,t){if(e._removeMirroring)throw new Error("Context is already forwarding operations.");e.__originalSave=e.save,e.__originalRestore=e.restore,e.__originalRotate=e.rotate,e.__originalScale=e.scale,e.__originalTranslate=e.translate,e.__originalTransform=e.transform,e.__originalSetTransform=e.setTransform,e.__originalResetTransform=e.resetTransform,e.__originalClip=e.clip,e.__originalMoveTo=e.moveTo,e.__originalLineTo=e.lineTo,e.__originalBezierCurveTo=e.bezierCurveTo,e.__originalRect=e.rect,e.__originalClosePath=e.closePath,e.__originalBeginPath=e.beginPath,e._removeMirroring=()=>{e.save=e.__originalSave,e.restore=e.__originalRestore,e.rotate=e.__originalRotate,e.scale=e.__originalScale,e.translate=e.__originalTranslate,e.transform=e.__originalTransform,e.setTransform=e.__originalSetTransform,e.resetTransform=e.__originalResetTransform,e.clip=e.__originalClip,e.moveTo=e.__originalMoveTo,e.lineTo=e.__originalLineTo,e.bezierCurveTo=e.__originalBezierCurveTo,e.rect=e.__originalRect,e.closePath=e.__originalClosePath,e.beginPath=e.__originalBeginPath,delete e._removeMirroring},e.save=function(){t.save(),this.__originalSave()},e.restore=function(){t.restore(),this.__originalRestore()},e.translate=function(e,n){t.translate(e,n),this.__originalTranslate(e,n)},e.scale=function(e,n){t.scale(e,n),this.__originalScale(e,n)},e.transform=function(e,n,r,i,s,a){t.transform(e,n,r,i,s,a),this.__originalTransform(e,n,r,i,s,a)},e.setTransform=function(e,n,r,i,s,a){t.setTransform(e,n,r,i,s,a),this.__originalSetTransform(e,n,r,i,s,a)},e.resetTransform=function(){t.resetTransform(),this.__originalResetTransform()},e.rotate=function(e){t.rotate(e),this.__originalRotate(e)},e.clip=function(e){t.clip(e),this.__originalClip(e)},e.moveTo=function(e,n){t.moveTo(e,n),this.__originalMoveTo(e,n)},e.lineTo=function(e,n){t.lineTo(e,n),this.__originalLineTo(e,n)},e.bezierCurveTo=function(e,n,r,i,s,a){t.bezierCurveTo(e,n,r,i,s,a),this.__originalBezierCurveTo(e,n,r,i,s,a)},e.rect=function(e,n,r,i){t.rect(e,n,r,i),this.__originalRect(e,n,r,i)},e.closePath=function(){t.closePath(),this.__originalClosePath()},e.beginPath=function(){t.beginPath(),this.__originalBeginPath()}}(s,this.suspendedCtx),this.setGState(e,[["BM","source-over"]])}endSMaskMode(){if(!this.inSMaskMode)throw new Error("endSMaskMode called while not in smask mode");this.ctx._removeMirroring(),Sn(this.ctx,this.suspendedCtx),this.ctx=this.suspendedCtx,this.suspendedCtx=null}compose(e){if(!this.current.activeSMask)return;e?(e[0]=Math.floor(e[0]),e[1]=Math.floor(e[1]),e[2]=Math.ceil(e[2]),e[3]=Math.ceil(e[3])):e=[0,0,this.ctx.canvas.width,this.ctx.canvas.height];const t=this.current.activeSMask,n=this.suspendedCtx;this.composeSMask(n,t,this.ctx,e),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()}composeSMask(e,t,n,r){const i=r[0],s=r[1],a=r[2]-i,o=r[3]-s;0!==a&&0!==o&&(this.genericComposeSMask(t.context,n,a,o,t.subtype,t.backdrop,t.transferMap,i,s,t.offsetX,t.offsetY),e.save(),e.globalAlpha=1,e.globalCompositeOperation="source-over",e.setTransform(1,0,0,1,0,0),e.drawImage(n.canvas,0,0),e.restore())}genericComposeSMask(e,t,n,r,i,s,a,o,l,c,h){let d=e.canvas,u=o-c,p=l-h;if(s)if(u<0||p<0||u+n>d.width||p+r>d.height){const e=this.cachedCanvases.getCanvas("maskExtension",n,r),t=e.context;t.drawImage(d,-u,-p),t.globalCompositeOperation="destination-atop",t.fillStyle=s,t.fillRect(0,0,n,r),t.globalCompositeOperation="source-over",d=e.canvas,u=p=0}else{e.save(),e.globalAlpha=1,e.setTransform(1,0,0,1,0,0);const t=new Path2D;t.rect(u,p,n,r),e.clip(t),e.globalCompositeOperation="destination-atop",e.fillStyle=s,e.fillRect(u,p,n,r),e.restore()}t.save(),t.globalAlpha=1,t.setTransform(1,0,0,1,0,0),"Alpha"===i&&a?t.filter=this.filterFactory.addAlphaFilter(a):"Luminosity"===i&&(t.filter=this.filterFactory.addLuminosityFilter(a));const f=new Path2D;f.rect(o,l,n,r),t.clip(f),t.globalCompositeOperation="destination-in",t.drawImage(d,u,p,n,r,o,l,n,r),t.restore()}save(e){this.inSMaskMode&&Sn(this.ctx,this.suspendedCtx),this.ctx.save();const t=this.current;this.stateStack.push(t),this.current=t.clone(),this.dependencyTracker?.save(e)}restore(e){this.dependencyTracker?.restore(e),0!==this.stateStack.length?(this.current=this.stateStack.pop(),this.ctx.restore(),this.inSMaskMode&&Sn(this.suspendedCtx,this.ctx),this.checkSMaskState(),this.pendingClip=null,this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null):this.inSMaskMode&&this.endSMaskMode()}transform(e,t,n,r,i,s,a){this.dependencyTracker?.recordIncrementalData("transform",e),this.ctx.transform(t,n,r,i,s,a),this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null}constructPath(e,t,n,r){let[i]=n;if(!r)return i||=n[0]=new Path2D,void this[t](e,i);if(null!==this.dependencyTracker){const n=t===F.stroke?this.current.lineWidth/2:0;this.dependencyTracker.resetBBox(e).recordBBox(e,this.ctx,r[0]-n,r[2]+n,r[1]-n,r[3]+n).recordDependencies(e,["transform"])}if(!(i instanceof Path2D)){const e=n[0]=new Path2D;for(let t=0,n=i.length;t<n;)switch(i[t++]){case R:e.moveTo(i[t++],i[t++]);break;case N:e.lineTo(i[t++],i[t++]);break;case L:e.bezierCurveTo(i[t++],i[t++],i[t++],i[t++],i[t++],i[t++]);break;case O:e.closePath();break;default:U(`Unrecognized drawing path operator: ${i[t-1]}`)}i=e}se.axialAlignedBoundingBox(r,Se(this.ctx),this.current.minMax),this[t](e,i),this._pathStartIdx=e}closePath(e){this.ctx.closePath()}stroke(e,t){let n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];const r=this.ctx,i=this.current.strokeColor;if(r.globalAlpha=this.current.strokeAlpha,this.contentVisible)if("object"===typeof i&&i?.getPattern){const n=i.isModifyingCurrentTransform()?r.getTransform():null;if(r.save(),r.strokeStyle=i.getPattern(r,this,Te(r),sn,e),n){const e=new Path2D;e.addPath(t,r.getTransform().invertSelf().multiplySelf(n)),t=e}this.rescaleAndStroke(t,!1),r.restore()}else this.rescaleAndStroke(t,!0);this.dependencyTracker?.recordDependencies(e,Yt),n&&this.consumePath(e,t,this.current.getClippedPathBoundingBox(sn,Se(this.ctx))),r.globalAlpha=this.current.fillAlpha}closeStroke(e,t){this.stroke(e,t)}fill(e,t){let n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];const r=this.ctx,i=this.current.fillColor;let s=!1;if(this.current.patternFill){const n=i.isModifyingCurrentTransform()?r.getTransform():null;if(this.dependencyTracker?.save(e),r.save(),r.fillStyle=i.getPattern(r,this,Te(r),rn,e),n){const e=new Path2D;e.addPath(t,r.getTransform().invertSelf().multiplySelf(n)),t=e}s=!0}const a=this.current.getClippedPathBoundingBox();this.contentVisible&&null!==a&&(this.pendingEOFill?(r.fill(t,"evenodd"),this.pendingEOFill=!1):r.fill(t)),this.dependencyTracker?.recordDependencies(e,Zt),s&&(r.restore(),this.dependencyTracker?.restore(e)),n&&this.consumePath(e,t,a)}eoFill(e,t){this.pendingEOFill=!0,this.fill(e,t)}fillStroke(e,t){this.fill(e,t,!1),this.stroke(e,t,!1),this.consumePath(e,t)}eoFillStroke(e,t){this.pendingEOFill=!0,this.fillStroke(e,t)}closeFillStroke(e,t){this.fillStroke(e,t)}closeEOFillStroke(e,t){this.pendingEOFill=!0,this.fillStroke(e,t)}endPath(e,t){this.consumePath(e,t)}rawFillPath(e,t){this.ctx.fill(t),this.dependencyTracker?.recordDependencies(e,Qt).recordOperation(e)}clip(e){this.dependencyTracker?.recordFutureForcedDependency("clipMode",e),this.pendingClip=In}eoClip(e){this.dependencyTracker?.recordFutureForcedDependency("clipMode",e),this.pendingClip=Fn}beginText(e){this.current.textMatrix=null,this.current.textMatrixScale=1,this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0,this.dependencyTracker?.recordOpenMarker(e).resetIncrementalData("sameLineText").resetIncrementalData("moveText",e)}endText(e){const t=this.pendingTextPaths,n=this.ctx;if(this.dependencyTracker){const{dependencyTracker:n}=this;void 0!==t&&n.recordFutureForcedDependency("textClip",n.getOpenMarker()).recordFutureForcedDependency("textClip",e),n.recordCloseMarker(e)}if(void 0!==t){const e=new Path2D,r=n.getTransform().invertSelf();for(const{transform:n,x:i,y:s,fontSize:a,path:o}of t)o&&e.addPath(o,new DOMMatrix(n).preMultiplySelf(r).translate(i,s).scale(a,-a));n.clip(e)}delete this.pendingTextPaths}setCharSpacing(e,t){this.dependencyTracker?.recordSimpleData("charSpacing",e),this.current.charSpacing=t}setWordSpacing(e,t){this.dependencyTracker?.recordSimpleData("wordSpacing",e),this.current.wordSpacing=t}setHScale(e,t){this.dependencyTracker?.recordSimpleData("hScale",e),this.current.textHScale=t/100}setLeading(e,t){this.dependencyTracker?.recordSimpleData("leading",e),this.current.leading=-t}setFont(e,t,n){this.dependencyTracker?.recordSimpleData("font",e).recordSimpleDataFromNamed("fontObj",t,e);const r=this.commonObjs.get(t),i=this.current;if(!r)throw new Error(`Can't find font for ${t}`);if(i.fontMatrix=r.fontMatrix||s,0!==i.fontMatrix[0]&&0!==i.fontMatrix[3]||U("Invalid font matrix for font "+t),n<0?(n=-n,i.fontDirection=-1):i.fontDirection=1,this.current.font=r,this.current.fontSize=n,r.isType3Font)return;const a=r.loadedName||"sans-serif",o=r.systemFontInfo?.css||`"${a}", ${r.fallbackName}`;let l="normal";r.black?l="900":r.bold&&(l="bold");const c=r.italic?"italic":"normal";let h=n;n<16?h=16:n>100&&(h=100),this.current.fontSizeScale=n/h,this.ctx.font=`${c} ${l} ${h}px ${o}`}setTextRenderingMode(e,t){this.dependencyTracker?.recordSimpleData("textRenderingMode",e),this.current.textRenderingMode=t}setTextRise(e,t){this.dependencyTracker?.recordSimpleData("textRise",e),this.current.textRise=t}moveText(e,t,n){this.dependencyTracker?.resetIncrementalData("sameLineText").recordIncrementalData("moveText",e),this.current.x=this.current.lineX+=t,this.current.y=this.current.lineY+=n}setLeadingMoveText(e,t,n){this.setLeading(e,-n),this.moveText(e,t,n)}setTextMatrix(e,t){this.dependencyTracker?.recordSimpleData("textMatrix",e);const{current:n}=this;n.textMatrix=t,n.textMatrixScale=Math.hypot(t[0],t[1]),n.x=n.lineX=0,n.y=n.lineY=0}nextLine(e){this.moveText(e,0,this.current.leading),this.dependencyTracker?.recordIncrementalData("moveText",this.dependencyTracker.getSimpleIndex("leading")??e)}#_r(e,t,n){const r=new Path2D;return r.addPath(e,new DOMMatrix(n).invertSelf().multiplySelf(t)),r}paintChar(e,t,n,r,i,s){const a=this.ctx,o=this.current,l=o.font,c=o.textRenderingMode,h=o.fontSize/o.fontSizeScale,d=c&x,u=!!(c&E),p=o.patternFill&&!l.missingFile,f=o.patternStroke&&!l.missingFile;let m;if((l.disableFontFace||u||p||f)&&!l.missingFile&&(m=l.getPathGenerator(this.commonObjs,t)),m&&(l.disableFontFace||p||f)){let t;if(a.save(),a.translate(n,r),a.scale(h,-h),this.dependencyTracker?.recordCharacterBBox(e,a,l),d===b||d===_)if(i){t=a.getTransform(),a.setTransform(...i);const e=this.#_r(m,t,i);a.fill(e)}else a.fill(m);if(d===w||d===_)if(s){t||=a.getTransform(),a.setTransform(...s);const{a:e,b:n,c:r,d:i}=t,o=se.inverseTransform(s),l=se.transform([e,n,r,i,0,0],o);se.singularValueDecompose2dScale(l,wn),a.lineWidth*=Math.max(wn[0],wn[1])/h,a.stroke(this.#_r(m,t,s))}else a.lineWidth/=h,a.stroke(m);a.restore()}else d!==b&&d!==_||(a.fillText(t,n,r),this.dependencyTracker?.recordCharacterBBox(e,a,l,h,n,r,()=>a.measureText(t))),d!==w&&d!==_||(this.dependencyTracker&&this.dependencyTracker?.recordCharacterBBox(e,a,l,h,n,r,()=>a.measureText(t)).recordDependencies(e,Yt),a.strokeText(t,n,r));if(u){(this.pendingTextPaths||=[]).push({transform:Se(a),x:n,y:r,fontSize:h,path:m}),this.dependencyTracker?.recordCharacterBBox(e,a,l,h,n,r)}}get isFontSubpixelAAEnabled(){const{context:e}=this.cachedCanvases.getCanvas("isFontSubpixelAAEnabled",10,10);e.scale(1.5,1),e.fillText("I",0,10);const t=e.getImageData(0,0,10,10).data;let n=!1;for(let r=3;r<t.length;r+=4)if(t[r]>0&&t[r]<255){n=!0;break}return G(this,"isFontSubpixelAAEnabled",n)}showText(e,t){this.dependencyTracker&&(this.dependencyTracker.recordDependencies(e,en).resetBBox(e),this.current.textRenderingMode&E&&this.dependencyTracker.recordFutureForcedDependency("textClip",e).inheritPendingDependenciesAsFutureForcedDependencies());const n=this.current,r=n.font;if(r.isType3Font)return this.showType3Text(e,t),void this.dependencyTracker?.recordShowTextOperation(e);const i=n.fontSize;if(0===i)return void this.dependencyTracker?.recordOperation(e);const s=this.ctx,a=n.fontSizeScale,o=n.charSpacing,l=n.wordSpacing,c=n.fontDirection,h=n.textHScale*c,d=t.length,u=r.vertical,p=u?1:-1,f=r.defaultVMetrics,m=i*n.fontMatrix[0],g=n.textRenderingMode===b&&!r.disableFontFace&&!n.patternFill;let v,y;if(s.save(),n.textMatrix&&s.transform(...n.textMatrix),s.translate(n.x,n.y+n.textRise),c>0?s.scale(h,-1):s.scale(h,1),n.patternFill){s.save();const t=n.fillColor.getPattern(s,this,Te(s),rn,e);v=Se(s),s.restore(),s.fillStyle=t}if(n.patternStroke){s.save();const t=n.strokeColor.getPattern(s,this,Te(s),sn,e);y=Se(s),s.restore(),s.strokeStyle=t}let A=n.lineWidth;const C=n.textMatrixScale;if(0===C||0===A){const e=n.textRenderingMode&x;e!==w&&e!==_||(A=this.getSinglePixelWidth())}else A/=C;if(1!==a&&(s.scale(a,a),A/=a),s.lineWidth=A,r.isInvalidPDFjsFont){const r=[];let i=0;for(const e of t)r.push(e.unicode),i+=e.width;const a=r.join("");if(s.fillText(a,0,0),null!==this.dependencyTracker){const t=s.measureText(a);this.dependencyTracker.recordBBox(e,this.ctx,-t.actualBoundingBoxLeft,t.actualBoundingBoxRight,-t.actualBoundingBoxAscent,t.actualBoundingBoxDescent).recordShowTextOperation(e)}return n.x+=i*m*h,s.restore(),void this.compose()}let k,S=0;for(k=0;k<d;++k){const n=t[k];if("number"===typeof n){S+=p*n*i/1e3;continue}let h=!1;const d=(n.isSpace?l:0)+o,b=n.fontChar,w=n.accent;let _,A,x,E=n.width;if(u){const e=n.vmetric||f,t=-(n.vmetric?e[1]:.5*E)*m,r=e[2]*m;E=e?-e[0]:E,_=t/a,A=(S+r)/a}else _=S/a,A=0;if(r.remeasure&&E>0){x=s.measureText(b);const e=1e3*x.width/i*a;if(E<e&&this.isFontSubpixelAAEnabled){const t=E/e;h=!0,s.save(),s.scale(t,1),_/=t}else E!==e&&(_+=(E-e)/2e3*i/a)}if(this.contentVisible&&(n.isInFont||r.missingFile))if(g&&!w)s.fillText(b,_,A),this.dependencyTracker?.recordCharacterBBox(e,s,x?{bbox:null}:r,i/a,_,A,()=>x??s.measureText(b));else if(this.paintChar(e,b,_,A,v,y),w){const t=_+i*w.offset.x/a,n=A-i*w.offset.y/a;this.paintChar(e,w.fontChar,t,n,v,y)}S+=u?E*m-d*c:E*m+d*c,h&&s.restore()}u?n.y-=S:n.x+=S*h,s.restore(),this.compose(),this.dependencyTracker?.recordShowTextOperation(e)}showType3Text(e,t){const n=this.ctx,r=this.current,i=r.font,a=r.fontSize,o=r.fontDirection,l=i.vertical?1:-1,c=r.charSpacing,h=r.wordSpacing,d=r.textHScale*o,u=r.fontMatrix||s,p=t.length;let f,m,g,v;if(r.textRenderingMode===A||0===a)return;this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null,n.save(),r.textMatrix&&n.transform(...r.textMatrix),n.translate(r.x,r.y+r.textRise),n.scale(d,o);const y=this.dependencyTracker;for(this.dependencyTracker=y?new Xt(y,e):null,f=0;f<p;++f){if(m=t[f],"number"===typeof m){v=l*m*a/1e3,this.ctx.translate(v,0),r.x+=v*d;continue}const e=(m.isSpace?h:0)+c,s=i.charProcOperatorList[m.operatorListId];s?this.contentVisible&&(this.save(),n.scale(a,a),n.transform(...u),this.executeOperatorList(s),this.restore()):U(`Type3 character "${m.operatorListId}" is not available.`);const o=[m.width,0];se.applyTransform(o,u),g=o[0]*a+e,n.translate(g,0),r.x+=g*d}n.restore(),y&&(this.dependencyTracker=y)}setCharWidth(e,t,n){}setCharWidthAndBounds(e,t,n,r,i,s,a){const o=new Path2D;o.rect(r,i,s-r,a-i),this.ctx.clip(o),this.dependencyTracker?.recordBBox(e,this.ctx,r,s,i,a).recordClipBox(e,this.ctx,r,s,i,a),this.endPath(e)}getColorN_Pattern(e,t){let n;if("TilingPattern"===t[0]){const e=this.baseTransform||Se(this.ctx),r={createCanvasGraphics:(e,t)=>new Rn(e,this.commonObjs,this.objs,this.canvasFactory,this.filterFactory,{optionalContentConfig:this.optionalContentConfig,markedContentStack:this.markedContentStack},void 0,void 0,this.dependencyTracker?new Xt(this.dependencyTracker,t,!0):null)};n=new gn(t,this.ctx,r,e)}else n=this._getPattern(e,t[1],t[2]);return n}setStrokeColorN(e){this.dependencyTracker?.recordSimpleData("strokeColor",e);for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.current.strokeColor=this.getColorN_Pattern(e,n),this.current.patternStroke=!0}setFillColorN(e){this.dependencyTracker?.recordSimpleData("fillColor",e);for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.current.fillColor=this.getColorN_Pattern(e,n),this.current.patternFill=!0}setStrokeRGBColor(e,t){this.dependencyTracker?.recordSimpleData("strokeColor",e),this.ctx.strokeStyle=this.current.strokeColor=t,this.current.patternStroke=!1}setStrokeTransparent(e){this.dependencyTracker?.recordSimpleData("strokeColor",e),this.ctx.strokeStyle=this.current.strokeColor="transparent",this.current.patternStroke=!1}setFillRGBColor(e,t){this.dependencyTracker?.recordSimpleData("fillColor",e),this.ctx.fillStyle=this.current.fillColor=t,this.current.patternFill=!1}setFillTransparent(e){this.dependencyTracker?.recordSimpleData("fillColor",e),this.ctx.fillStyle=this.current.fillColor="transparent",this.current.patternFill=!1}_getPattern(e,t){let n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return this.cachedPatterns.has(t)?n=this.cachedPatterns.get(t):(n=function(e){switch(e[0]){case"RadialAxial":return new cn(e);case"Mesh":return new un(e);case"Dummy":return new pn}throw new Error(`Unknown IR type: ${e[0]}`)}(this.getObject(e,t)),this.cachedPatterns.set(t,n)),r&&(n.matrix=r),n}shadingFill(e,t){if(!this.contentVisible)return;const n=this.ctx;this.save(e);const r=this._getPattern(e,t);n.fillStyle=r.getPattern(n,this,Te(n),an,e);const i=Te(n);if(i){const{width:e,height:t}=n.canvas,r=_n.slice();se.axialAlignedBoundingBox([0,0,e,t],i,r);const[s,a,o,l]=r;this.ctx.fillRect(s,a,o-s,l-a)}else this.ctx.fillRect(-1e10,-1e10,2e10,2e10);this.dependencyTracker?.resetBBox(e).recordFullPageBBox(e).recordDependencies(e,tn).recordDependencies(e,Zt).recordOperation(e),this.compose(this.current.getClippedPathBoundingBox()),this.restore(e)}beginInlineImage(){H("Should not call beginInlineImage")}beginImageData(){H("Should not call beginImageData")}paintFormXObjectBegin(e,t,n){if(this.contentVisible&&(this.save(e),this.baseTransformStack.push(this.baseTransform),t&&this.transform(e,...t),this.baseTransform=Se(this.ctx),n)){se.axialAlignedBoundingBox(n,this.baseTransform,this.current.minMax);const[t,r,i,s]=n,a=new Path2D;a.rect(t,r,i-t,s-r),this.ctx.clip(a),this.dependencyTracker?.recordClipBox(e,this.ctx,t,i,r,s),this.endPath(e)}}paintFormXObjectEnd(e){this.contentVisible&&(this.restore(e),this.baseTransform=this.baseTransformStack.pop())}beginGroup(e,t){if(!this.contentVisible)return;this.save(e),this.inSMaskMode&&(this.endSMaskMode(),this.current.activeSMask=null);const n=this.ctx;t.isolated||j("TODO: Support non-isolated groups."),t.knockout&&U("Knockout groups not supported.");const r=Se(n);if(t.matrix&&n.transform(...t.matrix),!t.bbox)throw new Error("Bounding box is required.");let i=_n.slice();se.axialAlignedBoundingBox(t.bbox,Se(n),i);const s=[0,0,n.canvas.width,n.canvas.height];i=se.intersect(i,s)||[0,0,0,0];const a=Math.floor(i[0]),o=Math.floor(i[1]),l=Math.max(Math.ceil(i[2])-a,1),c=Math.max(Math.ceil(i[3])-o,1);this.current.startNewPathAndClipBox([0,0,l,c]);let h="groupAt"+this.groupLevel;t.smask&&(h+="_smask_"+this.smaskCounter++%2);const d=this.cachedCanvases.getCanvas(h,l,c),u=d.context;u.translate(-a,-o),u.transform(...r);let p=new Path2D;const[f,m,g,v]=t.bbox;if(p.rect(f,m,g-f,v-m),t.matrix){const e=new Path2D;e.addPath(p,new DOMMatrix(t.matrix)),p=e}u.clip(p),t.smask&&this.smaskStack.push({canvas:d.canvas,context:u,offsetX:a,offsetY:o,subtype:t.smask.subtype,backdrop:t.smask.backdrop,transferMap:t.smask.transferMap||null,startTransformInverse:null}),t.smask&&!this.dependencyTracker||(n.setTransform(1,0,0,1,0,0),n.translate(a,o),n.save()),Sn(n,u),this.ctx=u,this.dependencyTracker?.inheritSimpleDataAsFutureForcedDependencies(["fillAlpha","strokeAlpha","globalCompositeOperation"]).pushBaseTransform(n),this.setGState(e,[["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(n),this.groupLevel++}endGroup(e,t){if(!this.contentVisible)return;this.groupLevel--;const n=this.ctx,r=this.groupStack.pop();if(this.ctx=r,this.ctx.imageSmoothingEnabled=!1,this.dependencyTracker?.popBaseTransform(),t.smask)this.tempSMask=this.smaskStack.pop(),this.restore(e),this.dependencyTracker&&this.ctx.restore();else{this.ctx.restore();const t=Se(this.ctx);this.restore(e),this.ctx.save(),this.ctx.setTransform(...t);const r=_n.slice();se.axialAlignedBoundingBox([0,0,n.canvas.width,n.canvas.height],t,r),this.ctx.drawImage(n.canvas,0,0),this.ctx.restore(),this.compose(r)}}beginAnnotation(e,t,n,r,i,s){if(this.#br(),Tn(this.ctx),this.ctx.save(),this.save(e),this.baseTransform&&this.ctx.setTransform(...this.baseTransform),n){const i=n[2]-n[0],a=n[3]-n[1];if(s&&this.annotationCanvasMap){(r=r.slice())[4]-=n[0],r[5]-=n[1],(n=n.slice())[0]=n[1]=0,n[2]=i,n[3]=a,se.singularValueDecompose2dScale(Se(this.ctx),wn);const{viewportScale:e}=this,s=Math.ceil(i*this.outputScaleX*e),o=Math.ceil(a*this.outputScaleY*e);this.annotationCanvas=this.canvasFactory.create(s,o);const{canvas:l,context:c}=this.annotationCanvas;this.annotationCanvasMap.set(t,l),this.annotationCanvas.savedCtx=this.ctx,this.ctx=c,this.ctx.save(),this.ctx.setTransform(wn[0],0,0,-wn[1],0,a*wn[1]),Tn(this.ctx)}else{Tn(this.ctx),this.endPath(e);const t=new Path2D;t.rect(n[0],n[1],i,a),this.ctx.clip(t)}}this.current=new En(this.ctx.canvas.width,this.ctx.canvas.height),this.transform(e,...r),this.transform(e,...i)}endAnnotation(e){this.annotationCanvas&&(this.ctx.restore(),this.#wr(),this.ctx=this.annotationCanvas.savedCtx,delete this.annotationCanvas.savedCtx,delete this.annotationCanvas)}paintImageMaskXObject(e,t){if(!this.contentVisible)return;const n=t.count;(t=this.getObject(e,t.data,t)).count=n;const r=this.ctx,i=this._createMaskCanvas(e,t),s=i.canvas;r.save(),r.setTransform(1,0,0,1,0,0),r.drawImage(s,i.offsetX,i.offsetY),this.dependencyTracker?.resetBBox(e).recordBBox(e,this.ctx,i.offsetX,i.offsetX+s.width,i.offsetY,i.offsetY+s.height).recordOperation(e),r.restore(),this.compose()}paintImageMaskXObjectRepeat(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,s=arguments.length>5?arguments[5]:void 0,a=arguments.length>6?arguments[6]:void 0;if(!this.contentVisible)return;t=this.getObject(e,t.data,t);const o=this.ctx;o.save();const l=Se(o);o.transform(n,r,i,s,0,0);const c=this._createMaskCanvas(e,t);o.setTransform(1,0,0,1,c.offsetX-l[4],c.offsetY-l[5]),this.dependencyTracker?.resetBBox(e);for(let h=0,d=a.length;h<d;h+=2){const t=se.transform(l,[n,r,i,s,a[h],a[h+1]]);o.drawImage(c.canvas,t[4],t[5]),this.dependencyTracker?.recordBBox(e,this.ctx,t[4],t[4]+c.canvas.width,t[5],t[5]+c.canvas.height)}o.restore(),this.compose(),this.dependencyTracker?.recordOperation(e)}paintImageMaskXObjectGroup(e,t){if(!this.contentVisible)return;const n=this.ctx,r=this.current.fillColor,i=this.current.patternFill;this.dependencyTracker?.resetBBox(e).recordDependencies(e,nn);for(const s of t){const{data:t,width:a,height:o,transform:l}=s,c=this.cachedCanvases.getCanvas("maskCanvas",a,o),h=c.context;h.save();kn(h,this.getObject(e,t,s)),h.globalCompositeOperation="source-in",h.fillStyle=i?r.getPattern(h,this,Te(n),rn,e):r,h.fillRect(0,0,a,o),h.restore(),n.save(),n.transform(...l),n.scale(1,-1),xn(n,c.canvas,0,0,a,o,0,-1,1,1),this.dependencyTracker?.recordBBox(e,n,0,a,0,o),n.restore()}this.compose(),this.dependencyTracker?.recordOperation(e)}paintImageXObject(e,t){if(!this.contentVisible)return;const n=this.getObject(e,t);n?this.paintInlineImageXObject(e,n):U("Dependent image isn't ready yet")}paintImageXObjectRepeat(e,t,n,r,i){if(!this.contentVisible)return;const s=this.getObject(e,t);if(!s)return void U("Dependent image isn't ready yet");const a=s.width,o=s.height,l=[];for(let c=0,h=i.length;c<h;c+=2)l.push({transform:[n,0,0,r,i[c],i[c+1]],x:0,y:0,w:a,h:o});this.paintInlineImageXObjectGroup(e,s,l)}applyTransferMapsToCanvas(e){return"none"!==this.current.transferMaps&&(e.filter=this.current.transferMaps,e.drawImage(e.canvas,0,0),e.filter="none"),e.canvas}applyTransferMapsToBitmap(e){if("none"===this.current.transferMaps)return e.bitmap;const{bitmap:t,width:n,height:r}=e,i=this.cachedCanvases.getCanvas("inlineImage",n,r),s=i.context;return s.filter=this.current.transferMaps,s.drawImage(t,0,0),s.filter="none",i.canvas}paintInlineImageXObject(e,t){if(!this.contentVisible)return;const n=t.width,r=t.height,i=this.ctx;this.save(e);const{filter:s}=i;let a;if("none"!==s&&""!==s&&(i.filter="none"),i.scale(1/n,-1/r),t.bitmap)a=this.applyTransferMapsToBitmap(t);else if("function"===typeof HTMLElement&&t instanceof HTMLElement||!t.data)a=t;else{const e=this.cachedCanvases.getCanvas("inlineImage",n,r).context;Cn(e,t),a=this.applyTransferMapsToCanvas(e)}const o=this._scaleImage(a,Te(i));i.imageSmoothingEnabled=Dn(Se(i),t.interpolate),this.dependencyTracker?.resetBBox(e).recordBBox(e,i,0,n,-r,0).recordDependencies(e,Jt).recordOperation(e),xn(i,o.img,0,0,o.paintWidth,o.paintHeight,0,-r,n,r),this.compose(),this.restore(e)}paintInlineImageXObjectGroup(e,t,n){if(!this.contentVisible)return;const r=this.ctx;let i;if(t.bitmap)i=t.bitmap;else{const e=t.width,n=t.height,r=this.cachedCanvases.getCanvas("inlineImage",e,n).context;Cn(r,t),i=this.applyTransferMapsToCanvas(r)}this.dependencyTracker?.resetBBox(e);for(const s of n)r.save(),r.transform(...s.transform),r.scale(1,-1),xn(r,i,s.x,s.y,s.w,s.h,0,-1,1,1),this.dependencyTracker?.recordBBox(e,r,0,1,-1,0),r.restore();this.dependencyTracker?.recordOperation(e),this.compose()}paintSolidColorImageMask(e){this.contentVisible&&(this.dependencyTracker?.resetBBox(e).recordBBox(e,this.ctx,0,1,0,1).recordDependencies(e,Zt).recordOperation(e),this.ctx.fillRect(0,0,1,1),this.compose())}markPoint(e,t){}markPointProps(e,t,n){}beginMarkedContent(e,t){this.dependencyTracker?.beginMarkedContent(e),this.markedContentStack.push({visible:!0})}beginMarkedContentProps(e,t,n){this.dependencyTracker?.beginMarkedContent(e),"OC"===t?this.markedContentStack.push({visible:this.optionalContentConfig.isVisible(n)}):this.markedContentStack.push({visible:!0}),this.contentVisible=this.isContentVisible()}endMarkedContent(e){this.dependencyTracker?.endMarkedContent(e),this.markedContentStack.pop(),this.contentVisible=this.isContentVisible()}beginCompat(e){}endCompat(e){}consumePath(e,t,n){const r=this.current.isEmptyClip();this.pendingClip&&this.current.updateClipFromPath(),this.pendingClip||this.compose(n);const i=this.ctx;this.pendingClip?(r||(this.pendingClip===Fn?i.clip(t,"evenodd"):i.clip(t)),this.pendingClip=null,this.dependencyTracker?.bboxToClipBoxDropOperation(e).recordFutureForcedDependency("clipPath",e)):this.dependencyTracker?.recordOperation(e),this.current.startNewPathAndClipBox(this.current.clipBox)}getSinglePixelWidth(){if(!this._cachedGetSinglePixelWidth){const e=Se(this.ctx);if(0===e[1]&&0===e[2])this._cachedGetSinglePixelWidth=1/Math.min(Math.abs(e[0]),Math.abs(e[3]));else{const t=Math.abs(e[0]*e[3]-e[2]*e[1]),n=Math.hypot(e[0],e[2]),r=Math.hypot(e[1],e[3]);this._cachedGetSinglePixelWidth=Math.max(n,r)/t}}return this._cachedGetSinglePixelWidth}getScaleForStroking(){if(-1===this._cachedScaleForStroking[0]){const{lineWidth:e}=this.current,{a:t,b:n,c:r,d:i}=this.ctx.getTransform();let s,a;if(0===n&&0===r){const n=Math.abs(t),r=Math.abs(i);if(n===r)if(0===e)s=a=1/n;else{const t=n*e;s=a=t<1?1/t:1}else if(0===e)s=1/n,a=1/r;else{const t=n*e,i=r*e;s=t<1?1/t:1,a=i<1?1/i:1}}else{const o=Math.abs(t*i-n*r),l=Math.hypot(t,n),c=Math.hypot(r,i);if(0===e)s=c/o,a=l/o;else{const t=e*o;s=c>t?c/t:1,a=l>t?l/t:1}}this._cachedScaleForStroking[0]=s,this._cachedScaleForStroking[1]=a}return this._cachedScaleForStroking}rescaleAndStroke(e,t){const{ctx:n,current:{lineWidth:r}}=this,[i,s]=this.getScaleForStroking();if(i===s)return n.lineWidth=(r||1)*i,void n.stroke(e);const a=n.getLineDash();t&&n.save(),n.scale(i,s),bn.a=1/i,bn.d=1/s;const o=new Path2D;if(o.addPath(e,bn),a.length>0){const e=Math.max(i,s);n.setLineDash(a.map(t=>t/e)),n.lineDashOffset/=e}n.lineWidth=r||1,n.stroke(o),t&&n.restore()}isContentVisible(){for(let e=this.markedContentStack.length-1;e>=0;e--)if(!this.markedContentStack[e].visible)return!1;return!0}}for(const Pi in F)void 0!==Rn.prototype[Pi]&&(Rn.prototype[F[Pi]]=Rn.prototype[Pi]);class Nn{#Ar;#xr;#Er;static strings=["fontFamily","fontWeight","italicAngle"];static write(e){const t=new TextEncoder,n={};let r=0;for(const l of Nn.strings){const i=t.encode(e[l]);n[l]=i,r+=4+i.length}const i=new ArrayBuffer(r),s=new Uint8Array(i),a=new DataView(i);let o=0;for(const l of Nn.strings){const e=n[l],t=e.length;a.setUint32(o,t),s.set(e,o+4),o+=4+t}return V(o===i.byteLength,"CssFontInfo.write: Buffer overflow"),i}constructor(e){this.#Ar=e,this.#xr=new DataView(this.#Ar),this.#Er=new TextDecoder}#Cr(e){V(e<Nn.strings.length,"Invalid string index");let t=0;for(let r=0;r<e;r++)t+=this.#xr.getUint32(t)+4;const n=this.#xr.getUint32(t);return this.#Er.decode(new Uint8Array(this.#Ar,t+4,n))}get fontFamily(){return this.#Cr(0)}get fontWeight(){return this.#Cr(1)}get italicAngle(){return this.#Cr(2)}}class Ln{#Ar;#xr;#Er;static strings=["css","loadedName","baseFontName","src"];static write(e){const t=new TextEncoder,n={};let r=0;for(const d of Ln.strings){const i=t.encode(e[d]);n[d]=i,r+=4+i.length}r+=4;let i,s,a=1+r;e.style&&(i=t.encode(e.style.style),s=t.encode(e.style.weight),a+=4+i.length+4+s.length);const o=new ArrayBuffer(a),l=new Uint8Array(o),c=new DataView(o);let h=0;c.setUint8(h++,e.guessFallback?1:0),c.setUint32(h,0),h+=4,r=0;for(const d of Ln.strings){const e=n[d],t=e.length;r+=4+t,c.setUint32(h,t),l.set(e,h+4),h+=4+t}return c.setUint32(h-r-4,r),e.style&&(c.setUint32(h,i.length),l.set(i,h+4),h+=4+i.length,c.setUint32(h,s.length),l.set(s,h+4),h+=4+s.length),V(h<=o.byteLength,"SubstitionInfo.write: Buffer overflow"),o.transferToFixedLength(h)}constructor(e){this.#Ar=e,this.#xr=new DataView(this.#Ar),this.#Er=new TextDecoder}get guessFallback(){return 0!==this.#xr.getUint8(0)}#Cr(e){V(e<Ln.strings.length,"Invalid string index");let t=5;for(let r=0;r<e;r++)t+=this.#xr.getUint32(t)+4;const n=this.#xr.getUint32(t);return this.#Er.decode(new Uint8Array(this.#Ar,t+4,n))}get css(){return this.#Cr(0)}get loadedName(){return this.#Cr(1)}get baseFontName(){return this.#Cr(2)}get src(){return this.#Cr(3)}get style(){let e=1;e+=4+this.#xr.getUint32(e);const t=this.#xr.getUint32(e),n=this.#Er.decode(new Uint8Array(this.#Ar,e+4,t));e+=4+t;const r=this.#xr.getUint32(e);return{style:n,weight:this.#Er.decode(new Uint8Array(this.#Ar,e+4,r))}}}class On{static bools=["black","bold","disableFontFace","fontExtraProperties","isInvalidPDFjsFont","isType3Font","italic","missingFile","remeasure","vertical"];static numbers=["ascent","defaultWidth","descent"];static strings=["fallbackName","loadedName","mimetype","name"];static#kr=(()=>Math.ceil(2*this.bools.length/8))();static#Sr=(()=>this.#kr+8*this.numbers.length)();static#Tr=(()=>this.#Sr+1+8)();static#Dr=(()=>this.#Tr+1+48)();static#Mr=(()=>this.#Dr+1+6)();#Ar;#Er;#xr;constructor(e){let{data:t,extra:n}=e;this.#Ar=t,this.#Er=new TextDecoder,this.#xr=new DataView(this.#Ar),n&&Object.assign(this,n)}#Pr(e){V(e<On.bools.length,"Invalid boolean index");const t=Math.floor(e/4),n=2*e%8,r=this.#xr.getUint8(t)>>n&3;return 0===r?void 0:2===r}get black(){return this.#Pr(0)}get bold(){return this.#Pr(1)}get disableFontFace(){return this.#Pr(2)}get fontExtraProperties(){return this.#Pr(3)}get isInvalidPDFjsFont(){return this.#Pr(4)}get isType3Font(){return this.#Pr(5)}get italic(){return this.#Pr(6)}get missingFile(){return this.#Pr(7)}get remeasure(){return this.#Pr(8)}get vertical(){return this.#Pr(9)}#Ir(e){return V(e<On.numbers.length,"Invalid number index"),this.#xr.getFloat64(On.#kr+8*e)}get ascent(){return this.#Ir(0)}get defaultWidth(){return this.#Ir(1)}get descent(){return this.#Ir(2)}get bbox(){let e=On.#Sr;if(0===this.#xr.getUint8(e))return;e+=1;const t=[];for(let n=0;n<4;n++)t.push(this.#xr.getInt16(e,!0)),e+=2;return t}get fontMatrix(){let e=On.#Tr;if(0===this.#xr.getUint8(e))return;e+=1;const t=[];for(let n=0;n<6;n++)t.push(this.#xr.getFloat64(e,!0)),e+=8;return t}get defaultVMetrics(){let e=On.#Dr;if(0===this.#xr.getUint8(e))return;e+=1;const t=[];for(let n=0;n<3;n++)t.push(this.#xr.getInt16(e,!0)),e+=2;return t}#Cr(e){V(e<On.strings.length,"Invalid string index");let t=On.#Mr+4;for(let i=0;i<e;i++)t+=this.#xr.getUint32(t)+4;const n=this.#xr.getUint32(t),r=new Uint8Array(n);return r.set(new Uint8Array(this.#Ar,t+4,n)),this.#Er.decode(r)}get fallbackName(){return this.#Cr(0)}get loadedName(){return this.#Cr(1)}get mimetype(){return this.#Cr(2)}get name(){return this.#Cr(3)}get data(){let e=On.#Mr;e+=4+this.#xr.getUint32(e);e+=4+this.#xr.getUint32(e);e+=4+this.#xr.getUint32(e);const t=this.#xr.getUint32(e);if(0!==t)return new Uint8Array(this.#Ar,e+4,t)}clearData(){let e=On.#Mr;e+=4+this.#xr.getUint32(e);e+=4+this.#xr.getUint32(e);e+=4+this.#xr.getUint32(e);const t=this.#xr.getUint32(e);new Uint8Array(this.#Ar,e+4,t).fill(0),this.#xr.setUint32(e,0)}get cssFontInfo(){let e=On.#Mr;e+=4+this.#xr.getUint32(e);e+=4+this.#xr.getUint32(e);const t=this.#xr.getUint32(e);if(0===t)return null;const n=new Uint8Array(t);return n.set(new Uint8Array(this.#Ar,e+4,t)),new Nn(n.buffer)}get systemFontInfo(){let e=On.#Mr;e+=4+this.#xr.getUint32(e);const t=this.#xr.getUint32(e);if(0===t)return null;const n=new Uint8Array(t);return n.set(new Uint8Array(this.#Ar,e+4,t)),new Ln(n.buffer)}static write(e){const t=e.systemFontInfo?Ln.write(e.systemFontInfo):null,n=e.cssFontInfo?Nn.write(e.cssFontInfo):null,r=new TextEncoder,i={};let s=0;for(const f of On.strings)i[f]=r.encode(e[f]),s+=4+i[f].length;const a=On.#Mr+4+s+4+(t?t.byteLength:0)+4+(n?n.byteLength:0)+4+(e.data?e.data.length:0),o=new ArrayBuffer(a),l=new Uint8Array(o),c=new DataView(o);let h=0;const d=On.bools.length;let u=0,p=0;for(let f=0;f<d;f++){const t=e[On.bools[f]];u|=(void 0===t?0:t?2:1)<<p,p+=2,8!==p&&f!==d-1||(c.setUint8(h++,u),u=0,p=0)}V(h===On.#kr,"FontInfo.write: Boolean properties offset mismatch");for(const f of On.numbers)c.setFloat64(h,e[f]),h+=8;if(V(h===On.#Sr,"FontInfo.write: Number properties offset mismatch"),e.bbox){c.setUint8(h++,4);for(const t of e.bbox)c.setInt16(h,t,!0),h+=2}else c.setUint8(h++,0),h+=8;if(V(h===On.#Tr,"FontInfo.write: BBox properties offset mismatch"),e.fontMatrix){c.setUint8(h++,6);for(const t of e.fontMatrix)c.setFloat64(h,t,!0),h+=8}else c.setUint8(h++,0),h+=48;if(V(h===On.#Dr,"FontInfo.write: FontMatrix properties offset mismatch"),e.defaultVMetrics){c.setUint8(h++,1);for(const t of e.defaultVMetrics)c.setInt16(h,t,!0),h+=2}else c.setUint8(h++,0),h+=6;V(h===On.#Mr,"FontInfo.write: DefaultVMetrics properties offset mismatch"),c.setUint32(On.#Mr,0),h+=4;for(const f of On.strings){const e=i[f],t=e.length;c.setUint32(h,t),l.set(e,h+4),h+=4+t}if(c.setUint32(On.#Mr,h-On.#Mr-4),t){const e=t.byteLength;c.setUint32(h,e),V(h+4+e<=o.byteLength,"FontInfo.write: Buffer overflow at systemFontInfo"),l.set(new Uint8Array(t),h+4),h+=4+e}else c.setUint32(h,0),h+=4;if(n){const e=n.byteLength;c.setUint32(h,e),V(h+4+e<=o.byteLength,"FontInfo.write: Buffer overflow at cssFontInfo"),l.set(new Uint8Array(n),h+4),h+=4+e}else c.setUint32(h,0),h+=4;return void 0===e.data?(c.setUint32(h,0),h+=4):(c.setUint32(h,e.data.length),l.set(e.data,h+4),h+=4+e.data.length),V(h<=o.byteLength,"FontInfo.write: Buffer overflow"),o.transferToFixedLength(h)}}class Bn{static#Fr=null;static#Rr="";static get workerPort(){return this.#Fr}static set workerPort(e){if(!("undefined"!==typeof Worker&&e instanceof Worker)&&null!==e)throw new Error("Invalid `workerPort` type.");this.#Fr=e}static get workerSrc(){return this.#Rr}static set workerSrc(e){if("string"!==typeof e)throw new Error("Invalid `workerSrc` type.");this.#Rr=e}}class $n{#Nr;#Lr;constructor(e){let{parsedData:t,rawData:n}=e;this.#Nr=t,this.#Lr=n}getRaw(){return this.#Lr}get(e){return this.#Nr.get(e)??null}[Symbol.iterator](){return this.#Nr.entries()}}const zn=Symbol("INTERNAL");class jn{#Or=!1;#Br=!1;#$r=!1;#zr=!0;constructor(e,t){let{name:n,intent:r,usage:i,rbGroups:s}=t;this.#Or=!!(e&l),this.#Br=!!(e&c),this.name=n,this.intent=r,this.usage=i,this.rbGroups=s}get visible(){if(this.#$r)return this.#zr;if(!this.#zr)return!1;const{print:e,view:t}=this.usage;return this.#Or?"OFF"!==t?.viewState:!this.#Br||"OFF"!==e?.printState}_setVisible(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];e!==zn&&H("Internal method `_setVisible` called."),this.#$r=n,this.#zr=t}}class Un{#jr=null;#Ur=(()=>new Map)();#Hr=null;#Vr=null;constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l;if(this.renderingIntent=t,this.name=null,this.creator=null,null!==e){this.name=e.name,this.creator=e.creator,this.#Vr=e.order;for(const n of e.groups)this.#Ur.set(n.id,new jn(t,n));if("OFF"===e.baseState)for(const e of this.#Ur.values())e._setVisible(zn,!1);for(const t of e.on)this.#Ur.get(t)._setVisible(zn,!0);for(const t of e.off)this.#Ur.get(t)._setVisible(zn,!1);this.#Hr=this.getHash()}}#qr(e){const t=e.length;if(t<2)return!0;const n=e[0];for(let r=1;r<t;r++){const t=e[r];let i;if(Array.isArray(t))i=this.#qr(t);else{if(!this.#Ur.has(t))return U(`Optional content group not found: ${t}`),!0;i=this.#Ur.get(t).visible}switch(n){case"And":if(!i)return!1;break;case"Or":if(i)return!0;break;case"Not":return!i;default:return!0}}return"And"===n}isVisible(e){if(0===this.#Ur.size)return!0;if(!e)return j("Optional content group not defined."),!0;if("OCG"===e.type)return this.#Ur.has(e.id)?this.#Ur.get(e.id).visible:(U(`Optional content group not found: ${e.id}`),!0);if("OCMD"===e.type){if(e.expression)return this.#qr(e.expression);if(!e.policy||"AnyOn"===e.policy){for(const t of e.ids){if(!this.#Ur.has(t))return U(`Optional content group not found: ${t}`),!0;if(this.#Ur.get(t).visible)return!0}return!1}if("AllOn"===e.policy){for(const t of e.ids){if(!this.#Ur.has(t))return U(`Optional content group not found: ${t}`),!0;if(!this.#Ur.get(t).visible)return!1}return!0}if("AnyOff"===e.policy){for(const t of e.ids){if(!this.#Ur.has(t))return U(`Optional content group not found: ${t}`),!0;if(!this.#Ur.get(t).visible)return!0}return!1}if("AllOff"===e.policy){for(const t of e.ids){if(!this.#Ur.has(t))return U(`Optional content group not found: ${t}`),!0;if(this.#Ur.get(t).visible)return!1}return!0}return U(`Unknown optional content policy ${e.policy}.`),!0}return U(`Unknown group type ${e.type}.`),!0}setVisibility(e){let t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];const r=this.#Ur.get(e);if(r){if(n&&t&&r.rbGroups.length)for(const t of r.rbGroups)for(const n of t)n!==e&&this.#Ur.get(n)?._setVisible(zn,!1,!0);r._setVisible(zn,!!t,!0),this.#jr=null}else U(`Optional content group not found: ${e}`)}setOCGState(e){let t,{state:n,preserveRB:r}=e;for(const i of n){switch(i){case"ON":case"OFF":case"Toggle":t=i;continue}const e=this.#Ur.get(i);if(e)switch(t){case"ON":this.setVisibility(i,!0,r);break;case"OFF":this.setVisibility(i,!1,r);break;case"Toggle":this.setVisibility(i,!e.visible,r)}}this.#jr=null}get hasInitialVisibility(){return null===this.#Hr||this.getHash()===this.#Hr}getOrder(){return this.#Ur.size?this.#Vr?this.#Vr.slice():[...this.#Ur.keys()]:null}getGroup(e){return this.#Ur.get(e)||null}getHash(){if(null!==this.#jr)return this.#jr;const e=new nt;for(const[t,n]of this.#Ur)e.update(`${t}:${n.visible}`);return this.#jr=e.hexdigest()}[Symbol.iterator](){return this.#Ur.entries()}}class Hn{constructor(e,t){let{disableRange:n=!1,disableStream:r=!1}=t;V(e,'PDFDataTransportStream - missing required "pdfDataRangeTransport" argument.');const{length:i,initialData:s,progressiveDone:a,contentDispositionFilename:o}=e;if(this._queuedChunks=[],this._progressiveDone=a,this._contentDispositionFilename=o,s?.length>0){const e=s instanceof Uint8Array&&s.byteLength===s.buffer.byteLength?s.buffer:new Uint8Array(s).buffer;this._queuedChunks.push(e)}this._pdfDataRangeTransport=e,this._isStreamingSupported=!r,this._isRangeSupported=!n,this._contentLength=i,this._fullRequestReader=null,this._rangeReaders=[],e.addRangeListener((e,t)=>{this._onReceiveData({begin:e,chunk:t})}),e.addProgressListener((e,t)=>{this._onProgress({loaded:e,total:t})}),e.addProgressiveReadListener(e=>{this._onReceiveData({chunk:e})}),e.addProgressiveDoneListener(()=>{this._onProgressiveDone()}),e.transportReady()}_onReceiveData(e){let{begin:t,chunk:n}=e;const r=n instanceof Uint8Array&&n.byteLength===n.buffer.byteLength?n.buffer:new Uint8Array(n).buffer;if(void 0===t)this._fullRequestReader?this._fullRequestReader._enqueue(r):this._queuedChunks.push(r);else{V(this._rangeReaders.some(function(e){return e._begin===t&&(e._enqueue(r),!0)}),"_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found.")}}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}_onProgress(e){void 0===e.total?this._rangeReaders[0]?.onProgress?.({loaded:e.loaded}):this._fullRequestReader?.onProgress?.({loaded:e.loaded,total:e.total})}_onProgressiveDone(){this._fullRequestReader?.progressiveDone(),this._progressiveDone=!0}_removeRangeReader(e){const t=this._rangeReaders.indexOf(e);t>=0&&this._rangeReaders.splice(t,1)}getFullReader(){V(!this._fullRequestReader,"PDFDataTransportStream.getFullReader can only be called once.");const e=this._queuedChunks;return this._queuedChunks=null,new Vn(this,e,this._progressiveDone,this._contentDispositionFilename)}getRangeReader(e,t){if(t<=this._progressiveDataLength)return null;const n=new qn(this,e,t);return this._pdfDataRangeTransport.requestDataRange(e,t),this._rangeReaders.push(n),n}cancelAllRequests(e){this._fullRequestReader?.cancel(e);for(const t of this._rangeReaders.slice(0))t.cancel(e);this._pdfDataRangeTransport.abort()}}class Vn{constructor(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;this._stream=e,this._done=n||!1,this._filename=we(r)?r:null,this._queuedChunks=t||[],this._loaded=0;for(const i of this._queuedChunks)this._loaded+=i.byteLength;this._requests=[],this._headersReady=Promise.resolve(),e._fullRequestReader=this,this.onProgress=null}_enqueue(e){if(!this._done){if(this._requests.length>0){this._requests.shift().resolve({value:e,done:!1})}else this._queuedChunks.push(e);this._loaded+=e.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 e=Promise.withResolvers();return this._requests.push(e),e.promise}cancel(e){this._done=!0;for(const t of this._requests)t.resolve({value:void 0,done:!0});this._requests.length=0}progressiveDone(){this._done||(this._done=!0)}}class qn{constructor(e,t,n){this._stream=e,this._begin=t,this._end=n,this._queuedChunk=null,this._requests=[],this._done=!1,this.onProgress=null}_enqueue(e){if(!this._done){if(0===this._requests.length)this._queuedChunk=e;else{this._requests.shift().resolve({value:e,done:!1});for(const e of this._requests)e.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 e=this._queuedChunk;return this._queuedChunk=null,{value:e,done:!1}}if(this._done)return{value:void 0,done:!0};const e=Promise.withResolvers();return this._requests.push(e),e.promise}cancel(e){this._done=!0;for(const t of this._requests)t.resolve({value:void 0,done:!0});this._requests.length=0,this._stream._removeRangeReader(this)}}function Wn(e,t){const n=new Headers;if(!e||!t||"object"!==typeof t)return n;for(const r in t){const e=t[r];void 0!==e&&n.append(r,e)}return n}function Gn(e){return URL.parse(e)?.origin??null}function Kn(e){let{responseHeaders:t,isHttp:n,rangeChunkSize:r,disableRange:i}=e;const s={allowRangeRequests:!1,suggestedLength:void 0},a=parseInt(t.get("Content-Length"),10);if(!Number.isInteger(a))return s;if(s.suggestedLength=a,a<=2*r)return s;if(i||!n)return s;if("bytes"!==t.get("Accept-Ranges"))return s;return"identity"!==(t.get("Content-Encoding")||"identity")||(s.allowRangeRequests=!0),s}function Xn(e){const t=e.get("Content-Disposition");if(t){let e=function(e){let t=!0,n=r("filename\\*","i").exec(e);if(n){n=n[1];let e=a(n);return e=unescape(e),e=o(e),e=l(e),s(e)}if(n=function(e){const t=[];let n;const i=r("filename\\*((?!0\\d)\\d+)(\\*?)","ig");for(;null!==(n=i.exec(e));){let[,e,r,i]=n;if(e=parseInt(e,10),e in t){if(0===e)break}else t[e]=[r,i]}const s=[];for(let r=0;r<t.length&&r in t;++r){let[e,n]=t[r];n=a(n),e&&(n=unescape(n),0===r&&(n=o(n))),s.push(n)}return s.join("")}(e),n)return s(l(n));if(n=r("filename","i").exec(e),n){n=n[1];let e=a(n);return e=l(e),s(e)}function r(e,t){return new RegExp("(?:^|;)\\s*"+e+'\\s*=\\s*([^";\\s][^;\\s]*|"(?:[^"\\\\]|\\\\"?)+"?)',t)}function i(e,n){if(e){if(!/^[\x00-\xFF]+$/.test(n))return n;try{const r=new TextDecoder(e,{fatal:!0}),i=ne(n);n=r.decode(i),t=!1}catch{}}return n}function s(e){return t&&/[\x80-\xff]/.test(e)&&(e=i("utf-8",e),t&&(e=i("iso-8859-1",e))),e}function a(e){if(e.startsWith('"')){const t=e.slice(1).split('\\"');for(let e=0;e<t.length;++e){const n=t[e].indexOf('"');-1!==n&&(t[e]=t[e].slice(0,n),t.length=e+1),t[e]=t[e].replaceAll(/\\(.)/g,"$1")}e=t.join('"')}return e}function o(e){const t=e.indexOf("'");return-1===t?e:i(e.slice(0,t),e.slice(t+1).replace(/^[^']*'/,""))}function l(e){return!e.startsWith("=?")||/[\x00-\x19\x80-\xff]/.test(e)?e:e.replaceAll(/=\?([\w-]*)\?([QqBb])\?((?:[^?]|\?(?!=))*)\?=/g,function(e,t,n,r){if("q"===n||"Q"===n)return i(t,r=(r=r.replaceAll("_"," ")).replaceAll(/=([0-9a-fA-F]{2})/g,function(e,t){return String.fromCharCode(parseInt(t,16))}));try{r=atob(r)}catch{}return i(t,r)})}return""}(t);if(e.includes("%"))try{e=decodeURIComponent(e)}catch{}if(we(e))return e}return null}function Yn(e,t){return new J(`Unexpected server response (${e}) while retrieving PDF "${t}".`,e,404===e||0===e&&t.startsWith("file:"))}function Zn(e){return 200===e||206===e}function Jn(e,t,n){return{method:"GET",headers:e,signal:n.signal,mode:"cors",credentials:t?"include":"same-origin",redirect:"follow"}}function Qn(e){return e instanceof Uint8Array?e.buffer:e instanceof ArrayBuffer?e:(U(`getArrayBuffer - unexpected data format: ${e}`),new Uint8Array(e).buffer)}class er{_responseOrigin=null;constructor(e){this.source=e,this.isHttp=/^https?:/i.test(e.url),this.headers=Wn(this.isHttp,e.httpHeaders),this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}getFullReader(){return V(!this._fullRequestReader,"PDFFetchStream.getFullReader can only be called once."),this._fullRequestReader=new tr(this),this._fullRequestReader}getRangeReader(e,t){if(t<=this._progressiveDataLength)return null;const n=new nr(this,e,t);return this._rangeRequestReaders.push(n),n}cancelAllRequests(e){this._fullRequestReader?.cancel(e);for(const t of this._rangeRequestReaders.slice(0))t.cancel(e)}}class tr{constructor(e){this._stream=e,this._reader=null,this._loaded=0,this._filename=null;const t=e.source;this._withCredentials=t.withCredentials||!1,this._contentLength=t.length,this._headersCapability=Promise.withResolvers(),this._disableRange=t.disableRange||!1,this._rangeChunkSize=t.rangeChunkSize,this._rangeChunkSize||this._disableRange||(this._disableRange=!0),this._abortController=new AbortController,this._isStreamingSupported=!t.disableStream,this._isRangeSupported=!t.disableRange;const n=new Headers(e.headers),r=t.url;fetch(r,Jn(n,this._withCredentials,this._abortController)).then(t=>{if(e._responseOrigin=Gn(t.url),!Zn(t.status))throw Yn(t.status,r);this._reader=t.body.getReader(),this._headersCapability.resolve();const n=t.headers,{allowRangeRequests:i,suggestedLength:s}=Kn({responseHeaders:n,isHttp:e.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=i,this._contentLength=s||this._contentLength,this._filename=Xn(n),!this._isStreamingSupported&&this._isRangeSupported&&this.cancel(new ee("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(){await this._headersCapability.promise;const{value:e,done:t}=await this._reader.read();return t?{value:e,done:t}:(this._loaded+=e.byteLength,this.onProgress?.({loaded:this._loaded,total:this._contentLength}),{value:Qn(e),done:!1})}cancel(e){this._reader?.cancel(e),this._abortController.abort()}}class nr{constructor(e,t,n){this._stream=e,this._reader=null,this._loaded=0;const r=e.source;this._withCredentials=r.withCredentials||!1,this._readCapability=Promise.withResolvers(),this._isStreamingSupported=!r.disableStream,this._abortController=new AbortController;const i=new Headers(e.headers);i.append("Range",`bytes=${t}-${n-1}`);const s=r.url;fetch(s,Jn(i,this._withCredentials,this._abortController)).then(t=>{const n=Gn(t.url);if(n!==e._responseOrigin)throw new Error(`Expected range response-origin "${n}" to match "${e._responseOrigin}".`);if(!Zn(t.status))throw Yn(t.status,s);this._readCapability.resolve(),this._reader=t.body.getReader()}).catch(this._readCapability.reject),this.onProgress=null}get isStreamingSupported(){return this._isStreamingSupported}async read(){await this._readCapability.promise;const{value:e,done:t}=await this._reader.read();return t?{value:e,done:t}:(this._loaded+=e.byteLength,this.onProgress?.({loaded:this._loaded}),{value:Qn(e),done:!1})}cancel(e){this._reader?.cancel(e),this._abortController.abort()}}class rr{_responseOrigin=null;constructor(e){let{url:t,httpHeaders:n,withCredentials:r}=e;this.url=t,this.isHttp=/^https?:/i.test(t),this.headers=Wn(this.isHttp,n),this.withCredentials=r||!1,this.currXhrId=0,this.pendingRequests=Object.create(null)}request(e){const t=new XMLHttpRequest,n=this.currXhrId++,r=this.pendingRequests[n]={xhr:t};t.open("GET",this.url),t.withCredentials=this.withCredentials;for(const[i,s]of this.headers)t.setRequestHeader(i,s);return this.isHttp&&"begin"in e&&"end"in e?(t.setRequestHeader("Range",`bytes=${e.begin}-${e.end-1}`),r.expectedStatus=206):r.expectedStatus=200,t.responseType="arraybuffer",V(e.onError,"Expected `onError` callback to be provided."),t.onerror=()=>{e.onError(t.status)},t.onreadystatechange=this.onStateChange.bind(this,n),t.onprogress=this.onProgress.bind(this,n),r.onHeadersReceived=e.onHeadersReceived,r.onDone=e.onDone,r.onError=e.onError,r.onProgress=e.onProgress,t.send(null),n}onProgress(e,t){const n=this.pendingRequests[e];n&&n.onProgress?.(t)}onStateChange(e,t){const n=this.pendingRequests[e];if(!n)return;const r=n.xhr;if(r.readyState>=2&&n.onHeadersReceived&&(n.onHeadersReceived(),delete n.onHeadersReceived),4!==r.readyState)return;if(!(e in this.pendingRequests))return;if(delete this.pendingRequests[e],0===r.status&&this.isHttp)return void n.onError(r.status);const i=r.status||200;if(!(200===i&&206===n.expectedStatus)&&i!==n.expectedStatus)return void n.onError(r.status);const s=function(e){const t=e.response;return"string"!==typeof t?t:ne(t).buffer}(r);if(206===i){const e=r.getResponseHeader("Content-Range"),t=/bytes (\d+)-(\d+)\/(\d+)/.exec(e);t?n.onDone({begin:parseInt(t[1],10),chunk:s}):(U('Missing or invalid "Content-Range" header.'),n.onError(0))}else s?n.onDone({begin:0,chunk:s}):n.onError(r.status)}getRequestXhr(e){return this.pendingRequests[e].xhr}isPendingRequest(e){return e in this.pendingRequests}abortRequest(e){const t=this.pendingRequests[e].xhr;delete this.pendingRequests[e],t.abort()}}class ir{constructor(e){this._source=e,this._manager=new rr(e),this._rangeChunkSize=e.rangeChunkSize,this._fullRequestReader=null,this._rangeRequestReaders=[]}_onRangeRequestReaderClosed(e){const t=this._rangeRequestReaders.indexOf(e);t>=0&&this._rangeRequestReaders.splice(t,1)}getFullReader(){return V(!this._fullRequestReader,"PDFNetworkStream.getFullReader can only be called once."),this._fullRequestReader=new sr(this._manager,this._source),this._fullRequestReader}getRangeReader(e,t){const n=new ar(this._manager,e,t);return n.onClosed=this._onRangeRequestReaderClosed.bind(this),this._rangeRequestReaders.push(n),n}cancelAllRequests(e){this._fullRequestReader?.cancel(e);for(const t of this._rangeRequestReaders.slice(0))t.cancel(e)}}class sr{constructor(e,t){this._manager=e,this._url=t.url,this._fullRequestId=e.request({onHeadersReceived:this._onHeadersReceived.bind(this),onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)}),this._headersCapability=Promise.withResolvers(),this._disableRange=t.disableRange||!1,this._contentLength=t.length,this._rangeChunkSize=t.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 e=this._fullRequestId,t=this._manager.getRequestXhr(e);this._manager._responseOrigin=Gn(t.responseURL);const n=t.getAllResponseHeaders(),r=new Headers(n?n.trimStart().replace(/[^\S ]+$/,"").split(/[\r\n]+/).map(e=>{const[t,...n]=e.split(": ");return[t,n.join(": ")]}):[]),{allowRangeRequests:i,suggestedLength:s}=Kn({responseHeaders:r,isHttp:this._manager.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});i&&(this._isRangeSupported=!0),this._contentLength=s||this._contentLength,this._filename=Xn(r),this._isRangeSupported&&this._manager.abortRequest(e),this._headersCapability.resolve()}_onDone(e){if(e)if(this._requests.length>0){this._requests.shift().resolve({value:e.chunk,done:!1})}else this._cachedChunks.push(e.chunk);if(this._done=!0,!(this._cachedChunks.length>0)){for(const e of this._requests)e.resolve({value:void 0,done:!0});this._requests.length=0}}_onError(e){this._storedError=Yn(e,this._url),this._headersCapability.reject(this._storedError);for(const t of this._requests)t.reject(this._storedError);this._requests.length=0,this._cachedChunks.length=0}_onProgress(e){this.onProgress?.({loaded:e.loaded,total:e.lengthComputable?e.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._headersCapability.promise}async read(){if(await this._headersCapability.promise,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 e=Promise.withResolvers();return this._requests.push(e),e.promise}cancel(e){this._done=!0,this._headersCapability.reject(e);for(const t of this._requests)t.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._fullRequestId)&&this._manager.abortRequest(this._fullRequestId),this._fullRequestReader=null}}class ar{constructor(e,t,n){this._manager=e,this._url=e.url,this._requestId=e.request({begin:t,end:n,onHeadersReceived:this._onHeadersReceived.bind(this),onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)}),this._requests=[],this._queuedChunk=null,this._done=!1,this._storedError=void 0,this.onProgress=null,this.onClosed=null}_onHeadersReceived(){const e=Gn(this._manager.getRequestXhr(this._requestId)?.responseURL);e!==this._manager._responseOrigin&&(this._storedError=new Error(`Expected range response-origin "${e}" to match "${this._manager._responseOrigin}".`),this._onError(0))}_close(){this.onClosed?.(this)}_onDone(e){const t=e.chunk;if(this._requests.length>0){this._requests.shift().resolve({value:t,done:!1})}else this._queuedChunk=t;this._done=!0;for(const n of this._requests)n.resolve({value:void 0,done:!0});this._requests.length=0,this._close()}_onError(e){this._storedError??=Yn(e,this._url);for(const t of this._requests)t.reject(this._storedError);this._requests.length=0,this._queuedChunk=null}_onProgress(e){this.isStreamingSupported||this.onProgress?.({loaded:e.loaded})}get isStreamingSupported(){return!1}async read(){if(this._storedError)throw this._storedError;if(null!==this._queuedChunk){const e=this._queuedChunk;return this._queuedChunk=null,{value:e,done:!1}}if(this._done)return{value:void 0,done:!0};const e=Promise.withResolvers();return this._requests.push(e),e.promise}cancel(e){this._done=!0;for(const t of this._requests)t.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._requestId)&&this._manager.abortRequest(this._requestId),this._close()}}const or=/^[a-z][a-z0-9\-+.]+:/i;class lr{constructor(e){this.source=e,this.url=function(e){if(or.test(e))return new URL(e);const t=process.getBuiltinModule("url");return new URL(t.pathToFileURL(e))}(e.url),V("file:"===this.url.protocol,"PDFNodeStream only supports file:// URLs."),this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}getFullReader(){return V(!this._fullRequestReader,"PDFNodeStream.getFullReader can only be called once."),this._fullRequestReader=new cr(this),this._fullRequestReader}getRangeReader(e,t){if(t<=this._progressiveDataLength)return null;const n=new hr(this,e,t);return this._rangeRequestReaders.push(n),n}cancelAllRequests(e){this._fullRequestReader?.cancel(e);for(const t of this._rangeRequestReaders.slice(0))t.cancel(e)}}class cr{constructor(e){this._url=e.url,this._done=!1,this._storedError=null,this.onProgress=null;const t=e.source;this._contentLength=t.length,this._loaded=0,this._filename=null,this._disableRange=t.disableRange||!1,this._rangeChunkSize=t.rangeChunkSize,this._rangeChunkSize||this._disableRange||(this._disableRange=!0),this._isStreamingSupported=!t.disableStream,this._isRangeSupported=!t.disableRange,this._readableStream=null,this._readCapability=Promise.withResolvers(),this._headersCapability=Promise.withResolvers();const n=process.getBuiltinModule("fs");n.promises.lstat(this._url).then(e=>{this._contentLength=e.size,this._setReadableStream(n.createReadStream(this._url)),this._headersCapability.resolve()},e=>{"ENOENT"===e.code&&(e=Yn(0,this._url.href)),this._storedError=e,this._headersCapability.reject(e)})}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(){if(await this._readCapability.promise,this._done)return{value:void 0,done:!0};if(this._storedError)throw this._storedError;const e=this._readableStream.read();if(null===e)return this._readCapability=Promise.withResolvers(),this.read();this._loaded+=e.length,this.onProgress?.({loaded:this._loaded,total:this._contentLength});return{value:new Uint8Array(e).buffer,done:!1}}cancel(e){this._readableStream?this._readableStream.destroy(e):this._error(e)}_error(e){this._storedError=e,this._readCapability.resolve()}_setReadableStream(e){this._readableStream=e,e.on("readable",()=>{this._readCapability.resolve()}),e.on("end",()=>{e.destroy(),this._done=!0,this._readCapability.resolve()}),e.on("error",e=>{this._error(e)}),!this._isStreamingSupported&&this._isRangeSupported&&this._error(new ee("streaming is disabled")),this._storedError&&this._readableStream.destroy(this._storedError)}}class hr{constructor(e,t,n){this._url=e.url,this._done=!1,this._storedError=null,this.onProgress=null,this._loaded=0,this._readableStream=null,this._readCapability=Promise.withResolvers();const r=e.source;this._isStreamingSupported=!r.disableStream;const i=process.getBuiltinModule("fs");this._setReadableStream(i.createReadStream(this._url,{start:t,end:n-1}))}get isStreamingSupported(){return this._isStreamingSupported}async read(){if(await this._readCapability.promise,this._done)return{value:void 0,done:!0};if(this._storedError)throw this._storedError;const e=this._readableStream.read();if(null===e)return this._readCapability=Promise.withResolvers(),this.read();this._loaded+=e.length,this.onProgress?.({loaded:this._loaded});return{value:new Uint8Array(e).buffer,done:!1}}cancel(e){this._readableStream?this._readableStream.destroy(e):this._error(e)}_error(e){this._storedError=e,this._readCapability.resolve()}_setReadableStream(e){this._readableStream=e,e.on("readable",()=>{this._readCapability.resolve()}),e.on("end",()=>{e.destroy(),this._done=!0,this._readCapability.resolve()}),e.on("error",e=>{this._error(e)}),this._storedError&&this._readableStream.destroy(this._storedError)}}const dr=Symbol("INITIAL_DATA");class ur{#Wr=(()=>Object.create(null))();#Gr(e){return this.#Wr[e]||={...Promise.withResolvers(),data:dr}}get(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(t){const n=this.#Gr(e);return n.promise.then(()=>t(n.data)),null}const n=this.#Wr[e];if(!n||n.data===dr)throw new Error(`Requesting object that isn't resolved yet ${e}.`);return n.data}has(e){const t=this.#Wr[e];return!!t&&t.data!==dr}delete(e){const t=this.#Wr[e];return!(!t||t.data===dr)&&(delete this.#Wr[e],!0)}resolve(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;const n=this.#Gr(e);n.data=t,n.resolve()}clear(){for(const e in this.#Wr){const{data:t}=this.#Wr[e];t?.bitmap?.close()}this.#Wr=Object.create(null)}*[Symbol.iterator](){for(const e in this.#Wr){const{data:t}=this.#Wr[e];t!==dr&&(yield[e,t])}}}class pr{#Kr=(()=>Promise.withResolvers())();#_e=null;#Xr=!1;#Yr=(()=>!!globalThis.FontInspector?.enabled)();#Zr=null;#Jr=null;#Qr=0;#ei=0;#ti=null;#ni=null;#ri=0;#ii=0;#si=(()=>Object.create(null))();#ai=[];#oi=null;#li=[];#ci=(()=>new WeakMap)();#hi=null;static#di=(()=>new Map)();static#ui=(()=>new Map)();static#pi=(()=>new WeakMap)();static#fi=null;static#mi=(()=>new Set)();constructor(e){let{textContentSource:t,container:n,viewport:r}=e;if(t instanceof ReadableStream)this.#oi=t;else{if("object"!==typeof t)throw new Error('No "textContentSource" parameter specified.');this.#oi=new ReadableStream({start(e){e.enqueue(t),e.close()}})}this.#_e=this.#ni=n,this.#ii=r.scale*Me.pixelRatio,this.#ri=r.rotation,this.#Jr={div:null,properties:null,ctx:null};const{pageWidth:i,pageHeight:s,pageX:a,pageY:o}=r.rawDims;this.#hi=[1,0,0,-1,-a,o+s],this.#ei=i,this.#Qr=s,pr.#gi(),De(n,r),this.#Kr.promise.finally(()=>{pr.#mi.delete(this),this.#Jr=null,this.#si=null}).catch(()=>{})}static get fontFamilyMap(){const{isWindows:e,isFirefox:t}=re.platform;return G(this,"fontFamilyMap",new Map([["sans-serif",(e&&t?"Calibri, ":"")+"sans-serif"],["monospace",(e&&t?"Lucida Console, ":"")+"monospace"]]))}render(){const e=()=>{this.#ti.read().then(t=>{let{value:n,done:r}=t;r?this.#Kr.resolve():(this.#Zr??=n.lang,Object.assign(this.#si,n.styles),this.#vi(n.items),e())},this.#Kr.reject)};return this.#ti=this.#oi.getReader(),pr.#mi.add(this),e(),this.#Kr.promise}update(e){let{viewport:t,onBefore:n=null}=e;const r=t.scale*Me.pixelRatio,i=t.rotation;if(i!==this.#ri&&(n?.(),this.#ri=i,De(this.#ni,{rotation:i})),r!==this.#ii){n?.(),this.#ii=r;const e={div:null,properties:null,ctx:pr.#yi(this.#Zr)};for(const t of this.#li)e.properties=this.#ci.get(t),e.div=t,this.#bi(e)}}cancel(){const e=new ee("TextLayer task cancelled.");this.#ti?.cancel(e).catch(()=>{}),this.#ti=null,this.#Kr.reject(e)}get textDivs(){return this.#li}get textContentItemsStr(){return this.#ai}#vi(e){if(this.#Xr)return;this.#Jr.ctx??=pr.#yi(this.#Zr);const t=this.#li,n=this.#ai;for(const r of e){if(t.length>1e5)return U("Ignoring additional textDivs for performance reasons."),void(this.#Xr=!0);if(void 0!==r.str)n.push(r.str),this.#wi(r);else if("beginMarkedContentProps"===r.type||"beginMarkedContent"===r.type){const e=this.#_e;this.#_e=document.createElement("span"),this.#_e.classList.add("markedContent"),r.id&&this.#_e.setAttribute("id",`${r.id}`),e.append(this.#_e)}else"endMarkedContent"===r.type&&(this.#_e=this.#_e.parentNode)}}#wi(e){const t=document.createElement("span"),n={angle:0,canvasWidth:0,hasText:""!==e.str,hasEOL:e.hasEOL,fontSize:0};this.#li.push(t);const r=se.transform(this.#hi,e.transform);let i=Math.atan2(r[1],r[0]);const s=this.#si[e.fontName];s.vertical&&(i+=Math.PI/2);let a=this.#Yr&&s.fontSubstitution||s.fontFamily;a=pr.fontFamilyMap.get(a)||a;const o=Math.hypot(r[2],r[3]),l=o*pr.#_i(a,s,this.#Zr);let c,h;0===i?(c=r[4],h=r[5]-l):(c=r[4]+l*Math.sin(i),h=r[5]-l*Math.cos(i));const d="calc(var(--total-scale-factor) *",u=t.style;this.#_e===this.#ni?(u.left=`${(100*c/this.#ei).toFixed(2)}%`,u.top=`${(100*h/this.#Qr).toFixed(2)}%`):(u.left=`${d}${c.toFixed(2)}px)`,u.top=`${d}${h.toFixed(2)}px)`),u.fontSize=`${d}${(pr.#fi*o).toFixed(2)}px)`,u.fontFamily=a,n.fontSize=o,t.setAttribute("role","presentation"),t.textContent=e.str,t.dir=e.dir,this.#Yr&&(t.dataset.fontName=s.fontSubstitutionLoadedName||e.fontName),0!==i&&(n.angle=i*(180/Math.PI));let p=!1;if(e.str.length>1)p=!0;else if(" "!==e.str&&e.transform[0]!==e.transform[3]){const t=Math.abs(e.transform[0]),n=Math.abs(e.transform[3]);t!==n&&Math.max(t,n)/Math.min(t,n)>1.5&&(p=!0)}if(p&&(n.canvasWidth=s.vertical?e.height:e.width),this.#ci.set(t,n),this.#Jr.div=t,this.#Jr.properties=n,this.#bi(this.#Jr),n.hasText&&this.#_e.append(t),n.hasEOL){const e=document.createElement("br");e.setAttribute("role","presentation"),this.#_e.append(e)}}#bi(e){const{div:t,properties:n,ctx:r}=e,{style:i}=t;let s="";if(pr.#fi>1&&(s=`scale(${1/pr.#fi})`),0!==n.canvasWidth&&n.hasText){const{fontFamily:e}=i,{canvasWidth:a,fontSize:o}=n;pr.#Ai(r,o*this.#ii,e);const{width:l}=r.measureText(t.textContent);l>0&&(s=`scaleX(${a*this.#ii/l}) ${s}`)}0!==n.angle&&(s=`rotate(${n.angle}deg) ${s}`),s.length>0&&(i.transform=s)}static cleanup(){if(!(this.#mi.size>0)){this.#di.clear();for(const{canvas:e}of this.#ui.values())e.remove();this.#ui.clear()}}static#yi(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=this.#ui.get(e||="");if(!t){const n=document.createElement("canvas");n.className="hiddenCanvasElement",n.lang=e,document.body.append(n),t=n.getContext("2d",{alpha:!1,willReadFrequently:!0}),this.#ui.set(e,t),this.#pi.set(t,{size:0,family:""})}return t}static#Ai(e,t,n){const r=this.#pi.get(e);t===r.size&&n===r.family||(e.font=`${t}px ${n}`,r.size=t,r.family=n)}static#gi(){if(null!==this.#fi)return;const e=document.createElement("div");e.style.opacity=0,e.style.lineHeight=1,e.style.fontSize="1px",e.style.position="absolute",e.textContent="X",document.body.append(e),this.#fi=e.getBoundingClientRect().height,e.remove()}static#_i(e,t,n){const r=this.#di.get(e);if(r)return r;const i=this.#yi(n);i.canvas.width=i.canvas.height=30,this.#Ai(i,30,e);const s=i.measureText(""),a=s.fontBoundingBoxAscent,o=Math.abs(s.fontBoundingBoxDescent);i.canvas.width=i.canvas.height=0;let l=.8;return a?l=a/(a+o):(re.platform.isFirefox&&U("Enable the `dom.textMetrics.fontBoundingBox.enabled` preference in `about:config` to improve TextLayer rendering."),t.ascent?l=t.ascent:t.descent&&(l=1+t.descent)),this.#di.set(e,l),l}}function fr(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};"string"===typeof e||e instanceof URL?e={url:e}:(e instanceof ArrayBuffer||ArrayBuffer.isView(e))&&(e={data:e});const t=new mr,{docId:n}=t,r=e.url?function(e){if(e instanceof URL)return e.href;if("string"===typeof e){if(i)return e;const t=URL.parse(e,window.location);if(t)return t.href}throw new Error("Invalid PDF url data: either string or URL-object is expected in the url property.")}(e.url):null,s=e.data?function(e){if(i&&"undefined"!==typeof Buffer&&e instanceof Buffer)throw new Error("Please provide binary data as `Uint8Array`, rather than `Buffer`.");if(e instanceof Uint8Array&&e.byteLength===e.buffer.byteLength)return e;if("string"===typeof e)return ne(e);if(e instanceof ArrayBuffer||ArrayBuffer.isView(e)||"object"===typeof e&&!isNaN(e?.length))return new Uint8Array(e);throw new Error("Invalid PDF binary data: either TypedArray, string, or array-like object is expected in the data property.")}(e.data):null,a=e.httpHeaders||null,o=!0===e.withCredentials,l=e.password??null,c=e.range instanceof gr?e.range:null,h=Number.isInteger(e.rangeChunkSize)&&e.rangeChunkSize>0?e.rangeChunkSize:65536;let d=e.worker instanceof br?e.worker:null;const u=e.verbosity,p="string"!==typeof e.docBaseUrl||be(e.docBaseUrl)?null:e.docBaseUrl,f=lt(e.cMapUrl),m=!1!==e.cMapPacked,g=e.CMapReaderFactory||(i?Bt:Tt),v=lt(e.iccUrl),y=lt(e.standardFontDataUrl),b=e.StandardFontDataFactory||(i?$t:It),w=lt(e.wasmUrl),_=e.WasmFactory||(i?zt:Rt),A=!0!==e.stopAtErrors,x=Number.isInteger(e.maxImageSize)&&e.maxImageSize>-1?e.maxImageSize:-1,E=!1!==e.isEvalSupported,C="boolean"===typeof e.isOffscreenCanvasSupported?e.isOffscreenCanvasSupported:!i,k="boolean"===typeof e.isImageDecoderSupported?e.isImageDecoderSupported:!i&&(re.platform.isFirefox||!globalThis.chrome),S=Number.isInteger(e.canvasMaxAreaInBytes)?e.canvasMaxAreaInBytes:-1,T="boolean"===typeof e.disableFontFace?e.disableFontFace:i,D=!0===e.fontExtraProperties,M=!0===e.enableXfa,P=e.ownerDocument||globalThis.document,I=!0===e.disableRange,F=!0===e.disableStream,R=!0===e.disableAutoFetch,N=!0===e.pdfBug,L=e.CanvasFactory||(i?Ot:kt),O=e.FilterFactory||(i?Lt:Mt),B=!0===e.enableHWA,z=!1!==e.useWasm,j=c?c.length:e.length??NaN,U="boolean"===typeof e.useSystemFonts?e.useSystemFonts:!i&&!T,H="boolean"===typeof e.useWorkerFetch?e.useWorkerFetch:!!(g===Tt&&b===It&&_===Rt&&f&&y&&w&&Ae(f,document.baseURI)&&Ae(y,document.baseURI)&&Ae(w,document.baseURI));$(u);const V={canvasFactory:new L({ownerDocument:P,enableHWA:B}),filterFactory:new O({docId:n,ownerDocument:P}),cMapReaderFactory:H?null:new g({baseUrl:f,isCompressed:m}),standardFontDataFactory:H?null:new b({baseUrl:y}),wasmFactory:H?null:new _({baseUrl:w})};d||(d=br.create({verbosity:u,port:Bn.workerPort}),t._worker=d);const q={docId:n,apiVersion:"5.4.296",data:s,password:l,disableAutoFetch:R,rangeChunkSize:h,length:j,docBaseUrl:p,enableXfa:M,evaluatorOptions:{maxImageSize:x,disableFontFace:T,ignoreErrors:A,isEvalSupported:E,isOffscreenCanvasSupported:C,isImageDecoderSupported:k,canvasMaxAreaInBytes:S,fontExtraProperties:D,useSystemFonts:U,useWasm:z,useWorkerFetch:H,cMapUrl:f,iccUrl:v,standardFontDataUrl:y,wasmUrl:w}},W={ownerDocument:P,pdfBug:N,styleElement:null,loadingParams:{disableAutoFetch:R,enableXfa:M}};return d.promise.then(function(){if(t.destroyed)throw new Error("Loading aborted");if(d.destroyed)throw new Error("Worker was destroyed");const e=d.messageHandler.sendWithPromise("GetDocRequest",q,s?[s.buffer]:null);let l;if(c)l=new Hn(c,{disableRange:I,disableStream:F});else if(!s){if(!r)throw new Error("getDocument - no `url` parameter provided.");const e=Ae(r)?er:i?lr:ir;l=new e({url:r,length:j,httpHeaders:a,withCredentials:o,rangeChunkSize:h,disableRange:I,disableStream:F})}return e.then(e=>{if(t.destroyed)throw new Error("Loading aborted");if(d.destroyed)throw new Error("Worker was destroyed");const r=new Et(n,e,d.port),i=new wr(r,t,l,W,V,B);t._transport=i,r.send("Ready",null)})}).catch(t._capability.reject),t}class mr{static#Nn=0;_capability=(()=>Promise.withResolvers())();_transport=null;_worker=null;docId=(()=>"d"+mr.#Nn++)();destroyed=!1;onPassword=null;onProgress=null;get promise(){return this._capability.promise}async destroy(){this.destroyed=!0;try{this._worker?.port&&(this._worker._pendingDestroy=!0),await(this._transport?.destroy())}catch(e){throw this._worker?.port&&delete this._worker._pendingDestroy,e}this._transport=null,this._worker?.destroy(),this._worker=null}async getData(){return this._transport.getData()}}class gr{#Kr=(()=>Promise.withResolvers())();#xi=[];#Ei=[];#Ci=[];#ki=[];constructor(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;this.length=e,this.initialData=t,this.progressiveDone=n,this.contentDispositionFilename=r}addRangeListener(e){this.#ki.push(e)}addProgressListener(e){this.#Ci.push(e)}addProgressiveReadListener(e){this.#Ei.push(e)}addProgressiveDoneListener(e){this.#xi.push(e)}onDataRange(e,t){for(const n of this.#ki)n(e,t)}onDataProgress(e,t){this.#Kr.promise.then(()=>{for(const n of this.#Ci)n(e,t)})}onDataProgressiveRead(e){this.#Kr.promise.then(()=>{for(const t of this.#Ei)t(e)})}onDataProgressiveDone(){this.#Kr.promise.then(()=>{for(const e of this.#xi)e()})}transportReady(){this.#Kr.resolve()}requestDataRange(e,t){H("Abstract method PDFDataRangeTransport.requestDataRange")}abort(){}}class vr{constructor(e,t){this._pdfInfo=e,this._transport=t}get annotationStorage(){return this._transport.annotationStorage}get canvasFactory(){return this._transport.canvasFactory}get filterFactory(){return this._transport.filterFactory}get numPages(){return this._pdfInfo.numPages}get fingerprints(){return this._pdfInfo.fingerprints}get isPureXfa(){return G(this,"isPureXfa",!!this._transport._htmlForXfa)}get allXfaHtml(){return this._transport._htmlForXfa}getPage(e){return this._transport.getPage(e)}getPageIndex(e){return this._transport.getPageIndex(e)}getDestinations(){return this._transport.getDestinations()}getDestination(e){return this._transport.getDestination(e)}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()}getAnnotationsByType(e,t){return this._transport.getAnnotationsByType(e,t)}getJSActions(){return this._transport.getDocJSActions()}getOutline(){return this._transport.getOutline()}getOptionalContentConfig(){let{intent:e="display"}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{renderingIntent:t}=this._transport.getRenderingIntent(e);return this._transport.getOptionalContentConfig(t)}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(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this._transport.startCleanup(e||this.isPureXfa)}destroy(){return this.loadingTask.destroy()}cachedPageNumber(e){return this._transport.cachedPageNumber(e)}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()}}class yr{#Si=!1;constructor(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];this._pageIndex=e,this._pageInfo=t,this._transport=n,this._stats=r?new _e:null,this._pdfBug=r,this.commonObjs=n.commonObjs,this.objs=new ur,this._intentStates=new Map,this.destroyed=!1,this.recordedBBoxes=null}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(){let{scale:e,rotation:t=this.rotate,offsetX:n=0,offsetY:r=0,dontFlip:i=!1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return new ve({viewBox:this.view,userUnit:this.userUnit,scale:e,rotation:t,offsetX:n,offsetY:r,dontFlip:i})}getAnnotations(){let{intent:e="display"}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{renderingIntent:t}=this._transport.getRenderingIntent(e);return this._transport.getAnnotations(this._pageIndex,t)}getJSActions(){return this._transport.getPageJSActions(this._pageIndex)}get filterFactory(){return this._transport.filterFactory}get isPureXfa(){return G(this,"isPureXfa",!!this._transport._htmlForXfa)}async getXfa(){return this._transport._htmlForXfa?.children[this._pageIndex]||null}render(e){let{canvasContext:t,canvas:n=t.canvas,viewport:r,intent:i="display",annotationMode:s=m.ENABLE,transform:a=null,background:o=null,optionalContentConfigPromise:l=null,annotationCanvasMap:h=null,pageColors:d=null,printAnnotationStorage:u=null,isEditing:p=!1,recordOperations:f=!1,operationsFilter:g=null}=e;this._stats?.time("Overall");const v=this._transport.getRenderingIntent(i,s,u,p),{renderingIntent:y,cacheKey:b}=v;this.#Si=!1,l||=this._transport.getOptionalContentConfig(y);let w=this._intentStates.get(b);w||(w=Object.create(null),this._intentStates.set(b,w)),w.streamReaderCancelTimeout&&(clearTimeout(w.streamReaderCancelTimeout),w.streamReaderCancelTimeout=null);const _=!!(y&c);w.displayReadyCapability||(w.displayReadyCapability=Promise.withResolvers(),w.operatorList={fnArray:[],argsArray:[],lastChunk:!1,separateAnnots:null},this._stats?.time("Page Request"),this._pumpOperatorList(v));const A=Boolean(this._pdfBug&&globalThis.StepperManager?.enabled),x=!this.recordedBBoxes&&(f||A),E=e=>{if(w.renderTasks.delete(C),x){const e=C.gfx?.dependencyTracker.take();e&&(C.stepper&&C.stepper.setOperatorBBoxes(e,C.gfx.dependencyTracker.takeDebugMetadata()),f&&(this.recordedBBoxes=e))}_&&(this.#Si=!0),this.#Ti(),e?(C.capability.reject(e),this._abortOperatorList({intentState:w,reason:e instanceof Error?e:new Error(e)})):C.capability.resolve(),this._stats&&(this._stats.timeEnd("Rendering"),this._stats.timeEnd("Overall"),globalThis.Stats?.enabled&&globalThis.Stats.add(this.pageNumber,this._stats))},C=new Ar({callback:E,params:{canvas:n,canvasContext:t,dependencyTracker:x?new Kt(n,w.operatorList.length,A):null,viewport:r,transform:a,background:o},objs:this.objs,commonObjs:this.commonObjs,annotationCanvasMap:h,operatorList:w.operatorList,pageIndex:this._pageIndex,canvasFactory:this._transport.canvasFactory,filterFactory:this._transport.filterFactory,useRequestAnimationFrame:!_,pdfBug:this._pdfBug,pageColors:d,enableHWA:this._transport.enableHWA,operationsFilter:g});(w.renderTasks||=new Set).add(C);const k=C.task;return Promise.all([w.displayReadyCapability.promise,l]).then(e=>{let[t,n]=e;if(this.destroyed)E();else{if(this._stats?.time("Rendering"),!(n.renderingIntent&y))throw new Error("Must use the same `intent`-argument when calling the `PDFPageProxy.render` and `PDFDocumentProxy.getOptionalContentConfig` methods.");C.initializeGraphics({transparency:t,optionalContentConfig:n}),C.operatorListChanged()}}).catch(E),k}getOperatorList(){let{intent:e="display",annotationMode:t=m.ENABLE,printAnnotationStorage:n=null,isEditing:r=!1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const i=this._transport.getRenderingIntent(e,t,n,r,!0);let s,a=this._intentStates.get(i.cacheKey);return a||(a=Object.create(null),this._intentStates.set(i.cacheKey,a)),a.opListReadCapability||(s=Object.create(null),s.operatorListChanged=function(){a.operatorList.lastChunk&&(a.opListReadCapability.resolve(a.operatorList),a.renderTasks.delete(s))},a.opListReadCapability=Promise.withResolvers(),(a.renderTasks||=new Set).add(s),a.operatorList={fnArray:[],argsArray:[],lastChunk:!1,separateAnnots:null},this._stats?.time("Page Request"),this._pumpOperatorList(i)),a.opListReadCapability.promise}streamTextContent(){let{includeMarkedContent:e=!1,disableNormalization:t=!1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this._transport.messageHandler.sendWithStream("GetTextContent",{pageIndex:this._pageIndex,includeMarkedContent:!0===e,disableNormalization:!0===t},{highWaterMark:100,size:e=>e.items.length})}getTextContent(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(this._transport._htmlForXfa)return this.getXfa().then(e=>ue.textContent(e));const t=this.streamTextContent(e);return new Promise(function(e,n){const r=t.getReader(),i={items:[],styles:Object.create(null),lang:null};!function t(){r.read().then(function(n){let{value:r,done:s}=n;s?e(i):(i.lang??=r.lang,Object.assign(i.styles,r.styles),i.items.push(...r.items),t())},n)}()})}getStructTree(){return this._transport.getStructTree(this._pageIndex)}_destroy(){this.destroyed=!0;const e=[];for(const t of this._intentStates.values())if(this._abortOperatorList({intentState:t,reason:new Error("Page was destroyed."),force:!0}),!t.opListReadCapability)for(const n of t.renderTasks)e.push(n.completed),n.cancel();return this.objs.clear(),this.#Si=!1,Promise.all(e)}cleanup(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.#Si=!0;const t=this.#Ti();return e&&t&&(this._stats&&=new _e),t}#Ti(){if(!this.#Si||this.destroyed)return!1;for(const{renderTasks:e,operatorList:t}of this._intentStates.values())if(e.size>0||!t.lastChunk)return!1;return this._intentStates.clear(),this.objs.clear(),this.#Si=!1,!0}_startRenderPage(e,t){const n=this._intentStates.get(t);n&&(this._stats?.timeEnd("Page Request"),n.displayReadyCapability?.resolve(e))}_renderPageChunk(e,t){for(let n=0,r=e.length;n<r;n++)t.operatorList.fnArray.push(e.fnArray[n]),t.operatorList.argsArray.push(e.argsArray[n]);t.operatorList.lastChunk=e.lastChunk,t.operatorList.separateAnnots=e.separateAnnots;for(const n of t.renderTasks)n.operatorListChanged();e.lastChunk&&this.#Ti()}_pumpOperatorList(e){let{renderingIntent:t,cacheKey:n,annotationStorageSerializable:r,modifiedIds:i}=e;const{map:s,transfer:a}=r,o=this._transport.messageHandler.sendWithStream("GetOperatorList",{pageIndex:this._pageIndex,intent:t,cacheKey:n,annotationStorage:s,modifiedIds:i},a).getReader(),l=this._intentStates.get(n);l.streamReader=o;const c=()=>{o.read().then(e=>{let{value:t,done:n}=e;n?l.streamReader=null:this._transport.destroyed||(this._renderPageChunk(t,l),c())},e=>{if(l.streamReader=null,!this._transport.destroyed){if(l.operatorList){l.operatorList.lastChunk=!0;for(const e of l.renderTasks)e.operatorListChanged();this.#Ti()}if(l.displayReadyCapability)l.displayReadyCapability.reject(e);else{if(!l.opListReadCapability)throw e;l.opListReadCapability.reject(e)}}})};c()}_abortOperatorList(e){let{intentState:t,reason:n,force:r=!1}=e;if(t.streamReader){if(t.streamReaderCancelTimeout&&(clearTimeout(t.streamReaderCancelTimeout),t.streamReaderCancelTimeout=null),!r){if(t.renderTasks.size>0)return;if(n instanceof ye){let e=100;return n.extraDelay>0&&n.extraDelay<1e3&&(e+=n.extraDelay),void(t.streamReaderCancelTimeout=setTimeout(()=>{t.streamReaderCancelTimeout=null,this._abortOperatorList({intentState:t,reason:n,force:!0})},e))}}if(t.streamReader.cancel(new ee(n.message)).catch(()=>{}),t.streamReader=null,!this._transport.destroyed){for(const[e,n]of this._intentStates)if(n===t){this._intentStates.delete(e);break}this.cleanup()}}}get stats(){return this._stats}}class br{#Kr=(()=>Promise.withResolvers())();#Di=null;#Fr=null;#Mi=null;static#Pi=0;static#Ii=!1;static#Fi=(()=>(r=()=>{i&&(this.#Ii=!0,Bn.workerSrc||="./pdf.worker.mjs"),this._isSameOrigin=(e,t)=>{const n=URL.parse(e);if(!n?.origin||"null"===n.origin)return!1;const r=new URL(t,n);return n.origin===r.origin},this._createCDNWrapper=e=>{const t=`await import("${e}");`;return URL.createObjectURL(new Blob([t],{type:"text/javascript"}))},this.fromPort=e=>{var t;if(t="`PDFWorker.fromPort` - please use `PDFWorker.create` instead.",console.log("Deprecated API usage: "+t),!e?.port)throw new Error("PDFWorker.fromPort - invalid method signature.");return this.create(e)}},new WeakMap))();constructor(){let{name:e=null,port:t=null,verbosity:n=z()}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(this.name=e,this.destroyed=!1,this.verbosity=n,t){if(br.#Fi.has(t))throw new Error("Cannot use more than one PDFWorker per port.");br.#Fi.set(t,this),this.#Ri(t)}else this.#Ni()}get promise(){return this.#Kr.promise}#Li(){this.#Kr.resolve(),this.#Di.send("configure",{verbosity:this.verbosity})}get port(){return this.#Fr}get messageHandler(){return this.#Di}#Ri(e){this.#Fr=e,this.#Di=new Et("main","worker",e),this.#Di.on("ready",()=>{}),this.#Li()}#Ni(){if(br.#Ii||br.#Oi)return void this.#Bi();let{workerSrc:e}=br;try{br._isSameOrigin(window.location,e)||(e=br._createCDNWrapper(new URL(e,window.location).href));const t=new Worker(e,{type:"module"}),n=new Et("main","worker",t),r=()=>{i.abort(),n.destroy(),t.terminate(),this.destroyed?this.#Kr.reject(new Error("Worker was destroyed")):this.#Bi()},i=new AbortController;t.addEventListener("error",()=>{this.#Mi||r()},{signal:i.signal}),n.on("test",e=>{i.abort(),!this.destroyed&&e?(this.#Di=n,this.#Fr=t,this.#Mi=t,this.#Li()):r()}),n.on("ready",e=>{if(i.abort(),this.destroyed)r();else try{s()}catch{this.#Bi()}});const s=()=>{const e=new Uint8Array;n.send("test",e,[e.buffer])};return void s()}catch{j("The worker has been disabled.")}this.#Bi()}#Bi(){br.#Ii||(U("Setting up fake worker."),br.#Ii=!0),br._setupFakeWorkerGlobal.then(e=>{if(this.destroyed)return void this.#Kr.reject(new Error("Worker was destroyed"));const t=new dt;this.#Fr=t;const n="fake"+br.#Pi++,r=new Et(n+"_worker",n,t);e.setup(r,t),this.#Di=new Et(n,n+"_worker",t),this.#Li()}).catch(e=>{this.#Kr.reject(new Error(`Setting up fake worker failed: "${e.message}".`))})}destroy(){this.destroyed=!0,this.#Mi?.terminate(),this.#Mi=null,br.#Fi.delete(this.#Fr),this.#Fr=null,this.#Di?.destroy(),this.#Di=null}static create(e){const t=this.#Fi.get(e?.port);if(t){if(t._pendingDestroy)throw new Error("PDFWorker.create - the worker is being destroyed.\nPlease remember to await `PDFDocumentLoadingTask.destroy()`-calls.");return t}return new br(e)}static get workerSrc(){if(Bn.workerSrc)return Bn.workerSrc;throw new Error('No "GlobalWorkerOptions.workerSrc" specified.')}static get#Oi(){try{return globalThis.pdfjsWorker?.WorkerMessageHandler||null}catch{return null}}static get _setupFakeWorkerGlobal(){return G(this,"_setupFakeWorkerGlobal",(async()=>{if(this.#Oi)return this.#Oi;return(await n(59169)(this.workerSrc)).WorkerMessageHandler})())}}r();class wr{#$i=(()=>new Map)();#zi=(()=>new Map)();#ji=(()=>new Map)();#Ui=(()=>new Map)();#Hi=null;constructor(e,t,n,r,i,s){this.messageHandler=e,this.loadingTask=t,this.commonObjs=new ur,this.fontLoader=new at({ownerDocument:r.ownerDocument,styleElement:r.styleElement}),this.loadingParams=r.loadingParams,this._params=r,this.canvasFactory=i.canvasFactory,this.filterFactory=i.filterFactory,this.cMapReaderFactory=i.cMapReaderFactory,this.standardFontDataFactory=i.standardFontDataFactory,this.wasmFactory=i.wasmFactory,this.destroyed=!1,this.destroyCapability=null,this._networkStream=n,this._fullReader=null,this._lastProgress=null,this.downloadInfoCapability=Promise.withResolvers(),this.enableHWA=s,this.setupMessageHandler()}#Vi(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;const n=this.#$i.get(e);if(n)return n;const r=this.messageHandler.sendWithPromise(e,t);return this.#$i.set(e,r),r}get annotationStorage(){return G(this,"annotationStorage",new it)}getRenderingIntent(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.ENABLE,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],i=arguments.length>4&&void 0!==arguments[4]&&arguments[4],s=l,a=rt;switch(e){case"any":s=o;break;case"display":break;case"print":s=c;break;default:U(`getRenderingIntent - invalid intent: ${e}`)}const g=s&c&&n instanceof st?n:this.annotationStorage;switch(t){case m.DISABLE:s+=u;break;case m.ENABLE:break;case m.ENABLE_FORMS:s+=h;break;case m.ENABLE_STORAGE:s+=d,a=g.serializable;break;default:U(`getRenderingIntent - invalid annotationMode: ${t}`)}r&&(s+=p),i&&(s+=f);const{ids:v,hash:y}=g.modifiedIds;return{renderingIntent:s,cacheKey:[s,a.hash,y].join("_"),annotationStorageSerializable:a,modifiedIds:v}}destroy(){if(this.destroyCapability)return this.destroyCapability.promise;this.destroyed=!0,this.destroyCapability=Promise.withResolvers(),this.#Hi?.reject(new Error("Worker was destroyed during onPassword callback"));const e=[];for(const n of this.#zi.values())e.push(n._destroy());this.#zi.clear(),this.#ji.clear(),this.#Ui.clear(),this.hasOwnProperty("annotationStorage")&&this.annotationStorage.resetModified();const t=this.messageHandler.sendWithPromise("Terminate",null);return e.push(t),Promise.all(e).then(()=>{this.commonObjs.clear(),this.fontLoader.clear(),this.#$i.clear(),this.filterFactory.destroy(),pr.cleanup(),this._networkStream?.cancelAllRequests(new ee("Worker was terminated.")),this.messageHandler?.destroy(),this.messageHandler=null,this.destroyCapability.resolve()},this.destroyCapability.reject),this.destroyCapability.promise}setupMessageHandler(){const{messageHandler:e,loadingTask:t}=this;e.on("GetReader",(e,t)=>{V(this._networkStream,"GetReader - no `IPDFStream` instance available."),this._fullReader=this._networkStream.getFullReader(),this._fullReader.onProgress=e=>{this._lastProgress={loaded:e.loaded,total:e.total}},t.onPull=()=>{this._fullReader.read().then(function(e){let{value:n,done:r}=e;r?t.close():(V(n instanceof ArrayBuffer,"GetReader - expected an ArrayBuffer."),t.enqueue(new Uint8Array(n),1,[n]))}).catch(e=>{t.error(e)})},t.onCancel=e=>{this._fullReader.cancel(e),t.ready.catch(e=>{if(!this.destroyed)throw e})}}),e.on("ReaderHeadersReady",async e=>{await this._fullReader.headersReady;const{isStreamingSupported:n,isRangeSupported:r,contentLength:i}=this._fullReader;return n&&r||(this._lastProgress&&t.onProgress?.(this._lastProgress),this._fullReader.onProgress=e=>{t.onProgress?.({loaded:e.loaded,total:e.total})}),{isStreamingSupported:n,isRangeSupported:r,contentLength:i}}),e.on("GetRangeReader",(e,t)=>{V(this._networkStream,"GetRangeReader - no `IPDFStream` instance available.");const n=this._networkStream.getRangeReader(e.begin,e.end);n?(t.onPull=()=>{n.read().then(function(e){let{value:n,done:r}=e;r?t.close():(V(n instanceof ArrayBuffer,"GetRangeReader - expected an ArrayBuffer."),t.enqueue(new Uint8Array(n),1,[n]))}).catch(e=>{t.error(e)})},t.onCancel=e=>{n.cancel(e),t.ready.catch(e=>{if(!this.destroyed)throw e})}):t.close()}),e.on("GetDoc",e=>{let{pdfInfo:n}=e;this._numPages=n.numPages,this._htmlForXfa=n.htmlForXfa,delete n.htmlForXfa,t._capability.resolve(new vr(n,this))}),e.on("DocException",e=>{t._capability.reject(xt(e))}),e.on("PasswordRequest",e=>{this.#Hi=Promise.withResolvers();try{if(!t.onPassword)throw xt(e);const n=e=>{e instanceof Error?this.#Hi.reject(e):this.#Hi.resolve({password:e})};t.onPassword(n,e.code)}catch(n){this.#Hi.reject(n)}return this.#Hi.promise}),e.on("DataLoaded",e=>{t.onProgress?.({loaded:e.length,total:e.length}),this.downloadInfoCapability.resolve(e)}),e.on("StartRenderPage",e=>{if(this.destroyed)return;this.#zi.get(e.pageIndex)._startRenderPage(e.transparency,e.cacheKey)}),e.on("commonobj",t=>{let[n,r,i]=t;if(this.destroyed)return null;if(this.commonObjs.has(n))return null;switch(r){case"Font":if("error"in i){const e=i.error;U(`Error during font loading: ${e}`),this.commonObjs.resolve(n,e);break}const t=new On(i),s=this._params.pdfBug&&globalThis.FontInspector?.enabled?(e,t)=>globalThis.FontInspector.fontAdded(e,t):null,a=new ot(t,s,i.extra,i.charProcOperatorList);this.fontLoader.bind(a).catch(()=>e.sendWithPromise("FontFallback",{id:n})).finally(()=>{!a.fontExtraProperties&&a.data&&a.clearData(),this.commonObjs.resolve(n,a)});break;case"CopyLocalImage":const{imageRef:o}=i;V(o,"The imageRef must be defined.");for(const e of this.#zi.values())for(const[,t]of e.objs)if(t?.ref===o)return t.dataLen?(this.commonObjs.resolve(n,structuredClone(t)),t.dataLen):null;break;case"FontPath":case"Image":case"Pattern":this.commonObjs.resolve(n,i);break;default:throw new Error(`Got unknown common object type ${r}`)}return null}),e.on("obj",e=>{let[t,n,r,i]=e;if(this.destroyed)return;const s=this.#zi.get(n);if(!s.objs.has(t))if(0!==s._intentStates.size)switch(r){case"Image":case"Pattern":s.objs.resolve(t,i);break;default:throw new Error(`Got unknown object type ${r}`)}else i?.bitmap?.close()}),e.on("DocProgress",e=>{this.destroyed||t.onProgress?.({loaded:e.loaded,total:e.total})}),e.on("FetchBinaryData",async e=>{if(this.destroyed)throw new Error("Worker was destroyed.");const t=this[e.type];if(!t)throw new Error(`${e.type} not initialized, see the \`useWorkerFetch\` parameter.`);return t.fetch(e)})}getData(){return this.messageHandler.sendWithPromise("GetData",null)}saveDocument(){this.annotationStorage.size<=0&&U("saveDocument called while `annotationStorage` is empty, please use the getData-method instead.");const{map:e,transfer:t}=this.annotationStorage.serializable;return this.messageHandler.sendWithPromise("SaveDocument",{isPureXfa:!!this._htmlForXfa,numPages:this._numPages,annotationStorage:e,filename:this._fullReader?.filename??null},t).finally(()=>{this.annotationStorage.resetModified()})}getPage(e){if(!Number.isInteger(e)||e<=0||e>this._numPages)return Promise.reject(new Error("Invalid page request."));const t=e-1,n=this.#ji.get(t);if(n)return n;const r=this.messageHandler.sendWithPromise("GetPage",{pageIndex:t}).then(n=>{if(this.destroyed)throw new Error("Transport destroyed");n.refStr&&this.#Ui.set(n.refStr,e);const r=new yr(t,n,this,this._params.pdfBug);return this.#zi.set(t,r),r});return this.#ji.set(t,r),r}getPageIndex(e){return ct(e)?this.messageHandler.sendWithPromise("GetPageIndex",{num:e.num,gen:e.gen}):Promise.reject(new Error("Invalid pageIndex request."))}getAnnotations(e,t){return this.messageHandler.sendWithPromise("GetAnnotations",{pageIndex:e,intent:t})}getFieldObjects(){return this.#Vi("GetFieldObjects")}hasJSActions(){return this.#Vi("HasJSActions")}getCalculationOrderIds(){return this.messageHandler.sendWithPromise("GetCalculationOrderIds",null)}getDestinations(){return this.messageHandler.sendWithPromise("GetDestinations",null)}getDestination(e){return"string"!==typeof e?Promise.reject(new Error("Invalid destination request.")):this.messageHandler.sendWithPromise("GetDestination",{id:e})}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)}getAnnotationsByType(e,t){return this.messageHandler.sendWithPromise("GetAnnotationsByType",{types:e,pageIndexesToSkip:t})}getDocJSActions(){return this.#Vi("GetDocJSActions")}getPageJSActions(e){return this.messageHandler.sendWithPromise("GetPageJSActions",{pageIndex:e})}getStructTree(e){return this.messageHandler.sendWithPromise("GetStructTree",{pageIndex:e})}getOutline(){return this.messageHandler.sendWithPromise("GetOutline",null)}getOptionalContentConfig(e){return this.#Vi("GetOptionalContentConfig").then(t=>new Un(t,e))}getPermissions(){return this.messageHandler.sendWithPromise("GetPermissions",null)}getMetadata(){const e="GetMetadata",t=this.#$i.get(e);if(t)return t;const n=this.messageHandler.sendWithPromise(e,null).then(e=>({info:e[0],metadata:e[1]?new $n(e[1]):null,contentDispositionFilename:this._fullReader?.filename??null,contentLength:this._fullReader?.contentLength??null}));return this.#$i.set(e,n),n}getMarkInfo(){return this.messageHandler.sendWithPromise("GetMarkInfo",null)}async startCleanup(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(!this.destroyed){await this.messageHandler.sendWithPromise("Cleanup",null);for(const e of this.#zi.values()){if(!e.cleanup())throw new Error(`startCleanup: Page ${e.pageNumber} is currently rendering.`)}this.commonObjs.clear(),e||this.fontLoader.clear(),this.#$i.clear(),this.filterFactory.destroy(!0),pr.cleanup()}}cachedPageNumber(e){if(!ct(e))return null;const t=0===e.gen?`${e.num}R`:`${e.num}R${e.gen}`;return this.#Ui.get(t)??null}}class _r{#qi=null;onContinue=null;onError=null;constructor(e){this.#qi=e}get promise(){return this.#qi.capability.promise}cancel(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;this.#qi.cancel(null,e)}get separateAnnots(){const{separateAnnots:e}=this.#qi.operatorList;if(!e)return!1;const{annotationCanvasMap:t}=this.#qi;return e.form||e.canvas&&t?.size>0}}class Ar{#Wi=null;static#Gi=(()=>new WeakSet)();constructor(e){let{callback:t,params:n,objs:r,commonObjs:i,annotationCanvasMap:s,operatorList:a,pageIndex:o,canvasFactory:l,filterFactory:c,useRequestAnimationFrame:h=!1,pdfBug:d=!1,pageColors:u=null,enableHWA:p=!1,operationsFilter:f=null}=e;this.callback=t,this.params=n,this.objs=r,this.commonObjs=i,this.annotationCanvasMap=s,this.operatorListIdx=null,this.operatorList=a,this._pageIndex=o,this.canvasFactory=l,this.filterFactory=c,this._pdfBug=d,this.pageColors=u,this.running=!1,this.graphicsReadyCallback=null,this.graphicsReady=!1,this._useRequestAnimationFrame=!0===h&&"undefined"!==typeof window,this.cancelled=!1,this.capability=Promise.withResolvers(),this.task=new _r(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=n.canvas,this._canvasContext=n.canvas?null:n.canvasContext,this._enableHWA=p,this._dependencyTracker=n.dependencyTracker,this._operationsFilter=f}get completed(){return this.capability.promise.catch(function(){})}initializeGraphics(e){let{transparency:t=!1,optionalContentConfig:n}=e;if(this.cancelled)return;if(this._canvas){if(Ar.#Gi.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.");Ar.#Gi.add(this._canvas)}this._pdfBug&&globalThis.StepperManager?.enabled&&(this.stepper=globalThis.StepperManager.create(this._pageIndex),this.stepper.init(this.operatorList),this.stepper.nextBreakPoint=this.stepper.getNextBreakPoint());const{viewport:r,transform:i,background:s,dependencyTracker:a}=this.params,o=this._canvasContext||this._canvas.getContext("2d",{alpha:!1,willReadFrequently:!this._enableHWA});this.gfx=new Rn(o,this.commonObjs,this.objs,this.canvasFactory,this.filterFactory,{optionalContentConfig:n},this.annotationCanvasMap,this.pageColors,a),this.gfx.beginDrawing({transform:i,viewport:r,transparency:t,background:s}),this.operatorListIdx=0,this.graphicsReady=!0,this.graphicsReadyCallback?.()}cancel(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;this.running=!1,this.cancelled=!0,this.gfx?.endDrawing(),this.#Wi&&(window.cancelAnimationFrame(this.#Wi),this.#Wi=null),Ar.#Gi.delete(this._canvas),e||=new ye(`Rendering cancelled, page ${this._pageIndex+1}`,t),this.callback(e),this.task.onError?.(e)}operatorListChanged(){this.graphicsReady?(this.gfx.dependencyTracker?.growOperationsCount(this.operatorList.fnArray.length),this.stepper?.updateOperatorList(this.operatorList),this.running||this._continue()):this.graphicsReadyCallback||=this._continueBound}_continue(){this.running=!0,this.cancelled||(this.task.onContinue?this.task.onContinue(this._scheduleNextBound):this._scheduleNext())}_scheduleNext(){this._useRequestAnimationFrame?this.#Wi=window.requestAnimationFrame(()=>{this.#Wi=null,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._operationsFilter),this.operatorListIdx===this.operatorList.argsArray.length&&(this.running=!1,this.operatorList.lastChunk&&(this.gfx.endDrawing(),Ar.#Gi.delete(this._canvas),this.callback())))}}class xr{#Ki=null;#Xi=null;#Yi;#Zi=null;#Ji=!1;#Qi=!1;#s=null;#es;#ts=null;#v=null;static#ns=null;static get _keyboardManager(){return G(this,"_keyboardManager",new qe([[["Escape","mac+Escape"],xr.prototype._hideDropdownFromKeyboard],[[" ","mac+ "],xr.prototype._colorSelectFromKeyboard],[["ArrowDown","ArrowRight","mac+ArrowDown","mac+ArrowRight"],xr.prototype._moveToNext],[["ArrowUp","ArrowLeft","mac+ArrowUp","mac+ArrowLeft"],xr.prototype._moveToPrevious],[["Home","mac+Home"],xr.prototype._moveToBeginning],[["End","mac+End"],xr.prototype._moveToEnd]]))}constructor(e){let{editor:t=null,uiManager:n=null}=e;t?(this.#Qi=!1,this.#s=t):this.#Qi=!0,this.#v=t?._uiManager||n,this.#es=this.#v._eventBus,this.#Yi=t?.color?.toUpperCase()||this.#v?.highlightColors.values().next().value||"#FFFF98",xr.#ns||=Object.freeze({blue:"pdfjs-editor-colorpicker-blue",green:"pdfjs-editor-colorpicker-green",pink:"pdfjs-editor-colorpicker-pink",red:"pdfjs-editor-colorpicker-red",yellow:"pdfjs-editor-colorpicker-yellow"})}renderButton(){const e=this.#Ki=document.createElement("button");e.className="colorPicker",e.tabIndex="0",e.setAttribute("data-l10n-id","pdfjs-editor-colorpicker-button"),e.ariaHasPopup="true",this.#s&&(e.ariaControls=`${this.#s.id}_colorpicker_dropdown`);const t=this.#v._signal;e.addEventListener("click",this.#rs.bind(this),{signal:t}),e.addEventListener("keydown",this.#is.bind(this),{signal:t});const n=this.#Xi=document.createElement("span");return n.className="swatch",n.ariaHidden="true",n.style.backgroundColor=this.#Yi,e.append(n),e}renderMainDropdown(){const e=this.#Zi=this.#ss();return e.ariaOrientation="horizontal",e.ariaLabelledBy="highlightColorPickerLabel",e}#ss(){const e=document.createElement("div"),t=this.#v._signal;e.addEventListener("contextmenu",xe,{signal:t}),e.className="dropdown",e.role="listbox",e.ariaMultiSelectable="false",e.ariaOrientation="vertical",e.setAttribute("data-l10n-id","pdfjs-editor-colorpicker-dropdown"),this.#s&&(e.id=`${this.#s.id}_colorpicker_dropdown`);for(const[n,r]of this.#v.highlightColors){const i=document.createElement("button");i.tabIndex="0",i.role="option",i.setAttribute("data-color",r),i.title=n,i.setAttribute("data-l10n-id",xr.#ns[n]);const s=document.createElement("span");i.append(s),s.className="swatch",s.style.backgroundColor=r,i.ariaSelected=r===this.#Yi,i.addEventListener("click",this.#as.bind(this,r),{signal:t}),e.append(i)}return e.addEventListener("keydown",this.#is.bind(this),{signal:t}),e}#as(e,t){t.stopPropagation(),this.#es.dispatch("switchannotationeditorparams",{source:this,type:y.HIGHLIGHT_COLOR,value:e}),this.updateColor(e)}_colorSelectFromKeyboard(e){if(e.target===this.#Ki)return void this.#rs(e);const t=e.target.getAttribute("data-color");t&&this.#as(t,e)}_moveToNext(e){this.#os?e.target!==this.#Ki?e.target.nextSibling?.focus():this.#Zi.firstChild?.focus():this.#rs(e)}_moveToPrevious(e){e.target!==this.#Zi?.firstChild&&e.target!==this.#Ki?(this.#os||this.#rs(e),e.target.previousSibling?.focus()):this.#os&&this._hideDropdownFromKeyboard()}_moveToBeginning(e){this.#os?this.#Zi.firstChild?.focus():this.#rs(e)}_moveToEnd(e){this.#os?this.#Zi.lastChild?.focus():this.#rs(e)}#is(e){xr._keyboardManager.exec(this,e)}#rs(e){if(this.#os)return void this.hideDropdown();if(this.#Ji=0===e.detail,this.#ts||(this.#ts=new AbortController,window.addEventListener("pointerdown",this.#u.bind(this),{signal:this.#v.combinedSignal(this.#ts)})),this.#Ki.ariaExpanded="true",this.#Zi)return void this.#Zi.classList.remove("hidden");const t=this.#Zi=this.#ss();this.#Ki.append(t)}#u(e){this.#Zi?.contains(e.target)||this.hideDropdown()}hideDropdown(){this.#Zi?.classList.add("hidden"),this.#Ki.ariaExpanded="false",this.#ts?.abort(),this.#ts=null}get#os(){return this.#Zi&&!this.#Zi.classList.contains("hidden")}_hideDropdownFromKeyboard(){this.#Qi||(this.#os?(this.hideDropdown(),this.#Ki.focus({preventScroll:!0,focusVisible:this.#Ji})):this.#s?.unselect())}updateColor(e){if(this.#Xi&&(this.#Xi.style.backgroundColor=e),!this.#Zi)return;const t=this.#v.highlightColors.values();for(const n of this.#Zi.children)n.ariaSelected=t.next().value===e.toUpperCase()}destroy(){this.#Ki?.remove(),this.#Ki=null,this.#Xi=null,this.#Zi?.remove(),this.#Zi=null}}class Er{#ls=null;#s=null;#v=null;static#ns=null;constructor(e){this.#s=e,this.#v=e._uiManager,Er.#ns||=Object.freeze({freetext:"pdfjs-editor-color-picker-free-text-input",ink:"pdfjs-editor-color-picker-ink-input"})}renderButton(){if(this.#ls)return this.#ls;const{editorType:e,colorType:t,colorValue:n}=this.#s,r=this.#ls=document.createElement("input");return r.type="color",r.value=n||"#000000",r.className="basicColorPicker",r.tabIndex=0,r.setAttribute("data-l10n-id",Er.#ns[e]),r.addEventListener("input",()=>{this.#v.updateParams(t,r.value)},{signal:this.#v._signal}),r}update(e){this.#ls&&(this.#ls.value=e)}destroy(){this.#ls?.remove(),this.#ls=null}hideDropdown(){}}function Cr(e){return Math.floor(255*Math.max(0,Math.min(1,e))).toString(16).padStart(2,"0")}function kr(e){return Math.max(0,Math.min(255,255*e))}class Sr{static CMYK_G(e){let[t,n,r,i]=e;return["G",1-Math.min(1,.3*t+.59*r+.11*n+i)]}static G_CMYK(e){let[t]=e;return["CMYK",0,0,0,1-t]}static G_RGB(e){let[t]=e;return["RGB",t,t,t]}static G_rgb(e){let[t]=e;return t=kr(t),[t,t,t]}static G_HTML(e){let[t]=e;const n=Cr(t);return`#${n}${n}${n}`}static RGB_G(e){let[t,n,r]=e;return["G",.3*t+.59*n+.11*r]}static RGB_rgb(e){return e.map(kr)}static RGB_HTML(e){return`#${e.map(Cr).join("")}`}static T_HTML(){return"#00000000"}static T_rgb(){return[null]}static CMYK_RGB(e){let[t,n,r,i]=e;return["RGB",1-Math.min(1,t+i),1-Math.min(1,r+i),1-Math.min(1,n+i)]}static CMYK_rgb(e){let[t,n,r,i]=e;return[kr(1-Math.min(1,t+i)),kr(1-Math.min(1,r+i)),kr(1-Math.min(1,n+i))]}static CMYK_HTML(e){const t=this.CMYK_RGB(e).slice(1);return this.RGB_HTML(t)}static RGB_CMYK(e){let[t,n,r]=e;const i=1-t,s=1-n,a=1-r;return["CMYK",i,s,a,Math.min(i,s,a)]}}class Tr{create(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(e<=0||t<=0)throw new Error("Invalid SVG dimensions");const r=this._createSVG("svg:svg");return r.setAttribute("version","1.1"),n||(r.setAttribute("width",`${e}px`),r.setAttribute("height",`${t}px`)),r.setAttribute("preserveAspectRatio","none"),r.setAttribute("viewBox",`0 0 ${e} ${t}`),r}createElement(e){if("string"!==typeof e)throw new Error("Invalid SVG element type");return this._createSVG(e)}_createSVG(e){H("Abstract method `_createSVG` called.")}}class Dr extends Tr{_createSVG(e){return document.createElementNS(fe,e)}}const Mr=new WeakSet,Pr=60*(new Date).getTimezoneOffset()*1e3;class Ir{static create(e){switch(e.data.annotationType){case k.LINK:return new Nr(e);case k.TEXT:return new Lr(e);case k.WIDGET:switch(e.data.fieldType){case"Tx":return new Br(e);case"Btn":return e.data.radioButton?new jr(e):e.data.checkBox?new zr(e):new Ur(e);case"Ch":return new Hr(e);case"Sig":return new $r(e)}return new Or(e);case k.POPUP:return new Vr(e);case k.FREETEXT:return new Wr(e);case k.LINE:return new Gr(e);case k.SQUARE:return new Kr(e);case k.CIRCLE:return new Xr(e);case k.POLYLINE:return new Yr(e);case k.CARET:return new Jr(e);case k.INK:return new Qr(e);case k.POLYGON:return new Zr(e);case k.HIGHLIGHT:return new ei(e);case k.UNDERLINE:return new ti(e);case k.SQUIGGLY:return new ni(e);case k.STRIKEOUT:return new ri(e);case k.STAMP:return new ii(e);case k.FILEATTACHMENT:return new si(e);default:return new Fr(e)}}}class Fr{#cs=null;#hs=!1;#ds=null;constructor(e){let{isRenderable:t=!1,ignoreBorder:n=!1,createQuadrilaterals:r=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.isRenderable=t,this.data=e.data,this.layer=e.layer,this.linkService=e.linkService,this.downloadManager=e.downloadManager,this.imageResourcesPath=e.imageResourcesPath,this.renderForms=e.renderForms,this.svgFactory=e.svgFactory,this.annotationStorage=e.annotationStorage,this.enableComment=e.enableComment,this.enableScripting=e.enableScripting,this.hasJSActions=e.hasJSActions,this._fieldObjects=e.fieldObjects,this.parent=e.parent,t&&(this.container=this._createContainer(n)),r&&this._createQuadrilaterals()}static _hasPopupData(e){let{contentsObj:t,richText:n}=e;return!(!t?.str&&!n?.str)}get _isEditable(){return this.data.isEditable}get hasPopupData(){return Fr._hasPopupData(this.data)||this.enableComment&&!!this.commentText}get commentData(){const{data:e}=this,t=this.annotationStorage?.getEditor(e.id);return t?t.getData():e}get hasCommentButton(){return this.enableComment&&this.hasPopupElement}get commentButtonPosition(){const e=this.annotationStorage?.getEditor(this.data.id);if(e)return e.commentButtonPositionInPage;const{quadPoints:t,inkLists:n,rect:r}=this.data;let i=-1/0,s=-1/0;if(t?.length>=8){for(let e=0;e<t.length;e+=8)t[e+1]>s?(s=t[e+1],i=t[e+2]):t[e+1]===s&&(i=Math.max(i,t[e+2]));return[i,s]}if(n?.length>=1){for(const e of n)for(let t=0,n=e.length;t<n;t+=2)e[t+1]>s?(s=e[t+1],i=e[t]):e[t+1]===s&&(i=Math.max(i,e[t]));if(i!==1/0)return[i,s]}return r?[r[2],r[3]]:null}_normalizePoint(e){const{page:{view:t},viewport:{rawDims:{pageWidth:n,pageHeight:r,pageX:i,pageY:s}}}=this.parent;return e[1]=t[3]-e[1]+t[1],e[0]=100*(e[0]-i)/n,e[1]=100*(e[1]-s)/r,e}get commentText(){const{data:e}=this;return this.annotationStorage.getRawValue(`${g}${e.id}`)?.popup?.contents||e.contentsObj?.str||""}set commentText(e){const{data:t}=this,n={deleted:!e,contents:e||""};this.annotationStorage.updateEditor(t.id,{popup:n})||this.annotationStorage.setValue(`${g}${t.id}`,{id:t.id,annotationType:t.annotationType,pageIndex:this.parent.page._pageIndex,popup:n,popupRef:t.popupRef,modificationDate:new Date}),e||this.removePopup()}removePopup(){(this.#ds?.popup||this.popup)?.remove(),this.#ds=this.popup=null}updateEdited(e){if(!this.container)return;e.rect&&(this.#cs||={rect:this.data.rect.slice(0)});const{rect:t,popup:n}=e;t&&this.#us(t);let r=this.#ds?.popup||this.popup;!r&&n?.text&&(this._createPopup(n),r=this.#ds.popup),r&&(r.updateEdited(e),n?.deleted&&(r.remove(),this.#ds=null,this.popup=null))}resetEdited(){this.#cs&&(this.#us(this.#cs.rect),this.#ds?.popup.resetEdited(),this.#cs=null)}#us(e){const{container:{style:t},data:{rect:n,rotation:r},parent:{viewport:{rawDims:{pageWidth:i,pageHeight:s,pageX:a,pageY:o}}}}=this;n?.splice(0,4,...e),t.left=100*(e[0]-a)/i+"%",t.top=100*(s-e[3]+o)/s+"%",0===r?(t.width=100*(e[2]-e[0])/i+"%",t.height=100*(e[3]-e[1])/s+"%"):this.setRotation(r)}_createContainer(e){const{data:t,parent:{page:n,viewport:r}}=this,i=document.createElement("section");i.setAttribute("data-annotation-id",t.id),this instanceof Or||this instanceof Nr||(i.tabIndex=0);const{style:s}=i;if(s.zIndex=this.parent.zIndex,this.parent.zIndex+=2,t.alternativeText&&(i.title=t.alternativeText),t.noRotate&&i.classList.add("norotate"),!t.rect||this instanceof Vr){const{rotation:e}=t;return t.hasOwnCanvas||0===e||this.setRotation(e,i),i}const{width:a,height:o}=this;if(!e&&t.borderStyle.width>0){s.borderWidth=`${t.borderStyle.width}px`;const e=t.borderStyle.horizontalCornerRadius,n=t.borderStyle.verticalCornerRadius;if(e>0||n>0){const t=`calc(${e}px * var(--total-scale-factor)) / calc(${n}px * var(--total-scale-factor))`;s.borderRadius=t}else if(this instanceof jr){const e=`calc(${a}px * var(--total-scale-factor)) / calc(${o}px * var(--total-scale-factor))`;s.borderRadius=e}switch(t.borderStyle.style){case S:s.borderStyle="solid";break;case T:s.borderStyle="dashed";break;case D:U("Unimplemented border style: beveled");break;case M:U("Unimplemented border style: inset");break;case P:s.borderBottomStyle="solid"}const r=t.borderColor||null;r?(this.#hs=!0,s.borderColor=se.makeHexColor(0|r[0],0|r[1],0|r[2])):s.borderWidth=0}const l=se.normalizeRect([t.rect[0],n.view[3]-t.rect[1]+n.view[1],t.rect[2],n.view[3]-t.rect[3]+n.view[1]]),{pageWidth:c,pageHeight:h,pageX:d,pageY:u}=r.rawDims;s.left=100*(l[0]-d)/c+"%",s.top=100*(l[1]-u)/h+"%";const{rotation:p}=t;return t.hasOwnCanvas||0===p?(s.width=100*a/c+"%",s.height=100*o/h+"%"):this.setRotation(p,i),i}setRotation(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.container;if(!this.data.rect)return;const{pageWidth:n,pageHeight:r}=this.parent.viewport.rawDims;let{width:i,height:s}=this;e%180!==0&&([i,s]=[s,i]),t.style.width=100*i/n+"%",t.style.height=100*s/r+"%",t.setAttribute("data-main-rotation",(360-e)%360)}get _commonActions(){const e=(e,t,n)=>{const r=n.detail[e],i=r[0],s=r.slice(1);n.target.style[t]=Sr[`${i}_HTML`](s),this.annotationStorage.setValue(this.data.id,{[t]:Sr[`${i}_rgb`](s)})};return G(this,"_commonActions",{display:e=>{const{display:t}=e.detail,n=t%2===1;this.container.style.visibility=n?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noView:n,noPrint:1===t||2===t})},print:e=>{this.annotationStorage.setValue(this.data.id,{noPrint:!e.detail.print})},hidden:e=>{const{hidden:t}=e.detail;this.container.style.visibility=t?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noPrint:t,noView:t})},focus:e=>{setTimeout(()=>e.target.focus({preventScroll:!1}),0)},userName:e=>{e.target.title=e.detail.userName},readonly:e=>{e.target.disabled=e.detail.readonly},required:e=>{this._setRequired(e.target,e.detail.required)},bgColor:t=>{e("bgColor","backgroundColor",t)},fillColor:t=>{e("fillColor","backgroundColor",t)},fgColor:t=>{e("fgColor","color",t)},textColor:t=>{e("textColor","color",t)},borderColor:t=>{e("borderColor","borderColor",t)},strokeColor:t=>{e("strokeColor","borderColor",t)},rotation:e=>{const t=e.detail.rotation;this.setRotation(t),this.annotationStorage.setValue(this.data.id,{rotation:t})}})}_dispatchEventFromSandbox(e,t){const n=this._commonActions;for(const r of Object.keys(t.detail)){const i=e[r]||n[r];i?.(t)}}_setDefaultPropertiesFromJS(e){if(!this.enableScripting)return;const t=this.annotationStorage.getRawValue(this.data.id);if(!t)return;const n=this._commonActions;for(const[r,i]of Object.entries(t)){const s=n[r];if(s){s({detail:{[r]:i},target:e}),delete t[r]}}}_createQuadrilaterals(){if(!this.container)return;const{quadPoints:e}=this.data;if(!e)return;const[t,n,r,i]=this.data.rect.map(e=>Math.fround(e));if(8===e.length){const[s,a,o,l]=e.subarray(2,6);if(r===s&&i===a&&t===o&&n===l)return}const{style:s}=this.container;let a;if(this.#hs){const{borderColor:e,borderWidth:t}=s;s.borderWidth=0,a=["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="${e}" stroke-width="${t}">`],this.container.classList.add("hasBorder")}const o=r-t,l=i-n,{svgFactory:c}=this,h=c.createElement("svg");h.classList.add("quadrilateralsContainer"),h.setAttribute("width",0),h.setAttribute("height",0),h.role="none";const d=c.createElement("defs");h.append(d);const u=c.createElement("clipPath"),p=`clippath_${this.data.id}`;u.setAttribute("id",p),u.setAttribute("clipPathUnits","objectBoundingBox"),d.append(u);for(let f=2,m=e.length;f<m;f+=8){const n=e[f],r=e[f+1],s=e[f+2],h=e[f+3],d=c.createElement("rect"),p=(s-t)/o,m=(i-r)/l,g=(n-s)/o,v=(r-h)/l;d.setAttribute("x",p),d.setAttribute("y",m),d.setAttribute("width",g),d.setAttribute("height",v),u.append(d),a?.push(`<rect vector-effect="non-scaling-stroke" x="${p}" y="${m}" width="${g}" height="${v}"/>`)}this.#hs&&(a.push("</g></svg>')"),s.backgroundImage=a.join("")),this.container.append(h),this.container.style.clipPath=`url(#${p})`}_createPopup(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;const{data:t}=this;let n,r;e?(n={str:e.text},r=e.date):(n=t.contentsObj,r=t.modificationDate);const i=this.#ds=new Vr({data:{color:t.color,titleObj:t.titleObj,modificationDate:r,contentsObj:n,richText:t.richText,parentRect:t.rect,borderStyle:0,id:`popup_${t.id}`,rotation:t.rotation,noRotate:!0},linkService:this.linkService,parent:this.parent,elements:[this]});this.parent._commentManager||this.parent.div.append(i.render())}get hasPopupElement(){return!!(this.#ds||this.popup||this.data.popupRef)}get extraPopupElement(){return this.#ds}render(){H("Abstract method `AnnotationElement.render` called")}_getElementsByName(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;const n=[];if(this._fieldObjects){const r=this._fieldObjects[e];if(r)for(const{page:e,id:i,exportValues:s}of r){if(-1===e)continue;if(i===t)continue;const r="string"===typeof s?s:null,a=document.querySelector(`[data-element-id="${i}"]`);!a||Mr.has(a)?n.push({id:i,exportValue:r,domElement:a}):U(`_getElementsByName - element not allowed: ${i}`)}return n}for(const r of document.getElementsByName(e)){const{exportValue:e}=r,i=r.getAttribute("data-element-id");i!==t&&(Mr.has(r)&&n.push({id:i,exportValue:e,domElement:r}))}return n}show(){this.container&&(this.container.hidden=!1),this.popup?.maybeShow()}hide(){this.container&&(this.container.hidden=!0),this.popup?.forceHide()}getElementsToTriggerPopup(){return this.container}addHighlightArea(){const e=this.getElementsToTriggerPopup();if(Array.isArray(e))for(const t of e)t.classList.add("highlightArea");else e.classList.add("highlightArea")}_editOnDoubleClick(){if(!this._isEditable)return;const{annotationEditorType:e,data:{id:t}}=this;this.container.addEventListener("dblclick",()=>{this.linkService.eventBus?.dispatch("switchannotationeditormode",{source:this,mode:e,editId:t,mustEnterInEditMode:!0})})}get width(){return this.data.rect[2]-this.data.rect[0]}get height(){return this.data.rect[3]-this.data.rect[1]}}class Rr extends Fr{constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0}),this.editor=e.editor}render(){return this.container.className="editorAnnotation",this.container}createOrUpdatePopup(){const{editor:e}=this;e.hasComment&&(this._createPopup(e.comment),this.extraPopupElement.popup.renderCommentButton())}get hasCommentButton(){return this.enableComment&&this.editor.hasComment}get commentButtonPosition(){return this.editor.commentButtonPositionInPage}get commentText(){return this.editor.comment.text}set commentText(e){this.editor.comment=e,e||this.removePopup()}get commentData(){return this.editor.getData()}remove(){this.container.remove(),this.container=null,this.removePopup()}}class Nr extends Fr{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;super(e,{isRenderable:!0,ignoreBorder:!!t?.ignoreBorder,createQuadrilaterals:!0}),this.isTooltipOnly=e.data.isTooltipOnly}render(){const{data:e,linkService:t}=this,n=document.createElement("a");n.setAttribute("data-element-id",e.id);let r=!1;return e.url?(t.addLinkAttributes(n,e.url,e.newWindow),r=!0):e.action?(this._bindNamedAction(n,e.action,e.overlaidText),r=!0):e.attachment?(this.#ps(n,e.attachment,e.overlaidText,e.attachmentDest),r=!0):e.setOCGState?(this.#fs(n,e.setOCGState,e.overlaidText),r=!0):e.dest?(this._bindLink(n,e.dest,e.overlaidText),r=!0):(e.actions&&(e.actions.Action||e.actions["Mouse Up"]||e.actions["Mouse Down"])&&this.enableScripting&&this.hasJSActions&&(this._bindJSAction(n,e),r=!0),e.resetForm?(this._bindResetFormAction(n,e.resetForm),r=!0):this.isTooltipOnly&&!r&&(this._bindLink(n,""),r=!0)),this.container.classList.add("linkAnnotation"),r&&this.container.append(n),this.container}#ms(){this.container.setAttribute("data-internal-link","")}_bindLink(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";e.href=this.linkService.getDestinationHash(t),e.onclick=()=>(t&&this.linkService.goToDestination(t),!1),(t||""===t)&&this.#ms(),n&&(e.title=n)}_bindNamedAction(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";e.href=this.linkService.getAnchorUrl(""),e.onclick=()=>(this.linkService.executeNamedAction(t),!1),n&&(e.title=n),this.#ms()}#ps(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;e.href=this.linkService.getAnchorUrl(""),t.description?e.title=t.description:n&&(e.title=n),e.onclick=()=>(this.downloadManager?.openOrDownloadData(t.content,t.filename,r),!1),this.#ms()}#fs(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";e.href=this.linkService.getAnchorUrl(""),e.onclick=()=>(this.linkService.executeSetOCGState(t),!1),n&&(e.title=n),this.#ms()}_bindJSAction(e,t){e.href=this.linkService.getAnchorUrl("");const n=new Map([["Action","onclick"],["Mouse Up","onmouseup"],["Mouse Down","onmousedown"]]);for(const r of Object.keys(t.actions)){const i=n.get(r);i&&(e[i]=()=>(this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:t.id,name:r}}),!1))}t.overlaidText&&(e.title=t.overlaidText),e.onclick||(e.onclick=()=>!1),this.#ms()}_bindResetFormAction(e,t){const n=e.onclick;if(n||(e.href=this.linkService.getAnchorUrl("")),this.#ms(),!this._fieldObjects)return U('_bindResetFormAction - "resetForm" action not supported, ensure that the `fieldObjects` parameter is provided.'),void(n||(e.onclick=()=>!1));e.onclick=()=>{n?.();const{fields:e,refs:r,include:i}=t,s=[];if(0!==e.length||0!==r.length){const t=new Set(r);for(const n of e){const e=this._fieldObjects[n]||[];for(const{id:n}of e)t.add(n)}for(const e of Object.values(this._fieldObjects))for(const n of e)t.has(n.id)===i&&s.push(n)}else for(const t of Object.values(this._fieldObjects))s.push(...t);const a=this.annotationStorage,o=[];for(const t of s){const{id:e}=t;switch(o.push(e),t.type){case"text":{const n=t.defaultValue||"";a.setValue(e,{value:n});break}case"checkbox":case"radiobutton":{const n=t.defaultValue===t.exportValues;a.setValue(e,{value:n});break}case"combobox":case"listbox":{const n=t.defaultValue||"";a.setValue(e,{value:n});break}default:continue}const n=document.querySelector(`[data-element-id="${e}"]`);n&&(Mr.has(n)?n.dispatchEvent(new Event("resetform")):U(`_bindResetFormAction - element not allowed: ${e}`))}return this.enableScripting&&this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:"app",ids:o,name:"ResetForm"}}),!1}}}class Lr extends Fr{constructor(e){super(e,{isRenderable:!0})}render(){this.container.classList.add("textAnnotation");const e=document.createElement("img");return e.src=this.imageResourcesPath+"annotation-"+this.data.name.toLowerCase()+".svg",e.setAttribute("data-l10n-id","pdfjs-text-annotation-type"),e.setAttribute("data-l10n-args",JSON.stringify({type:this.data.name})),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.append(e),this.container}}class Or extends Fr{render(){return this.container}showElementAndHideCanvas(e){this.data.hasOwnCanvas&&("CANVAS"===e.previousSibling?.nodeName&&(e.previousSibling.hidden=!0),e.hidden=!1)}_getKeyModifier(e){return re.platform.isMac?e.metaKey:e.ctrlKey}_setEventListener(e,t,n,r,i){n.includes("mouse")?e.addEventListener(n,e=>{this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:r,value:i(e),shift:e.shiftKey,modifier:this._getKeyModifier(e)}})}):e.addEventListener(n,e=>{if("blur"===n){if(!t.focused||!e.relatedTarget)return;t.focused=!1}else if("focus"===n){if(t.focused)return;t.focused=!0}i&&this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:r,value:i(e)}})})}_setEventListeners(e,t,n,r){for(const[i,s]of n)("Action"===s||this.data.actions?.[s])&&("Focus"!==s&&"Blur"!==s||(t||={focused:!1}),this._setEventListener(e,t,i,s,r),"Focus"!==s||this.data.actions?.Blur?"Blur"!==s||this.data.actions?.Focus||this._setEventListener(e,t,"focus","Focus",null):this._setEventListener(e,t,"blur","Blur",null))}_setBackgroundColor(e){const t=this.data.backgroundColor||null;e.style.backgroundColor=null===t?"transparent":se.makeHexColor(t[0],t[1],t[2])}_setTextStyle(e){const t=["left","center","right"],{fontColor:n}=this.data.defaultAppearanceData,r=this.data.defaultAppearanceData.fontSize||9,i=e.style;let s;const o=e=>Math.round(10*e)/10;if(this.data.multiLine){const e=Math.abs(this.data.rect[3]-this.data.rect[1]-2),t=e/(Math.round(e/(a*r))||1);s=Math.min(r,o(t/a))}else{const e=Math.abs(this.data.rect[3]-this.data.rect[1]-2);s=Math.min(r,o(e/a))}i.fontSize=`calc(${s}px * var(--total-scale-factor))`,i.color=se.makeHexColor(n[0],n[1],n[2]),null!==this.data.textAlignment&&(i.textAlign=t[this.data.textAlignment])}_setRequired(e,t){t?e.setAttribute("required",!0):e.removeAttribute("required"),e.setAttribute("aria-required",t)}}class Br extends Or{constructor(e){super(e,{isRenderable:e.renderForms||e.data.hasOwnCanvas||!e.data.hasAppearance&&!!e.data.fieldValue})}setPropertyOnSiblings(e,t,n,r){const i=this.annotationStorage;for(const s of this._getElementsByName(e.name,e.id))s.domElement&&(s.domElement[t]=n),i.setValue(s.id,{[r]:n})}render(){const e=this.annotationStorage,t=this.data.id;this.container.classList.add("textWidgetAnnotation");let n=null;if(this.renderForms){const r=e.getValue(t,{value:this.data.fieldValue});let i=r.value||"";const s=e.getValue(t,{charLimit:this.data.maxLen}).charLimit;s&&i.length>s&&(i=i.slice(0,s));let a=r.formattedValue||this.data.textContent?.join("\n")||null;a&&this.data.comb&&(a=a.replaceAll(/\s+/g,""));const o={userValue:i,formattedValue:a,lastCommittedValue:null,commitKey:1,focused:!1};this.data.multiLine?(n=document.createElement("textarea"),n.textContent=a??i,this.data.doNotScroll&&(n.style.overflowY="hidden")):(n=document.createElement("input"),n.type=this.data.password?"password":"text",n.setAttribute("value",a??i),this.data.doNotScroll&&(n.style.overflowX="hidden")),this.data.hasOwnCanvas&&(n.hidden=!0),Mr.add(n),n.setAttribute("data-element-id",t),n.disabled=this.data.readOnly,n.name=this.data.fieldName,n.tabIndex=0;const{datetimeFormat:l,datetimeType:c,timeStep:h}=this.data,d=!!c&&this.enableScripting;l&&(n.title=l),this._setRequired(n,this.data.required),s&&(n.maxLength=s),n.addEventListener("input",r=>{e.setValue(t,{value:r.target.value}),this.setPropertyOnSiblings(n,"value",r.target.value,"value"),o.formattedValue=null}),n.addEventListener("resetform",e=>{const t=this.data.defaultFieldValue??"";n.value=o.userValue=t,o.formattedValue=null});let u=e=>{const{formattedValue:t}=o;null!==t&&void 0!==t&&(e.target.value=t),e.target.scrollLeft=0};if(this.enableScripting&&this.hasJSActions){n.addEventListener("focus",e=>{if(o.focused)return;const{target:t}=e;if(d&&(t.type=c,h&&(t.step=h)),o.userValue){const e=o.userValue;if(d)if("time"===c){const n=new Date(e),r=[n.getHours(),n.getMinutes(),n.getSeconds()];t.value=r.map(e=>e.toString().padStart(2,"0")).join(":")}else t.value=new Date(e-Pr).toISOString().split("date"===c?"T":".",1)[0];else t.value=e}o.lastCommittedValue=t.value,o.commitKey=1,this.data.actions?.Focus||(o.focused=!0)}),n.addEventListener("updatefromsandbox",n=>{this.showElementAndHideCanvas(n.target);const r={value(n){o.userValue=n.detail.value??"",d||e.setValue(t,{value:o.userValue.toString()}),n.target.value=o.userValue},formattedValue(n){const{formattedValue:r}=n.detail;o.formattedValue=r,null!==r&&void 0!==r&&n.target!==document.activeElement&&(n.target.value=r);const i={formattedValue:r};d&&(i.value=r),e.setValue(t,i)},selRange(e){e.target.setSelectionRange(...e.detail.selRange)},charLimit:n=>{const{charLimit:r}=n.detail,{target:i}=n;if(0===r)return void i.removeAttribute("maxLength");i.setAttribute("maxLength",r);let s=o.userValue;!s||s.length<=r||(s=s.slice(0,r),i.value=o.userValue=s,e.setValue(t,{value:s}),this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:t,name:"Keystroke",value:s,willCommit:!0,commitKey:1,selStart:i.selectionStart,selEnd:i.selectionEnd}}))}};this._dispatchEventFromSandbox(r,n)}),n.addEventListener("keydown",e=>{o.commitKey=1;let n=-1;if("Escape"===e.key?n=0:"Enter"!==e.key||this.data.multiLine?"Tab"===e.key&&(o.commitKey=3):n=2,-1===n)return;const{value:r}=e.target;o.lastCommittedValue!==r&&(o.lastCommittedValue=r,o.userValue=r,this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:t,name:"Keystroke",value:r,willCommit:!0,commitKey:n,selStart:e.target.selectionStart,selEnd:e.target.selectionEnd}}))});const r=u;u=null,n.addEventListener("blur",e=>{if(!o.focused||!e.relatedTarget)return;this.data.actions?.Blur||(o.focused=!1);const{target:n}=e;let{value:i}=n;if(d){if(i&&"time"===c){const e=i.split(":").map(e=>parseInt(e,10));i=new Date(2e3,0,1,e[0],e[1],e[2]||0).valueOf(),n.step=""}else i.includes("T")||(i=`${i}T00:00`),i=new Date(i).valueOf();n.type="text"}o.userValue=i,o.lastCommittedValue!==i&&this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:t,name:"Keystroke",value:i,willCommit:!0,commitKey:o.commitKey,selStart:e.target.selectionStart,selEnd:e.target.selectionEnd}}),r(e)}),this.data.actions?.Keystroke&&n.addEventListener("beforeinput",e=>{o.lastCommittedValue=null;const{data:n,target:r}=e,{value:i,selectionStart:s,selectionEnd:a}=r;let l=s,c=a;switch(e.inputType){case"deleteWordBackward":{const e=i.substring(0,s).match(/\w*[^\w]*$/);e&&(l-=e[0].length);break}case"deleteWordForward":{const e=i.substring(s).match(/^[^\w]*\w*/);e&&(c+=e[0].length);break}case"deleteContentBackward":s===a&&(l-=1);break;case"deleteContentForward":s===a&&(c+=1)}e.preventDefault(),this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:t,name:"Keystroke",value:i,change:n||"",willCommit:!1,selStart:l,selEnd:c}})}),this._setEventListeners(n,o,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],e=>e.target.value)}if(u&&n.addEventListener("blur",u),this.data.comb){const e=(this.data.rect[2]-this.data.rect[0])/s;n.classList.add("comb"),n.style.letterSpacing=`calc(${e}px * var(--total-scale-factor) - 1ch)`}}else n=document.createElement("div"),n.textContent=this.data.fieldValue,n.style.verticalAlign="middle",n.style.display="table-cell",this.data.hasOwnCanvas&&(n.hidden=!0);return this._setTextStyle(n),this._setBackgroundColor(n),this._setDefaultPropertiesFromJS(n),this.container.append(n),this.container}}class $r extends Or{constructor(e){super(e,{isRenderable:!!e.data.hasOwnCanvas})}}class zr extends Or{constructor(e){super(e,{isRenderable:e.renderForms})}render(){const e=this.annotationStorage,t=this.data,n=t.id;let r=e.getValue(n,{value:t.exportValue===t.fieldValue}).value;"string"===typeof r&&(r="Off"!==r,e.setValue(n,{value:r})),this.container.classList.add("buttonWidgetAnnotation","checkBox");const i=document.createElement("input");return Mr.add(i),i.setAttribute("data-element-id",n),i.disabled=t.readOnly,this._setRequired(i,this.data.required),i.type="checkbox",i.name=t.fieldName,r&&i.setAttribute("checked",!0),i.setAttribute("exportValue",t.exportValue),i.tabIndex=0,i.addEventListener("change",r=>{const{name:i,checked:s}=r.target;for(const a of this._getElementsByName(i,n)){const n=s&&a.exportValue===t.exportValue;a.domElement&&(a.domElement.checked=n),e.setValue(a.id,{value:n})}e.setValue(n,{value:s})}),i.addEventListener("resetform",e=>{const n=t.defaultFieldValue||"Off";e.target.checked=n===t.exportValue}),this.enableScripting&&this.hasJSActions&&(i.addEventListener("updatefromsandbox",t=>{const r={value(t){t.target.checked="Off"!==t.detail.value,e.setValue(n,{value:t.target.checked})}};this._dispatchEventFromSandbox(r,t)}),this._setEventListeners(i,null,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],e=>e.target.checked)),this._setBackgroundColor(i),this._setDefaultPropertiesFromJS(i),this.container.append(i),this.container}}class jr extends Or{constructor(e){super(e,{isRenderable:e.renderForms})}render(){this.container.classList.add("buttonWidgetAnnotation","radioButton");const e=this.annotationStorage,t=this.data,n=t.id;let r=e.getValue(n,{value:t.fieldValue===t.buttonValue}).value;if("string"===typeof r&&(r=r!==t.buttonValue,e.setValue(n,{value:r})),r)for(const s of this._getElementsByName(t.fieldName,n))e.setValue(s.id,{value:!1});const i=document.createElement("input");if(Mr.add(i),i.setAttribute("data-element-id",n),i.disabled=t.readOnly,this._setRequired(i,this.data.required),i.type="radio",i.name=t.fieldName,r&&i.setAttribute("checked",!0),i.tabIndex=0,i.addEventListener("change",t=>{const{name:r,checked:i}=t.target;for(const s of this._getElementsByName(r,n))e.setValue(s.id,{value:!1});e.setValue(n,{value:i})}),i.addEventListener("resetform",e=>{const n=t.defaultFieldValue;e.target.checked=null!==n&&void 0!==n&&n===t.buttonValue}),this.enableScripting&&this.hasJSActions){const r=t.buttonValue;i.addEventListener("updatefromsandbox",t=>{const i={value:t=>{const i=r===t.detail.value;for(const r of this._getElementsByName(t.target.name)){const t=i&&r.id===n;r.domElement&&(r.domElement.checked=t),e.setValue(r.id,{value:t})}}};this._dispatchEventFromSandbox(i,t)}),this._setEventListeners(i,null,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],e=>e.target.checked)}return this._setBackgroundColor(i),this._setDefaultPropertiesFromJS(i),this.container.append(i),this.container}}class Ur extends Nr{constructor(e){super(e,{ignoreBorder:e.data.hasAppearance})}render(){const e=super.render();e.classList.add("buttonWidgetAnnotation","pushButton");const t=e.lastChild;return this.enableScripting&&this.hasJSActions&&t&&(this._setDefaultPropertiesFromJS(t),t.addEventListener("updatefromsandbox",e=>{this._dispatchEventFromSandbox({},e)})),e}}class Hr extends Or{constructor(e){super(e,{isRenderable:e.renderForms})}render(){this.container.classList.add("choiceWidgetAnnotation");const e=this.annotationStorage,t=this.data.id,n=e.getValue(t,{value:this.data.fieldValue}),r=document.createElement("select");Mr.add(r),r.setAttribute("data-element-id",t),r.disabled=this.data.readOnly,this._setRequired(r,this.data.required),r.name=this.data.fieldName,r.tabIndex=0;let i=this.data.combo&&this.data.options.length>0;this.data.combo||(r.size=this.data.options.length,this.data.multiSelect&&(r.multiple=!0)),r.addEventListener("resetform",e=>{const t=this.data.defaultFieldValue;for(const n of r.options)n.selected=n.value===t});for(const c of this.data.options){const e=document.createElement("option");e.textContent=c.displayValue,e.value=c.exportValue,n.value.includes(c.exportValue)&&(e.setAttribute("selected",!0),i=!1),r.append(e)}let s=null;if(i){const e=document.createElement("option");e.value=" ",e.setAttribute("hidden",!0),e.setAttribute("selected",!0),r.prepend(e),s=()=>{e.remove(),r.removeEventListener("input",s),s=null},r.addEventListener("input",s)}const a=e=>{const t=e?"value":"textContent",{options:n,multiple:i}=r;return i?Array.prototype.filter.call(n,e=>e.selected).map(e=>e[t]):-1===n.selectedIndex?null:n[n.selectedIndex][t]};let o=a(!1);const l=e=>{const t=e.target.options;return Array.prototype.map.call(t,e=>({displayValue:e.textContent,exportValue:e.value}))};return this.enableScripting&&this.hasJSActions?(r.addEventListener("updatefromsandbox",n=>{const i={value(n){s?.();const i=n.detail.value,l=new Set(Array.isArray(i)?i:[i]);for(const e of r.options)e.selected=l.has(e.value);e.setValue(t,{value:a(!0)}),o=a(!1)},multipleSelection(e){r.multiple=!0},remove(n){const i=r.options,s=n.detail.remove;if(i[s].selected=!1,r.remove(s),i.length>0){-1===Array.prototype.findIndex.call(i,e=>e.selected)&&(i[0].selected=!0)}e.setValue(t,{value:a(!0),items:l(n)}),o=a(!1)},clear(n){for(;0!==r.length;)r.remove(0);e.setValue(t,{value:null,items:[]}),o=a(!1)},insert(n){const{index:i,displayValue:s,exportValue:c}=n.detail.insert,h=r.children[i],d=document.createElement("option");d.textContent=s,d.value=c,h?h.before(d):r.append(d),e.setValue(t,{value:a(!0),items:l(n)}),o=a(!1)},items(n){const{items:i}=n.detail;for(;0!==r.length;)r.remove(0);for(const e of i){const{displayValue:t,exportValue:n}=e,i=document.createElement("option");i.textContent=t,i.value=n,r.append(i)}r.options.length>0&&(r.options[0].selected=!0),e.setValue(t,{value:a(!0),items:l(n)}),o=a(!1)},indices(n){const r=new Set(n.detail.indices);for(const e of n.target.options)e.selected=r.has(e.index);e.setValue(t,{value:a(!0)}),o=a(!1)},editable(e){e.target.disabled=!e.detail.editable}};this._dispatchEventFromSandbox(i,n)}),r.addEventListener("input",n=>{const r=a(!0),i=a(!1);e.setValue(t,{value:r}),n.preventDefault(),this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:t,name:"Keystroke",value:o,change:i,changeEx:r,willCommit:!1,commitKey:1,keyDown:!1}})}),this._setEventListeners(r,null,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"],["input","Action"],["input","Validate"]],e=>e.target.value)):r.addEventListener("input",function(n){e.setValue(t,{value:a(!0)})}),this.data.combo&&this._setTextStyle(r),this._setBackgroundColor(r),this._setDefaultPropertiesFromJS(r),this.container.append(r),this.container}}class Vr extends Fr{constructor(e){const{data:t,elements:n,parent:r}=e,i=!!r._commentManager;if(super(e,{isRenderable:!i&&Fr._hasPopupData(t)}),this.elements=n,i&&Fr._hasPopupData(t)){const e=this.popup=this.#gs();for(const t of n)t.popup=e}else this.popup=null}#gs(){return new qr({container:this.container,color:this.data.color,titleObj:this.data.titleObj,modificationDate:this.data.modificationDate||this.data.creationDate,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,commentManager:this.parent._commentManager})}render(){const{container:e}=this;e.classList.add("popupAnnotation"),e.role="comment";const t=this.popup=this.#gs(),n=[];for(const r of this.elements)r.popup=t,r.container.ariaHasPopup="dialog",n.push(r.data.id),r.addHighlightArea();return this.container.setAttribute("aria-controls",n.map(e=>`${ce}${e}`).join(",")),this.container}}class qr{#$=null;#vs=this.#is.bind(this);#ys=this.#bs.bind(this);#ws=this.#_s.bind(this);#As=this.#xs.bind(this);#Es=null;#_e=null;#Cs=null;#ks=null;#Ss=null;#Ts=null;#Ds=null;#Ms=!1;#Ps=null;#Is=null;#T=null;#Fs=null;#Rs=null;#pt=null;#Ns=null;#ct=null;#Ls=null;#cs=null;#Os=!1;#Bs=null;#$s=null;constructor(e){let{container:t,color:n,elements:r,titleObj:i,modificationDate:s,contentsObj:a,richText:o,parent:l,rect:c,parentRect:h,open:d,commentManager:u=null}=e;this.#_e=t,this.#Ls=i,this.#Cs=a,this.#ct=o,this.#Ts=l,this.#Es=n,this.#Ns=c,this.#Ds=h,this.#Ss=r,this.#$=u,this.#Bs=r[0],this.#ks=Ce.toDateObject(s),this.trigger=r.flatMap(e=>e.getElementsToTriggerPopup()),u?this.renderCommentButton():(this.#zs(),this.#_e.hidden=!0,d&&this.#xs())}#zs(){if(this.#Is)return;this.#Is=new AbortController;const{signal:e}=this.#Is;for(const t of this.trigger)t.addEventListener("click",this.#As,{signal:e}),t.addEventListener("pointerenter",this.#ws,{signal:e}),t.addEventListener("pointerleave",this.#ys,{signal:e}),t.classList.add("popupTriggerArea");for(const t of this.#Ss)t.container?.addEventListener("keydown",this.#vs,{signal:e})}#js(){const e=this.#Ss.find(e=>e.hasCommentButton);e&&(this.#Rs=e._normalizePoint(e.commentButtonPosition))}renderCommentButton(){if(this.#Fs)return;if(this.#Rs||this.#js(),!this.#Rs)return;const{signal:e}=this.#Is=new AbortController,t=!!this.#Bs.extraPopupElement,n=()=>{this.#$.toggleCommentPopup(this,!0,void 0,!t)},r=()=>{this.#$.toggleCommentPopup(this,!1,!0,!t)},i=()=>{this.#$.toggleCommentPopup(this,!1,!1)};if(t){this.#Fs=this.#Bs.container;for(const t of this.trigger)t.ariaHasPopup="dialog",t.ariaControls="commentPopup",t.addEventListener("keydown",this.#vs,{signal:e}),t.addEventListener("click",n,{signal:e}),t.addEventListener("pointerenter",r,{signal:e}),t.addEventListener("pointerleave",i,{signal:e}),t.classList.add("popupTriggerArea")}else{const t=this.#Fs=document.createElement("button");t.className="annotationCommentButton";const s=this.#Bs.container;t.style.zIndex=s.style.zIndex+1,t.tabIndex=0,t.ariaHasPopup="dialog",t.ariaControls="commentPopup",t.setAttribute("data-l10n-id","pdfjs-show-comment-button"),this.#Us(),this.#Hs(),t.addEventListener("keydown",this.#vs,{signal:e}),t.addEventListener("click",n,{signal:e}),t.addEventListener("pointerenter",r,{signal:e}),t.addEventListener("pointerleave",i,{signal:e}),s.after(t)}}#Hs(){if(this.#Bs.extraPopupElement&&!this.#Bs.editor)return;this.renderCommentButton();const[e,t]=this.#Rs,{style:n}=this.#Fs;n.left=`calc(${e}%)`,n.top=`calc(${t}% - var(--comment-button-dim))`}#Us(){this.#Bs.extraPopupElement||(this.renderCommentButton(),this.#Fs.style.backgroundColor=this.commentButtonColor||"")}get commentButtonColor(){const{color:e,opacity:t}=this.#Bs.commentData;return e?this.#Ts._commentManager.makeCommentColor(e,t):null}focusCommentButton(){setTimeout(()=>{this.#Fs?.focus()},0)}getData(){const{richText:e,color:t,opacity:n,creationDate:r,modificationDate:i}=this.#Bs.commentData;return{contentsObj:{str:this.comment},richText:e,color:t,opacity:n,creationDate:r,modificationDate:i}}get elementBeforePopup(){return this.#Fs}get comment(){return this.#$s||=this.#Bs.commentText,this.#$s}set comment(e){e!==this.comment&&(this.#Bs.commentText=this.#$s=e)}get parentBoundingClientRect(){return this.#Bs.layer.getBoundingClientRect()}setCommentButtonStates(e){let{selected:t,hasPopup:n}=e;this.#Fs&&(this.#Fs.classList.toggle("selected",t),this.#Fs.ariaExpanded=n)}setSelectedCommentButton(e){this.#Fs.classList.toggle("selected",e)}get commentPopupPosition(){if(this.#pt)return this.#pt;const{x:e,y:t,height:n}=this.#Fs.getBoundingClientRect(),{x:r,y:i,width:s,height:a}=this.#Bs.layer.getBoundingClientRect();return[(e-r)/s,(t+n-i)/a]}set commentPopupPosition(e){this.#pt=e}hasDefaultPopupPosition(){return null===this.#pt}get commentButtonPosition(){return this.#Rs}get commentButtonWidth(){return this.#Fs.getBoundingClientRect().width/this.parentBoundingClientRect.width}editComment(e){const[t,n]=this.#pt||this.commentButtonPosition.map(e=>e/100),r=this.parentBoundingClientRect,{x:i,y:s,width:a,height:o}=r;this.#$.showDialog(null,this,i+t*a,s+n*o,{...e,parentDimensions:r})}render(){if(this.#Ps)return;const e=this.#Ps=document.createElement("div");if(e.className="popup",this.#Es){const t=e.style.outlineColor=se.makeHexColor(...this.#Es);e.style.backgroundColor=`color-mix(in srgb, ${t} 30%, white)`}const t=document.createElement("span");if(t.className="header",this.#Ls?.str){const e=document.createElement("span");e.className="title",t.append(e),({dir:e.dir,str:e.textContent}=this.#Ls)}if(e.append(t),this.#ks){const e=document.createElement("time");e.className="popupDate",e.setAttribute("data-l10n-id","pdfjs-annotation-date-time-string"),e.setAttribute("data-l10n-args",JSON.stringify({dateObj:this.#ks.valueOf()})),e.dateTime=this.#ks.toISOString(),t.append(e)}Be({html:this.#Vs||this.#Cs.str,dir:this.#Cs?.dir,className:"popupContent"},e),this.#_e.append(e)}get#Vs(){const e=this.#ct,t=this.#Cs;return!e?.str||t?.str&&t.str!==e.str?null:this.#ct.html||null}get#qs(){return this.#Vs?.attributes?.style?.fontSize||0}get#Ws(){return this.#Vs?.attributes?.style?.color||null}#Gs(e){const t=[],n={str:e,html:{name:"div",attributes:{dir:"auto"},children:[{name:"p",children:t}]}},r={style:{color:this.#Ws,fontSize:this.#qs?`calc(${this.#qs}px * var(--total-scale-factor))`:""}};for(const i of e.split("\n"))t.push({name:"span",value:i,attributes:r});return n}#is(e){e.altKey||e.shiftKey||e.ctrlKey||e.metaKey||("Enter"===e.key||"Escape"===e.key&&this.#Ms)&&this.#xs()}updateEdited(e){let{rect:t,popup:n,deleted:r}=e;if(this.#$)return r?(this.remove(),this.#$s=null):n&&(n.deleted?this.remove():(this.#Us(),this.#$s=n.text)),void(t&&(this.#Rs=null,this.#js(),this.#Hs()));r||n?.deleted?this.remove():(this.#zs(),this.#cs||={contentsObj:this.#Cs,richText:this.#ct},t&&(this.#T=null),n&&n.text&&(this.#ct=this.#Gs(n.text),this.#ks=Ce.toDateObject(n.date),this.#Cs=null),this.#Ps?.remove(),this.#Ps=null)}resetEdited(){this.#cs&&(({contentsObj:this.#Cs,richText:this.#ct}=this.#cs),this.#cs=null,this.#Ps?.remove(),this.#Ps=null,this.#T=null)}remove(){if(this.#Is?.abort(),this.#Is=null,this.#Ps?.remove(),this.#Ps=null,this.#Os=!1,this.#Ms=!1,this.#Fs?.remove(),this.#Fs=null,this.trigger)for(const e of this.trigger)e.classList.remove("popupTriggerArea")}#Ks(){if(null!==this.#T)return;const{page:{view:e},viewport:{rawDims:{pageWidth:t,pageHeight:n,pageX:r,pageY:i}}}=this.#Ts;let s=!!this.#Ds,a=s?this.#Ds:this.#Ns;for(const u of this.#Ss)if(!a||null!==se.intersect(u.data.rect,a)){a=u.data.rect,s=!0;break}const o=se.normalizeRect([a[0],e[3]-a[1]+e[1],a[2],e[3]-a[3]+e[1]]),l=s?a[2]-a[0]+5:0,c=o[0]+l,h=o[1];this.#T=[100*(c-r)/t,100*(h-i)/n];const{style:d}=this.#_e;d.left=`${this.#T[0]}%`,d.top=`${this.#T[1]}%`}#xs(){this.#$?this.#$.toggleCommentPopup(this,!1):(this.#Ms=!this.#Ms,this.#Ms?(this.#_s(),this.#_e.addEventListener("click",this.#As),this.#_e.addEventListener("keydown",this.#vs)):(this.#bs(),this.#_e.removeEventListener("click",this.#As),this.#_e.removeEventListener("keydown",this.#vs)))}#_s(){this.#Ps||this.render(),this.isVisible?this.#Ms&&this.#_e.classList.add("focused"):(this.#Ks(),this.#_e.hidden=!1,this.#_e.style.zIndex=parseInt(this.#_e.style.zIndex)+1e3)}#bs(){this.#_e.classList.remove("focused"),!this.#Ms&&this.isVisible&&(this.#_e.hidden=!0,this.#_e.style.zIndex=parseInt(this.#_e.style.zIndex)-1e3)}forceHide(){this.#Os=this.isVisible,this.#Os&&(this.#_e.hidden=!0)}maybeShow(){this.#$||(this.#zs(),this.#Os&&(this.#Ps||this.#_s(),this.#Os=!1,this.#_e.hidden=!1))}get isVisible(){return!this.#$&&!1===this.#_e.hidden}}class Wr extends Fr{constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0}),this.textContent=e.data.textContent,this.textPosition=e.data.textPosition,this.annotationEditorType=v.FREETEXT}render(){if(this.container.classList.add("freeTextAnnotation"),this.textContent){const e=document.createElement("div");e.classList.add("annotationTextContent"),e.setAttribute("role","comment");for(const t of this.textContent){const n=document.createElement("span");n.textContent=t,e.append(n)}this.container.append(e)}return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this._editOnDoubleClick(),this.container}}class Gr extends Fr{#Xs=null;constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0})}render(){this.container.classList.add("lineAnnotation");const{data:e,width:t,height:n}=this,r=this.svgFactory.create(t,n,!0),i=this.#Xs=this.svgFactory.createElement("svg:line");return i.setAttribute("x1",e.rect[2]-e.lineCoordinates[0]),i.setAttribute("y1",e.rect[3]-e.lineCoordinates[1]),i.setAttribute("x2",e.rect[2]-e.lineCoordinates[2]),i.setAttribute("y2",e.rect[3]-e.lineCoordinates[3]),i.setAttribute("stroke-width",e.borderStyle.width||1),i.setAttribute("stroke","transparent"),i.setAttribute("fill","transparent"),r.append(i),this.container.append(r),!e.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return this.#Xs}addHighlightArea(){this.container.classList.add("highlightArea")}}class Kr extends Fr{#Ys=null;constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0})}render(){this.container.classList.add("squareAnnotation");const{data:e,width:t,height:n}=this,r=this.svgFactory.create(t,n,!0),i=e.borderStyle.width,s=this.#Ys=this.svgFactory.createElement("svg:rect");return s.setAttribute("x",i/2),s.setAttribute("y",i/2),s.setAttribute("width",t-i),s.setAttribute("height",n-i),s.setAttribute("stroke-width",i||1),s.setAttribute("stroke","transparent"),s.setAttribute("fill","transparent"),r.append(s),this.container.append(r),!e.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return this.#Ys}addHighlightArea(){this.container.classList.add("highlightArea")}}class Xr extends Fr{#Zs=null;constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0})}render(){this.container.classList.add("circleAnnotation");const{data:e,width:t,height:n}=this,r=this.svgFactory.create(t,n,!0),i=e.borderStyle.width,s=this.#Zs=this.svgFactory.createElement("svg:ellipse");return s.setAttribute("cx",t/2),s.setAttribute("cy",n/2),s.setAttribute("rx",t/2-i/2),s.setAttribute("ry",n/2-i/2),s.setAttribute("stroke-width",i||1),s.setAttribute("stroke","transparent"),s.setAttribute("fill","transparent"),r.append(s),this.container.append(r),!e.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return this.#Zs}addHighlightArea(){this.container.classList.add("highlightArea")}}class Yr extends Fr{#Js=null;constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0}),this.containerClassName="polylineAnnotation",this.svgElementName="svg:polyline"}render(){this.container.classList.add(this.containerClassName);const{data:{rect:e,vertices:t,borderStyle:n,popupRef:r},width:i,height:s}=this;if(!t)return this.container;const a=this.svgFactory.create(i,s,!0);let o=[];for(let c=0,h=t.length;c<h;c+=2){const n=t[c]-e[0],r=e[3]-t[c+1];o.push(`${n},${r}`)}o=o.join(" ");const l=this.#Js=this.svgFactory.createElement(this.svgElementName);return l.setAttribute("points",o),l.setAttribute("stroke-width",n.width||1),l.setAttribute("stroke","transparent"),l.setAttribute("fill","transparent"),a.append(l),this.container.append(a),!r&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return this.#Js}addHighlightArea(){this.container.classList.add("highlightArea")}}class Zr extends Yr{constructor(e){super(e),this.containerClassName="polygonAnnotation",this.svgElementName="svg:polygon"}}class Jr extends Fr{constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0})}render(){return this.container.classList.add("caretAnnotation"),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container}}class Qr extends Fr{#Qs=null;#ea=[];constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0}),this.containerClassName="inkAnnotation",this.svgElementName="svg:polyline",this.annotationEditorType="InkHighlight"===this.data.it?v.HIGHLIGHT:v.INK}#ta(e,t){switch(e){case 90:return{transform:`rotate(90) translate(${-t[0]},${t[1]}) scale(1,-1)`,width:t[3]-t[1],height:t[2]-t[0]};case 180:return{transform:`rotate(180) translate(${-t[2]},${t[1]}) scale(1,-1)`,width:t[2]-t[0],height:t[3]-t[1]};case 270:return{transform:`rotate(270) translate(${-t[2]},${t[3]}) scale(1,-1)`,width:t[3]-t[1],height:t[2]-t[0]};default:return{transform:`translate(${-t[0]},${t[3]}) scale(1,-1)`,width:t[2]-t[0],height:t[3]-t[1]}}}render(){this.container.classList.add(this.containerClassName);const{data:{rect:e,rotation:t,inkLists:n,borderStyle:r,popupRef:i}}=this,{transform:s,width:a,height:o}=this.#ta(t,e),l=this.svgFactory.create(a,o,!0),c=this.#Qs=this.svgFactory.createElement("svg:g");l.append(c),c.setAttribute("stroke-width",r.width||1),c.setAttribute("stroke-linecap","round"),c.setAttribute("stroke-linejoin","round"),c.setAttribute("stroke-miterlimit",10),c.setAttribute("stroke","transparent"),c.setAttribute("fill","transparent"),c.setAttribute("transform",s);for(let h=0,d=n.length;h<d;h++){const e=this.svgFactory.createElement(this.svgElementName);this.#ea.push(e),e.setAttribute("points",n[h].join(",")),c.append(e)}return!i&&this.hasPopupData&&this._createPopup(),this.container.append(l),this._editOnDoubleClick(),this.container}updateEdited(e){super.updateEdited(e);const{thickness:t,points:n,rect:r}=e,i=this.#Qs;if(t>=0&&i.setAttribute("stroke-width",t||1),n)for(let s=0,a=this.#ea.length;s<a;s++)this.#ea[s].setAttribute("points",n[s].join(","));if(r){const{transform:e,width:t,height:n}=this.#ta(this.data.rotation,r);i.parentElement.setAttribute("viewBox",`0 0 ${t} ${n}`),i.setAttribute("transform",e)}}getElementsToTriggerPopup(){return this.#ea}addHighlightArea(){this.container.classList.add("highlightArea")}}class ei extends Fr{constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0}),this.annotationEditorType=v.HIGHLIGHT}render(){const{data:{overlaidText:e,popupRef:t}}=this;if(!t&&this.hasPopupData&&this._createPopup(),this.container.classList.add("highlightAnnotation"),this._editOnDoubleClick(),e){const t=document.createElement("mark");t.classList.add("overlaidText"),t.textContent=e,this.container.append(t)}return this.container}}class ti extends Fr{constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){const{data:{overlaidText:e,popupRef:t}}=this;if(!t&&this.hasPopupData&&this._createPopup(),this.container.classList.add("underlineAnnotation"),e){const t=document.createElement("u");t.classList.add("overlaidText"),t.textContent=e,this.container.append(t)}return this.container}}class ni extends Fr{constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){const{data:{overlaidText:e,popupRef:t}}=this;if(!t&&this.hasPopupData&&this._createPopup(),this.container.classList.add("squigglyAnnotation"),e){const t=document.createElement("u");t.classList.add("overlaidText"),t.textContent=e,this.container.append(t)}return this.container}}class ri extends Fr{constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){const{data:{overlaidText:e,popupRef:t}}=this;if(!t&&this.hasPopupData&&this._createPopup(),this.container.classList.add("strikeoutAnnotation"),e){const t=document.createElement("s");t.classList.add("overlaidText"),t.textContent=e,this.container.append(t)}return this.container}}class ii extends Fr{constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0}),this.annotationEditorType=v.STAMP}render(){return this.container.classList.add("stampAnnotation"),this.container.setAttribute("role","img"),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this._editOnDoubleClick(),this.container}}class si extends Fr{#na=null;constructor(e){super(e,{isRenderable:!0});const{file:t}=this.data;this.filename=t.filename,this.content=t.content,this.linkService.eventBus?.dispatch("fileattachmentannotation",{source:this,...t})}render(){this.container.classList.add("fileAttachmentAnnotation");const{container:e,data:t}=this;let n;t.hasAppearance||0===t.fillAlpha?n=document.createElement("div"):(n=document.createElement("img"),n.src=`${this.imageResourcesPath}annotation-${/paperclip/i.test(t.name)?"paperclip":"pushpin"}.svg`,t.fillAlpha&&t.fillAlpha<1&&(n.style=`filter: opacity(${Math.round(100*t.fillAlpha)}%);`)),n.addEventListener("dblclick",this.#ra.bind(this)),this.#na=n;const{isMac:r}=re.platform;return e.addEventListener("keydown",e=>{"Enter"===e.key&&(r?e.metaKey:e.ctrlKey)&&this.#ra()}),!t.popupRef&&this.hasPopupData?this._createPopup():n.classList.add("popupTriggerArea"),e.append(n),e}getElementsToTriggerPopup(){return this.#na}addHighlightArea(){this.container.classList.add("highlightArea")}#ra(){this.downloadManager?.openOrDownloadData(this.content,this.filename)}}class ai{#ia=null;#sa=null;#L=null;#aa=(()=>new Map)();#oa=null;#la=null;constructor(e){let{div:t,accessibilityManager:n,annotationCanvasMap:r,annotationEditorUIManager:i,page:s,viewport:a,structTreeLayer:o,commentManager:l,linkService:c,annotationStorage:h}=e;this.div=t,this.#ia=n,this.#sa=r,this.#oa=o||null,this.#la=c||null,this.#L=h||new it,this.page=s,this.viewport=a,this.zIndex=0,this._annotationEditorUIManager=i,this._commentManager=l||null}hasEditableAnnotations(){return this.#aa.size>0}async#ca(e,t,n){const r=e.firstChild||e,i=r.id=`${ce}${t}`,s=await(this.#oa?.getAriaAttributes(i));if(s)for(const[a,o]of s)r.setAttribute(a,o);n?n.at(-1).container.after(e):(this.div.append(e),this.#ia?.moveElementInDOM(this.div,e,r,!1))}async render(e){const{annotations:t}=e,n=this.div;De(n,this.viewport);const r=new Map,i={data:null,layer:n,linkService:this.#la,downloadManager:e.downloadManager,imageResourcesPath:e.imageResourcesPath||"",renderForms:!1!==e.renderForms,svgFactory:new Dr,annotationStorage:this.#L,enableComment:!0===e.enableComment,enableScripting:!0===e.enableScripting,hasJSActions:e.hasJSActions,fieldObjects:e.fieldObjects,parent:this,elements:null};for(const s of t){if(s.noHTML)continue;const e=s.annotationType===k.POPUP;if(e){const e=r.get(s.id);if(!e)continue;i.elements=e}else if(s.rect[2]===s.rect[0]||s.rect[3]===s.rect[1])continue;i.data=s;const t=Ir.create(i);if(!t.isRenderable)continue;if(!e&&s.popupRef){const e=r.get(s.popupRef);e?e.push(t):r.set(s.popupRef,[t])}const n=t.render();s.hidden&&(n.style.visibility="hidden"),await this.#ca(n,s.id,i.elements),t.extraPopupElement?.popup?.renderCommentButton(),t._isEditable&&(this.#aa.set(t.data.id,t),this._annotationEditorUIManager?.renderAnnotationElement(t))}this.#ha()}async addLinkAnnotations(e){const t={data:null,layer:this.div,linkService:this.#la,svgFactory:new Dr,parent:this};for(const n of e){n.borderStyle||=ai._defaultBorderStyle,t.data=n;const e=Ir.create(t);if(!e.isRenderable)continue;const r=e.render();await this.#ca(r,n.id,null)}}update(e){let{viewport:t}=e;const n=this.div;this.viewport=t,De(n,{rotation:t.rotation}),this.#ha(),n.hidden=!1}#ha(){if(!this.#sa)return;const e=this.div;for(const[t,n]of this.#sa){const r=e.querySelector(`[data-annotation-id="${t}"]`);if(!r)continue;n.className="annotationContent";const{firstChild:i}=r;i?"CANVAS"===i.nodeName?i.replaceWith(n):i.classList.contains("annotationContent")?i.after(n):i.before(n):r.append(n);const s=this.#aa.get(t);s&&(s._hasNoCanvas?(this._annotationEditorUIManager?.setMissingCanvas(t,r.id,n),s._hasNoCanvas=!1):s.canvas=n)}this.#sa.clear()}getEditableAnnotations(){return Array.from(this.#aa.values())}getEditableAnnotation(e){return this.#aa.get(e)}addFakeAnnotation(e){const{div:t}=this,{id:n,rotation:r}=e,i=new Rr({data:{id:n,rect:e.getPDFRect(),rotation:r},editor:e,layer:t,parent:this,enableComment:!!this._commentManager,linkService:this.#la,annotationStorage:this.#L}),s=i.render();return t.append(s),this.#ia?.moveElementInDOM(t,s,s,!1),i.createOrUpdatePopup(),i}static get _defaultBorderStyle(){return G(this,"_defaultBorderStyle",Object.freeze({width:1,rawWidth:1,style:S,dashArray:[3],horizontalCornerRadius:0,verticalCornerRadius:0}))}}const oi=/\r\n?|\n/g;class li extends Ze{#da="";#ua=`${this.id}-editor`;#pa=null;#qs;_colorPicker=null;static _freeTextDefaultContent="";static _internalPadding=0;static _defaultColor=null;static _defaultFontSize=10;static get _keyboardManager(){const e=li.prototype,t=e=>e.isEmpty(),n=Ge.TRANSLATE_SMALL,r=Ge.TRANSLATE_BIG;return G(this,"_keyboardManager",new qe([[["ctrl+s","mac+meta+s","ctrl+p","mac+meta+p"],e.commitOrRemove,{bubbles:!0}],[["ctrl+Enter","mac+meta+Enter","Escape","mac+Escape"],e.commitOrRemove],[["ArrowLeft","mac+ArrowLeft"],e._translateEmpty,{args:[-n,0],checker:t}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],e._translateEmpty,{args:[-r,0],checker:t}],[["ArrowRight","mac+ArrowRight"],e._translateEmpty,{args:[n,0],checker:t}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],e._translateEmpty,{args:[r,0],checker:t}],[["ArrowUp","mac+ArrowUp"],e._translateEmpty,{args:[0,-n],checker:t}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],e._translateEmpty,{args:[0,-r],checker:t}],[["ArrowDown","mac+ArrowDown"],e._translateEmpty,{args:[0,n],checker:t}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],e._translateEmpty,{args:[0,r],checker:t}]]))}static _type="freetext";static _editorType=(()=>v.FREETEXT)();constructor(e){super({...e,name:"freeTextEditor"}),this.color=e.color||li._defaultColor||Ze._defaultLineColor,this.#qs=e.fontSize||li._defaultFontSize,this.annotationElementId||this._uiManager.a11yAlert("pdfjs-editor-freetext-added-alert")}static initialize(e,t){Ze.initialize(e,t);const n=getComputedStyle(document.documentElement);this._internalPadding=parseFloat(n.getPropertyValue("--freetext-padding"))}static updateDefaultParams(e,t){switch(e){case y.FREETEXT_SIZE:li._defaultFontSize=t;break;case y.FREETEXT_COLOR:li._defaultColor=t}}updateParams(e,t){switch(e){case y.FREETEXT_SIZE:this.#fa(t);break;case y.FREETEXT_COLOR:this.#Us(t)}}static get defaultPropertiesToUpdate(){return[[y.FREETEXT_SIZE,li._defaultFontSize],[y.FREETEXT_COLOR,li._defaultColor||Ze._defaultLineColor]]}get propertiesToUpdate(){return[[y.FREETEXT_SIZE,this.#qs],[y.FREETEXT_COLOR,this.color]]}get toolbarButtons(){return this._colorPicker||=new Er(this),[["colorPicker",this._colorPicker]]}get colorType(){return y.FREETEXT_COLOR}#fa(e){const t=e=>{this.editorDiv.style.fontSize=`calc(${e}px * var(--total-scale-factor))`,this.translate(0,-(e-this.#qs)*this.parentScale),this.#qs=e,this.#ma()},n=this.#qs;this.addCommands({cmd:t.bind(this,e),undo:t.bind(this,n),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:y.FREETEXT_SIZE,overwriteIfSameType:!0,keepUndo:!0})}onUpdatedColor(){this.editorDiv.style.color=this.color,this._colorPicker?.update(this.color),super.onUpdatedColor()}#Us(e){const t=e=>{this.color=e,this.onUpdatedColor()},n=this.color;this.addCommands({cmd:t.bind(this,e),undo:t.bind(this,n),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:y.FREETEXT_COLOR,overwriteIfSameType:!0,keepUndo:!0})}_translateEmpty(e,t){this._uiManager.translateSelectedEditors(e,t,!0)}getInitialTranslation(){const e=this.parentScale;return[-li._internalPadding*e,-(li._internalPadding+this.#qs)*e]}rebuild(){this.parent&&(super.rebuild(),null!==this.div&&(this.isAttachedToDOM||this.parent.add(this)))}enableEditMode(){if(!super.enableEditMode())return!1;this.overlayDiv.classList.remove("enabled"),this.editorDiv.contentEditable=!0,this._isDraggable=!1,this.div.removeAttribute("aria-activedescendant"),this.#pa=new AbortController;const e=this._uiManager.combinedSignal(this.#pa);return this.editorDiv.addEventListener("keydown",this.editorDivKeydown.bind(this),{signal:e}),this.editorDiv.addEventListener("focus",this.editorDivFocus.bind(this),{signal:e}),this.editorDiv.addEventListener("blur",this.editorDivBlur.bind(this),{signal:e}),this.editorDiv.addEventListener("input",this.editorDivInput.bind(this),{signal:e}),this.editorDiv.addEventListener("paste",this.editorDivPaste.bind(this),{signal:e}),!0}disableEditMode(){return!!super.disableEditMode()&&(this.overlayDiv.classList.add("enabled"),this.editorDiv.contentEditable=!1,this.div.setAttribute("aria-activedescendant",this.#ua),this._isDraggable=!0,this.#pa?.abort(),this.#pa=null,this.div.focus({preventScroll:!0}),this.isEditing=!1,this.parent.div.classList.add("freetextEditing"),!0)}focusin(e){this._focusEventsAllowed&&(super.focusin(e),e.target!==this.editorDiv&&this.editorDiv.focus())}onceAdded(e){this.width||(this.enableEditMode(),e&&this.editorDiv.focus(),this._initialOptions?.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()}#ga(){const e=[];this.editorDiv.normalize();let t=null;for(const n of this.editorDiv.childNodes)t?.nodeType===Node.TEXT_NODE&&"BR"===n.nodeName||(e.push(li.#va(n)),t=n);return e.join("\n")}#ma(){const[e,t]=this.parentDimensions;let n;if(this.isAttachedToDOM)n=this.div.getBoundingClientRect();else{const{currentLayer:e,div:t}=this,r=t.style.display,i=t.classList.contains("hidden");t.classList.remove("hidden"),t.style.display="hidden",e.div.append(this.div),n=t.getBoundingClientRect(),t.remove(),t.style.display=r,t.classList.toggle("hidden",i)}this.rotation%180===this.parentRotation%180?(this.width=n.width/e,this.height=n.height/t):(this.width=n.height/e,this.height=n.width/t),this.fixAndSetPosition()}commit(){if(!this.isInEditMode())return;super.commit(),this.disableEditMode();const e=this.#da,t=this.#da=this.#ga().trimEnd();if(e===t)return;const n=e=>{this.#da=e,e?(this.#ya(),this._uiManager.rebuild(this),this.#ma()):this.remove()};this.addCommands({cmd:()=>{n(t)},undo:()=>{n(e)},mustExec:!1}),this.#ma()}shouldGetKeyboardEvents(){return this.isInEditMode()}enterInEditMode(){this.enableEditMode(),this.editorDiv.focus()}keydown(e){e.target===this.div&&"Enter"===e.key&&(this.enterInEditMode(),e.preventDefault())}editorDivKeydown(e){li._keyboardManager.exec(this,e)}editorDivFocus(e){this.isEditing=!0}editorDivBlur(e){this.isEditing=!1}editorDivInput(e){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)}get canChangeContent(){return!0}render(){if(this.div)return this.div;let e,t;(this._isCopy||this.annotationElementId)&&(e=this.x,t=this.y),super.render(),this.editorDiv=document.createElement("div"),this.editorDiv.className="internal",this.editorDiv.setAttribute("id",this.#ua),this.editorDiv.setAttribute("data-l10n-id","pdfjs-free-text2"),this.editorDiv.setAttribute("data-l10n-attrs","default-content"),this.enableEditing(),this.editorDiv.contentEditable=!0;const{style:n}=this.editorDiv;if(n.fontSize=`calc(${this.#qs}px * var(--total-scale-factor))`,n.color=this.color,this.div.append(this.editorDiv),this.overlayDiv=document.createElement("div"),this.overlayDiv.classList.add("overlay","enabled"),this.div.append(this.overlayDiv),this._isCopy||this.annotationElementId){const[n,r]=this.parentDimensions;if(this.annotationElementId){const{position:i}=this._initialData;let[s,a]=this.getInitialTranslation();[s,a]=this.pageTranslationToScreen(s,a);const[o,l]=this.pageDimensions,[c,h]=this.pageTranslation;let d,u;switch(this.rotation){case 0:d=e+(i[0]-c)/o,u=t+this.height-(i[1]-h)/l;break;case 90:d=e+(i[0]-c)/o,u=t-(i[1]-h)/l,[s,a]=[a,-s];break;case 180:d=e-this.width+(i[0]-c)/o,u=t-(i[1]-h)/l,[s,a]=[-s,-a];break;case 270:d=e+(i[0]-c-this.height*l)/o,u=t+(i[1]-h-this.width*o)/l,[s,a]=[-a,s]}this.setAt(d*n,u*r,s,a)}else this._moveAfterPaste(e,t);this.#ya(),this._isDraggable=!0,this.editorDiv.contentEditable=!1}else this._isDraggable=!1,this.editorDiv.contentEditable=!0;return this.div}static#va(e){return(e.nodeType===Node.TEXT_NODE?e.nodeValue:e.innerText).replaceAll(oi,"")}editorDivPaste(e){const t=e.clipboardData||window.clipboardData,{types:n}=t;if(1===n.length&&"text/plain"===n[0])return;e.preventDefault();const r=li.#ba(t.getData("text")||"").replaceAll(oi,"\n");if(!r)return;const i=window.getSelection();if(!i.rangeCount)return;this.editorDiv.normalize(),i.deleteFromDocument();const s=i.getRangeAt(0);if(!r.includes("\n"))return s.insertNode(document.createTextNode(r)),this.editorDiv.normalize(),void i.collapseToStart();const{startContainer:a,startOffset:o}=s,l=[],c=[];if(a.nodeType===Node.TEXT_NODE){const e=a.parentElement;if(c.push(a.nodeValue.slice(o).replaceAll(oi,"")),e!==this.editorDiv){let t=l;for(const n of this.editorDiv.childNodes)n!==e?t.push(li.#va(n)):t=c}l.push(a.nodeValue.slice(0,o).replaceAll(oi,""))}else if(a===this.editorDiv){let e=l,t=0;for(const n of this.editorDiv.childNodes)t++===o&&(e=c),e.push(li.#va(n))}this.#da=`${l.join("\n")}${r}${c.join("\n")}`,this.#ya();const h=new Range;let d=Math.sumPrecise(l.map(e=>e.length));for(const{firstChild:u}of this.editorDiv.childNodes)if(u.nodeType===Node.TEXT_NODE){const e=u.nodeValue.length;if(d<=e){h.setStart(u,d),h.setEnd(u,d);break}d-=e}i.removeAllRanges(),i.addRange(h)}#ya(){if(this.editorDiv.replaceChildren(),this.#da)for(const e of this.#da.split("\n")){const t=document.createElement("div");t.append(e?document.createTextNode(e):document.createElement("br")),this.editorDiv.append(t)}}#wa(){return this.#da.replaceAll("\xa0"," ")}static#ba(e){return e.replaceAll(" ","\xa0")}get contentDiv(){return this.editorDiv}getPDFRect(){const e=li._internalPadding*this.parentScale;return this.getRect(e,e)}static async deserialize(e,t,n){let r=null;if(e instanceof Wr){const{data:{defaultAppearanceData:{fontSize:t,fontColor:n},rect:i,rotation:s,id:a,popupRef:o,richText:l,contentsObj:c,creationDate:h,modificationDate:d},textContent:u,textPosition:p,parent:{page:{pageNumber:f}}}=e;if(!u||0===u.length)return null;r=e={annotationType:v.FREETEXT,color:Array.from(n),fontSize:t,value:u.join("\n"),position:p,pageIndex:f-1,rect:i.slice(0),rotation:s,annotationElementId:a,id:a,deleted:!1,popupRef:o,comment:c?.str||null,richText:l,creationDate:h,modificationDate:d}}const i=await super.deserialize(e,t,n);return i.#qs=e.fontSize,i.color=se.makeHexColor(...e.color),i.#da=li.#ba(e.value),i._initialData=r,e.comment&&i.setCommentData(e),i}serialize(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.isEmpty())return null;if(this.deleted)return this.serializeDeleted();const t=Ze._colorManager.convert(this.isAttachedToDOM?getComputedStyle(this.editorDiv).color:this.color),n=Object.assign(super.serialize(e),{color:t,fontSize:this.#qs,value:this.#wa()});return this.addComment(n),e?(n.isCopy=!0,n):this.annotationElementId&&!this.#_a(n)?null:(n.id=this.annotationElementId,n)}#_a(e){const{value:t,fontSize:n,color:r,pageIndex:i}=this._initialData;return this.hasEditedComment||this._hasBeenMoved||e.value!==t||e.fontSize!==n||e.color.some((e,t)=>e!==r[t])||e.pageIndex!==i}renderAnnotationElement(e){const t=super.renderAnnotationElement(e);if(!t)return null;const{style:n}=t;n.fontSize=`calc(${this.#qs}px * var(--total-scale-factor))`,n.color=this.color,t.replaceChildren();for(const r of this.#da.split("\n")){const e=document.createElement("div");e.append(r?document.createTextNode(r):document.createElement("br")),t.append(e)}return e.updateEdited({rect:this.getPDFRect(),popup:this._uiManager.hasCommentManager()||this.hasEditedComment?this.comment:{text:this.#da}}),t}resetAnnotationElement(e){super.resetAnnotationElement(e),e.resetEdited()}}class ci{static PRECISION=1e-4;toSVGPath(){H("Abstract method `toSVGPath` must be implemented.")}get box(){H("Abstract getter `box` must be implemented.")}serialize(e,t){H("Abstract method `serialize` must be implemented.")}static _rescale(e,t,n,r,i,s){s||=new Float32Array(e.length);for(let a=0,o=e.length;a<o;a+=2)s[a]=t+e[a]*r,s[a+1]=n+e[a+1]*i;return s}static _rescaleAndSwap(e,t,n,r,i,s){s||=new Float32Array(e.length);for(let a=0,o=e.length;a<o;a+=2)s[a]=t+e[a+1]*r,s[a+1]=n+e[a]*i;return s}static _translate(e,t,n,r){r||=new Float32Array(e.length);for(let i=0,s=e.length;i<s;i+=2)r[i]=t+e[i],r[i+1]=n+e[i+1];return r}static svgRound(e){return Math.round(1e4*e)}static _normalizePoint(e,t,n,r,i){switch(i){case 90:return[1-t/n,e/r];case 180:return[1-e/n,1-t/r];case 270:return[t/n,1-e/r];default:return[e/n,t/r]}}static _normalizePagePoint(e,t,n){switch(n){case 90:return[1-t,e];case 180:return[1-e,1-t];case 270:return[t,1-e];default:return[e,t]}}static createBezierPoints(e,t,n,r,i,s){return[(e+5*n)/6,(t+5*r)/6,(5*n+i)/6,(5*r+s)/6,(n+i)/2,(r+s)/2]}}class hi{#Aa;#xa=[];#Ea;#Ca;#ka=[];#Sa=(()=>new Float32Array(18))();#Ta;#Da;#Ma;#Pa;#Ia;#Fa;#Ra=[];static#Na=8;static#La=2;static#Oa=(()=>hi.#Na+hi.#La)();constructor(e,t,n,r,i){let{x:s,y:a}=e,o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0;this.#Aa=t,this.#Fa=r*n,this.#Ca=i,this.#Sa.set([NaN,NaN,NaN,NaN,s,a],6),this.#Ea=o,this.#Pa=hi.#Na*n,this.#Ma=hi.#Oa*n,this.#Ia=n,this.#Ra.push(s,a)}isEmpty(){return isNaN(this.#Sa[8])}#Ba(){const e=this.#Sa.subarray(4,6),t=this.#Sa.subarray(16,18),[n,r,i,s]=this.#Aa;return[(this.#Ta+(e[0]-t[0])/2-n)/i,(this.#Da+(e[1]-t[1])/2-r)/s,(this.#Ta+(t[0]-e[0])/2-n)/i,(this.#Da+(t[1]-e[1])/2-r)/s]}add(e){let{x:t,y:n}=e;this.#Ta=t,this.#Da=n;const[r,i,s,a]=this.#Aa;let[o,l,c,h]=this.#Sa.subarray(8,12);const d=t-c,u=n-h,p=Math.hypot(d,u);if(p<this.#Ma)return!1;const f=p-this.#Pa,m=f/p,g=m*d,v=m*u;let y=o,b=l;o=c,l=h,c+=g,h+=v,this.#Ra?.push(t,n);const w=g/f,_=-v/f*this.#Fa,A=w*this.#Fa;if(this.#Sa.set(this.#Sa.subarray(2,8),0),this.#Sa.set([c+_,h+A],4),this.#Sa.set(this.#Sa.subarray(14,18),12),this.#Sa.set([c-_,h-A],16),isNaN(this.#Sa[6]))return 0===this.#ka.length&&(this.#Sa.set([o+_,l+A],2),this.#ka.push(NaN,NaN,NaN,NaN,(o+_-r)/s,(l+A-i)/a),this.#Sa.set([o-_,l-A],14),this.#xa.push(NaN,NaN,NaN,NaN,(o-_-r)/s,(l-A-i)/a)),this.#Sa.set([y,b,o,l,c,h],6),!this.isEmpty();this.#Sa.set([y,b,o,l,c,h],6);return Math.abs(Math.atan2(b-l,y-o)-Math.atan2(v,g))<Math.PI/2?([o,l,c,h]=this.#Sa.subarray(2,6),this.#ka.push(NaN,NaN,NaN,NaN,((o+c)/2-r)/s,((l+h)/2-i)/a),[o,l,y,b]=this.#Sa.subarray(14,18),this.#xa.push(NaN,NaN,NaN,NaN,((y+o)/2-r)/s,((b+l)/2-i)/a),!0):([y,b,o,l,c,h]=this.#Sa.subarray(0,6),this.#ka.push(((y+5*o)/6-r)/s,((b+5*l)/6-i)/a,((5*o+c)/6-r)/s,((5*l+h)/6-i)/a,((o+c)/2-r)/s,((l+h)/2-i)/a),[c,h,o,l,y,b]=this.#Sa.subarray(12,18),this.#xa.push(((y+5*o)/6-r)/s,((b+5*l)/6-i)/a,((5*o+c)/6-r)/s,((5*l+h)/6-i)/a,((o+c)/2-r)/s,((l+h)/2-i)/a),!0)}toSVGPath(){if(this.isEmpty())return"";const e=this.#ka,t=this.#xa;if(isNaN(this.#Sa[6])&&!this.isEmpty())return this.#$a();const n=[];n.push(`M${e[4]} ${e[5]}`);for(let r=6;r<e.length;r+=6)isNaN(e[r])?n.push(`L${e[r+4]} ${e[r+5]}`):n.push(`C${e[r]} ${e[r+1]} ${e[r+2]} ${e[r+3]} ${e[r+4]} ${e[r+5]}`);this.#za(n);for(let r=t.length-6;r>=6;r-=6)isNaN(t[r])?n.push(`L${t[r+4]} ${t[r+5]}`):n.push(`C${t[r]} ${t[r+1]} ${t[r+2]} ${t[r+3]} ${t[r+4]} ${t[r+5]}`);return this.#ja(n),n.join(" ")}#$a(){const[e,t,n,r]=this.#Aa,[i,s,a,o]=this.#Ba();return`M${(this.#Sa[2]-e)/n} ${(this.#Sa[3]-t)/r} L${(this.#Sa[4]-e)/n} ${(this.#Sa[5]-t)/r} L${i} ${s} L${a} ${o} L${(this.#Sa[16]-e)/n} ${(this.#Sa[17]-t)/r} L${(this.#Sa[14]-e)/n} ${(this.#Sa[15]-t)/r} Z`}#ja(e){const t=this.#xa;e.push(`L${t[4]} ${t[5]} Z`)}#za(e){const[t,n,r,i]=this.#Aa,s=this.#Sa.subarray(4,6),a=this.#Sa.subarray(16,18),[o,l,c,h]=this.#Ba();e.push(`L${(s[0]-t)/r} ${(s[1]-n)/i} L${o} ${l} L${c} ${h} L${(a[0]-t)/r} ${(a[1]-n)/i}`)}newFreeDrawOutline(e,t,n,r,i,s){return new di(e,t,n,r,i,s)}getOutlines(){const e=this.#ka,t=this.#xa,n=this.#Sa,[r,i,s,a]=this.#Aa,o=new Float32Array((this.#Ra?.length??0)+2);for(let h=0,d=o.length-2;h<d;h+=2)o[h]=(this.#Ra[h]-r)/s,o[h+1]=(this.#Ra[h+1]-i)/a;if(o[o.length-2]=(this.#Ta-r)/s,o[o.length-1]=(this.#Da-i)/a,isNaN(n[6])&&!this.isEmpty())return this.#Ua(o);const l=new Float32Array(this.#ka.length+24+this.#xa.length);let c=e.length;for(let h=0;h<c;h+=2)isNaN(e[h])?l[h]=l[h+1]=NaN:(l[h]=e[h],l[h+1]=e[h+1]);c=this.#Ha(l,c);for(let h=t.length-6;h>=6;h-=6)for(let e=0;e<6;e+=2)isNaN(t[h+e])?(l[c]=l[c+1]=NaN,c+=2):(l[c]=t[h+e],l[c+1]=t[h+e+1],c+=2);return this.#Va(l,c),this.newFreeDrawOutline(l,o,this.#Aa,this.#Ia,this.#Ea,this.#Ca)}#Ua(e){const t=this.#Sa,[n,r,i,s]=this.#Aa,[a,o,l,c]=this.#Ba(),h=new Float32Array(36);return h.set([NaN,NaN,NaN,NaN,(t[2]-n)/i,(t[3]-r)/s,NaN,NaN,NaN,NaN,(t[4]-n)/i,(t[5]-r)/s,NaN,NaN,NaN,NaN,a,o,NaN,NaN,NaN,NaN,l,c,NaN,NaN,NaN,NaN,(t[16]-n)/i,(t[17]-r)/s,NaN,NaN,NaN,NaN,(t[14]-n)/i,(t[15]-r)/s],0),this.newFreeDrawOutline(h,e,this.#Aa,this.#Ia,this.#Ea,this.#Ca)}#Va(e,t){const n=this.#xa;return e.set([NaN,NaN,NaN,NaN,n[4],n[5]],t),t+6}#Ha(e,t){const n=this.#Sa.subarray(4,6),r=this.#Sa.subarray(16,18),[i,s,a,o]=this.#Aa,[l,c,h,d]=this.#Ba();return e.set([NaN,NaN,NaN,NaN,(n[0]-i)/a,(n[1]-s)/o,NaN,NaN,NaN,NaN,l,c,NaN,NaN,NaN,NaN,h,d,NaN,NaN,NaN,NaN,(r[0]-i)/a,(r[1]-s)/o],t),t+24}}class di extends ci{#Aa;#qa=(()=>new Float32Array(4))();#Ea;#Ca;#Ra;#Ia;#Wa;constructor(e,t,n,r,i,s){super(),this.#Wa=e,this.#Ra=t,this.#Aa=n,this.#Ia=r,this.#Ea=i,this.#Ca=s,this.firstPoint=[NaN,NaN],this.lastPoint=[NaN,NaN],this.#Ga(s);const[a,o,l,c]=this.#qa;for(let h=0,d=e.length;h<d;h+=2)e[h]=(e[h]-a)/l,e[h+1]=(e[h+1]-o)/c;for(let h=0,d=t.length;h<d;h+=2)t[h]=(t[h]-a)/l,t[h+1]=(t[h+1]-o)/c}toSVGPath(){const e=[`M${this.#Wa[4]} ${this.#Wa[5]}`];for(let t=6,n=this.#Wa.length;t<n;t+=6)isNaN(this.#Wa[t])?e.push(`L${this.#Wa[t+4]} ${this.#Wa[t+5]}`):e.push(`C${this.#Wa[t]} ${this.#Wa[t+1]} ${this.#Wa[t+2]} ${this.#Wa[t+3]} ${this.#Wa[t+4]} ${this.#Wa[t+5]}`);return e.push("Z"),e.join(" ")}serialize(e,t){let[n,r,i,s]=e;const a=i-n,o=s-r;let l,c;switch(t){case 0:l=ci._rescale(this.#Wa,n,s,a,-o),c=ci._rescale(this.#Ra,n,s,a,-o);break;case 90:l=ci._rescaleAndSwap(this.#Wa,n,r,a,o),c=ci._rescaleAndSwap(this.#Ra,n,r,a,o);break;case 180:l=ci._rescale(this.#Wa,i,r,-a,o),c=ci._rescale(this.#Ra,i,r,-a,o);break;case 270:l=ci._rescaleAndSwap(this.#Wa,i,s,-a,-o),c=ci._rescaleAndSwap(this.#Ra,i,s,-a,-o)}return{outline:Array.from(l),points:[Array.from(c)]}}#Ga(e){const t=this.#Wa;let n=t[4],r=t[5];const i=[n,r,n,r];let s=n,a=r,o=n,l=r;const c=e?Math.max:Math.min,h=new Float32Array(4);for(let u=6,p=t.length;u<p;u+=6){const e=t[u+4],d=t[u+5];isNaN(t[u])?(se.pointBoundingBox(e,d,i),a>d?(s=e,a=d):a===d&&(s=c(s,e)),l<d?(o=e,l=d):l===d&&(o=c(o,e))):(h[0]=h[1]=1/0,h[2]=h[3]=-1/0,se.bezierBoundingBox(n,r,...t.slice(u,u+6),h),se.rectBoundingBox(h[0],h[1],h[2],h[3],i),a>h[1]?(s=h[0],a=h[1]):a===h[1]&&(s=c(s,h[0])),l<h[3]?(o=h[2],l=h[3]):l===h[3]&&(o=c(o,h[2]))),n=e,r=d}const d=this.#qa;d[0]=i[0]-this.#Ea,d[1]=i[1]-this.#Ea,d[2]=i[2]-i[0]+2*this.#Ea,d[3]=i[3]-i[1]+2*this.#Ea,this.firstPoint=[s,a],this.lastPoint=[o,l]}get box(){return this.#qa}newOutliner(e,t,n,r,i){return new hi(e,t,n,r,i,arguments.length>5&&void 0!==arguments[5]?arguments[5]:0)}getNewOutline(e,t){const[n,r,i,s]=this.#qa,[a,o,l,c]=this.#Aa,h=i*l,d=s*c,u=n*l+a,p=r*c+o,f=this.newOutliner({x:this.#Ra[0]*h+u,y:this.#Ra[1]*d+p},this.#Aa,this.#Ia,e,this.#Ca,t??this.#Ea);for(let m=2;m<this.#Ra.length;m+=2)f.add({x:this.#Ra[m]*h+u,y:this.#Ra[m+1]*d+p});return f.getOutlines()}}class ui{#Aa;#Ka;#Xa;#Ya=[];#Za=[];constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];const i=[1/0,1/0,-1/0,-1/0],s=10**-4;for(const{x:f,y:m,width:g,height:v}of e){const e=Math.floor((f-t)/s)*s,n=Math.ceil((f+g+t)/s)*s,r=Math.floor((m-t)/s)*s,a=Math.ceil((m+v+t)/s)*s,o=[e,r,a,!0],l=[n,r,a,!1];this.#Ya.push(o,l),se.rectBoundingBox(e,r,n,a,i)}const a=i[2]-i[0]+2*n,o=i[3]-i[1]+2*n,l=i[0]-n,c=i[1]-n;let h=r?-1/0:1/0,d=1/0;const u=this.#Ya.at(r?-1:-2),p=[u[0],u[2]];for(const f of this.#Ya){const[e,t,n,i]=f;!i&&r?t<d?(d=t,h=e):t===d&&(h=Math.max(h,e)):i&&!r&&(t<d?(d=t,h=e):t===d&&(h=Math.min(h,e))),f[0]=(e-l)/a,f[1]=(t-c)/o,f[2]=(n-c)/o}this.#Aa=new Float32Array([l,c,a,o]),this.#Ka=[h,d],this.#Xa=p}getOutlines(){this.#Ya.sort((e,t)=>e[0]-t[0]||e[1]-t[1]||e[2]-t[2]);const e=[];for(const t of this.#Ya)t[3]?(e.push(...this.#Ja(t)),this.#Qa(t)):(this.#eo(t),e.push(...this.#Ja(t)));return this.#to(e)}#to(e){const t=[],n=new Set;for(const s of e){const[e,n,r]=s;t.push([e,n,s],[e,r,s])}t.sort((e,t)=>e[1]-t[1]||e[0]-t[0]);for(let s=0,a=t.length;s<a;s+=2){const e=t[s][2],r=t[s+1][2];e.push(r),r.push(e),n.add(e),n.add(r)}const r=[];let i;for(;n.size>0;){const e=n.values().next().value;let[t,s,a,o,l]=e;n.delete(e);let c=t,h=s;for(i=[t,a],r.push(i);;){let e;if(n.has(o))e=o;else{if(!n.has(l))break;e=l}n.delete(e),[t,s,a,o,l]=e,c!==t&&(i.push(c,h,t,h===s?s:a),c=t),h=h===s?a:s}i.push(c,h)}return new pi(r,this.#Aa,this.#Ka,this.#Xa)}#no(e){const t=this.#Za;let n=0,r=t.length-1;for(;n<=r;){const i=n+r>>1,s=t[i][0];if(s===e)return i;s<e?n=i+1:r=i-1}return r+1}#Qa(e){let[,t,n]=e;const r=this.#no(t);this.#Za.splice(r,0,[t,n])}#eo(e){let[,t,n]=e;const r=this.#no(t);for(let i=r;i<this.#Za.length;i++){const[e,r]=this.#Za[i];if(e!==t)break;if(e===t&&r===n)return void this.#Za.splice(i,1)}for(let i=r-1;i>=0;i--){const[e,r]=this.#Za[i];if(e!==t)break;if(e===t&&r===n)return void this.#Za.splice(i,1)}}#Ja(e){const[t,n,r]=e,i=[[t,n,r]],s=this.#no(r);for(let a=0;a<s;a++){const[e,n]=this.#Za[a];for(let r=0,s=i.length;r<s;r++){const[,a,o]=i[r];if(!(n<=a||o<=e))if(a>=e)if(o>n)i[r][1]=n;else{if(1===s)return[];i.splice(r,1),r--,s--}else i[r][2]=e,o>n&&i.push([t,n,o])}}return i}}class pi extends ci{#Aa;#ro;constructor(e,t,n,r){super(),this.#ro=e,this.#Aa=t,this.firstPoint=n,this.lastPoint=r}toSVGPath(){const e=[];for(const t of this.#ro){let[n,r]=t;e.push(`M${n} ${r}`);for(let i=2;i<t.length;i+=2){const s=t[i],a=t[i+1];s===n?(e.push(`V${a}`),r=a):a===r&&(e.push(`H${s}`),n=s)}e.push("Z")}return e.join(" ")}serialize(e,t){let[n,r,i,s]=e;const a=[],o=i-n,l=s-r;for(const c of this.#ro){const e=new Array(c.length);for(let t=0;t<c.length;t+=2)e[t]=n+c[t]*o,e[t+1]=s-c[t+1]*l;a.push(e)}return a}get box(){return this.#Aa}get classNamesForOutlining(){return["highlightOutline"]}}class fi extends hi{newFreeDrawOutline(e,t,n,r,i,s){return new mi(e,t,n,r,i,s)}}class mi extends di{newOutliner(e,t,n,r,i){return new fi(e,t,n,r,i,arguments.length>5&&void 0!==arguments[5]?arguments[5]:0)}}class gi extends Ze{#io=null;#so=0;#ao;#oo=null;#i=null;#lo=null;#co=null;#ho=0;#do=null;#uo=null;#_=null;#po=!1;#Ka=null;#Xa=null;#fo=null;#ht="";#Fa;#mo="";static _defaultColor=null;static _defaultOpacity=1;static _defaultThickness=12;static _type="highlight";static _editorType=(()=>v.HIGHLIGHT)();static _freeHighlightId=-1;static _freeHighlight=null;static _freeHighlightClipId="";static get _keyboardManager(){const e=gi.prototype;return G(this,"_keyboardManager",new qe([[["ArrowLeft","mac+ArrowLeft"],e._moveCaret,{args:[0]}],[["ArrowRight","mac+ArrowRight"],e._moveCaret,{args:[1]}],[["ArrowUp","mac+ArrowUp"],e._moveCaret,{args:[2]}],[["ArrowDown","mac+ArrowDown"],e._moveCaret,{args:[3]}]]))}constructor(e){super({...e,name:"highlightEditor"}),this.color=e.color||gi._defaultColor,this.#Fa=e.thickness||gi._defaultThickness,this.opacity=e.opacity||gi._defaultOpacity,this.#ao=e.boxes||null,this.#mo=e.methodOfCreation||"",this.#ht=e.text||"",this._isDraggable=!1,this.defaultL10nId="pdfjs-editor-highlight-editor",e.highlightId>-1?(this.#po=!0,this.#go(e),this.#vo()):this.#ao&&(this.#io=e.anchorNode,this.#so=e.anchorOffset,this.#co=e.focusNode,this.#ho=e.focusOffset,this.#yo(),this.#vo(),this.rotate(this.rotation)),this.annotationElementId||this._uiManager.a11yAlert("pdfjs-editor-highlight-added-alert")}get telemetryInitialData(){return{action:"added",type:this.#po?"free_highlight":"highlight",color:this._uiManager.getNonHCMColorName(this.color),thickness:this.#Fa,methodOfCreation:this.#mo}}get telemetryFinalData(){return{type:"highlight",color:this._uiManager.getNonHCMColorName(this.color)}}static computeTelemetryFinalData(e){return{numberOfColors:e.get("color").size}}#yo(){const e=new ui(this.#ao,.001);this.#uo=e.getOutlines(),[this.x,this.y,this.width,this.height]=this.#uo.box;const t=new ui(this.#ao,.0025,.001,"ltr"===this._uiManager.direction);this.#lo=t.getOutlines();const{firstPoint:n}=this.#uo;this.#Ka=[(n[0]-this.x)/this.width,(n[1]-this.y)/this.height];const{lastPoint:r}=this.#lo;this.#Xa=[(r[0]-this.x)/this.width,(r[1]-this.y)/this.height]}#go(e){let{highlightOutlines:t,highlightId:n,clipPathId:r}=e;this.#uo=t;if(this.#lo=t.getNewOutline(this.#Fa/2+1.5,.0025),n>=0)this.#_=n,this.#oo=r,this.parent.drawLayer.finalizeDraw(n,{bbox:t.box,path:{d:t.toSVGPath()}}),this.#fo=this.parent.drawLayer.drawOutline({rootClass:{highlightOutline:!0,free:!0},bbox:this.#lo.box,path:{d:this.#lo.toSVGPath()}},!0);else if(this.parent){const e=this.parent.viewport.rotation;this.parent.drawLayer.updateProperties(this.#_,{bbox:gi.#bo(this.#uo.box,(e-this.rotation+360)%360),path:{d:t.toSVGPath()}}),this.parent.drawLayer.updateProperties(this.#fo,{bbox:gi.#bo(this.#lo.box,e),path:{d:this.#lo.toSVGPath()}})}const[i,s,a,o]=t.box;switch(this.rotation){case 0:this.x=i,this.y=s,this.width=a,this.height=o;break;case 90:{const[e,t]=this.parentDimensions;this.x=s,this.y=1-i,this.width=a*t/e,this.height=o*e/t;break}case 180:this.x=1-i,this.y=1-s,this.width=a,this.height=o;break;case 270:{const[e,t]=this.parentDimensions;this.x=1-s,this.y=i,this.width=a*t/e,this.height=o*e/t;break}}const{firstPoint:l}=t;this.#Ka=[(l[0]-i)/a,(l[1]-s)/o];const{lastPoint:c}=this.#lo;this.#Xa=[(c[0]-i)/a,(c[1]-s)/o]}static initialize(e,t){Ze.initialize(e,t),gi._defaultColor||=t.highlightColors?.values().next().value||"#fff066"}static updateDefaultParams(e,t){switch(e){case y.HIGHLIGHT_COLOR:gi._defaultColor=t;break;case y.HIGHLIGHT_THICKNESS:gi._defaultThickness=t}}translateInPage(e,t){}get toolbarPosition(){return this.#Xa}get commentButtonPosition(){return this.#Ka}updateParams(e,t){switch(e){case y.HIGHLIGHT_COLOR:this.#Us(t);break;case y.HIGHLIGHT_THICKNESS:this.#wo(t)}}static get defaultPropertiesToUpdate(){return[[y.HIGHLIGHT_COLOR,gi._defaultColor],[y.HIGHLIGHT_THICKNESS,gi._defaultThickness]]}get propertiesToUpdate(){return[[y.HIGHLIGHT_COLOR,this.color||gi._defaultColor],[y.HIGHLIGHT_THICKNESS,this.#Fa||gi._defaultThickness],[y.HIGHLIGHT_FREE,this.#po]]}onUpdatedColor(){this.parent?.drawLayer.updateProperties(this.#_,{root:{fill:this.color,"fill-opacity":this.opacity}}),this.#i?.updateColor(this.color),super.onUpdatedColor()}#Us(e){const t=(e,t)=>{this.color=e,this.opacity=t,this.onUpdatedColor()},n=this.color,r=this.opacity;this.addCommands({cmd:t.bind(this,e,gi._defaultOpacity),undo:t.bind(this,n,r),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:y.HIGHLIGHT_COLOR,overwriteIfSameType:!0,keepUndo:!0}),this._reportTelemetry({action:"color_changed",color:this._uiManager.getNonHCMColorName(e)},!0)}#wo(e){const t=this.#Fa,n=e=>{this.#Fa=e,this.#_o(e)};this.addCommands({cmd:n.bind(this,e),undo:n.bind(this,t),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:y.INK_THICKNESS,overwriteIfSameType:!0,keepUndo:!0}),this._reportTelemetry({action:"thickness_changed",thickness:e},!0)}get toolbarButtons(){if(this._uiManager.highlightColors){return[["colorPicker",this.#i=new xr({editor:this})]]}return super.toolbarButtons}disableEditing(){super.disableEditing(),this.div.classList.toggle("disabled",!0)}enableEditing(){super.enableEditing(),this.div.classList.toggle("disabled",!1)}fixAndSetPosition(){return super.fixAndSetPosition(this.#Ao())}getBaseTranslation(){return[0,0]}getRect(e,t){return super.getRect(e,t,this.#Ao())}onceAdded(e){this.annotationElementId||this.parent.addUndoableEditor(this),e&&this.div.focus()}remove(){this.#xo(),this._reportTelemetry({action:"deleted"}),super.remove()}rebuild(){this.parent&&(super.rebuild(),null!==this.div&&(this.#vo(),this.isAttachedToDOM||this.parent.add(this)))}setParent(e){let t=!1;this.parent&&!e?this.#xo():e&&(this.#vo(e),t=!this.parent&&this.div?.classList.contains("selectedEditor")),super.setParent(e),this.show(this._isVisible),t&&this.select()}#_o(e){this.#po&&(this.#go({highlightOutlines:this.#uo.getNewOutline(e/2)}),this.fixAndSetPosition(),this.setDims(this.width,this.height))}#xo(){null!==this.#_&&this.parent&&(this.parent.drawLayer.remove(this.#_),this.#_=null,this.parent.drawLayer.remove(this.#fo),this.#fo=null)}#vo(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.parent;null===this.#_&&(({id:this.#_,clipPathId:this.#oo}=e.drawLayer.draw({bbox:this.#uo.box,root:{viewBox:"0 0 1 1",fill:this.color,"fill-opacity":this.opacity},rootClass:{highlight:!0,free:this.#po},path:{d:this.#uo.toSVGPath()}},!1,!0)),this.#fo=e.drawLayer.drawOutline({rootClass:{highlightOutline:!0,free:this.#po},bbox:this.#lo.box,path:{d:this.#lo.toSVGPath()}},this.#po),this.#do&&(this.#do.style.clipPath=this.#oo))}static#bo(e,t){let[n,r,i,s]=e;switch(t){case 90:return[1-r-s,n,s,i];case 180:return[1-n-i,1-r-s,i,s];case 270:return[r,1-n-i,s,i]}return[n,r,i,s]}rotate(e){const{drawLayer:t}=this.parent;let n;this.#po?(e=(e-this.rotation+360)%360,n=gi.#bo(this.#uo.box,e)):n=gi.#bo([this.x,this.y,this.width,this.height],e),t.updateProperties(this.#_,{bbox:n,root:{"data-main-rotation":e}}),t.updateProperties(this.#fo,{bbox:gi.#bo(this.#lo.box,e),root:{"data-main-rotation":e}})}render(){if(this.div)return this.div;const e=super.render();this.#ht&&(e.setAttribute("aria-label",this.#ht),e.setAttribute("role","mark")),this.#po?e.classList.add("free"):this.div.addEventListener("keydown",this.#Eo.bind(this),{signal:this._uiManager._signal});const t=this.#do=document.createElement("div");return e.append(t),t.setAttribute("aria-hidden","true"),t.className="internal",t.style.clipPath=this.#oo,this.setDims(this.width,this.height),je(this,this.#do,["pointerover","pointerleave"]),this.enableEditing(),e}pointerover(){this.isSelected||this.parent?.drawLayer.updateProperties(this.#fo,{rootClass:{hovered:!0}})}pointerleave(){this.isSelected||this.parent?.drawLayer.updateProperties(this.#fo,{rootClass:{hovered:!1}})}#Eo(e){gi._keyboardManager.exec(this,e)}_moveCaret(e){switch(this.parent.unselect(this),e){case 0:case 2:this.#Co(!0);break;case 1:case 3:this.#Co(!1)}}#Co(e){if(!this.#io)return;const t=window.getSelection();e?t.setPosition(this.#io,this.#so):t.setPosition(this.#co,this.#ho)}select(){super.select(),this.#fo&&this.parent?.drawLayer.updateProperties(this.#fo,{rootClass:{hovered:!1,selected:!0}})}unselect(){super.unselect(),this.#fo&&(this.parent?.drawLayer.updateProperties(this.#fo,{rootClass:{selected:!1}}),this.#po||this.#Co(!1))}get _mustFixPosition(){return!this.#po}show(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this._isVisible;super.show(e),this.parent&&(this.parent.drawLayer.updateProperties(this.#_,{rootClass:{hidden:!e}}),this.parent.drawLayer.updateProperties(this.#fo,{rootClass:{hidden:!e}}))}#Ao(){return this.#po?this.rotation:0}#ko(){if(this.#po)return null;const[e,t]=this.pageDimensions,[n,r]=this.pageTranslation,i=this.#ao,s=new Float32Array(8*i.length);let a=0;for(const{x:o,y:l,width:c,height:h}of i){const i=o*e+n,d=(1-l)*t+r;s[a]=s[a+4]=i,s[a+1]=s[a+3]=d,s[a+2]=s[a+6]=i+c*e,s[a+5]=s[a+7]=d-h*t,a+=8}return s}#So(e){return this.#uo.serialize(e,this.#Ao())}static startHighlighting(e,t,n){let{target:r,x:i,y:s}=n;const{x:a,y:o,width:l,height:c}=r.getBoundingClientRect(),h=new AbortController,d=e.combinedSignal(h),u=t=>{h.abort(),this.#To(e,t)};window.addEventListener("blur",u,{signal:d}),window.addEventListener("pointerup",u,{signal:d}),window.addEventListener("pointerdown",Ee,{capture:!0,passive:!1,signal:d}),window.addEventListener("contextmenu",xe,{signal:d}),r.addEventListener("pointermove",this.#Do.bind(this,e),{signal:d}),this._freeHighlight=new fi({x:i,y:s},[a,o,l,c],e.scale,this._defaultThickness/2,t,.001),({id:this._freeHighlightId,clipPathId:this._freeHighlightClipId}=e.drawLayer.draw({bbox:[0,0,1,1],root:{viewBox:"0 0 1 1",fill:this._defaultColor,"fill-opacity":this._defaultOpacity},rootClass:{highlight:!0,free:!0},path:{d:this._freeHighlight.toSVGPath()}},!0,!0))}static#Do(e,t){this._freeHighlight.add(t)&&e.drawLayer.updateProperties(this._freeHighlightId,{path:{d:this._freeHighlight.toSVGPath()}})}static#To(e,t){this._freeHighlight.isEmpty()?e.drawLayer.remove(this._freeHighlightId):e.createAndAddNewEditor(t,!1,{highlightId:this._freeHighlightId,highlightOutlines:this._freeHighlight.getOutlines(),clipPathId:this._freeHighlightClipId,methodOfCreation:"main_toolbar"}),this._freeHighlightId=-1,this._freeHighlight=null,this._freeHighlightClipId=""}static async deserialize(e,t,n){let r=null;if(e instanceof ei){const{data:{quadPoints:t,rect:n,rotation:i,id:s,color:a,opacity:o,popupRef:l,richText:c,contentsObj:h,creationDate:d,modificationDate:u},parent:{page:{pageNumber:p}}}=e;r=e={annotationType:v.HIGHLIGHT,color:Array.from(a),opacity:o,quadPoints:t,boxes:null,pageIndex:p-1,rect:n.slice(0),rotation:i,annotationElementId:s,id:s,deleted:!1,popupRef:l,richText:c,comment:h?.str||null,creationDate:d,modificationDate:u}}else if(e instanceof Qr){const{data:{inkLists:t,rect:n,rotation:i,id:s,color:a,borderStyle:{rawWidth:o},popupRef:l,richText:c,contentsObj:h,creationDate:d,modificationDate:u},parent:{page:{pageNumber:p}}}=e;r=e={annotationType:v.HIGHLIGHT,color:Array.from(a),thickness:o,inkLists:t,boxes:null,pageIndex:p-1,rect:n.slice(0),rotation:i,annotationElementId:s,id:s,deleted:!1,popupRef:l,richText:c,comment:h?.str||null,creationDate:d,modificationDate:u}}const{color:i,quadPoints:s,inkLists:a,opacity:o}=e,l=await super.deserialize(e,t,n);l.color=se.makeHexColor(...i),l.opacity=o||1,a&&(l.#Fa=e.thickness),l._initialData=r,e.comment&&l.setCommentData(e);const[c,h]=l.pageDimensions,[d,u]=l.pageTranslation;if(s){const e=l.#ao=[];for(let t=0;t<s.length;t+=8)e.push({x:(s[t]-d)/c,y:1-(s[t+1]-u)/h,width:(s[t+2]-s[t])/c,height:(s[t+1]-s[t+5])/h});l.#yo(),l.#vo(),l.rotate(l.rotation)}else if(a){l.#po=!0;const e=a[0],n={x:e[0]-d,y:h-(e[1]-u)},r=new fi(n,[0,0,c,h],1,l.#Fa/2,!0,.001);for(let t=0,a=e.length;t<a;t+=2)n.x=e[t]-d,n.y=h-(e[t+1]-u),r.add(n);const{id:i,clipPathId:s}=t.drawLayer.draw({bbox:[0,0,1,1],root:{viewBox:"0 0 1 1",fill:l.color,"fill-opacity":l._defaultOpacity},rootClass:{highlight:!0,free:!0},path:{d:r.toSVGPath()}},!0,!0);l.#go({highlightOutlines:r.getOutlines(),highlightId:i,clipPathId:s}),l.#vo(),l.rotate(l.parentRotation)}return l}serialize(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.isEmpty()||e)return null;if(this.deleted)return this.serializeDeleted();const t=Ze._colorManager.convert(this._uiManager.getNonHCMColor(this.color)),n=super.serialize(e);return Object.assign(n,{color:t,opacity:this.opacity,thickness:this.#Fa,quadPoints:this.#ko(),outlines:this.#So(n.rect)}),this.addComment(n),this.annotationElementId&&!this.#_a(n)?null:(n.id=this.annotationElementId,n)}#_a(e){const{color:t}=this._initialData;return this.hasEditedComment||e.color.some((e,n)=>e!==t[n])}renderAnnotationElement(e){return this.deleted?(e.hide(),null):(e.updateEdited({rect:this.getPDFRect(),popup:this.comment}),null)}static canCreateNewEmptyEditor(){return!1}}class vi{#Mo=(()=>Object.create(null))();updateProperty(e,t){this[e]=t,this.updateSVGProperty(e,t)}updateProperties(e){if(e)for(const[t,n]of Object.entries(e))t.startsWith("_")||this.updateProperty(t,n)}updateSVGProperty(e,t){this.#Mo[e]=t}toSVGProperties(){const e=this.#Mo;return this.#Mo=Object.create(null),{root:e}}reset(){this.#Mo=Object.create(null)}updateAll(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this;this.updateProperties(e)}clone(){H("Not implemented")}}class yi extends Ze{#Po=null;#Io;_colorPicker=null;_drawId=null;static _currentDrawId=-1;static _currentParent=null;static#Fo=null;static#Ro=null;static#No=null;static#Lo=NaN;static#Oo=null;static#Bo=null;static#$o=NaN;static _INNER_MARGIN=3;constructor(e){super(e),this.#Io=e.mustBeCommitted||!1,this._addOutlines(e)}onUpdatedColor(){this._colorPicker?.update(this.color),super.onUpdatedColor()}_addOutlines(e){e.drawOutlines&&(this.#zo(e),this.#vo())}#zo(e){let{drawOutlines:t,drawId:n,drawingOptions:r}=e;this.#Po=t,this._drawingOptions||=r,this.annotationElementId||this._uiManager.a11yAlert(`pdfjs-editor-${this.editorType}-added-alert`),n>=0?(this._drawId=n,this.parent.drawLayer.finalizeDraw(n,t.defaultProperties)):this._drawId=this.#jo(t,this.parent),this.#Uo(t.box)}#jo(e,t){const{id:n}=t.drawLayer.draw(yi._mergeSVGProperties(this._drawingOptions.toSVGProperties(),e.defaultSVGProperties),!1,!1);return n}static _mergeSVGProperties(e,t){const n=new Set(Object.keys(e));for(const[r,i]of Object.entries(t))n.has(r)?Object.assign(e[r],i):e[r]=i;return e}static getDefaultDrawingOptions(e){H("Not implemented")}static get typesMap(){H("Not implemented")}static get isDrawer(){return!0}static get supportMultipleDrawings(){return!1}static updateDefaultParams(e,t){const n=this.typesMap.get(e);n&&this._defaultDrawingOptions.updateProperty(n,t),this._currentParent&&(yi.#Fo.updateProperty(n,t),this._currentParent.drawLayer.updateProperties(this._currentDrawId,this._defaultDrawingOptions.toSVGProperties()))}updateParams(e,t){const n=this.constructor.typesMap.get(e);n&&this._updateProperty(e,n,t)}static get defaultPropertiesToUpdate(){const e=[],t=this._defaultDrawingOptions;for(const[n,r]of this.typesMap)e.push([n,t[r]]);return e}get propertiesToUpdate(){const e=[],{_drawingOptions:t}=this;for(const[n,r]of this.constructor.typesMap)e.push([n,t[r]]);return e}_updateProperty(e,t,n){const r=this._drawingOptions,i=r[t],s=n=>{r.updateProperty(t,n);const i=this.#Po.updateProperty(t,n);i&&this.#Uo(i),this.parent?.drawLayer.updateProperties(this._drawId,r.toSVGProperties()),e===this.colorType&&this.onUpdatedColor()};this.addCommands({cmd:s.bind(this,n),undo:s.bind(this,i),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:e,overwriteIfSameType:!0,keepUndo:!0})}_onResizing(){this.parent?.drawLayer.updateProperties(this._drawId,yi._mergeSVGProperties(this.#Po.getPathResizingSVGProperties(this.#Ho()),{bbox:this.#Vo()}))}_onResized(){this.parent?.drawLayer.updateProperties(this._drawId,yi._mergeSVGProperties(this.#Po.getPathResizedSVGProperties(this.#Ho()),{bbox:this.#Vo()}))}_onTranslating(e,t){this.parent?.drawLayer.updateProperties(this._drawId,{bbox:this.#Vo()})}_onTranslated(){this.parent?.drawLayer.updateProperties(this._drawId,yi._mergeSVGProperties(this.#Po.getPathTranslatedSVGProperties(this.#Ho(),this.parentDimensions),{bbox:this.#Vo()}))}_onStartDragging(){this.parent?.drawLayer.updateProperties(this._drawId,{rootClass:{moving:!0}})}_onStopDragging(){this.parent?.drawLayer.updateProperties(this._drawId,{rootClass:{moving:!1}})}commit(){super.commit(),this.disableEditMode(),this.disableEditing()}disableEditing(){super.disableEditing(),this.div.classList.toggle("disabled",!0)}enableEditing(){super.enableEditing(),this.div.classList.toggle("disabled",!1)}getBaseTranslation(){return[0,0]}get isResizable(){return!0}onceAdded(e){this.annotationElementId||this.parent.addUndoableEditor(this),this._isDraggable=!0,this.#Io&&(this.#Io=!1,this.commit(),this.parent.setSelected(this),e&&this.isOnScreen&&this.div.focus())}remove(){this.#xo(),super.remove()}rebuild(){this.parent&&(super.rebuild(),null!==this.div&&(this.#vo(),this.#Uo(this.#Po.box),this.isAttachedToDOM||this.parent.add(this)))}setParent(e){let t=!1;this.parent&&!e?(this._uiManager.removeShouldRescale(this),this.#xo()):e&&(this._uiManager.addShouldRescale(this),this.#vo(e),t=!this.parent&&this.div?.classList.contains("selectedEditor")),super.setParent(e),t&&this.select()}#xo(){null!==this._drawId&&this.parent&&(this.parent.drawLayer.remove(this._drawId),this._drawId=null,this._drawingOptions.reset())}#vo(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.parent;null!==this._drawId&&this.parent===e||(null===this._drawId?(this._drawingOptions.updateAll(),this._drawId=this.#jo(this.#Po,e)):this.parent.drawLayer.updateParent(this._drawId,e.drawLayer))}#qo(e){let[t,n,r,i]=e;const{parentDimensions:[s,a],rotation:o}=this;switch(o){case 90:return[n,1-t,r*(a/s),i*(s/a)];case 180:return[1-t,1-n,r,i];case 270:return[1-n,t,r*(a/s),i*(s/a)];default:return[t,n,r,i]}}#Ho(){const{x:e,y:t,width:n,height:r,parentDimensions:[i,s],rotation:a}=this;switch(a){case 90:return[1-t,e,n*(i/s),r*(s/i)];case 180:return[1-e,1-t,n,r];case 270:return[t,1-e,n*(i/s),r*(s/i)];default:return[e,t,n,r]}}#Uo(e){[this.x,this.y,this.width,this.height]=this.#qo(e),this.div&&(this.fixAndSetPosition(),this.setDims()),this._onResized()}#Vo(){const{x:e,y:t,width:n,height:r,rotation:i,parentRotation:s,parentDimensions:[a,o]}=this;switch((4*i+s)/90){case 1:return[1-t-r,e,r,n];case 2:return[1-e-n,1-t-r,n,r];case 3:return[t,1-e-n,r,n];case 4:return[e,t-n*(a/o),r*(o/a),n*(a/o)];case 5:return[1-t,e,n*(a/o),r*(o/a)];case 6:return[1-e-r*(o/a),1-t,r*(o/a),n*(a/o)];case 7:return[t-n*(a/o),1-e-r*(o/a),n*(a/o),r*(o/a)];case 8:return[e-n,t-r,n,r];case 9:return[1-t,e-n,r,n];case 10:return[1-e,1-t,n,r];case 11:return[t-r,1-e,r,n];case 12:return[e-r*(o/a),t,r*(o/a),n*(a/o)];case 13:return[1-t-n*(a/o),e-r*(o/a),n*(a/o),r*(o/a)];case 14:return[1-e,1-t-n*(a/o),r*(o/a),n*(a/o)];case 15:return[t,1-e,n*(a/o),r*(o/a)];default:return[e,t,n,r]}}rotate(){this.parent&&this.parent.drawLayer.updateProperties(this._drawId,yi._mergeSVGProperties({bbox:this.#Vo()},this.#Po.updateRotation((this.parentRotation-this.rotation+360)%360)))}onScaleChanging(){this.parent&&this.#Uo(this.#Po.updateParentDimensions(this.parentDimensions,this.parent.scale))}static onScaleChangingWhenDrawing(){}render(){if(this.div)return this.div;let e,t;this._isCopy&&(e=this.x,t=this.y);const n=super.render();n.classList.add("draw");const r=document.createElement("div");return n.append(r),r.setAttribute("aria-hidden","true"),r.className="internal",this.setDims(),this._uiManager.addShouldRescale(this),this.disableEditing(),this._isCopy&&this._moveAfterPaste(e,t),n}static createDrawerInstance(e,t,n,r,i){H("Not implemented")}static startDrawing(e,t,n,r){const{target:i,offsetX:s,offsetY:a,pointerId:o,pointerType:l}=r;if(yi.#Oo&&yi.#Oo!==l)return;const{viewport:{rotation:c}}=e,{width:h,height:d}=i.getBoundingClientRect(),u=yi.#Ro=new AbortController,p=e.combinedSignal(u);yi.#Lo||=o,yi.#Oo??=l,window.addEventListener("pointerup",e=>{yi.#Lo===e.pointerId?this._endDraw(e):yi.#Bo?.delete(e.pointerId)},{signal:p}),window.addEventListener("pointercancel",e=>{yi.#Lo===e.pointerId?this._currentParent.endDrawingSession():yi.#Bo?.delete(e.pointerId)},{signal:p}),window.addEventListener("pointerdown",e=>{yi.#Oo===e.pointerType&&((yi.#Bo||=new Set).add(e.pointerId),yi.#Fo.isCancellable()&&(yi.#Fo.removeLastElement(),yi.#Fo.isEmpty()?this._currentParent.endDrawingSession(!0):this._endDraw(null)))},{capture:!0,passive:!1,signal:p}),window.addEventListener("contextmenu",xe,{signal:p}),i.addEventListener("pointermove",this._drawMove.bind(this),{signal:p}),i.addEventListener("touchmove",e=>{e.timeStamp===yi.#$o&&Ee(e)},{signal:p}),e.toggleDrawing(),t._editorUndoBar?.hide(),yi.#Fo?e.drawLayer.updateProperties(this._currentDrawId,yi.#Fo.startNew(s,a,h,d,c)):(t.updateUIForDefaultProperties(this),yi.#Fo=this.createDrawerInstance(s,a,h,d,c),yi.#No=this.getDefaultDrawingOptions(),this._currentParent=e,({id:this._currentDrawId}=e.drawLayer.draw(this._mergeSVGProperties(yi.#No.toSVGProperties(),yi.#Fo.defaultSVGProperties),!0,!1)))}static _drawMove(e){if(yi.#$o=-1,!yi.#Fo)return;const{offsetX:t,offsetY:n,pointerId:r}=e;yi.#Lo===r&&(yi.#Bo?.size>=1?this._endDraw(e):(this._currentParent.drawLayer.updateProperties(this._currentDrawId,yi.#Fo.add(t,n)),yi.#$o=e.timeStamp,Ee(e)))}static _cleanup(e){e&&(this._currentDrawId=-1,this._currentParent=null,yi.#Fo=null,yi.#No=null,yi.#Oo=null,yi.#$o=NaN),yi.#Ro&&(yi.#Ro.abort(),yi.#Ro=null,yi.#Lo=NaN,yi.#Bo=null)}static _endDraw(e){const t=this._currentParent;if(t){if(t.toggleDrawing(!0),this._cleanup(!1),e?.target===t.div&&t.drawLayer.updateProperties(this._currentDrawId,yi.#Fo.end(e.offsetX,e.offsetY)),this.supportMultipleDrawings){const e=yi.#Fo,n=this._currentDrawId,r=e.getLastElement();return void t.addCommands({cmd:()=>{t.drawLayer.updateProperties(n,e.setLastElement(r))},undo:()=>{t.drawLayer.updateProperties(n,e.removeLastElement())},mustExec:!1,type:y.DRAW_STEP})}this.endDrawing(!1)}}static endDrawing(e){const t=this._currentParent;if(!t)return null;if(t.toggleDrawing(!0),t.cleanUndoStack(y.DRAW_STEP),!yi.#Fo.isEmpty()){const{pageDimensions:[n,r],scale:i}=t,s=t.createAndAddNewEditor({offsetX:0,offsetY:0},!1,{drawId:this._currentDrawId,drawOutlines:yi.#Fo.getOutlines(n*i,r*i,i,this._INNER_MARGIN),drawingOptions:yi.#No,mustBeCommitted:!e});return this._cleanup(!0),s}return t.drawLayer.remove(this._currentDrawId),this._cleanup(!0),null}createDrawingOptions(e){}static deserializeDraw(e,t,n,r,i,s){H("Not implemented")}static async deserialize(e,t,n){const{rawDims:{pageWidth:r,pageHeight:i,pageX:s,pageY:a}}=t.viewport,o=this.deserializeDraw(s,a,r,i,this._INNER_MARGIN,e),l=await super.deserialize(e,t,n);return l.createDrawingOptions(e),l.#zo({drawOutlines:o}),l.#vo(),l.onScaleChanging(),l.rotate(),l}serializeDraw(e){const[t,n]=this.pageTranslation,[r,i]=this.pageDimensions;return this.#Po.serialize([t,n,r,i],e)}renderAnnotationElement(e){return e.updateEdited({rect:this.getPDFRect()}),null}static canCreateNewEmptyEditor(){return!1}}class bi{#Sa=(()=>new Float64Array(6))();#Xs;#Wo;#ri;#Fa;#Ra;#Go="";#Ko=0;#ro=(()=>new wi)();#Xo;#Yo;constructor(e,t,n,r,i,s){this.#Xo=n,this.#Yo=r,this.#ri=i,this.#Fa=s,[e,t]=this.#Zo(e,t);const a=this.#Xs=[NaN,NaN,NaN,NaN,e,t];this.#Ra=[e,t],this.#Wo=[{line:a,points:this.#Ra}],this.#Sa.set(a,0)}updateProperty(e,t){"stroke-width"===e&&(this.#Fa=t)}#Zo(e,t){return ci._normalizePoint(e,t,this.#Xo,this.#Yo,this.#ri)}isEmpty(){return!this.#Wo||0===this.#Wo.length}isCancellable(){return this.#Ra.length<=10}add(e,t){[e,t]=this.#Zo(e,t);const[n,r,i,s]=this.#Sa.subarray(2,6),a=e-i,o=t-s;return Math.hypot(this.#Xo*a,this.#Yo*o)<=2?null:(this.#Ra.push(e,t),isNaN(n)?(this.#Sa.set([i,s,e,t],2),this.#Xs.push(NaN,NaN,NaN,NaN,e,t),{path:{d:this.toSVGPath()}}):(isNaN(this.#Sa[0])&&this.#Xs.splice(6,6),this.#Sa.set([n,r,i,s,e,t],0),this.#Xs.push(...ci.createBezierPoints(n,r,i,s,e,t)),{path:{d:this.toSVGPath()}}))}end(e,t){const n=this.add(e,t);return n||(2===this.#Ra.length?{path:{d:this.toSVGPath()}}:null)}startNew(e,t,n,r,i){this.#Xo=n,this.#Yo=r,this.#ri=i,[e,t]=this.#Zo(e,t);const s=this.#Xs=[NaN,NaN,NaN,NaN,e,t];this.#Ra=[e,t];const a=this.#Wo.at(-1);return a&&(a.line=new Float32Array(a.line),a.points=new Float32Array(a.points)),this.#Wo.push({line:s,points:this.#Ra}),this.#Sa.set(s,0),this.#Ko=0,this.toSVGPath(),null}getLastElement(){return this.#Wo.at(-1)}setLastElement(e){return this.#Wo?(this.#Wo.push(e),this.#Xs=e.line,this.#Ra=e.points,this.#Ko=0,{path:{d:this.toSVGPath()}}):this.#ro.setLastElement(e)}removeLastElement(){if(!this.#Wo)return this.#ro.removeLastElement();this.#Wo.pop(),this.#Go="";for(let e=0,t=this.#Wo.length;e<t;e++){const{line:t,points:n}=this.#Wo[e];this.#Xs=t,this.#Ra=n,this.#Ko=0,this.toSVGPath()}return{path:{d:this.#Go}}}toSVGPath(){const e=ci.svgRound(this.#Xs[4]),t=ci.svgRound(this.#Xs[5]);if(2===this.#Ra.length)return this.#Go=`${this.#Go} M ${e} ${t} Z`,this.#Go;if(this.#Ra.length<=6){const n=this.#Go.lastIndexOf("M");this.#Go=`${this.#Go.slice(0,n)} M ${e} ${t}`,this.#Ko=6}if(4===this.#Ra.length){const e=ci.svgRound(this.#Xs[10]),t=ci.svgRound(this.#Xs[11]);return this.#Go=`${this.#Go} L ${e} ${t}`,this.#Ko=12,this.#Go}const n=[];0===this.#Ko&&(n.push(`M ${e} ${t}`),this.#Ko=6);for(let r=this.#Ko,i=this.#Xs.length;r<i;r+=6){const[e,t,i,s,a,o]=this.#Xs.slice(r,r+6).map(ci.svgRound);n.push(`C${e} ${t} ${i} ${s} ${a} ${o}`)}return this.#Go+=n.join(" "),this.#Ko=this.#Xs.length,this.#Go}getOutlines(e,t,n,r){const i=this.#Wo.at(-1);return i.line=new Float32Array(i.line),i.points=new Float32Array(i.points),this.#ro.build(this.#Wo,e,t,n,this.#ri,this.#Fa,r),this.#Sa=null,this.#Xs=null,this.#Wo=null,this.#Go=null,this.#ro}get defaultSVGProperties(){return{root:{viewBox:"0 0 10000 10000"},rootClass:{draw:!0},bbox:[0,0,1,1]}}}class wi extends ci{#qa;#Jo=0;#Ea;#Wo;#Xo;#Yo;#Qo;#ri;#Fa;build(e,t,n,r,i,s,a){this.#Xo=t,this.#Yo=n,this.#Qo=r,this.#ri=i,this.#Fa=s,this.#Ea=a??0,this.#Wo=e,this.#el()}get thickness(){return this.#Fa}setLastElement(e){return this.#Wo.push(e),{path:{d:this.toSVGPath()}}}removeLastElement(){return this.#Wo.pop(),{path:{d:this.toSVGPath()}}}toSVGPath(){const e=[];for(const{line:t}of this.#Wo)if(e.push(`M${ci.svgRound(t[4])} ${ci.svgRound(t[5])}`),6!==t.length)if(12===t.length&&isNaN(t[6]))e.push(`L${ci.svgRound(t[10])} ${ci.svgRound(t[11])}`);else for(let n=6,r=t.length;n<r;n+=6){const[r,i,s,a,o,l]=t.subarray(n,n+6).map(ci.svgRound);e.push(`C${r} ${i} ${s} ${a} ${o} ${l}`)}else e.push("Z");return e.join("")}serialize(e,t){let[n,r,i,s]=e;const a=[],o=[],[l,c,h,d]=this.#tl();let u,p,f,m,g,v,y,b,w;switch(this.#ri){case 0:w=ci._rescale,u=n,p=r+s,f=i,m=-s,g=n+l*i,v=r+(1-c-d)*s,y=n+(l+h)*i,b=r+(1-c)*s;break;case 90:w=ci._rescaleAndSwap,u=n,p=r,f=i,m=s,g=n+c*i,v=r+l*s,y=n+(c+d)*i,b=r+(l+h)*s;break;case 180:w=ci._rescale,u=n+i,p=r,f=-i,m=s,g=n+(1-l-h)*i,v=r+c*s,y=n+(1-l)*i,b=r+(c+d)*s;break;case 270:w=ci._rescaleAndSwap,u=n+i,p=r+s,f=-i,m=-s,g=n+(1-c-d)*i,v=r+(1-l-h)*s,y=n+(1-c)*i,b=r+(1-l)*s}for(const{line:_,points:A}of this.#Wo)a.push(w(_,u,p,f,m,t?new Array(_.length):null)),o.push(w(A,u,p,f,m,t?new Array(A.length):null));return{lines:a,points:o,rect:[g,v,y,b]}}static deserialize(e,t,n,r,i,s){let{paths:{lines:a,points:o},rotation:l,thickness:c}=s;const h=[];let d,u,p,f,m;switch(l){case 0:m=ci._rescale,d=-e/n,u=t/r+1,p=1/n,f=-1/r;break;case 90:m=ci._rescaleAndSwap,d=-t/r,u=-e/n,p=1/r,f=1/n;break;case 180:m=ci._rescale,d=e/n+1,u=-t/r,p=-1/n,f=1/r;break;case 270:m=ci._rescaleAndSwap,d=t/r+1,u=e/n+1,p=-1/r,f=-1/n}if(!a){a=[];for(const e of o){const t=e.length;if(2===t){a.push(new Float32Array([NaN,NaN,NaN,NaN,e[0],e[1]]));continue}if(4===t){a.push(new Float32Array([NaN,NaN,NaN,NaN,e[0],e[1],NaN,NaN,NaN,NaN,e[2],e[3]]));continue}const n=new Float32Array(3*(t-2));a.push(n);let[r,i,s,o]=e.subarray(0,4);n.set([NaN,NaN,NaN,NaN,r,i],0);for(let a=4;a<t;a+=2){const t=e[a],l=e[a+1];n.set(ci.createBezierPoints(r,i,s,o,t,l),3*(a-2)),[r,i,s,o]=[s,o,t,l]}}}for(let v=0,y=a.length;v<y;v++)h.push({line:m(a[v].map(e=>e??NaN),d,u,p,f),points:m(o[v].map(e=>e??NaN),d,u,p,f)});const g=new this.prototype.constructor;return g.build(h,n,r,1,l,c,i),g}#nl(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.#Fa;const t=this.#Ea+e/2*this.#Qo;return this.#ri%180===0?[t/this.#Xo,t/this.#Yo]:[t/this.#Yo,t/this.#Xo]}#tl(){const[e,t,n,r]=this.#qa,[i,s]=this.#nl(0);return[e+i,t+s,n-2*i,r-2*s]}#el(){const e=this.#qa=new Float32Array([1/0,1/0,-1/0,-1/0]);for(const{line:r}of this.#Wo){if(r.length<=12){for(let t=4,n=r.length;t<n;t+=6)se.pointBoundingBox(r[t],r[t+1],e);continue}let t=r[4],n=r[5];for(let i=6,s=r.length;i<s;i+=6){const[s,a,o,l,c,h]=r.subarray(i,i+6);se.bezierBoundingBox(t,n,s,a,o,l,c,h,e),t=c,n=h}}const[t,n]=this.#nl();e[0]=he(e[0]-t,0,1),e[1]=he(e[1]-n,0,1),e[2]=he(e[2]+t,0,1),e[3]=he(e[3]+n,0,1),e[2]-=e[0],e[3]-=e[1]}get box(){return this.#qa}updateProperty(e,t){return"stroke-width"===e?this.#wo(t):null}#wo(e){const[t,n]=this.#nl();this.#Fa=e;const[r,i]=this.#nl(),[s,a]=[r-t,i-n],o=this.#qa;return o[0]-=s,o[1]-=a,o[2]+=2*s,o[3]+=2*a,o}updateParentDimensions(e,t){let[n,r]=e;const[i,s]=this.#nl();this.#Xo=n,this.#Yo=r,this.#Qo=t;const[a,o]=this.#nl(),l=a-i,c=o-s,h=this.#qa;return h[0]-=l,h[1]-=c,h[2]+=2*l,h[3]+=2*c,h}updateRotation(e){return this.#Jo=e,{path:{transform:this.rotationTransform}}}get viewBox(){return this.#qa.map(ci.svgRound).join(" ")}get defaultProperties(){const[e,t]=this.#qa;return{root:{viewBox:this.viewBox},path:{"transform-origin":`${ci.svgRound(e)} ${ci.svgRound(t)}`}}}get rotationTransform(){const[,,e,t]=this.#qa;let n=0,r=0,i=0,s=0,a=0,o=0;switch(this.#Jo){case 90:r=t/e,i=-e/t,a=e;break;case 180:n=-1,s=-1,a=e,o=t;break;case 270:r=-t/e,i=e/t,o=t;break;default:return""}return`matrix(${n} ${r} ${i} ${s} ${ci.svgRound(a)} ${ci.svgRound(o)})`}getPathResizingSVGProperties(e){let[t,n,r,i]=e;const[s,a]=this.#nl(),[o,l,c,h]=this.#qa;if(Math.abs(c-s)<=ci.PRECISION||Math.abs(h-a)<=ci.PRECISION){const e=t+r/2-(o+c/2),s=n+i/2-(l+h/2);return{path:{"transform-origin":`${ci.svgRound(t)} ${ci.svgRound(n)}`,transform:`${this.rotationTransform} translate(${e} ${s})`}}}const d=(r-2*s)/(c-2*s),u=(i-2*a)/(h-2*a),p=c/r,f=h/i;return{path:{"transform-origin":`${ci.svgRound(o)} ${ci.svgRound(l)}`,transform:`${this.rotationTransform} scale(${p} ${f}) translate(${ci.svgRound(s)} ${ci.svgRound(a)}) scale(${d} ${u}) translate(${ci.svgRound(-s)} ${ci.svgRound(-a)})`}}}getPathResizedSVGProperties(e){let[t,n,r,i]=e;const[s,a]=this.#nl(),o=this.#qa,[l,c,h,d]=o;if(o[0]=t,o[1]=n,o[2]=r,o[3]=i,Math.abs(h-s)<=ci.PRECISION||Math.abs(d-a)<=ci.PRECISION){const e=t+r/2-(l+h/2),s=n+i/2-(c+d/2);for(const{line:t,points:n}of this.#Wo)ci._translate(t,e,s,t),ci._translate(n,e,s,n);return{root:{viewBox:this.viewBox},path:{"transform-origin":`${ci.svgRound(t)} ${ci.svgRound(n)}`,transform:this.rotationTransform||null,d:this.toSVGPath()}}}const u=(r-2*s)/(h-2*s),p=(i-2*a)/(d-2*a),f=-u*(l+s)+t+s,m=-p*(c+a)+n+a;if(1!==u||1!==p||0!==f||0!==m)for(const{line:g,points:v}of this.#Wo)ci._rescale(g,f,m,u,p,g),ci._rescale(v,f,m,u,p,v);return{root:{viewBox:this.viewBox},path:{"transform-origin":`${ci.svgRound(t)} ${ci.svgRound(n)}`,transform:this.rotationTransform||null,d:this.toSVGPath()}}}getPathTranslatedSVGProperties(e,t){let[n,r]=e;const[i,s]=t,a=this.#qa,o=n-a[0],l=r-a[1];if(this.#Xo===i&&this.#Yo===s)for(const{line:c,points:h}of this.#Wo)ci._translate(c,o,l,c),ci._translate(h,o,l,h);else{const e=this.#Xo/i,t=this.#Yo/s;this.#Xo=i,this.#Yo=s;for(const{line:n,points:r}of this.#Wo)ci._rescale(n,o,l,e,t,n),ci._rescale(r,o,l,e,t,r);a[2]*=e,a[3]*=t}return a[0]=n,a[1]=r,{root:{viewBox:this.viewBox},path:{d:this.toSVGPath(),"transform-origin":`${ci.svgRound(n)} ${ci.svgRound(r)}`}}}get defaultSVGProperties(){const e=this.#qa;return{root:{viewBox:this.viewBox},rootClass:{draw:!0},path:{d:this.toSVGPath(),"transform-origin":`${ci.svgRound(e[0])} ${ci.svgRound(e[1])}`,transform:this.rotationTransform||null},bbox:e}}}class _i extends vi{constructor(e){super(),this._viewParameters=e,super.updateProperties({fill:"none",stroke:Ze._defaultLineColor,"stroke-opacity":1,"stroke-width":1,"stroke-linecap":"round","stroke-linejoin":"round","stroke-miterlimit":10})}updateSVGProperty(e,t){"stroke-width"===e&&(t??=this["stroke-width"],t*=this._viewParameters.realScale),super.updateSVGProperty(e,t)}clone(){const e=new _i(this._viewParameters);return e.updateAll(this),e}}class Ai extends yi{static _type="ink";static _editorType=(()=>v.INK)();static _defaultDrawingOptions=null;constructor(e){super({...e,name:"inkEditor"}),this._willKeepAspectRatio=!0,this.defaultL10nId="pdfjs-editor-ink-editor"}static initialize(e,t){Ze.initialize(e,t),this._defaultDrawingOptions=new _i(t.viewParameters)}static getDefaultDrawingOptions(e){const t=this._defaultDrawingOptions.clone();return t.updateProperties(e),t}static get supportMultipleDrawings(){return!0}static get typesMap(){return G(this,"typesMap",new Map([[y.INK_THICKNESS,"stroke-width"],[y.INK_COLOR,"stroke"],[y.INK_OPACITY,"stroke-opacity"]]))}static createDrawerInstance(e,t,n,r,i){return new bi(e,t,n,r,i,this._defaultDrawingOptions["stroke-width"])}static deserializeDraw(e,t,n,r,i,s){return wi.deserialize(e,t,n,r,i,s)}static async deserialize(e,t,n){let r=null;if(e instanceof Qr){const{data:{inkLists:t,rect:n,rotation:i,id:s,color:a,opacity:o,borderStyle:{rawWidth:l},popupRef:c,richText:h,contentsObj:d,creationDate:u,modificationDate:p},parent:{page:{pageNumber:f}}}=e;r=e={annotationType:v.INK,color:Array.from(a),thickness:l,opacity:o,paths:{points:t},boxes:null,pageIndex:f-1,rect:n.slice(0),rotation:i,annotationElementId:s,id:s,deleted:!1,popupRef:c,richText:h,comment:d?.str||null,creationDate:u,modificationDate:p}}const i=await super.deserialize(e,t,n);return i._initialData=r,e.comment&&i.setCommentData(e),i}get toolbarButtons(){return this._colorPicker||=new Er(this),[["colorPicker",this._colorPicker]]}get colorType(){return y.INK_COLOR}get color(){return this._drawingOptions.stroke}get opacity(){return this._drawingOptions["stroke-opacity"]}onScaleChanging(){if(!this.parent)return;super.onScaleChanging();const{_drawId:e,_drawingOptions:t,parent:n}=this;t.updateSVGProperty("stroke-width"),n.drawLayer.updateProperties(e,t.toSVGProperties())}static onScaleChangingWhenDrawing(){const e=this._currentParent;e&&(super.onScaleChangingWhenDrawing(),this._defaultDrawingOptions.updateSVGProperty("stroke-width"),e.drawLayer.updateProperties(this._currentDrawId,this._defaultDrawingOptions.toSVGProperties()))}createDrawingOptions(e){let{color:t,thickness:n,opacity:r}=e;this._drawingOptions=Ai.getDefaultDrawingOptions({stroke:se.makeHexColor(...t),"stroke-width":n,"stroke-opacity":r})}serialize(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.isEmpty())return null;if(this.deleted)return this.serializeDeleted();const{lines:t,points:n}=this.serializeDraw(e),{_drawingOptions:{stroke:r,"stroke-opacity":i,"stroke-width":s}}=this,a=Object.assign(super.serialize(e),{color:Ze._colorManager.convert(r),opacity:i,thickness:s,paths:{lines:t,points:n}});return this.addComment(a),e?(a.isCopy=!0,a):this.annotationElementId&&!this.#_a(a)?null:(a.id=this.annotationElementId,a)}#_a(e){const{color:t,thickness:n,opacity:r,pageIndex:i}=this._initialData;return this.hasEditedComment||this._hasBeenMoved||this._hasBeenResized||e.color.some((e,n)=>e!==t[n])||e.thickness!==n||e.opacity!==r||e.pageIndex!==i}renderAnnotationElement(e){if(this.deleted)return e.hide(),null;const{points:t,rect:n}=this.serializeDraw(!1);return e.updateEdited({rect:n,thickness:this._drawingOptions["stroke-width"],points:t,popup:this.comment}),null}}class xi extends wi{toSVGPath(){let e=super.toSVGPath();return e.endsWith("Z")||(e+="Z"),e}}class Ei{static#rl={maxDim:512,sigmaSFactor:.02,sigmaR:25,kernelSize:16};static#il(e,t,n,r){return r-=t,0===(n-=e)?r>0?0:4:1===n?r+6:2-r}static#sl=(()=>new Int32Array([0,1,-1,1,-1,0,-1,-1,0,-1,1,-1,1,0,1,1]))();static#al(e,t,n,r,i,s,a){const o=this.#il(n,r,i,s);for(let l=0;l<8;l++){const i=(-l+o-a+16)%8;if(0!==e[(n+this.#sl[2*i])*t+(r+this.#sl[2*i+1])])return i}return-1}static#ol(e,t,n,r,i,s,a){const o=this.#il(n,r,i,s);for(let l=0;l<8;l++){const i=(l+o+a+16)%8;if(0!==e[(n+this.#sl[2*i])*t+(r+this.#sl[2*i+1])])return i}return-1}static#ll(e,t,n,r){const i=e.length,s=new Int32Array(i);for(let c=0;c<i;c++)s[c]=e[c]<=r?1:0;for(let c=1;c<n-1;c++)s[c*t]=s[c*t+t-1]=0;for(let c=0;c<t;c++)s[c]=s[t*n-1-c]=0;let a,o=1;const l=[];for(let c=1;c<n-1;c++){a=1;for(let e=1;e<t-1;e++){const n=c*t+e,r=s[n];if(0===r)continue;let i=c,h=e;if(1===r&&0===s[n-1])o+=1,h-=1;else{if(!(r>=1&&0===s[n+1])){1!==r&&(a=Math.abs(r));continue}o+=1,h+=1,r>1&&(a=r)}const d=[e,c],u=h===e+1,p={isHole:u,points:d,id:o,parent:0};let f;l.push(p);for(const e of l)if(e.id===a){f=e;break}f?f.isHole?p.parent=u?f.parent:a:p.parent=u?a:f.parent:p.parent=u?a:0;const m=this.#al(s,t,c,e,i,h,0);if(-1===m){s[n]=-o,1!==s[n]&&(a=Math.abs(s[n]));continue}let g=this.#sl[2*m],v=this.#sl[2*m+1];const y=c+g,b=e+v;i=y,h=b;let w=c,_=e;for(;;){const r=this.#ol(s,t,w,_,i,h,1);g=this.#sl[2*r],v=this.#sl[2*r+1];const l=w+g,u=_+v;d.push(u,l);const p=w*t+_;if(0===s[p+1]?s[p]=-o:1===s[p]&&(s[p]=o),l===c&&u===e&&w===y&&_===b){1!==s[n]&&(a=Math.abs(s[n]));break}i=w,h=_,w=l,_=u}}}return l}static#cl(e,t,n,r){if(n-t<=4){for(let i=t;i<n-2;i+=2)r.push(e[i],e[i+1]);return}const i=e[t],s=e[t+1],a=e[n-4]-i,o=e[n-3]-s,l=Math.hypot(a,o),c=a/l,h=o/l,d=c*s-h*i,u=o/a,p=1/l,f=Math.atan(u),m=Math.cos(f),g=Math.sin(f),v=p*(Math.abs(m)+Math.abs(g)),y=p*(1-v+v**2),b=Math.max(Math.atan(Math.abs(g+m)*y),Math.atan(Math.abs(g-m)*y));let w=0,_=t;for(let A=t+2;A<n-2;A+=2){const t=Math.abs(d-c*e[A+1]+h*e[A]);t>w&&(_=A,w=t)}w>(l*b)**2?(this.#cl(e,t,_+2,r),this.#cl(e,_,n,r)):r.push(i,s)}static#hl(e){const t=[],n=e.length;return this.#cl(e,0,n,t),t.push(e[n-2],e[n-1]),t.length<=4?null:t}static#dl(e,t,n,r,i,s){const a=new Float32Array(s**2),o=-2*r**2,l=s>>1;for(let f=0;f<s;f++){const e=(f-l)**2;for(let t=0;t<s;t++)a[f*s+t]=Math.exp((e+(t-l)**2)/o)}const c=new Float32Array(256),h=-2*i**2;for(let f=0;f<256;f++)c[f]=Math.exp(f**2/h);const d=e.length,u=new Uint8Array(d),p=new Uint32Array(256);for(let f=0;f<n;f++)for(let r=0;r<t;r++){const i=f*t+r,o=e[i];let h=0,d=0;for(let u=0;u<s;u++){const i=f+u-l;if(!(i<0||i>=n))for(let n=0;n<s;n++){const p=r+n-l;if(p<0||p>=t)continue;const f=e[i*t+p],m=a[u*s+n]*c[Math.abs(f-o)];h+=f*m,d+=m}}p[u[i]=Math.round(h/d)]++}return[u,p]}static#ul(e){const t=new Uint32Array(256);for(const n of e)t[n]++;return t}static#pl(e){const t=e.length,n=new Uint8ClampedArray(t>>2);let r=-1/0,i=1/0;for(let a=0,o=n.length;a<o;a++){const t=n[a]=e[a<<2];r=Math.max(r,t),i=Math.min(i,t)}const s=255/(r-i);for(let a=0,o=n.length;a<o;a++)n[a]=(n[a]-i)*s;return n}static#fl(e){let t,n=-1/0,r=-1/0;const i=e.findIndex(e=>0!==e);let s=i,a=i;for(t=i;t<256;t++){const i=e[t];i>n&&(t-s>r&&(r=t-s,a=t-1),n=i,s=t)}for(t=a-1;t>=0&&!(e[t]>e[t+1]);t--);return t}static#ml(e){const t=e,{width:n,height:r}=e,{maxDim:i}=this.#rl;let s=n,a=r;if(n>i||r>i){let o=n,l=r,c=Math.log2(Math.max(n,r)/i);const h=Math.floor(c);c=c===h?h-1:h;for(let n=0;n<c;n++){s=Math.ceil(o/2),a=Math.ceil(l/2);const n=new OffscreenCanvas(s,a);n.getContext("2d").drawImage(e,0,0,o,l,0,0,s,a),o=s,l=a,e!==t&&e.close(),e=n.transferToImageBitmap()}const d=Math.min(i/s,i/a);s=Math.round(s*d),a=Math.round(a*d)}const o=new OffscreenCanvas(s,a).getContext("2d",{willReadFrequently:!0});o.fillStyle="white",o.fillRect(0,0,s,a),o.filter="grayscale(1)",o.drawImage(e,0,0,e.width,e.height,0,0,s,a);const l=o.getImageData(0,0,s,a).data;return[this.#pl(l),s,a]}static extractContoursFromText(e,t,n,r,i,s){let{fontFamily:a,fontStyle:o,fontWeight:l}=t,c=new OffscreenCanvas(1,1),h=c.getContext("2d",{alpha:!1});const d=h.font=`${o} ${l} 200px ${a}`,{actualBoundingBoxLeft:u,actualBoundingBoxRight:p,actualBoundingBoxAscent:f,actualBoundingBoxDescent:m,fontBoundingBoxAscent:g,fontBoundingBoxDescent:v,width:y}=h.measureText(e),b=1.5,w=Math.ceil(Math.max(Math.abs(u)+Math.abs(p)||0,y)*b),_=Math.ceil(Math.max(Math.abs(f)+Math.abs(m)||200,Math.abs(g)+Math.abs(v)||200)*b);c=new OffscreenCanvas(w,_),h=c.getContext("2d",{alpha:!0,willReadFrequently:!0}),h.font=d,h.filter="grayscale(1)",h.fillStyle="white",h.fillRect(0,0,w,_),h.fillStyle="black",h.fillText(e,.5*w/2,1.5*_/2);const A=this.#pl(h.getImageData(0,0,w,_).data),x=this.#ul(A),E=this.#fl(x),C=this.#ll(A,w,_,E);return this.processDrawnLines({lines:{curves:C,width:w,height:_},pageWidth:n,pageHeight:r,rotation:i,innerMargin:s,mustSmooth:!0,areContours:!0})}static process(e,t,n,r,i){const[s,a,o]=this.#ml(e),[l,c]=this.#dl(s,a,o,Math.hypot(a,o)*this.#rl.sigmaSFactor,this.#rl.sigmaR,this.#rl.kernelSize),h=this.#fl(c),d=this.#ll(l,a,o,h);return this.processDrawnLines({lines:{curves:d,width:a,height:o},pageWidth:t,pageHeight:n,rotation:r,innerMargin:i,mustSmooth:!0,areContours:!0})}static processDrawnLines(e){let{lines:t,pageWidth:n,pageHeight:r,rotation:i,innerMargin:s,mustSmooth:a,areContours:o}=e;i%180!==0&&([n,r]=[r,n]);const{curves:l,width:c,height:h}=t,d=t.thickness??0,u=[],p=Math.min(n/c,r/h),f=p/n,m=p/r,g=[];for(const{points:y}of l){const e=a?this.#hl(y):y;if(!e)continue;g.push(e);const t=e.length,n=new Float32Array(t),r=new Float32Array(3*(2===t?2:t-2));if(u.push({line:r,points:n}),2===t){n[0]=e[0]*f,n[1]=e[1]*m,r.set([NaN,NaN,NaN,NaN,n[0],n[1]],0);continue}let[i,s,o,l]=e;i*=f,s*=m,o*=f,l*=m,n.set([i,s,o,l],0),r.set([NaN,NaN,NaN,NaN,i,s],0);for(let a=4;a<t;a+=2){const t=n[a]=e[a]*f,c=n[a+1]=e[a+1]*m;r.set(ci.createBezierPoints(i,s,o,l,t,c),3*(a-2)),[i,s,o,l]=[o,l,t,c]}}if(0===u.length)return null;const v=o?new xi:new wi;return v.build(u,n,r,1,i,o?0:d,s),{outline:v,newCurves:g,areContours:o,thickness:d,width:c,height:h}}static async compressSignature(e){let t,{outlines:n,areContours:r,thickness:i,width:s,height:a}=e,o=1/0,l=-1/0,c=0;for(const y of n){c+=y.length;for(let e=2,t=y.length;e<t;e++){const t=y[e]-y[e-2];o=Math.min(o,t),l=Math.max(l,t)}}t=o>=-128&&l<=127?Int8Array:o>=-32768&&l<=32767?Int16Array:Int32Array;const h=n.length,d=8+3*h,u=new Uint32Array(d);let p=0;u[p++]=d*Uint32Array.BYTES_PER_ELEMENT+(c-2*h)*t.BYTES_PER_ELEMENT,u[p++]=0,u[p++]=s,u[p++]=a,u[p++]=r?0:1,u[p++]=Math.max(0,Math.floor(i??0)),u[p++]=h,u[p++]=t.BYTES_PER_ELEMENT;for(const y of n)u[p++]=y.length-2,u[p++]=y[0],u[p++]=y[1];const f=new CompressionStream("deflate-raw"),m=f.writable.getWriter();await m.ready,m.write(u);const g=t.prototype.constructor;for(const y of n){const e=new g(y.length-2);for(let t=2,n=y.length;t<n;t++)e[t-2]=y[t]-y[t-2];m.write(e)}m.close();const v=await new Response(f.readable).arrayBuffer();return de(new Uint8Array(v))}static async decompressSignature(e){try{const n=(t=e,Uint8Array.fromBase64?Uint8Array.fromBase64(t):ne(atob(t))),{readable:r,writable:i}=new DecompressionStream("deflate-raw"),s=i.getWriter();await s.ready,s.write(n).then(async()=>{await s.ready,await s.close()}).catch(()=>{});let a=null,o=0;for await(const e of r)a||=new Uint8Array(new Uint32Array(e.buffer,0,4)[0]),a.set(e,o),o+=e.length;const l=new Uint32Array(a.buffer,0,a.length>>2),c=l[1];if(0!==c)throw new Error(`Invalid version: ${c}`);const h=l[2],d=l[3],u=0===l[4],p=l[5],f=l[6],m=l[7],g=[],v=(8+3*f)*Uint32Array.BYTES_PER_ELEMENT;let y;switch(m){case Int8Array.BYTES_PER_ELEMENT:y=new Int8Array(a.buffer,v);break;case Int16Array.BYTES_PER_ELEMENT:y=new Int16Array(a.buffer,v);break;case Int32Array.BYTES_PER_ELEMENT:y=new Int32Array(a.buffer,v)}o=0;for(let e=0;e<f;e++){const t=l[3*e+8],n=new Float32Array(t+2);g.push(n);for(let r=0;r<2;r++)n[r]=l[3*e+8+r+1];for(let e=0;e<t;e++)n[e+2]=n[e]+y[o++]}return{areContours:u,thickness:p,outlines:g,width:h,height:d}}catch(n){return U(`decompressSignature: ${n}`),null}var t}}class Ci extends vi{constructor(){super(),super.updateProperties({fill:Ze._defaultLineColor,"stroke-width":0})}clone(){const e=new Ci;return e.updateAll(this),e}}class ki extends _i{constructor(e){super(e),super.updateProperties({stroke:Ze._defaultLineColor,"stroke-width":1})}clone(){const e=new ki(this._viewParameters);return e.updateAll(this),e}}class Si extends yi{#gl=!1;#vl=null;#yl=null;#bl=null;static _type="signature";static _editorType=(()=>v.SIGNATURE)();static _defaultDrawingOptions=null;constructor(e){super({...e,mustBeCommitted:!0,name:"signatureEditor"}),this._willKeepAspectRatio=!0,this.#yl=e.signatureData||null,this.#vl=null,this.defaultL10nId="pdfjs-editor-signature-editor1"}static initialize(e,t){Ze.initialize(e,t),this._defaultDrawingOptions=new Ci,this._defaultDrawnSignatureOptions=new ki(t.viewParameters)}static getDefaultDrawingOptions(e){const t=this._defaultDrawingOptions.clone();return t.updateProperties(e),t}static get supportMultipleDrawings(){return!1}static get typesMap(){return G(this,"typesMap",new Map)}static get isDrawer(){return!1}get telemetryFinalData(){return{type:"signature",hasDescription:!!this.#vl}}static computeTelemetryFinalData(e){const t=e.get("hasDescription");return{hasAltText:t.get(!0)??0,hasNoAltText:t.get(!1)??0}}get isResizable(){return!0}onScaleChanging(){null!==this._drawId&&super.onScaleChanging()}render(){if(this.div)return this.div;let e,t;const{_isCopy:n}=this;if(n&&(this._isCopy=!1,e=this.x,t=this.y),super.render(),null===this._drawId)if(this.#yl){const{lines:e,mustSmooth:t,areContours:n,description:r,uuid:i,heightInPage:s}=this.#yl,{rawDims:{pageWidth:a,pageHeight:o},rotation:l}=this.parent.viewport,c=Ei.processDrawnLines({lines:e,pageWidth:a,pageHeight:o,rotation:l,innerMargin:Si._INNER_MARGIN,mustSmooth:t,areContours:n});this.addSignature(c,s,r,i)}else this.div.setAttribute("data-l10n-args",JSON.stringify({description:""})),this.div.hidden=!0,this._uiManager.getSignature(this);else this.div.setAttribute("data-l10n-args",JSON.stringify({description:this.#vl||""}));return n&&(this._isCopy=!0,this._moveAfterPaste(e,t)),this.div}setUuid(e){this.#bl=e,this.addEditToolbar()}getUuid(){return this.#bl}get description(){return this.#vl}set description(e){this.#vl=e,this.div&&(this.div.setAttribute("data-l10n-args",JSON.stringify({description:e})),super.addEditToolbar().then(t=>{t?.updateEditSignatureButton(e)}))}getSignaturePreview(){const{newCurves:e,areContours:t,thickness:n,width:r,height:i}=this.#yl,s=Math.max(r,i);return{areContours:t,outline:Ei.processDrawnLines({lines:{curves:e.map(e=>({points:e})),thickness:n,width:r,height:i},pageWidth:s,pageHeight:s,rotation:0,innerMargin:0,mustSmooth:!1,areContours:t}).outline}}get toolbarButtons(){return this._uiManager.signatureManager?[["editSignature",this._uiManager.signatureManager]]:super.toolbarButtons}addSignature(e,t,n,r){const{x:i,y:s}=this,{outline:a}=this.#yl=e;let o;this.#gl=a instanceof xi,this.description=n,this.#gl?o=Si.getDefaultDrawingOptions():(o=Si._defaultDrawnSignatureOptions.clone(),o.updateProperties({"stroke-width":a.thickness})),this._addOutlines({drawOutlines:a,drawingOptions:o});const[,l]=this.pageDimensions;let c=t/l;c=c>=1?.5:c,this.width*=c/this.height,this.width>=1&&(c*=.9/this.width,this.width=.9),this.height=c,this.setDims(),this.x=i,this.y=s,this.center(),this._onResized(),this.onScaleChanging(),this.rotate(),this._uiManager.addToAnnotationStorage(this),this.setUuid(r),this._reportTelemetry({action:"pdfjs.signature.inserted",data:{hasBeenSaved:!!r,hasDescription:!!n}}),this.div.hidden=!1}getFromImage(e){const{rawDims:{pageWidth:t,pageHeight:n},rotation:r}=this.parent.viewport;return Ei.process(e,t,n,r,Si._INNER_MARGIN)}getFromText(e,t){const{rawDims:{pageWidth:n,pageHeight:r},rotation:i}=this.parent.viewport;return Ei.extractContoursFromText(e,t,n,r,i,Si._INNER_MARGIN)}getDrawnSignature(e){const{rawDims:{pageWidth:t,pageHeight:n},rotation:r}=this.parent.viewport;return Ei.processDrawnLines({lines:e,pageWidth:t,pageHeight:n,rotation:r,innerMargin:Si._INNER_MARGIN,mustSmooth:!1,areContours:!1})}createDrawingOptions(e){let{areContours:t,thickness:n}=e;t?this._drawingOptions=Si.getDefaultDrawingOptions():(this._drawingOptions=Si._defaultDrawnSignatureOptions.clone(),this._drawingOptions.updateProperties({"stroke-width":n}))}serialize(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.isEmpty())return null;const{lines:t,points:n}=this.serializeDraw(e),{_drawingOptions:{"stroke-width":r}}=this,i=Object.assign(super.serialize(e),{isSignature:!0,areContours:this.#gl,color:[0,0,0],thickness:this.#gl?0:r});return this.addComment(i),e?(i.paths={lines:t,points:n},i.uuid=this.#bl,i.isCopy=!0):i.lines=t,this.#vl&&(i.accessibilityData={type:"Figure",alt:this.#vl}),i}static deserializeDraw(e,t,n,r,i,s){return s.areContours?xi.deserialize(e,t,n,r,i,s):wi.deserialize(e,t,n,r,i,s)}static async deserialize(e,t,n){const r=await super.deserialize(e,t,n);return r.#gl=e.areContours,r.description=e.accessibilityData?.alt||"",r.#bl=e.uuid,r}}class Ti extends Ze{#wl=null;#_l=null;#Al=null;#xl=null;#El=null;#Cl="";#kl=null;#Sl=!1;#Tl=null;#Dl=!1;#Ml=!1;static _type="stamp";static _editorType=(()=>v.STAMP)();constructor(e){super({...e,name:"stampEditor"}),this.#xl=e.bitmapUrl,this.#El=e.bitmapFile,this.defaultL10nId="pdfjs-editor-stamp-editor"}static initialize(e,t){Ze.initialize(e,t)}static isHandlingMimeForPasting(e){return Pe.includes(e)}static paste(e,t){t.pasteEditor({mode:v.STAMP},{bitmapFile:e.getAsFile()})}altTextFinish(){this._uiManager.useNewAltTextFlow&&(this.div.hidden=!1),super.altTextFinish()}get telemetryFinalData(){return{type:"stamp",hasAltText:!!this.altTextData?.altText}}static computeTelemetryFinalData(e){const t=e.get("hasAltText");return{hasAltText:t.get(!0)??0,hasNoAltText:t.get(!1)??0}}#Pl(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];e?(this.#wl=e.bitmap,t||(this.#_l=e.id,this.#Dl=e.isSvg),e.file&&(this.#Cl=e.file.name),this.#Il()):this.remove()}#Fl(){if(this.#Al=null,this._uiManager.enableWaiting(!1),this.#kl)if(this._uiManager.useNewAltTextWhenAddingImage&&this._uiManager.useNewAltTextFlow&&this.#wl)this.addEditToolbar().then(()=>{this._editToolbar.hide(),this._uiManager.editAltText(this,!0)});else{if(!this._uiManager.useNewAltTextWhenAddingImage&&this._uiManager.useNewAltTextFlow&&this.#wl){this._reportTelemetry({action:"pdfjs.image.image_added",data:{alt_text_modal:!1,alt_text_type:"empty"}});try{this.mlGuessAltText()}catch{}}this.div.focus()}}async mlGuessAltText(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(this.hasAltTextData())return null;const{mlManager:n}=this._uiManager;if(!n)throw new Error("No ML.");if(!await n.isEnabledFor("altText"))throw new Error("ML isn't enabled for alt text.");const{data:r,width:i,height:s}=e||this.copyCanvas(null,null,!0).imageData,a=await n.guess({name:"altText",request:{data:r,width:i,height:s,channels:r.length/(i*s)}});if(!a)throw new Error("No response from the AI service.");if(a.error)throw new Error("Error from the AI service.");if(a.cancel)return null;if(!a.output)throw new Error("No valid response from the AI service.");const o=a.output;return await this.setGuessedAltText(o),t&&!this.hasAltTextData()&&(this.altTextData={alt:o,decorative:!1}),o}#Rl(){if(this.#_l)return this._uiManager.enableWaiting(!0),void this._uiManager.imageManager.getFromId(this.#_l).then(e=>this.#Pl(e,!0)).finally(()=>this.#Fl());if(this.#xl){const e=this.#xl;return this.#xl=null,this._uiManager.enableWaiting(!0),void(this.#Al=this._uiManager.imageManager.getFromUrl(e).then(e=>this.#Pl(e)).finally(()=>this.#Fl()))}if(this.#El){const e=this.#El;return this.#El=null,this._uiManager.enableWaiting(!0),void(this.#Al=this._uiManager.imageManager.getFromFile(e).then(e=>this.#Pl(e)).finally(()=>this.#Fl()))}const e=document.createElement("input");e.type="file",e.accept=Pe.join(",");const t=this._uiManager._signal;this.#Al=new Promise(n=>{e.addEventListener("change",async()=>{if(e.files&&0!==e.files.length){this._uiManager.enableWaiting(!0);const t=await this._uiManager.imageManager.getFromFile(e.files[0]);this._reportTelemetry({action:"pdfjs.image.image_selected",data:{alt_text_modal:this._uiManager.useNewAltTextFlow}}),this.#Pl(t)}else this.remove();n()},{signal:t}),e.addEventListener("cancel",()=>{this.remove(),n()},{signal:t})}).finally(()=>this.#Fl()),e.click()}remove(){this.#_l&&(this.#wl=null,this._uiManager.imageManager.deleteId(this.#_l),this.#kl?.remove(),this.#kl=null,this.#Tl&&(clearTimeout(this.#Tl),this.#Tl=null)),super.remove()}rebuild(){this.parent?(super.rebuild(),null!==this.div&&(this.#_l&&null===this.#kl&&this.#Rl(),this.isAttachedToDOM||this.parent.add(this))):this.#_l&&this.#Rl()}onceAdded(e){this._isDraggable=!0,e&&this.div.focus()}isEmpty(){return!(this.#Al||this.#wl||this.#xl||this.#El||this.#_l||this.#Sl)}get toolbarButtons(){return[["altText",this.createAltText()]]}get isResizable(){return!0}render(){if(this.div)return this.div;let e,t;return this._isCopy&&(e=this.x,t=this.y),super.render(),this.div.hidden=!0,this.createAltText(),this.#Sl||(this.#wl?this.#Il():this.#Rl()),this._isCopy&&this._moveAfterPaste(e,t),this._uiManager.addShouldRescale(this),this.div}setCanvas(e,t){const{id:n,bitmap:r}=this._uiManager.imageManager.getFromCanvas(e,t);t.remove(),n&&this._uiManager.imageManager.isValidId(n)&&(this.#_l=n,r&&(this.#wl=r),this.#Sl=!1,this.#Il())}_onResized(){this.onScaleChanging()}onScaleChanging(){if(!this.parent)return;null!==this.#Tl&&clearTimeout(this.#Tl);this.#Tl=setTimeout(()=>{this.#Tl=null,this.#Nl()},200)}#Il(){const{div:e}=this;let{width:t,height:n}=this.#wl;const[r,i]=this.pageDimensions,s=.75;if(this.width)t=this.width*r,n=this.height*i;else if(t>s*r||n>s*i){const e=Math.min(s*r/t,s*i/n);t*=e,n*=e}this._uiManager.enableWaiting(!1);const a=this.#kl=document.createElement("canvas");a.setAttribute("role","img"),this.addContainer(a),this.width=t/r,this.height=n/i,this.setDims(),this._initialOptions?.isCentered?this.center():this.fixAndSetPosition(),this._initialOptions=null,this._uiManager.useNewAltTextWhenAddingImage&&this._uiManager.useNewAltTextFlow&&!this.annotationElementId||(e.hidden=!1),this.#Nl(),this.#Ml||(this.parent.addUndoableEditor(this),this.#Ml=!0),this._reportTelemetry({action:"inserted_image"}),this.#Cl&&this.div.setAttribute("aria-description",this.#Cl),this.annotationElementId||this._uiManager.a11yAlert("pdfjs-editor-stamp-added-alert")}copyCanvas(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];e||(e=224);const{width:r,height:i}=this.#wl,s=new Me;let a=this.#wl,o=r,l=i,c=null;if(t){if(r>t||i>t){const e=Math.min(t/r,t/i);o=Math.floor(r*e),l=Math.floor(i*e)}c=document.createElement("canvas");const e=c.width=Math.ceil(o*s.sx),n=c.height=Math.ceil(l*s.sy);this.#Dl||(a=this.#Ll(e,n));const h=c.getContext("2d");h.filter=this._uiManager.hcmFilter;let d="white",u="#cfcfd8";"none"!==this._uiManager.hcmFilter?u="black":Ie.isDarkMode&&(d="#8f8f9d",u="#42414d");const p=15,f=p*s.sx,m=p*s.sy,g=new OffscreenCanvas(2*f,2*m),v=g.getContext("2d");v.fillStyle=d,v.fillRect(0,0,2*f,2*m),v.fillStyle=u,v.fillRect(0,0,f,m),v.fillRect(f,m,f,m),h.fillStyle=h.createPattern(g,"repeat"),h.fillRect(0,0,e,n),h.drawImage(a,0,0,a.width,a.height,0,0,e,n)}let h=null;if(n){let t,n;if(s.symmetric&&a.width<e&&a.height<e)t=a.width,n=a.height;else if(a=this.#wl,r>e||i>e){const s=Math.min(e/r,e/i);t=Math.floor(r*s),n=Math.floor(i*s),this.#Dl||(a=this.#Ll(t,n))}const o=new OffscreenCanvas(t,n).getContext("2d",{willReadFrequently:!0});o.drawImage(a,0,0,a.width,a.height,0,0,t,n),h={width:t,height:n,data:o.getImageData(0,0,t,n).data}}return{canvas:c,width:o,height:l,imageData:h}}#Ll(e,t){const{width:n,height:r}=this.#wl;let i=n,s=r,a=this.#wl;for(;i>2*e||s>2*t;){const n=i,r=s;i>2*e&&(i=i>=16384?Math.floor(i/2)-1:Math.ceil(i/2)),s>2*t&&(s=s>=16384?Math.floor(s/2)-1:Math.ceil(s/2));const o=new OffscreenCanvas(i,s);o.getContext("2d").drawImage(a,0,0,n,r,0,0,i,s),a=o.transferToImageBitmap()}return a}#Nl(){const[e,t]=this.parentDimensions,{width:n,height:r}=this,i=new Me,s=Math.ceil(n*e*i.sx),a=Math.ceil(r*t*i.sy),o=this.#kl;if(!o||o.width===s&&o.height===a)return;o.width=s,o.height=a;const l=this.#Dl?this.#wl:this.#Ll(s,a),c=o.getContext("2d");c.filter=this._uiManager.hcmFilter,c.drawImage(l,0,0,l.width,l.height,0,0,s,a)}#Ol(e){if(e){if(this.#Dl){const e=this._uiManager.imageManager.getSvgUrl(this.#_l);if(e)return e}const e=document.createElement("canvas");({width:e.width,height:e.height}=this.#wl);return e.getContext("2d").drawImage(this.#wl,0,0),e.toDataURL()}if(this.#Dl){const[e,t]=this.pageDimensions,n=Math.round(this.width*e*me.PDF_TO_CSS_UNITS),r=Math.round(this.height*t*me.PDF_TO_CSS_UNITS),i=new OffscreenCanvas(n,r);return i.getContext("2d").drawImage(this.#wl,0,0,this.#wl.width,this.#wl.height,0,0,n,r),i.transferToImageBitmap()}return structuredClone(this.#wl)}static async deserialize(e,t,n){let r=null,i=!1;if(e instanceof ii){const{data:{rect:s,rotation:a,id:o,structParent:l,popupRef:c,richText:h,contentsObj:d,creationDate:u,modificationDate:p},container:f,parent:{page:{pageNumber:m}},canvas:g}=e;let y,b;g?(delete e.canvas,({id:y,bitmap:b}=n.imageManager.getFromCanvas(f.id,g)),g.remove()):(i=!0,e._hasNoCanvas=!0);const w=(await t._structTree.getAriaAttributes(`${ce}${o}`))?.get("aria-label")||"";r=e={annotationType:v.STAMP,bitmapId:y,bitmap:b,pageIndex:m-1,rect:s.slice(0),rotation:a,annotationElementId:o,id:o,deleted:!1,accessibilityData:{decorative:!1,altText:w},isSvg:!1,structParent:l,popupRef:c,richText:h,comment:d?.str||null,creationDate:u,modificationDate:p}}const s=await super.deserialize(e,t,n),{rect:a,bitmap:o,bitmapUrl:l,bitmapId:c,isSvg:h,accessibilityData:d}=e;i?(n.addMissingCanvas(e.id,s),s.#Sl=!0):c&&n.imageManager.isValidId(c)?(s.#_l=c,o&&(s.#wl=o)):s.#xl=l,s.#Dl=h;const[u,p]=s.pageDimensions;return s.width=(a[2]-a[0])/u,s.height=(a[3]-a[1])/p,d&&(s.altTextData=d),s._initialData=r,e.comment&&s.setCommentData(e),s.#Ml=!!r,s}serialize(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(this.isEmpty())return null;if(this.deleted)return this.serializeDeleted();const n=Object.assign(super.serialize(e),{bitmapId:this.#_l,isSvg:this.#Dl});if(this.addComment(n),e)return n.bitmapUrl=this.#Ol(!0),n.accessibilityData=this.serializeAltText(!0),n.isCopy=!0,n;const{decorative:r,altText:i}=this.serializeAltText(!1);if(!r&&i&&(n.accessibilityData={type:"Figure",alt:i}),this.annotationElementId){const e=this.#_a(n);return e.isSame?null:(e.isSameAltText?delete n.accessibilityData:n.accessibilityData.structParent=this._initialData.structParent??-1,n.id=this.annotationElementId,delete n.bitmapId,n)}if(null===t)return n;t.stamps||=new Map;const s=this.#Dl?(n.rect[2]-n.rect[0])*(n.rect[3]-n.rect[1]):null;if(t.stamps.has(this.#_l)){if(this.#Dl){const e=t.stamps.get(this.#_l);s>e.area&&(e.area=s,e.serialized.bitmap.close(),e.serialized.bitmap=this.#Ol(!1))}}else t.stamps.set(this.#_l,{area:s,serialized:n}),n.bitmap=this.#Ol(!1);return n}#_a(e){const{pageIndex:t,accessibilityData:{altText:n}}=this._initialData,r=e.pageIndex===t,i=(e.accessibilityData?.alt||"")===n;return{isSame:!this.hasEditedComment&&!this._hasBeenMoved&&!this._hasBeenResized&&r&&i,isSameAltText:i}}renderAnnotationElement(e){return this.deleted?(e.hide(),null):(e.updateEdited({rect:this.getPDFRect(),popup:this.comment}),null)}}class Di{#ia;#Bl=!1;#$l=null;#zl=null;#jl=null;#Ul=(()=>new Map)();#Hl=!1;#Vl=!1;#ql=!1;#Wl=null;#Gl=null;#Kl=null;#Xl=null;#Yl=null;#Zl=-1;#v;static _initialized=!1;static#q=(()=>new Map([li,Ai,Ti,gi,Si].map(e=>[e._editorType,e])))();constructor(e){let{uiManager:t,pageIndex:n,div:r,structTreeLayer:i,accessibilityManager:s,annotationLayer:a,drawLayer:o,textLayer:l,viewport:c,l10n:h}=e;const d=[...Di.#q.values()];if(!Di._initialized){Di._initialized=!0;for(const e of d)e.initialize(h,t)}t.registerEditorTypes(d),this.#v=t,this.pageIndex=n,this.div=r,this.#ia=s,this.#$l=a,this.viewport=c,this.#Kl=l,this.drawLayer=o,this._structTree=i,this.#v.addLayer(this)}get isEmpty(){return 0===this.#Ul.size}get isInvisible(){return this.isEmpty&&this.#v.getMode()===v.NONE}updateToolbar(e){this.#v.updateToolbar(e)}updateMode(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.#v.getMode();switch(this.#Jl(),e){case v.NONE:return this.div.classList.toggle("nonEditing",!0),this.disableTextSelection(),this.togglePointerEvents(!1),this.toggleAnnotationLayerPointerEvents(!0),void this.disableClick();case v.INK:this.disableTextSelection(),this.togglePointerEvents(!0),this.enableClick();break;case v.HIGHLIGHT:this.enableTextSelection(),this.togglePointerEvents(!1),this.disableClick();break;default:this.disableTextSelection(),this.togglePointerEvents(!0),this.enableClick()}this.toggleAnnotationLayerPointerEvents(!1);const{classList:t}=this.div;if(t.toggle("nonEditing",!1),e===v.POPUP)t.toggle("commentEditing",!0);else{t.toggle("commentEditing",!1);for(const n of Di.#q.values())t.toggle(`${n._type}Editing`,e===n._editorType)}this.div.hidden=!1}hasTextLayer(e){return e===this.#Kl?.div}setEditingState(e){this.#v.setEditingState(e)}addCommands(e){this.#v.addCommands(e)}cleanUndoStack(e){this.#v.cleanUndoStack(e)}toggleDrawing(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.div.classList.toggle("drawing",!e)}togglePointerEvents(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.div.classList.toggle("disabled",!e)}toggleAnnotationLayerPointerEvents(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.#$l?.div.classList.toggle("disabled",!e)}get#Ql(){return 0!==this.#Ul.size?this.#Ul.values():this.#v.getEditors(this.pageIndex)}async enable(){this.#ql=!0,this.div.tabIndex=0,this.togglePointerEvents(!0),this.div.classList.toggle("nonEditing",!1),this.#Yl?.abort(),this.#Yl=null;const e=new Set;for(const n of this.#Ql)n.enableEditing(),n.show(!0),n.annotationElementId&&(this.#v.removeChangedExistingAnnotation(n),e.add(n.annotationElementId));const t=this.#$l;if(t)for(const n of t.getEditableAnnotations()){if(n.hide(),this.#v.isDeletedAnnotationElement(n.data.id))continue;if(e.has(n.data.id))continue;const t=await this.deserialize(n);t&&(this.addOrRebuild(t),t.enableEditing())}this.#ql=!1,this.#v._eventBus.dispatch("editorsrendered",{source:this,pageNumber:this.pageIndex+1})}disable(){if(this.#Vl=!0,this.div.tabIndex=-1,this.togglePointerEvents(!1),this.div.classList.toggle("nonEditing",!0),this.#Kl&&!this.#Yl){this.#Yl=new AbortController;const e=this.#v.combinedSignal(this.#Yl);this.#Kl.div.addEventListener("pointerdown",e=>{const{clientX:t,clientY:n,timeStamp:r}=e;if(r-this.#Zl>500)return void(this.#Zl=r);this.#Zl=-1;const{classList:i}=this.div;i.toggle("getElements",!0);const s=document.elementsFromPoint(t,n);if(i.toggle("getElements",!1),!this.div.contains(s[0]))return;let a;const o=new RegExp(`^${g}[0-9]+$`);for(const c of s)if(o.test(c.id)){a=c.id;break}if(!a)return;const l=this.#Ul.get(a);null===l?.annotationElementId&&(e.stopPropagation(),e.preventDefault(),l.dblclick(e))},{signal:e,capture:!0})}const e=this.#$l;if(e){const t=new Map,n=new Map;for(const i of this.#Ql)i.disableEditing(),i.annotationElementId?null===i.serialize()?(n.set(i.annotationElementId,i),this.getEditableAnnotation(i.annotationElementId)?.show(),i.remove()):t.set(i.annotationElementId,i):i.updateFakeAnnotationElement(e);const r=e.getEditableAnnotations();for(const e of r){const{id:r}=e.data;if(this.#v.isDeletedAnnotationElement(r)){e.updateEdited({deleted:!0});continue}let i=n.get(r);i?(i.resetAnnotationElement(e),i.show(!1),e.show()):(i=t.get(r),i&&(this.#v.addChangedExistingAnnotation(i),i.renderAnnotationElement(e)&&i.show(!1)),e.show())}}this.#Jl(),this.isEmpty&&(this.div.hidden=!0);const{classList:t}=this.div;for(const n of Di.#q.values())t.remove(`${n._type}Editing`);this.disableTextSelection(),this.toggleAnnotationLayerPointerEvents(!0),this.#Vl=!1}getEditableAnnotation(e){return this.#$l?.getEditableAnnotation(e)||null}setActiveEditor(e){this.#v.getActive()!==e&&this.#v.setActiveEditor(e)}enableTextSelection(){if(this.div.tabIndex=-1,this.#Kl?.div&&!this.#Xl){this.#Xl=new AbortController;const e=this.#v.combinedSignal(this.#Xl);this.#Kl.div.addEventListener("pointerdown",this.#ec.bind(this),{signal:e}),this.#Kl.div.classList.add("highlighting")}}disableTextSelection(){this.div.tabIndex=0,this.#Kl?.div&&this.#Xl&&(this.#Xl.abort(),this.#Xl=null,this.#Kl.div.classList.remove("highlighting"))}#ec(e){this.#v.unselectAll();const{target:t}=e;if(t===this.#Kl.div||("img"===t.getAttribute("role")||t.classList.contains("endOfContent"))&&this.#Kl.div.contains(t)){const{isMac:t}=re.platform;if(0!==e.button||e.ctrlKey&&t)return;this.#v.showAllEditors("highlight",!0,!0),this.#Kl.div.classList.add("free"),this.toggleDrawing(),gi.startHighlighting(this,"ltr"===this.#v.direction,{target:this.#Kl.div,x:e.x,y:e.y}),this.#Kl.div.addEventListener("pointerup",()=>{this.#Kl.div.classList.remove("free"),this.toggleDrawing(!0)},{once:!0,signal:this.#v._signal}),e.preventDefault()}}enableClick(){if(this.#zl)return;this.#zl=new AbortController;const e=this.#v.combinedSignal(this.#zl);this.div.addEventListener("pointerdown",this.pointerdown.bind(this),{signal:e});const t=this.pointerup.bind(this);this.div.addEventListener("pointerup",t,{signal:e}),this.div.addEventListener("pointercancel",t,{signal:e})}disableClick(){this.#zl?.abort(),this.#zl=null}attach(e){this.#Ul.set(e.id,e);const{annotationElementId:t}=e;t&&this.#v.isDeletedAnnotationElement(t)&&this.#v.removeDeletedAnnotationElement(e)}detach(e){this.#Ul.delete(e.id),this.#ia?.removePointerInTextLayer(e.contentDiv),!this.#Vl&&e.annotationElementId&&this.#v.addDeletedAnnotationElement(e)}remove(e){this.detach(e),this.#v.removeEditor(e),e.div.remove(),e.isAttachedToDOM=!1}changeParent(e){e.parent!==this&&(e.parent&&e.annotationElementId&&(this.#v.addDeletedAnnotationElement(e.annotationElementId),Ze.deleteAnnotationElement(e),e.annotationElementId=null),this.attach(e),e.parent?.detach(e),e.setParent(this),e.div&&e.isAttachedToDOM&&(e.div.remove(),this.div.append(e.div)))}add(e){if(e.parent!==this||!e.isAttachedToDOM){if(this.changeParent(e),this.#v.addEditor(e),this.attach(e),!e.isAttachedToDOM){const t=e.render();this.div.append(t),e.isAttachedToDOM=!0}e.fixAndSetPosition(),e.onceAdded(!this.#ql),this.#v.addToAnnotationStorage(e),e._reportTelemetry(e.telemetryInitialData)}}moveEditorInDOM(e){if(!e.isAttachedToDOM)return;const{activeElement:t}=document;e.div.contains(t)&&!this.#jl&&(e._focusEventsAllowed=!1,this.#jl=setTimeout(()=>{this.#jl=null,e.div.contains(document.activeElement)?e._focusEventsAllowed=!0:(e.div.addEventListener("focusin",()=>{e._focusEventsAllowed=!0},{once:!0,signal:this.#v._signal}),t.focus())},0)),e._structTreeParentId=this.#ia?.moveElementInDOM(this.div,e.div,e.contentDiv,!0)}addOrRebuild(e){e.needsToBeRebuilt()?(e.parent||=this,e.rebuild(),e.show()):this.add(e)}addUndoableEditor(e){this.addCommands({cmd:()=>e._uiManager.rebuild(e),undo:()=>{e.remove()},mustExec:!1})}getEditorByUID(e){for(const t of this.#Ul.values())if(t.uid===e)return t;return null}getNextId(){return this.#v.getId()}get#tc(){return Di.#q.get(this.#v.getMode())}combinedSignal(e){return this.#v.combinedSignal(e)}#nc(e){const t=this.#tc;return t?new t.prototype.constructor(e):null}canCreateNewEmptyEditor(){return this.#tc?.canCreateNewEmptyEditor()}async pasteEditor(e,t){this.updateToolbar(e),await this.#v.updateMode(e.mode);const{offsetX:n,offsetY:r}=this.#rc(),i=this.getNextId(),s=this.#nc({parent:this,id:i,x:n,y:r,uiManager:this.#v,isCentered:!0,...t});s&&this.add(s)}async deserialize(e){return await(Di.#q.get(e.annotationType??e.annotationEditorType)?.deserialize(e,this,this.#v))||null}createAndAddNewEditor(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const r=this.getNextId(),i=this.#nc({parent:this,id:r,x:e.offsetX,y:e.offsetY,uiManager:this.#v,isCentered:t,...n});return i&&this.add(i),i}get boundingClientRect(){return this.div.getBoundingClientRect()}#rc(){const{x:e,y:t,width:n,height:r}=this.boundingClientRect,i=Math.max(0,e),s=Math.max(0,t),a=(i+Math.min(window.innerWidth,e+n))/2-e,o=(s+Math.min(window.innerHeight,t+r))/2-t,[l,c]=this.viewport.rotation%180===0?[a,o]:[o,a];return{offsetX:l,offsetY:c}}addNewEditor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.createAndAddNewEditor(this.#rc(),!0,e)}setSelected(e){this.#v.setSelected(e)}toggleSelected(e){this.#v.toggleSelected(e)}unselect(e){this.#v.unselect(e)}pointerup(e){const{isMac:t}=re.platform;if(0!==e.button||e.ctrlKey&&t)return;if(e.target!==this.div)return;if(!this.#Hl)return;if(this.#Hl=!1,this.#tc?.isDrawer&&this.#tc.supportMultipleDrawings)return;if(!this.#Bl)return void(this.#Bl=!0);const n=this.#v.getMode();n!==v.STAMP&&n!==v.SIGNATURE?this.createAndAddNewEditor(e,!1):this.#v.unselectAll()}pointerdown(e){if(this.#v.getMode()===v.HIGHLIGHT&&this.enableTextSelection(),this.#Hl)return void(this.#Hl=!1);const{isMac:t}=re.platform;if(0!==e.button||e.ctrlKey&&t)return;if(e.target!==this.div)return;if(this.#Hl=!0,this.#tc?.isDrawer)return void this.startDrawingSession(e);const n=this.#v.getActive();this.#Bl=!n||n.isEmpty()}startDrawingSession(e){if(this.div.focus({preventScroll:!0}),this.#Wl)return void this.#tc.startDrawing(this,this.#v,!1,e);this.#v.setCurrentDrawingSession(this),this.#Wl=new AbortController;const t=this.#v.combinedSignal(this.#Wl);this.div.addEventListener("blur",e=>{let{relatedTarget:t}=e;t&&!this.div.contains(t)&&(this.#Gl=null,this.commitOrRemove())},{signal:t}),this.#tc.startDrawing(this,this.#v,!1,e)}pause(e){if(e){const{activeElement:e}=document;return void(this.div.contains(e)&&(this.#Gl=e))}this.#Gl&&setTimeout(()=>{this.#Gl?.focus(),this.#Gl=null},0)}endDrawingSession(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this.#Wl?(this.#v.setCurrentDrawingSession(null),this.#Wl.abort(),this.#Wl=null,this.#Gl=null,this.#tc.endDrawing(e)):null}findNewParent(e,t,n){const r=this.#v.findParent(t,n);return null!==r&&r!==this&&(r.changeParent(e),!0)}commitOrRemove(){return!!this.#Wl&&(this.endDrawingSession(),!0)}onScaleChanging(){this.#Wl&&this.#tc.onScaleChangingWhenDrawing(this)}destroy(){this.commitOrRemove(),this.#v.getActive()?.parent===this&&(this.#v.commitOrRemove(),this.#v.setActiveEditor(null)),this.#jl&&(clearTimeout(this.#jl),this.#jl=null);for(const e of this.#Ul.values())this.#ia?.removePointerInTextLayer(e.contentDiv),e.setParent(null),e.isAttachedToDOM=!1,e.div.remove();this.div=null,this.#Ul.clear(),this.#v.removeLayer(this)}#Jl(){for(const e of this.#Ul.values())e.isEmpty()&&e.remove()}render(e){let{viewport:t}=e;this.viewport=t,De(this.div,t);for(const n of this.#v.getEditors(this.pageIndex))this.add(n),n.rebuild();this.updateMode()}update(e){let{viewport:t}=e;this.#v.commitOrRemove(),this.#Jl();const n=this.viewport.rotation,r=t.rotation;if(this.viewport=t,De(this.div,{rotation:r}),n!==r)for(const i of this.#Ul.values())i.rotate(r)}get pageDimensions(){const{pageWidth:e,pageHeight:t}=this.viewport.rawDims;return[e,t]}get scale(){return this.#v.viewParameters.realScale}}class Mi{#Ts=null;#ic=(()=>new Map)();#sc=(()=>new Map)();static#_=0;constructor(e){let{pageIndex:t}=e;this.pageIndex=t}setParent(e){if(this.#Ts){if(this.#Ts!==e){if(this.#ic.size>0)for(const t of this.#ic.values())t.remove(),e.append(t);this.#Ts=e}}else this.#Ts=e}static get _svgFactory(){return G(this,"_svgFactory",new Dr)}static#ac(e,t){let[n,r,i,s]=t;const{style:a}=e;a.top=100*r+"%",a.left=100*n+"%",a.width=100*i+"%",a.height=100*s+"%"}#oc(){const e=Mi._svgFactory.create(1,1,!0);return this.#Ts.append(e),e.setAttribute("aria-hidden",!0),e}#lc(e,t){const n=Mi._svgFactory.createElement("clipPath");e.append(n);const r=`clip_${t}`;n.setAttribute("id",r),n.setAttribute("clipPathUnits","objectBoundingBox");const i=Mi._svgFactory.createElement("use");return n.append(i),i.setAttribute("href",`#${t}`),i.classList.add("clip"),r}#cc(e,t){for(const[n,r]of Object.entries(t))null===r?e.removeAttribute(n):e.setAttribute(n,r)}draw(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];const r=Mi.#_++,i=this.#oc(),s=Mi._svgFactory.createElement("defs");i.append(s);const a=Mi._svgFactory.createElement("path");s.append(a);const o=`path_p${this.pageIndex}_${r}`;a.setAttribute("id",o),a.setAttribute("vector-effect","non-scaling-stroke"),t&&this.#sc.set(r,a);const l=n?this.#lc(s,o):null,c=Mi._svgFactory.createElement("use");return i.append(c),c.setAttribute("href",`#${o}`),this.updateProperties(i,e),this.#ic.set(r,i),{id:r,clipPathId:`url(#${l})`}}drawOutline(e,t){const n=Mi.#_++,r=this.#oc(),i=Mi._svgFactory.createElement("defs");r.append(i);const s=Mi._svgFactory.createElement("path");i.append(s);const a=`path_p${this.pageIndex}_${n}`;let o;if(s.setAttribute("id",a),s.setAttribute("vector-effect","non-scaling-stroke"),t){const e=Mi._svgFactory.createElement("mask");i.append(e),o=`mask_p${this.pageIndex}_${n}`,e.setAttribute("id",o),e.setAttribute("maskUnits","objectBoundingBox");const t=Mi._svgFactory.createElement("rect");e.append(t),t.setAttribute("width","1"),t.setAttribute("height","1"),t.setAttribute("fill","white");const r=Mi._svgFactory.createElement("use");e.append(r),r.setAttribute("href",`#${a}`),r.setAttribute("stroke","none"),r.setAttribute("fill","black"),r.setAttribute("fill-rule","nonzero"),r.classList.add("mask")}const l=Mi._svgFactory.createElement("use");r.append(l),l.setAttribute("href",`#${a}`),o&&l.setAttribute("mask",`url(#${o})`);const c=l.cloneNode();return r.append(c),l.classList.add("mainOutline"),c.classList.add("secondaryOutline"),this.updateProperties(r,e),this.#ic.set(n,r),n}finalizeDraw(e,t){this.#sc.delete(e),this.updateProperties(e,t)}updateProperties(e,t){if(!t)return;const{root:n,bbox:r,rootClass:i,path:s}=t,a="number"===typeof e?this.#ic.get(e):e;if(a){if(n&&this.#cc(a,n),r&&Mi.#ac(a,r),i){const{classList:e}=a;for(const[t,n]of Object.entries(i))e.toggle(t,n)}if(s){const e=a.firstChild.firstChild;this.#cc(e,s)}}}updateParent(e,t){if(t===this)return;const n=this.#ic.get(e);n&&(t.#Ts.append(n),this.#ic.delete(e),t.#ic.set(e,n))}remove(e){this.#sc.delete(e),null!==this.#Ts&&(this.#ic.get(e).remove(),this.#ic.delete(e))}destroy(){this.#Ts=null;for(const e of this.#ic.values())e.remove();this.#ic.clear(),this.#sc.clear()}}globalThis._pdfjsTestingUtils={HighlightOutliner:ui},globalThis.pdfjsLib={AbortException:ee,AnnotationEditorLayer:Di,AnnotationEditorParamsType:y,AnnotationEditorType:v,AnnotationEditorUIManager:Ge,AnnotationLayer:ai,AnnotationMode:m,AnnotationType:k,applyOpacity:function(e,t,n,r){const i=255*(1-(r=Math.min(Math.max(r??1,0),1)));return[e=Math.round(e*r+i),t=Math.round(t*r+i),n=Math.round(n*r+i)]},build:"f56dc8601",ColorPicker:xr,createValidAbsoluteUrl:q,CSSConstants:class{static get commentForegroundColor(){const e=document.createElement("span");e.classList.add("comment","sidebar");const{style:t}=e;t.width=t.height="0",t.display="none",t.color="var(--comment-fg-color)",document.body.append(e);const{color:n}=window.getComputedStyle(e);return e.remove(),G(this,"commentForegroundColor",ke(n))}},DOMSVGFactory:Dr,DrawLayer:Mi,FeatureTest:re,fetchData:ge,findContrastColor:function(e,t){const n=e[0]+256*e[1]+65536*e[2]+16777216*t[0]+4294967296*t[1]+1099511627776*t[2];let r=Oe.get(n);if(r)return r;const i=new Float32Array(9),s=i.subarray(0,3),a=i.subarray(3,6);Fe(e,a);const o=i.subarray(6,9);Fe(t,o);const l=o[2]<.5,c=l?12:4.5;if(a[2]=l?Math.sqrt(a[2]):1-Math.sqrt(1-a[2]),Le(a,o,s)<c){let e,t;l?(e=a[2],t=1):(e=0,t=a[2]);const n=.005;for(;t-e>n;){const n=a[2]=(e+t)/2;l===Le(a,o,s)<c?e=n:t=n}a[2]=l?t:e}return Re(a,s),r=se.makeHexColor(Math.round(255*s[0]),Math.round(255*s[1]),Math.round(255*s[2])),Oe.set(n,r),r},getDocument:fr,getFilenameFromUrl:function(e){return[e]=e.split(/[#?]/,1),e.substring(e.lastIndexOf("/")+1)},getPdfFilenameFromUrl:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"document.pdf";if("string"!==typeof e)return t;if(be(e))return U('getPdfFilenameFromUrl: ignore "data:"-URL for performance reasons.'),t;const n=(e=>{try{return new URL(e)}catch{try{return new URL(decodeURIComponent(e))}catch{try{return new URL(e,"https://foo.bar")}catch{try{return new URL(decodeURIComponent(e),"https://foo.bar")}catch{return null}}}}})(e);if(!n)return t;const r=e=>{try{let t=decodeURIComponent(e);return t.includes("/")?(t=t.split("/").at(-1),t.test(/^\.pdf$/i)?t:e):t}catch{return e}},i=/\.pdf$/i,s=n.pathname.split("/").at(-1);if(i.test(s))return r(s);if(n.searchParams.size>0){const e=Array.from(n.searchParams.values()).reverse();for(const n of e)if(i.test(n))return r(n);const t=Array.from(n.searchParams.keys()).reverse();for(const n of t)if(i.test(n))return r(n)}if(n.hash){const e=/[^/?#=]+\.pdf\b(?!.*\.pdf\b)/i.exec(n.hash);if(e)return r(e[0])}return t},getRGB:ke,getUuid:le,getXfaPageViewport:function(e,t){let{scale:n=1,rotation:r=0}=t;const{width:i,height:s}=e.attributes.style,a=[0,0,parseInt(i),parseInt(s)];return new ve({viewBox:a,userUnit:1,scale:n,rotation:r})},GlobalWorkerOptions:Bn,ImageKind:C,InvalidPDFException:Z,isDataScheme:be,isPdfFile:we,isValidExplicitDest:ht,MathClamp:he,noContextMenu:xe,normalizeUnicode:function(e){return ae||(ae=/([\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,oe=new Map([["\ufb05","\u017ft"]])),e.replaceAll(ae,(e,t,n)=>t?t.normalize("NFKC"):oe.get(n))},OPS:F,OutputScale:Me,PasswordResponses:{NEED_PASSWORD:1,INCORRECT_PASSWORD:2},PDFDataRangeTransport:gr,PDFDateString:Ce,PDFWorker:br,PermissionFlag:{PRINT:4,MODIFY_CONTENTS:8,COPY:16,MODIFY_ANNOTATIONS:32,FILL_INTERACTIVE_FORMS:256,COPY_FOR_ACCESSIBILITY:512,ASSEMBLE:1024,PRINT_HIGH_QUALITY:2048},PixelsPerInch:me,RenderingCancelledException:ye,renderRichText:Be,ResponseException:J,setLayerDimensions:De,shadow:G,SignatureExtractor:Ei,stopEvent:Ee,SupportedImageMimeTypes:Pe,TextLayer:pr,TouchManager:Ye,updateUrlHash:W,Util:se,VerbosityLevel:I,version:"5.4.296",XfaLayer:pe}},17402(e,t,n){"use strict";n.d(t,{A:()=>x});var r=n(89261),i=n(94922),s=n(47215),a=Object.prototype.hasOwnProperty;function o(e,t,n){for(n of e.keys())if(l(n,t))return n}function l(e,t){var n,r,i;if(e===t)return!0;if(e&&t&&(n=e.constructor)===t.constructor){if(n===Date)return e.getTime()===t.getTime();if(n===RegExp)return e.toString()===t.toString();if(n===Array){if((r=e.length)===t.length)for(;r--&&l(e[r],t[r]););return-1===r}if(n===Set){if(e.size!==t.size)return!1;for(r of e){if((i=r)&&"object"===typeof i&&!(i=o(t,i)))return!1;if(!t.has(i))return!1}return!0}if(n===Map){if(e.size!==t.size)return!1;for(r of e){if((i=r[0])&&"object"===typeof i&&!(i=o(t,i)))return!1;if(!l(r[1],t.get(i)))return!1}return!0}if(n===ArrayBuffer)e=new Uint8Array(e),t=new Uint8Array(t);else if(n===DataView){if((r=e.byteLength)===t.byteLength)for(;r--&&e.getInt8(r)===t.getInt8(r););return-1===r}if(ArrayBuffer.isView(e)){if((r=e.byteLength)===t.byteLength)for(;r--&&e[r]===t[r];);return-1===r}if(!n||"object"===typeof e){for(n in r=0,e){if(a.call(e,n)&&++r&&!a.call(t,n))return!1;if(!(n in t)||!l(e[n],t[n]))return!1}return Object.keys(t).length===r}}return e!==e&&t!==t}var c=n(78805),h=n(41338),d=n(31079),u=n(64288),p=n(98677),f=n(88648);class m{constructor(){this.externalLinkEnabled=!0,this.externalLinkRel=void 0,this.externalLinkTarget=void 0,this.isInPresentationMode=!1,this.pdfDocument=void 0,this.pdfViewer=void 0}setDocument(e){this.pdfDocument=e}setViewer(e){this.pdfViewer=e}setExternalLinkRel(e){this.externalLinkRel=e}setExternalLinkTarget(e){this.externalLinkTarget=e}setHash(){}setHistory(){}get pagesCount(){return this.pdfDocument?this.pdfDocument.numPages:0}get page(){return(0,u.A)(this.pdfViewer,"PDF viewer is not initialized."),this.pdfViewer.currentPageNumber||0}set page(e){(0,u.A)(this.pdfViewer,"PDF viewer is not initialized."),this.pdfViewer.currentPageNumber=e}get rotation(){return 0}set rotation(e){}addLinkAttributes(e,t,n){e.href=t,e.rel=this.externalLinkRel||"noopener noreferrer nofollow",e.target=n?"_blank":this.externalLinkTarget||""}goToDestination(e){return new Promise(t=>{(0,u.A)(this.pdfDocument,"PDF document not loaded."),(0,u.A)(e,"Destination is not specified."),"string"===typeof e?this.pdfDocument.getDestination(e).then(t):Array.isArray(e)?t(e):e.then(t)}).then(e=>{(0,u.A)(Array.isArray(e),`"${e}" is not a valid destination array.`);const t=e[0];new Promise(e=>{(0,u.A)(this.pdfDocument,"PDF document not loaded."),t instanceof Object?this.pdfDocument.getPageIndex(t).then(t=>{e(t)}).catch(()=>{(0,u.A)(!1,`"${t}" is not a valid page reference.`)}):"number"===typeof t?e(t):(0,u.A)(!1,`"${t}" is not a valid destination reference.`)}).then(t=>{const n=t+1;(0,u.A)(this.pdfViewer,"PDF viewer is not initialized."),(0,u.A)(n>=1&&n<=this.pagesCount,`"${n}" is not a valid page number.`),this.pdfViewer.scrollPageIntoView({dest:e,pageIndex:t,pageNumber:n})})})}goToPage(e){const t=e-1;(0,u.A)(this.pdfViewer,"PDF viewer is not initialized."),(0,u.A)(e>=1&&e<=this.pagesCount,`"${e}" is not a valid page number.`),this.pdfViewer.scrollPageIntoView({pageIndex:t,pageNumber:e})}goToXY(){}cachePageRef(){}getDestinationHash(){return"#"}getAnchorUrl(){return"#"}executeNamedAction(){}executeSetOCGState(){}isPageVisible(){return!0}isPageCached(){return!0}navigateTo(e){this.goToDestination(e)}}var g=n(60591);const v={NEED_PASSWORD:1,INCORRECT_PASSWORD:2};var y=n(7762),b=n(63185);const{Tm:w}=d,_=(e,t)=>{switch(t){case v.NEED_PASSWORD:e(prompt("Enter the password to open this PDF file."));break;case v.INCORRECT_PASSWORD:e(prompt("Invalid password. Please try again."));break}};function A(e){return"object"===typeof e&&null!==e&&("data"in e||"range"in e||"url"in e)}const x=(0,i.forwardRef)(function(e,t){let{children:n,className:a,error:o="Failed to load PDF file.",externalLinkRel:v,externalLinkTarget:x,file:E,inputRef:C,imageResourcesPath:k,loading:S="Loading PDF\u2026",noData:T="No PDF file specified.",onItemClick:D,onLoadError:M,onLoadProgress:P,onLoadSuccess:I,onPassword:F=_,onSourceError:R,onSourceSuccess:N,options:L,renderMode:O,rotate:B,scale:$,...z}=e;const[j,U]=(0,y.A)(),{value:H,error:V}=j,[q,W]=(0,y.A)(),{value:G,error:K}=q,X=(0,i.useRef)(new m),Y=(0,i.useRef)([]),Z=(0,i.useRef)(void 0),J=(0,i.useRef)(void 0);E&&E!==Z.current&&A(E)&&(p(!l(E,Z.current),'File prop passed to <Document /> changed, but it\'s equal to previous one. This might result in unnecessary reloads. Consider memoizing the value passed to "file" prop.'),Z.current=E),L&&L!==J.current&&(p(!l(L,J.current),'Options prop passed to <Document /> changed, but it\'s equal to previous one. This might result in unnecessary reloads. Consider memoizing the value passed to "options" prop.'),J.current=L);const Q=(0,i.useRef)({scrollPageIntoView:e=>{const{dest:t,pageNumber:n,pageIndex:r=n-1}=e;if(D)return void D({dest:t,pageIndex:r,pageNumber:n});const i=Y.current[r];i?i.scrollIntoView():p(!1,`An internal link leading to page ${n} was clicked, but neither <Document> was provided with onItemClick nor it was able to find the page within itself. Either provide onItemClick to <Document> and handle navigating by yourself or ensure that all pages are rendered within <Document>.`)}});(0,i.useImperativeHandle)(t,()=>({linkService:X,pages:Y,viewer:Q}),[]),(0,i.useEffect)(function(){U({type:"RESET"})},[E,U]);const ee=(0,i.useCallback)(async()=>{if(!E)return null;if("string"===typeof E){if((0,b.zL)(E)){return{data:(0,b.jA)(E)}}return(0,b.qC)(),{url:E}}if(E instanceof w)return{range:E};if((0,b.mw)(E))return{data:E};if(b.Bd&&(0,b.qf)(E)){return{data:await(0,b.h1)(E)}}if((0,u.A)("object"===typeof E,"Invalid parameter in file, need either Uint8Array, string or a parameter object"),(0,u.A)(A(E),"Invalid parameter object: need either .data, .range or .url"),"url"in E&&"string"===typeof E.url){if((0,b.zL)(E.url)){const{url:e,...t}=E;return{data:(0,b.jA)(e),...t}}(0,b.qC)()}return E},[E]);(0,i.useEffect)(()=>{const e=(0,c.A)(ee());return e.promise.then(e=>{U({type:"RESOLVE",value:e})}).catch(e=>{U({type:"REJECT",error:e})}),()=>{(0,b.xL)(e)}},[ee,U]),(0,i.useEffect)(()=>{"undefined"!==typeof H&&(!1!==H?N&&N():V&&(p(!1,V.toString()),R&&R(V)))},[H]),(0,i.useEffect)(function(){W({type:"RESET"})},[W,H]),(0,i.useEffect)(function(){if(!H)return;const e=L?{...H,...L}:H,t=d.YE(e);P&&(t.onProgress=P),F&&(t.onPassword=F);const n=t;return n.promise.then(e=>{n.destroyed||W({type:"RESOLVE",value:e})}).catch(e=>{n.destroyed||W({type:"REJECT",error:e})}),()=>{n.destroy()}},[L,W,H]),(0,i.useEffect)(()=>{"undefined"!==typeof G&&(!1!==G?G&&(I&&I(G),Y.current=new Array(G.numPages),X.current.setDocument(G)):K&&(p(!1,K.toString()),M&&M(K)))},[G]),(0,i.useEffect)(function(){X.current.setViewer(Q.current),X.current.setExternalLinkRel(v),X.current.setExternalLinkTarget(x)},[v,x]);const te=(0,i.useCallback)((e,t)=>{Y.current[e]=t},[]),ne=(0,i.useCallback)(e=>{delete Y.current[e]},[]),re=(0,i.useMemo)(()=>({imageResourcesPath:k,linkService:X.current,onItemClick:D,pdf:G,registerPage:te,renderMode:O,rotate:B,scale:$,unregisterPage:ne}),[k,D,G,te,O,B,$,ne]),ie=(0,i.useMemo)(()=>(0,h.Ay)(z,()=>G),[z,G]);return(0,r.jsx)("div",{className:(0,s.A)("react-pdf__Document",a),ref:C,...ie,children:E?void 0===G||null===G?(0,r.jsx)(g.A,{type:"loading",children:"function"===typeof S?S():S}):!1===G?(0,r.jsx)(g.A,{type:"error",children:"function"===typeof o?o():o}):function(){if(e=re,!Boolean(null===e||void 0===e?void 0:e.pdf))throw new Error("pdf is undefined");var e;const t="function"===typeof n?n(re):n;return(0,r.jsx)(f.A.Provider,{value:re,children:t})}():(0,r.jsx)(g.A,{type:"no-data",children:"function"===typeof T?T():T})})})},88648(e,t,n){"use strict";n.d(t,{A:()=>r});const r=(0,n(94922).createContext)(null)},60591(e,t,n){"use strict";n.d(t,{A:()=>i});var r=n(89261);function i(e){let{children:t,type:n}=e;return(0,r.jsx)("div",{className:`react-pdf__message react-pdf__message--${n}`,children:t})}},2153(e,t,n){"use strict";n.d(t,{A:()=>L});var r=n(89261),i=n(94922),s=n(47215),a=n(78805),o=n(41338);function l(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=e.filter(Boolean);return n.length<=1?n[0]||null:function(e){for(var t=0,r=n;t<r.length;t++){var i=r[t];"function"===typeof i?i(e):i&&(i.current=e)}}}var c=n(64288),h=n(98677),d=n(60591),u=n(31079),p=n(88648);function f(){return(0,i.useContext)(p.A)}const m=(0,i.createContext)(null);function g(){return(0,i.useContext)(m)}var v=n(7762),y=n(63185);function b(){const e=f(),t=g();(0,c.A)(t,"Unable to find Page context.");const n={...e,...t},{filterAnnotations:o,imageResourcesPath:l,linkService:d,onGetAnnotationsError:p,onGetAnnotationsSuccess:m,onRenderAnnotationLayerError:b,onRenderAnnotationLayerSuccess:w,page:_,pdf:A,renderForms:x,rotate:E,scale:C=1}=n;(0,c.A)(A,"Attempted to load page annotations, but no document was specified. Wrap <Page /> in a <Document /> or pass explicit `pdf` prop."),(0,c.A)(_,"Attempted to load page annotations, but no page was specified."),(0,c.A)(d,"Attempted to load page annotations, but no linkService was specified.");const[k,S]=(0,v.A)(),{value:T,error:D}=k,M=(0,i.useRef)(null);h(1===Number.parseInt(window.getComputedStyle(document.body).getPropertyValue("--react-pdf-annotation-layer"),10),"AnnotationLayer styles not found. Read more: https://github.com/wojtekmaj/react-pdf#support-for-annotations"),(0,i.useEffect)(function(){S({type:"RESET"})},[S,_]),(0,i.useEffect)(function(){if(!_)return;const e=(0,a.A)(_.getAnnotations()),t=e;return e.promise.then(e=>{S({type:"RESOLVE",value:e})}).catch(e=>{S({type:"REJECT",error:e})}),()=>{(0,y.xL)(t)}},[S,_]),(0,i.useEffect)(()=>{void 0!==T&&(!1!==T?T&&m&&m(T):D&&(h(!1,D.toString()),p&&p(D)))},[T]);const P=(0,i.useMemo)(()=>_.getViewport({scale:C,rotation:E}),[_,E,C]);return(0,i.useEffect)(function(){if(!A||!_||!d||!T)return;const{current:e}=M;if(!e)return;const t=P.clone({dontFlip:!0}),n={accessibilityManager:null,annotationCanvasMap:null,annotationEditorUIManager:null,annotationStorage:A.annotationStorage,commentManager:null,div:e,l10n:null,linkService:d,page:_,structTreeLayer:null,viewport:t},r={annotations:o?o({annotations:T}):T,annotationStorage:A.annotationStorage,div:e,imageResourcesPath:l,linkService:d,page:_,renderForms:x,viewport:t};e.innerHTML="";try{new u.dU(n).render(r),w&&w()}catch(i){!function(e){h(!1,`${e}`),b&&b(e)}(i)}return()=>{}},[T,o,l,d,_,A,x,P]),(0,r.jsx)("div",{className:(0,s.A)("react-pdf__Page__annotations","annotationLayer"),ref:M})}const w={Document:null,DocumentFragment:null,Part:"group",Sect:"group",Div:"group",Aside:"note",NonStruct:"none",P:null,H:"heading",Title:null,FENote:"note",Sub:"group",Lbl:null,Span:null,Em:null,Strong:null,Link:"link",Annot:"note",Form:"form",Ruby:null,RB:null,RT:null,RP:null,Warichu:null,WT:null,WP:null,L:"list",LI:"listitem",LBody:null,Table:"table",TR:"row",TH:"columnheader",TD:"cell",THead:"columnheader",TBody:null,TFoot:null,Caption:null,Figure:"figure",Formula:null,Artifact:null},_=/^H(\d+)$/;function A(e){return"children"in e}function x(e){return!!A(e)&&(1===e.children.length&&0 in e.children&&"id"in e.children[0])}function E(e){const t={};if(A(e)){const{role:n}=e,r=n.match(_);if(r)t.role="heading",t["aria-level"]=Number(r[1]);else if(function(e){return e in w}(n)){const e=w[n];e&&(t.role=e)}}return t}function C(e){const t={};if(A(e)){if(void 0!==e.alt&&(t["aria-label"]=e.alt),void 0!==e.lang&&(t.lang=e.lang),x(e)){const[n]=e.children;if(n){const e=C(n);return{...t,...e}}}}else"id"in e&&(t["aria-owns"]=e.id);return t}function k(e){let{className:t,node:n}=e;const s=(0,i.useMemo)(()=>function(e){return e?{...E(e),...C(e)}:null}(n),[n]),a=(0,i.useMemo)(()=>A(n)?x(n)?null:n.children.map((e,t)=>(0,r.jsx)(k,{node:e},t)):null,[n]);return(0,r.jsx)("span",{className:t,...s,children:a})}function S(){const e=g();(0,c.A)(e,"Unable to find Page context.");const{onGetStructTreeError:t,onGetStructTreeSuccess:n}=e,[s,o]=(0,v.A)(),{value:l,error:d}=s,{customTextRenderer:u,page:p}=e;return(0,i.useEffect)(function(){o({type:"RESET"})},[o,p]),(0,i.useEffect)(function(){if(u)return;if(!p)return;const e=(0,a.A)(p.getStructTree()),t=e;return e.promise.then(e=>{o({type:"RESOLVE",value:e})}).catch(e=>{o({type:"REJECT",error:e})}),()=>(0,y.xL)(t)},[u,p,o]),(0,i.useEffect)(()=>{void 0!==l&&(!1!==l?l&&n&&n(l):d&&(h(!1,d.toString()),t&&t(d)))},[l]),l?(0,r.jsx)(k,{className:"react-pdf__Page__structTree structTree",node:l}):null}const T=u.ng;function D(e){const t=g();(0,c.A)(t,"Unable to find Page context.");const n={...t,...e},{_className:s,canvasBackground:a,devicePixelRatio:o=(0,y.mZ)(),onRenderError:d,onRenderSuccess:u,page:p,renderForms:f,renderTextLayer:m,pageColors:v,rotate:b,scale:w}=n,{canvasRef:_}=e;(0,c.A)(p,"Attempted to render page canvas, but no page was specified.");const A=(0,i.useRef)(null);function x(e){(0,y.Kp)(e)||(h(!1,e.toString()),d&&d(e))}const E=(0,i.useMemo)(()=>p.getViewport({scale:w*o,rotation:b}),[o,p,b,w]),C=(0,i.useMemo)(()=>p.getViewport({scale:w,rotation:b}),[p,b,w]);(0,i.useEffect)(function(){if(!p)return;p.cleanup();const{current:e}=A;if(!e)return;e.width=E.width,e.height=E.height,e.style.width=`${Math.floor(C.width)}px`,e.style.height=`${Math.floor(C.height)}px`,e.style.visibility="hidden";const t={annotationMode:f?T.ENABLE_FORMS:T.ENABLE,canvas:e,canvasContext:e.getContext("2d",{alpha:!1}),pageColors:v,viewport:E};a&&(t.background=a);const n=p.render(t),r=n;return n.promise.then(()=>{e.style.visibility="",p&&u&&u((0,y.vS)(p,w))}).catch(x),()=>(0,y.xL)(r)},[a,p,v,f,E,C]);const k=(0,i.useCallback)(()=>{const{current:e}=A;e&&(e.width=0,e.height=0)},[]);return(0,i.useEffect)(()=>k,[k]),(0,r.jsx)("canvas",{className:`${s}__canvas`,dir:"ltr",ref:l(_,A),style:{display:"block",userSelect:"none"},children:m?(0,r.jsx)(S,{}):null})}const M=new Set(["base","embed","iframe","link","meta","object","script","style","template"]),P=new Set(["action","formaction","href","poster","src","xlink:href"]);function I(e){return function(e){return e.nodeType===Node.ELEMENT_NODE}(e)&&e instanceof HTMLElement}function F(e){var t;return I(e)&&!function(e){return I(e)&&M.has(e.tagName.toLowerCase())}(e)?function(e){const t=document.createElement(e.tagName.toLowerCase());return Array.from(e.attributes).forEach(e=>{const n=e.name.toLowerCase();n.startsWith("on")||"srcdoc"===n||P.has(n)&&function(e){let t="";for(const n of e){const e=n.charCodeAt(0);e<=32||127===e||(t+=n.toLowerCase())}return t.startsWith("javascript:")||t.startsWith("vbscript:")}(e.value)||t.setAttribute(e.name,e.value)}),Array.from(e.childNodes).forEach(e=>{t.append(F(e))}),t}(e):document.createTextNode(null!==(t=e.textContent)&&void 0!==t?t:"")}function R(){const e=g();(0,c.A)(e,"Unable to find Page context.");const{customTextRenderer:t,onGetTextError:n,onGetTextSuccess:o,onRenderTextLayerError:l,onRenderTextLayerSuccess:d,page:p,pageIndex:f,pageNumber:m,rotate:b,scale:w}=e;(0,c.A)(p,"Attempted to load page text content, but no page was specified.");const[_,A]=(0,v.A)(),{value:x,error:E}=_,C=(0,i.useRef)(null);h(1===Number.parseInt(window.getComputedStyle(document.body).getPropertyValue("--react-pdf-text-layer"),10),"TextLayer styles not found. Read more: https://github.com/wojtekmaj/react-pdf#support-for-text-layer"),(0,i.useEffect)(function(){A({type:"RESET"})},[p,A]),(0,i.useEffect)(function(){if(!p)return;const e=(0,a.A)(p.getTextContent()),t=e;return e.promise.then(e=>{A({type:"RESOLVE",value:e})}).catch(e=>{A({type:"REJECT",error:e})}),()=>(0,y.xL)(t)},[p,A]),(0,i.useEffect)(()=>{void 0!==x&&(!1!==x?x&&o&&o(x):E&&(h(!1,E.toString()),n&&n(E)))},[x]);const k=(0,i.useCallback)(()=>{d&&d()},[d]),S=(0,i.useCallback)(e=>{(0,y.Kp)(e)||(h(!1,e.toString()),l&&l(e))},[l]);const T=(0,i.useMemo)(()=>p.getViewport({scale:w,rotation:b}),[p,b,w]);return(0,i.useLayoutEffect)(function(){if(!p||!x)return;const{current:e}=C;if(!e)return;e.innerHTML="";const n=p.streamTextContent({includeMarkedContent:!0}),r={container:e,textContentSource:n,viewport:T},i=new u.D6(r),s=i;return i.render().then(()=>{const n=document.createElement("div");n.className="endOfContent",e.append(n);const r=e.querySelectorAll('[role="presentation"]');if(t){let e=0;x.items.forEach((n,i)=>{if(!function(e){return"str"in e}(n))return;const s=r[e];if(!s)return;!function(e,t){const n=document.createElement("template");n.innerHTML=t;const r=document.createDocumentFragment();Array.from(n.content.childNodes).forEach(e=>{r.append(F(e))}),e.replaceChildren(r)}(s,t({pageIndex:f,pageNumber:m,itemIndex:i,...n})),e+=n.str&&n.hasEOL?2:1})}k()}).catch(S),()=>(0,y.xL)(s)},[t,S,k,p,f,m,x,T]),(0,r.jsx)("div",{className:(0,s.A)("react-pdf__Page__textContent","textLayer"),onMouseUp:function(){const e=C.current;e&&e.classList.remove("selecting")},onMouseDown:function(){const e=C.current;e&&e.classList.add("selecting")},ref:C})}const N=1;function L(e){const t={...f(),...e},{_className:n="react-pdf__Page",_enableRegisterUnregisterPage:u=!0,canvasBackground:p,canvasRef:g,children:w,className:_,customRenderer:A,customTextRenderer:x,devicePixelRatio:E,error:C="Failed to load the page.",filterAnnotations:k,height:S,inputRef:T,loading:M="Loading page\u2026",noData:P="No page specified.",onGetAnnotationsError:I,onGetAnnotationsSuccess:F,onGetStructTreeError:L,onGetStructTreeSuccess:O,onGetTextError:B,onGetTextSuccess:$,onLoadError:z,onLoadSuccess:j,onRenderAnnotationLayerError:U,onRenderAnnotationLayerSuccess:H,onRenderError:V,onRenderSuccess:q,onRenderTextLayerError:W,onRenderTextLayerSuccess:G,pageColors:K,pageIndex:X,pageNumber:Y,pdf:Z,registerPage:J,renderAnnotationLayer:Q=!0,renderForms:ee=!1,renderMode:te="canvas",renderTextLayer:ne=!0,rotate:re,scale:ie=N,unregisterPage:se,width:ae,...oe}=t,[le,ce]=(0,v.A)(),{value:he,error:de}=le,ue=(0,i.useRef)(null);(0,c.A)(Z,"Attempted to load a page, but no document was specified. Wrap <Page /> in a <Document /> or pass explicit `pdf` prop.");const pe=(0,y.ci)(Y)?Y-1:null!==X&&void 0!==X?X:null,fe=null!==Y&&void 0!==Y?Y:(0,y.ci)(X)?X+1:null,me=null!==re&&void 0!==re?re:he?he.rotate:null,ge=(0,i.useMemo)(()=>{if(!he)return null;let e=1;const t=null!==ie&&void 0!==ie?ie:N;if(ae||S){const t=he.getViewport({scale:1,rotation:me});ae?e=ae/t.width:S&&(e=S/t.height)}return t*e},[S,he,me,ie,ae]);(0,i.useEffect)(function(){return()=>{(0,y.ci)(pe)&&u&&se&&se(pe)}},[u,Z,pe,se]),(0,i.useEffect)(function(){ce({type:"RESET"})},[ce,Z,pe]),(0,i.useEffect)(function(){if(!Z||!fe)return;const e=(0,a.A)(Z.getPage(fe)),t=e;return e.promise.then(e=>{ce({type:"RESOLVE",value:e})}).catch(e=>{ce({type:"REJECT",error:e})}),()=>(0,y.xL)(t)},[ce,Z,fe]),(0,i.useEffect)(()=>{void 0!==he&&(!1!==he?function(){if(j){if(!he||!ge)return;j((0,y.vS)(he,ge))}if(u&&J){if(!(0,y.ci)(pe)||!ue.current)return;J(pe,ue.current)}}():de&&(h(!1,de.toString()),z&&z(de)))},[he,ge]);const ve=(0,i.useMemo)(()=>(0,y.ci)(pe)&&fe&&(0,y.ci)(me)&&(0,y.ci)(ge)?{_className:n,canvasBackground:p,customTextRenderer:x,devicePixelRatio:E,filterAnnotations:k,onGetAnnotationsError:I,onGetAnnotationsSuccess:F,onGetStructTreeError:L,onGetStructTreeSuccess:O,onGetTextError:B,onGetTextSuccess:$,onRenderAnnotationLayerError:U,onRenderAnnotationLayerSuccess:H,onRenderError:V,onRenderSuccess:q,onRenderTextLayerError:W,onRenderTextLayerSuccess:G,page:he,pageColors:K,pageIndex:pe,pageNumber:fe,renderForms:ee,renderTextLayer:ne,rotate:me,scale:ge}:null,[n,p,x,E,k,I,F,L,O,B,$,U,H,V,q,W,G,he,K,pe,fe,ee,ne,me,ge]),ye=(0,i.useMemo)(()=>(0,o.Ay)(oe,()=>he?ge?(0,y.vS)(he,ge):void 0:he),[oe,he,ge]),be=`${pe}@${ge}/${me}`;function we(){switch(te){case"custom":return(0,c.A)(A,'renderMode was set to "custom", but no customRenderer was passed.'),(0,r.jsx)(A,{},`${be}_custom`);case"none":return null;default:return(0,r.jsx)(D,{canvasRef:g},`${be}_canvas`)}}return(0,r.jsx)("div",{className:(0,s.A)(n,_),"data-page-number":fe,ref:l(T,ue),style:{"--scale-round-x":"1px","--scale-round-y":"1px","--scale-factor":"1","--user-unit":`${ge}`,"--total-scale-factor":"calc(var(--scale-factor) * var(--user-unit))",backgroundColor:p||"white",position:"relative",minWidth:"min-content",minHeight:"min-content"},...ye,children:fe?null===Z||void 0===he||null===he?(0,r.jsx)(d.A,{type:"loading",children:"function"===typeof M?M():M}):!1===Z||!1===he?(0,r.jsx)(d.A,{type:"error",children:"function"===typeof C?C():C}):function(){if(e=ve,!Boolean(null===e||void 0===e?void 0:e.page))throw new Error("page is undefined");var e;const t="function"===typeof w?w(ve):w;return(0,r.jsxs)(m.Provider,{value:ve,children:[we(),ne?(0,r.jsx)(R,{},`${be}_text`):null,Q?(0,r.jsx)(b,{},`${be}_annotations`):null,t]})}():(0,r.jsx)(d.A,{type:"no-data",children:"function"===typeof P?P():P})})}},7762(e,t,n){"use strict";n.d(t,{A:()=>s});var r=n(94922);function i(e,t){switch(t.type){case"RESOLVE":return{value:t.value,error:void 0};case"REJECT":return{value:!1,error:t.error};case"RESET":return{value:void 0,error:void 0};default:return e}}function s(){return(0,r.useReducer)(i,{value:void 0,error:void 0})}},63185(e,t,n){"use strict";n.d(t,{Bd:()=>s,Kp:()=>v,ci:()=>o,h1:()=>y,jA:()=>d,mZ:()=>u,mw:()=>l,qC:()=>f,qf:()=>c,vS:()=>g,xL:()=>m,zL:()=>h});var r=n(64288),i=n(98677);const s="undefined"!==typeof window,a=s&&"file:"===window.location.protocol;function o(e){return function(e){return"undefined"!==typeof e}(e)&&null!==e}function l(e){return e instanceof ArrayBuffer}function c(e){return(0,r.A)(s,"isBlob can only be used in a browser environment"),e instanceof Blob}function h(e){return function(e){return"string"===typeof e}(e)&&/^data:/.test(e)}function d(e){(0,r.A)(h(e),"Invalid data URI.");const[t="",n=""]=e.split(",");return-1!==t.split(";").indexOf("base64")?atob(n):unescape(n)}function u(){return s&&window.devicePixelRatio||1}const p="On Chromium based browsers, you can use --allow-file-access-from-files flag for debugging purposes.";function f(){i(!a,`Loading PDF as base64 strings/URLs may not work on protocols other than HTTP/HTTPS. ${p}`)}function m(e){(null===e||void 0===e?void 0:e.cancel)&&e.cancel()}function g(e,t){return Object.defineProperty(e,"width",{get(){return this.getViewport({scale:t}).width},configurable:!0}),Object.defineProperty(e,"height",{get(){return this.getViewport({scale:t}).height},configurable:!0}),Object.defineProperty(e,"originalWidth",{get(){return this.getViewport({scale:1}).width},configurable:!0}),Object.defineProperty(e,"originalHeight",{get(){return this.getViewport({scale:1}).height},configurable:!0}),e}function v(e){return"AbortException"===e.name||"RenderingCancelledException"===e.name}function y(e){return new Promise((t,n)=>{const r=new FileReader;r.onload=()=>{if(!r.result)return n(new Error("Error while reading a file."));t(r.result)},r.onerror=e=>{if(!e.target)return n(new Error("Error while reading a file."));const{error:t}=e.target;if(!t)return n(new Error("Error while reading a file."));switch(t.code){case t.NOT_FOUND_ERR:return n(new Error("Error while reading a file: File not found."));case t.SECURITY_ERR:return n(new Error("Error while reading a file: Security error."));case t.ABORT_ERR:return n(new Error("Error while reading a file: Aborted."));default:return n(new Error("Error while reading a file."))}},r.readAsArrayBuffer(e)})}},87639(e,t,n){"use strict";n.d(t,{R:()=>p});var r=n(94922);const i="printWindow";function s(e){let{level:t="error",messages:n,suppressErrors:r=!1}=e;r||("error"===t?console.error(n):"warning"===t?console.warn(n):console.debug(n))}function a(e,t){if(t||!e){const e=document.getElementById(i);e&&document.body.removeChild(e)}}function o(e){return e instanceof Error?e:new Error("Unknown Error")}function l(e,t){const{documentTitle:n,onAfterPrint:r,onPrintError:i,preserveAfterPrint:l,print:c,suppressErrors:h}=t;setTimeout(()=>{if(e.contentWindow){let t=function(){r?.(),a(l)};if(e.contentWindow.focus(),c)c(e).then(t).catch(e=>{i?i("print",o(e)):s({messages:["An error was thrown by the specified `print` function"],suppressErrors:h})});else{if(e.contentWindow.print){const t=e.contentDocument?.title??"",r=e.ownerDocument.title,i="function"==typeof n?n():n;i&&(e.ownerDocument.title=i,e.contentDocument&&(e.contentDocument.title=i)),e.contentWindow.print(),i&&(e.ownerDocument.title=r,e.contentDocument&&(e.contentDocument.title=t))}else s({messages:["Printing for this browser is not currently possible: the browser does not have a `print` method available for iframes."],suppressErrors:h});[/Android/i,/webOS/i,/iPhone/i,/iPad/i,/iPod/i,/BlackBerry/i,/Windows Phone/i].some(e=>(navigator.userAgent??navigator.vendor??("opera"in window&&window.opera)).match(e))?setTimeout(t,500):t()}}else s({messages:["Printing failed because the `contentWindow` of the print iframe did not load. This is possibly an error with `react-to-print`. Please file an issue: https://github.com/MatthewHerbst/react-to-print/issues/"],suppressErrors:h})},500)}function c(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,null);let r=n.nextNode();for(;r;)t.push(r),r=n.nextNode();return t}function h(e,t,n){const r=c(e),i=c(t);if(r.length===i.length)for(let s=0;s<r.length;s++){const e=r[s],t=i[s],a=e.shadowRoot;if(null!==a){const e=t.attachShadow({mode:a.mode});e.innerHTML=a.innerHTML,h(a,e,n)}}else s({messages:["When cloning shadow root content, source and target elements have different size. `onBeforePrint` likely resolved too early.",e,t],suppressErrors:n})}function d(e,t,n){const{contentNode:r,clonedContentNode:i,clonedImgNodes:a,clonedVideoNodes:c,numResourcesToLoad:d,originalCanvasNodes:u}=t,{bodyClass:p,fonts:f,ignoreGlobalStyles:m,pageStyle:g,nonce:v,suppressErrors:y,copyShadowRoots:b}=n,w=[],_=[];function A(t,r){w.includes(t)?s({level:"debug",messages:["Tried to mark a resource that has already been handled",t],suppressErrors:y}):(r?(s({messages:['"react-to-print" was unable to load a resource but will continue attempting to print the page',...r],suppressErrors:y}),_.push(t)):w.push(t),w.length+_.length===d&&l(e,n))}e.onload=null;const x=e.contentDocument??e.contentWindow?.document;if(x){const t=x.body.appendChild(i);b&&h(r,t,!!y),f&&(e.contentDocument?.fonts&&e.contentWindow?.FontFace?f.forEach(t=>{const n=new FontFace(t.family,t.source,{weight:t.weight,style:t.style});e.contentDocument.fonts.add(n),n.loaded.then(()=>{A(n)}).catch(e=>{A(n,["Failed loading the font:",n,"Load error:",o(e)])})}):(f.forEach(e=>{A(e)}),s({messages:['"react-to-print" is not able to load custom fonts because the browser does not support the FontFace API but will continue attempting to print the page'],suppressErrors:y})));const n=g??'\n @page {\n /* Remove browser default header (title) and footer (url) */\n margin: 0;\n }\n @media print {\n body {\n /* Tell browsers to print background colors */\n color-adjust: exact; /* Firefox. This is an older version of "print-color-adjust" */\n print-color-adjust: exact; /* Firefox/Safari */\n -webkit-print-color-adjust: exact; /* Chrome/Safari/Edge/Opera */\n }\n }\n',l=x.createElement("style");v&&(l.setAttribute("nonce",v),x.head.setAttribute("nonce",v)),l.appendChild(x.createTextNode(n)),x.head.appendChild(l),p&&x.body.classList.add(...p.split(" "));const d=x.querySelectorAll("canvas");for(let e=0;e<u.length;++e){const t=u[e],n=d[e];if(void 0===n){s({messages:["A canvas element could not be copied for printing, has it loaded? `onBeforePrint` likely resolved too early.",t],suppressErrors:y});continue}const r=n.getContext("2d");r&&r.drawImage(t,0,0)}for(let e=0;e<a.length;e++){const t=a[e],n=t.getAttribute("src");if(n){const e=new Image;e.onload=()=>{A(t)},e.onerror=(e,n,r,i,s)=>{A(t,["Error loading <img>",t,"Error",s])},e.src=n}else A(t,['Found an <img> tag with an empty "src" attribute. This prevents pre-loading it.',t])}for(let e=0;e<c.length;e++){const t=c[e];t.preload="auto";const n=t.getAttribute("poster");if(n){const e=new Image;e.onload=()=>{A(t)},e.onerror=(e,r,i,s,a)=>{A(t,["Error loading video poster",n,"for video",t,"Error:",a])},e.src=n}else t.readyState>=2?A(t):t.src?(t.onloadeddata=()=>{A(t)},t.onerror=(e,n,r,i,s)=>{A(t,["Error loading video",t,"Error",s])},t.onstalled=()=>{A(t,["Loading video stalled, skipping",t])}):A(t,["Error loading video, `src` is empty",t])}const w="select",_=r.querySelectorAll(w),C=x.querySelectorAll(w);for(let e=0;e<_.length;e++)C[e].value=_[e].value;if(!m){const e=document.querySelectorAll("style, link[rel~='stylesheet'], link[as='style']");for(let t=0,n=e.length;t<n;++t){const n=e[t];if("style"===n.tagName.toLowerCase()){const e=x.createElement(n.tagName),r=n.sheet;if(r){let i="";try{const e=r.cssRules.length;for(let t=0;t<e;++t)"string"==typeof r.cssRules[t].cssText&&(i+=`${r.cssRules[t].cssText}\r\n`)}catch(E){s({messages:["A stylesheet could not be accessed. This is likely due to the stylesheet having cross-origin imports, and many browsers block script access to cross-origin stylesheets. See https://github.com/MatthewHerbst/react-to-print/issues/429 for details. You may be able to load the sheet by both marking the stylesheet with the cross `crossorigin` attribute, and setting the `Access-Control-Allow-Origin` header on the server serving the stylesheet. Alternatively, host the stylesheet on your domain to avoid this issue entirely.",n,`Original error: ${o(E).message}`],level:"warning"})}e.setAttribute("id",`react-to-print-${t}`),v&&e.setAttribute("nonce",v),e.appendChild(x.createTextNode(i)),x.head.appendChild(e)}}else if(n.getAttribute("href"))if(n.hasAttribute("disabled"))s({messages:["`react-to-print` encountered a <link> tag with a `disabled` attribute and will ignore it. Note that the `disabled` attribute is deprecated, and some browsers ignore it. You should stop using it. https://developer.mozilla.org/en-US/docs/Web/HTML/Element/link#attr-disabled. The <link> is:",n],level:"warning"}),A(n);else{const e=x.createElement(n.tagName);for(let t=0,r=n.attributes.length;t<r;++t){const r=n.attributes[t];r&&e.setAttribute(r.nodeName,r.nodeValue??"")}e.onload=()=>{A(e)},e.onerror=(t,n,r,i,s)=>{A(e,["Failed to load",e,"Error:",s])},v&&e.setAttribute("nonce",v),x.head.appendChild(e)}else s({messages:["`react-to-print` encountered a <link> tag with an empty `href` attribute. In addition to being invalid HTML, this can cause problems in many browsers, and so the <link> was not loaded. The <link> is:",n],level:"warning"}),A(n)}}}0===d&&l(e,n)}function u(e,t){const{contentRef:n,fonts:r,ignoreGlobalStyles:i,suppressErrors:a}=t,o=function(e){let{contentRef:t,optionalContent:n,suppressErrors:r}=e;return n&&"function"==typeof n?(t&&s({level:"warning",messages:['"react-to-print" received a `contentRef` option and an optional-content param passed to its callback. The `contentRef` option will be ignored.']}),n()):t?t.current:void s({messages:['"react-to-print" did not receive a `contentRef` option or a optional-content param pass to its callback.'],suppressErrors:r})}({contentRef:n,optionalContent:e,suppressErrors:a});if(!o)return;const l=o.cloneNode(!0),c=document.querySelectorAll("link[rel~='stylesheet'], link[as='style']"),h=l.querySelectorAll("img"),d=l.querySelectorAll("video"),u=r?r.length:0;return{contentNode:o,clonedContentNode:l,clonedImgNodes:h,clonedVideoNodes:d,numResourcesToLoad:(i?0:c.length)+h.length+d.length+u,originalCanvasNodes:o.querySelectorAll("canvas")}}function p(e){let{bodyClass:t,contentRef:n,copyShadowRoots:l,documentTitle:c,fonts:h,ignoreGlobalStyles:p,nonce:f,onAfterPrint:m,onBeforePrint:g,onPrintError:v,pageStyle:y,preserveAfterPrint:b,print:w,printIframeProps:_,suppressErrors:A}=e;return(0,r.useCallback)(e=>{function r(){const r={bodyClass:t,contentRef:n,copyShadowRoots:l,documentTitle:c,fonts:h,ignoreGlobalStyles:p,nonce:f,onAfterPrint:m,onPrintError:v,pageStyle:y,preserveAfterPrint:b,print:w,suppressErrors:A},a=function(e){const t=document.createElement("iframe");return t.width=`${document.documentElement.clientWidth}px`,t.height=`${document.documentElement.clientHeight}px`,t.style.position="absolute",t.style.top=`-${document.documentElement.clientHeight+100}px`,t.style.left=`-${document.documentElement.clientWidth+100}px`,t.id=i,t.srcdoc="<!DOCTYPE html>",e&&(e.allow&&(t.allow=e.allow),void 0!==e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),void 0!==e.sandbox&&(t.sandbox=e.sandbox)),t}(_),o=u(e,r);o?function(e,t,n){e.onload=()=>{d(e,t,n)},document.body.appendChild(e)}(a,o,r):s({messages:["There is nothing to print"],suppressErrors:A})}a(b,!0),g?g().then(()=>{r()}).catch(e=>{v?.("onBeforePrint",o(e))}):r()},[t,n,l,c,h,p,f,m,g,v,y,b,_,w,A])}},64288(e,t,n){"use strict";n.d(t,{A:()=>i});var r="Invariant failed";function i(e,t){if(!e)throw new Error(r)}},99209(e){"use strict";e.exports=JSON.parse('{"$id":"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#","description":"Meta-schema for $data reference (JSON AnySchema extension proposal)","type":"object","required":["$data"],"properties":{"$data":{"type":"string","anyOf":[{"format":"relative-json-pointer"},{"format":"json-pointer"}]}},"additionalProperties":false}')},70211(e){"use strict";e.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"http://json-schema.org/draft-07/schema#","title":"Core schema meta-schema","definitions":{"schemaArray":{"type":"array","minItems":1,"items":{"$ref":"#"}},"nonNegativeInteger":{"type":"integer","minimum":0},"nonNegativeIntegerDefault0":{"allOf":[{"$ref":"#/definitions/nonNegativeInteger"},{"default":0}]},"simpleTypes":{"enum":["array","boolean","integer","null","number","object","string"]},"stringArray":{"type":"array","items":{"type":"string"},"uniqueItems":true,"default":[]}},"type":["object","boolean"],"properties":{"$id":{"type":"string","format":"uri-reference"},"$schema":{"type":"string","format":"uri"},"$ref":{"type":"string","format":"uri-reference"},"$comment":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"default":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"multipleOf":{"type":"number","exclusiveMinimum":0},"maximum":{"type":"number"},"exclusiveMaximum":{"type":"number"},"minimum":{"type":"number"},"exclusiveMinimum":{"type":"number"},"maxLength":{"$ref":"#/definitions/nonNegativeInteger"},"minLength":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"pattern":{"type":"string","format":"regex"},"additionalItems":{"$ref":"#"},"items":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/schemaArray"}],"default":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"contains":{"$ref":"#"},"maxProperties":{"$ref":"#/definitions/nonNegativeInteger"},"minProperties":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"required":{"$ref":"#/definitions/stringArray"},"additionalProperties":{"$ref":"#"},"definitions":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"properties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"patternProperties":{"type":"object","additionalProperties":{"$ref":"#"},"propertyNames":{"format":"regex"},"default":{}},"dependencies":{"type":"object","additionalProperties":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/stringArray"}]}},"propertyNames":{"$ref":"#"},"const":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"format":{"type":"string"},"contentMediaType":{"type":"string"},"contentEncoding":{"type":"string"},"if":{"$ref":"#"},"then":{"$ref":"#"},"else":{"$ref":"#"},"allOf":{"$ref":"#/definitions/schemaArray"},"anyOf":{"$ref":"#/definitions/schemaArray"},"oneOf":{"$ref":"#/definitions/schemaArray"},"not":{"$ref":"#"}},"default":true}')}}]);
|
|
9
|
+
//# sourceMappingURL=776.d98d1437.chunk.js.map
|