@adaptive-ai/sdk 0.1.10 → 0.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,8 @@
1
- import {useState,useEffect,useRef,useCallback}from'react';import {useMutation}from'@tanstack/react-query';import {identity}from'lodash';import {nanoid}from'nanoid';import yt from'superjson';import {rpcClient,RpcError}from'typed-rpc';var wn=Object.create;var bt=Object.defineProperty;var vn=Object.getOwnPropertyDescriptor;var _n=Object.getOwnPropertyNames;var bn=Object.getPrototypeOf,En=Object.prototype.hasOwnProperty;var Ze=(i,r)=>()=>(r||i((r={exports:{}}).exports,r),r.exports);var Sn=(i,r,E,l)=>{if(r&&typeof r=="object"||typeof r=="function")for(let e of _n(r))!En.call(i,e)&&e!==E&&bt(i,e,{get:()=>r[e],enumerable:!(l=vn(r,e))||l.enumerable});return i};var Et=(i,r,E)=>(E=i!=null?wn(bn(i)):{},Sn(bt(E,"default",{value:i,enumerable:true}),i));var Ft=Ze((nt,rt)=>{(i=>{let r=(()=>{let R=0;return {escape:function(s){return s.replace(/([.*+?^${}()|[\]/\\])/g,"\\$1")},isDataUrl:function(s){return s.search(/^(data:)/)!==-1},canvasToBlob:function(s){return s.toBlob?new Promise(function(y){s.toBlob(y);}):(y=>new Promise(function(b){var A=a(y.toDataURL().split(",")[1]),T=A.length,m=new Uint8Array(T);for(let d=0;d<T;d++)m[d]=A.charCodeAt(d);b(new Blob([m],{type:"image/png"}));}))(s)},resolveUrl:function(s,y){var b=globalThis.document.implementation.createHTMLDocument(),A=b.createElement("base"),T=(b.head.appendChild(A),b.createElement("a"));return b.body.appendChild(T),A.href=y,T.href=s,T.href},getAndEncode:function(s){let y=w.impl.urlCache.find(function(b){return b.url===s});return y||(y={url:s,promise:null},w.impl.urlCache.push(y)),y.promise===null&&(w.impl.options.cacheBust&&(s+=(/\?/.test(s)?"&":"?")+new Date().getTime()),y.promise=new Promise(function(b){let A=new XMLHttpRequest;function T(P){console.error(P),b("");}function m(){var P=w.impl.options.imagePlaceholder;P?b(P):T("Status:"+A.status+" while fetching resource: "+s);}if(A.timeout=w.impl.options.httpTimeout,A.onerror=m,A.ontimeout=m,A.onloadend=function(){if(A.readyState===XMLHttpRequest.DONE){var P=A.status;if(P===0&&s.toLowerCase().startsWith("file://")||200<=P&&P<=300&&A.response!==null){P=A.response,P instanceof Blob||T("Expected response to be a Blob, but got: "+typeof P);let x=new globalThis.FileReader;x.onloadend=function(){var O=x.result;b(O);};try{x.readAsDataURL(P);}catch(O){T("Failed to read the response as Data URL: "+O.toString());}}else m();}},0<w.impl.options.useCredentialsFilters.length&&(w.impl.options.useCredentials=0<w.impl.options.useCredentialsFilters.filter(P=>0<=s.search(P)).length),w.impl.options.useCredentials&&(A.withCredentials=true),w.impl.options.corsImg&&s.indexOf("http")===0&&s.indexOf(globalThis.window.location.origin)===-1){var d=(w.impl.options.corsImg.method||"GET").toUpperCase()==="POST"?"POST":"GET";A.open(d,(w.impl.options.corsImg.url||"").replace("#{cors}",s),true);let P=false,x=w.impl.options.corsImg.headers||{},O=(Object.keys(x).forEach(function(N){x[N].indexOf("application/json")!==-1&&(P=true),A.setRequestHeader(N,x[N]);}),(N=>{try{return JSON.parse(JSON.stringify(N))}catch(D){T("corsImg.data is missing or invalid:"+D.toString());}})(w.impl.options.corsImg.data||""));Object.keys(O).forEach(function(N){typeof O[N]=="string"&&(O[N]=O[N].replace("#{cors}",s));}),A.responseType="blob",A.send(P?JSON.stringify(O):O);}else A.open("GET",s,true),A.responseType="blob",A.send();})),y.promise},uid:function(){return "u"+("0000"+(Math.random()*Math.pow(36,4)<<0).toString(36)).slice(-4)+R++},asArray:function(s){var y=[],b=s.length;for(let A=0;A<b;A++)y.push(s[A]);return y},escapeXhtml:function(s){return s.replace(/%/g,"%25").replace(/#/g,"%23").replace(/\n/g,"%0A")},makeImage:function(s){return s!=="data:,"?new Promise(function(y,b){let A=globalThis.document.createElementNS("http://www.w3.org/2000/svg","svg"),T=new globalThis.Image;w.impl.options.useCredentials&&(T.crossOrigin="use-credentials"),T.onload=function(){globalThis.document.body.removeChild(A),globalThis.window&&globalThis.window.requestAnimationFrame?globalThis.window.requestAnimationFrame(function(){y(T);}):y(T);},T.onerror=m=>{globalThis.document.body.removeChild(A),b(m);},A.appendChild(T),T.src=s,globalThis.document.body.appendChild(A);}):Promise.resolve()},width:function(s){var y=_(s,"width");if(!isNaN(y))return y;var y=_(s,"border-left-width"),b=_(s,"border-right-width");return s.scrollWidth+y+b},height:function(s){var y=_(s,"height");if(!isNaN(y))return y;var y=_(s,"border-top-width"),b=_(s,"border-bottom-width");return s.scrollHeight+y+b},getWindow:g,isElement:u,isElementHostForOpenShadowRoot:function(s){return u(s)&&s.shadowRoot!==null},isShadowRoot:U,isInShadowRoot:f,isHTMLElement:function(s){return s instanceof g(s).HTMLElement},isHTMLCanvasElement:function(s){return s instanceof g(s).HTMLCanvasElement},isHTMLInputElement:function(s){return s instanceof g(s).HTMLInputElement},isHTMLImageElement:function(s){return s instanceof g(s).HTMLImageElement},isHTMLLinkElement:function(s){return s instanceof g(s).HTMLLinkElement},isHTMLScriptElement:function(s){return s instanceof g(s).HTMLScriptElement},isHTMLStyleElement:function(s){return s instanceof g(s).HTMLStyleElement},isHTMLTextAreaElement:function(s){return s instanceof g(s).HTMLTextAreaElement},isShadowSlotElement:function(s){return f(s)&&s instanceof g(s).HTMLSlotElement},isSVGElement:function(s){return s instanceof g(s).SVGElement},isSVGRectElement:function(s){return s instanceof g(s).SVGRectElement},isDimensionMissing:function(s){return isNaN(s)||s<=0}};function g(s){return s=s?s.ownerDocument:void 0,(s?s.defaultView:void 0)||globalThis.window||i}function U(s){return s instanceof g(s).ShadowRoot}function f(s){return s!=null&&s.getRootNode!==void 0&&U(s.getRootNode())}function u(s){return s instanceof g(s).Element}function _(s,y){if(s.nodeType===S){let b=o(s).getPropertyValue(y);if(b.slice(-2)==="px")return b=b.slice(0,-2),parseFloat(b)}return NaN}})(),E=(()=>{let R=/url\(\s*(["']?)((?:\\.|[^\\)])+)\1\s*\)/gm;return {inlineAll:function(_,s,y){return g(_)?Promise.resolve(_).then(U).then(function(b){let A=Promise.resolve(_);return b.forEach(function(T){A=A.then(function(m){return u(m,T,s,y)});}),A}):Promise.resolve(_)},shouldProcess:g,impl:{readUrls:U,inline:u,urlAsRegex:f}};function g(_){return _.search(R)!==-1}function U(_){for(var s,y=[];(s=R.exec(_))!==null;)y.push(s[2]);return y.filter(function(b){return !r.isDataUrl(b)})}function f(_){return new RegExp(`url\\((["']?)(${r.escape(_)})\\1\\)`,"gm")}function u(_,s,y,b){return Promise.resolve(s).then(function(A){return y?r.resolveUrl(A,y):A}).then(b||r.getAndEncode).then(function(A){var T=f(s);return _.replace(T,`url($1${A}$1)`)})}})(),l={resolveAll:function(){return e().then(function(R){return Promise.all(R.map(function(g){return g.resolve()}))}).then(function(R){return R.join(`
2
- `)})},impl:{readAll:e}};function e(){return Promise.resolve(r.asArray(globalThis.document.styleSheets)).then(function(g){let U=[];return g.forEach(function(f){var u=Object.getPrototypeOf(f);if(Object.prototype.hasOwnProperty.call(u,"cssRules"))try{r.asArray(f.cssRules||[]).forEach(U.push.bind(U));}catch(_){console.error("domtoimage: Error while reading CSS rules from: "+f.href,_.toString());}}),U}).then(function(g){return g.filter(function(U){return U.type===CSSRule.FONT_FACE_RULE}).filter(function(U){return E.shouldProcess(U.style.getPropertyValue("src"))})}).then(function(g){return g.map(R)});function R(g){return {resolve:function(){var U=(g.parentStyleSheet||{}).href;return E.inlineAll(g.cssText,U)},src:function(){return g.style.getPropertyValue("src")}}}}let t={inlineAll:function R(g){if(!r.isElement(g))return Promise.resolve(g);return U(g).then(function(){return r.isHTMLImageElement(g)?p(g).inline():Promise.all(r.asArray(g.childNodes).map(function(f){return R(f)}))});function U(f){let u=["background","background-image"],_=u.map(function(s){let y=f.style.getPropertyValue(s),b=f.style.getPropertyPriority(s);return y?E.inlineAll(y).then(function(A){f.style.setProperty(s,A,b);}):Promise.resolve()});return Promise.all(_).then(function(){return f})}},impl:{newImage:p}};function p(R){return {inline:function(g){return r.isDataUrl(R.src)?Promise.resolve():Promise.resolve(R.src).then(g||r.getAndEncode).then(function(U){return new Promise(function(f){R.onload=f,R.onerror=f,R.src=U;})})}}}let c={copyDefaultStyles:true,imagePlaceholder:void 0,cacheBust:false,useCredentials:false,useCredentialsFilters:[],httpTimeout:3e4,styleCaching:"strict",corsImg:void 0},w={toSvg:n,toPng:function(R,g){return h(R,g).then(function(U){return U.toDataURL()})},toJpeg:function(R,g){return h(R,g).then(function(U){return U.toDataURL("image/jpeg",(g?g.quality:void 0)||1)})},toBlob:function(R,g){return h(R,g).then(r.canvasToBlob)},toPixelData:function(R,g){return h(R,g).then(function(U){return U.getContext("2d").getImageData(0,0,r.width(R),r.height(R)).data})},toCanvas:h,impl:{fontFaces:l,images:t,util:r,inliner:E,urlCache:[],options:{},copyOptions:function(R){R.copyDefaultStyles===void 0?w.impl.options.copyDefaultStyles=c.copyDefaultStyles:w.impl.options.copyDefaultStyles=R.copyDefaultStyles,w.impl.options.imagePlaceholder=(R.imagePlaceholder===void 0?c:R).imagePlaceholder,w.impl.options.cacheBust=(R.cacheBust===void 0?c:R).cacheBust,w.impl.options.corsImg=(R.corsImg===void 0?c:R).corsImg,w.impl.options.useCredentials=(R.useCredentials===void 0?c:R).useCredentials,w.impl.options.useCredentialsFilters=(R.useCredentialsFilters===void 0?c:R).useCredentialsFilters,w.impl.options.httpTimeout=(R.httpTimeout===void 0?c:R).httpTimeout,w.impl.options.styleCaching=(R.styleCaching===void 0?c:R).styleCaching;}}},S=(typeof nt=="object"&&typeof rt=="object"?rt.exports=w:i.domtoimage=w,(globalThis.Node===void 0?void 0:globalThis.Node.ELEMENT_NODE)||1),o=(i===void 0?void 0:i.getComputedStyle)||(globalThis.window===void 0?void 0:globalThis.window.getComputedStyle)||globalThis.getComputedStyle,a=(i===void 0?void 0:i.atob)||(globalThis.window===void 0?void 0:globalThis.window.atob)||globalThis.atob;function n(R,g){w.impl.util.getWindow(R);let f=(g=g||{},w.impl.copyOptions(g),[]);return Promise.resolve(R).then(function(u){if(u.nodeType===S)return u;var _=u,s=globalThis.document.createElement("span");return _.replaceWith(s),s.append(u),f.push({child:_,wrapper:s}),s}).then(function(u){return (function _(s,y,b,A){let T=y.filter;if(s===v||r.isHTMLScriptElement(s)||r.isHTMLStyleElement(s)||r.isHTMLLinkElement(s)||b!==null&&T&&!T(s))return Promise.resolve();return Promise.resolve(s).then(m).then(d).then(function(D){return O(D,x(s))}).then(P).then(function(D){return N(D,s)});function m(D){return r.isHTMLCanvasElement(D)?r.makeImage(D.toDataURL()):D.cloneNode(false)}function d(D){return y.adjustClonedNode&&y.adjustClonedNode(s,D,false),Promise.resolve(D)}function P(D){return y.adjustClonedNode&&y.adjustClonedNode(s,D,true),Promise.resolve(D)}function x(D){return r.isElementHostForOpenShadowRoot(D)?D.shadowRoot:D}function O(D,Q){let H=K(Q),F=Promise.resolve();if(H.length!==0){let V=o($(Q));r.asArray(H).forEach(function(z){F=F.then(function(){return _(z,y,V).then(function(q){q&&D.appendChild(q);})});});}return F.then(function(){return D});function $(V){return r.isShadowRoot(V)?V.host:V}function K(V){if(r.isShadowSlotElement(V)){let z=V.assignedNodes();if(z&&0<z.length)return z}return V.childNodes}}function N(D,Q){return !r.isElement(D)||r.isShadowSlotElement(Q)?Promise.resolve(D):Promise.resolve().then(F).then($).then(K).then(V).then(H).then(function(){return D});function H(){r.isHTMLImageElement(D)&&(D.removeAttribute("loading"),Q.srcset||Q.sizes)&&(D.removeAttribute("srcset"),D.removeAttribute("sizes"),D.src=Q.currentSrc||Q.src);}function F(){function z(G,W){W.font=G.font,W.fontFamily=G.fontFamily,W.fontFeatureSettings=G.fontFeatureSettings,W.fontKerning=G.fontKerning,W.fontSize=G.fontSize,W.fontStretch=G.fontStretch,W.fontStyle=G.fontStyle,W.fontVariant=G.fontVariant,W.fontVariantCaps=G.fontVariantCaps,W.fontVariantEastAsian=G.fontVariantEastAsian,W.fontVariantLigatures=G.fontVariantLigatures,W.fontVariantNumeric=G.fontVariantNumeric,W.fontVariationSettings=G.fontVariationSettings,W.fontWeight=G.fontWeight;}function q(G,W){let ie=o(G);ie.cssText?(W.style.cssText=ie.cssText,z(ie,W.style)):(I(y,G,ie,b,W),b===null&&(["inset-block","inset-block-start","inset-block-end"].forEach(ae=>W.style.removeProperty(ae)),["left","right","top","bottom"].forEach(ae=>{W.style.getPropertyValue(ae)&&W.style.setProperty(ae,"0px");})));}q(Q,D);}function $(){let z=r.uid();function q(G){let W=o(Q,G),ie=W.getPropertyValue("content");if(ie!==""&&ie!=="none"){let Y=function(){let J=`.${z}:`+G,ne=(W.cssText?oe:j)();return globalThis.document.createTextNode(J+`{${ne}}`);function oe(){return `${W.cssText} content: ${ie};`}function j(){return r.asArray(W).map(ee).join("; ")+";";function ee(X){let le=W.getPropertyValue(X),ge=W.getPropertyPriority(X)?" !important":"";return X+": "+le+ge}}};let Z=D.getAttribute("class")||"",te=(D.setAttribute("class",Z+" "+z),globalThis.document.createElement("style"));te.appendChild(Y()),D.appendChild(te);}}[":before",":after"].forEach(function(G){q(G);});}function K(){r.isHTMLTextAreaElement(Q)&&(D.innerHTML=Q.value),r.isHTMLInputElement(Q)&&D.setAttribute("value",Q.value);}function V(){r.isSVGElement(D)&&(D.setAttribute("xmlns","http://www.w3.org/2000/svg"),r.isSVGRectElement(D))&&["width","height"].forEach(function(z){let q=D.getAttribute(z);q&&D.style.setProperty(z,q);});}}})(u,g,null)}).then(g.disableEmbedFonts?Promise.resolve(R):C).then(g.disableInlineImages?Promise.resolve(R):M).then(function(u){g.bgcolor&&(u.style.backgroundColor=g.bgcolor),g.width&&(u.style.width=g.width+"px"),g.height&&(u.style.height=g.height+"px"),g.style&&Object.keys(g.style).forEach(function(s){u.style[s]=g.style[s];});let _=null;return typeof g.onclone=="function"&&(_=g.onclone(u)),Promise.resolve(_).then(function(){return u})}).then(function(u){let _=g.width||r.width(R),s=g.height||r.height(R);return Promise.resolve(u).then(function(y){return y.setAttribute("xmlns","http://www.w3.org/1999/xhtml"),new XMLSerializer().serializeToString(y)}).then(r.escapeXhtml).then(function(y){var b=(r.isDimensionMissing(_)?' width="100%"':` width="${_}"`)+(r.isDimensionMissing(s)?' height="100%"':` height="${s}"`);return `<svg xmlns="http://www.w3.org/2000/svg"${(r.isDimensionMissing(_)?"":` width="${_}"`)+(r.isDimensionMissing(s)?"":` height="${s}"`)}><foreignObject${b}>${y}</foreignObject></svg>`}).then(function(y){return "data:image/svg+xml;charset=utf-8,"+y})}).then(function(u){for(;0<f.length;){var _=f.pop();_.wrapper.replaceWith(_.child);}return u}).then(function(u){return w.impl.urlCache=[],v&&(globalThis.document.body.removeChild(v),v=null),B&&clearTimeout(B),B=setTimeout(()=>{B=null,k={};},2e4),u})}function h(R,g){return n(R,g=g||{}).then(r.makeImage).then(function(U){var f=typeof g.scale!="number"?1:g.scale,u=((s,y)=>{let b=g.width||r.width(s),A=g.height||r.height(s);return r.isDimensionMissing(b)&&(b=r.isDimensionMissing(A)?300:2*A),r.isDimensionMissing(A)&&(A=b/2),(s=globalThis.document.createElement("canvas")).width=b*y,s.height=A*y,g.bgcolor&&((y=s.getContext("2d")).fillStyle=g.bgcolor,y.fillRect(0,0,s.width,s.height)),s})(R,f),_=u.getContext("2d");return _.msImageSmoothingEnabled=false,_.imageSmoothingEnabled=false,U&&(_.scale(f,f),_.drawImage(U,0,0)),u})}let v=null;function C(R){return l.resolveAll().then(function(g){var U;return g!==""&&(U=globalThis.document.createElement("style"),R.appendChild(U),U.appendChild(globalThis.document.createTextNode(g))),R})}function M(R){return t.inlineAll(R).then(function(){return R})}function I(R,g,U,f,u){let _=w.impl.options.copyDefaultStyles?((y,b)=>{var A,T=(P=>(y.styleCaching!=="relaxed"?P:P.filter((x,O,N)=>O===0||O===N.length-1)).join(">"))(b=(P=>{var x=[];do if(P.nodeType===S){var O=P.tagName;if(x.push(O),L.includes(O))break}while(P=P.parentNode);return x})(b));{if(k[T])return k[T];b=((P,x)=>{let O=P.body;do{var N=x.pop(),N=P.createElement(N);O.appendChild(N),O=N;}while(0<x.length);return O.textContent="\u200B",O})((A=(()=>{if(v)return v.contentWindow;x=globalThis.document.characterSet||"UTF-8",P=(P=globalThis.document.doctype)?(`<!DOCTYPE ${F(P.name)} ${F(P.publicId)} `+F(P.systemId)).trim()+">":"",(v=globalThis.document.createElement("iframe")).id="domtoimage-sandbox-"+r.uid(),v.style.top="-9999px",v.style.visibility="hidden",v.style.position="fixed",globalThis.document.body.appendChild(v);var P,x,O=v,N="domtoimage-sandbox";try{return O.contentWindow.document.write(P+`<html><head><meta charset='${x}'><title>${N}</title></head><body></body></html>`),O.contentWindow}catch{}var D=globalThis.document.createElement("meta");D.setAttribute("charset",x);try{var Q=globalThis.document.implementation.createHTMLDocument(N),H=(Q.head.appendChild(D),P+Q.documentElement.outerHTML);return O.setAttribute("srcdoc",H),O.contentWindow}catch{}return O.contentDocument.head.appendChild(D),O.contentDocument.title=N,O.contentWindow;function F($){var K;return $?((K=globalThis.document.createElement("div")).innerText=$,K.innerHTML):""}})()).document,b),A=((P,x)=>{let O={},N=P.getComputedStyle(x);return r.asArray(N).forEach(function(D){O[D]=D==="width"||D==="height"?"auto":N.getPropertyValue(D);}),O})(A,b);var m=b;do{var d=m.parentElement;d!==null&&d.removeChild(m),m=d;}while(m&&m.tagName!=="BODY");return k[T]=A}})(R,g):{},s=u.style;r.asArray(U).forEach(function(y){var b,A,T,m;R.filterStyles&&!R.filterStyles(g,y)||(A=U.getPropertyValue(y),T=_[y],b=f?f.getPropertyValue(y):void 0,s.getPropertyValue(y))||(A!==T||f&&A!==b)&&(T=U.getPropertyPriority(y),b=s,A=A,T=T,m=0<=["background-clip"].indexOf(y=y),T?(b.setProperty(y,A,T),m&&b.setProperty("-webkit-"+y,A,T)):(b.setProperty(y,A),m&&b.setProperty("-webkit-"+y,A)));});}let B=null,k={},L=["ADDRESS","ARTICLE","ASIDE","BLOCKQUOTE","DETAILS","DIALOG","DD","DIV","DL","DT","FIELDSET","FIGCAPTION","FIGURE","FOOTER","FORM","H1","H2","H3","H4","H5","H6","HEADER","HGROUP","HR","LI","MAIN","NAV","OL","P","PRE","SECTION","SVG","TABLE","UL","math","svg","BODY","HEAD","HTML"];})(nt);});var kt=Ze(()=>{});var on=Ze((Or,rn)=>{var ht=typeof Map=="function"&&Map.prototype,ot=Object.getOwnPropertyDescriptor&&ht?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,Ke=ht&&ot&&typeof ot.get=="function"?ot.get:null,Bt=ht&&Map.prototype.forEach,pt=typeof Set=="function"&&Set.prototype,it=Object.getOwnPropertyDescriptor&&pt?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,Xe=pt&&it&&typeof it.get=="function"?it.get:null,Ht=pt&&Set.prototype.forEach,Mn=typeof WeakMap=="function"&&WeakMap.prototype,ke=Mn?WeakMap.prototype.has:null,Ln=typeof WeakSet=="function"&&WeakSet.prototype,Be=Ln?WeakSet.prototype.has:null,Dn=typeof WeakRef=="function"&&WeakRef.prototype,Nt=Dn?WeakRef.prototype.deref:null,Fn=Boolean.prototype.valueOf,kn=Object.prototype.toString,Bn=Function.prototype.toString,Hn=String.prototype.match,gt=String.prototype.slice,Ee=String.prototype.replace,Nn=String.prototype.toUpperCase,Qt=String.prototype.toLowerCase,Yt=RegExp.prototype.test,$t=Array.prototype.concat,Ae=Array.prototype.join,Qn=Array.prototype.slice,Wt=Math.floor,lt=typeof BigInt=="function"?BigInt.prototype.valueOf:null,at=Object.getOwnPropertySymbols,ct=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,Me=typeof Symbol=="function"&&typeof Symbol.iterator=="object",He=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===Me||true)?Symbol.toStringTag:null,Jt=Object.prototype.propertyIsEnumerable,zt=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(i){return i.__proto__}:null);function Gt(i,r){if(i===1/0||i===-1/0||i!==i||i&&i>-1e3&&i<1e3||Yt.call(/e/,r))return r;var E=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof i=="number"){var l=i<0?-Wt(-i):Wt(i);if(l!==i){var e=String(l),t=gt.call(r,e.length+1);return Ee.call(e,E,"$&_")+"."+Ee.call(Ee.call(t,/([0-9]{3})/g,"$&_"),/_$/,"")}}return Ee.call(r,E,"$&_")}var ut=kt(),Vt=ut.custom,qt=en(Vt)?Vt:null,Zt={__proto__:null,double:'"',single:"'"},$n={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};rn.exports=function i(r,E,l,e){var t=E||{};if(ve(t,"quoteStyle")&&!ve(Zt,t.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(ve(t,"maxStringLength")&&(typeof t.maxStringLength=="number"?t.maxStringLength<0&&t.maxStringLength!==1/0:t.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var p=ve(t,"customInspect")?t.customInspect:true;if(typeof p!="boolean"&&p!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(ve(t,"indent")&&t.indent!==null&&t.indent!==" "&&!(parseInt(t.indent,10)===t.indent&&t.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(ve(t,"numericSeparator")&&typeof t.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var c=t.numericSeparator;if(typeof r>"u")return "undefined";if(r===null)return "null";if(typeof r=="boolean")return r?"true":"false";if(typeof r=="string")return nn(r,t);if(typeof r=="number"){if(r===0)return 1/0/r>0?"0":"-0";var w=String(r);return c?Gt(r,w):w}if(typeof r=="bigint"){var S=String(r)+"n";return c?Gt(r,S):S}var o=typeof t.depth>"u"?5:t.depth;if(typeof l>"u"&&(l=0),l>=o&&o>0&&typeof r=="object")return ft(r)?"[Array]":"[Object]";var a=ar(t,l);if(typeof e>"u")e=[];else if(tn(e,r)>=0)return "[Circular]";function n(b,A,T){if(A&&(e=Qn.call(e),e.push(A)),T){var m={depth:t.depth};return ve(t,"quoteStyle")&&(m.quoteStyle=t.quoteStyle),i(b,m,l+1,e)}return i(b,t,l+1,e)}if(typeof r=="function"&&!Kt(r)){var h=Jn(r),v=qe(r,n);return "[Function"+(h?": "+h:" (anonymous)")+"]"+(v.length>0?" { "+Ae.call(v,", ")+" }":"")}if(en(r)){var C=Me?Ee.call(String(r),/^(Symbol\(.*\))_[^)]*$/,"$1"):ct.call(r);return typeof r=="object"&&!Me?Fe(C):C}if(rr(r)){for(var M="<"+Qt.call(String(r.nodeName)),I=r.attributes||[],B=0;B<I.length;B++)M+=" "+I[B].name+"="+jt(Wn(I[B].value),"double",t);return M+=">",r.childNodes&&r.childNodes.length&&(M+="..."),M+="</"+Qt.call(String(r.nodeName))+">",M}if(ft(r)){if(r.length===0)return "[]";var k=qe(r,n);return a&&!ir(k)?"["+dt(k,a)+"]":"[ "+Ae.call(k,", ")+" ]"}if(Gn(r)){var L=qe(r,n);return !("cause"in Error.prototype)&&"cause"in r&&!Jt.call(r,"cause")?"{ ["+String(r)+"] "+Ae.call($t.call("[cause]: "+n(r.cause),L),", ")+" }":L.length===0?"["+String(r)+"]":"{ ["+String(r)+"] "+Ae.call(L,", ")+" }"}if(typeof r=="object"&&p){if(qt&&typeof r[qt]=="function"&&ut)return ut(r,{depth:o-l});if(p!=="symbol"&&typeof r.inspect=="function")return r.inspect()}if(Zn(r)){var R=[];return Bt&&Bt.call(r,function(b,A){R.push(n(A,r,true)+" => "+n(b,r));}),Xt("Map",Ke.call(r),R,a)}if(tr(r)){var g=[];return Ht&&Ht.call(r,function(b){g.push(n(b,r));}),Xt("Set",Xe.call(r),g,a)}if(jn(r))return st("WeakMap");if(nr(r))return st("WeakSet");if(er(r))return st("WeakRef");if(qn(r))return Fe(n(Number(r)));if(Xn(r))return Fe(n(lt.call(r)));if(Kn(r))return Fe(Fn.call(r));if(Vn(r))return Fe(n(String(r)));if(typeof globalThis.window<"u"&&r===globalThis.window)return "{ [object Window] }";if(typeof globalThis<"u"&&r===globalThis||typeof global<"u"&&r===global)return "{ [object globalThis] }";if(!zn(r)&&!Kt(r)){var U=qe(r,n),f=zt?zt(r)===Object.prototype:r instanceof Object||r.constructor===Object,u=r instanceof Object?"":"null prototype",_=!f&&He&&Object(r)===r&&He in r?gt.call(Se(r),8,-1):u?"Object":"",s=f||typeof r.constructor!="function"?"":r.constructor.name?r.constructor.name+" ":"",y=s+(_||u?"["+Ae.call($t.call([],_||[],u||[]),": ")+"] ":"");return U.length===0?y+"{}":a?y+"{"+dt(U,a)+"}":y+"{ "+Ae.call(U,", ")+" }"}return String(r)};function jt(i,r,E){var l=E.quoteStyle||r,e=Zt[l];return e+i+e}function Wn(i){return Ee.call(String(i),/"/g,"&quot;")}function Ue(i){return !He||!(typeof i=="object"&&(He in i||typeof i[He]<"u"))}function ft(i){return Se(i)==="[object Array]"&&Ue(i)}function zn(i){return Se(i)==="[object Date]"&&Ue(i)}function Kt(i){return Se(i)==="[object RegExp]"&&Ue(i)}function Gn(i){return Se(i)==="[object Error]"&&Ue(i)}function Vn(i){return Se(i)==="[object String]"&&Ue(i)}function qn(i){return Se(i)==="[object Number]"&&Ue(i)}function Kn(i){return Se(i)==="[object Boolean]"&&Ue(i)}function en(i){if(Me)return i&&typeof i=="object"&&i instanceof Symbol;if(typeof i=="symbol")return true;if(!i||typeof i!="object"||!ct)return false;try{return ct.call(i),!0}catch{}return false}function Xn(i){if(!i||typeof i!="object"||!lt)return false;try{return lt.call(i),!0}catch{}return false}var Yn=Object.prototype.hasOwnProperty||function(i){return i in this};function ve(i,r){return Yn.call(i,r)}function Se(i){return kn.call(i)}function Jn(i){if(i.name)return i.name;var r=Hn.call(Bn.call(i),/^function\s*([\w$]+)/);return r?r[1]:null}function tn(i,r){if(i.indexOf)return i.indexOf(r);for(var E=0,l=i.length;E<l;E++)if(i[E]===r)return E;return -1}function Zn(i){if(!Ke||!i||typeof i!="object")return false;try{Ke.call(i);try{Xe.call(i);}catch{return !0}return i instanceof Map}catch{}return false}function jn(i){if(!ke||!i||typeof i!="object")return false;try{ke.call(i,ke);try{Be.call(i,Be);}catch{return !0}return i instanceof WeakMap}catch{}return false}function er(i){if(!Nt||!i||typeof i!="object")return false;try{return Nt.call(i),!0}catch{}return false}function tr(i){if(!Xe||!i||typeof i!="object")return false;try{Xe.call(i);try{Ke.call(i);}catch{return !0}return i instanceof Set}catch{}return false}function nr(i){if(!Be||!i||typeof i!="object")return false;try{Be.call(i,Be);try{ke.call(i,ke);}catch{return !0}return i instanceof WeakSet}catch{}return false}function rr(i){return !i||typeof i!="object"?false:typeof HTMLElement<"u"&&i instanceof HTMLElement?true:typeof i.nodeName=="string"&&typeof i.getAttribute=="function"}function nn(i,r){if(i.length>r.maxStringLength){var E=i.length-r.maxStringLength,l="... "+E+" more character"+(E>1?"s":"");return nn(gt.call(i,0,r.maxStringLength),r)+l}var e=$n[r.quoteStyle||"single"];e.lastIndex=0;var t=Ee.call(Ee.call(i,e,"\\$1"),/[\x00-\x1f]/g,or);return jt(t,"single",r)}function or(i){var r=i.charCodeAt(0),E={8:"b",9:"t",10:"n",12:"f",13:"r"}[r];return E?"\\"+E:"\\x"+(r<16?"0":"")+Nn.call(r.toString(16))}function Fe(i){return "Object("+i+")"}function st(i){return i+" { ? }"}function Xt(i,r,E,l){var e=l?dt(E,l):Ae.call(E,", ");return i+" ("+r+") {"+e+"}"}function ir(i){for(var r=0;r<i.length;r++)if(tn(i[r],`
1
+ import {useState,useEffect,useRef,useCallback}from'react';import {useMutation}from'@tanstack/react-query';import {identity}from'lodash';import {nanoid}from'nanoid';import yt from'superjson';import {rpcClient,RpcError}from'typed-rpc';var wn=Object.create;var bt=Object.defineProperty;var vn=Object.getOwnPropertyDescriptor;var _n=Object.getOwnPropertyNames;var bn=Object.getPrototypeOf,En=Object.prototype.hasOwnProperty;var Ze=(i,r)=>()=>(r||i((r={exports:{}}).exports,r),r.exports);var Sn=(i,r,E,l)=>{if(r&&typeof r=="object"||typeof r=="function")for(let e of _n(r))!En.call(i,e)&&e!==E&&bt(i,e,{get:()=>r[e],enumerable:!(l=vn(r,e))||l.enumerable});return i};var Et=(i,r,E)=>(E=i!=null?wn(bn(i)):{},Sn(bt(E,"default",{value:i,enumerable:true}),i));var Ft=Ze((nt,rt)=>{(i=>{let r=(()=>{let R=0;return {escape:function(s){return s.replace(/([.*+?^${}()|[\]/\\])/g,"\\$1")},isDataUrl:function(s){return s.search(/^(data:)/)!==-1},canvasToBlob:function(s){return s.toBlob?new Promise(function(A){s.toBlob(A);}):(A=>new Promise(function(b){var w=a(A.toDataURL().split(",")[1]),T=w.length,m=new Uint8Array(T);for(let d=0;d<T;d++)m[d]=w.charCodeAt(d);b(new Blob([m],{type:"image/png"}));}))(s)},resolveUrl:function(s,A){var b=globalThis.document.implementation.createHTMLDocument(),w=b.createElement("base"),T=(b.head.appendChild(w),b.createElement("a"));return b.body.appendChild(T),w.href=A,T.href=s,T.href},getAndEncode:function(s){let A=y.impl.urlCache.find(function(b){return b.url===s});return A||(A={url:s,promise:null},y.impl.urlCache.push(A)),A.promise===null&&(y.impl.options.cacheBust&&(s+=(/\?/.test(s)?"&":"?")+new Date().getTime()),A.promise=new Promise(function(b){let w=new XMLHttpRequest;function T(P){console.error(P),b("");}function m(){var P=y.impl.options.imagePlaceholder;P?b(P):T("Status:"+w.status+" while fetching resource: "+s);}if(w.timeout=y.impl.options.httpTimeout,w.onerror=m,w.ontimeout=m,w.onloadend=function(){if(w.readyState===XMLHttpRequest.DONE){var P=w.status;if(P===0&&s.toLowerCase().startsWith("file://")||200<=P&&P<=300&&w.response!==null){P=w.response,P instanceof Blob||T("Expected response to be a Blob, but got: "+typeof P);let x=new globalThis.FileReader;x.onloadend=function(){var O=x.result;b(O);};try{x.readAsDataURL(P);}catch(O){T("Failed to read the response as Data URL: "+O.toString());}}else m();}},0<y.impl.options.useCredentialsFilters.length&&(y.impl.options.useCredentials=0<y.impl.options.useCredentialsFilters.filter(P=>0<=s.search(P)).length),y.impl.options.useCredentials&&(w.withCredentials=true),y.impl.options.corsImg&&s.indexOf("http")===0&&s.indexOf(globalThis.window.location.origin)===-1){var d=(y.impl.options.corsImg.method||"GET").toUpperCase()==="POST"?"POST":"GET";w.open(d,(y.impl.options.corsImg.url||"").replace("#{cors}",s),true);let P=false,x=y.impl.options.corsImg.headers||{},O=(Object.keys(x).forEach(function(H){x[H].indexOf("application/json")!==-1&&(P=true),w.setRequestHeader(H,x[H]);}),(H=>{try{return JSON.parse(JSON.stringify(H))}catch(D){T("corsImg.data is missing or invalid:"+D.toString());}})(y.impl.options.corsImg.data||""));Object.keys(O).forEach(function(H){typeof O[H]=="string"&&(O[H]=O[H].replace("#{cors}",s));}),w.responseType="blob",w.send(P?JSON.stringify(O):O);}else w.open("GET",s,true),w.responseType="blob",w.send();})),A.promise},uid:function(){return "u"+("0000"+(Math.random()*Math.pow(36,4)<<0).toString(36)).slice(-4)+R++},asArray:function(s){var A=[],b=s.length;for(let w=0;w<b;w++)A.push(s[w]);return A},escapeXhtml:function(s){return s.replace(/%/g,"%25").replace(/#/g,"%23").replace(/\n/g,"%0A")},makeImage:function(s){return s!=="data:,"?new Promise(function(A,b){let w=globalThis.document.createElementNS("http://www.w3.org/2000/svg","svg"),T=new globalThis.Image;y.impl.options.useCredentials&&(T.crossOrigin="use-credentials"),T.onload=function(){globalThis.document.body.removeChild(w),globalThis.window&&globalThis.window.requestAnimationFrame?globalThis.window.requestAnimationFrame(function(){A(T);}):A(T);},T.onerror=m=>{globalThis.document.body.removeChild(w),b(m);},w.appendChild(T),T.src=s,globalThis.document.body.appendChild(w);}):Promise.resolve()},width:function(s){var A=_(s,"width");if(!isNaN(A))return A;var A=_(s,"border-left-width"),b=_(s,"border-right-width");return s.scrollWidth+A+b},height:function(s){var A=_(s,"height");if(!isNaN(A))return A;var A=_(s,"border-top-width"),b=_(s,"border-bottom-width");return s.scrollHeight+A+b},getWindow:g,isElement:u,isElementHostForOpenShadowRoot:function(s){return u(s)&&s.shadowRoot!==null},isShadowRoot:U,isInShadowRoot:f,isHTMLElement:function(s){return s instanceof g(s).HTMLElement},isHTMLCanvasElement:function(s){return s instanceof g(s).HTMLCanvasElement},isHTMLInputElement:function(s){return s instanceof g(s).HTMLInputElement},isHTMLImageElement:function(s){return s instanceof g(s).HTMLImageElement},isHTMLLinkElement:function(s){return s instanceof g(s).HTMLLinkElement},isHTMLScriptElement:function(s){return s instanceof g(s).HTMLScriptElement},isHTMLStyleElement:function(s){return s instanceof g(s).HTMLStyleElement},isHTMLTextAreaElement:function(s){return s instanceof g(s).HTMLTextAreaElement},isShadowSlotElement:function(s){return f(s)&&s instanceof g(s).HTMLSlotElement},isSVGElement:function(s){return s instanceof g(s).SVGElement},isSVGRectElement:function(s){return s instanceof g(s).SVGRectElement},isDimensionMissing:function(s){return isNaN(s)||s<=0}};function g(s){return s=s?s.ownerDocument:void 0,(s?s.defaultView:void 0)||globalThis.window||i}function U(s){return s instanceof g(s).ShadowRoot}function f(s){return s!=null&&s.getRootNode!==void 0&&U(s.getRootNode())}function u(s){return s instanceof g(s).Element}function _(s,A){if(s.nodeType===S){let b=o(s).getPropertyValue(A);if(b.slice(-2)==="px")return b=b.slice(0,-2),parseFloat(b)}return NaN}})(),E=(()=>{let R=/url\(\s*(["']?)((?:\\.|[^\\)])+)\1\s*\)/gm;return {inlineAll:function(_,s,A){return g(_)?Promise.resolve(_).then(U).then(function(b){let w=Promise.resolve(_);return b.forEach(function(T){w=w.then(function(m){return u(m,T,s,A)});}),w}):Promise.resolve(_)},shouldProcess:g,impl:{readUrls:U,inline:u,urlAsRegex:f}};function g(_){return _.search(R)!==-1}function U(_){for(var s,A=[];(s=R.exec(_))!==null;)A.push(s[2]);return A.filter(function(b){return !r.isDataUrl(b)})}function f(_){return new RegExp(`url\\((["']?)(${r.escape(_)})\\1\\)`,"gm")}function u(_,s,A,b){return Promise.resolve(s).then(function(w){return A?r.resolveUrl(w,A):w}).then(b||r.getAndEncode).then(function(w){var T=f(s);return _.replace(T,`url($1${w}$1)`)})}})(),l={resolveAll:function(){return e().then(function(R){return Promise.all(R.map(function(g){return g.resolve()}))}).then(function(R){return R.join(`
2
+ `)})},impl:{readAll:e}};function e(){return Promise.resolve(r.asArray(globalThis.document.styleSheets)).then(function(g){let U=[];return g.forEach(function(f){var u=Object.getPrototypeOf(f);if(Object.prototype.hasOwnProperty.call(u,"cssRules"))try{r.asArray(f.cssRules||[]).forEach(U.push.bind(U));}catch(_){console.error("domtoimage: Error while reading CSS rules from: "+f.href,_.toString());}}),U}).then(function(g){return g.filter(function(U){return U.type===CSSRule.FONT_FACE_RULE}).filter(function(U){return E.shouldProcess(U.style.getPropertyValue("src"))})}).then(function(g){return g.map(R)});function R(g){return {resolve:function(){var U=(g.parentStyleSheet||{}).href;return E.inlineAll(g.cssText,U)},src:function(){return g.style.getPropertyValue("src")}}}}let t={inlineAll:function R(g){if(!r.isElement(g))return Promise.resolve(g);return U(g).then(function(){return r.isHTMLImageElement(g)?p(g).inline():Promise.all(r.asArray(g.childNodes).map(function(f){return R(f)}))});function U(f){let u=["background","background-image"],_=u.map(function(s){let A=f.style.getPropertyValue(s),b=f.style.getPropertyPriority(s);return A?E.inlineAll(A).then(function(w){f.style.setProperty(s,w,b);}):Promise.resolve()});return Promise.all(_).then(function(){return f})}},impl:{newImage:p}};function p(R){return {inline:function(g){return r.isDataUrl(R.src)?Promise.resolve():Promise.resolve(R.src).then(g||r.getAndEncode).then(function(U){return new Promise(function(f){R.onload=f,R.onerror=f,R.src=U;})})}}}let c={copyDefaultStyles:true,imagePlaceholder:void 0,cacheBust:false,useCredentials:false,useCredentialsFilters:[],httpTimeout:3e4,styleCaching:"strict",corsImg:void 0},y={toSvg:n,toPng:function(R,g){return h(R,g).then(function(U){return U.toDataURL()})},toJpeg:function(R,g){return h(R,g).then(function(U){return U.toDataURL("image/jpeg",(g?g.quality:void 0)||1)})},toBlob:function(R,g){return h(R,g).then(r.canvasToBlob)},toPixelData:function(R,g){return h(R,g).then(function(U){return U.getContext("2d").getImageData(0,0,r.width(R),r.height(R)).data})},toCanvas:h,impl:{fontFaces:l,images:t,util:r,inliner:E,urlCache:[],options:{},copyOptions:function(R){R.copyDefaultStyles===void 0?y.impl.options.copyDefaultStyles=c.copyDefaultStyles:y.impl.options.copyDefaultStyles=R.copyDefaultStyles,y.impl.options.imagePlaceholder=(R.imagePlaceholder===void 0?c:R).imagePlaceholder,y.impl.options.cacheBust=(R.cacheBust===void 0?c:R).cacheBust,y.impl.options.corsImg=(R.corsImg===void 0?c:R).corsImg,y.impl.options.useCredentials=(R.useCredentials===void 0?c:R).useCredentials,y.impl.options.useCredentialsFilters=(R.useCredentialsFilters===void 0?c:R).useCredentialsFilters,y.impl.options.httpTimeout=(R.httpTimeout===void 0?c:R).httpTimeout,y.impl.options.styleCaching=(R.styleCaching===void 0?c:R).styleCaching;}}},S=(typeof nt=="object"&&typeof rt=="object"?rt.exports=y:i.domtoimage=y,(globalThis.Node===void 0?void 0:globalThis.Node.ELEMENT_NODE)||1),o=(i===void 0?void 0:i.getComputedStyle)||(globalThis.window===void 0?void 0:globalThis.window.getComputedStyle)||globalThis.getComputedStyle,a=(i===void 0?void 0:i.atob)||(globalThis.window===void 0?void 0:globalThis.window.atob)||globalThis.atob;function n(R,g){y.impl.util.getWindow(R);let f=(g=g||{},y.impl.copyOptions(g),[]);return Promise.resolve(R).then(function(u){if(u.nodeType===S)return u;var _=u,s=globalThis.document.createElement("span");return _.replaceWith(s),s.append(u),f.push({child:_,wrapper:s}),s}).then(function(u){return (function _(s,A,b,w){let T=A.filter;if(s===v||r.isHTMLScriptElement(s)||r.isHTMLStyleElement(s)||r.isHTMLLinkElement(s)||b!==null&&T&&!T(s))return Promise.resolve();return Promise.resolve(s).then(m).then(d).then(function(D){return O(D,x(s))}).then(P).then(function(D){return H(D,s)});function m(D){return r.isHTMLCanvasElement(D)?r.makeImage(D.toDataURL()):D.cloneNode(false)}function d(D){return A.adjustClonedNode&&A.adjustClonedNode(s,D,false),Promise.resolve(D)}function P(D){return A.adjustClonedNode&&A.adjustClonedNode(s,D,true),Promise.resolve(D)}function x(D){return r.isElementHostForOpenShadowRoot(D)?D.shadowRoot:D}function O(D,Q){let N=K(Q),F=Promise.resolve();if(N.length!==0){let V=o($(Q));r.asArray(N).forEach(function(z){F=F.then(function(){return _(z,A,V).then(function(q){q&&D.appendChild(q);})});});}return F.then(function(){return D});function $(V){return r.isShadowRoot(V)?V.host:V}function K(V){if(r.isShadowSlotElement(V)){let z=V.assignedNodes();if(z&&0<z.length)return z}return V.childNodes}}function H(D,Q){return !r.isElement(D)||r.isShadowSlotElement(Q)?Promise.resolve(D):Promise.resolve().then(F).then($).then(K).then(V).then(N).then(function(){return D});function N(){r.isHTMLImageElement(D)&&(D.removeAttribute("loading"),Q.srcset||Q.sizes)&&(D.removeAttribute("srcset"),D.removeAttribute("sizes"),D.src=Q.currentSrc||Q.src);}function F(){function z(G,W){W.font=G.font,W.fontFamily=G.fontFamily,W.fontFeatureSettings=G.fontFeatureSettings,W.fontKerning=G.fontKerning,W.fontSize=G.fontSize,W.fontStretch=G.fontStretch,W.fontStyle=G.fontStyle,W.fontVariant=G.fontVariant,W.fontVariantCaps=G.fontVariantCaps,W.fontVariantEastAsian=G.fontVariantEastAsian,W.fontVariantLigatures=G.fontVariantLigatures,W.fontVariantNumeric=G.fontVariantNumeric,W.fontVariationSettings=G.fontVariationSettings,W.fontWeight=G.fontWeight;}function q(G,W){let ie=o(G);ie.cssText?(W.style.cssText=ie.cssText,z(ie,W.style)):(I(A,G,ie,b,W),b===null&&(["inset-block","inset-block-start","inset-block-end"].forEach(ae=>W.style.removeProperty(ae)),["left","right","top","bottom"].forEach(ae=>{W.style.getPropertyValue(ae)&&W.style.setProperty(ae,"0px");})));}q(Q,D);}function $(){let z=r.uid();function q(G){let W=o(Q,G),ie=W.getPropertyValue("content");if(ie!==""&&ie!=="none"){let Y=function(){let J=`.${z}:`+G,ne=(W.cssText?oe:j)();return globalThis.document.createTextNode(J+`{${ne}}`);function oe(){return `${W.cssText} content: ${ie};`}function j(){return r.asArray(W).map(ee).join("; ")+";";function ee(X){let le=W.getPropertyValue(X),ge=W.getPropertyPriority(X)?" !important":"";return X+": "+le+ge}}};let Z=D.getAttribute("class")||"",te=(D.setAttribute("class",Z+" "+z),globalThis.document.createElement("style"));te.appendChild(Y()),D.appendChild(te);}}[":before",":after"].forEach(function(G){q(G);});}function K(){r.isHTMLTextAreaElement(Q)&&(D.innerHTML=Q.value),r.isHTMLInputElement(Q)&&D.setAttribute("value",Q.value);}function V(){r.isSVGElement(D)&&(D.setAttribute("xmlns","http://www.w3.org/2000/svg"),r.isSVGRectElement(D))&&["width","height"].forEach(function(z){let q=D.getAttribute(z);q&&D.style.setProperty(z,q);});}}})(u,g,null)}).then(g.disableEmbedFonts?Promise.resolve(R):C).then(g.disableInlineImages?Promise.resolve(R):M).then(function(u){g.bgcolor&&(u.style.backgroundColor=g.bgcolor),g.width&&(u.style.width=g.width+"px"),g.height&&(u.style.height=g.height+"px"),g.style&&Object.keys(g.style).forEach(function(s){u.style[s]=g.style[s];});let _=null;return typeof g.onclone=="function"&&(_=g.onclone(u)),Promise.resolve(_).then(function(){return u})}).then(function(u){let _=g.width||r.width(R),s=g.height||r.height(R);return Promise.resolve(u).then(function(A){return A.setAttribute("xmlns","http://www.w3.org/1999/xhtml"),new XMLSerializer().serializeToString(A)}).then(r.escapeXhtml).then(function(A){var b=(r.isDimensionMissing(_)?' width="100%"':` width="${_}"`)+(r.isDimensionMissing(s)?' height="100%"':` height="${s}"`);return `<svg xmlns="http://www.w3.org/2000/svg"${(r.isDimensionMissing(_)?"":` width="${_}"`)+(r.isDimensionMissing(s)?"":` height="${s}"`)}><foreignObject${b}>${A}</foreignObject></svg>`}).then(function(A){return "data:image/svg+xml;charset=utf-8,"+A})}).then(function(u){for(;0<f.length;){var _=f.pop();_.wrapper.replaceWith(_.child);}return u}).then(function(u){return y.impl.urlCache=[],v&&(globalThis.document.body.removeChild(v),v=null),B&&clearTimeout(B),B=setTimeout(()=>{B=null,k={};},2e4),u})}function h(R,g){return n(R,g=g||{}).then(r.makeImage).then(function(U){var f=typeof g.scale!="number"?1:g.scale,u=((s,A)=>{let b=g.width||r.width(s),w=g.height||r.height(s);return r.isDimensionMissing(b)&&(b=r.isDimensionMissing(w)?300:2*w),r.isDimensionMissing(w)&&(w=b/2),(s=globalThis.document.createElement("canvas")).width=b*A,s.height=w*A,g.bgcolor&&((A=s.getContext("2d")).fillStyle=g.bgcolor,A.fillRect(0,0,s.width,s.height)),s})(R,f),_=u.getContext("2d");return _.msImageSmoothingEnabled=false,_.imageSmoothingEnabled=false,U&&(_.scale(f,f),_.drawImage(U,0,0)),u})}let v=null;function C(R){return l.resolveAll().then(function(g){var U;return g!==""&&(U=globalThis.document.createElement("style"),R.appendChild(U),U.appendChild(globalThis.document.createTextNode(g))),R})}function M(R){return t.inlineAll(R).then(function(){return R})}function I(R,g,U,f,u){let _=y.impl.options.copyDefaultStyles?((A,b)=>{var w,T=(P=>(A.styleCaching!=="relaxed"?P:P.filter((x,O,H)=>O===0||O===H.length-1)).join(">"))(b=(P=>{var x=[];do if(P.nodeType===S){var O=P.tagName;if(x.push(O),L.includes(O))break}while(P=P.parentNode);return x})(b));{if(k[T])return k[T];b=((P,x)=>{let O=P.body;do{var H=x.pop(),H=P.createElement(H);O.appendChild(H),O=H;}while(0<x.length);return O.textContent="\u200B",O})((w=(()=>{if(v)return v.contentWindow;x=globalThis.document.characterSet||"UTF-8",P=(P=globalThis.document.doctype)?(`<!DOCTYPE ${F(P.name)} ${F(P.publicId)} `+F(P.systemId)).trim()+">":"",(v=globalThis.document.createElement("iframe")).id="domtoimage-sandbox-"+r.uid(),v.style.top="-9999px",v.style.visibility="hidden",v.style.position="fixed",globalThis.document.body.appendChild(v);var P,x,O=v,H="domtoimage-sandbox";try{return O.contentWindow.document.write(P+`<html><head><meta charset='${x}'><title>${H}</title></head><body></body></html>`),O.contentWindow}catch{}var D=globalThis.document.createElement("meta");D.setAttribute("charset",x);try{var Q=globalThis.document.implementation.createHTMLDocument(H),N=(Q.head.appendChild(D),P+Q.documentElement.outerHTML);return O.setAttribute("srcdoc",N),O.contentWindow}catch{}return O.contentDocument.head.appendChild(D),O.contentDocument.title=H,O.contentWindow;function F($){var K;return $?((K=globalThis.document.createElement("div")).innerText=$,K.innerHTML):""}})()).document,b),w=((P,x)=>{let O={},H=P.getComputedStyle(x);return r.asArray(H).forEach(function(D){O[D]=D==="width"||D==="height"?"auto":H.getPropertyValue(D);}),O})(w,b);var m=b;do{var d=m.parentElement;d!==null&&d.removeChild(m),m=d;}while(m&&m.tagName!=="BODY");return k[T]=w}})(R,g):{},s=u.style;r.asArray(U).forEach(function(A){var b,w,T,m;R.filterStyles&&!R.filterStyles(g,A)||(w=U.getPropertyValue(A),T=_[A],b=f?f.getPropertyValue(A):void 0,s.getPropertyValue(A))||(w!==T||f&&w!==b)&&(T=U.getPropertyPriority(A),b=s,w=w,T=T,m=0<=["background-clip"].indexOf(A=A),T?(b.setProperty(A,w,T),m&&b.setProperty("-webkit-"+A,w,T)):(b.setProperty(A,w),m&&b.setProperty("-webkit-"+A,w)));});}let B=null,k={},L=["ADDRESS","ARTICLE","ASIDE","BLOCKQUOTE","DETAILS","DIALOG","DD","DIV","DL","DT","FIELDSET","FIGCAPTION","FIGURE","FOOTER","FORM","H1","H2","H3","H4","H5","H6","HEADER","HGROUP","HR","LI","MAIN","NAV","OL","P","PRE","SECTION","SVG","TABLE","UL","math","svg","BODY","HEAD","HTML"];})(nt);});var kt=Ze(()=>{});var on=Ze((Or,rn)=>{var ht=typeof Map=="function"&&Map.prototype,ot=Object.getOwnPropertyDescriptor&&ht?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,Ke=ht&&ot&&typeof ot.get=="function"?ot.get:null,Bt=ht&&Map.prototype.forEach,pt=typeof Set=="function"&&Set.prototype,it=Object.getOwnPropertyDescriptor&&pt?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,Xe=pt&&it&&typeof it.get=="function"?it.get:null,Nt=pt&&Set.prototype.forEach,Mn=typeof WeakMap=="function"&&WeakMap.prototype,ke=Mn?WeakMap.prototype.has:null,Ln=typeof WeakSet=="function"&&WeakSet.prototype,Be=Ln?WeakSet.prototype.has:null,Dn=typeof WeakRef=="function"&&WeakRef.prototype,Ht=Dn?WeakRef.prototype.deref:null,Fn=Boolean.prototype.valueOf,kn=Object.prototype.toString,Bn=Function.prototype.toString,Nn=String.prototype.match,gt=String.prototype.slice,Ee=String.prototype.replace,Hn=String.prototype.toUpperCase,Qt=String.prototype.toLowerCase,Yt=RegExp.prototype.test,$t=Array.prototype.concat,Ae=Array.prototype.join,Qn=Array.prototype.slice,Wt=Math.floor,lt=typeof BigInt=="function"?BigInt.prototype.valueOf:null,at=Object.getOwnPropertySymbols,ct=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,Me=typeof Symbol=="function"&&typeof Symbol.iterator=="object",Ne=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===Me||true)?Symbol.toStringTag:null,Jt=Object.prototype.propertyIsEnumerable,zt=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(i){return i.__proto__}:null);function Gt(i,r){if(i===1/0||i===-1/0||i!==i||i&&i>-1e3&&i<1e3||Yt.call(/e/,r))return r;var E=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof i=="number"){var l=i<0?-Wt(-i):Wt(i);if(l!==i){var e=String(l),t=gt.call(r,e.length+1);return Ee.call(e,E,"$&_")+"."+Ee.call(Ee.call(t,/([0-9]{3})/g,"$&_"),/_$/,"")}}return Ee.call(r,E,"$&_")}var ut=kt(),Vt=ut.custom,qt=en(Vt)?Vt:null,Zt={__proto__:null,double:'"',single:"'"},$n={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};rn.exports=function i(r,E,l,e){var t=E||{};if(ve(t,"quoteStyle")&&!ve(Zt,t.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(ve(t,"maxStringLength")&&(typeof t.maxStringLength=="number"?t.maxStringLength<0&&t.maxStringLength!==1/0:t.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var p=ve(t,"customInspect")?t.customInspect:true;if(typeof p!="boolean"&&p!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(ve(t,"indent")&&t.indent!==null&&t.indent!==" "&&!(parseInt(t.indent,10)===t.indent&&t.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(ve(t,"numericSeparator")&&typeof t.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var c=t.numericSeparator;if(typeof r>"u")return "undefined";if(r===null)return "null";if(typeof r=="boolean")return r?"true":"false";if(typeof r=="string")return nn(r,t);if(typeof r=="number"){if(r===0)return 1/0/r>0?"0":"-0";var y=String(r);return c?Gt(r,y):y}if(typeof r=="bigint"){var S=String(r)+"n";return c?Gt(r,S):S}var o=typeof t.depth>"u"?5:t.depth;if(typeof l>"u"&&(l=0),l>=o&&o>0&&typeof r=="object")return ft(r)?"[Array]":"[Object]";var a=ar(t,l);if(typeof e>"u")e=[];else if(tn(e,r)>=0)return "[Circular]";function n(b,w,T){if(w&&(e=Qn.call(e),e.push(w)),T){var m={depth:t.depth};return ve(t,"quoteStyle")&&(m.quoteStyle=t.quoteStyle),i(b,m,l+1,e)}return i(b,t,l+1,e)}if(typeof r=="function"&&!Kt(r)){var h=Jn(r),v=qe(r,n);return "[Function"+(h?": "+h:" (anonymous)")+"]"+(v.length>0?" { "+Ae.call(v,", ")+" }":"")}if(en(r)){var C=Me?Ee.call(String(r),/^(Symbol\(.*\))_[^)]*$/,"$1"):ct.call(r);return typeof r=="object"&&!Me?Fe(C):C}if(rr(r)){for(var M="<"+Qt.call(String(r.nodeName)),I=r.attributes||[],B=0;B<I.length;B++)M+=" "+I[B].name+"="+jt(Wn(I[B].value),"double",t);return M+=">",r.childNodes&&r.childNodes.length&&(M+="..."),M+="</"+Qt.call(String(r.nodeName))+">",M}if(ft(r)){if(r.length===0)return "[]";var k=qe(r,n);return a&&!ir(k)?"["+dt(k,a)+"]":"[ "+Ae.call(k,", ")+" ]"}if(Gn(r)){var L=qe(r,n);return !("cause"in Error.prototype)&&"cause"in r&&!Jt.call(r,"cause")?"{ ["+String(r)+"] "+Ae.call($t.call("[cause]: "+n(r.cause),L),", ")+" }":L.length===0?"["+String(r)+"]":"{ ["+String(r)+"] "+Ae.call(L,", ")+" }"}if(typeof r=="object"&&p){if(qt&&typeof r[qt]=="function"&&ut)return ut(r,{depth:o-l});if(p!=="symbol"&&typeof r.inspect=="function")return r.inspect()}if(Zn(r)){var R=[];return Bt&&Bt.call(r,function(b,w){R.push(n(w,r,true)+" => "+n(b,r));}),Xt("Map",Ke.call(r),R,a)}if(tr(r)){var g=[];return Nt&&Nt.call(r,function(b){g.push(n(b,r));}),Xt("Set",Xe.call(r),g,a)}if(jn(r))return st("WeakMap");if(nr(r))return st("WeakSet");if(er(r))return st("WeakRef");if(qn(r))return Fe(n(Number(r)));if(Xn(r))return Fe(n(lt.call(r)));if(Kn(r))return Fe(Fn.call(r));if(Vn(r))return Fe(n(String(r)));if(typeof globalThis.window<"u"&&r===globalThis.window)return "{ [object Window] }";if(typeof globalThis<"u"&&r===globalThis||typeof global<"u"&&r===global)return "{ [object globalThis] }";if(!zn(r)&&!Kt(r)){var U=qe(r,n),f=zt?zt(r)===Object.prototype:r instanceof Object||r.constructor===Object,u=r instanceof Object?"":"null prototype",_=!f&&Ne&&Object(r)===r&&Ne in r?gt.call(Se(r),8,-1):u?"Object":"",s=f||typeof r.constructor!="function"?"":r.constructor.name?r.constructor.name+" ":"",A=s+(_||u?"["+Ae.call($t.call([],_||[],u||[]),": ")+"] ":"");return U.length===0?A+"{}":a?A+"{"+dt(U,a)+"}":A+"{ "+Ae.call(U,", ")+" }"}return String(r)};function jt(i,r,E){var l=E.quoteStyle||r,e=Zt[l];return e+i+e}function Wn(i){return Ee.call(String(i),/"/g,"&quot;")}function Ue(i){return !Ne||!(typeof i=="object"&&(Ne in i||typeof i[Ne]<"u"))}function ft(i){return Se(i)==="[object Array]"&&Ue(i)}function zn(i){return Se(i)==="[object Date]"&&Ue(i)}function Kt(i){return Se(i)==="[object RegExp]"&&Ue(i)}function Gn(i){return Se(i)==="[object Error]"&&Ue(i)}function Vn(i){return Se(i)==="[object String]"&&Ue(i)}function qn(i){return Se(i)==="[object Number]"&&Ue(i)}function Kn(i){return Se(i)==="[object Boolean]"&&Ue(i)}function en(i){if(Me)return i&&typeof i=="object"&&i instanceof Symbol;if(typeof i=="symbol")return true;if(!i||typeof i!="object"||!ct)return false;try{return ct.call(i),!0}catch{}return false}function Xn(i){if(!i||typeof i!="object"||!lt)return false;try{return lt.call(i),!0}catch{}return false}var Yn=Object.prototype.hasOwnProperty||function(i){return i in this};function ve(i,r){return Yn.call(i,r)}function Se(i){return kn.call(i)}function Jn(i){if(i.name)return i.name;var r=Nn.call(Bn.call(i),/^function\s*([\w$]+)/);return r?r[1]:null}function tn(i,r){if(i.indexOf)return i.indexOf(r);for(var E=0,l=i.length;E<l;E++)if(i[E]===r)return E;return -1}function Zn(i){if(!Ke||!i||typeof i!="object")return false;try{Ke.call(i);try{Xe.call(i);}catch{return !0}return i instanceof Map}catch{}return false}function jn(i){if(!ke||!i||typeof i!="object")return false;try{ke.call(i,ke);try{Be.call(i,Be);}catch{return !0}return i instanceof WeakMap}catch{}return false}function er(i){if(!Ht||!i||typeof i!="object")return false;try{return Ht.call(i),!0}catch{}return false}function tr(i){if(!Xe||!i||typeof i!="object")return false;try{Xe.call(i);try{Ke.call(i);}catch{return !0}return i instanceof Set}catch{}return false}function nr(i){if(!Be||!i||typeof i!="object")return false;try{Be.call(i,Be);try{ke.call(i,ke);}catch{return !0}return i instanceof WeakSet}catch{}return false}function rr(i){return !i||typeof i!="object"?false:typeof HTMLElement<"u"&&i instanceof HTMLElement?true:typeof i.nodeName=="string"&&typeof i.getAttribute=="function"}function nn(i,r){if(i.length>r.maxStringLength){var E=i.length-r.maxStringLength,l="... "+E+" more character"+(E>1?"s":"");return nn(gt.call(i,0,r.maxStringLength),r)+l}var e=$n[r.quoteStyle||"single"];e.lastIndex=0;var t=Ee.call(Ee.call(i,e,"\\$1"),/[\x00-\x1f]/g,or);return jt(t,"single",r)}function or(i){var r=i.charCodeAt(0),E={8:"b",9:"t",10:"n",12:"f",13:"r"}[r];return E?"\\"+E:"\\x"+(r<16?"0":"")+Hn.call(r.toString(16))}function Fe(i){return "Object("+i+")"}function st(i){return i+" { ? }"}function Xt(i,r,E,l){var e=l?dt(E,l):Ae.call(E,", ");return i+" ("+r+") {"+e+"}"}function ir(i){for(var r=0;r<i.length;r++)if(tn(i[r],`
3
3
  `)>=0)return false;return true}function ar(i,r){var E;if(i.indent===" ")E=" ";else if(typeof i.indent=="number"&&i.indent>0)E=Ae.call(Array(i.indent+1)," ");else return null;return {base:E,prev:Ae.call(Array(r+1),E)}}function dt(i,r){if(i.length===0)return "";var E=`
4
4
  `+r.prev+r.base;return E+Ae.call(i,","+E)+`
5
- `+r.prev}function qe(i,r){var E=ft(i),l=[];if(E){l.length=i.length;for(var e=0;e<i.length;e++)l[e]=ve(i,e)?r(i[e],i):"";}var t=typeof at=="function"?at(i):[],p;if(Me){p={};for(var c=0;c<t.length;c++)p["$"+t[c]]=t[c];}for(var w in i)ve(i,w)&&(E&&String(Number(w))===w&&w<i.length||Me&&p["$"+w]instanceof Symbol||(Yt.call(/[^\w$]/,w)?l.push(r(w,i)+": "+r(i[w],i)):l.push(w+": "+r(i[w],i))));if(typeof at=="function")for(var S=0;S<t.length;S++)Jt.call(i,t[S])&&l.push("["+r(t[S])+"]: "+r(i[t[S]],i));return l}});function Tn(i,r){return r.forEach((function(E){E&&typeof E!="string"&&!Array.isArray(E)&&Object.keys(E).forEach((function(l){if(l!=="default"&&!(l in i)){var e=Object.getOwnPropertyDescriptor(E,l);Object.defineProperty(i,l,e.get?e:{enumerable:true,get:function(){return E[l]}});}}));})),Object.freeze(i)}function Tt(i,r){return new Promise((function(E,l){let e;return In(i).then((function(t){try{return e=t,E(new Blob([r.slice(0,2),e,r.slice(2)],{type:"image/jpeg"}))}catch(p){return l(p)}}),l)}))}var In=i=>new Promise(((r,E)=>{let l=new globalThis.FileReader;l.addEventListener("load",(({target:{result:e}})=>{let t=new DataView(e),p=0;if(t.getUint16(p)!==65496)return E("not a valid JPEG");for(p+=2;;){let c=t.getUint16(p);if(c===65498)break;let w=t.getUint16(p+2);if(c===65505&&t.getUint32(p+4)===1165519206){let S=p+10,o;switch(t.getUint16(S)){case 18761:o=true;break;case 19789:o=false;break;default:return E("TIFF header contains invalid endian")}if(t.getUint16(S+2,o)!==42)return E("TIFF header contains invalid version");let a=t.getUint32(S+4,o),n=S+a+2+12*t.getUint16(S+a,o);for(let h=S+a+2;h<n;h+=12)if(t.getUint16(h,o)==274){if(t.getUint16(h+2,o)!==3)return E("Orientation data type is invalid");if(t.getUint32(h+4,o)!==1)return E("Orientation data count is invalid");t.setUint16(h+8,1,o);break}return r(e.slice(p,p+2+w))}p+=2+w;}return r(new Blob)})),l.readAsArrayBuffer(i);})),$e={},Rn={get exports(){return $e},set exports(i){$e=i;}};(function(i){var r,E,l={};Rn.exports=l,l.parse=function(e,t){for(var p=l.bin.readUshort,c=l.bin.readUint,w=0,S={},o=new Uint8Array(e),a=o.length-4;c(o,a)!=101010256;)a--;w=a,w+=4;var n=p(o,w+=4);p(o,w+=2);var h=c(o,w+=2),v=c(o,w+=4);w+=4,w=v;for(var C=0;C<n;C++){c(o,w),w+=4,w+=4,w+=4,c(o,w+=4),h=c(o,w+=4);var M=c(o,w+=4),I=p(o,w+=4),B=p(o,w+2),k=p(o,w+4);w+=6;var L=c(o,w+=8);w+=4,w+=I+B+k,l._readLocal(o,L,S,h,M,t);}return S},l._readLocal=function(e,t,p,c,w,S){var o=l.bin.readUshort,a=l.bin.readUint;a(e,t),o(e,t+=4),o(e,t+=2);var n=o(e,t+=2);a(e,t+=2),a(e,t+=4),t+=4;var h=o(e,t+=8),v=o(e,t+=2);t+=2;var C=l.bin.readUTF8(e,t,h);if(t+=h,t+=v,S)p[C]={size:w,csize:c};else {var M=new Uint8Array(e.buffer,t);if(n==0)p[C]=new Uint8Array(M.buffer.slice(t,t+c));else {if(n!=8)throw "unknown compression method: "+n;var I=new Uint8Array(w);l.inflateRaw(M,I),p[C]=I;}}},l.inflateRaw=function(e,t){return l.F.inflate(e,t)},l.inflate=function(e,t){return e[0],e[1],l.inflateRaw(new Uint8Array(e.buffer,e.byteOffset+2,e.length-6),t)},l.deflate=function(e,t){t==null&&(t={level:6});var p=0,c=new Uint8Array(50+Math.floor(1.1*e.length));c[p]=120,c[p+1]=156,p+=2,p=l.F.deflateRaw(e,c,p,t.level);var w=l.adler(e,0,e.length);return c[p+0]=w>>>24&255,c[p+1]=w>>>16&255,c[p+2]=w>>>8&255,c[p+3]=w>>>0&255,new Uint8Array(c.buffer,0,p+4)},l.deflateRaw=function(e,t){t==null&&(t={level:6});var p=new Uint8Array(50+Math.floor(1.1*e.length)),c=l.F.deflateRaw(e,p,c,t.level);return new Uint8Array(p.buffer,0,c)},l.encode=function(e,t){t==null&&(t=false);var p=0,c=l.bin.writeUint,w=l.bin.writeUshort,S={};for(var o in e){var a=!l._noNeed(o)&&!t,n=e[o],h=l.crc.crc(n,0,n.length);S[o]={cpr:a,usize:n.length,crc:h,file:a?l.deflateRaw(n):n};}for(var o in S)p+=S[o].file.length+30+46+2*l.bin.sizeUTF8(o);p+=22;var v=new Uint8Array(p),C=0,M=[];for(var o in S){var I=S[o];M.push(C),C=l._writeHeader(v,C,o,I,0);}var B=0,k=C;for(var o in S)I=S[o],M.push(C),C=l._writeHeader(v,C,o,I,1,M[B++]);var L=C-k;return c(v,C,101010256),C+=4,w(v,C+=4,B),w(v,C+=2,B),c(v,C+=2,L),c(v,C+=4,k),C+=4,C+=2,v.buffer},l._noNeed=function(e){var t=e.split(".").pop().toLowerCase();return "png,jpg,jpeg,zip".indexOf(t)!=-1},l._writeHeader=function(e,t,p,c,w,S){var o=l.bin.writeUint,a=l.bin.writeUshort,n=c.file;return o(e,t,w==0?67324752:33639248),t+=4,w==1&&(t+=2),a(e,t,20),a(e,t+=2,0),a(e,t+=2,c.cpr?8:0),o(e,t+=2,0),o(e,t+=4,c.crc),o(e,t+=4,n.length),o(e,t+=4,c.usize),a(e,t+=4,l.bin.sizeUTF8(p)),a(e,t+=2,0),t+=2,w==1&&(t+=2,t+=2,o(e,t+=6,S),t+=4),t+=l.bin.writeUTF8(e,t,p),w==0&&(e.set(n,t),t+=n.length),t},l.crc={table:(function(){for(var e=new Uint32Array(256),t=0;t<256;t++){for(var p=t,c=0;c<8;c++)1&p?p=3988292384^p>>>1:p>>>=1;e[t]=p;}return e})(),update:function(e,t,p,c){for(var w=0;w<c;w++)e=l.crc.table[255&(e^t[p+w])]^e>>>8;return e},crc:function(e,t,p){return 4294967295^l.crc.update(4294967295,e,t,p)}},l.adler=function(e,t,p){for(var c=1,w=0,S=t,o=t+p;S<o;){for(var a=Math.min(S+5552,o);S<a;)w+=c+=e[S++];c%=65521,w%=65521;}return w<<16|c},l.bin={readUshort:function(e,t){return e[t]|e[t+1]<<8},writeUshort:function(e,t,p){e[t]=255&p,e[t+1]=p>>8&255;},readUint:function(e,t){return 16777216*e[t+3]+(e[t+2]<<16|e[t+1]<<8|e[t])},writeUint:function(e,t,p){e[t]=255&p,e[t+1]=p>>8&255,e[t+2]=p>>16&255,e[t+3]=p>>24&255;},readASCII:function(e,t,p){for(var c="",w=0;w<p;w++)c+=String.fromCharCode(e[t+w]);return c},writeASCII:function(e,t,p){for(var c=0;c<p.length;c++)e[t+c]=p.charCodeAt(c);},pad:function(e){return e.length<2?"0"+e:e},readUTF8:function(e,t,p){for(var c,w="",S=0;S<p;S++)w+="%"+l.bin.pad(e[t+S].toString(16));try{c=decodeURIComponent(w);}catch{return l.bin.readASCII(e,t,p)}return c},writeUTF8:function(e,t,p){for(var c=p.length,w=0,S=0;S<c;S++){var o=p.charCodeAt(S);if((4294967168&o)==0)e[t+w]=o,w++;else if((4294965248&o)==0)e[t+w]=192|o>>6,e[t+w+1]=128|o>>0&63,w+=2;else if((4294901760&o)==0)e[t+w]=224|o>>12,e[t+w+1]=128|o>>6&63,e[t+w+2]=128|o>>0&63,w+=3;else {if((4292870144&o)!=0)throw "e";e[t+w]=240|o>>18,e[t+w+1]=128|o>>12&63,e[t+w+2]=128|o>>6&63,e[t+w+3]=128|o>>0&63,w+=4;}}return w},sizeUTF8:function(e){for(var t=e.length,p=0,c=0;c<t;c++){var w=e.charCodeAt(c);if((4294967168&w)==0)p++;else if((4294965248&w)==0)p+=2;else if((4294901760&w)==0)p+=3;else {if((4292870144&w)!=0)throw "e";p+=4;}}return p}},l.F={},l.F.deflateRaw=function(e,t,p,c){var w=[[0,0,0,0,0],[4,4,8,4,0],[4,5,16,8,0],[4,6,16,16,0],[4,10,16,32,0],[8,16,32,32,0],[8,16,128,128,0],[8,32,128,256,0],[32,128,258,1024,1],[32,258,258,4096,1]][c],S=l.F.U,o=l.F._goodIndex;l.F._hash;var a=l.F._putsE,n=0,h=p<<3,v=0,C=e.length;if(c==0){for(;n<C;)a(t,h,n+(s=Math.min(65535,C-n))==C?1:0),h=l.F._copyExact(e,n,s,t,h+8),n+=s;return h>>>3}var M=S.lits,I=S.strt,B=S.prev,k=0,L=0,R=0,g=0,U=0,f=0;for(C>2&&(I[f=l.F._hash(e,0)]=0),n=0;n<C;n++){if(U=f,n+1<C-2){f=l.F._hash(e,n+1);var u=n+1&32767;B[u]=I[f],I[f]=u;}if(v<=n){(k>14e3||L>26697)&&C-n>100&&(v<n&&(M[k]=n-v,k+=2,v=n),h=l.F._writeBlock(n==C-1||v==C?1:0,M,k,g,e,R,n-R,t,h),k=L=g=0,R=n);var _=0;n<C-2&&(_=l.F._bestMatch(e,n,B,U,Math.min(w[2],C-n),w[3]));var s=_>>>16,y=65535&_;if(_!=0){y=65535&_;var b=o(s=_>>>16,S.of0);S.lhst[257+b]++;var A=o(y,S.df0);S.dhst[A]++,g+=S.exb[b]+S.dxb[A],M[k]=s<<23|n-v,M[k+1]=y<<16|b<<8|A,k+=2,v=n+s;}else S.lhst[e[n]]++;L++;}}for(R==n&&e.length!=0||(v<n&&(M[k]=n-v,k+=2,v=n),h=l.F._writeBlock(1,M,k,g,e,R,n-R,t,h),k=0,L=0,k=L=g=0,R=n);(7&h)!=0;)h++;return h>>>3},l.F._bestMatch=function(e,t,p,c,w,S){var o=32767&t,a=p[o],n=o-a+32768&32767;if(a==o||c!=l.F._hash(e,t-n))return 0;for(var h=0,v=0,C=Math.min(32767,t);n<=C&&--S!=0&&a!=o;){if(h==0||e[t+h]==e[t+h-n]){var M=l.F._howLong(e,t,n);if(M>h){if(v=n,(h=M)>=w)break;n+2<M&&(M=n+2);for(var I=0,B=0;B<M-2;B++){var k=t-n+B+32768&32767,L=k-p[k]+32768&32767;L>I&&(I=L,a=k);}}}n+=(o=a)-(a=p[o])+32768&32767;}return h<<16|v},l.F._howLong=function(e,t,p){if(e[t]!=e[t-p]||e[t+1]!=e[t+1-p]||e[t+2]!=e[t+2-p])return 0;var c=t,w=Math.min(e.length,t+258);for(t+=3;t<w&&e[t]==e[t-p];)t++;return t-c},l.F._hash=function(e,t){return (e[t]<<8|e[t+1])+(e[t+2]<<4)&65535},l.saved=0,l.F._writeBlock=function(e,t,p,c,w,S,o,a,n){var h,v,C,M,I,B,k,L,R,g=l.F.U,U=l.F._putsF,f=l.F._putsE;g.lhst[256]++,v=(h=l.F.getTrees())[0],C=h[1],M=h[2],I=h[3],B=h[4],k=h[5],L=h[6],R=h[7];var u=32+((n+3&7)==0?0:8-(n+3&7))+(o<<3),_=c+l.F.contSize(g.fltree,g.lhst)+l.F.contSize(g.fdtree,g.dhst),s=c+l.F.contSize(g.ltree,g.lhst)+l.F.contSize(g.dtree,g.dhst);s+=14+3*k+l.F.contSize(g.itree,g.ihst)+(2*g.ihst[16]+3*g.ihst[17]+7*g.ihst[18]);for(var y=0;y<286;y++)g.lhst[y]=0;for(y=0;y<30;y++)g.dhst[y]=0;for(y=0;y<19;y++)g.ihst[y]=0;var b=u<_&&u<s?0:_<s?1:2;if(U(a,n,e),U(a,n+1,b),n+=3,b==0){for(;(7&n)!=0;)n++;n=l.F._copyExact(w,S,o,a,n);}else {var A,T;if(b==1&&(A=g.fltree,T=g.fdtree),b==2){l.F.makeCodes(g.ltree,v),l.F.revCodes(g.ltree,v),l.F.makeCodes(g.dtree,C),l.F.revCodes(g.dtree,C),l.F.makeCodes(g.itree,M),l.F.revCodes(g.itree,M),A=g.ltree,T=g.dtree,f(a,n,I-257),f(a,n+=5,B-1),f(a,n+=5,k-4),n+=4;for(var m=0;m<k;m++)f(a,n+3*m,g.itree[1+(g.ordr[m]<<1)]);n+=3*k,n=l.F._codeTiny(L,g.itree,a,n),n=l.F._codeTiny(R,g.itree,a,n);}for(var d=S,P=0;P<p;P+=2){for(var x=t[P],O=x>>>23,N=d+(8388607&x);d<N;)n=l.F._writeLit(w[d++],A,a,n);if(O!=0){var D=t[P+1],Q=D>>16,H=D>>8&255,F=255&D;f(a,n=l.F._writeLit(257+H,A,a,n),O-g.of0[H]),n+=g.exb[H],U(a,n=l.F._writeLit(F,T,a,n),Q-g.df0[F]),n+=g.dxb[F],d+=O;}}n=l.F._writeLit(256,A,a,n);}return n},l.F._copyExact=function(e,t,p,c,w){var S=w>>>3;return c[S]=p,c[S+1]=p>>>8,c[S+2]=255-c[S],c[S+3]=255-c[S+1],S+=4,c.set(new Uint8Array(e.buffer,t,p),S),w+(p+4<<3)},l.F.getTrees=function(){for(var e=l.F.U,t=l.F._hufTree(e.lhst,e.ltree,15),p=l.F._hufTree(e.dhst,e.dtree,15),c=[],w=l.F._lenCodes(e.ltree,c),S=[],o=l.F._lenCodes(e.dtree,S),a=0;a<c.length;a+=2)e.ihst[c[a]]++;for(a=0;a<S.length;a+=2)e.ihst[S[a]]++;for(var n=l.F._hufTree(e.ihst,e.itree,7),h=19;h>4&&e.itree[1+(e.ordr[h-1]<<1)]==0;)h--;return [t,p,n,w,o,h,c,S]},l.F.getSecond=function(e){for(var t=[],p=0;p<e.length;p+=2)t.push(e[p+1]);return t},l.F.nonZero=function(e){for(var t="",p=0;p<e.length;p+=2)e[p+1]!=0&&(t+=(p>>1)+",");return t},l.F.contSize=function(e,t){for(var p=0,c=0;c<t.length;c++)p+=t[c]*e[1+(c<<1)];return p},l.F._codeTiny=function(e,t,p,c){for(var w=0;w<e.length;w+=2){var S=e[w],o=e[w+1];c=l.F._writeLit(S,t,p,c);var a=S==16?2:S==17?3:7;S>15&&(l.F._putsE(p,c,o,a),c+=a);}return c},l.F._lenCodes=function(e,t){for(var p=e.length;p!=2&&e[p-1]==0;)p-=2;for(var c=0;c<p;c+=2){var w=e[c+1],S=c+3<p?e[c+3]:-1,o=c+5<p?e[c+5]:-1,a=c==0?-1:e[c-1];if(w==0&&S==w&&o==w){for(var n=c+5;n+2<p&&e[n+2]==w;)n+=2;(h=Math.min(n+1-c>>>1,138))<11?t.push(17,h-3):t.push(18,h-11),c+=2*h-2;}else if(w==a&&S==w&&o==w){for(n=c+5;n+2<p&&e[n+2]==w;)n+=2;var h=Math.min(n+1-c>>>1,6);t.push(16,h-3),c+=2*h-2;}else t.push(w,0);}return p>>>1},l.F._hufTree=function(e,t,p){var c=[],w=e.length,S=t.length,o=0;for(o=0;o<S;o+=2)t[o]=0,t[o+1]=0;for(o=0;o<w;o++)e[o]!=0&&c.push({lit:o,f:e[o]});var a=c.length,n=c.slice(0);if(a==0)return 0;if(a==1){var h=c[0].lit;return n=h==0?1:0,t[1+(h<<1)]=1,t[1+(n<<1)]=1,1}c.sort((function(L,R){return L.f-R.f}));var v=c[0],C=c[1],M=0,I=1,B=2;for(c[0]={lit:-1,f:v.f+C.f,l:v,r:C,d:0};I!=a-1;)v=M!=I&&(B==a||c[M].f<c[B].f)?c[M++]:c[B++],C=M!=I&&(B==a||c[M].f<c[B].f)?c[M++]:c[B++],c[I++]={lit:-1,f:v.f+C.f,l:v,r:C};var k=l.F.setDepth(c[I-1],0);for(k>p&&(l.F.restrictDepth(n,p,k),k=p),o=0;o<a;o++)t[1+(n[o].lit<<1)]=n[o].d;return k},l.F.setDepth=function(e,t){return e.lit!=-1?(e.d=t,t):Math.max(l.F.setDepth(e.l,t+1),l.F.setDepth(e.r,t+1))},l.F.restrictDepth=function(e,t,p){var c=0,w=1<<p-t,S=0;for(e.sort((function(a,n){return n.d==a.d?a.f-n.f:n.d-a.d})),c=0;c<e.length&&e[c].d>t;c++){var o=e[c].d;e[c].d=t,S+=w-(1<<p-o);}for(S>>>=p-t;S>0;)(o=e[c].d)<t?(e[c].d++,S-=1<<t-o-1):c++;for(;c>=0;c--)e[c].d==t&&S<0&&(e[c].d--,S++);S!=0&&console.log("debt left");},l.F._goodIndex=function(e,t){var p=0;return t[16|p]<=e&&(p|=16),t[8|p]<=e&&(p|=8),t[4|p]<=e&&(p|=4),t[2|p]<=e&&(p|=2),t[1|p]<=e&&(p|=1),p},l.F._writeLit=function(e,t,p,c){return l.F._putsF(p,c,t[e<<1]),c+t[1+(e<<1)]},l.F.inflate=function(e,t){var p=Uint8Array;if(e[0]==3&&e[1]==0)return t||new p(0);var c=l.F,w=c._bitsF,S=c._bitsE,o=c._decodeTiny,a=c.makeCodes,n=c.codes2map,h=c._get17,v=c.U,C=t==null;C&&(t=new p(e.length>>>2<<3));for(var M,I,B=0,k=0,L=0,R=0,g=0,U=0,f=0,u=0,_=0;B==0;)if(B=w(e,_,1),k=w(e,_+1,2),_+=3,k!=0){if(C&&(t=l.F._check(t,u+(1<<17))),k==1&&(M=v.flmap,I=v.fdmap,U=511,f=31),k==2){L=S(e,_,5)+257,R=S(e,_+5,5)+1,g=S(e,_+10,4)+4,_+=14;for(var s=0;s<38;s+=2)v.itree[s]=0,v.itree[s+1]=0;var y=1;for(s=0;s<g;s++){var b=S(e,_+3*s,3);v.itree[1+(v.ordr[s]<<1)]=b,b>y&&(y=b);}_+=3*g,a(v.itree,y),n(v.itree,y,v.imap),M=v.lmap,I=v.dmap,_=o(v.imap,(1<<y)-1,L+R,e,_,v.ttree);var A=c._copyOut(v.ttree,0,L,v.ltree);U=(1<<A)-1;var T=c._copyOut(v.ttree,L,R,v.dtree);f=(1<<T)-1,a(v.ltree,A),n(v.ltree,A,M),a(v.dtree,T),n(v.dtree,T,I);}for(;;){var m=M[h(e,_)&U];_+=15&m;var d=m>>>4;if(!(d>>>8))t[u++]=d;else {if(d==256)break;var P=u+d-254;if(d>264){var x=v.ldef[d-257];P=u+(x>>>3)+S(e,_,7&x),_+=7&x;}var O=I[h(e,_)&f];_+=15&O;var N=O>>>4,D=v.ddef[N],Q=(D>>>4)+w(e,_,15&D);for(_+=15&D,C&&(t=l.F._check(t,u+(1<<17)));u<P;)t[u]=t[u++-Q],t[u]=t[u++-Q],t[u]=t[u++-Q],t[u]=t[u++-Q];u=P;}}}else {(7&_)!=0&&(_+=8-(7&_));var H=4+(_>>>3),F=e[H-4]|e[H-3]<<8;C&&(t=l.F._check(t,u+F)),t.set(new p(e.buffer,e.byteOffset+H,F),u),_=H+F<<3,u+=F;}return t.length==u?t:t.slice(0,u)},l.F._check=function(e,t){var p=e.length;if(t<=p)return e;var c=new Uint8Array(Math.max(p<<1,t));return c.set(e,0),c},l.F._decodeTiny=function(e,t,p,c,w,S){for(var o=l.F._bitsE,a=l.F._get17,n=0;n<p;){var h=e[a(c,w)&t];w+=15&h;var v=h>>>4;if(v<=15)S[n]=v,n++;else {var C=0,M=0;v==16?(M=3+o(c,w,2),w+=2,C=S[n-1]):v==17?(M=3+o(c,w,3),w+=3):v==18&&(M=11+o(c,w,7),w+=7);for(var I=n+M;n<I;)S[n]=C,n++;}}return w},l.F._copyOut=function(e,t,p,c){for(var w=0,S=0,o=c.length>>>1;S<p;){var a=e[S+t];c[S<<1]=0,c[1+(S<<1)]=a,a>w&&(w=a),S++;}for(;S<o;)c[S<<1]=0,c[1+(S<<1)]=0,S++;return w},l.F.makeCodes=function(e,t){for(var p,c,w,S,o=l.F.U,a=e.length,n=o.bl_count,h=0;h<=t;h++)n[h]=0;for(h=1;h<a;h+=2)n[e[h]]++;var v=o.next_code;for(p=0,n[0]=0,c=1;c<=t;c++)p=p+n[c-1]<<1,v[c]=p;for(w=0;w<a;w+=2)(S=e[w+1])!=0&&(e[w]=v[S],v[S]++);},l.F.codes2map=function(e,t,p){for(var c=e.length,w=l.F.U.rev15,S=0;S<c;S+=2)if(e[S+1]!=0)for(var o=S>>1,a=e[S+1],n=o<<4|a,h=t-a,v=e[S]<<h,C=v+(1<<h);v!=C;)p[w[v]>>>15-t]=n,v++;},l.F.revCodes=function(e,t){for(var p=l.F.U.rev15,c=15-t,w=0;w<e.length;w+=2){var S=e[w]<<t-e[w+1];e[w]=p[S]>>>c;}},l.F._putsE=function(e,t,p){p<<=7&t;var c=t>>>3;e[c]|=p,e[c+1]|=p>>>8;},l.F._putsF=function(e,t,p){p<<=7&t;var c=t>>>3;e[c]|=p,e[c+1]|=p>>>8,e[c+2]|=p>>>16;},l.F._bitsE=function(e,t,p){return (e[t>>>3]|e[1+(t>>>3)]<<8)>>>(7&t)&(1<<p)-1},l.F._bitsF=function(e,t,p){return (e[t>>>3]|e[1+(t>>>3)]<<8|e[2+(t>>>3)]<<16)>>>(7&t)&(1<<p)-1},l.F._get17=function(e,t){return (e[t>>>3]|e[1+(t>>>3)]<<8|e[2+(t>>>3)]<<16)>>>(7&t)},l.F._get25=function(e,t){return (e[t>>>3]|e[1+(t>>>3)]<<8|e[2+(t>>>3)]<<16|e[3+(t>>>3)]<<24)>>>(7&t)},l.F.U=(r=Uint16Array,E=Uint32Array,{next_code:new r(16),bl_count:new r(16),ordr:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],of0:[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,999,999,999],exb:[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0],ldef:new r(32),df0:[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,65535,65535],dxb:[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0],ddef:new E(32),flmap:new r(512),fltree:[],fdmap:new r(32),fdtree:[],lmap:new r(32768),ltree:[],ttree:[],dmap:new r(32768),dtree:[],imap:new r(512),itree:[],rev15:new r(32768),lhst:new E(286),dhst:new E(30),ihst:new E(19),lits:new E(15e3),strt:new r(65536),prev:new r(32768)}),(function(){for(var e=l.F.U,t=0;t<32768;t++){var p=t;p=(4278255360&(p=(4042322160&(p=(3435973836&(p=(2863311530&p)>>>1|(1431655765&p)<<1))>>>2|(858993459&p)<<2))>>>4|(252645135&p)<<4))>>>8|(16711935&p)<<8,e.rev15[t]=(p>>>16|p<<16)>>>17;}function c(w,S,o){for(;S--!=0;)w.push(0,o);}for(t=0;t<32;t++)e.ldef[t]=e.of0[t]<<3|e.exb[t],e.ddef[t]=e.df0[t]<<4|e.dxb[t];c(e.fltree,144,8),c(e.fltree,112,9),c(e.fltree,24,7),c(e.fltree,8,8),l.F.makeCodes(e.fltree,9),l.F.codes2map(e.fltree,9,e.flmap),l.F.revCodes(e.fltree,9),c(e.fdtree,32,5),l.F.makeCodes(e.fdtree,5),l.F.codes2map(e.fdtree,5,e.fdmap),l.F.revCodes(e.fdtree,5),c(e.itree,19,0),c(e.ltree,286,0),c(e.dtree,30,0),c(e.ttree,320,0);})();})();var Cn=Tn({__proto__:null,default:$e},[$e]),pe=(function(){var i={nextZero(o,a){for(;o[a]!=0;)a++;return a},readUshort:(o,a)=>o[a]<<8|o[a+1],writeUshort(o,a,n){o[a]=n>>8&255,o[a+1]=255&n;},readUint:(o,a)=>16777216*o[a]+(o[a+1]<<16|o[a+2]<<8|o[a+3]),writeUint(o,a,n){o[a]=n>>24&255,o[a+1]=n>>16&255,o[a+2]=n>>8&255,o[a+3]=255&n;},readASCII(o,a,n){let h="";for(let v=0;v<n;v++)h+=String.fromCharCode(o[a+v]);return h},writeASCII(o,a,n){for(let h=0;h<n.length;h++)o[a+h]=n.charCodeAt(h);},readBytes(o,a,n){let h=[];for(let v=0;v<n;v++)h.push(o[a+v]);return h},pad:o=>o.length<2?`0${o}`:o,readUTF8(o,a,n){let h,v="";for(let C=0;C<n;C++)v+=`%${i.pad(o[a+C].toString(16))}`;try{h=decodeURIComponent(v);}catch{return i.readASCII(o,a,n)}return h}};function r(o,a,n,h){let v=a*n,C=t(h),M=Math.ceil(a*C/8),I=new Uint8Array(4*v),B=new Uint32Array(I.buffer),{ctype:k}=h,{depth:L}=h,R=i.readUshort;if(k==6){let x=v<<2;if(L==8)for(var g=0;g<x;g+=4)I[g]=o[g],I[g+1]=o[g+1],I[g+2]=o[g+2],I[g+3]=o[g+3];if(L==16)for(g=0;g<x;g++)I[g]=o[g<<1];}else if(k==2){let x=h.tabs.tRNS;if(x==null){if(L==8)for(g=0;g<v;g++){var U=3*g;B[g]=255<<24|o[U+2]<<16|o[U+1]<<8|o[U];}if(L==16)for(g=0;g<v;g++)U=6*g,B[g]=255<<24|o[U+4]<<16|o[U+2]<<8|o[U];}else {var f=x[0];let O=x[1],N=x[2];if(L==8)for(g=0;g<v;g++){var u=g<<2;U=3*g,B[g]=255<<24|o[U+2]<<16|o[U+1]<<8|o[U],o[U]==f&&o[U+1]==O&&o[U+2]==N&&(I[u+3]=0);}if(L==16)for(g=0;g<v;g++)u=g<<2,U=6*g,B[g]=255<<24|o[U+4]<<16|o[U+2]<<8|o[U],R(o,U)==f&&R(o,U+2)==O&&R(o,U+4)==N&&(I[u+3]=0);}}else if(k==3){let x=h.tabs.PLTE,O=h.tabs.tRNS,N=O?O.length:0;if(L==1)for(var _=0;_<n;_++){var s=_*M,y=_*a;for(g=0;g<a;g++){u=y+g<<2;var b=3*(A=o[s+(g>>3)]>>7-((7&g)<<0)&1);I[u]=x[b],I[u+1]=x[b+1],I[u+2]=x[b+2],I[u+3]=A<N?O[A]:255;}}if(L==2)for(_=0;_<n;_++)for(s=_*M,y=_*a,g=0;g<a;g++)u=y+g<<2,b=3*(A=o[s+(g>>2)]>>6-((3&g)<<1)&3),I[u]=x[b],I[u+1]=x[b+1],I[u+2]=x[b+2],I[u+3]=A<N?O[A]:255;if(L==4)for(_=0;_<n;_++)for(s=_*M,y=_*a,g=0;g<a;g++)u=y+g<<2,b=3*(A=o[s+(g>>1)]>>4-((1&g)<<2)&15),I[u]=x[b],I[u+1]=x[b+1],I[u+2]=x[b+2],I[u+3]=A<N?O[A]:255;if(L==8)for(g=0;g<v;g++){var A;u=g<<2,b=3*(A=o[g]),I[u]=x[b],I[u+1]=x[b+1],I[u+2]=x[b+2],I[u+3]=A<N?O[A]:255;}}else if(k==4){if(L==8)for(g=0;g<v;g++){u=g<<2;var T=o[m=g<<1];I[u]=T,I[u+1]=T,I[u+2]=T,I[u+3]=o[m+1];}if(L==16)for(g=0;g<v;g++){var m;u=g<<2,T=o[m=g<<2],I[u]=T,I[u+1]=T,I[u+2]=T,I[u+3]=o[m+2];}}else if(k==0)for(f=h.tabs.tRNS?h.tabs.tRNS:-1,_=0;_<n;_++){let x=_*M,O=_*a;if(L==1)for(var d=0;d<a;d++){var P=(T=255*(o[x+(d>>>3)]>>>7-(7&d)&1))==255*f?0:255;B[O+d]=P<<24|T<<16|T<<8|T;}else if(L==2)for(d=0;d<a;d++)P=(T=85*(o[x+(d>>>2)]>>>6-((3&d)<<1)&3))==85*f?0:255,B[O+d]=P<<24|T<<16|T<<8|T;else if(L==4)for(d=0;d<a;d++)P=(T=17*(o[x+(d>>>1)]>>>4-((1&d)<<2)&15))==17*f?0:255,B[O+d]=P<<24|T<<16|T<<8|T;else if(L==8)for(d=0;d<a;d++)P=(T=o[x+d])==f?0:255,B[O+d]=P<<24|T<<16|T<<8|T;else if(L==16)for(d=0;d<a;d++)T=o[x+(d<<1)],P=R(o,x+(d<<1))==f?0:255,B[O+d]=P<<24|T<<16|T<<8|T;}return I}function E(o,a,n,h){let v=t(o),C=Math.ceil(n*v/8),M=new Uint8Array((C+1+o.interlace)*h);return a=o.tabs.CgBI?e(a,M):l(a,M),o.interlace==0?a=p(a,o,0,n,h):o.interlace==1&&(a=(function(B,k){let L=k.width,R=k.height,g=t(k),U=g>>3,f=Math.ceil(L*g/8),u=new Uint8Array(R*f),_=0,s=[0,0,4,0,2,0,1],y=[0,4,0,2,0,1,0],b=[8,8,8,4,4,2,2],A=[8,8,4,4,2,2,1],T=0;for(;T<7;){let d=b[T],P=A[T],x=0,O=0,N=s[T];for(;N<R;)N+=d,O++;let D=y[T];for(;D<L;)D+=P,x++;let Q=Math.ceil(x*g/8);p(B,k,_,x,O);let H=0,F=s[T];for(;F<R;){let $=y[T],K=_+H*Q<<3;for(;$<L;){var m;if(g==1&&(m=(m=B[K>>3])>>7-(7&K)&1,u[F*f+($>>3)]|=m<<7-((7&$)<<0)),g==2&&(m=(m=B[K>>3])>>6-(7&K)&3,u[F*f+($>>2)]|=m<<6-((3&$)<<1)),g==4&&(m=(m=B[K>>3])>>4-(7&K)&15,u[F*f+($>>1)]|=m<<4-((1&$)<<2)),g>=8){let V=F*f+$*U;for(let z=0;z<U;z++)u[V+z]=B[(K>>3)+z];}K+=g,$+=P;}H++,F+=d;}x*O!=0&&(_+=O*(1+Q)),T+=1;}return u})(a,o)),a}function l(o,a){return e(new Uint8Array(o.buffer,2,o.length-6),a)}var e=(function(){let o={H:{}};return o.H.N=function(a,n){let h=Uint8Array,v,C,M=0,I=0,B=0,k=0,L=0,R=0,g=0,U=0,f=0;if(a[0]==3&&a[1]==0)return n||new h(0);let u=o.H,_=u.b,s=u.e,y=u.R,b=u.n,A=u.A,T=u.Z,m=u.m,d=n==null;for(d&&(n=new h(a.length>>>2<<5));M==0;)if(M=_(a,f,1),I=_(a,f+1,2),f+=3,I!=0){if(d&&(n=o.H.W(n,U+(1<<17))),I==1&&(v=m.J,C=m.h,R=511,g=31),I==2){B=s(a,f,5)+257,k=s(a,f+5,5)+1,L=s(a,f+10,4)+4,f+=14;let x=1;for(var P=0;P<38;P+=2)m.Q[P]=0,m.Q[P+1]=0;for(P=0;P<L;P++){let D=s(a,f+3*P,3);m.Q[1+(m.X[P]<<1)]=D,D>x&&(x=D);}f+=3*L,b(m.Q,x),A(m.Q,x,m.u),v=m.w,C=m.d,f=y(m.u,(1<<x)-1,B+k,a,f,m.v);let O=u.V(m.v,0,B,m.C);R=(1<<O)-1;let N=u.V(m.v,B,k,m.D);g=(1<<N)-1,b(m.C,O),A(m.C,O,v),b(m.D,N),A(m.D,N,C);}for(;;){let x=v[T(a,f)&R];f+=15&x;let O=x>>>4;if(!(O>>>8))n[U++]=O;else {if(O==256)break;{let N=U+O-254;if(O>264){let $=m.q[O-257];N=U+($>>>3)+s(a,f,7&$),f+=7&$;}let D=C[T(a,f)&g];f+=15&D;let Q=D>>>4,H=m.c[Q],F=(H>>>4)+_(a,f,15&H);for(f+=15&H;U<N;)n[U]=n[U++-F],n[U]=n[U++-F],n[U]=n[U++-F],n[U]=n[U++-F];U=N;}}}}else {(7&f)!=0&&(f+=8-(7&f));let x=4+(f>>>3),O=a[x-4]|a[x-3]<<8;d&&(n=o.H.W(n,U+O)),n.set(new h(a.buffer,a.byteOffset+x,O),U),f=x+O<<3,U+=O;}return n.length==U?n:n.slice(0,U)},o.H.W=function(a,n){let h=a.length;if(n<=h)return a;let v=new Uint8Array(h<<1);return v.set(a,0),v},o.H.R=function(a,n,h,v,C,M){let I=o.H.e,B=o.H.Z,k=0;for(;k<h;){let L=a[B(v,C)&n];C+=15&L;let R=L>>>4;if(R<=15)M[k]=R,k++;else {let g=0,U=0;R==16?(U=3+I(v,C,2),C+=2,g=M[k-1]):R==17?(U=3+I(v,C,3),C+=3):R==18&&(U=11+I(v,C,7),C+=7);let f=k+U;for(;k<f;)M[k]=g,k++;}}return C},o.H.V=function(a,n,h,v){let C=0,M=0,I=v.length>>>1;for(;M<h;){let B=a[M+n];v[M<<1]=0,v[1+(M<<1)]=B,B>C&&(C=B),M++;}for(;M<I;)v[M<<1]=0,v[1+(M<<1)]=0,M++;return C},o.H.n=function(a,n){let h=o.H.m,v=a.length,C,M,I,B,k=h.j;for(var L=0;L<=n;L++)k[L]=0;for(L=1;L<v;L+=2)k[a[L]]++;let R=h.K;for(C=0,k[0]=0,M=1;M<=n;M++)C=C+k[M-1]<<1,R[M]=C;for(I=0;I<v;I+=2)B=a[I+1],B!=0&&(a[I]=R[B],R[B]++);},o.H.A=function(a,n,h){let v=a.length,C=o.H.m.r;for(let M=0;M<v;M+=2)if(a[M+1]!=0){let I=M>>1,B=a[M+1],k=I<<4|B,L=n-B,R=a[M]<<L,g=R+(1<<L);for(;R!=g;)h[C[R]>>>15-n]=k,R++;}},o.H.l=function(a,n){let h=o.H.m.r,v=15-n;for(let C=0;C<a.length;C+=2){let M=a[C]<<n-a[C+1];a[C]=h[M]>>>v;}},o.H.M=function(a,n,h){h<<=7&n;let v=n>>>3;a[v]|=h,a[v+1]|=h>>>8;},o.H.I=function(a,n,h){h<<=7&n;let v=n>>>3;a[v]|=h,a[v+1]|=h>>>8,a[v+2]|=h>>>16;},o.H.e=function(a,n,h){return (a[n>>>3]|a[1+(n>>>3)]<<8)>>>(7&n)&(1<<h)-1},o.H.b=function(a,n,h){return (a[n>>>3]|a[1+(n>>>3)]<<8|a[2+(n>>>3)]<<16)>>>(7&n)&(1<<h)-1},o.H.Z=function(a,n){return (a[n>>>3]|a[1+(n>>>3)]<<8|a[2+(n>>>3)]<<16)>>>(7&n)},o.H.i=function(a,n){return (a[n>>>3]|a[1+(n>>>3)]<<8|a[2+(n>>>3)]<<16|a[3+(n>>>3)]<<24)>>>(7&n)},o.H.m=(function(){let a=Uint16Array,n=Uint32Array;return {K:new a(16),j:new a(16),X:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],S:[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,999,999,999],T:[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0],q:new a(32),p:[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,65535,65535],z:[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0],c:new n(32),J:new a(512),_:[],h:new a(32),$:[],w:new a(32768),C:[],v:[],d:new a(32768),D:[],u:new a(512),Q:[],r:new a(32768),s:new n(286),Y:new n(30),a:new n(19),t:new n(15e3),k:new a(65536),g:new a(32768)}})(),(function(){let a=o.H.m;for(var n=0;n<32768;n++){let v=n;v=(2863311530&v)>>>1|(1431655765&v)<<1,v=(3435973836&v)>>>2|(858993459&v)<<2,v=(4042322160&v)>>>4|(252645135&v)<<4,v=(4278255360&v)>>>8|(16711935&v)<<8,a.r[n]=(v>>>16|v<<16)>>>17;}function h(v,C,M){for(;C--!=0;)v.push(0,M);}for(n=0;n<32;n++)a.q[n]=a.S[n]<<3|a.T[n],a.c[n]=a.p[n]<<4|a.z[n];h(a._,144,8),h(a._,112,9),h(a._,24,7),h(a._,8,8),o.H.n(a._,9),o.H.A(a._,9,a.J),o.H.l(a._,9),h(a.$,32,5),o.H.n(a.$,5),o.H.A(a.$,5,a.h),o.H.l(a.$,5),h(a.Q,19,0),h(a.C,286,0),h(a.D,30,0),h(a.v,320,0);})(),o.H.N})();function t(o){return [1,null,3,1,2,null,4][o.ctype]*o.depth}function p(o,a,n,h,v){let C=t(a),M=Math.ceil(h*C/8),I,B;C=Math.ceil(C/8);let k=o[n],L=0;if(k>1&&(o[n]=[0,0,1][k-2]),k==3)for(L=C;L<M;L++)o[L+1]=o[L+1]+(o[L+1-C]>>>1)&255;for(let R=0;R<v;R++)if(I=n+R*M,B=I+R+1,k=o[B-1],L=0,k==0)for(;L<M;L++)o[I+L]=o[B+L];else if(k==1){for(;L<C;L++)o[I+L]=o[B+L];for(;L<M;L++)o[I+L]=o[B+L]+o[I+L-C];}else if(k==2)for(;L<M;L++)o[I+L]=o[B+L]+o[I+L-M];else if(k==3){for(;L<C;L++)o[I+L]=o[B+L]+(o[I+L-M]>>>1);for(;L<M;L++)o[I+L]=o[B+L]+(o[I+L-M]+o[I+L-C]>>>1);}else {for(;L<C;L++)o[I+L]=o[B+L]+c(0,o[I+L-M],0);for(;L<M;L++)o[I+L]=o[B+L]+c(o[I+L-C],o[I+L-M],o[I+L-C-M]);}return o}function c(o,a,n){let h=o+a-n,v=h-o,C=h-a,M=h-n;return v*v<=C*C&&v*v<=M*M?o:C*C<=M*M?a:n}function w(o,a,n){n.width=i.readUint(o,a),a+=4,n.height=i.readUint(o,a),a+=4,n.depth=o[a],a++,n.ctype=o[a],a++,n.compress=o[a],a++,n.filter=o[a],a++,n.interlace=o[a],a++;}function S(o,a,n,h,v,C,M,I,B){let k=Math.min(a,v),L=Math.min(n,C),R=0,g=0;for(let T=0;T<L;T++)for(let m=0;m<k;m++)if(M>=0&&I>=0?(R=T*a+m<<2,g=(I+T)*v+M+m<<2):(R=(-I+T)*a-M+m<<2,g=T*v+m<<2),B==0)h[g]=o[R],h[g+1]=o[R+1],h[g+2]=o[R+2],h[g+3]=o[R+3];else if(B==1){var U=o[R+3]*.00392156862745098,f=o[R]*U,u=o[R+1]*U,_=o[R+2]*U,s=h[g+3]*(1/255),y=h[g]*s,b=h[g+1]*s,A=h[g+2]*s;let d=1-U,P=U+s*d,x=P==0?0:1/P;h[g+3]=255*P,h[g+0]=(f+y*d)*x,h[g+1]=(u+b*d)*x,h[g+2]=(_+A*d)*x;}else if(B==2)U=o[R+3],f=o[R],u=o[R+1],_=o[R+2],s=h[g+3],y=h[g],b=h[g+1],A=h[g+2],U==s&&f==y&&u==b&&_==A?(h[g]=0,h[g+1]=0,h[g+2]=0,h[g+3]=0):(h[g]=f,h[g+1]=u,h[g+2]=_,h[g+3]=U);else if(B==3){if(U=o[R+3],f=o[R],u=o[R+1],_=o[R+2],s=h[g+3],y=h[g],b=h[g+1],A=h[g+2],U==s&&f==y&&u==b&&_==A)continue;if(U<220&&s>20)return false}return true}return {decode:function(a){let n=new Uint8Array(a),h=8,v=i,C=v.readUshort,M=v.readUint,I={tabs:{},frames:[]},B=new Uint8Array(n.length),k,L=0,R=0,g=[137,80,78,71,13,10,26,10];for(var U=0;U<8;U++)if(n[U]!=g[U])throw "The input is not a PNG file!";for(;h<n.length;){let T=v.readUint(n,h);h+=4;let m=v.readASCII(n,h,4);if(h+=4,m=="IHDR")w(n,h,I);else if(m=="iCCP"){for(var f=h;n[f]!=0;)f++;v.readASCII(n,h,f-h),n[f+1];let d=n.slice(f+2,h+T),P=null;try{P=l(d);}catch{P=e(d);}I.tabs[m]=P;}else if(m=="CgBI")I.tabs[m]=n.slice(h,h+4);else if(m=="IDAT"){for(U=0;U<T;U++)B[L+U]=n[h+U];L+=T;}else if(m=="acTL")I.tabs[m]={num_frames:M(n,h),num_plays:M(n,h+4)},k=new Uint8Array(n.length);else if(m=="fcTL"){R!=0&&((A=I.frames[I.frames.length-1]).data=E(I,k.slice(0,R),A.rect.width,A.rect.height),R=0);let d={x:M(n,h+12),y:M(n,h+16),width:M(n,h+4),height:M(n,h+8)},P=C(n,h+22);P=C(n,h+20)/(P==0?100:P);let x={rect:d,delay:Math.round(1e3*P),dispose:n[h+24],blend:n[h+25]};I.frames.push(x);}else if(m=="fdAT"){for(U=0;U<T-4;U++)k[R+U]=n[h+U+4];R+=T-4;}else if(m=="pHYs")I.tabs[m]=[v.readUint(n,h),v.readUint(n,h+4),n[h+8]];else if(m=="cHRM")for(I.tabs[m]=[],U=0;U<8;U++)I.tabs[m].push(v.readUint(n,h+4*U));else if(m=="tEXt"||m=="zTXt"){I.tabs[m]==null&&(I.tabs[m]={});var u=v.nextZero(n,h),_=v.readASCII(n,h,u-h),s=h+T-u-1;if(m=="tEXt")b=v.readASCII(n,u+1,s);else {var y=l(n.slice(u+2,u+2+s));b=v.readUTF8(y,0,y.length);}I.tabs[m][_]=b;}else if(m=="iTXt"){I.tabs[m]==null&&(I.tabs[m]={}),u=0,f=h,u=v.nextZero(n,f),_=v.readASCII(n,f,u-f);let d=n[f=u+1];var b;n[f+1],f+=2,u=v.nextZero(n,f),v.readASCII(n,f,u-f),f=u+1,u=v.nextZero(n,f),v.readUTF8(n,f,u-f),s=T-((f=u+1)-h),d==0?b=v.readUTF8(n,f,s):(y=l(n.slice(f,f+s)),b=v.readUTF8(y,0,y.length)),I.tabs[m][_]=b;}else if(m=="PLTE")I.tabs[m]=v.readBytes(n,h,T);else if(m=="hIST"){let d=I.tabs.PLTE.length/3;for(I.tabs[m]=[],U=0;U<d;U++)I.tabs[m].push(C(n,h+2*U));}else if(m=="tRNS")I.ctype==3?I.tabs[m]=v.readBytes(n,h,T):I.ctype==0?I.tabs[m]=C(n,h):I.ctype==2&&(I.tabs[m]=[C(n,h),C(n,h+2),C(n,h+4)]);else if(m=="gAMA")I.tabs[m]=v.readUint(n,h)/1e5;else if(m=="sRGB")I.tabs[m]=n[h];else if(m=="bKGD")I.ctype==0||I.ctype==4?I.tabs[m]=[C(n,h)]:I.ctype==2||I.ctype==6?I.tabs[m]=[C(n,h),C(n,h+2),C(n,h+4)]:I.ctype==3&&(I.tabs[m]=n[h]);else if(m=="IEND")break;h+=T,v.readUint(n,h),h+=4;}var A;return R!=0&&((A=I.frames[I.frames.length-1]).data=E(I,k.slice(0,R),A.rect.width,A.rect.height)),I.data=E(I,B,I.width,I.height),delete I.compress,delete I.interlace,delete I.filter,I},toRGBA8:function(a){let n=a.width,h=a.height;if(a.tabs.acTL==null)return [r(a.data,n,h,a).buffer];let v=[];a.frames[0].data==null&&(a.frames[0].data=a.data);let C=n*h*4,M=new Uint8Array(C),I=new Uint8Array(C),B=new Uint8Array(C);for(let L=0;L<a.frames.length;L++){let R=a.frames[L],g=R.rect.x,U=R.rect.y,f=R.rect.width,u=R.rect.height,_=r(R.data,f,u,a);if(L!=0)for(var k=0;k<C;k++)B[k]=M[k];if(R.blend==0?S(_,f,u,M,n,h,g,U,0):R.blend==1&&S(_,f,u,M,n,h,g,U,1),v.push(M.buffer.slice(0)),R.dispose!=0){if(R.dispose==1)S(I,f,u,M,n,h,g,U,0);else if(R.dispose==2)for(k=0;k<C;k++)M[k]=B[k];}}return v},_paeth:c,_copyTile:S,_bin:i}})();(function(){let{_copyTile:i}=pe,{_bin:r}=pe,E=pe._paeth;var l={table:(function(){let f=new Uint32Array(256);for(let u=0;u<256;u++){let _=u;for(let s=0;s<8;s++)1&_?_=3988292384^_>>>1:_>>>=1;f[u]=_;}return f})(),update(f,u,_,s){for(let y=0;y<s;y++)f=l.table[255&(f^u[_+y])]^f>>>8;return f},crc:(f,u,_)=>4294967295^l.update(4294967295,f,u,_)};function e(f,u,_,s){u[_]+=f[0]*s>>4,u[_+1]+=f[1]*s>>4,u[_+2]+=f[2]*s>>4,u[_+3]+=f[3]*s>>4;}function t(f){return Math.max(0,Math.min(255,f))}function p(f,u){let _=f[0]-u[0],s=f[1]-u[1],y=f[2]-u[2],b=f[3]-u[3];return _*_+s*s+y*y+b*b}function c(f,u,_,s,y,b,A){A==null&&(A=1);let T=s.length,m=[];for(var d=0;d<T;d++){let F=s[d];m.push([F>>>0&255,F>>>8&255,F>>>16&255,F>>>24&255]);}for(d=0;d<T;d++){let F=4294967295;for(var P=0,x=0;x<T;x++){var O=p(m[d],m[x]);x!=d&&O<F&&(F=O,P=x);}}let N=new Uint32Array(y.buffer),D=new Int16Array(u*_*4),Q=[0,8,2,10,12,4,14,6,3,11,1,9,15,7,13,5];for(d=0;d<Q.length;d++)Q[d]=255*((Q[d]+.5)/16-.5);for(let F=0;F<_;F++)for(let $=0;$<u;$++){var H;d=4*(F*u+$),A!=2?H=[t(f[d]+D[d]),t(f[d+1]+D[d+1]),t(f[d+2]+D[d+2]),t(f[d+3]+D[d+3])]:(O=Q[4*(3&F)+(3&$)],H=[t(f[d]+O),t(f[d+1]+O),t(f[d+2]+O),t(f[d+3]+O)]),P=0;let K=16777215;for(x=0;x<T;x++){let q=p(H,m[x]);q<K&&(K=q,P=x);}let V=m[P],z=[H[0]-V[0],H[1]-V[1],H[2]-V[2],H[3]-V[3]];A==1&&($!=u-1&&e(z,D,d+4,7),F!=_-1&&($!=0&&e(z,D,d+4*u-4,3),e(z,D,d+4*u,5),$!=u-1&&e(z,D,d+4*u+4,1))),b[d>>2]=P,N[d>>2]=s[P];}}function w(f,u,_,s,y){y==null&&(y={});let{crc:b}=l,A=r.writeUint,T=r.writeUshort,m=r.writeASCII,d=8,P=f.frames.length>1,x,O=false,N=33+(P?20:0);if(y.sRGB!=null&&(N+=13),y.pHYs!=null&&(N+=21),y.iCCP!=null&&(x=pako.deflate(y.iCCP),N+=21+x.length+4),f.ctype==3){for(var D=f.plte.length,Q=0;Q<D;Q++)f.plte[Q]>>>24!=255&&(O=true);N+=8+3*D+4+(O?8+1*D+4:0);}for(var H=0;H<f.frames.length;H++)P&&(N+=38),N+=(V=f.frames[H]).cimg.length+12,H!=0&&(N+=4);N+=12;let F=new Uint8Array(N),$=[137,80,78,71,13,10,26,10];for(Q=0;Q<8;Q++)F[Q]=$[Q];if(A(F,d,13),d+=4,m(F,d,"IHDR"),d+=4,A(F,d,u),d+=4,A(F,d,_),d+=4,F[d]=f.depth,d++,F[d]=f.ctype,d++,F[d]=0,d++,F[d]=0,d++,F[d]=0,d++,A(F,d,b(F,d-17,17)),d+=4,y.sRGB!=null&&(A(F,d,1),d+=4,m(F,d,"sRGB"),d+=4,F[d]=y.sRGB,d++,A(F,d,b(F,d-5,5)),d+=4),y.iCCP!=null){let z=13+x.length;A(F,d,z),d+=4,m(F,d,"iCCP"),d+=4,m(F,d,"ICC profile"),d+=11,d+=2,F.set(x,d),d+=x.length,A(F,d,b(F,d-(z+4),z+4)),d+=4;}if(y.pHYs!=null&&(A(F,d,9),d+=4,m(F,d,"pHYs"),d+=4,A(F,d,y.pHYs[0]),d+=4,A(F,d,y.pHYs[1]),d+=4,F[d]=y.pHYs[2],d++,A(F,d,b(F,d-13,13)),d+=4),P&&(A(F,d,8),d+=4,m(F,d,"acTL"),d+=4,A(F,d,f.frames.length),d+=4,A(F,d,y.loop!=null?y.loop:0),d+=4,A(F,d,b(F,d-12,12)),d+=4),f.ctype==3){for(A(F,d,3*(D=f.plte.length)),d+=4,m(F,d,"PLTE"),d+=4,Q=0;Q<D;Q++){let z=3*Q,q=f.plte[Q],G=255&q,W=q>>>8&255,ie=q>>>16&255;F[d+z+0]=G,F[d+z+1]=W,F[d+z+2]=ie;}if(d+=3*D,A(F,d,b(F,d-3*D-4,3*D+4)),d+=4,O){for(A(F,d,D),d+=4,m(F,d,"tRNS"),d+=4,Q=0;Q<D;Q++)F[d+Q]=f.plte[Q]>>>24&255;d+=D,A(F,d,b(F,d-D-4,D+4)),d+=4;}}let K=0;for(H=0;H<f.frames.length;H++){var V=f.frames[H];P&&(A(F,d,26),d+=4,m(F,d,"fcTL"),d+=4,A(F,d,K++),d+=4,A(F,d,V.rect.width),d+=4,A(F,d,V.rect.height),d+=4,A(F,d,V.rect.x),d+=4,A(F,d,V.rect.y),d+=4,T(F,d,s[H]),d+=2,T(F,d,1e3),d+=2,F[d]=V.dispose,d++,F[d]=V.blend,d++,A(F,d,b(F,d-30,30)),d+=4);let z=V.cimg;A(F,d,(D=z.length)+(H==0?0:4)),d+=4;let q=d;m(F,d,H==0?"IDAT":"fdAT"),d+=4,H!=0&&(A(F,d,K++),d+=4),F.set(z,d),d+=D,A(F,d,b(F,q,d-q)),d+=4;}return A(F,d,0),d+=4,m(F,d,"IEND"),d+=4,A(F,d,b(F,d-4,4)),d+=4,F.buffer}function S(f,u,_){for(let s=0;s<f.frames.length;s++){let y=f.frames[s];y.rect.width;let b=y.rect.height,A=new Uint8Array(b*y.bpl+b);y.cimg=h(y.img,b,y.bpp,y.bpl,A,u,_);}}function o(f,u,_,s,y){let b=y[0],A=y[1],T=y[2],m=y[3],d=y[4],P=y[5],x=6,O=8,N=255;for(var D=0;D<f.length;D++){let te=new Uint8Array(f[D]);for(var Q=te.length,H=0;H<Q;H+=4)N&=te[H+3];}let F=N!=255,$=(function(Y,J,ne,oe,j,ue){let ee=[];for(var X=0;X<Y.length;X++){let ce=new Uint8Array(Y[X]),he=new Uint32Array(ce.buffer);var le;let de=0,we=0,me=J,Ie=ne,Ye=oe?1:0;if(X!=0){let yn=ue||oe||X==1||ee[X-2].dispose!=0?1:2,Je=0,vt=1e9;for(let Le=0;Le<yn;Le++){var ge=new Uint8Array(Y[X-1-Le]);let An=new Uint32Array(Y[X-1-Le]),_e=J,be=ne,Oe=-1,De=-1;for(let Re=0;Re<ne;Re++)for(let Ce=0;Ce<J;Ce++)he[se=Re*J+Ce]!=An[se]&&(Ce<_e&&(_e=Ce),Ce>Oe&&(Oe=Ce),Re<be&&(be=Re),Re>De&&(De=Re));Oe==-1&&(_e=be=Oe=De=0),j&&((1&_e)==1&&_e--,(1&be)==1&&be--);let _t=(Oe-_e+1)*(De-be+1);_t<vt&&(vt=_t,Je=Le,de=_e,we=be,me=Oe-_e+1,Ie=De-be+1);}ge=new Uint8Array(Y[X-1-Je]),Je==1&&(ee[X-1].dispose=2),le=new Uint8Array(me*Ie*4),i(ge,J,ne,le,me,Ie,-de,-we,0),Ye=i(ce,J,ne,le,me,Ie,-de,-we,3)?1:0,Ye==1?n(ce,J,ne,le,{x:de,y:we,width:me,height:Ie}):i(ce,J,ne,le,me,Ie,-de,-we,0);}else le=ce.slice(0);ee.push({rect:{x:de,y:we,width:me,height:Ie},img:le,blend:Ye,dispose:0});}if(oe)for(X=0;X<ee.length;X++){if((Te=ee[X]).blend==1)continue;let ce=Te.rect,he=ee[X-1].rect,de=Math.min(ce.x,he.x),we=Math.min(ce.y,he.y),me={x:de,y:we,width:Math.max(ce.x+ce.width,he.x+he.width)-de,height:Math.max(ce.y+ce.height,he.y+he.height)-we};ee[X-1].dispose=1,X-1!=0&&a(Y,J,ne,ee,X-1,me,j),a(Y,J,ne,ee,X,me,j);}let Ne=0;if(Y.length!=1)for(var se=0;se<ee.length;se++){var Te;Ne+=(Te=ee[se]).rect.width*Te.rect.height;}return ee})(f,u,_,b,A,T),K={},V=[],z=[];if(s!=0){let te=[];for(H=0;H<$.length;H++)te.push($[H].img.buffer);let Y=(function(j){let ue=0;for(var ee=0;ee<j.length;ee++)ue+=j[ee].byteLength;let X=new Uint8Array(ue),le=0;for(ee=0;ee<j.length;ee++){let ge=new Uint8Array(j[ee]),Ne=ge.length;for(let se=0;se<Ne;se+=4){let Te=ge[se],ce=ge[se+1],he=ge[se+2],de=ge[se+3];de==0&&(Te=ce=he=0),X[le+se]=Te,X[le+se+1]=ce,X[le+se+2]=he,X[le+se+3]=de;}le+=Ne;}return X.buffer})(te),J=C(Y,s);for(H=0;H<J.plte.length;H++)V.push(J.plte[H].est.rgba);let ne=0;for(H=0;H<$.length;H++){let oe=(G=$[H]).img.length;var q=new Uint8Array(J.inds.buffer,ne>>2,oe>>2);z.push(q);let j=new Uint8Array(J.abuf,ne,oe);P&&c(G.img,G.rect.width,G.rect.height,V,j,q),G.img.set(j),ne+=oe;}}else for(D=0;D<$.length;D++){var G=$[D];let te=new Uint32Array(G.img.buffer);var W=G.rect.width;for(Q=te.length,q=new Uint8Array(Q),z.push(q),H=0;H<Q;H++){let Y=te[H];if(H!=0&&Y==te[H-1])q[H]=q[H-1];else if(H>W&&Y==te[H-W])q[H]=q[H-W];else {let J=K[Y];if(J==null&&(K[Y]=J=V.length,V.push(Y),V.length>=300))break;q[H]=J;}}}let ie=V.length;for(ie<=256&&d==0&&(O=ie<=2?1:ie<=4?2:ie<=16?4:8,O=Math.max(O,m)),D=0;D<$.length;D++){(G=$[D]).rect.x,G.rect.y,W=G.rect.width;let te=G.rect.height,Y=G.img;new Uint32Array(Y.buffer);let J=4*W,ne=4;if(ie<=256&&d==0){J=Math.ceil(O*W/8);var ae=new Uint8Array(J*te);let oe=z[D];for(let j=0;j<te;j++){H=j*J;let ue=j*W;if(O==8)for(var Z=0;Z<W;Z++)ae[H+Z]=oe[ue+Z];else if(O==4)for(Z=0;Z<W;Z++)ae[H+(Z>>1)]|=oe[ue+Z]<<4-4*(1&Z);else if(O==2)for(Z=0;Z<W;Z++)ae[H+(Z>>2)]|=oe[ue+Z]<<6-2*(3&Z);else if(O==1)for(Z=0;Z<W;Z++)ae[H+(Z>>3)]|=oe[ue+Z]<<7-1*(7&Z);}Y=ae,x=3,ne=1;}else if(F==0&&$.length==1){ae=new Uint8Array(W*te*3);let oe=W*te;for(H=0;H<oe;H++){let j=3*H,ue=4*H;ae[j]=Y[ue],ae[j+1]=Y[ue+1],ae[j+2]=Y[ue+2];}Y=ae,x=2,ne=3,J=3*W;}G.img=Y,G.bpl=J,G.bpp=ne;}return {ctype:x,depth:O,plte:V,frames:$}}function a(f,u,_,s,y,b,A){let T=Uint8Array,m=Uint32Array,d=new T(f[y-1]),P=new m(f[y-1]),x=y+1<f.length?new T(f[y+1]):null,O=new T(f[y]),N=new m(O.buffer),D=u,Q=_,H=-1,F=-1;for(let K=0;K<b.height;K++)for(let V=0;V<b.width;V++){let z=b.x+V,q=b.y+K,G=q*u+z,W=N[G];W==0||s[y-1].dispose==0&&P[G]==W&&(x==null||x[4*G+3]!=0)||(z<D&&(D=z),z>H&&(H=z),q<Q&&(Q=q),q>F&&(F=q));}H==-1&&(D=Q=H=F=0),A&&((1&D)==1&&D--,(1&Q)==1&&Q--),b={x:D,y:Q,width:H-D+1,height:F-Q+1};let $=s[y];$.rect=b,$.blend=1,$.img=new Uint8Array(b.width*b.height*4),s[y-1].dispose==0?(i(d,u,_,$.img,b.width,b.height,-b.x,-b.y,0),n(O,u,_,$.img,b)):i(O,u,_,$.img,b.width,b.height,-b.x,-b.y,0);}function n(f,u,_,s,y){i(f,u,_,s,y.width,y.height,-y.x,-y.y,2);}function h(f,u,_,s,y,b,A){let T=[],m,d=[0,1,2,3,4];b!=-1?d=[b]:(u*s>5e5||_==1)&&(d=[0]),A&&(m={level:0});let P=Cn;for(var x=0;x<d.length;x++){for(let D=0;D<u;D++)v(y,f,D,s,_,d[x]);T.push(P.deflate(y,m));}let O,N=1e9;for(x=0;x<T.length;x++)T[x].length<N&&(O=x,N=T[x].length);return T[O]}function v(f,u,_,s,y,b){let A=_*s,T=A+_;if(f[T]=b,T++,b==0)if(s<500)for(var m=0;m<s;m++)f[T+m]=u[A+m];else f.set(new Uint8Array(u.buffer,A,s),T);else if(b==1){for(m=0;m<y;m++)f[T+m]=u[A+m];for(m=y;m<s;m++)f[T+m]=u[A+m]-u[A+m-y]+256&255;}else if(_==0){for(m=0;m<y;m++)f[T+m]=u[A+m];if(b==2)for(m=y;m<s;m++)f[T+m]=u[A+m];if(b==3)for(m=y;m<s;m++)f[T+m]=u[A+m]-(u[A+m-y]>>1)+256&255;if(b==4)for(m=y;m<s;m++)f[T+m]=u[A+m]-E(u[A+m-y],0,0)+256&255;}else {if(b==2)for(m=0;m<s;m++)f[T+m]=u[A+m]+256-u[A+m-s]&255;if(b==3){for(m=0;m<y;m++)f[T+m]=u[A+m]+256-(u[A+m-s]>>1)&255;for(m=y;m<s;m++)f[T+m]=u[A+m]+256-(u[A+m-s]+u[A+m-y]>>1)&255;}if(b==4){for(m=0;m<y;m++)f[T+m]=u[A+m]+256-E(0,u[A+m-s],0)&255;for(m=y;m<s;m++)f[T+m]=u[A+m]+256-E(u[A+m-y],u[A+m-s],u[A+m-y-s])&255;}}}function C(f,u){let _=new Uint8Array(f),s=_.slice(0),y=new Uint32Array(s.buffer),b=M(s,u),A=b[0],T=b[1],m=_.length,d=new Uint8Array(m>>2),P;if(_.length<2e7)for(var x=0;x<m;x+=4)P=I(A,O=_[x]*(1/255),N=_[x+1]*(1/255),D=_[x+2]*(1/255),Q=_[x+3]*(1/255)),d[x>>2]=P.ind,y[x>>2]=P.est.rgba;else for(x=0;x<m;x+=4){var O=_[x]*.00392156862745098,N=_[x+1]*(1/255),D=_[x+2]*(1/255),Q=_[x+3]*(1/255);for(P=A;P.left;)P=B(P.est,O,N,D,Q)<=0?P.left:P.right;d[x>>2]=P.ind,y[x>>2]=P.est.rgba;}return {abuf:s.buffer,inds:d,plte:T}}function M(f,u,_){_==null&&(_=1e-4);let s=new Uint32Array(f.buffer),y={i0:0,i1:f.length,bst:null,est:null,tdst:0,left:null,right:null};y.bst=R(f,y.i0,y.i1),y.est=g(y.bst);let b=[y];for(;b.length<u;){let T=0,m=0;for(var A=0;A<b.length;A++)b[A].est.L>T&&(T=b[A].est.L,m=A);if(T<_)break;let d=b[m],P=k(f,s,d.i0,d.i1,d.est.e,d.est.eMq255);if(d.i0>=P||d.i1<=P){d.est.L=0;continue}let x={i0:d.i0,i1:P,bst:null,est:null,tdst:0,left:null,right:null};x.bst=R(f,x.i0,x.i1),x.est=g(x.bst);let O={i0:P,i1:d.i1,bst:null,est:null,tdst:0,left:null,right:null};for(O.bst={R:[],m:[],N:d.bst.N-x.bst.N},A=0;A<16;A++)O.bst.R[A]=d.bst.R[A]-x.bst.R[A];for(A=0;A<4;A++)O.bst.m[A]=d.bst.m[A]-x.bst.m[A];O.est=g(O.bst),d.left=x,d.right=O,b[m]=x,b.push(O);}for(b.sort(((T,m)=>m.bst.N-T.bst.N)),A=0;A<b.length;A++)b[A].ind=A;return [y,b]}function I(f,u,_,s,y){if(f.left==null)return f.tdst=(function(x,O,N,D,Q){let H=O-x[0],F=N-x[1],$=D-x[2],K=Q-x[3];return H*H+F*F+$*$+K*K})(f.est.q,u,_,s,y),f;let b=B(f.est,u,_,s,y),A=f.left,T=f.right;b>0&&(A=f.right,T=f.left);let m=I(A,u,_,s,y);if(m.tdst<=b*b)return m;let d=I(T,u,_,s,y);return d.tdst<m.tdst?d:m}function B(f,u,_,s,y){let{e:b}=f;return b[0]*u+b[1]*_+b[2]*s+b[3]*y-f.eMq}function k(f,u,_,s,y,b){for(s-=4;_<s;){for(;L(f,_,y)<=b;)_+=4;for(;L(f,s,y)>b;)s-=4;if(_>=s)break;let A=u[_>>2];u[_>>2]=u[s>>2],u[s>>2]=A,_+=4,s-=4;}for(;L(f,_,y)>b;)_-=4;return _+4}function L(f,u,_){return f[u]*_[0]+f[u+1]*_[1]+f[u+2]*_[2]+f[u+3]*_[3]}function R(f,u,_){let s=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],y=[0,0,0,0],b=_-u>>2;for(let A=u;A<_;A+=4){let T=f[A]*.00392156862745098,m=f[A+1]*(1/255),d=f[A+2]*(1/255),P=f[A+3]*(1/255);y[0]+=T,y[1]+=m,y[2]+=d,y[3]+=P,s[0]+=T*T,s[1]+=T*m,s[2]+=T*d,s[3]+=T*P,s[5]+=m*m,s[6]+=m*d,s[7]+=m*P,s[10]+=d*d,s[11]+=d*P,s[15]+=P*P;}return s[4]=s[1],s[8]=s[2],s[9]=s[6],s[12]=s[3],s[13]=s[7],s[14]=s[11],{R:s,m:y,N:b}}function g(f){let{R:u}=f,{m:_}=f,{N:s}=f,y=_[0],b=_[1],A=_[2],T=_[3],m=s==0?0:1/s,d=[u[0]-y*y*m,u[1]-y*b*m,u[2]-y*A*m,u[3]-y*T*m,u[4]-b*y*m,u[5]-b*b*m,u[6]-b*A*m,u[7]-b*T*m,u[8]-A*y*m,u[9]-A*b*m,u[10]-A*A*m,u[11]-A*T*m,u[12]-T*y*m,u[13]-T*b*m,u[14]-T*A*m,u[15]-T*T*m],P=d,x=U,O=[Math.random(),Math.random(),Math.random(),Math.random()],N=0,D=0;if(s!=0)for(let H=0;H<16&&(O=x.multVec(P,O),D=Math.sqrt(x.dot(O,O)),O=x.sml(1/D,O),!(H!=0&&Math.abs(D-N)<1e-9));H++)N=D;let Q=[y*m,b*m,A*m,T*m];return {Cov:d,q:Q,e:O,L:N,eMq255:x.dot(x.sml(255,Q),O),eMq:x.dot(O,Q),rgba:(Math.round(255*Q[3])<<24|Math.round(255*Q[2])<<16|Math.round(255*Q[1])<<8|Math.round(255*Q[0])<<0)>>>0}}var U={multVec:(f,u)=>[f[0]*u[0]+f[1]*u[1]+f[2]*u[2]+f[3]*u[3],f[4]*u[0]+f[5]*u[1]+f[6]*u[2]+f[7]*u[3],f[8]*u[0]+f[9]*u[1]+f[10]*u[2]+f[11]*u[3],f[12]*u[0]+f[13]*u[1]+f[14]*u[2]+f[15]*u[3]],dot:(f,u)=>f[0]*u[0]+f[1]*u[1]+f[2]*u[2]+f[3]*u[3],sml:(f,u)=>[f*u[0],f*u[1],f*u[2],f*u[3]]};pe.encode=function(u,_,s,y,b,A,T){y==null&&(y=0),T==null&&(T=false);let m=o(u,_,s,y,[false,false,false,0,T,false]);return S(m,-1),w(m,_,s,b,A)},pe.encodeLL=function(u,_,s,y,b,A,T,m){let d={ctype:0+(y==1?0:2)+(b==0?0:4),depth:A,frames:[]},P=(y+b)*A,x=P*_;for(let O=0;O<u.length;O++)d.frames.push({rect:{x:0,y:0,width:_,height:s},img:new Uint8Array(u[O]),blend:0,dispose:1,bpp:Math.ceil(P/8),bpl:Math.ceil(x/8)});return S(d,0,true),w(d,_,s,T,m)},pe.encode.compress=o,pe.encode.dither=c,pe.quantize=C,pe.quantize.getKDtree=M,pe.quantize.getNearest=I;})();var It={toArrayBuffer(i,r){let E=i.width,l=i.height,e=E<<2,t=i.getContext("2d").getImageData(0,0,E,l),p=new Uint32Array(t.data.buffer),c=(32*E+31)/32<<2,w=c*l,S=122+w,o=new ArrayBuffer(S),a=new DataView(o),n=1<<20,h,v,C,M,I=n,B=0,k=0,L=0;function R(f){a.setUint16(k,f,true),k+=2;}function g(f){a.setUint32(k,f,true),k+=4;}function U(f){k+=f;}R(19778),g(S),U(4),g(122),g(108),g(E),g(-l>>>0),R(1),R(32),g(3),g(w),g(2835),g(2835),U(8),g(16711680),g(65280),g(255),g(4278190080),g(1466527264),(function f(){for(;B<l&&I>0;){for(M=122+B*c,h=0;h<e;)I--,v=p[L++],C=v>>>24,a.setUint32(M+h,v<<8|C),h+=4;B++;}L<p.length?(I=n,setTimeout(f,It._dly)):r(o);})();},toBlob(i,r){this.toArrayBuffer(i,(E=>{r(new Blob([E],{type:"image/bmp"}));}));},_dly:9},fe={CHROME:"CHROME",FIREFOX:"FIREFOX",DESKTOP_SAFARI:"DESKTOP_SAFARI",IE:"IE",IOS:"IOS",ETC:"ETC"},xn={[fe.CHROME]:16384,[fe.FIREFOX]:11180,[fe.DESKTOP_SAFARI]:16384,[fe.IE]:8192,[fe.IOS]:4096,[fe.ETC]:8192},et=typeof globalThis.window<"u",Rt=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,We=et&&globalThis.window.cordova&&globalThis.window.cordova.require&&globalThis.window.cordova.require("cordova/modulemapper"),Un=(et||Rt)&&(We&&We.getOriginalSymbol(globalThis.window,"File")||typeof File<"u"&&File),Ct=(et||Rt)&&(We&&We.getOriginalSymbol(globalThis.window,"FileReader")||typeof globalThis.FileReader<"u"&&globalThis.FileReader);function tt(i,r,E=Date.now()){return new Promise((l=>{let e=i.split(","),t=e[0].match(/:(.*?);/)[1],p=globalThis.atob(e[1]),c=p.length,w=new Uint8Array(c);for(;c--;)w[c]=p.charCodeAt(c);let S=new Blob([w],{type:t});S.name=r,S.lastModified=E,l(S);}))}function xt(i){return new Promise(((r,E)=>{let l=new Ct;l.onload=()=>r(l.result),l.onerror=e=>E(e),l.readAsDataURL(i);}))}function Ut(i){return new Promise(((r,E)=>{let l=new globalThis.Image;l.onload=()=>r(l),l.onerror=e=>E(e),l.src=i;}))}function xe(){if(xe.cachedResult!==void 0)return xe.cachedResult;let i=fe.ETC,{userAgent:r}=navigator;return /Chrom(e|ium)/i.test(r)?i=fe.CHROME:/iP(ad|od|hone)/i.test(r)&&/WebKit/i.test(r)?i=fe.IOS:/Safari/i.test(r)?i=fe.DESKTOP_SAFARI:/Firefox/i.test(r)?i=fe.FIREFOX:(/MSIE/i.test(r)||globalThis.document.documentMode)&&(i=fe.IE),xe.cachedResult=i,xe.cachedResult}function Ot(i,r){let E=xe(),l=xn[E],e=i,t=r,p=e*t,c=e>t?t/e:e/t;for(;p>l*l;){let w=(l+e)/2,S=(l+t)/2;w<S?(t=S,e=S*c):(t=w*c,e=w),p=e*t;}return {width:e,height:t}}function Ve(i,r){let E,l;try{if(E=new OffscreenCanvas(i,r),l=E.getContext("2d"),l===null)throw new Error("getContext of OffscreenCanvas returns null")}catch{E=globalThis.document.createElement("canvas"),l=E.getContext("2d");}return E.width=i,E.height=r,[E,l]}function Pt(i,r){let{width:E,height:l}=Ot(i.width,i.height),[e,t]=Ve(E,l);return r&&/jpe?g/.test(r)&&(t.fillStyle="white",t.fillRect(0,0,e.width,e.height)),t.drawImage(i,0,0,e.width,e.height),e}function Qe(){return Qe.cachedResult!==void 0||(Qe.cachedResult=["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&typeof globalThis.document<"u"&&"ontouchend"in globalThis.document),Qe.cachedResult}function ze(i,r={}){return new Promise((function(E,l){let e,t;var p=function(){try{return t=Pt(e,r.fileType||i.type),E([e,t])}catch(w){return l(w)}},c=function(w){try{var S=function(o){try{throw o}catch(a){return l(a)}};try{let o;return xt(i).then((function(a){try{return o=a,Ut(o).then((function(n){try{return e=n,(function(){try{return p()}catch(h){return l(h)}})()}catch(h){return S(h)}}),S)}catch(n){return S(n)}}),S)}catch(o){S(o);}}catch(o){return l(o)}};try{if(Qe()||[fe.DESKTOP_SAFARI,fe.MOBILE_SAFARI].includes(xe()))throw new Error("Skip createImageBitmap on IOS and Safari");return createImageBitmap(i).then((function(w){try{return e=w,p()}catch{return c()}}),c)}catch{c();}}))}function Ge(i,r,E,l,e=1){return new Promise((function(t,p){let c;if(r==="image/png"){let a,n,h;return a=i.getContext("2d"),{data:n}=a.getImageData(0,0,i.width,i.height),h=pe.encode([n.buffer],i.width,i.height,4096*e),c=new Blob([h],{type:r}),c.name=E,c.lastModified=l,w.call(this)}{let a=function(){return w.call(this)};if(r==="image/bmp")return new Promise((n=>It.toBlob(i,n))).then(function(n){try{return c=n,c.name=E,c.lastModified=l,a.call(this)}catch(h){return p(h)}}.bind(this),p);{let n=function(){return a.call(this)};if(typeof OffscreenCanvas=="function"&&i instanceof OffscreenCanvas)return i.convertToBlob({type:r,quality:e}).then(function(h){try{return c=h,c.name=E,c.lastModified=l,n.call(this)}catch(v){return p(v)}}.bind(this),p);{let h;return h=i.toDataURL(r,e),tt(h,E,l).then(function(v){try{return c=v,n.call(this)}catch(C){return p(C)}}.bind(this),p)}}}function w(){return t(c)}}))}function ye(i){i.width=0,i.height=0;}function Pe(){return new Promise((function(i,r){let l,e,t,p;return Pe.cachedResult!==void 0?i(Pe.cachedResult):(tt("data:image/jpeg;base64,/9j/4QAiRXhpZgAATU0AKgAAAAgAAQESAAMAAAABAAYAAAAAAAD/2wCEAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAf/AABEIAAEAAgMBEQACEQEDEQH/xABKAAEAAAAAAAAAAAAAAAAAAAALEAEAAAAAAAAAAAAAAAAAAAAAAQEAAAAAAAAAAAAAAAAAAAAAEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwA/8H//2Q==","test.jpg",Date.now()).then((function(c){try{return l=c,ze(l).then((function(w){try{return e=w[1],Ge(e,l.type,l.name,l.lastModified).then((function(S){try{return t=S,ye(e),ze(t).then((function(o){try{return p=o[0],Pe.cachedResult=p.width===1&&p.height===2,i(Pe.cachedResult)}catch(a){return r(a)}}),r)}catch(o){return r(o)}}),r)}catch(S){return r(S)}}),r)}catch(w){return r(w)}}),r))}))}function Mt(i){return new Promise(((r,E)=>{let l=new Ct;l.onload=e=>{let t=new DataView(e.target.result);if(t.getUint16(0,false)!=65496)return r(-2);let p=t.byteLength,c=2;for(;c<p;){if(t.getUint16(c+2,false)<=8)return r(-1);let w=t.getUint16(c,false);if(c+=2,w==65505){if(t.getUint32(c+=2,false)!=1165519206)return r(-1);let S=t.getUint16(c+=6,false)==18761;c+=t.getUint32(c+4,S);let o=t.getUint16(c,S);c+=2;for(let a=0;a<o;a++)if(t.getUint16(c+12*a,S)==274)return r(t.getUint16(c+12*a+8,S))}else {if((65280&w)!=65280)break;c+=t.getUint16(c,false);}}return r(-1)},l.onerror=e=>E(e),l.readAsArrayBuffer(i);}))}function Lt(i,r){let{width:E}=i,{height:l}=i,{maxWidthOrHeight:e}=r,t,p=i;return isFinite(e)&&(E>e||l>e)&&([p,t]=Ve(E,l),E>l?(p.width=e,p.height=l/E*e):(p.width=E/l*e,p.height=e),t.drawImage(i,0,0,p.width,p.height),ye(i)),p}function Dt(i,r){let{width:E}=i,{height:l}=i,[e,t]=Ve(E,l);switch(r>4&&r<9?(e.width=l,e.height=E):(e.width=E,e.height=l),r){case 2:t.transform(-1,0,0,1,E,0);break;case 3:t.transform(-1,0,0,-1,E,l);break;case 4:t.transform(1,0,0,-1,0,l);break;case 5:t.transform(0,1,1,0,0,0);break;case 6:t.transform(0,1,-1,0,l,0);break;case 7:t.transform(0,-1,-1,0,l,E);break;case 8:t.transform(0,-1,1,0,0,E);}return t.drawImage(i,0,0,E,l),ye(i),e}function St(i,r,E=0){return new Promise((function(l,e){let t,p,c,w,S,o,a,n,h,v,C,M,I,B,k,L,R,g,U,f;function u(s=5){if(r.signal&&r.signal.aborted)throw r.signal.reason;t+=s,r.onProgress(Math.min(t,100));}function _(s){if(r.signal&&r.signal.aborted)throw r.signal.reason;t=Math.min(Math.max(s,t),100),r.onProgress(t);}return t=E,p=r.maxIteration||10,c=1024*r.maxSizeMB*1024,u(),ze(i,r).then(function(s){try{return [,w]=s,u(),S=Lt(w,r),u(),new Promise((function(y,b){var A;if(!(A=r.exifOrientation))return Mt(i).then(function(m){try{return A=m,T.call(this)}catch(d){return b(d)}}.bind(this),b);function T(){return y(A)}return T.call(this)})).then(function(y){try{return o=y,u(),Pe().then(function(b){try{return a=b?S:Dt(S,o),u(),n=r.initialQuality||1,h=r.fileType||i.type,Ge(a,h,i.name,i.lastModified,n).then(function(A){try{{let P=function(){if(p--&&(k>c||k>I)){let O,N;return O=f?.95*U.width:U.width,N=f?.95*U.height:U.height,[R,g]=Ve(O,N),g.drawImage(U,0,0,O,N),n*=h==="image/png"?.85:.95,Ge(R,h,i.name,i.lastModified,n).then((function(D){try{return L=D,ye(U),U=R,k=L.size,_(Math.min(99,Math.floor((B-k)/(B-c)*100))),P}catch(Q){return e(Q)}}),e)}return [1]},x=function(){return ye(U),ye(R),ye(S),ye(a),ye(w),_(100),l(L)};var m=P,d=x;if(v=A,u(),C=v.size>c,M=v.size>i.size,!C&&!M)return _(100),l(v);var T;return I=i.size,B=v.size,k=B,U=a,f=!r.alwaysKeepResolution&&C,(T=function(O){for(;O;){if(O.then)return void O.then(T,e);try{if(O.pop){if(O.length)return O.pop()?x.call(this):O;O=P;}else O=O.call(this);}catch(N){return e(N)}}}.bind(this))(P)}}catch(P){return e(P)}}.bind(this),e)}catch(A){return e(A)}}.bind(this),e)}catch(b){return e(b)}}.bind(this),e)}catch(y){return e(y)}}.bind(this),e)}))}var On=`
5
+ `+r.prev}function qe(i,r){var E=ft(i),l=[];if(E){l.length=i.length;for(var e=0;e<i.length;e++)l[e]=ve(i,e)?r(i[e],i):"";}var t=typeof at=="function"?at(i):[],p;if(Me){p={};for(var c=0;c<t.length;c++)p["$"+t[c]]=t[c];}for(var y in i)ve(i,y)&&(E&&String(Number(y))===y&&y<i.length||Me&&p["$"+y]instanceof Symbol||(Yt.call(/[^\w$]/,y)?l.push(r(y,i)+": "+r(i[y],i)):l.push(y+": "+r(i[y],i))));if(typeof at=="function")for(var S=0;S<t.length;S++)Jt.call(i,t[S])&&l.push("["+r(t[S])+"]: "+r(i[t[S]],i));return l}});function Tn(i,r){return r.forEach((function(E){E&&typeof E!="string"&&!Array.isArray(E)&&Object.keys(E).forEach((function(l){if(l!=="default"&&!(l in i)){var e=Object.getOwnPropertyDescriptor(E,l);Object.defineProperty(i,l,e.get?e:{enumerable:true,get:function(){return E[l]}});}}));})),Object.freeze(i)}function Tt(i,r){return new Promise((function(E,l){let e;return In(i).then((function(t){try{return e=t,E(new Blob([r.slice(0,2),e,r.slice(2)],{type:"image/jpeg"}))}catch(p){return l(p)}}),l)}))}var In=i=>new Promise(((r,E)=>{let l=new globalThis.FileReader;l.addEventListener("load",(({target:{result:e}})=>{let t=new DataView(e),p=0;if(t.getUint16(p)!==65496)return E("not a valid JPEG");for(p+=2;;){let c=t.getUint16(p);if(c===65498)break;let y=t.getUint16(p+2);if(c===65505&&t.getUint32(p+4)===1165519206){let S=p+10,o;switch(t.getUint16(S)){case 18761:o=true;break;case 19789:o=false;break;default:return E("TIFF header contains invalid endian")}if(t.getUint16(S+2,o)!==42)return E("TIFF header contains invalid version");let a=t.getUint32(S+4,o),n=S+a+2+12*t.getUint16(S+a,o);for(let h=S+a+2;h<n;h+=12)if(t.getUint16(h,o)==274){if(t.getUint16(h+2,o)!==3)return E("Orientation data type is invalid");if(t.getUint32(h+4,o)!==1)return E("Orientation data count is invalid");t.setUint16(h+8,1,o);break}return r(e.slice(p,p+2+y))}p+=2+y;}return r(new Blob)})),l.readAsArrayBuffer(i);})),$e={},Rn={get exports(){return $e},set exports(i){$e=i;}};(function(i){var r,E,l={};Rn.exports=l,l.parse=function(e,t){for(var p=l.bin.readUshort,c=l.bin.readUint,y=0,S={},o=new Uint8Array(e),a=o.length-4;c(o,a)!=101010256;)a--;y=a,y+=4;var n=p(o,y+=4);p(o,y+=2);var h=c(o,y+=2),v=c(o,y+=4);y+=4,y=v;for(var C=0;C<n;C++){c(o,y),y+=4,y+=4,y+=4,c(o,y+=4),h=c(o,y+=4);var M=c(o,y+=4),I=p(o,y+=4),B=p(o,y+2),k=p(o,y+4);y+=6;var L=c(o,y+=8);y+=4,y+=I+B+k,l._readLocal(o,L,S,h,M,t);}return S},l._readLocal=function(e,t,p,c,y,S){var o=l.bin.readUshort,a=l.bin.readUint;a(e,t),o(e,t+=4),o(e,t+=2);var n=o(e,t+=2);a(e,t+=2),a(e,t+=4),t+=4;var h=o(e,t+=8),v=o(e,t+=2);t+=2;var C=l.bin.readUTF8(e,t,h);if(t+=h,t+=v,S)p[C]={size:y,csize:c};else {var M=new Uint8Array(e.buffer,t);if(n==0)p[C]=new Uint8Array(M.buffer.slice(t,t+c));else {if(n!=8)throw "unknown compression method: "+n;var I=new Uint8Array(y);l.inflateRaw(M,I),p[C]=I;}}},l.inflateRaw=function(e,t){return l.F.inflate(e,t)},l.inflate=function(e,t){return e[0],e[1],l.inflateRaw(new Uint8Array(e.buffer,e.byteOffset+2,e.length-6),t)},l.deflate=function(e,t){t==null&&(t={level:6});var p=0,c=new Uint8Array(50+Math.floor(1.1*e.length));c[p]=120,c[p+1]=156,p+=2,p=l.F.deflateRaw(e,c,p,t.level);var y=l.adler(e,0,e.length);return c[p+0]=y>>>24&255,c[p+1]=y>>>16&255,c[p+2]=y>>>8&255,c[p+3]=y>>>0&255,new Uint8Array(c.buffer,0,p+4)},l.deflateRaw=function(e,t){t==null&&(t={level:6});var p=new Uint8Array(50+Math.floor(1.1*e.length)),c=l.F.deflateRaw(e,p,c,t.level);return new Uint8Array(p.buffer,0,c)},l.encode=function(e,t){t==null&&(t=false);var p=0,c=l.bin.writeUint,y=l.bin.writeUshort,S={};for(var o in e){var a=!l._noNeed(o)&&!t,n=e[o],h=l.crc.crc(n,0,n.length);S[o]={cpr:a,usize:n.length,crc:h,file:a?l.deflateRaw(n):n};}for(var o in S)p+=S[o].file.length+30+46+2*l.bin.sizeUTF8(o);p+=22;var v=new Uint8Array(p),C=0,M=[];for(var o in S){var I=S[o];M.push(C),C=l._writeHeader(v,C,o,I,0);}var B=0,k=C;for(var o in S)I=S[o],M.push(C),C=l._writeHeader(v,C,o,I,1,M[B++]);var L=C-k;return c(v,C,101010256),C+=4,y(v,C+=4,B),y(v,C+=2,B),c(v,C+=2,L),c(v,C+=4,k),C+=4,C+=2,v.buffer},l._noNeed=function(e){var t=e.split(".").pop().toLowerCase();return "png,jpg,jpeg,zip".indexOf(t)!=-1},l._writeHeader=function(e,t,p,c,y,S){var o=l.bin.writeUint,a=l.bin.writeUshort,n=c.file;return o(e,t,y==0?67324752:33639248),t+=4,y==1&&(t+=2),a(e,t,20),a(e,t+=2,0),a(e,t+=2,c.cpr?8:0),o(e,t+=2,0),o(e,t+=4,c.crc),o(e,t+=4,n.length),o(e,t+=4,c.usize),a(e,t+=4,l.bin.sizeUTF8(p)),a(e,t+=2,0),t+=2,y==1&&(t+=2,t+=2,o(e,t+=6,S),t+=4),t+=l.bin.writeUTF8(e,t,p),y==0&&(e.set(n,t),t+=n.length),t},l.crc={table:(function(){for(var e=new Uint32Array(256),t=0;t<256;t++){for(var p=t,c=0;c<8;c++)1&p?p=3988292384^p>>>1:p>>>=1;e[t]=p;}return e})(),update:function(e,t,p,c){for(var y=0;y<c;y++)e=l.crc.table[255&(e^t[p+y])]^e>>>8;return e},crc:function(e,t,p){return 4294967295^l.crc.update(4294967295,e,t,p)}},l.adler=function(e,t,p){for(var c=1,y=0,S=t,o=t+p;S<o;){for(var a=Math.min(S+5552,o);S<a;)y+=c+=e[S++];c%=65521,y%=65521;}return y<<16|c},l.bin={readUshort:function(e,t){return e[t]|e[t+1]<<8},writeUshort:function(e,t,p){e[t]=255&p,e[t+1]=p>>8&255;},readUint:function(e,t){return 16777216*e[t+3]+(e[t+2]<<16|e[t+1]<<8|e[t])},writeUint:function(e,t,p){e[t]=255&p,e[t+1]=p>>8&255,e[t+2]=p>>16&255,e[t+3]=p>>24&255;},readASCII:function(e,t,p){for(var c="",y=0;y<p;y++)c+=String.fromCharCode(e[t+y]);return c},writeASCII:function(e,t,p){for(var c=0;c<p.length;c++)e[t+c]=p.charCodeAt(c);},pad:function(e){return e.length<2?"0"+e:e},readUTF8:function(e,t,p){for(var c,y="",S=0;S<p;S++)y+="%"+l.bin.pad(e[t+S].toString(16));try{c=decodeURIComponent(y);}catch{return l.bin.readASCII(e,t,p)}return c},writeUTF8:function(e,t,p){for(var c=p.length,y=0,S=0;S<c;S++){var o=p.charCodeAt(S);if((4294967168&o)==0)e[t+y]=o,y++;else if((4294965248&o)==0)e[t+y]=192|o>>6,e[t+y+1]=128|o>>0&63,y+=2;else if((4294901760&o)==0)e[t+y]=224|o>>12,e[t+y+1]=128|o>>6&63,e[t+y+2]=128|o>>0&63,y+=3;else {if((4292870144&o)!=0)throw "e";e[t+y]=240|o>>18,e[t+y+1]=128|o>>12&63,e[t+y+2]=128|o>>6&63,e[t+y+3]=128|o>>0&63,y+=4;}}return y},sizeUTF8:function(e){for(var t=e.length,p=0,c=0;c<t;c++){var y=e.charCodeAt(c);if((4294967168&y)==0)p++;else if((4294965248&y)==0)p+=2;else if((4294901760&y)==0)p+=3;else {if((4292870144&y)!=0)throw "e";p+=4;}}return p}},l.F={},l.F.deflateRaw=function(e,t,p,c){var y=[[0,0,0,0,0],[4,4,8,4,0],[4,5,16,8,0],[4,6,16,16,0],[4,10,16,32,0],[8,16,32,32,0],[8,16,128,128,0],[8,32,128,256,0],[32,128,258,1024,1],[32,258,258,4096,1]][c],S=l.F.U,o=l.F._goodIndex;l.F._hash;var a=l.F._putsE,n=0,h=p<<3,v=0,C=e.length;if(c==0){for(;n<C;)a(t,h,n+(s=Math.min(65535,C-n))==C?1:0),h=l.F._copyExact(e,n,s,t,h+8),n+=s;return h>>>3}var M=S.lits,I=S.strt,B=S.prev,k=0,L=0,R=0,g=0,U=0,f=0;for(C>2&&(I[f=l.F._hash(e,0)]=0),n=0;n<C;n++){if(U=f,n+1<C-2){f=l.F._hash(e,n+1);var u=n+1&32767;B[u]=I[f],I[f]=u;}if(v<=n){(k>14e3||L>26697)&&C-n>100&&(v<n&&(M[k]=n-v,k+=2,v=n),h=l.F._writeBlock(n==C-1||v==C?1:0,M,k,g,e,R,n-R,t,h),k=L=g=0,R=n);var _=0;n<C-2&&(_=l.F._bestMatch(e,n,B,U,Math.min(y[2],C-n),y[3]));var s=_>>>16,A=65535&_;if(_!=0){A=65535&_;var b=o(s=_>>>16,S.of0);S.lhst[257+b]++;var w=o(A,S.df0);S.dhst[w]++,g+=S.exb[b]+S.dxb[w],M[k]=s<<23|n-v,M[k+1]=A<<16|b<<8|w,k+=2,v=n+s;}else S.lhst[e[n]]++;L++;}}for(R==n&&e.length!=0||(v<n&&(M[k]=n-v,k+=2,v=n),h=l.F._writeBlock(1,M,k,g,e,R,n-R,t,h),k=0,L=0,k=L=g=0,R=n);(7&h)!=0;)h++;return h>>>3},l.F._bestMatch=function(e,t,p,c,y,S){var o=32767&t,a=p[o],n=o-a+32768&32767;if(a==o||c!=l.F._hash(e,t-n))return 0;for(var h=0,v=0,C=Math.min(32767,t);n<=C&&--S!=0&&a!=o;){if(h==0||e[t+h]==e[t+h-n]){var M=l.F._howLong(e,t,n);if(M>h){if(v=n,(h=M)>=y)break;n+2<M&&(M=n+2);for(var I=0,B=0;B<M-2;B++){var k=t-n+B+32768&32767,L=k-p[k]+32768&32767;L>I&&(I=L,a=k);}}}n+=(o=a)-(a=p[o])+32768&32767;}return h<<16|v},l.F._howLong=function(e,t,p){if(e[t]!=e[t-p]||e[t+1]!=e[t+1-p]||e[t+2]!=e[t+2-p])return 0;var c=t,y=Math.min(e.length,t+258);for(t+=3;t<y&&e[t]==e[t-p];)t++;return t-c},l.F._hash=function(e,t){return (e[t]<<8|e[t+1])+(e[t+2]<<4)&65535},l.saved=0,l.F._writeBlock=function(e,t,p,c,y,S,o,a,n){var h,v,C,M,I,B,k,L,R,g=l.F.U,U=l.F._putsF,f=l.F._putsE;g.lhst[256]++,v=(h=l.F.getTrees())[0],C=h[1],M=h[2],I=h[3],B=h[4],k=h[5],L=h[6],R=h[7];var u=32+((n+3&7)==0?0:8-(n+3&7))+(o<<3),_=c+l.F.contSize(g.fltree,g.lhst)+l.F.contSize(g.fdtree,g.dhst),s=c+l.F.contSize(g.ltree,g.lhst)+l.F.contSize(g.dtree,g.dhst);s+=14+3*k+l.F.contSize(g.itree,g.ihst)+(2*g.ihst[16]+3*g.ihst[17]+7*g.ihst[18]);for(var A=0;A<286;A++)g.lhst[A]=0;for(A=0;A<30;A++)g.dhst[A]=0;for(A=0;A<19;A++)g.ihst[A]=0;var b=u<_&&u<s?0:_<s?1:2;if(U(a,n,e),U(a,n+1,b),n+=3,b==0){for(;(7&n)!=0;)n++;n=l.F._copyExact(y,S,o,a,n);}else {var w,T;if(b==1&&(w=g.fltree,T=g.fdtree),b==2){l.F.makeCodes(g.ltree,v),l.F.revCodes(g.ltree,v),l.F.makeCodes(g.dtree,C),l.F.revCodes(g.dtree,C),l.F.makeCodes(g.itree,M),l.F.revCodes(g.itree,M),w=g.ltree,T=g.dtree,f(a,n,I-257),f(a,n+=5,B-1),f(a,n+=5,k-4),n+=4;for(var m=0;m<k;m++)f(a,n+3*m,g.itree[1+(g.ordr[m]<<1)]);n+=3*k,n=l.F._codeTiny(L,g.itree,a,n),n=l.F._codeTiny(R,g.itree,a,n);}for(var d=S,P=0;P<p;P+=2){for(var x=t[P],O=x>>>23,H=d+(8388607&x);d<H;)n=l.F._writeLit(y[d++],w,a,n);if(O!=0){var D=t[P+1],Q=D>>16,N=D>>8&255,F=255&D;f(a,n=l.F._writeLit(257+N,w,a,n),O-g.of0[N]),n+=g.exb[N],U(a,n=l.F._writeLit(F,T,a,n),Q-g.df0[F]),n+=g.dxb[F],d+=O;}}n=l.F._writeLit(256,w,a,n);}return n},l.F._copyExact=function(e,t,p,c,y){var S=y>>>3;return c[S]=p,c[S+1]=p>>>8,c[S+2]=255-c[S],c[S+3]=255-c[S+1],S+=4,c.set(new Uint8Array(e.buffer,t,p),S),y+(p+4<<3)},l.F.getTrees=function(){for(var e=l.F.U,t=l.F._hufTree(e.lhst,e.ltree,15),p=l.F._hufTree(e.dhst,e.dtree,15),c=[],y=l.F._lenCodes(e.ltree,c),S=[],o=l.F._lenCodes(e.dtree,S),a=0;a<c.length;a+=2)e.ihst[c[a]]++;for(a=0;a<S.length;a+=2)e.ihst[S[a]]++;for(var n=l.F._hufTree(e.ihst,e.itree,7),h=19;h>4&&e.itree[1+(e.ordr[h-1]<<1)]==0;)h--;return [t,p,n,y,o,h,c,S]},l.F.getSecond=function(e){for(var t=[],p=0;p<e.length;p+=2)t.push(e[p+1]);return t},l.F.nonZero=function(e){for(var t="",p=0;p<e.length;p+=2)e[p+1]!=0&&(t+=(p>>1)+",");return t},l.F.contSize=function(e,t){for(var p=0,c=0;c<t.length;c++)p+=t[c]*e[1+(c<<1)];return p},l.F._codeTiny=function(e,t,p,c){for(var y=0;y<e.length;y+=2){var S=e[y],o=e[y+1];c=l.F._writeLit(S,t,p,c);var a=S==16?2:S==17?3:7;S>15&&(l.F._putsE(p,c,o,a),c+=a);}return c},l.F._lenCodes=function(e,t){for(var p=e.length;p!=2&&e[p-1]==0;)p-=2;for(var c=0;c<p;c+=2){var y=e[c+1],S=c+3<p?e[c+3]:-1,o=c+5<p?e[c+5]:-1,a=c==0?-1:e[c-1];if(y==0&&S==y&&o==y){for(var n=c+5;n+2<p&&e[n+2]==y;)n+=2;(h=Math.min(n+1-c>>>1,138))<11?t.push(17,h-3):t.push(18,h-11),c+=2*h-2;}else if(y==a&&S==y&&o==y){for(n=c+5;n+2<p&&e[n+2]==y;)n+=2;var h=Math.min(n+1-c>>>1,6);t.push(16,h-3),c+=2*h-2;}else t.push(y,0);}return p>>>1},l.F._hufTree=function(e,t,p){var c=[],y=e.length,S=t.length,o=0;for(o=0;o<S;o+=2)t[o]=0,t[o+1]=0;for(o=0;o<y;o++)e[o]!=0&&c.push({lit:o,f:e[o]});var a=c.length,n=c.slice(0);if(a==0)return 0;if(a==1){var h=c[0].lit;return n=h==0?1:0,t[1+(h<<1)]=1,t[1+(n<<1)]=1,1}c.sort((function(L,R){return L.f-R.f}));var v=c[0],C=c[1],M=0,I=1,B=2;for(c[0]={lit:-1,f:v.f+C.f,l:v,r:C,d:0};I!=a-1;)v=M!=I&&(B==a||c[M].f<c[B].f)?c[M++]:c[B++],C=M!=I&&(B==a||c[M].f<c[B].f)?c[M++]:c[B++],c[I++]={lit:-1,f:v.f+C.f,l:v,r:C};var k=l.F.setDepth(c[I-1],0);for(k>p&&(l.F.restrictDepth(n,p,k),k=p),o=0;o<a;o++)t[1+(n[o].lit<<1)]=n[o].d;return k},l.F.setDepth=function(e,t){return e.lit!=-1?(e.d=t,t):Math.max(l.F.setDepth(e.l,t+1),l.F.setDepth(e.r,t+1))},l.F.restrictDepth=function(e,t,p){var c=0,y=1<<p-t,S=0;for(e.sort((function(a,n){return n.d==a.d?a.f-n.f:n.d-a.d})),c=0;c<e.length&&e[c].d>t;c++){var o=e[c].d;e[c].d=t,S+=y-(1<<p-o);}for(S>>>=p-t;S>0;)(o=e[c].d)<t?(e[c].d++,S-=1<<t-o-1):c++;for(;c>=0;c--)e[c].d==t&&S<0&&(e[c].d--,S++);S!=0&&console.log("debt left");},l.F._goodIndex=function(e,t){var p=0;return t[16|p]<=e&&(p|=16),t[8|p]<=e&&(p|=8),t[4|p]<=e&&(p|=4),t[2|p]<=e&&(p|=2),t[1|p]<=e&&(p|=1),p},l.F._writeLit=function(e,t,p,c){return l.F._putsF(p,c,t[e<<1]),c+t[1+(e<<1)]},l.F.inflate=function(e,t){var p=Uint8Array;if(e[0]==3&&e[1]==0)return t||new p(0);var c=l.F,y=c._bitsF,S=c._bitsE,o=c._decodeTiny,a=c.makeCodes,n=c.codes2map,h=c._get17,v=c.U,C=t==null;C&&(t=new p(e.length>>>2<<3));for(var M,I,B=0,k=0,L=0,R=0,g=0,U=0,f=0,u=0,_=0;B==0;)if(B=y(e,_,1),k=y(e,_+1,2),_+=3,k!=0){if(C&&(t=l.F._check(t,u+(1<<17))),k==1&&(M=v.flmap,I=v.fdmap,U=511,f=31),k==2){L=S(e,_,5)+257,R=S(e,_+5,5)+1,g=S(e,_+10,4)+4,_+=14;for(var s=0;s<38;s+=2)v.itree[s]=0,v.itree[s+1]=0;var A=1;for(s=0;s<g;s++){var b=S(e,_+3*s,3);v.itree[1+(v.ordr[s]<<1)]=b,b>A&&(A=b);}_+=3*g,a(v.itree,A),n(v.itree,A,v.imap),M=v.lmap,I=v.dmap,_=o(v.imap,(1<<A)-1,L+R,e,_,v.ttree);var w=c._copyOut(v.ttree,0,L,v.ltree);U=(1<<w)-1;var T=c._copyOut(v.ttree,L,R,v.dtree);f=(1<<T)-1,a(v.ltree,w),n(v.ltree,w,M),a(v.dtree,T),n(v.dtree,T,I);}for(;;){var m=M[h(e,_)&U];_+=15&m;var d=m>>>4;if(!(d>>>8))t[u++]=d;else {if(d==256)break;var P=u+d-254;if(d>264){var x=v.ldef[d-257];P=u+(x>>>3)+S(e,_,7&x),_+=7&x;}var O=I[h(e,_)&f];_+=15&O;var H=O>>>4,D=v.ddef[H],Q=(D>>>4)+y(e,_,15&D);for(_+=15&D,C&&(t=l.F._check(t,u+(1<<17)));u<P;)t[u]=t[u++-Q],t[u]=t[u++-Q],t[u]=t[u++-Q],t[u]=t[u++-Q];u=P;}}}else {(7&_)!=0&&(_+=8-(7&_));var N=4+(_>>>3),F=e[N-4]|e[N-3]<<8;C&&(t=l.F._check(t,u+F)),t.set(new p(e.buffer,e.byteOffset+N,F),u),_=N+F<<3,u+=F;}return t.length==u?t:t.slice(0,u)},l.F._check=function(e,t){var p=e.length;if(t<=p)return e;var c=new Uint8Array(Math.max(p<<1,t));return c.set(e,0),c},l.F._decodeTiny=function(e,t,p,c,y,S){for(var o=l.F._bitsE,a=l.F._get17,n=0;n<p;){var h=e[a(c,y)&t];y+=15&h;var v=h>>>4;if(v<=15)S[n]=v,n++;else {var C=0,M=0;v==16?(M=3+o(c,y,2),y+=2,C=S[n-1]):v==17?(M=3+o(c,y,3),y+=3):v==18&&(M=11+o(c,y,7),y+=7);for(var I=n+M;n<I;)S[n]=C,n++;}}return y},l.F._copyOut=function(e,t,p,c){for(var y=0,S=0,o=c.length>>>1;S<p;){var a=e[S+t];c[S<<1]=0,c[1+(S<<1)]=a,a>y&&(y=a),S++;}for(;S<o;)c[S<<1]=0,c[1+(S<<1)]=0,S++;return y},l.F.makeCodes=function(e,t){for(var p,c,y,S,o=l.F.U,a=e.length,n=o.bl_count,h=0;h<=t;h++)n[h]=0;for(h=1;h<a;h+=2)n[e[h]]++;var v=o.next_code;for(p=0,n[0]=0,c=1;c<=t;c++)p=p+n[c-1]<<1,v[c]=p;for(y=0;y<a;y+=2)(S=e[y+1])!=0&&(e[y]=v[S],v[S]++);},l.F.codes2map=function(e,t,p){for(var c=e.length,y=l.F.U.rev15,S=0;S<c;S+=2)if(e[S+1]!=0)for(var o=S>>1,a=e[S+1],n=o<<4|a,h=t-a,v=e[S]<<h,C=v+(1<<h);v!=C;)p[y[v]>>>15-t]=n,v++;},l.F.revCodes=function(e,t){for(var p=l.F.U.rev15,c=15-t,y=0;y<e.length;y+=2){var S=e[y]<<t-e[y+1];e[y]=p[S]>>>c;}},l.F._putsE=function(e,t,p){p<<=7&t;var c=t>>>3;e[c]|=p,e[c+1]|=p>>>8;},l.F._putsF=function(e,t,p){p<<=7&t;var c=t>>>3;e[c]|=p,e[c+1]|=p>>>8,e[c+2]|=p>>>16;},l.F._bitsE=function(e,t,p){return (e[t>>>3]|e[1+(t>>>3)]<<8)>>>(7&t)&(1<<p)-1},l.F._bitsF=function(e,t,p){return (e[t>>>3]|e[1+(t>>>3)]<<8|e[2+(t>>>3)]<<16)>>>(7&t)&(1<<p)-1},l.F._get17=function(e,t){return (e[t>>>3]|e[1+(t>>>3)]<<8|e[2+(t>>>3)]<<16)>>>(7&t)},l.F._get25=function(e,t){return (e[t>>>3]|e[1+(t>>>3)]<<8|e[2+(t>>>3)]<<16|e[3+(t>>>3)]<<24)>>>(7&t)},l.F.U=(r=Uint16Array,E=Uint32Array,{next_code:new r(16),bl_count:new r(16),ordr:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],of0:[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,999,999,999],exb:[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0],ldef:new r(32),df0:[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,65535,65535],dxb:[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0],ddef:new E(32),flmap:new r(512),fltree:[],fdmap:new r(32),fdtree:[],lmap:new r(32768),ltree:[],ttree:[],dmap:new r(32768),dtree:[],imap:new r(512),itree:[],rev15:new r(32768),lhst:new E(286),dhst:new E(30),ihst:new E(19),lits:new E(15e3),strt:new r(65536),prev:new r(32768)}),(function(){for(var e=l.F.U,t=0;t<32768;t++){var p=t;p=(4278255360&(p=(4042322160&(p=(3435973836&(p=(2863311530&p)>>>1|(1431655765&p)<<1))>>>2|(858993459&p)<<2))>>>4|(252645135&p)<<4))>>>8|(16711935&p)<<8,e.rev15[t]=(p>>>16|p<<16)>>>17;}function c(y,S,o){for(;S--!=0;)y.push(0,o);}for(t=0;t<32;t++)e.ldef[t]=e.of0[t]<<3|e.exb[t],e.ddef[t]=e.df0[t]<<4|e.dxb[t];c(e.fltree,144,8),c(e.fltree,112,9),c(e.fltree,24,7),c(e.fltree,8,8),l.F.makeCodes(e.fltree,9),l.F.codes2map(e.fltree,9,e.flmap),l.F.revCodes(e.fltree,9),c(e.fdtree,32,5),l.F.makeCodes(e.fdtree,5),l.F.codes2map(e.fdtree,5,e.fdmap),l.F.revCodes(e.fdtree,5),c(e.itree,19,0),c(e.ltree,286,0),c(e.dtree,30,0),c(e.ttree,320,0);})();})();var Cn=Tn({__proto__:null,default:$e},[$e]),pe=(function(){var i={nextZero(o,a){for(;o[a]!=0;)a++;return a},readUshort:(o,a)=>o[a]<<8|o[a+1],writeUshort(o,a,n){o[a]=n>>8&255,o[a+1]=255&n;},readUint:(o,a)=>16777216*o[a]+(o[a+1]<<16|o[a+2]<<8|o[a+3]),writeUint(o,a,n){o[a]=n>>24&255,o[a+1]=n>>16&255,o[a+2]=n>>8&255,o[a+3]=255&n;},readASCII(o,a,n){let h="";for(let v=0;v<n;v++)h+=String.fromCharCode(o[a+v]);return h},writeASCII(o,a,n){for(let h=0;h<n.length;h++)o[a+h]=n.charCodeAt(h);},readBytes(o,a,n){let h=[];for(let v=0;v<n;v++)h.push(o[a+v]);return h},pad:o=>o.length<2?`0${o}`:o,readUTF8(o,a,n){let h,v="";for(let C=0;C<n;C++)v+=`%${i.pad(o[a+C].toString(16))}`;try{h=decodeURIComponent(v);}catch{return i.readASCII(o,a,n)}return h}};function r(o,a,n,h){let v=a*n,C=t(h),M=Math.ceil(a*C/8),I=new Uint8Array(4*v),B=new Uint32Array(I.buffer),{ctype:k}=h,{depth:L}=h,R=i.readUshort;if(k==6){let x=v<<2;if(L==8)for(var g=0;g<x;g+=4)I[g]=o[g],I[g+1]=o[g+1],I[g+2]=o[g+2],I[g+3]=o[g+3];if(L==16)for(g=0;g<x;g++)I[g]=o[g<<1];}else if(k==2){let x=h.tabs.tRNS;if(x==null){if(L==8)for(g=0;g<v;g++){var U=3*g;B[g]=255<<24|o[U+2]<<16|o[U+1]<<8|o[U];}if(L==16)for(g=0;g<v;g++)U=6*g,B[g]=255<<24|o[U+4]<<16|o[U+2]<<8|o[U];}else {var f=x[0];let O=x[1],H=x[2];if(L==8)for(g=0;g<v;g++){var u=g<<2;U=3*g,B[g]=255<<24|o[U+2]<<16|o[U+1]<<8|o[U],o[U]==f&&o[U+1]==O&&o[U+2]==H&&(I[u+3]=0);}if(L==16)for(g=0;g<v;g++)u=g<<2,U=6*g,B[g]=255<<24|o[U+4]<<16|o[U+2]<<8|o[U],R(o,U)==f&&R(o,U+2)==O&&R(o,U+4)==H&&(I[u+3]=0);}}else if(k==3){let x=h.tabs.PLTE,O=h.tabs.tRNS,H=O?O.length:0;if(L==1)for(var _=0;_<n;_++){var s=_*M,A=_*a;for(g=0;g<a;g++){u=A+g<<2;var b=3*(w=o[s+(g>>3)]>>7-((7&g)<<0)&1);I[u]=x[b],I[u+1]=x[b+1],I[u+2]=x[b+2],I[u+3]=w<H?O[w]:255;}}if(L==2)for(_=0;_<n;_++)for(s=_*M,A=_*a,g=0;g<a;g++)u=A+g<<2,b=3*(w=o[s+(g>>2)]>>6-((3&g)<<1)&3),I[u]=x[b],I[u+1]=x[b+1],I[u+2]=x[b+2],I[u+3]=w<H?O[w]:255;if(L==4)for(_=0;_<n;_++)for(s=_*M,A=_*a,g=0;g<a;g++)u=A+g<<2,b=3*(w=o[s+(g>>1)]>>4-((1&g)<<2)&15),I[u]=x[b],I[u+1]=x[b+1],I[u+2]=x[b+2],I[u+3]=w<H?O[w]:255;if(L==8)for(g=0;g<v;g++){var w;u=g<<2,b=3*(w=o[g]),I[u]=x[b],I[u+1]=x[b+1],I[u+2]=x[b+2],I[u+3]=w<H?O[w]:255;}}else if(k==4){if(L==8)for(g=0;g<v;g++){u=g<<2;var T=o[m=g<<1];I[u]=T,I[u+1]=T,I[u+2]=T,I[u+3]=o[m+1];}if(L==16)for(g=0;g<v;g++){var m;u=g<<2,T=o[m=g<<2],I[u]=T,I[u+1]=T,I[u+2]=T,I[u+3]=o[m+2];}}else if(k==0)for(f=h.tabs.tRNS?h.tabs.tRNS:-1,_=0;_<n;_++){let x=_*M,O=_*a;if(L==1)for(var d=0;d<a;d++){var P=(T=255*(o[x+(d>>>3)]>>>7-(7&d)&1))==255*f?0:255;B[O+d]=P<<24|T<<16|T<<8|T;}else if(L==2)for(d=0;d<a;d++)P=(T=85*(o[x+(d>>>2)]>>>6-((3&d)<<1)&3))==85*f?0:255,B[O+d]=P<<24|T<<16|T<<8|T;else if(L==4)for(d=0;d<a;d++)P=(T=17*(o[x+(d>>>1)]>>>4-((1&d)<<2)&15))==17*f?0:255,B[O+d]=P<<24|T<<16|T<<8|T;else if(L==8)for(d=0;d<a;d++)P=(T=o[x+d])==f?0:255,B[O+d]=P<<24|T<<16|T<<8|T;else if(L==16)for(d=0;d<a;d++)T=o[x+(d<<1)],P=R(o,x+(d<<1))==f?0:255,B[O+d]=P<<24|T<<16|T<<8|T;}return I}function E(o,a,n,h){let v=t(o),C=Math.ceil(n*v/8),M=new Uint8Array((C+1+o.interlace)*h);return a=o.tabs.CgBI?e(a,M):l(a,M),o.interlace==0?a=p(a,o,0,n,h):o.interlace==1&&(a=(function(B,k){let L=k.width,R=k.height,g=t(k),U=g>>3,f=Math.ceil(L*g/8),u=new Uint8Array(R*f),_=0,s=[0,0,4,0,2,0,1],A=[0,4,0,2,0,1,0],b=[8,8,8,4,4,2,2],w=[8,8,4,4,2,2,1],T=0;for(;T<7;){let d=b[T],P=w[T],x=0,O=0,H=s[T];for(;H<R;)H+=d,O++;let D=A[T];for(;D<L;)D+=P,x++;let Q=Math.ceil(x*g/8);p(B,k,_,x,O);let N=0,F=s[T];for(;F<R;){let $=A[T],K=_+N*Q<<3;for(;$<L;){var m;if(g==1&&(m=(m=B[K>>3])>>7-(7&K)&1,u[F*f+($>>3)]|=m<<7-((7&$)<<0)),g==2&&(m=(m=B[K>>3])>>6-(7&K)&3,u[F*f+($>>2)]|=m<<6-((3&$)<<1)),g==4&&(m=(m=B[K>>3])>>4-(7&K)&15,u[F*f+($>>1)]|=m<<4-((1&$)<<2)),g>=8){let V=F*f+$*U;for(let z=0;z<U;z++)u[V+z]=B[(K>>3)+z];}K+=g,$+=P;}N++,F+=d;}x*O!=0&&(_+=O*(1+Q)),T+=1;}return u})(a,o)),a}function l(o,a){return e(new Uint8Array(o.buffer,2,o.length-6),a)}var e=(function(){let o={H:{}};return o.H.N=function(a,n){let h=Uint8Array,v,C,M=0,I=0,B=0,k=0,L=0,R=0,g=0,U=0,f=0;if(a[0]==3&&a[1]==0)return n||new h(0);let u=o.H,_=u.b,s=u.e,A=u.R,b=u.n,w=u.A,T=u.Z,m=u.m,d=n==null;for(d&&(n=new h(a.length>>>2<<5));M==0;)if(M=_(a,f,1),I=_(a,f+1,2),f+=3,I!=0){if(d&&(n=o.H.W(n,U+(1<<17))),I==1&&(v=m.J,C=m.h,R=511,g=31),I==2){B=s(a,f,5)+257,k=s(a,f+5,5)+1,L=s(a,f+10,4)+4,f+=14;let x=1;for(var P=0;P<38;P+=2)m.Q[P]=0,m.Q[P+1]=0;for(P=0;P<L;P++){let D=s(a,f+3*P,3);m.Q[1+(m.X[P]<<1)]=D,D>x&&(x=D);}f+=3*L,b(m.Q,x),w(m.Q,x,m.u),v=m.w,C=m.d,f=A(m.u,(1<<x)-1,B+k,a,f,m.v);let O=u.V(m.v,0,B,m.C);R=(1<<O)-1;let H=u.V(m.v,B,k,m.D);g=(1<<H)-1,b(m.C,O),w(m.C,O,v),b(m.D,H),w(m.D,H,C);}for(;;){let x=v[T(a,f)&R];f+=15&x;let O=x>>>4;if(!(O>>>8))n[U++]=O;else {if(O==256)break;{let H=U+O-254;if(O>264){let $=m.q[O-257];H=U+($>>>3)+s(a,f,7&$),f+=7&$;}let D=C[T(a,f)&g];f+=15&D;let Q=D>>>4,N=m.c[Q],F=(N>>>4)+_(a,f,15&N);for(f+=15&N;U<H;)n[U]=n[U++-F],n[U]=n[U++-F],n[U]=n[U++-F],n[U]=n[U++-F];U=H;}}}}else {(7&f)!=0&&(f+=8-(7&f));let x=4+(f>>>3),O=a[x-4]|a[x-3]<<8;d&&(n=o.H.W(n,U+O)),n.set(new h(a.buffer,a.byteOffset+x,O),U),f=x+O<<3,U+=O;}return n.length==U?n:n.slice(0,U)},o.H.W=function(a,n){let h=a.length;if(n<=h)return a;let v=new Uint8Array(h<<1);return v.set(a,0),v},o.H.R=function(a,n,h,v,C,M){let I=o.H.e,B=o.H.Z,k=0;for(;k<h;){let L=a[B(v,C)&n];C+=15&L;let R=L>>>4;if(R<=15)M[k]=R,k++;else {let g=0,U=0;R==16?(U=3+I(v,C,2),C+=2,g=M[k-1]):R==17?(U=3+I(v,C,3),C+=3):R==18&&(U=11+I(v,C,7),C+=7);let f=k+U;for(;k<f;)M[k]=g,k++;}}return C},o.H.V=function(a,n,h,v){let C=0,M=0,I=v.length>>>1;for(;M<h;){let B=a[M+n];v[M<<1]=0,v[1+(M<<1)]=B,B>C&&(C=B),M++;}for(;M<I;)v[M<<1]=0,v[1+(M<<1)]=0,M++;return C},o.H.n=function(a,n){let h=o.H.m,v=a.length,C,M,I,B,k=h.j;for(var L=0;L<=n;L++)k[L]=0;for(L=1;L<v;L+=2)k[a[L]]++;let R=h.K;for(C=0,k[0]=0,M=1;M<=n;M++)C=C+k[M-1]<<1,R[M]=C;for(I=0;I<v;I+=2)B=a[I+1],B!=0&&(a[I]=R[B],R[B]++);},o.H.A=function(a,n,h){let v=a.length,C=o.H.m.r;for(let M=0;M<v;M+=2)if(a[M+1]!=0){let I=M>>1,B=a[M+1],k=I<<4|B,L=n-B,R=a[M]<<L,g=R+(1<<L);for(;R!=g;)h[C[R]>>>15-n]=k,R++;}},o.H.l=function(a,n){let h=o.H.m.r,v=15-n;for(let C=0;C<a.length;C+=2){let M=a[C]<<n-a[C+1];a[C]=h[M]>>>v;}},o.H.M=function(a,n,h){h<<=7&n;let v=n>>>3;a[v]|=h,a[v+1]|=h>>>8;},o.H.I=function(a,n,h){h<<=7&n;let v=n>>>3;a[v]|=h,a[v+1]|=h>>>8,a[v+2]|=h>>>16;},o.H.e=function(a,n,h){return (a[n>>>3]|a[1+(n>>>3)]<<8)>>>(7&n)&(1<<h)-1},o.H.b=function(a,n,h){return (a[n>>>3]|a[1+(n>>>3)]<<8|a[2+(n>>>3)]<<16)>>>(7&n)&(1<<h)-1},o.H.Z=function(a,n){return (a[n>>>3]|a[1+(n>>>3)]<<8|a[2+(n>>>3)]<<16)>>>(7&n)},o.H.i=function(a,n){return (a[n>>>3]|a[1+(n>>>3)]<<8|a[2+(n>>>3)]<<16|a[3+(n>>>3)]<<24)>>>(7&n)},o.H.m=(function(){let a=Uint16Array,n=Uint32Array;return {K:new a(16),j:new a(16),X:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],S:[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,999,999,999],T:[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0],q:new a(32),p:[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,65535,65535],z:[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0],c:new n(32),J:new a(512),_:[],h:new a(32),$:[],w:new a(32768),C:[],v:[],d:new a(32768),D:[],u:new a(512),Q:[],r:new a(32768),s:new n(286),Y:new n(30),a:new n(19),t:new n(15e3),k:new a(65536),g:new a(32768)}})(),(function(){let a=o.H.m;for(var n=0;n<32768;n++){let v=n;v=(2863311530&v)>>>1|(1431655765&v)<<1,v=(3435973836&v)>>>2|(858993459&v)<<2,v=(4042322160&v)>>>4|(252645135&v)<<4,v=(4278255360&v)>>>8|(16711935&v)<<8,a.r[n]=(v>>>16|v<<16)>>>17;}function h(v,C,M){for(;C--!=0;)v.push(0,M);}for(n=0;n<32;n++)a.q[n]=a.S[n]<<3|a.T[n],a.c[n]=a.p[n]<<4|a.z[n];h(a._,144,8),h(a._,112,9),h(a._,24,7),h(a._,8,8),o.H.n(a._,9),o.H.A(a._,9,a.J),o.H.l(a._,9),h(a.$,32,5),o.H.n(a.$,5),o.H.A(a.$,5,a.h),o.H.l(a.$,5),h(a.Q,19,0),h(a.C,286,0),h(a.D,30,0),h(a.v,320,0);})(),o.H.N})();function t(o){return [1,null,3,1,2,null,4][o.ctype]*o.depth}function p(o,a,n,h,v){let C=t(a),M=Math.ceil(h*C/8),I,B;C=Math.ceil(C/8);let k=o[n],L=0;if(k>1&&(o[n]=[0,0,1][k-2]),k==3)for(L=C;L<M;L++)o[L+1]=o[L+1]+(o[L+1-C]>>>1)&255;for(let R=0;R<v;R++)if(I=n+R*M,B=I+R+1,k=o[B-1],L=0,k==0)for(;L<M;L++)o[I+L]=o[B+L];else if(k==1){for(;L<C;L++)o[I+L]=o[B+L];for(;L<M;L++)o[I+L]=o[B+L]+o[I+L-C];}else if(k==2)for(;L<M;L++)o[I+L]=o[B+L]+o[I+L-M];else if(k==3){for(;L<C;L++)o[I+L]=o[B+L]+(o[I+L-M]>>>1);for(;L<M;L++)o[I+L]=o[B+L]+(o[I+L-M]+o[I+L-C]>>>1);}else {for(;L<C;L++)o[I+L]=o[B+L]+c(0,o[I+L-M],0);for(;L<M;L++)o[I+L]=o[B+L]+c(o[I+L-C],o[I+L-M],o[I+L-C-M]);}return o}function c(o,a,n){let h=o+a-n,v=h-o,C=h-a,M=h-n;return v*v<=C*C&&v*v<=M*M?o:C*C<=M*M?a:n}function y(o,a,n){n.width=i.readUint(o,a),a+=4,n.height=i.readUint(o,a),a+=4,n.depth=o[a],a++,n.ctype=o[a],a++,n.compress=o[a],a++,n.filter=o[a],a++,n.interlace=o[a],a++;}function S(o,a,n,h,v,C,M,I,B){let k=Math.min(a,v),L=Math.min(n,C),R=0,g=0;for(let T=0;T<L;T++)for(let m=0;m<k;m++)if(M>=0&&I>=0?(R=T*a+m<<2,g=(I+T)*v+M+m<<2):(R=(-I+T)*a-M+m<<2,g=T*v+m<<2),B==0)h[g]=o[R],h[g+1]=o[R+1],h[g+2]=o[R+2],h[g+3]=o[R+3];else if(B==1){var U=o[R+3]*.00392156862745098,f=o[R]*U,u=o[R+1]*U,_=o[R+2]*U,s=h[g+3]*(1/255),A=h[g]*s,b=h[g+1]*s,w=h[g+2]*s;let d=1-U,P=U+s*d,x=P==0?0:1/P;h[g+3]=255*P,h[g+0]=(f+A*d)*x,h[g+1]=(u+b*d)*x,h[g+2]=(_+w*d)*x;}else if(B==2)U=o[R+3],f=o[R],u=o[R+1],_=o[R+2],s=h[g+3],A=h[g],b=h[g+1],w=h[g+2],U==s&&f==A&&u==b&&_==w?(h[g]=0,h[g+1]=0,h[g+2]=0,h[g+3]=0):(h[g]=f,h[g+1]=u,h[g+2]=_,h[g+3]=U);else if(B==3){if(U=o[R+3],f=o[R],u=o[R+1],_=o[R+2],s=h[g+3],A=h[g],b=h[g+1],w=h[g+2],U==s&&f==A&&u==b&&_==w)continue;if(U<220&&s>20)return false}return true}return {decode:function(a){let n=new Uint8Array(a),h=8,v=i,C=v.readUshort,M=v.readUint,I={tabs:{},frames:[]},B=new Uint8Array(n.length),k,L=0,R=0,g=[137,80,78,71,13,10,26,10];for(var U=0;U<8;U++)if(n[U]!=g[U])throw "The input is not a PNG file!";for(;h<n.length;){let T=v.readUint(n,h);h+=4;let m=v.readASCII(n,h,4);if(h+=4,m=="IHDR")y(n,h,I);else if(m=="iCCP"){for(var f=h;n[f]!=0;)f++;v.readASCII(n,h,f-h),n[f+1];let d=n.slice(f+2,h+T),P=null;try{P=l(d);}catch{P=e(d);}I.tabs[m]=P;}else if(m=="CgBI")I.tabs[m]=n.slice(h,h+4);else if(m=="IDAT"){for(U=0;U<T;U++)B[L+U]=n[h+U];L+=T;}else if(m=="acTL")I.tabs[m]={num_frames:M(n,h),num_plays:M(n,h+4)},k=new Uint8Array(n.length);else if(m=="fcTL"){R!=0&&((w=I.frames[I.frames.length-1]).data=E(I,k.slice(0,R),w.rect.width,w.rect.height),R=0);let d={x:M(n,h+12),y:M(n,h+16),width:M(n,h+4),height:M(n,h+8)},P=C(n,h+22);P=C(n,h+20)/(P==0?100:P);let x={rect:d,delay:Math.round(1e3*P),dispose:n[h+24],blend:n[h+25]};I.frames.push(x);}else if(m=="fdAT"){for(U=0;U<T-4;U++)k[R+U]=n[h+U+4];R+=T-4;}else if(m=="pHYs")I.tabs[m]=[v.readUint(n,h),v.readUint(n,h+4),n[h+8]];else if(m=="cHRM")for(I.tabs[m]=[],U=0;U<8;U++)I.tabs[m].push(v.readUint(n,h+4*U));else if(m=="tEXt"||m=="zTXt"){I.tabs[m]==null&&(I.tabs[m]={});var u=v.nextZero(n,h),_=v.readASCII(n,h,u-h),s=h+T-u-1;if(m=="tEXt")b=v.readASCII(n,u+1,s);else {var A=l(n.slice(u+2,u+2+s));b=v.readUTF8(A,0,A.length);}I.tabs[m][_]=b;}else if(m=="iTXt"){I.tabs[m]==null&&(I.tabs[m]={}),u=0,f=h,u=v.nextZero(n,f),_=v.readASCII(n,f,u-f);let d=n[f=u+1];var b;n[f+1],f+=2,u=v.nextZero(n,f),v.readASCII(n,f,u-f),f=u+1,u=v.nextZero(n,f),v.readUTF8(n,f,u-f),s=T-((f=u+1)-h),d==0?b=v.readUTF8(n,f,s):(A=l(n.slice(f,f+s)),b=v.readUTF8(A,0,A.length)),I.tabs[m][_]=b;}else if(m=="PLTE")I.tabs[m]=v.readBytes(n,h,T);else if(m=="hIST"){let d=I.tabs.PLTE.length/3;for(I.tabs[m]=[],U=0;U<d;U++)I.tabs[m].push(C(n,h+2*U));}else if(m=="tRNS")I.ctype==3?I.tabs[m]=v.readBytes(n,h,T):I.ctype==0?I.tabs[m]=C(n,h):I.ctype==2&&(I.tabs[m]=[C(n,h),C(n,h+2),C(n,h+4)]);else if(m=="gAMA")I.tabs[m]=v.readUint(n,h)/1e5;else if(m=="sRGB")I.tabs[m]=n[h];else if(m=="bKGD")I.ctype==0||I.ctype==4?I.tabs[m]=[C(n,h)]:I.ctype==2||I.ctype==6?I.tabs[m]=[C(n,h),C(n,h+2),C(n,h+4)]:I.ctype==3&&(I.tabs[m]=n[h]);else if(m=="IEND")break;h+=T,v.readUint(n,h),h+=4;}var w;return R!=0&&((w=I.frames[I.frames.length-1]).data=E(I,k.slice(0,R),w.rect.width,w.rect.height)),I.data=E(I,B,I.width,I.height),delete I.compress,delete I.interlace,delete I.filter,I},toRGBA8:function(a){let n=a.width,h=a.height;if(a.tabs.acTL==null)return [r(a.data,n,h,a).buffer];let v=[];a.frames[0].data==null&&(a.frames[0].data=a.data);let C=n*h*4,M=new Uint8Array(C),I=new Uint8Array(C),B=new Uint8Array(C);for(let L=0;L<a.frames.length;L++){let R=a.frames[L],g=R.rect.x,U=R.rect.y,f=R.rect.width,u=R.rect.height,_=r(R.data,f,u,a);if(L!=0)for(var k=0;k<C;k++)B[k]=M[k];if(R.blend==0?S(_,f,u,M,n,h,g,U,0):R.blend==1&&S(_,f,u,M,n,h,g,U,1),v.push(M.buffer.slice(0)),R.dispose!=0){if(R.dispose==1)S(I,f,u,M,n,h,g,U,0);else if(R.dispose==2)for(k=0;k<C;k++)M[k]=B[k];}}return v},_paeth:c,_copyTile:S,_bin:i}})();(function(){let{_copyTile:i}=pe,{_bin:r}=pe,E=pe._paeth;var l={table:(function(){let f=new Uint32Array(256);for(let u=0;u<256;u++){let _=u;for(let s=0;s<8;s++)1&_?_=3988292384^_>>>1:_>>>=1;f[u]=_;}return f})(),update(f,u,_,s){for(let A=0;A<s;A++)f=l.table[255&(f^u[_+A])]^f>>>8;return f},crc:(f,u,_)=>4294967295^l.update(4294967295,f,u,_)};function e(f,u,_,s){u[_]+=f[0]*s>>4,u[_+1]+=f[1]*s>>4,u[_+2]+=f[2]*s>>4,u[_+3]+=f[3]*s>>4;}function t(f){return Math.max(0,Math.min(255,f))}function p(f,u){let _=f[0]-u[0],s=f[1]-u[1],A=f[2]-u[2],b=f[3]-u[3];return _*_+s*s+A*A+b*b}function c(f,u,_,s,A,b,w){w==null&&(w=1);let T=s.length,m=[];for(var d=0;d<T;d++){let F=s[d];m.push([F>>>0&255,F>>>8&255,F>>>16&255,F>>>24&255]);}for(d=0;d<T;d++){let F=4294967295;for(var P=0,x=0;x<T;x++){var O=p(m[d],m[x]);x!=d&&O<F&&(F=O,P=x);}}let H=new Uint32Array(A.buffer),D=new Int16Array(u*_*4),Q=[0,8,2,10,12,4,14,6,3,11,1,9,15,7,13,5];for(d=0;d<Q.length;d++)Q[d]=255*((Q[d]+.5)/16-.5);for(let F=0;F<_;F++)for(let $=0;$<u;$++){var N;d=4*(F*u+$),w!=2?N=[t(f[d]+D[d]),t(f[d+1]+D[d+1]),t(f[d+2]+D[d+2]),t(f[d+3]+D[d+3])]:(O=Q[4*(3&F)+(3&$)],N=[t(f[d]+O),t(f[d+1]+O),t(f[d+2]+O),t(f[d+3]+O)]),P=0;let K=16777215;for(x=0;x<T;x++){let q=p(N,m[x]);q<K&&(K=q,P=x);}let V=m[P],z=[N[0]-V[0],N[1]-V[1],N[2]-V[2],N[3]-V[3]];w==1&&($!=u-1&&e(z,D,d+4,7),F!=_-1&&($!=0&&e(z,D,d+4*u-4,3),e(z,D,d+4*u,5),$!=u-1&&e(z,D,d+4*u+4,1))),b[d>>2]=P,H[d>>2]=s[P];}}function y(f,u,_,s,A){A==null&&(A={});let{crc:b}=l,w=r.writeUint,T=r.writeUshort,m=r.writeASCII,d=8,P=f.frames.length>1,x,O=false,H=33+(P?20:0);if(A.sRGB!=null&&(H+=13),A.pHYs!=null&&(H+=21),A.iCCP!=null&&(x=pako.deflate(A.iCCP),H+=21+x.length+4),f.ctype==3){for(var D=f.plte.length,Q=0;Q<D;Q++)f.plte[Q]>>>24!=255&&(O=true);H+=8+3*D+4+(O?8+1*D+4:0);}for(var N=0;N<f.frames.length;N++)P&&(H+=38),H+=(V=f.frames[N]).cimg.length+12,N!=0&&(H+=4);H+=12;let F=new Uint8Array(H),$=[137,80,78,71,13,10,26,10];for(Q=0;Q<8;Q++)F[Q]=$[Q];if(w(F,d,13),d+=4,m(F,d,"IHDR"),d+=4,w(F,d,u),d+=4,w(F,d,_),d+=4,F[d]=f.depth,d++,F[d]=f.ctype,d++,F[d]=0,d++,F[d]=0,d++,F[d]=0,d++,w(F,d,b(F,d-17,17)),d+=4,A.sRGB!=null&&(w(F,d,1),d+=4,m(F,d,"sRGB"),d+=4,F[d]=A.sRGB,d++,w(F,d,b(F,d-5,5)),d+=4),A.iCCP!=null){let z=13+x.length;w(F,d,z),d+=4,m(F,d,"iCCP"),d+=4,m(F,d,"ICC profile"),d+=11,d+=2,F.set(x,d),d+=x.length,w(F,d,b(F,d-(z+4),z+4)),d+=4;}if(A.pHYs!=null&&(w(F,d,9),d+=4,m(F,d,"pHYs"),d+=4,w(F,d,A.pHYs[0]),d+=4,w(F,d,A.pHYs[1]),d+=4,F[d]=A.pHYs[2],d++,w(F,d,b(F,d-13,13)),d+=4),P&&(w(F,d,8),d+=4,m(F,d,"acTL"),d+=4,w(F,d,f.frames.length),d+=4,w(F,d,A.loop!=null?A.loop:0),d+=4,w(F,d,b(F,d-12,12)),d+=4),f.ctype==3){for(w(F,d,3*(D=f.plte.length)),d+=4,m(F,d,"PLTE"),d+=4,Q=0;Q<D;Q++){let z=3*Q,q=f.plte[Q],G=255&q,W=q>>>8&255,ie=q>>>16&255;F[d+z+0]=G,F[d+z+1]=W,F[d+z+2]=ie;}if(d+=3*D,w(F,d,b(F,d-3*D-4,3*D+4)),d+=4,O){for(w(F,d,D),d+=4,m(F,d,"tRNS"),d+=4,Q=0;Q<D;Q++)F[d+Q]=f.plte[Q]>>>24&255;d+=D,w(F,d,b(F,d-D-4,D+4)),d+=4;}}let K=0;for(N=0;N<f.frames.length;N++){var V=f.frames[N];P&&(w(F,d,26),d+=4,m(F,d,"fcTL"),d+=4,w(F,d,K++),d+=4,w(F,d,V.rect.width),d+=4,w(F,d,V.rect.height),d+=4,w(F,d,V.rect.x),d+=4,w(F,d,V.rect.y),d+=4,T(F,d,s[N]),d+=2,T(F,d,1e3),d+=2,F[d]=V.dispose,d++,F[d]=V.blend,d++,w(F,d,b(F,d-30,30)),d+=4);let z=V.cimg;w(F,d,(D=z.length)+(N==0?0:4)),d+=4;let q=d;m(F,d,N==0?"IDAT":"fdAT"),d+=4,N!=0&&(w(F,d,K++),d+=4),F.set(z,d),d+=D,w(F,d,b(F,q,d-q)),d+=4;}return w(F,d,0),d+=4,m(F,d,"IEND"),d+=4,w(F,d,b(F,d-4,4)),d+=4,F.buffer}function S(f,u,_){for(let s=0;s<f.frames.length;s++){let A=f.frames[s];A.rect.width;let b=A.rect.height,w=new Uint8Array(b*A.bpl+b);A.cimg=h(A.img,b,A.bpp,A.bpl,w,u,_);}}function o(f,u,_,s,A){let b=A[0],w=A[1],T=A[2],m=A[3],d=A[4],P=A[5],x=6,O=8,H=255;for(var D=0;D<f.length;D++){let te=new Uint8Array(f[D]);for(var Q=te.length,N=0;N<Q;N+=4)H&=te[N+3];}let F=H!=255,$=(function(Y,J,ne,oe,j,ue){let ee=[];for(var X=0;X<Y.length;X++){let ce=new Uint8Array(Y[X]),he=new Uint32Array(ce.buffer);var le;let de=0,we=0,me=J,Ie=ne,Ye=oe?1:0;if(X!=0){let yn=ue||oe||X==1||ee[X-2].dispose!=0?1:2,Je=0,vt=1e9;for(let Le=0;Le<yn;Le++){var ge=new Uint8Array(Y[X-1-Le]);let An=new Uint32Array(Y[X-1-Le]),_e=J,be=ne,Oe=-1,De=-1;for(let Re=0;Re<ne;Re++)for(let Ce=0;Ce<J;Ce++)he[se=Re*J+Ce]!=An[se]&&(Ce<_e&&(_e=Ce),Ce>Oe&&(Oe=Ce),Re<be&&(be=Re),Re>De&&(De=Re));Oe==-1&&(_e=be=Oe=De=0),j&&((1&_e)==1&&_e--,(1&be)==1&&be--);let _t=(Oe-_e+1)*(De-be+1);_t<vt&&(vt=_t,Je=Le,de=_e,we=be,me=Oe-_e+1,Ie=De-be+1);}ge=new Uint8Array(Y[X-1-Je]),Je==1&&(ee[X-1].dispose=2),le=new Uint8Array(me*Ie*4),i(ge,J,ne,le,me,Ie,-de,-we,0),Ye=i(ce,J,ne,le,me,Ie,-de,-we,3)?1:0,Ye==1?n(ce,J,ne,le,{x:de,y:we,width:me,height:Ie}):i(ce,J,ne,le,me,Ie,-de,-we,0);}else le=ce.slice(0);ee.push({rect:{x:de,y:we,width:me,height:Ie},img:le,blend:Ye,dispose:0});}if(oe)for(X=0;X<ee.length;X++){if((Te=ee[X]).blend==1)continue;let ce=Te.rect,he=ee[X-1].rect,de=Math.min(ce.x,he.x),we=Math.min(ce.y,he.y),me={x:de,y:we,width:Math.max(ce.x+ce.width,he.x+he.width)-de,height:Math.max(ce.y+ce.height,he.y+he.height)-we};ee[X-1].dispose=1,X-1!=0&&a(Y,J,ne,ee,X-1,me,j),a(Y,J,ne,ee,X,me,j);}let He=0;if(Y.length!=1)for(var se=0;se<ee.length;se++){var Te;He+=(Te=ee[se]).rect.width*Te.rect.height;}return ee})(f,u,_,b,w,T),K={},V=[],z=[];if(s!=0){let te=[];for(N=0;N<$.length;N++)te.push($[N].img.buffer);let Y=(function(j){let ue=0;for(var ee=0;ee<j.length;ee++)ue+=j[ee].byteLength;let X=new Uint8Array(ue),le=0;for(ee=0;ee<j.length;ee++){let ge=new Uint8Array(j[ee]),He=ge.length;for(let se=0;se<He;se+=4){let Te=ge[se],ce=ge[se+1],he=ge[se+2],de=ge[se+3];de==0&&(Te=ce=he=0),X[le+se]=Te,X[le+se+1]=ce,X[le+se+2]=he,X[le+se+3]=de;}le+=He;}return X.buffer})(te),J=C(Y,s);for(N=0;N<J.plte.length;N++)V.push(J.plte[N].est.rgba);let ne=0;for(N=0;N<$.length;N++){let oe=(G=$[N]).img.length;var q=new Uint8Array(J.inds.buffer,ne>>2,oe>>2);z.push(q);let j=new Uint8Array(J.abuf,ne,oe);P&&c(G.img,G.rect.width,G.rect.height,V,j,q),G.img.set(j),ne+=oe;}}else for(D=0;D<$.length;D++){var G=$[D];let te=new Uint32Array(G.img.buffer);var W=G.rect.width;for(Q=te.length,q=new Uint8Array(Q),z.push(q),N=0;N<Q;N++){let Y=te[N];if(N!=0&&Y==te[N-1])q[N]=q[N-1];else if(N>W&&Y==te[N-W])q[N]=q[N-W];else {let J=K[Y];if(J==null&&(K[Y]=J=V.length,V.push(Y),V.length>=300))break;q[N]=J;}}}let ie=V.length;for(ie<=256&&d==0&&(O=ie<=2?1:ie<=4?2:ie<=16?4:8,O=Math.max(O,m)),D=0;D<$.length;D++){(G=$[D]).rect.x,G.rect.y,W=G.rect.width;let te=G.rect.height,Y=G.img;new Uint32Array(Y.buffer);let J=4*W,ne=4;if(ie<=256&&d==0){J=Math.ceil(O*W/8);var ae=new Uint8Array(J*te);let oe=z[D];for(let j=0;j<te;j++){N=j*J;let ue=j*W;if(O==8)for(var Z=0;Z<W;Z++)ae[N+Z]=oe[ue+Z];else if(O==4)for(Z=0;Z<W;Z++)ae[N+(Z>>1)]|=oe[ue+Z]<<4-4*(1&Z);else if(O==2)for(Z=0;Z<W;Z++)ae[N+(Z>>2)]|=oe[ue+Z]<<6-2*(3&Z);else if(O==1)for(Z=0;Z<W;Z++)ae[N+(Z>>3)]|=oe[ue+Z]<<7-1*(7&Z);}Y=ae,x=3,ne=1;}else if(F==0&&$.length==1){ae=new Uint8Array(W*te*3);let oe=W*te;for(N=0;N<oe;N++){let j=3*N,ue=4*N;ae[j]=Y[ue],ae[j+1]=Y[ue+1],ae[j+2]=Y[ue+2];}Y=ae,x=2,ne=3,J=3*W;}G.img=Y,G.bpl=J,G.bpp=ne;}return {ctype:x,depth:O,plte:V,frames:$}}function a(f,u,_,s,A,b,w){let T=Uint8Array,m=Uint32Array,d=new T(f[A-1]),P=new m(f[A-1]),x=A+1<f.length?new T(f[A+1]):null,O=new T(f[A]),H=new m(O.buffer),D=u,Q=_,N=-1,F=-1;for(let K=0;K<b.height;K++)for(let V=0;V<b.width;V++){let z=b.x+V,q=b.y+K,G=q*u+z,W=H[G];W==0||s[A-1].dispose==0&&P[G]==W&&(x==null||x[4*G+3]!=0)||(z<D&&(D=z),z>N&&(N=z),q<Q&&(Q=q),q>F&&(F=q));}N==-1&&(D=Q=N=F=0),w&&((1&D)==1&&D--,(1&Q)==1&&Q--),b={x:D,y:Q,width:N-D+1,height:F-Q+1};let $=s[A];$.rect=b,$.blend=1,$.img=new Uint8Array(b.width*b.height*4),s[A-1].dispose==0?(i(d,u,_,$.img,b.width,b.height,-b.x,-b.y,0),n(O,u,_,$.img,b)):i(O,u,_,$.img,b.width,b.height,-b.x,-b.y,0);}function n(f,u,_,s,A){i(f,u,_,s,A.width,A.height,-A.x,-A.y,2);}function h(f,u,_,s,A,b,w){let T=[],m,d=[0,1,2,3,4];b!=-1?d=[b]:(u*s>5e5||_==1)&&(d=[0]),w&&(m={level:0});let P=Cn;for(var x=0;x<d.length;x++){for(let D=0;D<u;D++)v(A,f,D,s,_,d[x]);T.push(P.deflate(A,m));}let O,H=1e9;for(x=0;x<T.length;x++)T[x].length<H&&(O=x,H=T[x].length);return T[O]}function v(f,u,_,s,A,b){let w=_*s,T=w+_;if(f[T]=b,T++,b==0)if(s<500)for(var m=0;m<s;m++)f[T+m]=u[w+m];else f.set(new Uint8Array(u.buffer,w,s),T);else if(b==1){for(m=0;m<A;m++)f[T+m]=u[w+m];for(m=A;m<s;m++)f[T+m]=u[w+m]-u[w+m-A]+256&255;}else if(_==0){for(m=0;m<A;m++)f[T+m]=u[w+m];if(b==2)for(m=A;m<s;m++)f[T+m]=u[w+m];if(b==3)for(m=A;m<s;m++)f[T+m]=u[w+m]-(u[w+m-A]>>1)+256&255;if(b==4)for(m=A;m<s;m++)f[T+m]=u[w+m]-E(u[w+m-A],0,0)+256&255;}else {if(b==2)for(m=0;m<s;m++)f[T+m]=u[w+m]+256-u[w+m-s]&255;if(b==3){for(m=0;m<A;m++)f[T+m]=u[w+m]+256-(u[w+m-s]>>1)&255;for(m=A;m<s;m++)f[T+m]=u[w+m]+256-(u[w+m-s]+u[w+m-A]>>1)&255;}if(b==4){for(m=0;m<A;m++)f[T+m]=u[w+m]+256-E(0,u[w+m-s],0)&255;for(m=A;m<s;m++)f[T+m]=u[w+m]+256-E(u[w+m-A],u[w+m-s],u[w+m-A-s])&255;}}}function C(f,u){let _=new Uint8Array(f),s=_.slice(0),A=new Uint32Array(s.buffer),b=M(s,u),w=b[0],T=b[1],m=_.length,d=new Uint8Array(m>>2),P;if(_.length<2e7)for(var x=0;x<m;x+=4)P=I(w,O=_[x]*(1/255),H=_[x+1]*(1/255),D=_[x+2]*(1/255),Q=_[x+3]*(1/255)),d[x>>2]=P.ind,A[x>>2]=P.est.rgba;else for(x=0;x<m;x+=4){var O=_[x]*.00392156862745098,H=_[x+1]*(1/255),D=_[x+2]*(1/255),Q=_[x+3]*(1/255);for(P=w;P.left;)P=B(P.est,O,H,D,Q)<=0?P.left:P.right;d[x>>2]=P.ind,A[x>>2]=P.est.rgba;}return {abuf:s.buffer,inds:d,plte:T}}function M(f,u,_){_==null&&(_=1e-4);let s=new Uint32Array(f.buffer),A={i0:0,i1:f.length,bst:null,est:null,tdst:0,left:null,right:null};A.bst=R(f,A.i0,A.i1),A.est=g(A.bst);let b=[A];for(;b.length<u;){let T=0,m=0;for(var w=0;w<b.length;w++)b[w].est.L>T&&(T=b[w].est.L,m=w);if(T<_)break;let d=b[m],P=k(f,s,d.i0,d.i1,d.est.e,d.est.eMq255);if(d.i0>=P||d.i1<=P){d.est.L=0;continue}let x={i0:d.i0,i1:P,bst:null,est:null,tdst:0,left:null,right:null};x.bst=R(f,x.i0,x.i1),x.est=g(x.bst);let O={i0:P,i1:d.i1,bst:null,est:null,tdst:0,left:null,right:null};for(O.bst={R:[],m:[],N:d.bst.N-x.bst.N},w=0;w<16;w++)O.bst.R[w]=d.bst.R[w]-x.bst.R[w];for(w=0;w<4;w++)O.bst.m[w]=d.bst.m[w]-x.bst.m[w];O.est=g(O.bst),d.left=x,d.right=O,b[m]=x,b.push(O);}for(b.sort(((T,m)=>m.bst.N-T.bst.N)),w=0;w<b.length;w++)b[w].ind=w;return [A,b]}function I(f,u,_,s,A){if(f.left==null)return f.tdst=(function(x,O,H,D,Q){let N=O-x[0],F=H-x[1],$=D-x[2],K=Q-x[3];return N*N+F*F+$*$+K*K})(f.est.q,u,_,s,A),f;let b=B(f.est,u,_,s,A),w=f.left,T=f.right;b>0&&(w=f.right,T=f.left);let m=I(w,u,_,s,A);if(m.tdst<=b*b)return m;let d=I(T,u,_,s,A);return d.tdst<m.tdst?d:m}function B(f,u,_,s,A){let{e:b}=f;return b[0]*u+b[1]*_+b[2]*s+b[3]*A-f.eMq}function k(f,u,_,s,A,b){for(s-=4;_<s;){for(;L(f,_,A)<=b;)_+=4;for(;L(f,s,A)>b;)s-=4;if(_>=s)break;let w=u[_>>2];u[_>>2]=u[s>>2],u[s>>2]=w,_+=4,s-=4;}for(;L(f,_,A)>b;)_-=4;return _+4}function L(f,u,_){return f[u]*_[0]+f[u+1]*_[1]+f[u+2]*_[2]+f[u+3]*_[3]}function R(f,u,_){let s=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],A=[0,0,0,0],b=_-u>>2;for(let w=u;w<_;w+=4){let T=f[w]*.00392156862745098,m=f[w+1]*(1/255),d=f[w+2]*(1/255),P=f[w+3]*(1/255);A[0]+=T,A[1]+=m,A[2]+=d,A[3]+=P,s[0]+=T*T,s[1]+=T*m,s[2]+=T*d,s[3]+=T*P,s[5]+=m*m,s[6]+=m*d,s[7]+=m*P,s[10]+=d*d,s[11]+=d*P,s[15]+=P*P;}return s[4]=s[1],s[8]=s[2],s[9]=s[6],s[12]=s[3],s[13]=s[7],s[14]=s[11],{R:s,m:A,N:b}}function g(f){let{R:u}=f,{m:_}=f,{N:s}=f,A=_[0],b=_[1],w=_[2],T=_[3],m=s==0?0:1/s,d=[u[0]-A*A*m,u[1]-A*b*m,u[2]-A*w*m,u[3]-A*T*m,u[4]-b*A*m,u[5]-b*b*m,u[6]-b*w*m,u[7]-b*T*m,u[8]-w*A*m,u[9]-w*b*m,u[10]-w*w*m,u[11]-w*T*m,u[12]-T*A*m,u[13]-T*b*m,u[14]-T*w*m,u[15]-T*T*m],P=d,x=U,O=[Math.random(),Math.random(),Math.random(),Math.random()],H=0,D=0;if(s!=0)for(let N=0;N<16&&(O=x.multVec(P,O),D=Math.sqrt(x.dot(O,O)),O=x.sml(1/D,O),!(N!=0&&Math.abs(D-H)<1e-9));N++)H=D;let Q=[A*m,b*m,w*m,T*m];return {Cov:d,q:Q,e:O,L:H,eMq255:x.dot(x.sml(255,Q),O),eMq:x.dot(O,Q),rgba:(Math.round(255*Q[3])<<24|Math.round(255*Q[2])<<16|Math.round(255*Q[1])<<8|Math.round(255*Q[0])<<0)>>>0}}var U={multVec:(f,u)=>[f[0]*u[0]+f[1]*u[1]+f[2]*u[2]+f[3]*u[3],f[4]*u[0]+f[5]*u[1]+f[6]*u[2]+f[7]*u[3],f[8]*u[0]+f[9]*u[1]+f[10]*u[2]+f[11]*u[3],f[12]*u[0]+f[13]*u[1]+f[14]*u[2]+f[15]*u[3]],dot:(f,u)=>f[0]*u[0]+f[1]*u[1]+f[2]*u[2]+f[3]*u[3],sml:(f,u)=>[f*u[0],f*u[1],f*u[2],f*u[3]]};pe.encode=function(u,_,s,A,b,w,T){A==null&&(A=0),T==null&&(T=false);let m=o(u,_,s,A,[false,false,false,0,T,false]);return S(m,-1),y(m,_,s,b,w)},pe.encodeLL=function(u,_,s,A,b,w,T,m){let d={ctype:0+(A==1?0:2)+(b==0?0:4),depth:w,frames:[]},P=(A+b)*w,x=P*_;for(let O=0;O<u.length;O++)d.frames.push({rect:{x:0,y:0,width:_,height:s},img:new Uint8Array(u[O]),blend:0,dispose:1,bpp:Math.ceil(P/8),bpl:Math.ceil(x/8)});return S(d,0,true),y(d,_,s,T,m)},pe.encode.compress=o,pe.encode.dither=c,pe.quantize=C,pe.quantize.getKDtree=M,pe.quantize.getNearest=I;})();var It={toArrayBuffer(i,r){let E=i.width,l=i.height,e=E<<2,t=i.getContext("2d").getImageData(0,0,E,l),p=new Uint32Array(t.data.buffer),c=(32*E+31)/32<<2,y=c*l,S=122+y,o=new ArrayBuffer(S),a=new DataView(o),n=1<<20,h,v,C,M,I=n,B=0,k=0,L=0;function R(f){a.setUint16(k,f,true),k+=2;}function g(f){a.setUint32(k,f,true),k+=4;}function U(f){k+=f;}R(19778),g(S),U(4),g(122),g(108),g(E),g(-l>>>0),R(1),R(32),g(3),g(y),g(2835),g(2835),U(8),g(16711680),g(65280),g(255),g(4278190080),g(1466527264),(function f(){for(;B<l&&I>0;){for(M=122+B*c,h=0;h<e;)I--,v=p[L++],C=v>>>24,a.setUint32(M+h,v<<8|C),h+=4;B++;}L<p.length?(I=n,setTimeout(f,It._dly)):r(o);})();},toBlob(i,r){this.toArrayBuffer(i,(E=>{r(new Blob([E],{type:"image/bmp"}));}));},_dly:9},fe={CHROME:"CHROME",FIREFOX:"FIREFOX",DESKTOP_SAFARI:"DESKTOP_SAFARI",IE:"IE",IOS:"IOS",ETC:"ETC"},xn={[fe.CHROME]:16384,[fe.FIREFOX]:11180,[fe.DESKTOP_SAFARI]:16384,[fe.IE]:8192,[fe.IOS]:4096,[fe.ETC]:8192},et=typeof globalThis.window<"u",Rt=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,We=et&&globalThis.window.cordova&&globalThis.window.cordova.require&&globalThis.window.cordova.require("cordova/modulemapper"),Un=(et||Rt)&&(We&&We.getOriginalSymbol(globalThis.window,"File")||typeof File<"u"&&File),Ct=(et||Rt)&&(We&&We.getOriginalSymbol(globalThis.window,"FileReader")||typeof globalThis.FileReader<"u"&&globalThis.FileReader);function tt(i,r,E=Date.now()){return new Promise((l=>{let e=i.split(","),t=e[0].match(/:(.*?);/)[1],p=globalThis.atob(e[1]),c=p.length,y=new Uint8Array(c);for(;c--;)y[c]=p.charCodeAt(c);let S=new Blob([y],{type:t});S.name=r,S.lastModified=E,l(S);}))}function xt(i){return new Promise(((r,E)=>{let l=new Ct;l.onload=()=>r(l.result),l.onerror=e=>E(e),l.readAsDataURL(i);}))}function Ut(i){return new Promise(((r,E)=>{let l=new globalThis.Image;l.onload=()=>r(l),l.onerror=e=>E(e),l.src=i;}))}function xe(){if(xe.cachedResult!==void 0)return xe.cachedResult;let i=fe.ETC,{userAgent:r}=navigator;return /Chrom(e|ium)/i.test(r)?i=fe.CHROME:/iP(ad|od|hone)/i.test(r)&&/WebKit/i.test(r)?i=fe.IOS:/Safari/i.test(r)?i=fe.DESKTOP_SAFARI:/Firefox/i.test(r)?i=fe.FIREFOX:(/MSIE/i.test(r)||globalThis.document.documentMode)&&(i=fe.IE),xe.cachedResult=i,xe.cachedResult}function Ot(i,r){let E=xe(),l=xn[E],e=i,t=r,p=e*t,c=e>t?t/e:e/t;for(;p>l*l;){let y=(l+e)/2,S=(l+t)/2;y<S?(t=S,e=S*c):(t=y*c,e=y),p=e*t;}return {width:e,height:t}}function Ve(i,r){let E,l;try{if(E=new OffscreenCanvas(i,r),l=E.getContext("2d"),l===null)throw new Error("getContext of OffscreenCanvas returns null")}catch{E=globalThis.document.createElement("canvas"),l=E.getContext("2d");}return E.width=i,E.height=r,[E,l]}function Pt(i,r){let{width:E,height:l}=Ot(i.width,i.height),[e,t]=Ve(E,l);return r&&/jpe?g/.test(r)&&(t.fillStyle="white",t.fillRect(0,0,e.width,e.height)),t.drawImage(i,0,0,e.width,e.height),e}function Qe(){return Qe.cachedResult!==void 0||(Qe.cachedResult=["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&typeof globalThis.document<"u"&&"ontouchend"in globalThis.document),Qe.cachedResult}function ze(i,r={}){return new Promise((function(E,l){let e,t;var p=function(){try{return t=Pt(e,r.fileType||i.type),E([e,t])}catch(y){return l(y)}},c=function(y){try{var S=function(o){try{throw o}catch(a){return l(a)}};try{let o;return xt(i).then((function(a){try{return o=a,Ut(o).then((function(n){try{return e=n,(function(){try{return p()}catch(h){return l(h)}})()}catch(h){return S(h)}}),S)}catch(n){return S(n)}}),S)}catch(o){S(o);}}catch(o){return l(o)}};try{if(Qe()||[fe.DESKTOP_SAFARI,fe.MOBILE_SAFARI].includes(xe()))throw new Error("Skip createImageBitmap on IOS and Safari");return createImageBitmap(i).then((function(y){try{return e=y,p()}catch{return c()}}),c)}catch{c();}}))}function Ge(i,r,E,l,e=1){return new Promise((function(t,p){let c;if(r==="image/png"){let a,n,h;return a=i.getContext("2d"),{data:n}=a.getImageData(0,0,i.width,i.height),h=pe.encode([n.buffer],i.width,i.height,4096*e),c=new Blob([h],{type:r}),c.name=E,c.lastModified=l,y.call(this)}{let a=function(){return y.call(this)};if(r==="image/bmp")return new Promise((n=>It.toBlob(i,n))).then(function(n){try{return c=n,c.name=E,c.lastModified=l,a.call(this)}catch(h){return p(h)}}.bind(this),p);{let n=function(){return a.call(this)};if(typeof OffscreenCanvas=="function"&&i instanceof OffscreenCanvas)return i.convertToBlob({type:r,quality:e}).then(function(h){try{return c=h,c.name=E,c.lastModified=l,n.call(this)}catch(v){return p(v)}}.bind(this),p);{let h;return h=i.toDataURL(r,e),tt(h,E,l).then(function(v){try{return c=v,n.call(this)}catch(C){return p(C)}}.bind(this),p)}}}function y(){return t(c)}}))}function ye(i){i.width=0,i.height=0;}function Pe(){return new Promise((function(i,r){let l,e,t,p;return Pe.cachedResult!==void 0?i(Pe.cachedResult):(tt("data:image/jpeg;base64,/9j/4QAiRXhpZgAATU0AKgAAAAgAAQESAAMAAAABAAYAAAAAAAD/2wCEAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAf/AABEIAAEAAgMBEQACEQEDEQH/xABKAAEAAAAAAAAAAAAAAAAAAAALEAEAAAAAAAAAAAAAAAAAAAAAAQEAAAAAAAAAAAAAAAAAAAAAEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwA/8H//2Q==","test.jpg",Date.now()).then((function(c){try{return l=c,ze(l).then((function(y){try{return e=y[1],Ge(e,l.type,l.name,l.lastModified).then((function(S){try{return t=S,ye(e),ze(t).then((function(o){try{return p=o[0],Pe.cachedResult=p.width===1&&p.height===2,i(Pe.cachedResult)}catch(a){return r(a)}}),r)}catch(o){return r(o)}}),r)}catch(S){return r(S)}}),r)}catch(y){return r(y)}}),r))}))}function Mt(i){return new Promise(((r,E)=>{let l=new Ct;l.onload=e=>{let t=new DataView(e.target.result);if(t.getUint16(0,false)!=65496)return r(-2);let p=t.byteLength,c=2;for(;c<p;){if(t.getUint16(c+2,false)<=8)return r(-1);let y=t.getUint16(c,false);if(c+=2,y==65505){if(t.getUint32(c+=2,false)!=1165519206)return r(-1);let S=t.getUint16(c+=6,false)==18761;c+=t.getUint32(c+4,S);let o=t.getUint16(c,S);c+=2;for(let a=0;a<o;a++)if(t.getUint16(c+12*a,S)==274)return r(t.getUint16(c+12*a+8,S))}else {if((65280&y)!=65280)break;c+=t.getUint16(c,false);}}return r(-1)},l.onerror=e=>E(e),l.readAsArrayBuffer(i);}))}function Lt(i,r){let{width:E}=i,{height:l}=i,{maxWidthOrHeight:e}=r,t,p=i;return isFinite(e)&&(E>e||l>e)&&([p,t]=Ve(E,l),E>l?(p.width=e,p.height=l/E*e):(p.width=E/l*e,p.height=e),t.drawImage(i,0,0,p.width,p.height),ye(i)),p}function Dt(i,r){let{width:E}=i,{height:l}=i,[e,t]=Ve(E,l);switch(r>4&&r<9?(e.width=l,e.height=E):(e.width=E,e.height=l),r){case 2:t.transform(-1,0,0,1,E,0);break;case 3:t.transform(-1,0,0,-1,E,l);break;case 4:t.transform(1,0,0,-1,0,l);break;case 5:t.transform(0,1,1,0,0,0);break;case 6:t.transform(0,1,-1,0,l,0);break;case 7:t.transform(0,-1,-1,0,l,E);break;case 8:t.transform(0,-1,1,0,0,E);}return t.drawImage(i,0,0,E,l),ye(i),e}function St(i,r,E=0){return new Promise((function(l,e){let t,p,c,y,S,o,a,n,h,v,C,M,I,B,k,L,R,g,U,f;function u(s=5){if(r.signal&&r.signal.aborted)throw r.signal.reason;t+=s,r.onProgress(Math.min(t,100));}function _(s){if(r.signal&&r.signal.aborted)throw r.signal.reason;t=Math.min(Math.max(s,t),100),r.onProgress(t);}return t=E,p=r.maxIteration||10,c=1024*r.maxSizeMB*1024,u(),ze(i,r).then(function(s){try{return [,y]=s,u(),S=Lt(y,r),u(),new Promise((function(A,b){var w;if(!(w=r.exifOrientation))return Mt(i).then(function(m){try{return w=m,T.call(this)}catch(d){return b(d)}}.bind(this),b);function T(){return A(w)}return T.call(this)})).then(function(A){try{return o=A,u(),Pe().then(function(b){try{return a=b?S:Dt(S,o),u(),n=r.initialQuality||1,h=r.fileType||i.type,Ge(a,h,i.name,i.lastModified,n).then(function(w){try{{let P=function(){if(p--&&(k>c||k>I)){let O,H;return O=f?.95*U.width:U.width,H=f?.95*U.height:U.height,[R,g]=Ve(O,H),g.drawImage(U,0,0,O,H),n*=h==="image/png"?.85:.95,Ge(R,h,i.name,i.lastModified,n).then((function(D){try{return L=D,ye(U),U=R,k=L.size,_(Math.min(99,Math.floor((B-k)/(B-c)*100))),P}catch(Q){return e(Q)}}),e)}return [1]},x=function(){return ye(U),ye(R),ye(S),ye(a),ye(y),_(100),l(L)};var m=P,d=x;if(v=w,u(),C=v.size>c,M=v.size>i.size,!C&&!M)return _(100),l(v);var T;return I=i.size,B=v.size,k=B,U=a,f=!r.alwaysKeepResolution&&C,(T=function(O){for(;O;){if(O.then)return void O.then(T,e);try{if(O.pop){if(O.length)return O.pop()?x.call(this):O;O=P;}else O=O.call(this);}catch(H){return e(H)}}}.bind(this))(P)}}catch(P){return e(P)}}.bind(this),e)}catch(w){return e(w)}}.bind(this),e)}catch(b){return e(b)}}.bind(this),e)}catch(A){return e(A)}}.bind(this),e)}))}var On=`
6
6
  let scriptImported = false
7
7
  self.addEventListener('message', async (e) => {
8
8
  const { file, id, imageCompressionLibUrl, options } = e.data
@@ -21,7 +21,7 @@ self.addEventListener('message', async (e) => {
21
21
  self.postMessage({ error: e.message + '\\n' + e.stack, id })
22
22
  }
23
23
  })
24
- `,je;function Pn(i,r){return new Promise(((E,l)=>{je||(je=(function(p){let c=[];return c.push(p),URL.createObjectURL(new Blob(c))})(On));let e=new Worker(je);e.addEventListener("message",(function(p){if(r.signal&&r.signal.aborted)e.terminate();else if(p.data.progress===void 0){if(p.data.error)return l(new Error(p.data.error)),void e.terminate();E(p.data.file),e.terminate();}else r.onProgress(p.data.progress);})),e.addEventListener("error",l),r.signal&&r.signal.addEventListener("abort",(()=>{l(r.signal.reason),e.terminate();})),e.postMessage({file:i,imageCompressionLibUrl:r.libURL,options:{...r,onProgress:void 0,signal:void 0}});}))}function re(i,r){return new Promise((function(E,l){let e,t,p,c,w,S;if(e={...r},p=0,{onProgress:c}=e,e.maxSizeMB=e.maxSizeMB||Number.POSITIVE_INFINITY,w=typeof e.useWebWorker!="boolean"||e.useWebWorker,delete e.useWebWorker,e.onProgress=h=>{p=h,typeof c=="function"&&c(p);},!(i instanceof Blob||i instanceof Un))return l(new Error("The file given is not an instance of Blob or File"));if(!/^image/.test(i.type))return l(new Error("The file given is not an image"));if(S=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,!w||typeof Worker!="function"||S)return St(i,e).then(function(h){try{return t=h,n.call(this)}catch(v){return l(v)}}.bind(this),l);var o=function(){try{return n.call(this)}catch(h){return l(h)}}.bind(this),a=function(h){try{return St(i,e).then((function(v){try{return t=v,o()}catch(C){return l(C)}}),l)}catch(v){return l(v)}};try{return e.libURL=e.libURL||"https://cdn.jsdelivr.net/npm/browser-image-compression@2.0.2/dist/browser-image-compression.js",Pn(i,e).then((function(h){try{return t=h,o()}catch{return a()}}),a)}catch{a();}function n(){try{t.name=i.name,t.lastModified=i.lastModified;}catch{}try{e.preserveExif&&i.type==="image/jpeg"&&(!e.fileType||e.fileType&&e.fileType===i.type)&&(t=Tt(i,t));}catch{}return E(t)}}))}re.getDataUrlFromFile=xt,re.getFilefromDataUrl=tt,re.loadImage=Ut,re.drawImageInCanvas=Pt,re.drawFileInCanvas=ze,re.canvasToFile=Ge,re.getExifOrientation=Mt,re.handleMaxWidthOrHeight=Lt,re.followExifOrientation=Dt,re.cleanupCanvasMemory=ye,re.isAutoOrientationInBrowser=Pe,re.approximateBelowMaximumCanvasSizeOfBrowser=Ot,re.copyExifWithoutOrientation=Tt,re.getBrowserName=xe,re.version="2.0.2";var gn=Et(Ft()),mn=Et(on());function cr(i){let r=globalThis.document.getElementById("__AUTH_DRAWER"),E=globalThis.document.querySelector(".__drawer_container"),l=globalThis.document.querySelector(".__auth_close_button");r&&l&&E?.classList.contains("__hidden")&&(E.classList.remove("__hidden"),r.src=i,r.onload=()=>{l.classList.remove("__hidden"),r.classList.remove("__hidden"),r.contentWindow?.focus();});}function an(){if(globalThis.document.getElementById("__AUTH_DRAWER"))return;let i=globalThis.document.createElement("style");i.innerHTML=`
24
+ `,je;function Pn(i,r){return new Promise(((E,l)=>{je||(je=(function(p){let c=[];return c.push(p),URL.createObjectURL(new Blob(c))})(On));let e=new Worker(je);e.addEventListener("message",(function(p){if(r.signal&&r.signal.aborted)e.terminate();else if(p.data.progress===void 0){if(p.data.error)return l(new Error(p.data.error)),void e.terminate();E(p.data.file),e.terminate();}else r.onProgress(p.data.progress);})),e.addEventListener("error",l),r.signal&&r.signal.addEventListener("abort",(()=>{l(r.signal.reason),e.terminate();})),e.postMessage({file:i,imageCompressionLibUrl:r.libURL,options:{...r,onProgress:void 0,signal:void 0}});}))}function re(i,r){return new Promise((function(E,l){let e,t,p,c,y,S;if(e={...r},p=0,{onProgress:c}=e,e.maxSizeMB=e.maxSizeMB||Number.POSITIVE_INFINITY,y=typeof e.useWebWorker!="boolean"||e.useWebWorker,delete e.useWebWorker,e.onProgress=h=>{p=h,typeof c=="function"&&c(p);},!(i instanceof Blob||i instanceof Un))return l(new Error("The file given is not an instance of Blob or File"));if(!/^image/.test(i.type))return l(new Error("The file given is not an image"));if(S=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,!y||typeof Worker!="function"||S)return St(i,e).then(function(h){try{return t=h,n.call(this)}catch(v){return l(v)}}.bind(this),l);var o=function(){try{return n.call(this)}catch(h){return l(h)}}.bind(this),a=function(h){try{return St(i,e).then((function(v){try{return t=v,o()}catch(C){return l(C)}}),l)}catch(v){return l(v)}};try{return e.libURL=e.libURL||"https://cdn.jsdelivr.net/npm/browser-image-compression@2.0.2/dist/browser-image-compression.js",Pn(i,e).then((function(h){try{return t=h,o()}catch{return a()}}),a)}catch{a();}function n(){try{t.name=i.name,t.lastModified=i.lastModified;}catch{}try{e.preserveExif&&i.type==="image/jpeg"&&(!e.fileType||e.fileType&&e.fileType===i.type)&&(t=Tt(i,t));}catch{}return E(t)}}))}re.getDataUrlFromFile=xt,re.getFilefromDataUrl=tt,re.loadImage=Ut,re.drawImageInCanvas=Pt,re.drawFileInCanvas=ze,re.canvasToFile=Ge,re.getExifOrientation=Mt,re.handleMaxWidthOrHeight=Lt,re.followExifOrientation=Dt,re.cleanupCanvasMemory=ye,re.isAutoOrientationInBrowser=Pe,re.approximateBelowMaximumCanvasSizeOfBrowser=Ot,re.copyExifWithoutOrientation=Tt,re.getBrowserName=xe,re.version="2.0.2";var gn=Et(Ft()),mn=Et(on());function cr(i){let r=globalThis.document.getElementById("__AUTH_DRAWER"),E=globalThis.document.querySelector(".__drawer_container"),l=globalThis.document.querySelector(".__auth_close_button");r&&l&&E?.classList.contains("__hidden")&&(E.classList.remove("__hidden"),r.src=i,r.onload=()=>{l.classList.remove("__hidden"),r.classList.remove("__hidden"),r.contentWindow?.focus();});}function an(){if(globalThis.document.getElementById("__AUTH_DRAWER"))return;let i=globalThis.document.createElement("style");i.innerHTML=`
25
25
  .__button_container * {
26
26
  font-family: -apple-system,
27
27
  BlinkMacSystemFont,
@@ -226,7 +226,7 @@ self.addEventListener('message', async (e) => {
226
226
  max-width: 100%;
227
227
  }
228
228
  }
229
- `,globalThis.document.head.appendChild(i);let r=globalThis.document.createElement("div");r.className="__drawer_container __hidden";let E=globalThis.document.createElement("iframe");E.className="__drawer_frame __hidden",E.id="__AUTH_DRAWER",E.setAttribute("allow","fullscreen; camera; microphone; gyroscope; accelerometer; clipboard-write; clipboard-read; autoplay; geolocation; display-capture; picture-in-picture; payment; midi; bluetooth; web-share; screen-wake-lock; xr-spatial-tracking; encrypted-media; idle-detection; hid; serial; window-management"),E.loading="eager",E.referrerPolicy="unsafe-url",E.title="Login";let l=globalThis.document.createElement("div");l.setAttribute("alt","Close"),l.className="__auth_close_button",r.appendChild(E),r.appendChild(l),globalThis.document.body.appendChild(r);let e=globalThis.document.querySelector(".__auth_close_button");function t(){r.classList.add("__hidden"),E.classList.add("__hidden");}globalThis.window.addEventListener("message",p=>{!p.data||typeof p.data!="object"||p.data.type==="closeAuthDrawer"&&t();}),e?.addEventListener("click",t),r.addEventListener("click",t);}var mt=i=>{let{email:r,phoneNumber:E}=i??{},l=r??E,e=new URLSearchParams;i&&"redirectUri"in i&&i.redirectUri?e.set("returnTo",i.redirectUri):e.set("returnTo",globalThis.window.location.pathname+globalThis.window.location.search),l&&e.set("identity",l),e.set("stripped","true");let t=globalThis.window.__APP_ID__;cr(`${globalThis.window.__ROOT_URL__}/setup/${t}?${e.toString()}`);};function ur(i={}){let[r,E]=useState({userId:void 0,status:"loading",signIn:mt,providers:[]});return useEffect(()=>{(async()=>{try{let t=await(await fetch("/api/session",{method:"POST",headers:{"Content-Type":"application/json","x-guest-api-internal":"session",...globalThis.window.__IS_TESTING__?{"x-is-testing":"true"}:{}}})).json()??{};E({userId:t.userId??null,status:"authenticated",signIn:mt,providers:t?.providers??[]});}catch{if(i.required){let t=encodeURIComponent(globalThis.window.location.pathname+globalThis.window.location.search),p=globalThis.window.__APP_ID__;globalThis.window.top?globalThis.window.top.location.href=`${globalThis.window.__ROOT_URL__}/setup/${p}?returnTo=${t}`:globalThis.window.location.href=`${globalThis.window.__ROOT_URL__}/setup/${p}?returnTo=${t}`;}else E({userId:null,status:"unauthenticated",signIn:mt,providers:[]});}})();},[i.required]),r}async function fr(i){let r=`c_${Math.random().toString(36).slice(2)}_${Date.now()}`,E=new URLSearchParams;E.set("connectId",r),E.set("provider",i.provider),E.set("mode",i.mode??"get_or_request"),i.scope&&i.scope.length>0&&E.set("scope",i.scope.join(",")),typeof globalThis.window<"u"&&globalThis.window.__APP_ID__&&E.set("appId",globalThis.window.__APP_ID__);let l=`${globalThis.window.__ROOT_URL__}/connect-drawer?${E.toString()}`;return await globalThis.window.__REQUEST_CONNECTION__(l,r)}async function ln({channelId:i,initialData:r,broadcastOnly:E,onUpdate:l}){let e=r,t=0,p=globalThis.window.__REALTIME_DOMAIN__;if(E)return {getData(){return e},setData(w){e=w,fetch(`https://${p}/${i}`,{method:"POST",body:yt.stringify(e)}).catch(console.error),l?.(w);},destroy(){}};let c=new WebSocket(`wss://${p}/${i}`);return new Promise((w,S)=>{function o(v){try{let C=JSON.parse(v.data.toString());C?.id&&C.id>t?(e=yt.parse(C.payload),l?.(e),t=C.id):console.error("Invalid message:",v.data);}catch{console.error("Error parsing message:",v.data);}}function a(v){h(),S(v);}function n(){w({getData(){return e},setData(v){e=v,l?.(v),c.send(yt.stringify(v));},destroy:h});}function h(){c.removeEventListener("message",o),c.removeEventListener("error",a),c.removeEventListener("open",n),c.close();}c.addEventListener("message",o),c.addEventListener("error",a),c.addEventListener("open",n);})}function cn(i,r){let E=useRef(null),[l,e]=useState(0);return useEffect(()=>((async()=>i&&(E.current=await ln({channelId:i,initialData:r,onUpdate:()=>{e(t=>t+1);}})))(),E.current?.destroy),[i,e]),[E.current?.getData(),E.current?.setData??identity]}function Ar(i){let[r,E]=useState(null),[l]=cn(r,void 0),e=i.mutationFn;if(!e)throw new Error("useRealtimeMutation requires a mutationFn option.");let t=useCallback(async c=>{let w=nanoid(32);return E(w),await e({...c,__channelId:w})},[i?.mutationFn]);return {...useMutation({...i,mutationFn:t}),data:l}}function un(i){return i?.message?.startsWith("__MISSING AUTH FOR SCOPE")}function hn(i){return i[0]}function _r(i){let E=i?.message?.slice("__MISSING AUTH FOR SCOPE:".length+1).trim()??"",l=JSON.parse(atob(E.split(" ")?.[0])),e=l?.provider,t=l?.scope;return {provider:e,scope:t,isPopup:i?.message?.endsWith("--popup"),accountId:l?.accountId}}var br=60,Er=30*1e3,At=0,pn=Date.now(),wt=false;function Sr(){return rpcClient({transport:async(i,r)=>{let E=Date.now();if(E-pn>=Er)pn=E,At=0,wt=false;else if(At>=br)throw wt||(globalThis.window.dispatchEvent(new Event("rate-limit-exceeded")),wt=true),new RpcError("Rate limit exceeded",-32e3,{status:429});At++;let l="/api/"+i.method,e=i.params&&hn(i.params)?.__channelId;e&&delete hn(i.params)?.__channelId;let t=await fetch(l,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",...e?{"x-channel-id":e}:{},...globalThis.window.__IS_TESTING__?{"x-is-testing":"true"}:{},"x-boxman-box-id":globalThis.window.__BOX_ID__},body:yt.stringify(i),signal:r});if(!t.ok){let c=t.statusText,w=-32e3;try{let{message:S,code:o}=await t.json();S&&(c=S),o&&(w=o);}catch{}throw c.trim()===""&&(c=`Request failed with status: ${t.status}`),new RpcError(c,w,{status:t.status})}let p=yt.deserialize(await t.json());if(un(p.error)){let c=encodeURIComponent(globalThis.window.location.pathname+globalThis.window.location.search),w=_r(p.error),S=[`returnTo=${c}`,w.provider?`&provider=${w.provider}`:"",w.scope?`&scope=${w.scope.join(",")}`:"",w.accountId?`&accountId=${w.accountId}`:""].filter(Boolean).join("&");if(w.isPopup){globalThis.window.__OPEN_AUTH_DRAWER__(`${globalThis.window.__ROOT_URL__}/setup/${globalThis.window.__APP_ID__}?${S}&stripped=true`);return}let o=globalThis.window.top??globalThis.window;return o.location.href=`${globalThis.window.__ROOT_URL__}/setup/${globalThis.window.__APP_ID__}?${S}`,null}return p}})}function Xr(i){return new Promise(r=>{let E=new globalThis.FileReader;E.onload=()=>{r(E.result);},E.readAsDataURL(i);})}function Tr(){let i={...globalThis.window.console};function r(E,l){let e=(0, mn.default)(l,{depth:5,maxStringLength:512,indent:2});fetch("/_logger",{method:"POST",body:`[console.${E.toLowerCase()}] ${e}`}).catch(()=>{});}globalThis.window.console.log=(...E)=>{r("LOG",E),i.log(...E);},globalThis.window.console.error=(...E)=>{r("ERROR",E),i.error(...E);},globalThis.window.console.info=(...E)=>{r("INFO",E),i.info(...E);},globalThis.window.console.warn=(...E)=>{r("WARN",E),i.warn(...E);};}function Ir(){function i(r,E=globalThis.window.parent,l="*"){E?.postMessage({...r,source:"iframe"},{targetOrigin:l});}globalThis.window.addEventListener("message",async r=>{let{origin:E,source:l,data:e}=r,{type:t}=e;if(t==="screenshot"){let p=globalThis.window.getComputedStyle(globalThis.document.body).backgroundColor,c=await gn.default.toPng(globalThis.document.body,{bgcolor:p,style:{transform:"translateY("+-globalThis.window.scrollY+"px)"},width:globalThis.window.innerWidth,height:globalThis.window.innerHeight,copyDefaultStyles:false}),w=await fetch(c).then(n=>n.blob()),S=await re(w,{maxSizeMB:4,maxWidthOrHeight:1920,useWebWorker:false}),a={type:"screenshot",payload:{screenshot:await re.getDataUrlFromFile(S)}};i(a,l,E);}});}function Yr({appId:i,rootUrl:r,baseUrl:E,isTesting:l,realtimeDomain:e,boxId:t}){typeof globalThis.window>"u"||globalThis.window.__APP_ID__||(globalThis.window.__APP_ID__=i,globalThis.window.__ROOT_URL__=r,globalThis.window.__BASE_URL__=E,globalThis.window.__IS_TESTING__=l,globalThis.window.__REALTIME_DOMAIN__=e,globalThis.window.__BOX_ID__=t,Ir(),Tr(),an(),globalThis.window.onerror=function(p){console.error("Global JS error:",p);},globalThis.window.onunhandledrejection=function(p){console.error("Unhandled promise rejection:",p.reason);});}function Jr(){return globalThis.window.__BASE_URL__}/*! Bundled license information:
229
+ `,globalThis.document.head.appendChild(i);let r=globalThis.document.createElement("div");r.className="__drawer_container __hidden";let E=globalThis.document.createElement("iframe");E.className="__drawer_frame __hidden",E.id="__AUTH_DRAWER",E.setAttribute("allow","fullscreen; camera; microphone; gyroscope; accelerometer; clipboard-write; clipboard-read; autoplay; geolocation; display-capture; picture-in-picture; payment; midi; bluetooth; web-share; screen-wake-lock; xr-spatial-tracking; encrypted-media; idle-detection; hid; serial; window-management"),E.loading="eager",E.referrerPolicy="unsafe-url",E.title="Login";let l=globalThis.document.createElement("div");l.setAttribute("alt","Close"),l.className="__auth_close_button",r.appendChild(E),r.appendChild(l),globalThis.document.body.appendChild(r);let e=globalThis.document.querySelector(".__auth_close_button");function t(){r.classList.add("__hidden"),E.classList.add("__hidden");}globalThis.window.__REQUEST_CONNECTION__=(p,c)=>(E.src=p,new Promise(y=>{let S=o=>{if(o.source!==E.contentWindow)return;let a=o.data||{};a.type==="REQUEST_CONNECTION_RESULT"&&(globalThis.window.removeEventListener("message",S),y(a),t());};globalThis.window.addEventListener("message",S);})),globalThis.window.addEventListener("message",p=>{!p.data||typeof p.data!="object"||p.data.type==="closeAuthDrawer"&&t();}),e?.addEventListener("click",t),r.addEventListener("click",t);}var mt=i=>{let{email:r,phoneNumber:E}=i??{},l=r??E,e=new URLSearchParams;i&&"redirectUri"in i&&i.redirectUri?e.set("returnTo",i.redirectUri):e.set("returnTo",globalThis.window.location.pathname+globalThis.window.location.search),l&&e.set("identity",l),e.set("stripped","true");let t=globalThis.window.__APP_ID__;cr(`${globalThis.window.__ROOT_URL__}/setup/${t}?${e.toString()}`);};function ur(i={}){let[r,E]=useState({userId:void 0,status:"loading",signIn:mt,providers:[]});return useEffect(()=>{(async()=>{try{let t=await(await fetch("/api/session",{method:"POST",headers:{"Content-Type":"application/json","x-guest-api-internal":"session",...globalThis.window.__IS_TESTING__?{"x-is-testing":"true"}:{}}})).json()??{};E({userId:t.userId??null,status:"authenticated",signIn:mt,providers:t?.providers??[]});}catch{if(i.required){let t=encodeURIComponent(globalThis.window.location.pathname+globalThis.window.location.search),p=globalThis.window.__APP_ID__;globalThis.window.top?globalThis.window.top.location.href=`${globalThis.window.__ROOT_URL__}/setup/${p}?returnTo=${t}`:globalThis.window.location.href=`${globalThis.window.__ROOT_URL__}/setup/${p}?returnTo=${t}`;}else E({userId:null,status:"unauthenticated",signIn:mt,providers:[]});}})();},[i.required]),r}async function fr(i){let r=`c_${Math.random().toString(36).slice(2)}_${Date.now()}`,E=new URLSearchParams;E.set("connectId",r),E.set("provider",i.provider),E.set("mode",i.mode??"get_or_request"),i.scope&&i.scope.length>0&&E.set("scope",i.scope.join(",")),typeof globalThis.window<"u"&&globalThis.window.__APP_ID__&&E.set("appId",globalThis.window.__APP_ID__);let l=`${globalThis.window.__ROOT_URL__}/connect-drawer?${E.toString()}`;return await globalThis.window.__REQUEST_CONNECTION__(l,r)}async function ln({channelId:i,initialData:r,broadcastOnly:E,onUpdate:l}){let e=r,t=0,p=globalThis.window.__REALTIME_DOMAIN__;if(E)return {getData(){return e},setData(y){e=y,fetch(`https://${p}/${i}`,{method:"POST",body:yt.stringify(e)}).catch(console.error),l?.(y);},destroy(){}};let c=new WebSocket(`wss://${p}/${i}`);return new Promise((y,S)=>{function o(v){try{let C=JSON.parse(v.data.toString());C?.id&&C.id>t?(e=yt.parse(C.payload),l?.(e),t=C.id):console.error("Invalid message:",v.data);}catch{console.error("Error parsing message:",v.data);}}function a(v){h(),S(v);}function n(){y({getData(){return e},setData(v){e=v,l?.(v),c.send(yt.stringify(v));},destroy:h});}function h(){c.removeEventListener("message",o),c.removeEventListener("error",a),c.removeEventListener("open",n),c.close();}c.addEventListener("message",o),c.addEventListener("error",a),c.addEventListener("open",n);})}function cn(i,r){let E=useRef(null),[l,e]=useState(0);return useEffect(()=>((async()=>i&&(E.current=await ln({channelId:i,initialData:r,onUpdate:()=>{e(t=>t+1);}})))(),E.current?.destroy),[i,e]),[E.current?.getData(),E.current?.setData??identity]}function Ar(i){let[r,E]=useState(null),[l]=cn(r,void 0),e=i.mutationFn;if(!e)throw new Error("useRealtimeMutation requires a mutationFn option.");let t=useCallback(async c=>{let y=nanoid(32);return E(y),await e({...c,__channelId:y})},[i?.mutationFn]);return {...useMutation({...i,mutationFn:t}),data:l}}function un(i){return i?.message?.startsWith("__MISSING AUTH FOR SCOPE")}function hn(i){return i[0]}function _r(i){let E=i?.message?.slice("__MISSING AUTH FOR SCOPE:".length+1).trim()??"",l=JSON.parse(atob(E.split(" ")?.[0])),e=l?.provider,t=l?.scope;return {provider:e,scope:t,isPopup:i?.message?.endsWith("--popup"),accountId:l?.accountId}}var br=60,Er=30*1e3,At=0,pn=Date.now(),wt=false;function Sr(){return rpcClient({transport:async(i,r)=>{let E=Date.now();if(E-pn>=Er)pn=E,At=0,wt=false;else if(At>=br)throw wt||(globalThis.window.dispatchEvent(new Event("rate-limit-exceeded")),wt=true),new RpcError("Rate limit exceeded",-32e3,{status:429});At++;let l="/api/"+i.method,e=i.params&&hn(i.params)?.__channelId;e&&delete hn(i.params)?.__channelId;let t=await fetch(l,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",...e?{"x-channel-id":e}:{},...globalThis.window.__IS_TESTING__?{"x-is-testing":"true"}:{},"x-boxman-box-id":globalThis.window.__BOX_ID__},body:yt.stringify(i),signal:r});if(!t.ok){let c=t.statusText,y=-32e3;try{let{message:S,code:o}=await t.json();S&&(c=S),o&&(y=o);}catch{}throw c.trim()===""&&(c=`Request failed with status: ${t.status}`),new RpcError(c,y,{status:t.status})}let p=yt.deserialize(await t.json());if(un(p.error)){let c=encodeURIComponent(globalThis.window.location.pathname+globalThis.window.location.search),y=_r(p.error),S=[`returnTo=${c}`,y.provider?`&provider=${y.provider}`:"",y.scope?`&scope=${y.scope.join(",")}`:"",y.accountId?`&accountId=${y.accountId}`:""].filter(Boolean).join("&");if(y.isPopup){globalThis.window.__OPEN_AUTH_DRAWER__(`${globalThis.window.__ROOT_URL__}/setup/${globalThis.window.__APP_ID__}?${S}&stripped=true`);return}let o=globalThis.window.top??globalThis.window;return o.location.href=`${globalThis.window.__ROOT_URL__}/setup/${globalThis.window.__APP_ID__}?${S}`,null}return p}})}function Xr(i){return new Promise(r=>{let E=new globalThis.FileReader;E.onload=()=>{r(E.result);},E.readAsDataURL(i);})}function Tr(){let i={...globalThis.window.console};function r(E,l){let e=(0, mn.default)(l,{depth:5,maxStringLength:512,indent:2});fetch("/_logger",{method:"POST",body:`[console.${E.toLowerCase()}] ${e}`}).catch(()=>{});}globalThis.window.console.log=(...E)=>{r("LOG",E),i.log(...E);},globalThis.window.console.error=(...E)=>{r("ERROR",E),i.error(...E);},globalThis.window.console.info=(...E)=>{r("INFO",E),i.info(...E);},globalThis.window.console.warn=(...E)=>{r("WARN",E),i.warn(...E);};}function Ir(){function i(r,E=globalThis.window.parent,l="*"){E?.postMessage({...r,source:"iframe"},{targetOrigin:l});}globalThis.window.addEventListener("message",async r=>{let{origin:E,source:l,data:e}=r,{type:t}=e;if(t==="screenshot"){let p=globalThis.window.getComputedStyle(globalThis.document.body).backgroundColor,c=await gn.default.toPng(globalThis.document.body,{bgcolor:p,style:{transform:"translateY("+-globalThis.window.scrollY+"px)"},width:globalThis.window.innerWidth,height:globalThis.window.innerHeight,copyDefaultStyles:false}),y=await fetch(c).then(n=>n.blob()),S=await re(y,{maxSizeMB:4,maxWidthOrHeight:1920,useWebWorker:false}),a={type:"screenshot",payload:{screenshot:await re.getDataUrlFromFile(S)}};i(a,l,E);}});}function Yr({appId:i,rootUrl:r,baseUrl:E,isTesting:l,realtimeDomain:e,boxId:t}){typeof globalThis.window>"u"||globalThis.window.__APP_ID__||(globalThis.window.__APP_ID__=i,globalThis.window.__ROOT_URL__=r,globalThis.window.__BASE_URL__=E,globalThis.window.__IS_TESTING__=l,globalThis.window.__REALTIME_DOMAIN__=e,globalThis.window.__BOX_ID__=t,Ir(),Tr(),an(),globalThis.window.onerror=function(p){console.error("Global JS error:",p);},globalThis.window.onunhandledrejection=function(p){console.error("Unhandled promise rejection:",p.reason);});}function Jr(){return globalThis.window.__BASE_URL__}/*! Bundled license information:
230
230
 
231
231
  dom-to-image-more/dist/dom-to-image-more.min.js:
232
232
  (*! dom-to-image-more 23-10-2025 *)
@@ -327,88 +327,6 @@ declare let client: {
327
327
  id: string;
328
328
  }>>;
329
329
  };
330
- uploadToBucket: {
331
- mutate: _trpc_client.Resolver<_trpc_server.BuildProcedure<"mutation", {
332
- _config: _trpc_server.RootConfig<{
333
- ctx: {
334
- appId: string;
335
- versionId: string;
336
- appName: string;
337
- appSubdomain: string;
338
- userId: string;
339
- isTesting: boolean;
340
- rpcMethod: string;
341
- requestId: string;
342
- type?: undefined;
343
- dbUrl?: string | null | undefined;
344
- userIdActual?: string | null | undefined;
345
- channelId?: string | null | undefined;
346
- } | {
347
- type: "BOXMAN_REQUEST";
348
- boxId: string;
349
- isDevelopment: boolean | null;
350
- appId?: string | null | undefined;
351
- rpcMethod?: string | null | undefined;
352
- requestId?: string | null | undefined;
353
- channelId?: string | null | undefined;
354
- platformUserId?: string | null | undefined;
355
- agent?: string | null | undefined;
356
- sessionId?: string | null | undefined;
357
- pushToken?: string | null | undefined;
358
- };
359
- meta: object;
360
- errorShape: {
361
- data: {
362
- zodError: typeToFlattenedError<any, string> | null;
363
- code: _trpc_server_rpc.TRPC_ERROR_CODE_KEY;
364
- httpStatus: number;
365
- path?: string;
366
- stack?: string;
367
- };
368
- message: string;
369
- code: _trpc_server_rpc.TRPC_ERROR_CODE_NUMBER;
370
- };
371
- transformer: typeof superjson;
372
- }>;
373
- _meta: object;
374
- _ctx_out: {
375
- type: undefined;
376
- appId: string;
377
- versionId: string;
378
- dbUrl: string | null | undefined;
379
- appName: string;
380
- appSubdomain: string;
381
- userId: string;
382
- userIdActual: string | null | undefined;
383
- isTesting: boolean;
384
- rpcMethod: string;
385
- requestId: string;
386
- channelId: string | null | undefined;
387
- } | {
388
- type: "BOXMAN_REQUEST";
389
- appId: string | null | undefined;
390
- boxId: string;
391
- rpcMethod: string | null | undefined;
392
- requestId: string | null | undefined;
393
- channelId: string | null | undefined;
394
- platformUserId: string | null | undefined;
395
- isDevelopment: boolean | null;
396
- agent: string | null | undefined;
397
- sessionId: string | null | undefined;
398
- pushToken: string | null | undefined;
399
- };
400
- _input_in: {
401
- fileName: string;
402
- base64: string;
403
- };
404
- _input_out: {
405
- fileName: string;
406
- base64: string;
407
- };
408
- _output_in: typeof _trpc_server.unsetMarker;
409
- _output_out: typeof _trpc_server.unsetMarker;
410
- }, string>>;
411
- };
412
330
  generateSoundEffect: {
413
331
  mutate: _trpc_client.Resolver<_trpc_server.BuildProcedure<"mutation", {
414
332
  _config: _trpc_server.RootConfig<{
@@ -1751,6 +1669,102 @@ declare let client: {
1751
1669
  };
1752
1670
  }, unknown>>;
1753
1671
  };
1672
+ connectedApiRequest: {
1673
+ mutate: _trpc_client.Resolver<_trpc_server.BuildProcedure<"mutation", {
1674
+ _config: _trpc_server.RootConfig<{
1675
+ ctx: {
1676
+ appId: string;
1677
+ versionId: string;
1678
+ appName: string;
1679
+ appSubdomain: string;
1680
+ userId: string;
1681
+ isTesting: boolean;
1682
+ rpcMethod: string;
1683
+ requestId: string;
1684
+ type?: undefined;
1685
+ dbUrl?: string | null | undefined;
1686
+ userIdActual?: string | null | undefined;
1687
+ channelId?: string | null | undefined;
1688
+ } | {
1689
+ type: "BOXMAN_REQUEST";
1690
+ boxId: string;
1691
+ isDevelopment: boolean | null;
1692
+ appId?: string | null | undefined;
1693
+ rpcMethod?: string | null | undefined;
1694
+ requestId?: string | null | undefined;
1695
+ channelId?: string | null | undefined;
1696
+ platformUserId?: string | null | undefined;
1697
+ agent?: string | null | undefined;
1698
+ sessionId?: string | null | undefined;
1699
+ pushToken?: string | null | undefined;
1700
+ };
1701
+ meta: object;
1702
+ errorShape: {
1703
+ data: {
1704
+ zodError: typeToFlattenedError<any, string> | null;
1705
+ code: _trpc_server_rpc.TRPC_ERROR_CODE_KEY;
1706
+ httpStatus: number;
1707
+ path?: string;
1708
+ stack?: string;
1709
+ };
1710
+ message: string;
1711
+ code: _trpc_server_rpc.TRPC_ERROR_CODE_NUMBER;
1712
+ };
1713
+ transformer: typeof superjson;
1714
+ }>;
1715
+ _meta: object;
1716
+ _ctx_out: {
1717
+ type: undefined;
1718
+ appId: string;
1719
+ versionId: string;
1720
+ dbUrl: string | null | undefined;
1721
+ appName: string;
1722
+ appSubdomain: string;
1723
+ userId: string;
1724
+ userIdActual: string | null | undefined;
1725
+ isTesting: boolean;
1726
+ rpcMethod: string;
1727
+ requestId: string;
1728
+ channelId: string | null | undefined;
1729
+ } | {
1730
+ type: "BOXMAN_REQUEST";
1731
+ appId: string | null | undefined;
1732
+ boxId: string;
1733
+ rpcMethod: string | null | undefined;
1734
+ requestId: string | null | undefined;
1735
+ channelId: string | null | undefined;
1736
+ platformUserId: string | null | undefined;
1737
+ isDevelopment: boolean | null;
1738
+ agent: string | null | undefined;
1739
+ sessionId: string | null | undefined;
1740
+ pushToken: string | null | undefined;
1741
+ };
1742
+ _input_in: {
1743
+ url: string;
1744
+ connectionToken: string;
1745
+ method: string;
1746
+ body?: any;
1747
+ headers?: Record<string, string> | undefined;
1748
+ };
1749
+ _input_out: {
1750
+ url: string;
1751
+ connectionToken: string;
1752
+ method: string;
1753
+ body?: any;
1754
+ headers?: Record<string, string> | undefined;
1755
+ };
1756
+ _output_in: typeof _trpc_server.unsetMarker;
1757
+ _output_out: typeof _trpc_server.unsetMarker;
1758
+ }, {
1759
+ status: number;
1760
+ body: any;
1761
+ error?: undefined;
1762
+ } | {
1763
+ status: number;
1764
+ error: string;
1765
+ body?: undefined;
1766
+ }>>;
1767
+ };
1754
1768
  health: {
1755
1769
  query: _trpc_client.Resolver<_trpc_server.BuildProcedure<"query", {
1756
1770
  _config: _trpc_server.RootConfig<{
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adaptive-ai/sdk",
3
- "version": "0.1.10",
3
+ "version": "0.1.12",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "exports": {