PageSourceSearch

https://aztecexplorer.xyz/assets/index-eQvfn6QJ.js

js aztecexplorer.xyz collected 2026-10-08 20:20:35 UTC 1,825,248 bytes, 2,126 lines download raw bytes

vendor: 6,964 bytes, line 1
1var H_e=Object.defineProperty;var YV=Rr=>{throw TypeError(Rr)};var W_e=(Rr,dt,Nr)=>dt in Rr?H_e(Rr,dt,{enumerable:!0,configurable:!0,writable:!0,value:Nr}):Rr[dt]=Nr;var te=(Rr,dt,Nr)=>W_e(Rr,typeof dt!="symbol"?dt+"":dt,Nr),XE=(Rr,dt,Nr)=>dt.has(Rr)||YV("Cannot "+Nr);var Se=(Rr,dt,Nr)=>(XE(Rr,dt,"read from private field"),Nr?Nr.call(Rr):dt.get(Rr)),qt=(Rr,dt,Nr)=>dt.has(Rr)?YV("Cannot add the same private member more than once"):dt instanceof WeakSet?dt.add(Rr):dt.set(Rr,Nr),vt=(Rr,dt,Nr,Cf)=>(XE(Rr,dt,"write to private field"),Cf?Cf.call(Rr,Nr):dt.set(Rr,Nr),Nr),Vt=(Rr,dt,Nr)=>(XE(Rr,dt,"access private method"),Nr);var X2=(Rr,dt,Nr,Cf)=>({set _(V1){vt(Rr,dt,V1,Nr)},get _(){return Se(Rr,dt,Cf)}});let Qr,M,he,K_e=(async()=>{var Gh,uE,Yh,uf,bp,Mq,yp,ff,vp,Aq,Xh,Cq,wp,xp,$s,Jh,aa,m1,Qh,Po,Kc,Tq,Rl,jq,Nl,pa,ed,Fl,Af,Iq,Uc,zo,g1,Oq,Cn,hf,df,_p,Sp,pf,kp,Ep,Bq,Da,xr,b1,ma,td,Mp,mf,gf,y1,Ap,Cp,rd,nd,bf,Tp,Or,U1,JE,QE,e9,t9,r9,n9,i9,XV,Rq,v2,fs,Ho,ad,q1;function Rr(e,t){for(var r=0;r<t.length;r++){const n=t[r];if(typeof n!="string"&&!Array.isArray(n)){for(const i in n)if(i!=="default"&&!(i in e)){const a=Object.getOwnPropertyDescriptor(n,i);a&&Object.defineProperty(e,i,a.get?a:{enumerable:!0,get:()=>n[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))r(n);new MutationObserver(n=>{for(const i of n)if(i.type==="childList")for(const a of i.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&r(a)}).observe(document,{childList:!0,subtree:!0});function t(n){const i={};return n.integrity&&(i.integrity=n.integrity),n.referrerPolicy&&(i.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?i.credentials="include":n.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(n){if(n.ep)return;n.ep=!0;const i=t(n);fetch(n.href,i)}})();var dt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Nr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Cf(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function n(){return this instanceof n?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach(function(n){var i=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(r,n,i.get?i:{enumerable:!0,get:function(){return e[n]}})}),r}var V1={exports:{}},Z1={},a9={exports:{}},fr={},Up=Symbol.for("react.element"),JV=Symbol.for("react.portal"),QV=Symbol.for("react.fragment"),eZ=Symbol.for("react.strict_mode"),tZ=Symbol.for("react.profiler"),rZ=Symbol.for("react.provider"),nZ=Symbol.for("react.context"),iZ=Symbol.for("react.forward_ref"),aZ=Symbol.for("react.suspense"),sZ=Symbol.for("react.memo"),oZ=Symbol.for("react.lazy"),s9=Symbol.iterator;function lZ(e){return e===null||typeof e!="object"?null:(e=s9&&e[s9]||e["@@iterator"],typeof e=="function"?e:null)}var o9={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},l9=Object.assign,c9={};function md(e,t,r){this.props=e,this.context=t,this.refs=c9,this.updater=r||o9}md.prototype.isReactComponent={},md.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},md.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function u9(){}u9.prototype=md.prototype;function J2(e,t,r){this.props=e,this.context=t,this.refs=c9,this.updater=r||o9}var Q2=J2.prototype=new u9;Q2.constructor=J2,l9(Q2,md.prototype),Q2.isPureReactComponent=!0;var f9=Array.isArray,h9=Object.prototype.hasOwnProperty,e_={current:null},d9={key:!0,ref:!0,__self:!0,__source:!0};function p9(e,t,r){var n,i={},a=null,s=null;if(t!=null)for(n in t.ref!==void 0&&(s=t.ref),t.key!==void 0&&(a=""+t.key),t)h9.call(t,n)&&!d9.hasOwnProperty(n)&&(i[n]=t[n]);var o=arguments.length-2;if(o===1)i.children=r;else if(1<o){for(var c=Array(o),l=0;l<o;l++)c[l]=arguments[l+2];i.children=c}if(e&&e.defaultProps)for(n in o=e.defaultProps,o)i[n]===void 0&&(i[n]=o[n]);return{$$typeof:Up,type:e,key:a,ref:s,props:i,_owner:e_.current}}function cZ(e,t){return{$$typeof:Up,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function t_(e){return typeof e=="object"&&e!==null&&e.$$typeof===Up}function uZ(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(r){return t[r]})}var m9=/\/+/g;function r_(e,t){return typeof e=="object"&&e!==null&&e.key!=null?uZ(""+e.key):t.toString(36)}function $1(e,t,r,n,i){var a=typeof e;(a==="undefined"||a==="boolean")&&(e=null);var s=!1;if(e===null)s=!0;else switch(a){case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case Up:case JV:s=!0}}if(s)return s=e,i=i(s),e=n===""?"."+r_(s,0):n,f9(i)?(r="",e!=null&&(r=e.replace(m9,"$&/")+"/"),$1(i,t,r,"",function(l){return l})):i!=null&&(t_(i)&&(i=cZ(i,r+(!i.key||s&&s.key===i.key?"":(""+i.key).replace(m9,"$&/")+"/")+e)),t.push(i)),1;if(s=0,n=n===""?".":n+":",f9(e))for(var o=0;o<e.length;o++){a=e[o];var c=n+r_(a,o);s+=$1(a,t,r,c,i)}else if(c=lZ(e),typeof c=="function")for(e=c.call(e),o=0;!(a=e.next()).done;)a=a.value,c=n+r_(a,o++),s+=$1(a,t,r,c,i);else if(a==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return s}function H1(e,t,r){if(e==null)return e;var n=[],i=0;return $1(e,n,"","",function(a){return t.call(r,a,i++)}),n}function fZ(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(r){(e._status===0||e._status===-1)&&(e._status=1,e._result=r)},function(r){(e._status===0||e._status===-1)&&(e._status=2,e._result=r)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var sa={current:null},W1={transition:null},hZ={ReactCurrentDispatcher:sa,ReactCurrentBatchConfig:W1,ReactCurrentOwner:e_};function g9(){throw Error("act(...) is not supported in production builds of React.")}fr.Children={map:H1,forEach:function(e,t,r){H1(e,function(){t.apply(this,arguments)},r)},count:function(e){var t=0;return H1(e,function(){t++}),t},toArray:function(e){return H1(e,function(t){return t})||[]},only:function(e){if(!t_(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},fr.Component=md,fr.Fragment=QV,fr.Profiler=tZ,fr.PureComponent=J2,fr.StrictMode=eZ,fr.Suspense=aZ,fr.__SECRET_INT
vendor: 4,561 bytes, line 1
1ERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=hZ,fr.act=g9,fr.cloneElement=function(e,t,r){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var n=l9({},e.props),i=e.key,a=e.ref,s=e._owner;if(t!=null){if(t.ref!==void 0&&(a=t.ref,s=e_.current),t.key!==void 0&&(i=""+t.key),e.type&&e.type.defaultProps)var o=e.type.defaultProps;for(c in t)h9.call(t,c)&&!d9.hasOwnProperty(c)&&(n[c]=t[c]===void 0&&o!==void 0?o[c]:t[c])}var c=arguments.length-2;if(c===1)n.children=r;else if(1<c){o=Array(c);for(var l=0;l<c;l++)o[l]=arguments[l+2];n.children=o}return{$$typeof:Up,type:e.type,key:i,ref:a,props:n,_owner:s}},fr.createContext=function(e){return e={$$typeof:nZ,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:rZ,_context:e},e.Consumer=e},fr.createElement=p9,fr.createFactory=function(e){var t=p9.bind(null,e);return t.type=e,t},fr.createRef=function(){return{current:null}},fr.forwardRef=function(e){return{$$typeof:iZ,render:e}},fr.isValidElement=t_,fr.lazy=function(e){return{$$typeof:oZ,_payload:{_status:-1,_result:e},_init:fZ}},fr.memo=function(e,t){return{$$typeof:sZ,type:e,compare:t===void 0?null:t}},fr.startTransition=function(e){var t=W1.transition;W1.transition={};try{e()}finally{W1.transition=t}},fr.unstable_act=g9,fr.useCallback=function(e,t){return sa.current.useCallback(e,t)},fr.useContext=function(e){return sa.current.useContext(e)},fr.useDebugValue=function(){},fr.useDeferredValue=function(e){return sa.current.useDeferredValue(e)},fr.useEffect=function(e,t){return sa.current.useEffect(e,t)},fr.useId=function(){return sa.current.useId()},fr.useImperativeHandle=function(e,t,r){return sa.current.useImperativeHandle(e,t,r)},fr.useInsertionEffect=function(e,t){return sa.current.useInsertionEffect(e,t)},fr.useLayoutEffect=function(e,t){return sa.current.useLayoutEffect(e,t)},fr.useMemo=function(e,t){return sa.current.useMemo(e,t)},fr.useReducer=function(e,t,r){return sa.current.useReducer(e,t,r)},fr.useRef=function(e){return sa.current.useRef(e)},fr.useState=function(e){return sa.current.useState(e)},fr.useSyncExternalStore=function(e,t,r){return sa.current.useSyncExternalStore(e,t,r)},fr.useTransition=function(){return sa.current.useTransition()},fr.version="18.3.1",a9.exports=fr,he=a9.exports;const Ei=Nr(he),dZ=Rr({__proto__:null,default:Ei},[he]);var pZ=he,mZ=Symbol.for("react.element"),gZ=Symbol.for("react.fragment"),bZ=Object.prototype.hasOwnProperty,yZ=pZ.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,vZ={key:!0,ref:!0,__self:!0,__source:!0};function b9(e,t,r){var n,i={},a=null,s=null;r!==void 0&&(a=""+r),t.key!==void 0&&(a=""+t.key),t.ref!==void 0&&(s=t.ref);for(n in t)bZ.call(t,n)&&!vZ.hasOwnProperty(n)&&(i[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps,t)i[n]===void 0&&(i[n]=t[n]);return{$$typeof:mZ,type:e,key:a,ref:s,props:i,_owner:yZ.current}}Z1.Fragment=gZ,Z1.jsx=b9,Z1.jsxs=b9,V1.exports=Z1;let K1,n_,ya,i_,a_;M=V1.exports,K1={},n_={exports:{}},ya={},i_={exports:{}},a_={},function(e){function t(S,h){var x=S.length;S.push(h);e:for(;0<x;){var v=x-1>>>1,F=S[v];if(0<i(F,h))S[v]=h,S[x]=F,x=v;else break e}}function r(S){return S.length===0?null:S[0]}function n(S){if(S.length===0)return null;var h=S[0],x=S.pop();if(x!==h){S[0]=x;e:for(var v=0,F=S.length,Q=F>>>1;v<Q;){var G=2*(v+1)-1,J=S[G],Y=G+1,V=S[Y];if(0>i(J,x))Y<F&&0>i(V,J)?(S[v]=V,S[Y]=x,v=Y):(S[v]=J,S[G]=x,v=G);else if(Y<F&&0>i(V,x))S[v]=V,S[Y]=x,v=Y;else break e}}return h}function i(S,h){var x=S.sortIndex-h.sortIndex;return x!==0?x:S.id-h.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var s=Date,o=s.now();e.unstable_now=function(){return s.now()-o}}var c=[],l=[],u=1,d=null,p=3,w=!1,O=!1,I=!1,R=typeof setTimeout=="function"?setTimeout:null,C=typeof clearTimeout=="function"?clearTimeout:null,j=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function N(S){for(var h=r(l);h!==null;){if(h.callback===null)n(l);else if(h.startTime<=S)n(l),h.sortIndex=h.expirationTime,t(c,h);else break;h=r(l)}}function P(S){if(I=!1,N(S),!O)if(r(c)!==null)O=!0,B(Z);else{var h=r(l);h!==null&&T(P,h.startTime-S)}}function Z(S,h){O=!1,I&&(I=!1,C(ne),ne=-1),w=!0;var x=p;try{for(N(h),d=r(c);d!==null&&(!(d.expirationTime>h)||S&&!m());){var v=d.callback;
vendor: 4,398 bytes, line 1
1if(typeof v=="function"){d.callback=null,p=d.priorityLevel;var F=v(d.expirationTime<=h);h=e.unstable_now(),typeof F=="function"?d.callback=F:d===r(c)&&n(c),N(h)}else n(c);d=r(c)}if(d!==null)var Q=!0;else{var G=r(l);G!==null&&T(P,G.startTime-h),Q=!1}return Q}finally{d=null,p=x,w=!1}}var X=!1,re=null,ne=-1,ae=5,ue=-1;function m(){return!(e.unstable_now()-ue<ae)}function A(){if(re!==null){var S=e.unstable_now();ue=S;var h=!0;try{h=re(!0,S)}finally{h?f():(X=!1,re=null)}}else X=!1}var f;if(typeof j=="function")f=function(){j(A)};else if(typeof MessageChannel<"u"){var g=new MessageChannel,_=g.port2;g.port1.onmessage=A,f=function(){_.postMessage(null)}}else f=function(){R(A,0)};function B(S){re=S,X||(X=!0,f())}function T(S,h){ne=R(function(){S(e.unstable_now())},h)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(S){S.callback=null},e.unstable_continueExecution=function(){O||w||(O=!0,B(Z))},e.unstable_forceFrameRate=function(S){0>S||125<S?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):ae=0<S?Math.floor(1e3/S):5},e.unstable_getCurrentPriorityLevel=function(){return p},e.unstable_getFirstCallbackNode=function(){return r(c)},e.unstable_next=function(S){switch(p){case 1:case 2:case 3:var h=3;break;default:h=p}var x=p;p=h;try{return S()}finally{p=x}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(S,h){switch(S){case 1:case 2:case 3:case 4:case 5:break;default:S=3}var x=p;p=S;try{return h()}finally{p=x}},e.unstable_scheduleCallback=function(S,h,x){var v=e.unstable_now();switch(typeof x=="object"&&x!==null?(x=x.delay,x=typeof x=="number"&&0<x?v+x:v):x=v,S){case 1:var F=-1;break;case 2:F=250;break;case 5:F=1073741823;break;case 4:F=1e4;break;default:F=5e3}return F=x+F,S={id:u++,callback:h,priorityLevel:S,startTime:x,expirationTime:F,sortIndex:-1},x>v?(S.sortIndex=x,t(l,S),r(c)===null&&S===r(l)&&(I?(C(ne),ne=-1):I=!0,T(P,x-v))):(S.sortIndex=F,t(c,S),O||w||(O=!0,B(Z))),S},e.unstable_shouldYield=m,e.unstable_wrapCallback=function(S){var h=p;return function(){var x=p;p=h;try{return S.apply(this,arguments)}finally{p=x}}}}(a_),i_.exports=a_;var wZ=i_.exports,xZ=he,Za=wZ;function Ge(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var y9=new Set,qp={};function Tf(e,t){gd(e,t),gd(e+"Capture",t)}function gd(e,t){for(qp[e]=t,e=0;e<t.length;e++)y9.add(t[e])}var Hl=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),s_=Object.prototype.hasOwnProperty,_Z=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,v9={},w9={};function SZ(e){return s_.call(w9,e)?!0:s_.call(v9,e)?!1:_Z.test(e)?w9[e]=!0:(v9[e]=!0,!1)}function kZ(e,t,r,n){if(r!==null&&r.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return n?!1:r!==null?!r.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function EZ(e,t,r,n){if(t===null||typeof t>"u"||kZ(e,t,r,n))return!0;if(n)return!1;if(r!==null)switch(r.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function oa(e,t,r,n,i,a,s){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=a,this.removeEmptyString=s}var Mi={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Mi[e]=new oa(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEac
vendor: 4,526 bytes, lines 1-2
1h(function(e){var t=e[0];Mi[t]=new oa(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){Mi[e]=new oa(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Mi[e]=new oa(e,2,!1,e,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Mi[e]=new oa(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){Mi[e]=new oa(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){Mi[e]=new oa(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){Mi[e]=new oa(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){Mi[e]=new oa(e,5,!1,e.toLowerCase(),null,!1,!1)});var o_=/[\-:]([a-z])/g;function l_(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(o_,l_);Mi[t]=new oa(t,1,!1,e,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(o_,l_);Mi[t]=new oa(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(o_,l_);Mi[t]=new oa(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){Mi[e]=new oa(e,1,!1,e.toLowerCase(),null,!1,!1)}),Mi.xlinkHref=new oa("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){Mi[e]=new oa(e,1,!1,e.toLowerCase(),null,!0,!0)});function c_(e,t,r,n){var i=Mi.hasOwnProperty(t)?Mi[t]:null;(i!==null?i.type!==0:n||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(EZ(t,r,i,n)&&(r=null),n||i===null?SZ(t)&&(r===null?e.removeAttribute(t):e.setAttribute(t,""+r)):i.mustUseProperty?e[i.propertyName]=r===null?i.type===3?!1:"":r:(t=i.attributeName,n=i.attributeNamespace,r===null?e.removeAttribute(t):(i=i.type,r=i===3||i===4&&r===!0?"":""+r,n?e.setAttributeNS(n,t,r):e.setAttribute(t,r))))}var Wl=xZ.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,G1=Symbol.for("react.element"),bd=Symbol.for("react.portal"),yd=Symbol.for("react.fragment"),u_=Symbol.for("react.strict_mode"),f_=Symbol.for("react.profiler"),x9=Symbol.for("react.provider"),_9=Symbol.for("react.context"),h_=Symbol.for("react.forward_ref"),d_=Symbol.for("react.suspense"),p_=Symbol.for("react.suspense_list"),m_=Symbol.for("react.memo"),Gc=Symbol.for("react.lazy"),S9=Symbol.for("react.offscreen"),k9=Symbol.iterator;function Vp(e){return e===null||typeof e!="object"?null:(e=k9&&e[k9]||e["@@iterator"],typeof e=="function"?e:null)}var yn=Object.assign,g_;function Zp(e){if(g_===void 0)try{throw Error()}catch(r){var t=r.stack.trim().match(/\n( *(at )?)/);g_=t&&t[1]||""}return`
2`+g_+e}var b_=!1;function y_(e,t){if(!e||b_)return"";b_=!0;var r=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(l){var n=l}Reflect.construct(e,[],t)}else{try{t.call()}catch(l){n=l}e.call(t.prototype)}else{try{throw Error()}catch(l){n=l}e()}}
vendor: 14,106 bytes, lines 2-5
2catch(l){if(l&&n&&typeof l.stack=="string"){for(var i=l.stack.split(`
3`),a=n.stack.split(`
4`),s=i.length-1,o=a.length-1;1<=s&&0<=o&&i[s]!==a[o];)o--;for(;1<=s&&0<=o;s--,o--)if(i[s]!==a[o]){if(s!==1||o!==1)do if(s--,o--,0>o||i[s]!==a[o]){var c=`
5`+i[s].replace(" at new "," at ");return e.displayName&&c.includes("<anonymous>")&&(c=c.replace("<anonymous>",e.displayName)),c}while(1<=s&&0<=o);break}}}finally{b_=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?Zp(e):""}function MZ(e){switch(e.tag){case 5:return Zp(e.type);case 16:return Zp("Lazy");case 13:return Zp("Suspense");case 19:return Zp("SuspenseList");case 0:case 2:case 15:return e=y_(e.type,!1),e;case 11:return e=y_(e.type.render,!1),e;case 1:return e=y_(e.type,!0),e;default:return""}}function v_(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case yd:return"Fragment";case bd:return"Portal";case f_:return"Profiler";case u_:return"StrictMode";case d_:return"Suspense";case p_:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case _9:return(e.displayName||"Context")+".Consumer";case x9:return(e._context.displayName||"Context")+".Provider";case h_:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case m_:return t=e.displayName||null,t!==null?t:v_(e.type)||"Memo";case Gc:t=e._payload,e=e._init;try{return v_(e(t))}catch{}}return null}function AZ(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return v_(t);case 8:return t===u_?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Yc(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function E9(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function CZ(e){var t=E9(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),n=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(s){n=""+s,a.call(this,s)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(s){n=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Y1(e){e._valueTracker||(e._valueTracker=CZ(e))}function M9(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),n="";return e&&(n=E9(e)?e.checked?"true":"false":e.value),e=n,e!==r?(t.setValue(e),!0):!1}function X1(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function w_(e,t){var r=t.checked;return yn({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??e._wrapperState.initialChecked})}function A9(e,t){var r=t.defaultValue==null?"":t.defaultValue,n=t.checked!=null?t.checked:t.defaultChecked;r=Yc(t.value!=null?t.value:r),e._wrapperState={initialChecked:n,initialValue:r,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function C9(e,t){t=t.checked,t!=null&&c_(e,"checked",t,!1)}function x_(e,t){C9(e,t);var r=Yc(t.value),n=t.type;if(r!=null)n==="number"?(r===0&&e.value===""||e.value!=r)&&(e.value=""+r):e.value!==""+r&&(e.value=""+r);else if(n==="submit"||n==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?__(e,t.type,r):t.hasOwnProperty("defaultValue")&&__(e,t.type,Yc(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function T9(e,t,r){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var n=t.type;if(!(n!=="submit"&&n!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,r||t===e.value||(e.value=t),e.defaultValue=t}r=e.name,r!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,r!==""&&(e.name=r)}function __(e,t,r){(t!=="number"||X1(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var $p=Array.isArray;function vd(e,t,r,n){if(e=e.options,t){t={};for(var i=0;i<r.length;i++)t["$"+r[i]]=!0;for(r=0;r<e.length;r++)i=t.hasOwnProperty("$"+e[r].value),e[r].selected!==i&&(e[r].selected=i),i&&n&&(e[r].defaultSelected=!0)}else{for(r=""+Yc(r),t=null,i=0;i<e.length;i++){if(e[i].value===r){e[i].selected=!0,n&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function S_(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(Ge(91));return yn({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function j9(e,t){var r=t.value;if(r==null){if(r=t.children,t=t.defaultValue,r!=null){if(t!=null)throw Error(Ge(92));if($p(r)){if(1<r.length)throw Error(Ge(93));r=r[0]}t=r}t==null&&(t=""),r=t}e._wrapperState={initialValue:Yc(r)}}function I9(e,t){var r=Yc(t.value),n=Yc(t.defaultValue);r!=null&&(r=""+r,r!==e.value&&(e.value=r),t.defaultValue==null&&e.defaultValue!==r&&(e.defaultValue=r)),n!=null&&(e.defaultValue=""+n)}function O9(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function B9(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function k_(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?B9(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var J1,R9=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,r,n,i){MSApp.execUnsafeLocalFunction(function(){return e(t,r,n,i)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(J1=J1||document.createElement("div"),J1.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=J1.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Hp(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var Wp={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},TZ=["Webkit","ms","Moz","O"];Object.keys(Wp).forEach(function(e){TZ.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Wp[t]=Wp[e]})});function N9(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||Wp.hasOwnProperty(e)&&Wp[e]?(""+t).trim():t+"px"}function F9(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var n=r.indexOf("--")===0,i=N9(r,t[r],n);r==="float"&&(r="cssFloat"),n?e.setProperty(r,i):e[r]=i}}var jZ=yn({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function E_(e,t){if(t){if(jZ[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(Ge(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(Ge(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(Ge(61))}if(t.style!=null&&typeof t.style!="object")throw Error(Ge(62))}}function M_(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var A_=null;function C_(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var T_=null,wd=null,xd=null;function P9(e){if(e=mm(e)){if(typeof T_!="function")throw Error(Ge(280));var t=e.stateNode;t&&(t=xy(t),T_(e.stateNode,e.type,t))}}function z9(e){wd?xd?xd.push(e):xd=[e]:wd=e}function L9(){if(wd){var e=wd,t=xd;if(xd=wd=null,P9(e),t)for(e=0;e<t.length;e++)P9(t[e])}}function D9(e,t){return e(t)}function U9(){}var j_=!1;function q9(e,t,r){if(j_)return e(t,r);j_=!0;try{return D9(e,t,r)}finally{j_=!1,(wd!==null||xd!==null)&&(U9(),L9())}}function Kp(e,t){var r=e.stateNode;if(r===null)return null;var n=xy(r);if(n===null)return null;r=n[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(n=!n.disabled)||(e=e.type,n=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!n;break e;default:e=!1}if(e)return null;if(r&&typeof r!="function")throw Error(Ge(231,t,typeof r));return r}var I_=!1;if(Hl)try{var Gp={};Object.defineProperty(Gp,"passive",{get:function(){I_=!0}}),window.addEventListener("test",Gp,Gp),window.removeEventListener("test",Gp,Gp)}catch{I_=!1}function IZ(e,t,r,n,i,a,s,o,c){var l=Array.prototype.slice.call(arguments,3);try{t.apply(r,l)}catch(u){this.onError(u)}}var Yp=!1,Q1=null,ey=!1,O_=null,OZ={onError:function(e){Yp=!0,Q1=e}};function BZ(e,t,r,n,i,a,s,o,c){Yp=!1,Q1=null,IZ.apply(OZ,arguments)}function RZ(e,t,r,n,i,a,s,o,c){if(BZ.apply(this,arguments),Yp){if(Yp){var l=Q1;Yp=!1,Q1=null}else throw Error(Ge(198));ey||(ey=!0,O_=l)}}function jf(e){var t=e,r=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(r=t.return),e=t.return;while(e)}return t.tag===3?r:null}function V9(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function Z9(e){if(jf(e)!==e)throw Error(Ge(188))}function NZ(e){var t=e.alternate;if(!t){if(t=jf(e),t===null)throw Error(Ge(188));return t!==e?null:e}for(var r=e,n=t;;){var i=r.return;if(i===null)break;var a=i.alternate;if(a===null){if(n=i.return,n!==null){r=n;continue}break}if(i.child===a.child){for(a=i.child;a;){if(a===r)return Z9(i),e;if(a===n)return Z9(i),t;a=a.sibling}throw Error(Ge(188))}if(r.return!==n.return)r=i,n=a;else{for(var s=!1,o=i.child;o;){if(o===r){s=!0,r=i,n=a;break}if(o===n){s=!0,n=i,r=a;break}o=o.sibling}if(!s){for(o=a.child;o;){if(o===r){s=!0,r=a,n=i;break}if(o===n){s=!0,n=a,r=i;break}o=o.sibling}if(!s)throw Error(Ge(189))}}if(r.alternate!==n)throw Error(Ge(190))}if(r.tag!==3)throw Error(Ge(188));return r.stateNode.current===r?e:t}function $9(e){return e=NZ(e),e!==null?H9(e):null}function H9(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=H9(e);if(t!==null)return t;e=e.sibling}return null}var W9=Za.unstable_scheduleCallback,K9=Za.unstable_cancelCallback,FZ=Za.unstable_shouldYield,PZ=Za.unstable_requestPaint,In=Za.unstable_now,zZ=Za.unstable_getCurrentPriorityLevel,B_=Za.unstable_ImmediatePriority,G9=Za.unstable_UserBlockingPriority,ty=Za.unstable_NormalPriority,LZ=Za.unstable_LowPriority,Y9=Za.unstable_IdlePriority,ry=null,Wo=null;function DZ(e){if(Wo&&typeof Wo.onCommitFiberRoot=="function")try{Wo.onCommitFiberRoot(ry,e,void 0,(e.current.flags&128)===128)}catch{}}var Ks=Math.clz32?Math.clz32:VZ,UZ=Math.log,qZ=Math.LN2;function VZ(e){return e>>>=0,e===0?32:31-(UZ(e)/qZ|0)|0}var ny=64,iy=4194304;function Xp(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function ay(e,t){var r=e.pendingLanes;if(r===0)return 0;var n=0,i=e.suspendedLanes,a=e.pingedLanes,s=r&268435455;if(s!==0){var o=s&~i;o!==0?n=Xp(o):(a&=s,a!==0&&(n=Xp(a)))}else s=r&~i,s!==0?n=Xp(s):a!==0&&(n=Xp(a));if(n===0)return 0;if(t!==0&&t!==n&&!(t&i)&&(i=n&-n,a=t&-t,i>=a||i===16&&(a&4194240)!==0))return t;if(n&4&&(n|=r&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=n;0<t;)r=31-Ks(t),i=1<<r,n|=e[r],t&=~i;return n}function ZZ(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function $Z(e,t){for(var r=e.suspendedLanes,n=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes;0<a;){var s=31-Ks(a),o=1<<s,c=i[s];c===-1?(!(o&r)||o&n)&&(i[s]=ZZ(o,t)):c<=t&&(e.expiredLanes|=o),a&=~o}}function R_(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function X9(){var e=ny;return ny<<=1,!(ny&4194240)&&(ny=64),e}function N_(e){for(var t=[],r=0;31>r;r++)t.push(e);return t}
vendor: 4,087 bytes, line 5
5function Jp(e,t,r){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Ks(t),e[t]=r}function HZ(e,t){var r=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var n=e.eventTimes;for(e=e.expirationTimes;0<r;){var i=31-Ks(r),a=1<<i;t[i]=0,n[i]=-1,e[i]=-1,r&=~a}}function F_(e,t){var r=e.entangledLanes|=t;for(e=e.entanglements;r;){var n=31-Ks(r),i=1<<n;i&t|e[n]&t&&(e[n]|=t),r&=~i}}var Fr=0;function J9(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var Q9,P_,eM,tM,rM,z_=!1,sy=[],Xc=null,Jc=null,Qc=null,Qp=new Map,em=new Map,eu=[],WZ="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function nM(e,t){switch(e){case"focusin":case"focusout":Xc=null;break;case"dragenter":case"dragleave":Jc=null;break;case"mouseover":case"mouseout":Qc=null;break;case"pointerover":case"pointerout":Qp.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":em.delete(t.pointerId)}}function tm(e,t,r,n,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:r,eventSystemFlags:n,nativeEvent:a,targetContainers:[i]},t!==null&&(t=mm(t),t!==null&&P_(t)),e):(e.eventSystemFlags|=n,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function KZ(e,t,r,n,i){switch(t){case"focusin":return Xc=tm(Xc,e,t,r,n,i),!0;case"dragenter":return Jc=tm(Jc,e,t,r,n,i),!0;case"mouseover":return Qc=tm(Qc,e,t,r,n,i),!0;case"pointerover":var a=i.pointerId;return Qp.set(a,tm(Qp.get(a)||null,e,t,r,n,i)),!0;case"gotpointercapture":return a=i.pointerId,em.set(a,tm(em.get(a)||null,e,t,r,n,i)),!0}return!1}function iM(e){var t=If(e.target);if(t!==null){var r=jf(t);if(r!==null){if(t=r.tag,t===13){if(t=V9(r),t!==null){e.blockedOn=t,rM(e.priority,function(){eM(r)});return}}else if(t===3&&r.stateNode.current.memoizedState.isDehydrated){e.blockedOn=r.tag===3?r.stateNode.containerInfo:null;return}}}e.blockedOn=null}function oy(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var r=D_(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(r===null){r=e.nativeEvent;var n=new r.constructor(r.type,r);A_=n,r.target.dispatchEvent(n),A_=null}else return t=mm(r),t!==null&&P_(t),e.blockedOn=r,!1;t.shift()}return!0}function aM(e,t,r){oy(e)&&r.delete(t)}function GZ(){z_=!1,Xc!==null&&oy(Xc)&&(Xc=null),Jc!==null&&oy(Jc)&&(Jc=null),Qc!==null&&oy(Qc)&&(Qc=null),Qp.forEach(aM),em.forEach(aM)}function rm(e,t){e.blockedOn===t&&(e.blockedOn=null,z_||(z_=!0,Za.unstable_scheduleCallback(Za.unstable_NormalPriority,GZ)))}function nm(e){function t(i){return rm(i,e)}if(0<sy.length){rm(sy[0],e);for(var r=1;r<sy.length;r++){var n=sy[r];n.blockedOn===e&&(n.blockedOn=null)}}for(Xc!==null&&rm(Xc,e),Jc!==null&&rm(Jc,e),Qc!==null&&rm(Qc,e),Qp.forEach(t),em.forEach(t),r=0;r<eu.length;r++)n=eu[r],n.blockedOn===e&&(n.blockedOn=null);for(;0<eu.length&&(r=eu[0],r.blockedOn===null);)iM(r),r.blockedOn===null&&eu.shift()}var _d=Wl.ReactCurrentBatchConfig,ly=!0;function YZ(e,t,r,n){var i=Fr,a=_d.transition;_d.transition=null;try{Fr=1,L_(e,t,r,n)}finally{Fr=i,_d.transition=a}}function XZ(e,t,r,n){var i=Fr,a=_d.transition;_d.transition=null;try{Fr=4,L_(e,t,r,n)}finally{Fr=i,_d.transition=a}}function L_(e,t,r,n){if(ly){var i=D_(e,t,r,n);if(i===null)n3(e,t,n,cy,r),nM(e,n);else if(KZ(i,e,t,r,n))n.stopPropagation();else if(nM(e,n),t&4&&-1<WZ.indexOf(e)){for(;i!==null;){var a=mm(i);if(a!==null&&Q9(a),a=D_(e,t,r,n),a===null&&n3(e,t,n,cy,r),a===i)break;i=a}i!==null&&n.stopPropagation()}else n3(e,t,n,null,r)}}var cy=null;function D_(e,t,r,n){if(cy=null,e=C_(n),e=If(e),e!==null)if(t=jf(e),t===null)e=null;else if(r=t.tag,r===13){if(e=V9(t),e!==null)return e;e=null}else if(r===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return cy=e,null}
vendor: 10,401 bytes, line 5
5function sM(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(zZ()){case B_:return 1;case G9:return 4;case ty:case LZ:return 16;case Y9:return 536870912;default:return 16}default:return 16}}var tu=null,U_=null,uy=null;function oM(){if(uy)return uy;var e,t=U_,r=t.length,n,i="value"in tu?tu.value:tu.textContent,a=i.length;for(e=0;e<r&&t[e]===i[e];e++);var s=r-e;for(n=1;n<=s&&t[r-n]===i[a-n];n++);return uy=i.slice(e,1<n?1-n:void 0)}function fy(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function hy(){return!0}function lM(){return!1}function $a(e){function t(r,n,i,a,s){this._reactName=r,this._targetInst=i,this.type=n,this.nativeEvent=a,this.target=s,this.currentTarget=null;for(var o in e)e.hasOwnProperty(o)&&(r=e[o],this[o]=r?r(a):a[o]);return this.isDefaultPrevented=(a.defaultPrevented!=null?a.defaultPrevented:a.returnValue===!1)?hy:lM,this.isPropagationStopped=lM,this}return yn(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var r=this.nativeEvent;r&&(r.preventDefault?r.preventDefault():typeof r.returnValue!="unknown"&&(r.returnValue=!1),this.isDefaultPrevented=hy)},stopPropagation:function(){var r=this.nativeEvent;r&&(r.stopPropagation?r.stopPropagation():typeof r.cancelBubble!="unknown"&&(r.cancelBubble=!0),this.isPropagationStopped=hy)},persist:function(){},isPersistent:hy}),t}var Sd={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},q_=$a(Sd),im=yn({},Sd,{view:0,detail:0}),JZ=$a(im),V_,Z_,am,dy=yn({},im,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:H_,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==am&&(am&&e.type==="mousemove"?(V_=e.screenX-am.screenX,Z_=e.screenY-am.screenY):Z_=V_=0,am=e),V_)},movementY:function(e){return"movementY"in e?e.movementY:Z_}}),cM=$a(dy),QZ=yn({},dy,{dataTransfer:0}),e$=$a(QZ),t$=yn({},im,{relatedTarget:0}),$_=$a(t$),r$=yn({},Sd,{animationName:0,elapsedTime:0,pseudoElement:0}),n$=$a(r$),i$=yn({},Sd,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),a$=$a(i$),s$=yn({},Sd,{data:0}),uM=$a(s$),o$={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},l$={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},c$={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function u$(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=c$[e])?!!t[e]:!1}function H_(){return u$}var f$=yn({},im,{key:function(e){if(e.key){var t=o$[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=fy(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?l$[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:H_,charCode:function(e){return e.type==="keypress"?fy(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?fy(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),h$=$a(f$),d$=yn({},dy,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),fM=$a(d$),p$=yn({},im,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:H_}),m$=$a(p$),g$=yn({},Sd,{propertyName:0,elapsedTime:0,pseudoElement:0}),b$=$a(g$),y$=yn({},dy,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),v$=$a(y$),w$=[9,13,27,32],W_=Hl&&"CompositionEvent"in window,sm=null;Hl&&"documentMode"in document&&(sm=document.documentMode);var x$=Hl&&"TextEvent"in window&&!sm,hM=Hl&&(!W_||sm&&8<sm&&11>=sm),dM=" ",pM=!1;function mM(e,t){switch(e){case"keyup":return w$.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function gM(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var kd=!1;function _$(e,t){switch(e){case"compositionend":return gM(t);case"keypress":return t.which!==32?null:(pM=!0,dM);case"textInput":return e=t.data,e===dM&&pM?null:e;default:return null}}function S$(e,t){if(kd)return e==="compositionend"||!W_&&mM(e,t)?(e=oM(),uy=U_=tu=null,kd=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return hM&&t.locale!=="ko"?null:t.data;default:return null}}var k$={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function bM(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!k$[e.type]:t==="textarea"}function yM(e,t,r,n){z9(n),t=yy(t,"onChange"),0<t.length&&(r=new q_("onChange","change",null,r,n),e.push({event:r,listeners:t}))}var om=null,lm=null;function E$(e){FM(e,0)}function py(e){var t=Td(e);if(M9(t))return e}function M$(e,t){if(e==="change")return t}var vM=!1;if(Hl){var K_;if(Hl){var G_="oninput"in document;if(!G_){var wM=document.createElement("div");wM.setAttribute("oninput","return;"),G_=typeof wM.oninput=="function"}K_=G_}else K_=!1;vM=K_&&(!document.documentMode||9<document.documentMode)}function xM(){om&&(om.detachEvent("onpropertychange",_M),lm=om=null)}function _M(e){if(e.propertyName==="value"&&py(lm)){var t=[];yM(t,lm,e,C_(e)),q9(E$,t)}}function A$(e,t,r){e==="focusin"?(xM(),om=t,lm=r,om.attachEvent("onpropertychange",_M)):e==="focusout"&&xM()}function C$(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return py(lm)}function T$(e,t){if(e==="click")return py(t)}function j$(e,t){if(e==="input"||e==="change")return py(t)}function I$(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Gs=typeof Object.is=="function"?Object.is:I$;function cm(e,t){if(Gs(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(n=0;n<r.length;n++){var i=r[n];if(!s_.call(t,i)||!Gs(e[i],t[i]))return!1}return!0}function SM(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function kM(e,t){var r=SM(e);e=0;for(var n;r;){if(r.nodeType===3){if(n=e+r.textContent.length,e<=t&&n>=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=SM(r)}}function EM(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?EM(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function MM(){for(var e=window,t=X1();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=X1(e.document)}return t}function Y_(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function O$(e){var t=MM(),r=e.focusedElem,n=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&EM(r.ownerDocument.documentElement,r)){if(n!==null&&Y_(r)){if(t=n.start,e=n.end,e===void 0&&(e=t),"selectionStart"in r)r.selectionStart=t,r.selectionEnd=Math.min(e,r.value.length);else if(e=(t=r.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=r.textContent.length,a=Math.min(n.start,i);n=n.end===void 0?a:Math.min(n.end,i),!e.extend&&a>n&&(i=n,n=a,a=i),i=kM(r,a);var s=kM(r,n);i&&s&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==s.node||e.focusOffset!==s.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),a>n?(e.addRange(t),e.extend(s.node,s.offset)):(t.setEnd(s.node,s.offset),e.addRange(t)))}}for(t=[],e=r;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r<t.length;r++)e=t[r],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var B$=Hl&&"documentMode"in document&&11>=document.documentMode,Ed=null,X_=null,um=null,J_=!1;function AM(e,t,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;J_||Ed==null||Ed!==X1(n)||(n=Ed,"selectionStart"in n&&Y_(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focu
vendor: 10,098 bytes, lines 5-6
5sNode:n.focusNode,focusOffset:n.focusOffset}),um&&cm(um,n)||(um=n,n=yy(X_,"onSelect"),0<n.length&&(t=new q_("onSelect","select",null,t,r),e.push({event:t,listeners:n}),t.target=Ed)))}function my(e,t){var r={};return r[e.toLowerCase()]=t.toLowerCase(),r["Webkit"+e]="webkit"+t,r["Moz"+e]="moz"+t,r}var Md={animationend:my("Animation","AnimationEnd"),animationiteration:my("Animation","AnimationIteration"),animationstart:my("Animation","AnimationStart"),transitionend:my("Transition","TransitionEnd")},Q_={},CM={};Hl&&(CM=document.createElement("div").style,"AnimationEvent"in window||(delete Md.animationend.animation,delete Md.animationiteration.animation,delete Md.animationstart.animation),"TransitionEvent"in window||delete Md.transitionend.transition);function gy(e){if(Q_[e])return Q_[e];if(!Md[e])return e;var t=Md[e],r;for(r in t)if(t.hasOwnProperty(r)&&r in CM)return Q_[e]=t[r];return e}var TM=gy("animationend"),jM=gy("animationiteration"),IM=gy("animationstart"),OM=gy("transitionend"),BM=new Map,RM="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function ru(e,t){BM.set(e,t),Tf(t,[e])}for(var e3=0;e3<RM.length;e3++){var t3=RM[e3],R$=t3.toLowerCase(),N$=t3[0].toUpperCase()+t3.slice(1);ru(R$,"on"+N$)}ru(TM,"onAnimationEnd"),ru(jM,"onAnimationIteration"),ru(IM,"onAnimationStart"),ru("dblclick","onDoubleClick"),ru("focusin","onFocus"),ru("focusout","onBlur"),ru(OM,"onTransitionEnd"),gd("onMouseEnter",["mouseout","mouseover"]),gd("onMouseLeave",["mouseout","mouseover"]),gd("onPointerEnter",["pointerout","pointerover"]),gd("onPointerLeave",["pointerout","pointerover"]),Tf("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Tf("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Tf("onBeforeInput",["compositionend","keypress","textInput","paste"]),Tf("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Tf("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Tf("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var fm="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),F$=new Set("cancel close invalid load scroll toggle".split(" ").concat(fm));function NM(e,t,r){var n=e.type||"unknown-event";e.currentTarget=r,RZ(n,t,void 0,e),e.currentTarget=null}function FM(e,t){t=(t&4)!==0;for(var r=0;r<e.length;r++){var n=e[r],i=n.event;n=n.listeners;e:{var a=void 0;if(t)for(var s=n.length-1;0<=s;s--){var o=n[s],c=o.instance,l=o.currentTarget;if(o=o.listener,c!==a&&i.isPropagationStopped())break e;NM(i,o,l),a=c}else for(s=0;s<n.length;s++){if(o=n[s],c=o.instance,l=o.currentTarget,o=o.listener,c!==a&&i.isPropagationStopped())break e;NM(i,o,l),a=c}}}if(ey)throw e=O_,ey=!1,O_=null,e}function en(e,t){var r=t[c3];r===void 0&&(r=t[c3]=new Set);var n=e+"__bubble";r.has(n)||(PM(t,e,2,!1),r.add(n))}function r3(e,t,r){var n=0;t&&(n|=4),PM(r,e,n,t)}var by="_reactListening"+Math.random().toString(36).slice(2);function hm(e){if(!e[by]){e[by]=!0,y9.forEach(function(r){r!=="selectionchange"&&(F$.has(r)||r3(r,!1,e),r3(r,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[by]||(t[by]=!0,r3("selectionchange",!1,t))}}function PM(e,t,r,n){switch(sM(t)){case 1:var i=YZ;break;case 4:i=XZ;break;default:i=L_}r=i.bind(null,t,r,e),i=void 0,!I_||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(i=!0),n?i!==void 0?e.addEventListener(t,r,{capture:!0,passive:i}):e.addEventListener(t,r,!0):i!==void 0?e.addEventListener(t,r,{passive:i}):e.addEventListener(t,r,!1)}function n3(e,t,r,n,i){var a=n;if(!(t&1)&&!(t&2)&&n!==null)e:for(;;){if(n===null)return;var s=n.tag;if(s===3||s===4){var o=n.stateNode.containerInfo;if(o===i||o.nodeType===8&&o.parentNode===i)break;if(s===4)for(s=n.return;s!==null;){var c=s.tag;if((c===3||c===4)&&(c=s.stateNode.containerInfo,c===i||c.nodeType===8&&c.parentNode===i))return;s=s.return}for(;o!==null;){if(s=If(o),s===null)return;if(c=s.tag,c===5||c===6){n=a=s;continue e}o=o.parentNode}}n=n.return}q9(function(){var l=a,u=C_(r),d=[];e:{var p=BM.get(e);if(p!==void 0){var w=q_,O=e;switch(e){case"keypress":if(fy(r)===0)break e;case"keydown":case"keyup":w=h$;break;case"focusin":O="focus",w=$_;break;case"focusout":O="blur",w=$_;break;case"beforeblur":case"afterblur":w=$_;break;case"click":if(r.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":w=cM;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":w=e$;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":w=m$;break;case TM:case jM:case IM:w=n$;break;case OM:w=b$;break;case"scroll":w=JZ;break;case"wheel":w=v$;break;case"copy":case"cut":case"paste":w=a$;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":w=fM}var I=(t&4)!==0,R=!I&&e==="scroll",C=I?p!==null?p+"Capture":null:p;I=[];for(var j=l,N;j!==null;){N=j;var P=N.stateNode;if(N.tag===5&&P!==null&&(N=P,C!==null&&(P=Kp(j,C),P!=null&&I.push(dm(j,P,N)))),R)break;j=j.return}0<I.length&&(p=new w(p,O,null,r,u),d.push({event:p,listeners:I}))}}if(!(t&7)){e:{if(p=e==="mouseover"||e==="pointerover",w=e==="mouseout"||e==="pointerout",p&&r!==A_&&(O=r.relatedTarget||r.fromElement)&&(If(O)||O[Kl]))break e;if((w||p)&&(p=u.window===u?u:(p=u.ownerDocument)?p.defaultView||p.parentWindow:window,w?(O=r.relatedTarget||r.toElement,w=l,O=O?If(O):null,O!==null&&(R=jf(O),O!==R||O.tag!==5&&O.tag!==6)&&(O=null)):(w=null,O=l),w!==O)){if(I=cM,P="onMouseLeave",C="onMouseEnter",j="mouse",(e==="pointerout"||e==="pointerover")&&(I=fM,P="onPointerLeave",C="onPointerEnter",j="pointer"),R=w==null?p:Td(w),N=O==null?p:Td(O),p=new I(P,j+"leave",w,r,u),p.target=R,p.relatedTarget=N,P=null,If(u)===l&&(I=new I(C,j+"enter",O,r,u),I.target=N,I.relatedTarget=R,P=I),R=P,w&&O)t:{for(I=w,C=O,j=0,N=I;N;N=Ad(N))j++;for(N=0,P=C;P;P=Ad(P))N++;for(;0<j-N;)I=Ad(I),j--;for(;0<N-j;)C=Ad(C),N--;for(;j--;){if(I===C||C!==null&&I===C.alternate)break t;I=Ad(I),C=Ad(C)}I=null}else I=null;w!==null&&zM(d,p,w,I,!1),O!==null&&R!==null&&zM(d,R,O,I,!0)}}e:{if(p=l?Td(l):window,w=p.nodeName&&p.nodeName.toLowerCase(),w==="select"||w==="input"&&p.type==="file")var Z=M$;else if(bM(p))if(vM)Z=j$;else{Z=C$;var X=A$}else(w=p.nodeName)&&w.toLowerCase()==="input"&&(p.type==="checkbox"||p.type==="radio")&&(Z=T$);if(Z&&(Z=Z(e,l))){yM(d,Z,r,u);break e}X&&X(e,p,l),e==="focusout"&&(X=p._wrapperState)&&X.controlled&&p.type==="number"&&__(p,"number",p.value)}switch(X=l?Td(l):window,e){case"focusin":(bM(X)||X.contentEditable==="true")&&(Ed=X,X_=l,um=null);break;case"focusout":um=X_=Ed=null;break;case"mousedown":J_=!0;break;case"contextmenu":case"mouseup":case"dragend":J_=!1,AM(d,r,u);break;case"selectionchange":if(B$)break;case"keydown":case"keyup":AM(d,r,u)}var re;if(W_)e:{switch(e){case"compositionstart":var ne="onCompositionStart";break e;case"compositionend":ne="onCompositionEnd";break e;case"compositionupdate":ne="onCompositionUpdate";break e}ne=void 0}else kd?mM(e,r)&&(ne="onCompositionEnd"):e==="keydown"&&r.keyCode===229&&(ne="onCompositionStart");ne&&(hM&&r.locale!=="ko"&&(kd||ne!=="onCompositionStart"?ne==="onCompositionEnd"&&kd&&(re=oM()):(tu=u,U_="value"in tu?tu.value:tu.textContent,kd=!0)),X=yy(l,ne),0<X.length&&(ne=new uM(ne,e,null,r,u),d.push({event:ne,listeners:X}),re?ne.data=re:(re=gM(r),re!==null&&(ne.data=re)))),(re=x$?_$(e,r):S$(e,r))&&(l=yy(l,"onBeforeInput"),0<l.length&&(u=new uM("onBeforeInput","beforeinput",null,r,u),d.push({event:u,listeners:l}),u.data=re))}FM(d,t)})}function dm(e,t,r){return{instance:e,listener:t,currentTarget:r}}function yy(e,t){for(var r=t+"Capture",n=[];e!==null;){var i=e,a=i.stateNode;i.tag===5&&a!==null&&(i=a,a=Kp(e,r),a!=null&&n.unshift(dm(e,a,i)),a=Kp(e,t),a!=null&&n.push(dm(e,a,i))),e=e.return}return n}function Ad(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function zM(e,t,r,n,i){for(var a=t._reactName,s=[];r!==null&&r!==n;){var o=r,c=o.alternate,l=o.stateNode;if(c!==null&&c===n)break;o.tag===5&&l!==null&&(o=l,i?(c=Kp(r,a),c!=null&&s.unshift(dm(r,c,o))):i||(c=Kp(r,a),c!=null&&s.push(dm(r,c,o)))),r=r.return}s.length!==0&&e.push({event:t,listeners:s})}var P$=/\r\n?/g,z$=/\u0000|\uFFFD/g;function LM(e){return(typeof e=="string"?e:""+e).replace(P$,`
6`).replace(z$,"")}function vy(e,t,r){if(t=LM(t),LM(e)!==t&&r)throw Error(Ge(425))}function wy(){}var i3=null,a3=null;function s3(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var o3=typeof setTimeout=="function"?setTimeout:void 0,L$=typeof clearTimeout=="function"?clearTimeout:void 0,DM=typeof Promise=="function"?Promise:void 0,D$=typeof queueMicrotask=="function"?queueMicrotask:typeof DM<"u"?function(e){return DM.resolve(null).then(e).catch(U$)}:o3;function U$(e){setTimeout(function(){throw e})}function l3(e,t){var r=t,n=0;do{var i=r.nextSibling;if(e.removeChild(r),i&&i.nodeType===8)if(r=i.data,r==="/$"){if(n===0){e.removeChild(i),nm(t);return}n--}else r!=="$"&&r!=="$?"&&r!=="$!"||n++;r=i}
vendor: 4,383 bytes, line 6
6while(r);nm(t)}function nu(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function UM(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="$"||r==="$!"||r==="$?"){if(t===0)return e;t--}else r==="/$"&&t++}e=e.previousSibling}return null}var Cd=Math.random().toString(36).slice(2),Ko="__reactFiber$"+Cd,pm="__reactProps$"+Cd,Kl="__reactContainer$"+Cd,c3="__reactEvents$"+Cd,q$="__reactListeners$"+Cd,V$="__reactHandles$"+Cd;function If(e){var t=e[Ko];if(t)return t;for(var r=e.parentNode;r;){if(t=r[Kl]||r[Ko]){if(r=t.alternate,t.child!==null||r!==null&&r.child!==null)for(e=UM(e);e!==null;){if(r=e[Ko])return r;e=UM(e)}return t}e=r,r=e.parentNode}return null}function mm(e){return e=e[Ko]||e[Kl],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Td(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(Ge(33))}function xy(e){return e[pm]||null}var u3=[],jd=-1;function iu(e){return{current:e}}function tn(e){0>jd||(e.current=u3[jd],u3[jd]=null,jd--)}function Hr(e,t){jd++,u3[jd]=e.current,e.current=t}var au={},Li=iu(au),va=iu(!1),Of=au;function Id(e,t){var r=e.type.contextTypes;if(!r)return au;var n=e.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===t)return n.__reactInternalMemoizedMaskedChildContext;var i={},a;for(a in r)i[a]=t[a];return n&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function wa(e){return e=e.childContextTypes,e!=null}function _y(){tn(va),tn(Li)}function qM(e,t,r){if(Li.current!==au)throw Error(Ge(168));Hr(Li,t),Hr(va,r)}function VM(e,t,r){var n=e.stateNode;if(t=t.childContextTypes,typeof n.getChildContext!="function")return r;n=n.getChildContext();for(var i in n)if(!(i in t))throw Error(Ge(108,AZ(e)||"Unknown",i));return yn({},r,n)}function Sy(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||au,Of=Li.current,Hr(Li,e),Hr(va,va.current),!0}function ZM(e,t,r){var n=e.stateNode;if(!n)throw Error(Ge(169));r?(e=VM(e,t,Of),n.__reactInternalMemoizedMergedChildContext=e,tn(va),tn(Li),Hr(Li,e)):tn(va),Hr(va,r)}var Gl=null,ky=!1,f3=!1;function $M(e){Gl===null?Gl=[e]:Gl.push(e)}function Z$(e){ky=!0,$M(e)}function su(){if(!f3&&Gl!==null){f3=!0;var e=0,t=Fr;try{var r=Gl;for(Fr=1;e<r.length;e++){var n=r[e];do n=n(!0);while(n!==null)}Gl=null,ky=!1}catch(i){throw Gl!==null&&(Gl=Gl.slice(e+1)),W9(B_,su),i}finally{Fr=t,f3=!1}}return null}var Od=[],Bd=0,Ey=null,My=0,ys=[],vs=0,Bf=null,Yl=1,Xl="";function Rf(e,t){Od[Bd++]=My,Od[Bd++]=Ey,Ey=e,My=t}function HM(e,t,r){ys[vs++]=Yl,ys[vs++]=Xl,ys[vs++]=Bf,Bf=e;var n=Yl;e=Xl;var i=32-Ks(n)-1;n&=~(1<<i),r+=1;var a=32-Ks(t)+i;if(30<a){var s=i-i%5;a=(n&(1<<s)-1).toString(32),n>>=s,i-=s,Yl=1<<32-Ks(t)+i|r<<i|n,Xl=a+e}else Yl=1<<a|r<<i|n,Xl=e}function h3(e){e.return!==null&&(Rf(e,1),HM(e,1,0))}function d3(e){for(;e===Ey;)Ey=Od[--Bd],Od[Bd]=null,My=Od[--Bd],Od[Bd]=null;for(;e===Bf;)Bf=ys[--vs],ys[vs]=null,Xl=ys[--vs],ys[vs]=null,Yl=ys[--vs],ys[vs]=null}var Ha=null,Wa=null,ln=!1,Ys=null;function WM(e,t){var r=Ss(5,null,null,0);r.elementType="DELETED",r.stateNode=t,r.return=e,t=e.deletions,t===null?(e.deletions=[r],e.flags|=16):t.push(r)}function KM(e,t){switch(e.tag){case 5:var r=e.type;return t=t.nodeType!==1||r.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,Ha=e,Wa=nu(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Ha=e,Wa=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(r=Bf!==null?{id:Yl,overflow:Xl}:null,e.memoizedState={dehydrated:t,treeContext:r,retryLane:1073741824},r=Ss(18,null,null,0),r.stateNode=t,r.return=e,e.child=r,Ha=e,Wa=null,!0):!1;default:return!1}}function p3(e){return(e.mode&1)!==0&&(e.flags&128)===0}function m3(e){if(ln){var t=Wa;if(t){var r=t;if(!KM(e,t)){if(p3(e))throw Error(Ge(418));t=nu(r.nextSibling);var n=Ha;t&&KM(e,t)?WM(n,r):(e.flags=e.flags&-4097|2,ln=!1,Ha=e)}}else{if(p3(e))throw Error(Ge(418));e.flags=e.flags&-4097|2,ln=!1,Ha=e}}}function GM(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Ha=e}function Ay(e){if(e!==Ha)return!1;if(!ln)return GM(e),ln=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!s3(e.type,e.memoizedProps)),t&&(t=Wa)){if
vendor: 11,751 bytes, line 6
6(p3(e))throw YM(),Error(Ge(418));for(;t;)WM(e,t),t=nu(t.nextSibling)}if(GM(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(Ge(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="/$"){if(t===0){Wa=nu(e.nextSibling);break e}t--}else r!=="$"&&r!=="$!"&&r!=="$?"||t++}e=e.nextSibling}Wa=null}}else Wa=Ha?nu(e.stateNode.nextSibling):null;return!0}function YM(){for(var e=Wa;e;)e=nu(e.nextSibling)}function Rd(){Wa=Ha=null,ln=!1}function g3(e){Ys===null?Ys=[e]:Ys.push(e)}var $$=Wl.ReactCurrentBatchConfig;function gm(e,t,r){if(e=r.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(r._owner){if(r=r._owner,r){if(r.tag!==1)throw Error(Ge(309));var n=r.stateNode}if(!n)throw Error(Ge(147,e));var i=n,a=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===a?t.ref:(t=function(s){var o=i.refs;s===null?delete o[a]:o[a]=s},t._stringRef=a,t)}if(typeof e!="string")throw Error(Ge(284));if(!r._owner)throw Error(Ge(290,e))}return e}function Cy(e,t){throw e=Object.prototype.toString.call(t),Error(Ge(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function XM(e){var t=e._init;return t(e._payload)}function JM(e){function t(C,j){if(e){var N=C.deletions;N===null?(C.deletions=[j],C.flags|=16):N.push(j)}}function r(C,j){if(!e)return null;for(;j!==null;)t(C,j),j=j.sibling;return null}function n(C,j){for(C=new Map;j!==null;)j.key!==null?C.set(j.key,j):C.set(j.index,j),j=j.sibling;return C}function i(C,j){return C=pu(C,j),C.index=0,C.sibling=null,C}function a(C,j,N){return C.index=N,e?(N=C.alternate,N!==null?(N=N.index,N<j?(C.flags|=2,j):N):(C.flags|=2,j)):(C.flags|=1048576,j)}function s(C){return e&&C.alternate===null&&(C.flags|=2),C}function o(C,j,N,P){return j===null||j.tag!==6?(j=s6(N,C.mode,P),j.return=C,j):(j=i(j,N),j.return=C,j)}function c(C,j,N,P){var Z=N.type;return Z===yd?u(C,j,N.props.children,P,N.key):j!==null&&(j.elementType===Z||typeof Z=="object"&&Z!==null&&Z.$$typeof===Gc&&XM(Z)===j.type)?(P=i(j,N.props),P.ref=gm(C,j,N),P.return=C,P):(P=Jy(N.type,N.key,N.props,null,C.mode,P),P.ref=gm(C,j,N),P.return=C,P)}function l(C,j,N,P){return j===null||j.tag!==4||j.stateNode.containerInfo!==N.containerInfo||j.stateNode.implementation!==N.implementation?(j=o6(N,C.mode,P),j.return=C,j):(j=i(j,N.children||[]),j.return=C,j)}function u(C,j,N,P,Z){return j===null||j.tag!==7?(j=qf(N,C.mode,P,Z),j.return=C,j):(j=i(j,N),j.return=C,j)}function d(C,j,N){if(typeof j=="string"&&j!==""||typeof j=="number")return j=s6(""+j,C.mode,N),j.return=C,j;if(typeof j=="object"&&j!==null){switch(j.$$typeof){case G1:return N=Jy(j.type,j.key,j.props,null,C.mode,N),N.ref=gm(C,null,j),N.return=C,N;case bd:return j=o6(j,C.mode,N),j.return=C,j;case Gc:var P=j._init;return d(C,P(j._payload),N)}if($p(j)||Vp(j))return j=qf(j,C.mode,N,null),j.return=C,j;Cy(C,j)}return null}function p(C,j,N,P){var Z=j!==null?j.key:null;if(typeof N=="string"&&N!==""||typeof N=="number")return Z!==null?null:o(C,j,""+N,P);if(typeof N=="object"&&N!==null){switch(N.$$typeof){case G1:return N.key===Z?c(C,j,N,P):null;case bd:return N.key===Z?l(C,j,N,P):null;case Gc:return Z=N._init,p(C,j,Z(N._payload),P)}if($p(N)||Vp(N))return Z!==null?null:u(C,j,N,P,null);Cy(C,N)}return null}function w(C,j,N,P,Z){if(typeof P=="string"&&P!==""||typeof P=="number")return C=C.get(N)||null,o(j,C,""+P,Z);if(typeof P=="object"&&P!==null){switch(P.$$typeof){case G1:return C=C.get(P.key===null?N:P.key)||null,c(j,C,P,Z);case bd:return C=C.get(P.key===null?N:P.key)||null,l(j,C,P,Z);case Gc:var X=P._init;return w(C,j,N,X(P._payload),Z)}if($p(P)||Vp(P))return C=C.get(N)||null,u(j,C,P,Z,null);Cy(j,P)}return null}function O(C,j,N,P){for(var Z=null,X=null,re=j,ne=j=0,ae=null;re!==null&&ne<N.length;ne++){re.index>ne?(ae=re,re=null):ae=re.sibling;var ue=p(C,re,N[ne],P);if(ue===null){re===null&&(re=ae);break}e&&re&&ue.alternate===null&&t(C,re),j=a(ue,j,ne),X===null?Z=ue:X.sibling=ue,X=ue,re=ae}if(ne===N.length)return r(C,re),ln&&Rf(C,ne),Z;if(re===null){for(;ne<N.length;ne++)re=d(C,N[ne],P),re!==null&&(j=a(re,j,ne),X===null?Z=re:X.sibling=re,X=re);return ln&&Rf(C,ne),Z}for(re=n(C,re);ne<N.length;ne++)ae=w(re,C,ne,N[ne],P),ae!==null&&(e&&ae.alternate!==null&&re.delete(ae.key===null?ne:ae.key),j=a(ae,j,ne),X===null?Z=ae:X.sibling=ae,X=ae);return e&&re.forEach(function(m){return t(C,m)}),ln&&Rf(C,ne),Z}function I(C,j,N,P){var Z=Vp(N);if(typeof Z!="function")throw Error(Ge(150));if(N=Z.call(N),N==null)throw Error(Ge(151));for(var X=Z=null,re=j,ne=j=0,ae=null,ue=N.next();re!==null&&!ue.done;ne++,ue=N.next()){re.index>ne?(ae=re,re=null):ae=re.sibling;var m=p(C,re,ue.value,P);if(m===null){re===null&&(re=ae);break}e&&re&&m.alternate===null&&t(C,re),j=a(m,j,ne),X===null?Z=m:X.sibling=m,X=m,re=ae}if(ue.done)return r(C,re),ln&&Rf(C,ne),Z;if(re===null){for(;!ue.done;ne++,ue=N.next())ue=d(C,ue.value,P),ue!==null&&(j=a(ue,j,ne),X===null?Z=ue:X.sibling=ue,X=ue);return ln&&Rf(C,ne),Z}for(re=n(C,re);!ue.done;ne++,ue=N.next())ue=w(re,C,ne,ue.value,P),ue!==null&&(e&&ue.alternate!==null&&re.delete(ue.key===null?ne:ue.key),j=a(ue,j,ne),X===null?Z=ue:X.sibling=ue,X=ue);return e&&re.forEach(function(A){return t(C,A)}),ln&&Rf(C,ne),Z}function R(C,j,N,P){if(typeof N=="object"&&N!==null&&N.type===yd&&N.key===null&&(N=N.props.children),typeof N=="object"&&N!==null){switch(N.$$typeof){case G1:e:{for(var Z=N.key,X=j;X!==null;){if(X.key===Z){if(Z=N.type,Z===yd){if(X.tag===7){r(C,X.sibling),j=i(X,N.props.children),j.return=C,C=j;break e}}else if(X.elementType===Z||typeof Z=="object"&&Z!==null&&Z.$$typeof===Gc&&XM(Z)===X.type){r(C,X.sibling),j=i(X,N.props),j.ref=gm(C,X,N),j.return=C,C=j;break e}r(C,X);break}else t(C,X);X=X.sibling}N.type===yd?(j=qf(N.props.children,C.mode,P,N.key),j.return=C,C=j):(P=Jy(N.type,N.key,N.props,null,C.mode,P),P.ref=gm(C,j,N),P.return=C,C=P)}return s(C);case bd:e:{for(X=N.key;j!==null;){if(j.key===X)if(j.tag===4&&j.stateNode.containerInfo===N.containerInfo&&j.stateNode.implementation===N.implementation){r(C,j.sibling),j=i(j,N.children||[]),j.return=C,C=j;break e}else{r(C,j);break}else t(C,j);j=j.sibling}j=o6(N,C.mode,P),j.return=C,C=j}return s(C);case Gc:return X=N._init,R(C,j,X(N._payload),P)}if($p(N))return O(C,j,N,P);if(Vp(N))return I(C,j,N,P);Cy(C,N)}return typeof N=="string"&&N!==""||typeof N=="number"?(N=""+N,j!==null&&j.tag===6?(r(C,j.sibling),j=i(j,N),j.return=C,C=j):(r(C,j),j=s6(N,C.mode,P),j.return=C,C=j),s(C)):r(C,j)}return R}var Nd=JM(!0),QM=JM(!1),Ty=iu(null),jy=null,Fd=null,b3=null;function y3(){b3=Fd=jy=null}function v3(e){var t=Ty.current;tn(Ty),e._currentValue=t}function w3(e,t,r){for(;e!==null;){var n=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,n!==null&&(n.childLanes|=t)):n!==null&&(n.childLanes&t)!==t&&(n.childLanes|=t),e===r)break;e=e.return}}function Pd(e,t){jy=e,b3=Fd=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(xa=!0),e.firstContext=null)}function ws(e){var t=e._currentValue;if(b3!==e)if(e={context:e,memoizedValue:t,next:null},Fd===null){if(jy===null)throw Error(Ge(308));Fd=e,jy.dependencies={lanes:0,firstContext:e}}else Fd=Fd.next=e;return t}var Nf=null;function x3(e){Nf===null?Nf=[e]:Nf.push(e)}function eA(e,t,r,n){var i=t.interleaved;return i===null?(r.next=r,x3(t)):(r.next=i.next,i.next=r),t.interleaved=r,Jl(e,n)}function Jl(e,t){e.lanes|=t;var r=e.alternate;for(r!==null&&(r.lanes|=t),r=e,e=e.return;e!==null;)e.childLanes|=t,r=e.alternate,r!==null&&(r.childLanes|=t),r=e,e=e.return;return r.tag===3?r.stateNode:null}var ou=!1;function _3(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function tA(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Ql(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function lu(e,t,r){var n=e.updateQueue;if(n===null)return null;if(n=n.shared,kr&2){var i=n.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),n.pending=t,Jl(e,r)}return i=n.interleaved,i===null?(t.next=t,x3(n)):(t.next=i.next,i.next=t),n.interleaved=t,Jl(e,r)}function Iy(e,t,r){if(t=t.updateQueue,t!==null&&(t=t.shared,(r&4194240)!==0)){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,F_(e,r)}}function rA(e,t){var r=e.updateQueue,n=e.alternate;if(n!==null&&(n=n.updateQueue,r===n)){var i=null,a=null;if(r=r.firstBaseUpdate,r!==null){do{var s={eventTime:r.eventTime,lane:r.lane,tag:r.tag,payload:r.payload,callback:r.callback,next:null};a===null?i=a=s:a=a.next=s,r=r.next}while(r!==null);a===null?i=a=t:a=a.next=t}else i=a=t;r={baseState:n.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:n.shared,effects:n.effects},e.updateQueue=r;return}e=r.lastBaseUpdate,e===null?r.firstBaseUpdate=t:e.next=t,r.lastBaseUpdate=t}function Oy(e,t,r,n){var i=e.updateQueue;ou=!1;var a=i.firstBaseUpdate,s=i.lastBaseUpdate,o=i.shared.pending;if(o!==null){i.shared.pending=null;var c=o,l=c.next;c.next=null,s===null?a=l:s.next=l,s=c;var u=e.alternate;u!==null&&(u=u.updateQueue,o=u.lastBaseUpdate,o!==s&&(o===null?u.firstBaseUpdate=l:o.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;s=0,u=l=c=null,o=a;do{var p=o.lane,w=o.eventTime;if((n&p)===p){u!==null&&(u=u.next={eventTime:w,lane:0,tag:o.tag,payload:o.payload,callback:o.callback,next:null});e:{var O=e,I=o;switch(p=t,w=r,I.tag){case 1:if(O=I.payload,typeof O=="function"){d=O.call(w,d,p);break e}d=O;break e;case 3:O.flags=O.flags&-65537|128;case 0:if(O=I.payload,p=typeof O=="function"?O.call(w,d,p):O,p==null)break e;d=yn({},d,p);break e;case 2:ou=!0}}o.callback!==null&&o.lane!==0&&(e.flags|=64,p=i.effects,p===null?i.effects=[o]:p.push(o))}else w={eventTime:w,lane:p,tag:o.tag,payload:o.payload,callback:o.callback,next:null},u===null?(l=u=w,c=d):u=u.next=w,s|=p;if(o=o.next,o===null){if(o=i.shared.pending,o===null)break;p=o,o=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(!0);if(u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,t=i.shared.interleaved,t!==null){i=t;do s|=i.lane,i=i.next;while(i!==t)}else a===null&&(i.shared.lanes=0);zf|=s,e.lanes=s,e.memoizedState=d}}function nA(e,t,r){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var n=e[t],i=n.callback;if(i!==null){if(n.callback=null,n=r,typeof i!="function")throw Error(Ge(191,i));i.call(n)}}}var bm={},Go=iu(bm),ym=iu(bm),vm=iu(bm);function Ff(e){if(e===bm)throw Error(Ge(174));return e}function S3(e,t){switch(Hr(vm,t),Hr(ym,e),Hr(Go,bm),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:k_(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=k_(t,e)}tn(Go),Hr(Go,t)}function zd(){tn(Go),tn(ym),tn(vm)}function iA(e){Ff(vm.current);var t=Ff(Go.current),r=k_(t,e.type);t!==r&&(Hr(ym,e),Hr(Go,r))}function k3(e){ym.current===e&&(tn(Go),tn(ym))}var vn=iu(0);function By(e){for(var t=e;t!==null;){if(t.tag===13){var r=t.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||r.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var E3=[];function M3(){for(var e=0;e<E3.length;e++)E3[e]._workInProgressVersionPrimary=null;E3.length=0}var Ry=Wl.ReactCurrentDispatcher,A3=Wl.ReactCurrentBatchConfig,Pf=0,wn=null,Qn=null,fi=null,Ny=!1,wm=!1,xm=0,H$=0;function Di(){throw Error(Ge(321))}function C3(e,t){if(t===null)return!1;for(var r=0;r<t.length&&r<e.length;r++)if(!Gs(e[r],t[r]))return!1;return!0}
vendor: 6,753 bytes, line 6
6function T3(e,t,r,n,i,a){if(Pf=a,wn=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Ry.current=e===null||e.memoizedState===null?Y$:X$,e=r(n,i),wm){a=0;do{if(wm=!1,xm=0,25<=a)throw Error(Ge(301));a+=1,fi=Qn=null,t.updateQueue=null,Ry.current=J$,e=r(n,i)}while(wm)}if(Ry.current=zy,t=Qn!==null&&Qn.next!==null,Pf=0,fi=Qn=wn=null,Ny=!1,t)throw Error(Ge(300));return e}function j3(){var e=xm!==0;return xm=0,e}function Yo(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return fi===null?wn.memoizedState=fi=e:fi=fi.next=e,fi}function xs(){if(Qn===null){var e=wn.alternate;e=e!==null?e.memoizedState:null}else e=Qn.next;var t=fi===null?wn.memoizedState:fi.next;if(t!==null)fi=t,Qn=e;else{if(e===null)throw Error(Ge(310));Qn=e,e={memoizedState:Qn.memoizedState,baseState:Qn.baseState,baseQueue:Qn.baseQueue,queue:Qn.queue,next:null},fi===null?wn.memoizedState=fi=e:fi=fi.next=e}return fi}function _m(e,t){return typeof t=="function"?t(e):t}function I3(e){var t=xs(),r=t.queue;if(r===null)throw Error(Ge(311));r.lastRenderedReducer=e;var n=Qn,i=n.baseQueue,a=r.pending;if(a!==null){if(i!==null){var s=i.next;i.next=a.next,a.next=s}n.baseQueue=i=a,r.pending=null}if(i!==null){a=i.next,n=n.baseState;var o=s=null,c=null,l=a;do{var u=l.lane;if((Pf&u)===u)c!==null&&(c=c.next={lane:0,action:l.action,hasEagerState:l.hasEagerState,eagerState:l.eagerState,next:null}),n=l.hasEagerState?l.eagerState:e(n,l.action);else{var d={lane:u,action:l.action,hasEagerState:l.hasEagerState,eagerState:l.eagerState,next:null};c===null?(o=c=d,s=n):c=c.next=d,wn.lanes|=u,zf|=u}l=l.next}while(l!==null&&l!==a);c===null?s=n:c.next=o,Gs(n,t.memoizedState)||(xa=!0),t.memoizedState=n,t.baseState=s,t.baseQueue=c,r.lastRenderedState=n}if(e=r.interleaved,e!==null){i=e;do a=i.lane,wn.lanes|=a,zf|=a,i=i.next;while(i!==e)}else i===null&&(r.lanes=0);return[t.memoizedState,r.dispatch]}function O3(e){var t=xs(),r=t.queue;if(r===null)throw Error(Ge(311));r.lastRenderedReducer=e;var n=r.dispatch,i=r.pending,a=t.memoizedState;if(i!==null){r.pending=null;var s=i=i.next;do a=e(a,s.action),s=s.next;while(s!==i);Gs(a,t.memoizedState)||(xa=!0),t.memoizedState=a,t.baseQueue===null&&(t.baseState=a),r.lastRenderedState=a}return[a,n]}function aA(){}function sA(e,t){var r=wn,n=xs(),i=t(),a=!Gs(n.memoizedState,i);if(a&&(n.memoizedState=i,xa=!0),n=n.queue,B3(cA.bind(null,r,n,e),[e]),n.getSnapshot!==t||a||fi!==null&&fi.memoizedState.tag&1){if(r.flags|=2048,Sm(9,lA.bind(null,r,n,i,t),void 0,null),hi===null)throw Error(Ge(349));Pf&30||oA(r,t,i)}return i}function oA(e,t,r){e.flags|=16384,e={getSnapshot:t,value:r},t=wn.updateQueue,t===null?(t={lastEffect:null,stores:null},wn.updateQueue=t,t.stores=[e]):(r=t.stores,r===null?t.stores=[e]:r.push(e))}function lA(e,t,r,n){t.value=r,t.getSnapshot=n,uA(t)&&fA(e)}function cA(e,t,r){return r(function(){uA(t)&&fA(e)})}function uA(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!Gs(e,r)}catch{return!0}}function fA(e){var t=Jl(e,1);t!==null&&eo(t,e,1,-1)}function hA(e){var t=Yo();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:_m,lastRenderedState:e},t.queue=e,e=e.dispatch=G$.bind(null,wn,e),[t.memoizedState,e]}function Sm(e,t,r,n){return e={tag:e,create:t,destroy:r,deps:n,next:null},t=wn.updateQueue,t===null?(t={lastEffect:null,stores:null},wn.updateQueue=t,t.lastEffect=e.next=e):(r=t.lastEffect,r===null?t.lastEffect=e.next=e:(n=r.next,r.next=e,e.next=n,t.lastEffect=e)),e}function dA(){return xs().memoizedState}function Fy(e,t,r,n){var i=Yo();wn.flags|=e,i.memoizedState=Sm(1|t,r,void 0,n===void 0?null:n)}function Py(e,t,r,n){var i=xs();n=n===void 0?null:n;var a=void 0;if(Qn!==null){var s=Qn.memoizedState;if(a=s.destroy,n!==null&&C3(n,s.deps)){i.memoizedState=Sm(t,r,a,n);return}}wn.flags|=e,i.memoizedState=Sm(1|t,r,a,n)}function pA(e,t){return Fy(8390656,8,e,t)}function B3(e,t){return Py(2048,8,e,t)}function mA(e,t){return Py(4,2,e,t)}function gA(e,t){return Py(4,4,e,t)}function bA(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function yA(e,t,r){return r=r!=null?r.concat([e]):null,Py(4,4,bA.bind(null,t,e),r)}function R3(){}function vA(e,t){var r=xs();t=t===void 0?null:t;var n=r.memoizedState;return n!==null&&t!==null&&C3(t,n[1])?n[0]:(r.memoizedState=[e,t],e)}function wA(e,t){var r=xs();t=t===void 0?null:t;var n=r.memoizedState;return n!==null&&t!==null&&C3(t,n[1])?n[0]:(e=e(),r.memoizedState=[e,t],e)}function xA(e,t,r){return Pf&21?(Gs(r,t)||(r=X9(),wn.lanes|=r,zf|=r,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,xa=!0),e.memoizedState=r)}function W$(e,t){var r=Fr;Fr=r!==0&&4>r?r:4,e(!0);var n=A3.transition;A3.transition={};try{e(!1),t()}finally{Fr=r,A3.transition=n}}function _A(){return xs().memoizedState}function K$(e,t,r){var n=hu(e);if(r={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null},SA(e))kA(t,r);else if(r=eA(e,t,r,n),r!==null){var i=ca();eo(r,e,n,i),EA(r,t,n)}}function G$(e,t,r){var n=hu(e),i={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null};if(SA(e))kA(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var s=t.lastRenderedState,o=a(s,r);if(i.hasEagerState=!0,i.eagerState=o,Gs(o,s)){var c=t.interleaved;c===null?(i.next=i,x3(t)):(i.next=c.next,c.next=i),t.interleaved=i;return}}catch{}finally{}r=eA(e,t,i,n),r!==null&&(i=ca(),eo(r,e,n,i),EA(r,t,n))}}function SA(e){var t=e.alternate;return e===wn||t!==null&&t===wn}function kA(e,t){wm=Ny=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function EA(e,t,r){if(r&4194240){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,F_(e,r)}}var zy={readContext:ws,useCallback:Di,useContext:Di,useEffect:Di,useImperativeHandle:Di,useInsertionEffect:Di,useLayoutEffect:Di,useMemo:Di,useReducer:Di,useRef:Di,useState:Di,useDebugValue:Di,useDeferredValue:Di,useTransition:Di,useMutableSource:Di,useSyncExternalStore:Di,useId:Di,unstable_isNewReconciler:!1},Y$={readContext:ws,useCallback:function(e,t){return Yo().memoizedState=[e,t===void 0?null:t],e},useContext:ws,useEffect:pA,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,Fy(4194308,4,bA.bind(null,t,e),r)},useLayoutEffect:function(e,t){return Fy(4194308,4,e,t)},useInsertionEffect:function(e,t){return Fy(4,2,e,t)},useMemo:function(e,t){var r=Yo();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var n=Yo();return t=r!==void 0?r(t):t,n.memoizedState=n.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},n.queue=e,e=e.dispatch=K$.bind(null,wn,e),[n.memoizedState,e]}
vendor: 7,433 bytes, lines 6-8
6,useRef:function(e){var t=Yo();return e={current:e},t.memoizedState=e},useState:hA,useDebugValue:R3,useDeferredValue:function(e){return Yo().memoizedState=e},useTransition:function(){var e=hA(!1),t=e[0];return e=W$.bind(null,e[1]),Yo().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var n=wn,i=Yo();if(ln){if(r===void 0)throw Error(Ge(407));r=r()}else{if(r=t(),hi===null)throw Error(Ge(349));Pf&30||oA(n,t,r)}i.memoizedState=r;var a={value:r,getSnapshot:t};return i.queue=a,pA(cA.bind(null,n,a,e),[e]),n.flags|=2048,Sm(9,lA.bind(null,n,a,r,t),void 0,null),r},useId:function(){var e=Yo(),t=hi.identifierPrefix;if(ln){var r=Xl,n=Yl;r=(n&~(1<<32-Ks(n)-1)).toString(32)+r,t=":"+t+"R"+r,r=xm++,0<r&&(t+="H"+r.toString(32)),t+=":"}else r=H$++,t=":"+t+"r"+r.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},X$={readContext:ws,useCallback:vA,useContext:ws,useEffect:B3,useImperativeHandle:yA,useInsertionEffect:mA,useLayoutEffect:gA,useMemo:wA,useReducer:I3,useRef:dA,useState:function(){return I3(_m)},useDebugValue:R3,useDeferredValue:function(e){var t=xs();return xA(t,Qn.memoizedState,e)},useTransition:function(){var e=I3(_m)[0],t=xs().memoizedState;return[e,t]},useMutableSource:aA,useSyncExternalStore:sA,useId:_A,unstable_isNewReconciler:!1},J$={readContext:ws,useCallback:vA,useContext:ws,useEffect:B3,useImperativeHandle:yA,useInsertionEffect:mA,useLayoutEffect:gA,useMemo:wA,useReducer:O3,useRef:dA,useState:function(){return O3(_m)},useDebugValue:R3,useDeferredValue:function(e){var t=xs();return Qn===null?t.memoizedState=e:xA(t,Qn.memoizedState,e)},useTransition:function(){var e=O3(_m)[0],t=xs().memoizedState;return[e,t]},useMutableSource:aA,useSyncExternalStore:sA,useId:_A,unstable_isNewReconciler:!1};function Xs(e,t){if(e&&e.defaultProps){t=yn({},t),e=e.defaultProps;for(var r in e)t[r]===void 0&&(t[r]=e[r]);return t}return t}function N3(e,t,r,n){t=e.memoizedState,r=r(n,t),r=r==null?t:yn({},t,r),e.memoizedState=r,e.lanes===0&&(e.updateQueue.baseState=r)}var Ly={isMounted:function(e){return(e=e._reactInternals)?jf(e)===e:!1},enqueueSetState:function(e,t,r){e=e._reactInternals;var n=ca(),i=hu(e),a=Ql(n,i);a.payload=t,r!=null&&(a.callback=r),t=lu(e,a,i),t!==null&&(eo(t,e,i,n),Iy(t,e,i))},enqueueReplaceState:function(e,t,r){e=e._reactInternals;var n=ca(),i=hu(e),a=Ql(n,i);a.tag=1,a.payload=t,r!=null&&(a.callback=r),t=lu(e,a,i),t!==null&&(eo(t,e,i,n),Iy(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var r=ca(),n=hu(e),i=Ql(r,n);i.tag=2,t!=null&&(i.callback=t),t=lu(e,i,n),t!==null&&(eo(t,e,n,r),Iy(t,e,n))}};function MA(e,t,r,n,i,a,s){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(n,a,s):t.prototype&&t.prototype.isPureReactComponent?!cm(r,n)||!cm(i,a):!0}function AA(e,t,r){var n=!1,i=au,a=t.contextType;return typeof a=="object"&&a!==null?a=ws(a):(i=wa(t)?Of:Li.current,n=t.contextTypes,a=(n=n!=null)?Id(e,i):au),t=new t(r,a),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Ly,e.stateNode=t,t._reactInternals=e,n&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=a),t}function CA(e,t,r,n){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(r,n),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(r,n),t.state!==e&&Ly.enqueueReplaceState(t,t.state,null)}function F3(e,t,r,n){var i=e.stateNode;i.props=r,i.state=e.memoizedState,i.refs={},_3(e);var a=t.contextType;typeof a=="object"&&a!==null?i.context=ws(a):(a=wa(t)?Of:Li.current,i.context=Id(e,a)),i.state=e.memoizedState,a=t.getDerivedStateFromProps,typeof a=="function"&&(N3(e,t,a,r),i.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(t=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),t!==i.state&&Ly.enqueueReplaceState(i,i.state,null),Oy(e,r,i,n),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308)}function Ld(e,t){try{var r="",n=t;do r+=MZ(n),n=n.return;while(n);var i=r}catch(a){i=`
7Error generating stack: `+a.message+`
8`+a.stack}return{value:e,source:t,stack:i,digest:null}}function P3(e,t,r){return{value:e,source:null,stack:r??null,digest:t??null}}function z3(e,t){try{console.error(t.value)}catch(r){setTimeout(function(){throw r})}}var Q$=typeof WeakMap=="function"?WeakMap:Map;function TA(e,t,r){r=Ql(-1,r),r.tag=3,r.payload={element:null};var n=t.value;return r.callback=function(){Hy||(Hy=!0,J3=n),z3(e,t)},r}function jA(e,t,r){r=Ql(-1,r),r.tag=3;var n=e.type.getDerivedStateFromError;if(typeof n=="function"){var i=t.value;r.payload=function(){return n(i)},r.callback=function(){z3(e,t)}}var a=e.stateNode;return a!==null&&typeof a.componentDidCatch=="function"&&(r.callback=function(){z3(e,t),typeof n!="function"&&(uu===null?uu=new Set([this]):uu.add(this));var s=t.stack;this.componentDidCatch(t.value,{componentStack:s!==null?s:""})}),r}function IA(e,t,r){var n=e.pingCache;if(n===null){n=e.pingCache=new Q$;var i=new Set;n.set(t,i)}else i=n.get(t),i===void 0&&(i=new Set,n.set(t,i));i.has(r)||(i.add(r),e=dH.bind(null,e,t,r),t.then(e,e))}function OA(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function BA(e,t,r,n,i){return e.mode&1?(e.flags|=65536,e.lanes=i,e):(e===t?e.flags|=65536:(e.flags|=128,r.flags|=131072,r.flags&=-52805,r.tag===1&&(r.alternate===null?r.tag=17:(t=Ql(-1,1),t.tag=2,lu(r,t,1))),r.lanes|=1),e)}var eH=Wl.ReactCurrentOwner,xa=!1;function la(e,t,r,n){t.child=e===null?QM(t,null,r,n):Nd(t,e.child,r,n)}function RA(e,t,r,n,i){r=r.render;var a=t.ref;return Pd(t,i),n=T3(e,t,r,n,a,i),r=j3(),e!==null&&!xa?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,ec(e,t,i)):(ln&&r&&h3(t),t.flags|=1,la(e,t,n,i),t.child)}function NA(e,t,r,n,i){if(e===null){var a=r.type;return typeof a=="function"&&!a6(a)&&a.defaultProps===void 0&&r.compare===null&&r.defaultProps===void 0?(t.tag=15,t.type=a,FA(e,t,a,n,i)):(e=Jy(r.type,null,n,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!(e.lanes&i)){var s=a.memoizedProps;if(r=r.compare,r=r!==null?r:cm,r(s,n)&&e.ref===t.ref)return ec(e,t,i)}return t.flags|=1,e=pu(a,n),e.ref=t.ref,e.return=t,t.child=e}function FA(e,t,r,n,i){if(e!==null){var a=e.memoizedProps;if(cm(a,n)&&e.ref===t.ref)if(xa=!1,t.pendingProps=n=a,(e.lanes&i)!==0)e.flags&131072&&(xa=!0);else return t.lanes=e.lanes,ec(e,t,i)}return L3(e,t,r,n,i)}function PA(e,t,r){var n=t.pendingProps,i=n.children,a=e!==null?e.memoizedState:null;if(n.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},Hr(Ud,Ka),Ka|=r;else{if(!(r&1073741824))return e=a!==null?a.baseLanes|r:r,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,Hr(Ud,Ka),Ka|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},n=a!==null?a.baseLanes:r,Hr(Ud,Ka),Ka|=n}else a!==null?(n=a.baseLanes|r,t.memoizedState=null):n=r,Hr(Ud,Ka),Ka|=n;return la(e,t,i,r),t.child}function zA(e,t){var r=t.ref;(e===null&&r!==null||e!==null&&e.ref!==r)&&(t.flags|=512,t.flags|=2097152)}
vendor: 9,036 bytes, line 8
8function L3(e,t,r,n,i){var a=wa(r)?Of:Li.current;return a=Id(t,a),Pd(t,i),r=T3(e,t,r,n,a,i),n=j3(),e!==null&&!xa?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,ec(e,t,i)):(ln&&n&&h3(t),t.flags|=1,la(e,t,r,i),t.child)}function LA(e,t,r,n,i){if(wa(r)){var a=!0;Sy(t)}else a=!1;if(Pd(t,i),t.stateNode===null)Uy(e,t),AA(t,r,n),F3(t,r,n,i),n=!0;else if(e===null){var s=t.stateNode,o=t.memoizedProps;s.props=o;var c=s.context,l=r.contextType;typeof l=="object"&&l!==null?l=ws(l):(l=wa(r)?Of:Li.current,l=Id(t,l));var u=r.getDerivedStateFromProps,d=typeof u=="function"||typeof s.getSnapshotBeforeUpdate=="function";d||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(o!==n||c!==l)&&CA(t,s,n,l),ou=!1;var p=t.memoizedState;s.state=p,Oy(t,n,s,i),c=t.memoizedState,o!==n||p!==c||va.current||ou?(typeof u=="function"&&(N3(t,r,u,n),c=t.memoizedState),(o=ou||MA(t,r,o,n,p,c,l))?(d||typeof s.UNSAFE_componentWillMount!="function"&&typeof s.componentWillMount!="function"||(typeof s.componentWillMount=="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&s.UNSAFE_componentWillMount()),typeof s.componentDidMount=="function"&&(t.flags|=4194308)):(typeof s.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=n,t.memoizedState=c),s.props=n,s.state=c,s.context=l,n=o):(typeof s.componentDidMount=="function"&&(t.flags|=4194308),n=!1)}else{s=t.stateNode,tA(e,t),o=t.memoizedProps,l=t.type===t.elementType?o:Xs(t.type,o),s.props=l,d=t.pendingProps,p=s.context,c=r.contextType,typeof c=="object"&&c!==null?c=ws(c):(c=wa(r)?Of:Li.current,c=Id(t,c));var w=r.getDerivedStateFromProps;(u=typeof w=="function"||typeof s.getSnapshotBeforeUpdate=="function")||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(o!==d||p!==c)&&CA(t,s,n,c),ou=!1,p=t.memoizedState,s.state=p,Oy(t,n,s,i);var O=t.memoizedState;o!==d||p!==O||va.current||ou?(typeof w=="function"&&(N3(t,r,w,n),O=t.memoizedState),(l=ou||MA(t,r,l,n,p,O,c)||!1)?(u||typeof s.UNSAFE_componentWillUpdate!="function"&&typeof s.componentWillUpdate!="function"||(typeof s.componentWillUpdate=="function"&&s.componentWillUpdate(n,O,c),typeof s.UNSAFE_componentWillUpdate=="function"&&s.UNSAFE_componentWillUpdate(n,O,c)),typeof s.componentDidUpdate=="function"&&(t.flags|=4),typeof s.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof s.componentDidUpdate!="function"||o===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||o===e.memoizedProps&&p===e.memoizedState||(t.flags|=1024),t.memoizedProps=n,t.memoizedState=O),s.props=n,s.state=O,s.context=c,n=l):(typeof s.componentDidUpdate!="function"||o===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||o===e.memoizedProps&&p===e.memoizedState||(t.flags|=1024),n=!1)}return D3(e,t,r,n,a,i)}function D3(e,t,r,n,i,a){zA(e,t);var s=(t.flags&128)!==0;if(!n&&!s)return i&&ZM(t,r,!1),ec(e,t,a);n=t.stateNode,eH.current=t;var o=s&&typeof r.getDerivedStateFromError!="function"?null:n.render();return t.flags|=1,e!==null&&s?(t.child=Nd(t,e.child,null,a),t.child=Nd(t,null,o,a)):la(e,t,o,a),t.memoizedState=n.state,i&&ZM(t,r,!0),t.child}function DA(e){var t=e.stateNode;t.pendingContext?qM(e,t.pendingContext,t.pendingContext!==t.context):t.context&&qM(e,t.context,!1),S3(e,t.containerInfo)}function UA(e,t,r,n,i){return Rd(),g3(i),t.flags|=256,la(e,t,r,n),t.child}var U3={dehydrated:null,treeContext:null,retryLane:0};function q3(e){return{baseLanes:e,cachePool:null,transitions:null}}function qA(e,t,r){var n=t.pendingProps,i=vn.current,a=!1,s=(t.flags&128)!==0,o;if((o=s)||(o=e!==null&&e.memoizedState===null?!1:(i&2)!==0),o?(a=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(i|=1),Hr(vn,i&1),e===null)return m3(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(s=n.children,e=n.fallback,a?(n=t.mode,a=t.child,s={mode:"hidden",children:s},!(n&1)&&a!==null?(a.childLanes=0,a.pendingProps=s):a=Qy(s,n,0,null),e=qf(e,n,r,null),a.return=t,e.return=t,a.sibling=e,t.child=a,t.child.memoizedState=q3(r),t.memoizedState=U3,e):V3(t,s));if(i=e.memoizedState,i!==null&&(o=i.dehydrated,o!==null))return tH(e,t,s,n,o,i,r);if(a){a=n.fallback,s=t.mode,i=e.child,o=i.sibling;var c={mode:"hidden",children:n.children};return!(s&1)&&t.child!==i?(n=t.child,n.childLanes=0,n.pendingProps=c,t.deletions=null):(n=pu(i,c),n.subtreeFlags=i.subtreeFlags&14680064),o!==null?a=pu(o,a):(a=qf(a,s,r,null),a.flags|=2),a.return=t,n.return=t,n.sibling=a,t.child=n,n=a,a=t.child,s=e.child.memoizedState,s=s===null?q3(r):{baseLanes:s.baseLanes|r,cachePool:null,transitions:s.transitions},a.memoizedState=s,a.childLanes=e.childLanes&~r,t.memoizedState=U3,n}return a=e.child,e=a.sibling,n=pu(a,{mode:"visible",children:n.children}),!(t.mode&1)&&(n.lanes=r),n.return=t,n.sibling=null,e!==null&&(r=t.deletions,r===null?(t.deletions=[e],t.flags|=16):r.push(e)),t.child=n,t.memoizedState=null,n}function V3(e,t){return t=Qy({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Dy(e,t,r,n){return n!==null&&g3(n),Nd(t,e.child,null,r),e=V3(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function tH(e,t,r,n,i,a,s){if(r)return t.flags&256?(t.flags&=-257,n=P3(Error(Ge(422))),Dy(e,t,s,n)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(a=n.fallback,i=t.mode,n=Qy({mode:"visible",children:n.children},i,0,null),a=qf(a,i,s,null),a.flags|=2,n.return=t,a.return=t,n.sibling=a,t.child=n,t.mode&1&&Nd(t,e.child,null,s),t.child.memoizedState=q3(s),t.memoizedState=U3,a);if(!(t.mode&1))return Dy(e,t,s,null);if(i.data==="$!"){if(n=i.nextSibling&&i.nextSibling.dataset,n)var o=n.dgst;return n=o,a=Error(Ge(419)),n=P3(a,n,void 0),Dy(e,t,s,n)}if(o=(s&e.childLanes)!==0,xa||o){if(n=hi,n!==null){switch(s&-s){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(n.suspendedLanes|s)?0:i,i!==0&&i!==a.retryLane&&(a.retryLane=i,Jl(e,i),eo(n,e,i,-1))}return i6(),n=P3(Error(Ge(421))),Dy(e,t,s,n)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=pH.bind(null,e),i._reactRetry=t,null):(e=a.treeContext,Wa=nu(i.nextSibling),Ha=t,ln=!0,Ys=null,e!==null&&(ys[vs++]=Yl,ys[vs++]=Xl,ys[vs++]=Bf,Yl=e.id,Xl=e.overflow,Bf=t),t=V3(t,n.children),t.flags|=4096,t)}function VA(e,t,r){e.lanes|=t;var n=e.alternate;n!==null&&(n.lanes|=t),w3(e.return,t,r)}function Z3(e,t,r,n,i){var a=e.memoizedState;a===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:n,tail:r,tailMode:i}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=n,a.tail=r,a.tailMode=i)}function ZA(e,t,r){var n=t.pendingProps,i=n.revealOrder,a=n.tail;if(la(e,t,n.children,r),n=vn.current,n&2)n=n&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&VA(e,r,t);else if(e.tag===19)VA(e,r,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}n&=1}if(Hr(vn,n),!(t.mode&1))t.memoizedState=null;else switch(i){case"forwards":for(r=t.child,i=null;r!==null;)e=r.alternate,e!==null&&By(e)===null&&(i=r),r=r.sibling;r=i,r===null?(i=t.child,t.child=null):(i=r.sibling,r.sibling=null),Z3(t,!1,i,r,a);break;case"backwards":for(r=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&By(e)===null){t.child=i;break}e=i.sibling,i.sibling=r,r=i,i=e}Z3(t,!0,r,null,a);break;case"together":Z3(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Uy(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function ec(e,t,r){if(e!==null&&(t.dependencies=e.dependencies),zf|=t.lanes,!(r&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(Ge(153));if(t.child!==null){for(e=t.child,r=pu(e,e.pendingProps),t.child=r,r.return=t;e.sibling!==null;)e=e.sibling,r=r.sibling=pu(e,e.pendingProps),r.return=t;r.sibling=null}return t.child}function rH(e,t,r){switch(t.tag){case 3:DA(t),Rd();break;case 5:iA(t);break;case 1:wa(t.type)&&Sy(t);break;case 4:S3(t,t.stateNode.containerInfo);break;case 10:var n=t.type._context,i=t.memoizedProps.value;Hr(Ty,n._currentValue),n._currentValue=i;break;case 13:if(n=t.memoizedState,n!==null)return n.dehydrated!==null?(Hr(vn,vn.current&1),t.flags|=128,null):r&t.child.childLanes?qA(e,t,r):(Hr(vn,vn.current&1),e=ec(e,t,r),e!==null?e.sibling:null);Hr(vn,vn.current&1);break;case 19:if(n=(r&t.childLanes)!==0,e.flags&128){if(n)return ZA(e,t,r);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),Hr(vn,vn.current),n)break;return null;
vendor: 4,598 bytes, line 8
8case 22:case 23:return t.lanes=0,PA(e,t,r)}return ec(e,t,r)}var $A,$3,HA,WA;$A=function(e,t){for(var r=t.child;r!==null;){if(r.tag===5||r.tag===6)e.appendChild(r.stateNode);else if(r.tag!==4&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return;r=r.return}r.sibling.return=r.return,r=r.sibling}},$3=function(){},HA=function(e,t,r,n){var i=e.memoizedProps;if(i!==n){e=t.stateNode,Ff(Go.current);var a=null;switch(r){case"input":i=w_(e,i),n=w_(e,n),a=[];break;case"select":i=yn({},i,{value:void 0}),n=yn({},n,{value:void 0}),a=[];break;case"textarea":i=S_(e,i),n=S_(e,n),a=[];break;default:typeof i.onClick!="function"&&typeof n.onClick=="function"&&(e.onclick=wy)}E_(r,n);var s;r=null;for(l in i)if(!n.hasOwnProperty(l)&&i.hasOwnProperty(l)&&i[l]!=null)if(l==="style"){var o=i[l];for(s in o)o.hasOwnProperty(s)&&(r||(r={}),r[s]="")}else l!=="dangerouslySetInnerHTML"&&l!=="children"&&l!=="suppressContentEditableWarning"&&l!=="suppressHydrationWarning"&&l!=="autoFocus"&&(qp.hasOwnProperty(l)?a||(a=[]):(a=a||[]).push(l,null));for(l in n){var c=n[l];if(o=i==null?void 0:i[l],n.hasOwnProperty(l)&&c!==o&&(c!=null||o!=null))if(l==="style")if(o){for(s in o)!o.hasOwnProperty(s)||c&&c.hasOwnProperty(s)||(r||(r={}),r[s]="");for(s in c)c.hasOwnProperty(s)&&o[s]!==c[s]&&(r||(r={}),r[s]=c[s])}else r||(a||(a=[]),a.push(l,r)),r=c;else l==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,o=o?o.__html:void 0,c!=null&&o!==c&&(a=a||[]).push(l,c)):l==="children"?typeof c!="string"&&typeof c!="number"||(a=a||[]).push(l,""+c):l!=="suppressContentEditableWarning"&&l!=="suppressHydrationWarning"&&(qp.hasOwnProperty(l)?(c!=null&&l==="onScroll"&&en("scroll",e),a||o===c||(a=[])):(a=a||[]).push(l,c))}r&&(a=a||[]).push("style",r);var l=a;(t.updateQueue=l)&&(t.flags|=4)}},WA=function(e,t,r,n){r!==n&&(t.flags|=4)};function km(e,t){if(!ln)switch(e.tailMode){case"hidden":t=e.tail;for(var r=null;t!==null;)t.alternate!==null&&(r=t),t=t.sibling;r===null?e.tail=null:r.sibling=null;break;case"collapsed":r=e.tail;for(var n=null;r!==null;)r.alternate!==null&&(n=r),r=r.sibling;n===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:n.sibling=null}}function Ui(e){var t=e.alternate!==null&&e.alternate.child===e.child,r=0,n=0;if(t)for(var i=e.child;i!==null;)r|=i.lanes|i.childLanes,n|=i.subtreeFlags&14680064,n|=i.flags&14680064,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)r|=i.lanes|i.childLanes,n|=i.subtreeFlags,n|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=n,e.childLanes=r,t}function nH(e,t,r){var n=t.pendingProps;switch(d3(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ui(t),null;case 1:return wa(t.type)&&_y(),Ui(t),null;case 3:return n=t.stateNode,zd(),tn(va),tn(Li),M3(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Ay(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ys!==null&&(t6(Ys),Ys=null))),$3(e,t),Ui(t),null;case 5:k3(t);var i=Ff(vm.current);if(r=t.type,e!==null&&t.stateNode!=null)HA(e,t,r,n,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!n){if(t.stateNode===null)throw Error(Ge(166));return Ui(t),null}if(e=Ff(Go.current),Ay(t)){n=t.stateNode,r=t.type;var a=t.memoizedProps;switch(n[Ko]=t,n[pm]=a,e=(t.mode&1)!==0,r){case"dialog":en("cancel",n),en("close",n);break;case"iframe":case"object":case"embed":en("load",n);break;case"video":case"audio":for(i=0;i<fm.length;i++)en(fm[i],n);break;case"source":en("error",n);break;case"img":case"image":case"link":en("error",n),en("load",n);break;case"details":en("toggle",n);break;case"input":A9(n,a),en("invalid",n);break;case"select":n._wrapperState={wasMultiple:!!a.multiple},en("invalid",n);break;case"textarea":j9(n,a),en("invalid",n)}E_(r,a),i=null;for(var s in a)if(a.hasOwnProperty(s)){var o=a[s];s==="children"?typeof o=="string"?n.textContent!==o&&(a.suppressHydrationWarning!==!0&&vy(n.textContent,o,e),i=["children",o]):typeof o=="number"&&n.textContent!==""+o&&(a.suppressHydrationWarning!==!0&&vy(n.textContent,o,e),i=["children",""+o]):qp.hasOwnProperty(s)&&o!=null&&s==="onScroll"&&en("scroll",n)}switch(r){case"input":Y1(n),T9(n,a,!0);break;case"textarea":Y1(n),O9(n);break;case"select":case"option":break;default:typeof a.onClick=="function"&&(n.onclick=wy)}n=i,t.updateQueue=n,n!==null&&(t.flags|=4)}else{s=i.nodeType===9?i:i.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=B9(r)),e==="http://www.w3.org/1999/xhtml"?r==="script"?(e=s.createElement("div"),e.innerHTML="<script><\/script>
8",e=e.removeChild(e.firstChild)):typeof n.is=="string"?e=s.createElement(r,{is:n.is}):(e=s.createElement(r),r==="select"&&(s=e,n.multiple?s.multiple=!0:n.size&&(s.size=n.size))):e=s.createElementNS(e,r),e[Ko]=t,e[pm]=n,$A(e,t,!1,!1),t.stateNode=e;e:{switch(s=M_(r,n),r){case"dialog":en("cancel",e),en("close",e),i=n;break;case"iframe":case"object":case"embed":en("load",e),i=n;break;case"video":case"audio":for(i=0;i<fm.length;i++)en(fm[i],e);i=n;break;case"source":en("error",e),i=n;break;case"img":case"image":case"link":en("error",e),en("load",e),i=n;break;case"details":en("toggle",e),i=n;break;case"input":A9(e,n),i=w_(e,n),en("invalid",e);break;case"option":i=n;break;case"select":e._wrapperState={wasMultiple:!!n.multiple},i=yn({},n,{value:void 0}),en("invalid",e);break;case"textarea":j9(e,n),i=S_(e,n),en("invalid",e);break;default:i=n}E_(r,i),o=i;for(a in o)if(o.hasOwnProperty(a)){var c=o[a];a==="style"?F9(e,c):a==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,c!=null&&R9(e,c)):a==="children"?typeof c=="string"?(r!=="textarea"||c!=="")&&Hp(e,c):typeof c=="number"&&Hp(e,""+c):a!=="suppressContentEditableWarning"&&a!=="suppressHydrationWarning"&&a!=="autoFocus"&&(qp.hasOwnProperty(a)?c!=null&&a==="onScroll"&&en("scroll",e):c!=null&&c_(e,a,c,s))}switch(r){case"input":Y1(e),T9(e,n,!1);break;case"textarea":Y1(e),O9(e);break;case"option":n.value!=null&&e.setAttribute("value",""+Yc(n.value));break;case"select":e.multiple=!!n.multiple,a=n.value,a!=null?vd(e,!!n.multiple,a,!1):n.defaultValue!=null&&vd(e,!!n.multiple,n.defaultValue,!0);break;default:typeof i.onClick=="function"&&(e.onclick=wy)}switch(r){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break e;case"img":n=!0;break e;default:n=!1}}n&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return Ui(t),null;case 6:if(e&&t.stateNode!=null)WA(e,t,e.memoizedProps,n);else{if(typeof n!="string"&&t.stateNode===null)throw Error(Ge(166));if(r=Ff(vm.current),Ff(Go.current),Ay(t)){if(n=t.stateNode,r=t.memoizedProps,n[Ko]=t,(a=n.nodeValue!==r)&&(e=Ha,e!==null))switch(e.tag){case 3:vy(n.nodeValue,r,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&vy(n.nodeValue,r,(e.mode&1)!==0)}a&&(t.flags|=4)}else n=(r.nodeType===9?r:r.ownerDocument).createTextNode(n),n[Ko]=t,t.stateNode=n}return Ui(t),null;case 13:if(tn(vn),n=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(ln&&Wa!==null&&t.mode&1&&!(t.flags&128))YM(),Rd(),t.flags|=98560,a=!1;else if(a=Ay(t),n!==null&&n.dehydrated!==null){if(e===null){if(!a)throw Error(Ge(318));if(a=t.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(Ge(317));a[Ko]=t}else Rd(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Ui(t),a=!1}else Ys!==null&&(t6(Ys),Ys=null),a=!0;if(!a)return t.flags&65536?t:null}return t.flags&128?(t.lanes=r,t):(n=n!==null,n!==(e!==null&&e.memoizedState!==null)&&n&&(t.child.flags|=8192,t.mode&1&&(e===null||vn.current&1?ei===0&&(ei=3):i6())),t.updateQueue!==null&&(t.flags|=4),Ui(t),null);case 4:return zd(),$3(e,t),e===null&&hm(t.stateNode.containerInfo),Ui(t),null;case 10:return v3(t.type._context),Ui(t),null;case 17:return wa(t.type)&&_y(),Ui(t),null;case 19:if(tn(vn),a=t.memoizedState,a===null)return Ui(t),null;if(n=(t.flags&128)!==0,s=a.rendering,s===null)if(n)km(a,!1);else{if(ei!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(s=By(e),s!==null){for(t.flags|=128,km(a,!1),n=s.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),t.subtreeFlags=0,n=r,r=t.child;r!==null;)a=r,e=n,a.flags&=14680066,s=a.alternate,s===null?(a.childLanes=0,a.lanes=e,a.child=null,a.subtreeFlags=0,a.memoizedProps=null,a.memoizedState=null,a.updateQueue=null,a.dependencies=null,a.stateNode=null):(a.childLanes=s.childLanes,a.lanes=s.lanes,a.child=s.child,a.subtreeFlags=0,a.deletions=null,a.memoizedProps=s.memoizedProps,a.memoizedState=s.memoizedState,a.updateQueue=s.updateQueue,a.type=s.type,e=s.dependencies,a.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),r=r.sibling;return Hr(vn,vn.current&1|2),t.child}e=e.sibling}a.tail!==null&&In()>qd&&(t.flags|=128,n=!0,km(a,!1),t.lanes=4194304)}else{if(!n)if(e=By(s),e!==null){if(t.flags|=128,n=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),km(a,!0),a.tail===null&&a.tailMode==="hidden"&&!s.alternate&&!ln)return Ui(t),null}else 2*In()-a.renderingStartTime>qd&&r!==1073741824&&(t.flags|=128,n=!0,km(a,!1),t.lanes=4194304);a.isBackwards?(s.sibling=t.child,t.child=s):(r=a.last,r!==null?r.sibling=s:t.child=s,a.last=s)}return a.tail!==null?(t=a.tail,a.rendering=t,a.tail=t.sibling,a.renderingStartTime=In(),t.sibling=null,r=vn.current,Hr(vn,n?r&1|2:r&1),t):(Ui(t),null);case 22:case 23:return n6(),n=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==n&&(t.flags|=8192),n&&t.mode&1?Ka&1073741824&&(Ui(t),t.subtreeFlags&6&&(t.flags|=8192)):Ui(t),null;case 24:return null;case 25:return null}throw Error(Ge(156,t.tag))}function iH(e,t){switch(d3(t),t.tag){case 1:return wa(t.type)&&_y(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;
vendor: 32,648 bytes, line 8
8case 3:return zd(),tn(va),tn(Li),M3(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return k3(t),null;case 13:if(tn(vn),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(Ge(340));Rd()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return tn(vn),null;case 4:return zd(),null;case 10:return v3(t.type._context),null;case 22:case 23:return n6(),null;case 24:return null;default:return null}}var qy=!1,qi=!1,aH=typeof WeakSet=="function"?WeakSet:Set,gt=null;function Dd(e,t){var r=e.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(n){kn(e,t,n)}else r.current=null}function KA(e,t,r){try{r()}catch(n){kn(e,t,n)}}var GA=!1;function sH(e,t){if(i3=ly,e=MM(),Y_(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var n=r.getSelection&&r.getSelection();if(n&&n.rangeCount!==0){r=n.anchorNode;var i=n.anchorOffset,a=n.focusNode;n=n.focusOffset;try{r.nodeType,a.nodeType}catch{r=null;break e}var s=0,o=-1,c=-1,l=0,u=0,d=e,p=null;t:for(;;){for(var w;d!==r||i!==0&&d.nodeType!==3||(o=s+i),d!==a||n!==0&&d.nodeType!==3||(c=s+n),d.nodeType===3&&(s+=d.nodeValue.length),(w=d.firstChild)!==null;)p=d,d=w;for(;;){if(d===e)break t;if(p===r&&++l===i&&(o=s),p===a&&++u===n&&(c=s),(w=d.nextSibling)!==null)break;d=p,p=d.parentNode}d=w}r=o===-1||c===-1?null:{start:o,end:c}}else r=null}r=r||{start:0,end:0}}else r=null;for(a3={focusedElem:e,selectionRange:r},ly=!1,gt=t;gt!==null;)if(t=gt,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,gt=e;else for(;gt!==null;){t=gt;try{var O=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(O!==null){var I=O.memoizedProps,R=O.memoizedState,C=t.stateNode,j=C.getSnapshotBeforeUpdate(t.elementType===t.type?I:Xs(t.type,I),R);C.__reactInternalSnapshotBeforeUpdate=j}break;case 3:var N=t.stateNode.containerInfo;N.nodeType===1?N.textContent="":N.nodeType===9&&N.documentElement&&N.removeChild(N.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(Ge(163))}}catch(P){kn(t,t.return,P)}if(e=t.sibling,e!==null){e.return=t.return,gt=e;break}gt=t.return}return O=GA,GA=!1,O}function Em(e,t,r){var n=t.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var i=n=n.next;do{if((i.tag&e)===e){var a=i.destroy;i.destroy=void 0,a!==void 0&&KA(t,r,a)}i=i.next}while(i!==n)}}function Vy(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var r=t=t.next;do{if((r.tag&e)===e){var n=r.create;r.destroy=n()}r=r.next}while(r!==t)}}function H3(e){var t=e.ref;if(t!==null){var r=e.stateNode;switch(e.tag){case 5:e=r;break;default:e=r}typeof t=="function"?t(e):t.current=e}}function YA(e){var t=e.alternate;t!==null&&(e.alternate=null,YA(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Ko],delete t[pm],delete t[c3],delete t[q$],delete t[V$])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function XA(e){return e.tag===5||e.tag===3||e.tag===4}function JA(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||XA(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function W3(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.nodeType===8?r.parentNode.insertBefore(e,t):r.insertBefore(e,t):(r.nodeType===8?(t=r.parentNode,t.insertBefore(e,r)):(t=r,t.appendChild(e)),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=wy));else if(n!==4&&(e=e.child,e!==null))for(W3(e,t,r),e=e.sibling;e!==null;)W3(e,t,r),e=e.sibling}function K3(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.insertBefore(e,t):r.appendChild(e);else if(n!==4&&(e=e.child,e!==null))for(K3(e,t,r),e=e.sibling;e!==null;)K3(e,t,r),e=e.sibling}var Ai=null,Js=!1;function cu(e,t,r){for(r=r.child;r!==null;)QA(e,t,r),r=r.sibling}function QA(e,t,r){if(Wo&&typeof Wo.onCommitFiberUnmount=="function")try{Wo.onCommitFiberUnmount(ry,r)}catch{}switch(r.tag){case 5:qi||Dd(r,t);case 6:var n=Ai,i=Js;Ai=null,cu(e,t,r),Ai=n,Js=i,Ai!==null&&(Js?(e=Ai,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):Ai.removeChild(r.stateNode));break;case 18:Ai!==null&&(Js?(e=Ai,r=r.stateNode,e.nodeType===8?l3(e.parentNode,r):e.nodeType===1&&l3(e,r),nm(e)):l3(Ai,r.stateNode));break;case 4:n=Ai,i=Js,Ai=r.stateNode.containerInfo,Js=!0,cu(e,t,r),Ai=n,Js=i;break;case 0:case 11:case 14:case 15:if(!qi&&(n=r.updateQueue,n!==null&&(n=n.lastEffect,n!==null))){i=n=n.next;do{var a=i,s=a.destroy;a=a.tag,s!==void 0&&(a&2||a&4)&&KA(r,t,s),i=i.next}while(i!==n)}cu(e,t,r);break;case 1:if(!qi&&(Dd(r,t),n=r.stateNode,typeof n.componentWillUnmount=="function"))try{n.props=r.memoizedProps,n.state=r.memoizedState,n.componentWillUnmount()}catch(o){kn(r,t,o)}cu(e,t,r);break;case 21:cu(e,t,r);break;case 22:r.mode&1?(qi=(n=qi)||r.memoizedState!==null,cu(e,t,r),qi=n):cu(e,t,r);break;default:cu(e,t,r)}}function e7(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new aH),t.forEach(function(n){var i=mH.bind(null,e,n);r.has(n)||(r.add(n),n.then(i,i))})}}function Qs(e,t){var r=t.deletions;if(r!==null)for(var n=0;n<r.length;n++){var i=r[n];try{var a=e,s=t,o=s;e:for(;o!==null;){switch(o.tag){case 5:Ai=o.stateNode,Js=!1;break e;case 3:Ai=o.stateNode.containerInfo,Js=!0;break e;case 4:Ai=o.stateNode.containerInfo,Js=!0;break e}o=o.return}if(Ai===null)throw Error(Ge(160));QA(a,s,i),Ai=null,Js=!1;var c=i.alternate;c!==null&&(c.return=null),i.return=null}catch(l){kn(i,t,l)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)t7(t,e),t=t.sibling}function t7(e,t){var r=e.alternate,n=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Qs(t,e),Xo(e),n&4){try{Em(3,e,e.return),Vy(3,e)}catch(I){kn(e,e.return,I)}try{Em(5,e,e.return)}catch(I){kn(e,e.return,I)}}break;case 1:Qs(t,e),Xo(e),n&512&&r!==null&&Dd(r,r.return);break;case 5:if(Qs(t,e),Xo(e),n&512&&r!==null&&Dd(r,r.return),e.flags&32){var i=e.stateNode;try{Hp(i,"")}catch(I){kn(e,e.return,I)}}if(n&4&&(i=e.stateNode,i!=null)){var a=e.memoizedProps,s=r!==null?r.memoizedProps:a,o=e.type,c=e.updateQueue;if(e.updateQueue=null,c!==null)try{o==="input"&&a.type==="radio"&&a.name!=null&&C9(i,a),M_(o,s);var l=M_(o,a);for(s=0;s<c.length;s+=2){var u=c[s],d=c[s+1];u==="style"?F9(i,d):u==="dangerouslySetInnerHTML"?R9(i,d):u==="children"?Hp(i,d):c_(i,u,d,l)}switch(o){case"input":x_(i,a);break;case"textarea":I9(i,a);break;case"select":var p=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!a.multiple;var w=a.value;w!=null?vd(i,!!a.multiple,w,!1):p!==!!a.multiple&&(a.defaultValue!=null?vd(i,!!a.multiple,a.defaultValue,!0):vd(i,!!a.multiple,a.multiple?[]:"",!1))}i[pm]=a}catch(I){kn(e,e.return,I)}}break;case 6:if(Qs(t,e),Xo(e),n&4){if(e.stateNode===null)throw Error(Ge(162));i=e.stateNode,a=e.memoizedProps;try{i.nodeValue=a}catch(I){kn(e,e.return,I)}}break;case 3:if(Qs(t,e),Xo(e),n&4&&r!==null&&r.memoizedState.isDehydrated)try{nm(t.containerInfo)}catch(I){kn(e,e.return,I)}break;case 4:Qs(t,e),Xo(e);break;case 13:Qs(t,e),Xo(e),i=e.child,i.flags&8192&&(a=i.memoizedState!==null,i.stateNode.isHidden=a,!a||i.alternate!==null&&i.alternate.memoizedState!==null||(X3=In())),n&4&&e7(e);break;case 22:if(u=r!==null&&r.memoizedState!==null,e.mode&1?(qi=(l=qi)||u,Qs(t,e),qi=l):Qs(t,e),Xo(e),n&8192){if(l=e.memoizedState!==null,(e.stateNode.isHidden=l)&&!u&&e.mode&1)for(gt=e,u=e.child;u!==null;){for(d=gt=u;gt!==null;){switch(p=gt,w=p.child,p.tag){case 0:case 11:case 14:case 15:Em(4,p,p.return);break;case 1:Dd(p,p.return);var O=p.stateNode;if(typeof O.componentWillUnmount=="function"){n=p,r=p.return;try{t=n,O.props=t.memoizedProps,O.state=t.memoizedState,O.componentWillUnmount()}catch(I){kn(n,r,I)}}break;case 5:Dd(p,p.return);break;case 22:if(p.memoizedState!==null){i7(d);continue}}w!==null?(w.return=p,gt=w):i7(d)}u=u.sibling}e:for(u=null,d=e;;){if(d.tag===5){if(u===null){u=d;try{i=d.stateNode,l?(a=i.style,typeof a.setProperty=="function"?a.setProperty("display","none","important"):a.display="none"):(o=d.stateNode,c=d.memoizedProps.style,s=c!=null&&c.hasOwnProperty("display")?c.display:null,o.style.display=N9("display",s))}catch(I){kn(e,e.return,I)}}}else if(d.tag===6){if(u===null)try{d.stateNode.nodeValue=l?"":d.memoizedProps}catch(I){kn(e,e.return,I)}}else if((d.tag!==22&&d.tag!==23||d.memoizedState===null||d===e)&&d.child!==null){d.child.return=d,d=d.child;continue}if(d===e)break e;for(;d.sibling===null;){if(d.return===null||d.return===e)break e;u===d&&(u=null),d=d.return}u===d&&(u=null),d.sibling.return=d.return,d=d.sibling}}break;case 19:Qs(t,e),Xo(e),n&4&&e7(e);break;case 21:break;default:Qs(t,e),Xo(e)}}function Xo(e){var t=e.flags;if(t&2){try{e:{for(var r=e.return;r!==null;){if(XA(r)){var n=r;break e}r=r.return}throw Error(Ge(160))}switch(n.tag){case 5:var i=n.stateNode;n.flags&32&&(Hp(i,""),n.flags&=-33);var a=JA(e);K3(e,a,i);break;case 3:case 4:var s=n.stateNode.containerInfo,o=JA(e);W3(e,o,s);break;default:throw Error(Ge(161))}}catch(c){kn(e,e.return,c)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function oH(e,t,r){gt=e,r7(e)}function r7(e,t,r){for(var n=(e.mode&1)!==0;gt!==null;){var i=gt,a=i.child;if(i.tag===22&&n){var s=i.memoizedState!==null||qy;if(!s){var o=i.alternate,c=o!==null&&o.memoizedState!==null||qi;o=qy;var l=qi;if(qy=s,(qi=c)&&!l)for(gt=i;gt!==null;)s=gt,c=s.child,s.tag===22&&s.memoizedState!==null?a7(i):c!==null?(c.return=s,gt=c):a7(i);for(;a!==null;)gt=a,r7(a),a=a.sibling;gt=i,qy=o,qi=l}n7(e)}else i.subtreeFlags&8772&&a!==null?(a.return=i,gt=a):n7(e)}}function n7(e){for(;gt!==null;){var t=gt;if(t.flags&8772){var r=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:qi||Vy(5,t);break;case 1:var n=t.stateNode;if(t.flags&4&&!qi)if(r===null)n.componentDidMount();else{var i=t.elementType===t.type?r.memoizedProps:Xs(t.type,r.memoizedProps);n.componentDidUpdate(i,r.memoizedState,n.__reactInternalSnapshotBeforeUpdate)}var a=t.updateQueue;a!==null&&nA(t,a,n);break;case 3:var s=t.updateQueue;if(s!==null){if(r=null,t.child!==null)switch(t.child.tag){case 5:r=t.child.stateNode;break;case 1:r=t.child.stateNode}nA(t,s,r)}break;case 5:var o=t.stateNode;if(r===null&&t.flags&4){r=o;var c=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":c.autoFocus&&r.focus();break;case"img":c.src&&(r.src=c.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var l=t.alternate;if(l!==null){var u=l.memoizedState;if(u!==null){var d=u.dehydrated;d!==null&&nm(d)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(Ge(163))}qi||t.flags&512&&H3(t)}catch(p){kn(t,t.return,p)}}if(t===e){gt=null;break}if(r=t.sibling,r!==null){r.return=t.return,gt=r;break}gt=t.return}}function i7(e){for(;gt!==null;){var t=gt;if(t===e){gt=null;break}var r=t.sibling;if(r!==null){r.return=t.return,gt=r;break}gt=t.return}}function a7(e){for(;gt!==null;){var t=gt;try{switch(t.tag){case 0:case 11:case 15:var r=t.return;try{Vy(4,t)}catch(c){kn(t,r,c)}break;case 1:var n=t.stateNode;if(typeof n.componentDidMount=="function"){var i=t.return;try{n.componentDidMount()}catch(c){kn(t,i,c)}}var a=t.return;try{H3(t)}catch(c){kn(t,a,c)}break;case 5:var s=t.return;try{H3(t)}catch(c){kn(t,s,c)}}}catch(c){kn(t,t.return,c)}if(t===e){gt=null;break}var o=t.sibling;if(o!==null){o.return=t.return,gt=o;break}gt=t.return}}var lH=Math.ceil,Zy=Wl.ReactCurrentDispatcher,G3=Wl.ReactCurrentOwner,_s=Wl.ReactCurrentBatchConfig,kr=0,hi=null,Un=null,Ci=0,Ka=0,Ud=iu(0),ei=0,Mm=null,zf=0,$y=0,Y3=0,Am=null,_a=null,X3=0,qd=1/0,tc=null,Hy=!1,J3=null,uu=null,Wy=!1,fu=null,Ky=0,Cm=0,Q3=null,Gy=-1,Yy=0;function ca(){return kr&6?In():Gy!==-1?Gy:Gy=In()}function hu(e){return e.mode&1?kr&2&&Ci!==0?Ci&-Ci:$$.transition!==null?(Yy===0&&(Yy=X9()),Yy):(e=Fr,e!==0||(e=window.event,e=e===void 0?16:sM(e.type)),e):1}function eo(e,t,r,n){if(50<Cm)throw Cm=0,Q3=null,Error(Ge(185));Jp(e,r,n),(!(kr&2)||e!==hi)&&(e===hi&&(!(kr&2)&&($y|=r),ei===4&&du(e,Ci)),Sa(e,n),r===1&&kr===0&&!(t.mode&1)&&(qd=In()+500,ky&&su()))}function Sa(e,t){var r=e.callbackNode;$Z(e,t);var n=ay(e,e===hi?Ci:0);if(n===0)r!==null&&K9(r),e.callbackNode=null,e.callbackPriority=0;else if(t=n&-n,e.callbackPriority!==t){if(r!=null&&K9(r),t===1)e.tag===0?Z$(o7.bind(null,e)):$M(o7.bind(null,e)),D$(function(){!(kr&6)&&su()}),r=null;else{switch(J9(n)){case 1:r=B_;break;case 4:r=G9;break;case 16:r=ty;break;case 536870912:r=Y9;break;default:r=ty}r=m7(r,s7.bind(null,e))}e.callbackPriority=t,e.callbackNode=r}}function s7(e,t){if(Gy=-1,Yy=0,kr&6)throw Error(Ge(327));var r=e.callbackNode;if(Vd()&&e.callbackNode!==r)return null;var n=ay(e,e===hi?Ci:0);if(n===0)return null;if(n&30||n&e.expiredLanes||t)t=Xy(e,n);else{t=n;var i=kr;kr|=2;var a=c7();(hi!==e||Ci!==t)&&(tc=null,qd=In()+500,Df(e,t));do try{fH();break}catch(o){l7(e,o)}while(!0);y3(),Zy.current=a,kr=i,Un!==null?t=0:(hi=null,Ci=0,t=ei)}if(t!==0){if(t===2&&(i=R_(e),i!==0&&(n=i,t=e6(e,i))),t===1)throw r=Mm,Df(e,0),du(e,n),Sa(e,In()),r;if(t===6)du(e,n);else{if(i=e.current.alternate,!(n&30)&&!cH(i)&&(t=Xy(e,n),t===2&&(a=R_(e),a!==0&&(n=a,t=e6(e,a))),t===1))throw r=Mm,Df(e,0),du(e,n),Sa(e,In()),r;switch(e.finishedWork=i,e.finishedLanes=n,t){case 0:case 1:throw Error(Ge(345));case 2:Uf(e,_a,tc);break;case 3:if(du(e,n),(n&130023424)===n&&(t=X3+500-In(),10<t)){if(ay(e,0)!==0)break;if(i=e.suspendedLanes,(i&n)!==n){ca(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=o3(Uf.bind(null,e,_a,tc),t);break}Uf(e,_a,tc);break;case 4:if(du(e,n),(n&4194240)===n)break;for(t=e.eventTimes,i=-1;0<n;){var s=31-Ks(n);a=1<<s,s=t[s],s>i&&(i=s),n&=~a}if(n=i,n=In()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*lH(n/1960))-n,10<n){e.timeoutHandle=o3(Uf.bind(null,e,_a,tc),n);break}Uf(e,_a,tc);break;case 5:Uf(e,_a,tc);break;default:throw Error(Ge(329))}}}return Sa(e,In()),e.callbackNode===r?s7.bind(null,e):null}function e6(e,t){var r=Am;return e.current.memoizedState.isDehydrated&&(Df(e,t).flags|=256),e=Xy(e,t),e!==2&&(t=_a,_a=r,t!==null&&t6(t)),e}function t6(e){_a===null?_a=e:_a.push.apply(_a,e)}function cH(e){for(var t=e;;){if(t.flags&16384){var r=t.updateQueue;if(r!==null&&(r=r.stores,r!==null))for(var n=0;n<r.length;n++){var i=r[n],a=i.getSnapshot;i=i.value;try{if(!Gs(a(),i))return!1}catch{return!1}}}if(r=t.child,t.subtreeFlags&16384&&r!==null)r.return=t,t=r;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function du(e,t){for(t&=~Y3,t&=~$y,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var r=31-Ks(t),n=1<<r;e[r]=-1,t&=~n}}function o7(e){if(kr&6)throw Error(Ge(327));Vd();var t=ay(e,0);if(!(t&1))return Sa(e,In()),null;var r=Xy(e,t);if(e.tag!==0&&r===2){var n=R_(e);n!==0&&(t=n,r=e6(e,n))}if(r===1)throw r=Mm,Df(e,0),du(e,t),Sa(e,In()),r;if(r===6)throw Error(Ge(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Uf(e,_a,tc),Sa(e,In()),null}function r6(e,t){var r=kr;kr|=1;try{return e(t)}finally{kr=r,kr===0&&(qd=In()+500,ky&&su())}}function Lf(e){fu!==null&&fu.tag===0&&!(kr&6)&&Vd();var t=kr;kr|=1;var r=_s.transition,n=Fr;try{if(_s.transition=null,Fr=1,e)return e()}finally{Fr=n,_s.transition=r,kr=t,!(kr&6)&&su()}}function n6(){Ka=Ud.current,tn(Ud)}function Df(e,t){e.finishedWork=null,e.finishedLanes=0;var r=e.timeoutHandle;if(r!==-1&&(e.timeoutHandle=-1,L$(r)),Un!==null)for(r=Un.return;r!==null;){var n=r;switch(d3(n),n.tag){case 1:n=n.type.childContextTypes,n!=null&&_y();break;case 3:zd(),tn(va),tn(Li),M3();break;case 5:k3(n);break;case 4:zd();break;case 13:tn(vn);break;case 19:tn(vn);break;case 10:v3(n.type._context);break;case 22:case 23:n6()}r=r.return}if(hi=e,Un=e=pu(e.current,null),Ci=Ka=t,ei=0,Mm=null,Y3=$y=zf=0,_a=Am=null,Nf!==null){for(t=0;t<Nf.length;t++)if(r=Nf[t],n=r.interleaved,n!==null){r.interleaved=null;var i=n.next,a=r.pending;if(a!==null){var s=a.next;a.next=i,n.next=s}r.pending=n}Nf=null}return e}function l7(e,t){do{var r=Un;try{if(y3(),Ry.current=zy,Ny){for(var n=wn.memoizedState;n!==null;){var i=n.queue;i!==null&&(i.pending=null),n=n.next}Ny=!1}if(Pf=0,fi=Qn=wn=null,wm=!1,xm=0,G3.current=null,r===null||r.return===null){ei=1,Mm=t,Un=null;break}e:{var a=e,s=r.return,o=r,c=t;if(t=Ci,o.flags|=32768,c!==null&&typeof c=="object"&&typeof c.then=="function"){var l=c,u=o,d=u.tag;if(!(u.mode&1)&&(d===0||d===11||d===15)){var p=u.alternate;p?(u.updateQueue=p.updateQueue,u.memoizedState=p.memoizedState,u.lanes=p.lanes):(u.updateQueue=null,u.memoizedState=null)}var w=OA(s);if(w!==null){w.flags&=-257,BA(w,s,o,a,t),w.mode&1&&IA(a,l,t),t=w,c=l;var O=t.updateQueue;if(O===null){var I=new Set;I.add(c),t.updateQueue=I}else O.add(c);break e}else{if(!(t&1)){IA(a,l,t),i6();break e}c=Error(Ge(426))}}else if(ln&&o.mode&1){var R=OA(s);if(R!==null){!(R.flags&65536)&&(R.flags|=256),BA(R,s,o,a,t),g3(Ld(c,o));break e}}a=c=Ld(c,o),ei!==4&&(ei=2),Am===null?Am=[a]:Am.push(a),a=s;do{switch(a.tag){case 3:a.flags|=65536,t&=-t,a.lanes|=t;var C=TA(a,c,t);rA(a,C);break e;case 1:o=c;var j=a.type,N=a.stateNode;if(!(a.flags&128)&&(typeof j.getDerivedStateFromError=="function"||N!==null&&typeof N.componentDidCatch=="function"&&(uu===null||!uu.has(N)))){a.flags|=65536,t&=-t,a.lanes|=t;var P=jA(a,o,t);rA(a,P);break e}}a=a.return}while(a!==null)}f7(r)}catch(Z){t=Z,Un===r&&r!==null&&(Un=r=r.return);continue}break}while(!0)}function c7(){var e=Zy.current;return Zy.current=zy,e===null?zy:e}function i6(){(ei===0||ei===3||ei===2)&&(ei=4),hi===null||!(zf&268435455)&&!($y&268435455)||du(hi,Ci)}function Xy(e,t){var r=kr;kr|=2;var n=c7();(hi!==e||Ci!==t)&&(tc=null,Df(e,t));do try{uH();break}catch(i){l7(e,i)}while(!0);if(y3(),kr=r,Zy.current=n,Un!==null)throw Error(Ge(261));return hi=null,Ci=0,ei}function uH(){for(;Un!==null;)u7(Un)}function fH(){for(;Un!==null&&!FZ();)u7(Un)}function u7(e){var t=p7(e.alternate,e,Ka);e.memoizedProps=e.pendingProps,t===null?f7(e):Un=t,G3.current=null}function f7(e){var t=e;do{var r=t.alternate;if(e=t.return,t.flags&32768){if(r=iH(r,t),r!==null){r.flags&=32767,Un=r;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{ei=6,Un=null;return}}else if(r=nH(r,t,Ka),r!==null){Un=r;return}if(t=t.sibling,t!==null){Un=t;return}Un=t=e}while(t!==null);ei===0&&(ei=5)}function Uf(e,t,r){var n=Fr,i=_s.transition;try{_s.transition=null,Fr=1,hH(e,t,r,n)}finally{_s.transition=i,Fr=n}return null}function hH(e,t,r,n){do Vd();while(fu!==null);if(kr&6)throw Error(Ge(327));r=e.finishedWork;var i=e.finishedLanes;if(r===null)return null;if(e.finishedWork=null,e.finishedLanes=0,r===e.current)throw Error(Ge(177));e.callbackNode=null,e.callbackPriority=0;var a=r.lanes|r.childLanes;if(HZ(e,a),e===hi&&(Un=hi=null,Ci=0),!(r.subtreeFlags&2064)&&!(r.flags&2064)||Wy||(Wy=!0,m7(ty,function(){return Vd(),null})),a=(r.flags&15990)!==0,r.subtreeFlags&15990||a){a=_s.transition,_s.transition=null;var s=Fr;Fr=1;var o=kr;kr|=4,G3.current=null,sH(e,r),t7(r,e),O$(a3),ly=!!i3,a3=i3=null,e.current=r,oH(r),PZ(),kr=o,Fr=s,_s.transition=a}else e.current=r;if(Wy&&(Wy=!1,fu=e,Ky=i),a=e.pendingLanes,a===0&&(uu=null),DZ(r.stateNode),Sa(e,In()),t!==null)for(n=e.onRecoverableError,r=0;r<t.length;r++)i=t[r],n(i.value,{componentStack:i.stack,digest:i.digest});if(Hy)throw Hy=!1,e=J3,J3=null,e;return Ky&1&&e.tag!==0&&Vd(),a=e.pendingLanes,a&1?e===Q3?Cm++:(Cm=0,Q3=e):Cm=0,su(),null}function Vd(){if(fu!==null){var e=J9(Ky),t=_s.transition,r=Fr;try{if(_s.transition=null,Fr=16>e?16:e,fu===null)var n=!1;else{if(e=fu,fu=null,Ky=0,kr&6)throw Error(Ge(331));var i=kr;for(kr|=4,gt=e.current;gt!==null;){var a=gt,s=a.child;if(gt.flags&16){var o=a.deletions;if(o!==null){for(var c=0;c<o.length;c++){var l=o[c];for(gt=l;gt!==null;){var u=gt;switch(u.tag){case 0:case 11:case 15:Em(8,u,a)}var d=u.child;if(d!==null)d.return=u,gt=d;else for(;gt!==null;){u=gt;var p=u.sibling,w=u.return;if(YA(u),u===l){gt=null;break}if(p!==null){p.return=w,gt=p;break}gt=w}}}var O=a.alternate;if(O!==null){var I=O.child;if(I!==null){O.child=null;do{var R=I.sibling;I.sibling=null,I=R}while(I!==null)}}gt=a}}if(a.subtreeFlags&2064&&s!==null)s.return=a,gt=s;else e:for(;gt!==null;){if(a=gt,a.flags&2048)switch(a.tag){case 0:case 11:case 15:Em(9,a,a.return)}var C=a.sibling;if(C!==null){C.return=a.return,gt=C;break e}gt=a.return}}var j=e.current;for(gt=j;gt!==null;){s=gt;var N=s.child;if(s.subtreeFlags&2064&&N!==null)N.return=s,gt=N;else e:for(s=j;gt!==null;){if(o=gt,o.flags&2048)try{switch(o.tag){case 0:case 11:case 15:Vy(9,o)}}catch(Z){kn(o,o.return,Z)}if(o===s){gt=null;break e}var P=o.sibling;if(P!==null){P.return=o.return,gt=P;break e}gt=o.return}}if(kr=i,su(),Wo&&typeof Wo.onPostCommitFiberRoot=="function")try{Wo.onPostCommitFiberRoot(ry,e)}catch{}n=!0}return n}finally{Fr=r,_s.transition=t}}return!1}function h7(e,t,r){t=Ld(r,t),t=TA(e,t,1),e=lu(e,t,1),t=ca(),e!==null&&(Jp(e,1,t),Sa(e,t))}function kn(e,t,r){if(e.tag===3)h7(e,e,r);else for(;t!==null;){if(t.tag===3){h7(t,e,r);break}else if(t.tag===1){var n=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(uu===null||!uu.has(n))){e=Ld(r,e),e=jA(t,e,1),t=lu(t,e,1),e=ca(),t!==null&&(Jp(t,1,e),Sa(t,e));break}}t=t.return}}function dH(e,t,r){var n=e.pingCache;n!==null&&n.delete(t),t=ca(),e.pingedLanes|=e.suspendedLanes&r,hi===e&&(Ci&r)===r&&(ei===4||ei===3&&(Ci&130023424)===Ci&&500>In()-X3?Df(e,0):Y3|=r),Sa(e,t)}function d7(e,t){t===0&&(e.mode&1?(t=iy,iy<<=1,!(iy&130023424)&&(iy=4194304)):t=1);var r=ca();e=Jl(e,t),e!==null&&(Jp(e,t,r),Sa(e,r))}function pH(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),d7(e,r)}function mH(e,t){var r=0;switch(e.tag){case 13:var n=e.stateNode,i=e.memoizedState;i!==null&&(r=i.retryLane);break;case 19:n=e.stateNode;break;default:throw Error(Ge(314))}n!==null&&n.delete(t),d7(e,r)}var p7;p7=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||va.current)xa=!0;else{if(!(e.lanes&r)&&!(t.flags&128))return xa=!1,rH(e,t,r);xa=!!(e.flags&131072)}else xa=!1,ln&&t.flags&1048576&&HM(t,My,t.index);switch(t.lanes=0,t.tag){case 2:var n=t.type;Uy(e,t),e=t.pendingProps;var i=Id(t,Li.current);Pd(t,r),i=T3(null,t,n,e,i,r);var a=j3();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,wa(n)?(a=!0,Sy(t)):a=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,_3(t),i.updater=Ly,t.stateNode=i,i._reactInternals=t,F3(t,n,e,r),t=D3(null,t,n,!0,a,r)):(t.tag=0,ln&&a&&h3(t),la(null,t,i,r),t=t.child),t;case 16:n=t.elementType;e:{switch(Uy(e,t),e=t.pendingProps,i=n._init,n=i(n._payload),t.type=n,i=t.tag=bH(n),e=Xs(n,e),i){case 0:t=L3(null,t,n,e,r);break e;case 1:t=LA(null,t,n,e,r);break e;case 11:t=RA(null,t,n,e,r);break e;case 14:t=NA(null,t,n,Xs(n.type,e),r);break e}throw Error(Ge(306,n,""))}return t;case 0:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Xs(n,i),L3(e,t,n,i,r);case 1:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Xs(n,i),LA(e,t,n,i,r);case 3:e:{if(DA(t),e===null)throw Error(Ge(387));n=t.pendingProps,a=t.memoizedState,i=a.element,tA(e,t),Oy(t,n,null,r);var s=t.memoizedState;if(n=s.element,a.isDehydrated)if(a={element:n,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=a,t.memoizedState=a,t.flags&256){i=Ld(Error(Ge(423)),t),t=UA(e,t,n,r,i);break e}else if(n!==i){i=Ld(Error(Ge(424)),t),t=UA(e,t,n,r,i);break e}else for(Wa=nu(t.stateNode.containerInfo.firstChild),Ha=t,ln=!0,Ys=null,r=QM(t,null,n,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(Rd(),n===i){t=ec(e,t,r);break e}la(e,t,n,r)}t=t.child}return t;case 5:return iA(t),e===null&&m3(t),n=t.type,i=t.pendingProps,a=e!==null?e.memoizedProps:null,s=i.children,s3(n,i)?s=null:a!==null&&s3(n,a)&&(t.flags|=32),zA(e,t),la(e,t,s,r),t.child;case 6:return e===null&&m3(t),null;case 13:return qA(e,t,r);case 4:return S3(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=Nd(t,null,n,r):la(e,t,n,r),t.child;case 11:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Xs(n,i),RA(e,t,n,i,r);case 7:return la(e,t,t.pendingProps,r),t.child;case 8:return la(e,t,t.pendingProps.children,r),t.child;case 12:return la(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(n=t.type._context,i=t.pendingProps,a=t.memoizedProps,s=i.value,Hr(Ty,n._currentValue),n._currentValue=s,a!==null)if(Gs(a.value,s)){if(a.children===i.children&&!va.current){t=ec(e,t,r);break e}}else for(a=t.child,a!==null&&(a.return=t);a!==null;){var o=a.dependencies;if(o!==null){s=a.child;for(var c=o.firstContext;c!==null;){if(c.context===n){if(a.tag===1){c=Ql(-1,r&-r),c.tag=2;var l=a.updateQueue;if(l!==null){l=l.shared;var u=l.pending;u===null?c.next=c:(c.next=u.next,u.next=c),l.pending=c}}a.lanes|=r,c=a.alternate,c!==null&&(c.lanes|=r),w3(a.return,r,t),o.lanes|=r;break}c=c.next}}else if(a.tag===10)s=a.type===t.type?null:a.child;else if(a.tag===18){if(s=a.return,s===null)throw Error(Ge(341));s.lanes|=r,o=s.alternate,o!==null&&(o.lanes|=r),w3(s,r,t),s=a.sibling}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===t){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}la(e,t,i.children,r),t=t.child}return t;case 9:return i=t.type,n=t.pendingProps.children,Pd(t,r),i=ws(i),n=n(i),t.flags|=1,la(e,t,n,r),t.child;case 14:return n=t.type,i=Xs(n,t.pendingProps),i=Xs(n.type,i),NA(e,t,n,i,r);case 15:return FA(e,t,t.type,t.pendingProps,r);case 17:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Xs(n,i),Uy(e,t),t.tag=1,wa(n)?(e=!0,Sy(t)):e=!1,Pd(t,r),AA(t,n,i),F3(t,n,i,r),D3(null,t,n,!0,e,r);case 19:return ZA(e,t,r);case 22:return PA(e,t,r)}throw Error(Ge(156,t.tag))};function m7(e,t){return W9(e,t)}function gH(e,t,r,n){this.tag=e,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Ss(e,t,r,n){return new gH(e,t,r,n)}function a6(e){return e=e.prototype,!(!e||!e.isReactComponent)}function bH(e){if(typeof e=="function")return a6(e)?1:0;if(e!=null){if(e=e.$$typeof,e===h_)return 11;if(e===m_)return 14}return 2}function pu(e,t){var r=e.alternate;return r===null?(r=Ss(e.tag,t,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&14680064,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.dependencies,r.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r}function Jy(e,t,r,n,i,a){var s=2;if(n=e,typeof e=="function")a6(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case yd:return qf(r.children,i,a,t);case u_:s=8,i|=8;break;case f_:return e=Ss(12,r,t,i|2),e.elementType=f_,e.lanes=a,e;case d_:return e=Ss(13,r,t,i),e.elementType=d_,e.lanes=a,e;case p_:return e=Ss(19,r,t,i),e.elementType=p_,e.lanes=a,e;case S9:return Qy(r,i,a,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case x9:s=10;break e;case _9:s=9;break e;case h_:s=11;break e;case m_:s=14;break e;case Gc:s=16,n=null;break e}throw Error(Ge(130,e==null?e:typeof e,""))}return t=Ss(s,r,t,i),t.elementType=e,t.type=n,t.lanes=a,t}function qf(e,t,r,n){return e=Ss(7,e,n,t),e.lanes=r,e}function Qy(e,t,r,n){return e=Ss(22,e,n,t),e.elementType=S9,e.lanes=r,e.stateNode={isHidden:!1},e}function s6(e,t,r){return e=Ss(6,e,null,t),e.lanes=r,e}function o6(e,t,r){return t=Ss(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function yH(e,t,r,n,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=N_(0),this.expirationTimes=N_(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=N_(0),this.identifierPrefix=n,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function l6(e,t,r,n,i,a,s,o,c){return e=new yH(e,t,r,o,c),t===1?(t=1,a===!0&&(t|=8)):t=0,a=Ss(3,null,null,t),e.current=a,a.stateNode=e,a.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},_3(a),e}function vH(e,t,r){var n=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:bd,key:n==null?null:""+n,children:e,containerInfo:t,implementation:r}}function g7(e){if(!e)return au;e=e._reactInternals;e:{if(jf(e)!==e||e.tag!==1)throw Error(Ge(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(wa(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(Ge(171))}if(e.tag===1){var r=e.type;if(wa(r))return VM(e,r,t)}return t}function b7(e,t,r,n,i,a,s,o,c){return e=l6(r,n,!0,e,i,a,s,o,c),e.context=g7(null),r=e.current,n=ca(),i=hu(r),a=Ql(n,i),a.callback=t??null,lu(r,a,i),e.current.lanes=i,Jp(e,i,n),Sa(e,n),e}function ev(e,t,r,n){var i=t.current,a=ca(),s=hu(i);return r=g7(r),t.context===null?t.context=r:t.pendingContext=r,t=Ql(a,s),t.payload={element:e},n=n===void 0?null:n,n!==null&&(t.callback=n),e=lu(i,t,s),e!==null&&(eo(e,i,s,a),Iy(e,i,s)),s}function tv(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function y7(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var r=e.retryLane;e.retryLane=r!==0&&r<t?r:t}}function c6(e,t){y7(e,t),(e=e.alternate)&&y7(e,t)}function wH(){return null}var v7=typeof reportError=="function"?reportError:function(e){console.error(e)};function u6(e){this._internalRoot=e}rv.prototype.render=u6.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(Ge(409));ev(e,t,null,null)},rv.prototype.unmount=u6.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Lf(function(){ev(null,e,null,null)}),t[Kl]=null}};function rv(e){this._internalRoot=e}rv.prototype.unstable_scheduleHydration=function(e){if(e){var t=tM();e={blockedOn:null,target:e,priority:t};for(var r=0;r<eu.length&&t!==0&&t<eu[r].priority;r++);eu.splice(r,0,e),r===0&&iM(e)}};function f6(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function nv(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function w7(){}function xH(e,t,r,n,i){if(i){if(typeof n=="function"){var a=n;n=function(){var l=tv(s);a.call(l)}}var s=b7(t,n,e,0,null,!1,!1,"",w7);return e._reactRootContainer=s,e[Kl]=s.current,hm(e.nodeType===8?e.parentNode:e),Lf(),s}for(;i=e.lastChild;)e.removeChild(i);if(typeof n=="function"){var o=n;n=function(){var l=tv(c);o.call(l)}}var c=l6(e,0,!1,null,null,!1,!1,"",w7);return e._reactRootContainer=c,e[Kl]=c.current,hm(e.nodeType===8?e.parentNode:e),Lf(function(){ev(t,c,r,n)}),c}function iv(e,t,r,n,i){var a=r._reactRootContainer;if(a){var s=a;if(typeof i=="function"){var o=i;i=function(){var c=tv(s);o.call(c)}}ev(t,s,e,i)}else s=xH(r,t,e,i,n);return tv(s)}Q9=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var r=Xp(t.pendingLanes);r!==0&&(F_(t,r|1),Sa(t,In()),!(kr&6)&&(qd=In()+500,su()))}break;case 13:Lf(function(){var n=Jl(e,1);if(n!==null){var i=ca();eo(n,e,1,i)}}),c6(e,1)}},P_=function(e){if(e.tag===13){var t=Jl(e,134217728);if(t!==null){var r=ca();eo(t,e,134217728,r)}c6(e,134217728)}},eM=function(e){if(e.tag===13){var t=hu(e),r=Jl(e,t);if(r!==null){var n=ca();eo(r,e,t,n)}c6(e,t)}},tM=function(){return Fr},rM=function(e,t){var r=Fr;try{return Fr=e,t()}finally{Fr=r}},T_=function(e,t,r){switch(t){case"input":if(x_(e,r),t=r.name,r.type==="radio"&&t!=null){for(r=e;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<r.length;t++){var n=r[t];if(n!==e&&n.form===e.form){var i=xy(n);if(!i)throw Error(Ge(90));M9(n),x_(n,i)}}}break;
8case"textarea":I9(e,r);break;case"select":t=r.value,t!=null&&vd(e,!!r.multiple,t,!1)}},D9=r6,U9=Lf;var _H={usingClientEntryPoint:!1,Events:[mm,Td,xy,z9,L9,r6]},Tm={findFiberByHostInstance:If,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},SH={bundleType:Tm.bundleType,version:Tm.version,rendererPackageName:Tm.rendererPackageName,rendererConfig:Tm.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Wl.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=$9(e),e===null?null:e.stateNode},findFiberByHostInstance:Tm.findFiberByHostInstance||wH,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var av=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!av.isDisabled&&av.supportsFiber)try{ry=av.inject(SH),Wo=av}catch{}}ya.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=_H,ya.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!f6(t))throw Error(Ge(200));return vH(e,t,null,r)},ya.createRoot=function(e,t){if(!f6(e))throw Error(Ge(299));var r=!1,n="",i=v7;return t!=null&&(t.unstable_strictMode===!0&&(r=!0),t.identifierPrefix!==void 0&&(n=t.identifierPrefix),t.onRecoverableError!==void 0&&(i=t.onRecoverableError)),t=l6(e,1,!1,null,null,r,!1,n,i),e[Kl]=t.current,hm(e.nodeType===8?e.parentNode:e),new u6(t)},ya.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(Ge(188)):(e=Object.keys(e).join(","),Error(Ge(268,e)));return e=$9(t),e=e===null?null:e.stateNode,e},ya.flushSync=function(e){return Lf(e)},ya.hydrate=function(e,t,r){if(!nv(t))throw Error(Ge(200));return iv(null,e,t,!0,r)},ya.hydrateRoot=function(e,t,r){if(!f6(e))throw Error(Ge(405));var n=r!=null&&r.hydratedSources||null,i=!1,a="",s=v7;if(r!=null&&(r.unstable_strictMode===!0&&(i=!0),r.identifierPrefix!==void 0&&(a=r.identifierPrefix),r.onRecoverableError!==void 0&&(s=r.onRecoverableError)),t=b7(t,null,e,1,r??null,i,!1,a,s),e[Kl]=t.current,hm(e),n)for(e=0;e<n.length;e++)r=n[e],i=r._getVersion,i=i(r._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[r,i]:t.mutableSourceEagerHydrationData.push(r,i);return new rv(t)},ya.render=function(e,t,r){if(!nv(t))throw Error(Ge(200));return iv(null,e,t,!1,r)},ya.unmountComponentAtNode=function(e){if(!nv(e))throw Error(Ge(40));return e._reactRootContainer?(Lf(function(){iv(null,null,e,!1,function(){e._reactRootContainer=null,e[Kl]=null})}),!0):!1},ya.unstable_batchedUpdates=r6,ya.unstable_renderSubtreeIntoContainer=function(e,t,r,n){if(!nv(r))throw Error(Ge(200));if(e==null||e._reactInternals===void 0)throw Error(Ge(38));return iv(e,t,r,!1,n)},ya.version="18.3.1-next-f1338f8080-20240426";function x7(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(x7)}catch(e){console.error(e)}}x7(),n_.exports=ya;var jm=n_.exports,_7=jm;K1.createRoot=_7.createRoot,K1.hydrateRoot=_7.hydrateRoot;function Im(){return Im=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Im.apply(this,arguments)}var mu;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(mu||(mu={}));const S7="popstate";function kH(e){e===void 0&&(e={});function t(n,i){let{pathname:a,search:s,hash:o}=n.location;return h6("",{pathname:a,search:s,hash:o},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function r(n,i){return typeof i=="string"?i:sv(i)}return MH(t,r,null,e)}function qn(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function k7(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function EH(){return Math.random().toString(36).substr(2,8)}function E7(e,t){return{usr:e.state,key:e.key,idx:t}}function h6(e,t,r,n){return r===void 0&&(r=null),Im({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Zd(t):t,{state:r,key:t&&t.key||n||EH()})}function sv(e){let{pathname:t="/",search:r="",hash:n=""}=e;return r&&r!=="?"&&(t+=r.charAt(0)==="?"?r:"?"+r),n&&n!=="#"&&(t+=n.charAt(0)==="#"?n:"#"+n),t}function Zd(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substr(r),e=e.substr(0,r));let n=e.indexOf("?");n>=0&&(t.search=e.substr(n),e=e.substr(0,n)),e&&(t.pathname=e)}return t}function MH(e,t,r,n){n===void 0&&(n={});let{window:i=document.defaultView,v5Compat:a=!1}=n,s=i.history,o=mu.Pop,c=null,l=u();l==null&&(l=0,s.replaceState(Im({},s.state,{idx:l}),""));function u(){return(s.state||{idx:null}).idx}function d(){o=mu.Pop;let R=u(),C=R==null?null:R-l;l=R,c&&c({action:o,location:I.location,delta:C})}function p(R,C){o=mu.Push;let j=h6(I.location,R,C);l=u()+1;let N=E7(j,l),P=I.createHref(j);try{s.pushState(N,"",P)}catch(Z){if(Z instanceof DOMException&&Z.name==="DataCloneError")throw Z;i.location.assign(P)}a&&c&&c({action:o,location:I.location,delta:1})}function w(R,C){o=mu.Replace;let j=h6(I.location,R,C);l=u();let N=E7(j,l),P=I.createHref(j);s.replaceState(N,"",P),a&&c&&c({action:o,location:I.location,delta:0})}function O(R){let C=i.location.origin!=="null"?i.location.origin:i.location.href,j=typeof R=="str
8ing"?R:sv(R);return j=j.replace(/ $/,"%20"),qn(C,"No window.location.(origin|href) available to create URL for href: "+j),new URL(j,C)}let I={get action(){return o},get location(){return e(i,s)},listen(R){if(c)throw new Error("A history only accepts one active listener");return i.addEventListener(S7,d),c=R,()=>{i.removeEventListener(S7,d),c=null}},createHref(R){return t(i,R)},createURL:O,encodeLocation(R){let C=O(R);return{pathname:C.pathname,search:C.search,hash:C.hash}},push:p,replace:w,go(R){return s.go(R)}};return I}var M7;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(M7||(M7={}));function AH(e,t,r){return r===void 0&&(r="/"),CH(e,t,r,!1)}function CH(e,t,r,n){let i=typeof t=="string"?Zd(t):t,a=d6(i.pathname||"/",r);if(a==null)return null;let s=A7(e);TH(s);let o=null;for(let c=0;o==null&&c<s.length;++c){let l=DH(a);o=zH(s[c],l,n)}return o}function A7(e,t,r,n){t===void 0&&(t=[]),r===void 0&&(r=[]),n===void 0&&(n="");let i=(a,s,o)=>{let c={relativePath:o===void 0?a.path||"":o,caseSensitive:a.caseSensitive===!0,childrenIndex:s,route:a};c.relativePath.startsWith("/")&&(qn(c.relativePath.startsWith(n),'Absolute route path "'+c.relativePath+'" nested under path '+('"'+n+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),c.relativePath=c.relativePath.slice(n.length));let l=gu([n,c.relativePath]),u=r.concat(c);a.children&&a.children.length>0&&(qn(a.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+l+'".')),A7(a.children,t,u,l)),!(a.path==null&&!a.index)&&t.push({path:l,score:FH(l,a.index),routesMeta:u})};return e.forEach((a,s)=>{var o;if(a.path===""||!((o=a.path)!=null&&o.includes("?")))i(a,s);else for(let c of C7(a.path))i(a,s,c)}),t}function C7(e){let t=e.split("/");if(t.length===0)return[];let[r,...n]=t,i=r.endsWith("?"),a=r.replace(/\?$/,"");if(n.length===0)return i?[a,""]:[a];let s=C7(n.join("/")),o=[];return o.push(...s.map(c=>c===""?a:[a,c].join("/"))),i&&o.push(...s),o.map(c=>e.startsWith("/")&&c===""?"/":c)}function TH(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:PH(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}const jH=/^:[\w-]+$/,IH=3,OH=2,BH=1,RH=10,NH=-2,T7=e=>e==="*";function FH(e,t){let r=e.split("/"),n=r.length;return r.some(T7)&&(n+=NH),t&&(n+=OH),r.filter(i=>!T7(i)).reduce((i,a)=>i+(jH.test(a)?IH:a===""?BH:RH),n)}function PH(e,t){return e.length===t.length&&e.slice(0,-1).every((r,n)=>r===t[n])?e[e.length-1]-t[t.length-1]:0}function zH(e,t,r){let{routesMeta:n}=e,i={},a="/",s=[];for(let o=0;o<n.length;++o){let c=n[o],l=o===n.length-1,u=a==="/"?t:t.slice(a.length)||"/",d=j7({path:c.relativePath,caseSensitive:c.caseSensitive,end:l},u),p=c.route;if(!d&&l&&r&&!n[n.length-1].route.index&&(d=j7({path:c.relativePath,caseSensitive:c.caseSensitive,end:!1},u)),!d)return null;
vendor: 10,841 bytes, line 8
8Object.assign(i,d.params),s.push({params:i,pathname:gu([a,d.pathname]),pathnameBase:ZH(gu([a,d.pathnameBase])),route:p}),d.pathnameBase!=="/"&&(a=gu([a,d.pathnameBase]))}return s}function j7(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[r,n]=LH(e.path,e.caseSensitive,e.end),i=t.match(r);if(!i)return null;let a=i[0],s=a.replace(/(.)\/+$/,"$1"),o=i.slice(1);return{params:n.reduce((c,l,u)=>{let{paramName:d,isOptional:p}=l;if(d==="*"){let O=o[u]||"";s=a.slice(0,a.length-O.length).replace(/(.)\/+$/,"$1")}const w=o[u];return p&&!w?c[d]=void 0:c[d]=(w||"").replace(/%2F/g,"/"),c},{}),pathname:a,pathnameBase:s,pattern:e}}function LH(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!0),k7(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let n=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(a,s,o)=>(n.push({paramName:s,isOptional:o!=null}),o?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(n.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),n]}function DH(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return k7(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function d6(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,n=e.charAt(r);return n&&n!=="/"?null:e.slice(r)||"/"}function UH(e,t){t===void 0&&(t="/");let{pathname:r,search:n="",hash:i=""}=typeof e=="string"?Zd(e):e;return{pathname:r?r.startsWith("/")?r:qH(r,t):t,search:$H(n),hash:HH(i)}}function qH(e,t){let r=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(n=>{n===".."?r.length>1&&r.pop():n!=="."&&r.push(n)}),r.length>1?r.join("/"):"/"}function p6(e,t,r,n){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(n)+"].  Please separate it out to the ")+("`to."+r+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function VH(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}function I7(e,t){let r=VH(e);return t?r.map((n,i)=>i===r.length-1?n.pathname:n.pathnameBase):r.map(n=>n.pathnameBase)}function O7(e,t,r,n){n===void 0&&(n=!1);let i;typeof e=="string"?i=Zd(e):(i=Im({},e),qn(!i.pathname||!i.pathname.includes("?"),p6("?","pathname","search",i)),qn(!i.pathname||!i.pathname.includes("#"),p6("#","pathname","hash",i)),qn(!i.search||!i.search.includes("#"),p6("#","search","hash",i)));let a=e===""||i.pathname==="",s=a?"/":i.pathname,o;if(s==null)o=r;else{let d=t.length-1;if(!n&&s.startsWith("..")){let p=s.split("/");for(;p[0]==="..";)p.shift(),d-=1;i.pathname=p.join("/")}o=d>=0?t[d]:"/"}let c=UH(i,o),l=s&&s!=="/"&&s.endsWith("/"),u=(a||s===".")&&r.endsWith("/");return!c.pathname.endsWith("/")&&(l||u)&&(c.pathname+="/"),c}const gu=e=>e.join("/").replace(/\/\/+/g,"/"),ZH=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),$H=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,HH=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function WH(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const B7=["post","put","patch","delete"];new Set(B7);const KH=["get",...B7];new Set(KH);function Om(){return Om=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Om.apply(this,arguments)}const m6=he.createContext(null),GH=he.createContext(null),Vf=he.createContext(null),ov=he.createContext(null),bu=he.createContext({outlet:null,matches:[],isDataRoute:!1}),R7=he.createContext(null);function YH(e,t){let{relative:r}=t===void 0?{}:t;Bm()||qn(!1);let{basename:n,navigator:i}=he.useContext(Vf),{hash:a,pathname:s,search:o}=F7(e,{relative:r}),c=s;return n!=="/"&&(c=s==="/"?n:gu([n,s])),i.createHref({pathname:c,search:o,hash:a})}function Bm(){return he.useContext(ov)!=null}function to(){return Bm()||qn(!1),he.useContext(ov).location}function N7(e){he.useContext(Vf).static||he.useLayoutEffect(e)}function g6(){let{isDataRoute:e}=he.useContext(bu);return e?cW():XH()}function XH(){Bm()||qn(!1);let e=he.useContext(m6),{basename:t,future:r,navigator:n}=he.useContext(Vf),{matches:i}=he.useContext(bu),{pathname:a}=to(),s=JSON.stringify(I7(i,r.v7_relativeSplatPath)),o=he.useRef(!1);return N7(()=>{o.current=!0}),he.useCallback(function(c,l){if(l===void 0&&(l={}),!o.current)return;if(typeof c=="number"){n.go(c);return}let u=O7(c,JSON.parse(s),a,l.relative==="path");e==null&&t!=="/"&&(u.pathname=u.pathname==="/"?t:gu([t,u.pathname])),(l.replace?n.replace:n.push)(u,l.state,l)},[t,n,s,a,e])}function $d(){let{matches:e}=he.useContext(bu),t=e[e.length-1];return t?t.params:{}}function F7(e,t){let{relative:r}=t===void 0?{}:t,{future:n}=he.useContext(Vf),{matches:i}=he.useContext(bu),{pathname:a}=to(),s=JSON.stringify(I7(i,n.v7_relativeSplatPath));return he.useMemo(()=>O7(e,JSON.parse(s),a,r==="path"),[e,s,a,r])}function JH(e,t){return QH(e,t)}function QH(e,t,r,n){Bm()||qn(!1);let{navigator:i}=he.useContext(Vf),{matches:a}=he.useContext(bu),s=a[a.length-1],o=s?s.params:{};s&&s.pathname;let c=s?s.pathnameBase:"/";s&&s.route;let l=to(),u;if(t){var d;let R=typeof t=="string"?Zd(t):t;c==="/"||(d=R.pathname)!=null&&d.startsWith(c)||qn(!1),u=R}else u=l;let p=u.pathname||"/",w=p;if(c!=="/"){let R=c.replace(/^\//,"").split("/");w="/"+p.replace(/^\//,"").split("/").slice(R.length).join("/")}let O=AH(e,{pathname:w}),I=iW(O&&O.map(R=>Object.assign({},R,{params:Object.assign({},o,R.params),pathname:gu([c,i.encodeLocation?i.encodeLocation(R.pathname).pathname:R.pathname]),pathnameBase:R.pathnameBase==="/"?c:gu([c,i.encodeLocation?i.encodeLocation(R.pathnameBase).pathname:R.pathnameBase])})),a,r,n);return t&&I?he.createElement(ov.Provider,{value:{location:Om({pathname:"/",search:"",hash:"",state:null,key:"default"},u),navigationType:mu.Pop}},I):I}function eW(){let e=lW(),t=WH(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,n={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return he.createElement(he.Fragment,null,he.createElement("h2",null,"Unexpected Application Error!"),he.createElement("h3",{style:{fontStyle:"italic"}},t),r?he.createElement("pre",{style:n},r):null,null)}const tW=he.createElement(eW,null);class rW extends he.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,r){return r.location!==t.location||r.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:r.error,location:r.location,revalidation:t.revalidation||r.revalidation}}componentDidCatch(t,r){console.error("React Router caught the following error during render",t,r)}render(){return this.state.error!==void 0?he.createElement(bu.Provider,{value:this.props.routeContext},he.createElement(R7.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function nW(e){let{routeContext:t,match:r,children:n}=e,i=he.useContext(m6);return i&&i.static&&i.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=r.route.id),he.createElement(bu.Provider,{value:t},n)}function iW(e,t,r,n){var i;if(t===void 0&&(t=[]),r===void 0&&(r=null),n===void 0&&(n=null),e==null){var a;if(!r)return null;if(r.errors)e=r.matches;else if((a=n)!=null&&a.v7_partialHydration&&t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let s=e,o=(i=r)==null?void 0:i.errors;if(o!=null){let u=s.findIndex(d=>d.route.id&&(o==null?void 0:o[d.route.id])!==void 0);u>=0||qn(!1),s=s.slice(0,Math.min(s.length,u+1))}let c=!1,l=-1;if(r&&n&&n.v7_partialHydration)for(let u=0;u<s.length;u++){let d=s[u];if((d.route.HydrateFallback||d.route.hydrateFallbackElement)&&(l=u),d.route.id){let{loaderData:p,errors:w}=r,O=d.route.loader&&p[d.route.id]===void 0&&(!w||w[d.route.id]===void 0);if(d.route.lazy||O){c=!0,l>=0?s=s.slice(0,l+1):s=[s[0]];break}}}return s.reduceRight((u,d,p)=>{let w,O=!1,I=null,R=null;r&&(w=o&&d.route.id?o[d.route.id]:void 0,I=d.route.errorElement||tW,c&&(l<0&&p===0?(O=!0,R=null):l===p&&(O=!0,R=d.route.hydrateFallbackElement||null)));let C=t.concat(s.slice(0,p+1)),j=()=>{let N;return w?N=I:O?N=R:d.route.Component?N=he.createElement(d.route.Component,null):d.route.element?N=d.route.element:N=u,he.createElement(nW,{match:d,routeContext:{outlet:u,matches:C,isDataRoute:r!=null},children:N})};return r&&(d.route.ErrorBoundary||d.route.errorElement||p===0)?he.createElement(rW,{location:r.location,revalidation:r.revalidation,component:I,error:w,children:j(),routeContext:{outlet:null,matches:C,isDataRoute:!0}}):j()},null)}var P7=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(P7||{}),lv=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(lv||{});function aW(e){let t=he.useContext(m6);return t||qn(!1),t}function sW(e){let t=he.useContext(GH);return t||qn(!1),t}function oW(e){let t=he.useContext(bu);return t||qn(!1),t}function z7(e){let t=oW(),r=t.matches[t.matches.length-1];return r.route.id||qn(!1),r.route.id}function lW(){var e;let t=he.useContext(R7),r=sW(lv.UseRouteError),n=z7(lv.UseRouteError);return t!==void 0?t:(e=r.errors)==null?void 0:e[n]}function cW(){let{router:e}=aW(P7.UseNavigateStable),t=z7(lv.UseNavigateStable),r=he.useRef(!1);return N7(()=>{r.current=!0}),he.useCallback(function(n,i){i===void 0&&(i={}),r.current&&(typeof n=="number"?e.navigate(n):e.navigate(n,Om({fromRouteId:t},i)))},[e,t])}function Ga(e){qn(!1)}function uW(e){let{basename:t="/",children:r=null,location:n,navigationType:i=mu.Pop,navigator:a,static:s=!1,future:o}=e;Bm()&&qn(!1);let c=t.replace(/^\/*/,"/"),l=he.useMemo(()=>({basename:c,navigator:a,static:s,future:Om({v7_relativeSplatPath:!1},o)}),[c,o,a,s]);typeof n=="string"&&(n=Zd(n));
8let{pathname:u="/",search:d="",hash:p="",state:w=null,key:O="default"}=n,I=he.useMemo(()=>{let R=d6(u,c);return R==null?null:{location:{pathname:R,search:d,hash:p,state:w,key:O},navigationType:i}},[c,u,d,p,w,O,i]);return I==null?null:he.createElement(Vf.Provider,{value:l},he.createElement(ov.Provider,{children:r,value:I}))}function fW(e){let{children:t,location:r}=e;return JH(b6(t),r)}new Promise(()=>{});function b6(e,t){t===void 0&&(t=[]);let r=[];return he.Children.forEach(e,(n,i)=>{if(!he.isValidElement(n))return;let a=[...t,i];if(n.type===he.Fragment){r.push.apply(r,b6(n.props.children,a));return}n.type!==Ga&&qn(!1),!n.props.index||!n.props.children||qn(!1);let s={id:n.props.id||a.join("-"),caseSensitive:n.props.caseSensitive,element:n.props.element,Component:n.props.Component,index:n.props.index,path:n.props.path,loader:n.props.loader,action:n.props.action,errorElement:n.props.errorElement,ErrorBoundary:n.props.ErrorBoundary,hasErrorBoundary:n.props.ErrorBoundary!=null||n.props.errorElement!=null,shouldRevalidate:n.props.shouldRevalidate,handle:n.props.handle,lazy:n.props.lazy};n.props.children&&(s.children=b6(n.props.children,a)),r.push(s)}),r}function y6(){return y6=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},y6.apply(this,arguments)}function hW(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,a;for(a=0;a<n.length;a++)i=n[a],!(t.indexOf(i)>=0)&&(r[i]=e[i]);return r}function dW(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function pW(e,t){return e.button===0&&(!t||t==="_self")&&!dW(e)}const mW=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","unstable_viewTransition"],gW="6";try{window.__reactRouterVersion=gW}catch{}const bW="startTransition",L7=dZ[bW];function yW(e){let{basename:t,children:r,future:n,window:i}=e,a=he.useRef();a.current==null&&(a.current=kH({window:i,v5Compat:!0}));let s=a.current,[o,c]=he.useState({action:s.action,location:s.location}),{v7_startTransition:l}=n||{},u=he.useCallback(d=>{l&&L7?L7(()=>c(d)):c(d)},[c,l]);return he.useLayoutEffect(()=>s.listen(u),[s,u]),he.createElement(uW,{basename:t,children:r,location:o.location,navigationType:o.action,navigator:s,future:n})}const vW=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",wW=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,v6=he.forwardRef(function(e,t){let{onClick:r,relative:n,reloadDocument:i,replace:a,state:s,target:o,to:c,preventScrollReset:l,unstable_viewTransition:u}=e,d=hW(e,mW),{basename:p}=he.useContext(Vf),w,O=!1;if(typeof c=="string"&&wW.test(c)&&(w=c,vW))try{let j=new URL(window.location.href),N=c.startsWith("//")?new URL(j.protocol+c):new URL(c),P=d6(N.pathname,p);N.origin===j.origin&&P!=null?c=P+N.search+N.hash:O=!0}catch{}let I=YH(c,{relative:n}),R=xW(c,{replace:a,state:s,target:o,preventScrollReset:l,relative:n,unstable_viewTransition:u});function C(j){r&&r(j),j.defaultPrevented||R(j)}return he.createElement("a",y6({},d,{href:w||I,onClick:O||i?r:C,ref:t,target:o}))});var D7;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(D7||(D7={}));var U7;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(U7||(U7={}));function xW(e,t){let{target:r,replace:n,state:i,preventScrollReset:a,relative:s,unstable_viewTransition:o}=t===void 0?{}:t,c=g6(),l=to(),u=F7(e,{relative:s});return he.useCallback(d=>{if(pW(d,r)){d.preventDefault();let p=n!==void 0?n:sv(l)===sv(u);c(e,{replace:p,state:i,preventScrollReset:a,relative:s,unstable_viewTransition:o})}},[l,c,u,n,i,r,e,a,s,o])}var q7={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},V7=Ei.createContext&&Ei.createContext(q7),_W=["attr","size","title"];function SW(e,t){if(e==null)return{};var r=kW(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function kW(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function cv(){return cv=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];
vendor: 2,077 bytes, line 8
8for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},cv.apply(this,arguments)}function Z7(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function uv(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Z7(Object(r),!0).forEach(function(n){EW(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Z7(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function EW(e,t,r){return t=MW(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function MW(e){var t=AW(e,"string");return typeof t=="symbol"?t:t+""}function AW(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function $7(e){return e&&e.map((t,r)=>Ei.createElement(t.tag,uv({key:r},t.attr),$7(t.child)))}function dr(e){return t=>Ei.createElement(CW,cv({attr:uv({},e.attr)},t),$7(e.child))}function CW(e){var t=r=>{var{attr:n,size:i,title:a}=e,s=SW(e,_W),o=i||r.size||"1em",c;return r.className&&(c=r.className),e.className&&(c=(c?c+" ":"")+e.className),Ei.createElement("svg",cv({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},r.attr,n,s,{className:c,style:uv(uv({color:e.color||r.color},r.style),e.style),height:o,width:o,xmlns:"http://www.w3.org/2000/svg"}),a&&Ei.createElement("title",null,a),e.children)};return V7!==void 0?Ei.createElement(V7.Consumer,null,r=>t(r)):t(q7)}function TW(e){return dr({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M9.37 5.51A7.35 7.35 0 0 0 9.1 7.5c0 4.08 3.32 7.4 7.4 7.4.68 0 1.35-.09 1.99-.27A7.014 7.014 0 0 1 12 19c-3.8
86 0-7-3.14-7-7 0-2.93 1.81-5.45 4.37-6.49zM12 3a9 9 0 1 0 9 9c0-.46-.04-.92-.1-1.36a5.389 5.389 0 0 1-4.4 2.26 5.403 5.403 0 0 1-3.14-9.8c-.44-.06-.9-.1-1.36-.1z"},child:[]}]})(e)}function jW(e){return dr({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M12 9c1.65 0 3 1.35 3 3s-1.35 3-3 3-3-1.35-3-3 1.35-3 3-3m0-2c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zM2 13h2c.55 0 1-.45 1-1s-.45-1-1-1H2c-.55 0-1 .45-1 1s.45 1 1 1zm18 0h2c.55 0 1-.45 1-1s-.45-1-1-1h-2c-.55 0-1 .45-1 1s.45 1 1 1zM11 2v2c0 .55.45 1 1 1s1-.45 1-1V2c0-.55-.45-1-1-1s-1 .45-1 1zm0 18v2c0 .55.45 1 1 1s1-.45 1-1v-2c0-.55-.45-1-1-1s-1 .45-1 1zM5.99 4.58a.996.996 0 0 0-1.41 0 .996.996 0 0 0 0 1.41l1.06 1.06c.39.39 1.03.39 1.41 0s.39-1.03 0-1.41L5.99 4.58zm12.37 12.37a.996.996 0 0 0-1.41 0 .996.996 0 0 0 0 1.41l1.06 1.06c.39.39 1.03.39 1.41 0a.996.996 0 0 0 0-1.41l-1.06-1.06zm1.06-10.96a.996.996 0 0 0 0-1.41.996.996 0 0 0-1.41 0l-1.06 1.06c-.39.39-.39 1.03 0 1.41s1.03.39 1.41 0l1.06-1.06zM7.05 18.36a.996.996 0 0 0 0-1.41.996.996 0 0 0-1.41 0l-1.06 1.06c-.39.39-.39 1.03 0 1.41s1.03.39 1.41 0l1.06-1.06z"},child:[]}]})(e)}function IW(e){return dr({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"},child:[]},{tag:"path",attr:{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z"},child:[]}]})(e)}function OW(e){return dr({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"},child:[]},{tag:"path",attr:{d:"M7.41 15.41 12 10.83l4.59 4.58L18 14l-6-6-6 6 1.41 1.41z"},child:[]}]})(e)}function fv(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M256 112v288m144-144H112"},child:[]}]})(e)}function BW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeMiterlimit:"10",strokeWidth:"32",d:"M448 256c0-106-86-192-192-192S64 150 64 256s86 192 192 192 192-86 192-192z"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M250.26 166.05 256 288l5.73-121.95a5.74 5.74 0 0 0-5.79-6h0a5.74 5.74 0 0 0-5.68 6z"},child:[]},{tag:"path",attr:{d:"M256 367.91a20 20 0 1 1 20-20 20 20 0 0 1-20 20z"},child:[]}]})(e)}function RW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"48",d:"m112 268 144 144 144-144M256 392V100"},child:[]}]})(e)}function NW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"48",d:"m112 244 144-144 144 144M256 120v292"},child:[]}]})(e)}function Rm(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M416 128 192 384l-96-96"},child:[]}]})(e)}function yu(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"48",d:"m184 112 144 144-144 144"},child:[]}]})(e)}function Hd(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M368 368 144 144m224 0L144 368"},child:[]}]})(e)}function FW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M320 336h76c55 0 100-21.21 100-75.6s-53-73.47-96-75.6C391.11 99.74 329 48 256 48c-69 0-113.44 45.79-128 91.2-60 5.7-112 35.88-112 98.4S70 336 136 336h56m0 64.1 64 63.9 64-63.9M256 224v224.03"},child:[]}]})(e)}function PW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"rect",attr:{width:"336",height:"336",x:"128",y:"128",fill:"none",strokeLinejoin:"round",strokeWidth:"32",rx:"57",ry:"57"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"m383.5 128 .5-24a56.16 56.16 0 0 0-56-56H112a64.19 64.19 0 0 0-64 64v216a56.16 56.16 0 0 0 56 56h24"},child:[]}]})(e)}function Zf(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M448 341.37V170.61A32 32 0 0 0 432.11 143l-152-88.46a47.94 47.94 0 0 0-48.24 0L79.89 143A32 32 0 0 0 64 170.61v170.76A32 32 0 0 0 79.89 369l152 88.46a48 48 0 0 0 48.24 0l152-88.46A32 32 0 0 0 448 341.37z"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"m69 153.99 187 110 187-110m-187 310v-200"},child:[]}]})(e)}function zW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinejoin:"round",strokeWidth:"32",d:"M416 221.25V416a48 48 0 0 1-48 48H144a48 48 0 0 1-48-48V96a48 48 0 0 1 48-48h98.75a32 32 0 0 1 22.62 9.37l141.26 141.26a32 32 0 0 1 9.37 22.62z"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M256 56v120a32 32 0 0 0 32 32h120"},child:[]}]})(e)}function Nm(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinejoin:"round",strokeWidth:"32",d:"M416 221.25V416a48 48 0 0 1-48 48H144a48 48 0 0 1-48-48V96a48 48 0 0 1 48-48h98.75a32 32 0 0 1 22.62 9.37l141.26 141.26a32 32 0 0 1 9.37 22.62z"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M256 56v120a32 32 0 0 0 32 32h120m-232 80h160m-160 80h160"},child:[]}]})(e)}function LW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M255.66 112c-77.94 0-157.89 45.11-220.83 135.33a16 16 0 0 0-.27 17.77C82.92 340.8 161.8 400 255.66 400c92.84 0 173.34-59.38 221.79-135.25a16.14 16.14 0 0 0 0-17.47C428.89 172.28 347.8 112 255.66 112z"},child:[]},{tag:"circle",attr:{cx:"256",cy:"256",r:"80",fill:"none",strokeMiterlimit:"10",strokeWidth:"32"},child:[]}]})(e)}function H7(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M472 168H40a24 24 0 0 1 0-48h432a24 24 0 0 1 0 48zm-80 112H120a24 24 0 0 1 0-48h272a24 24 0 0 1 0 48zm-96 112h-80a24 24 0 0 1 0-48h80a24 24 0 0 1 0 48z"},child:[]}]})(e)}function w6(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M63.28 202a15.29 15.29 0 0 1-7.7-2 14.84 14.84 0 0 1-5.52-20.46C69.34 147.36 128 72.25 256 72.25c55.47 0 104.12 14.57 144.53 43.29 33.26 23.57 51.9 50.25 60.78 63.1a14.79 14.79 0 0 1-4 20.79 15.52 15.52 0 0 1-21.24
8-4C420 172.32 371 102 256 102c-112.25 0-163 64.71-179.53 92.46A15 15 0 0 1 63.28 202z"},child:[]},{tag:"path",attr:{d:"M320.49 496a15.31 15.31 0 0 1-3.79-.43c-92.85-23-127.52-115.82-128.93-119.68l-.22-.85c-.76-2.68-19.39-66.33 9.21-103.61 13.11-17 33.05-25.72 59.38-25.72 24.48 0 42.14 7.61 54.28 23.36 10 12.86 14 28.72 17.87 44 8.13 31.82 14 48.53 47.79 50.25 14.84.75 24.59-7.93 30.12-15.32 14.95-20.15 17.55-53 6.28-82C398 228.57 346.61 158 256 158c-38.68 0-74.22 12.43-102.72 35.79-23.59 19.35-42.28 46.67-51.28 74.75-16.69 52.28 5.2 134.46 5.41 135.21A14.83 14.83 0 0 1 96.54 422a15.39 15.39 0 0 1-18.74-10.6c-1-3.75-24.38-91.4-5.1-151.82 21-65.47 85.81-131.47 183.33-131.47 45.07 0 87.65 15.32 123.19 44.25 27.52 22.5 50 52.72 61.76 82.93 14.95 38.57 10.94 81.86-10.19 110.14-14.08 18.86-34.13 28.72-56.34 27.65-57.86-2.9-68.26-43.29-75.84-72.75-7.8-30.22-12.79-44.79-42.58-44.79-16.36 0-27.85 4.5-35 13.82-9.75 12.75-10.51 32.68-9.43 47.14a152.44 152.44 0 0 0 5.1 29.79c2.38 6 33.37 82 107.59 100.39a14.88 14.88 0 0 1 11 18.11 15.36 15.36 0 0 1-14.8 11.21z"},child:[]},{tag:"path",attr:{d:"M201.31 489.14a15.5 15.5 0 0 1-11.16-4.71c-37.16-39-58.18-82.61-66.09-137.14V347c-4.44-36.1 2.06-87.21 33.91-122.35 23.51-25.93 56.56-39.11 98.06-39.11 49.08 0 87.65 22.82 111.7 65.89 17.45 31.29 20.91 62.47 21 63.75a15.07 15.07 0 0 1-13.65 16.4 15.26 15.26 0 0 1-16.79-13.29A154 154 0 0 0 340.43 265c-18.64-32.89-47-49.61-84.51-49.61-32.4 0-57.75 9.75-75.19 29-25.14 27.75-30 70.5-26.55 98.78 6.93 48.22 25.46 86.58 58.18 120.86a14.7 14.7 0 0 1-.76 21.11 15.44 15.44 0 0 1-10.29 4z"},child:[]},{tag:"path",attr:{d:"M372.5 446.18c-32.5 0-60.13-9-82.24-26.89-44.42-35.79-49.4-94.08-49.62-96.54a15.27 15.27 0 0 1 30.45-2.36c.11.86 4.55 48.54 38.79 76 20.26 16.18 47.34 22.6 80.71 18.85a15.2 15.2 0 0 1 16.91 13.18 14.92 14.92 0 0 1-13.44 16.5 187 187 0 0 1-21.56 1.26zm25.68-397.39C385.5 40.54 340.54 16 256 16c-88.74 0-133.81 27.11-143.78 34a11.59 11.59 0 0 0-1.84 1.4.36.36 0 0 1-.22.1 14.87 14.87 0 0 0-5.09 11.15 15.06 15.06 0 0 0 15.31 14.85 15.56 15.56 0 0 0 8.88-2.79c.43-.32 39.22-28.82 126.77-28.82S382.58 74.29 383 74.5a15.25 15.25 0 0 0 9.21 3 15.06 15.06 0 0 0 15.29-14.89 14.9 14.9 0 0 0-9.32-13.82z"},child:[]}]})(e)}function W7(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeMiterlimit:"10",strokeWidth:"32",d:"M248 64C146.39 64 64 146.39 64 248s82.39 184 184 184 184-82.39 184-184S349.61 64 248 64z"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M220 220h32v116"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeMiterlimit:"10",strokeWidth:"32",d:"M208 340h88"},child:[]},{tag:"path",attr:{d:"M248 130a26 26 0 1 0 26 26 26 26 0 0 0-26-26z"},child:[]}]})(e)}function hv(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"m434.8 137.65-149.36-68.1c-16.19-7.4-42.69-7.4-58.88 0L77.3 137.65c-17.6 8-17.6 21.09 0 29.09l148 67.5c16.89 7.7 44.69 7.7 61.58 0l148-67.5c17.52-8 17.52-21.1-.08-29.09zM160 308.52l-82.7 37.11c-17.6 8-17.6 21.1 0 29.1l148 67.5c16.89 7.69 44.69 7.69 61.58 0l148-67.5c17.6-8 17.6-21.1 0-29.1l-79.94-38.47"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"m160 204.48-82.8 37.16c-17.6 8-17.6 21.1 0 29.1l148 67.49c16.89 7.7 44.69 7.7 61.58 0l148-67.49c17.7-8 17.7-21.1.1-29.1L352 204.48"},child:[]}]})(e)}function DW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M321.89 171.42C233 114 141 155.22 56 65.22c-19.8-21-8.3 235.5 98.1 332.7 77.79 71 197.9 63.08 238.4-5.92s18.28-163.17-70.61-220.58zM173 253c86 81 175 129 292 147"},child:[]}]})(e)}function UW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"36",d:"M208 352h-64a96 96 0 0 1 0-192h64m96 0h64a96 96 0 0 1 0 192h-64m-14
80.71-96h187.42"},child:[]}]})(e)}function qW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeMiterlimit:"10",strokeWidth:"32",d:"M80 160h352M80 256h352M80 352h352"},child:[]}]})(e)}function x6(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M364.13 125.25 87 403l-23 45 44.99-23 277.76-277.13-22.62-22.62zm56.56-56.56-22.62 22.62 22.62 22.63 22.62-22.63a16 16 0 0 0 0-22.62h0a16 16 0 0 0-22.62 0z"},child:[]}]})(e)}function dv(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M435.25 48h-122.9a14.46 14.46 0 0 0-10.2 4.2L56.45 297.9a28.85 28.85 0 0 0 0 40.7l117 117a28.85 28.85 0 0 0 40.7 0L459.75 210a14.46 14.46 0 0 0 4.2-10.2v-123a28.66 28.66 0 0 0-28.7-28.8z"},child:[]},{tag:"path",attr:{d:"M384 160a32 32 0 1 1 32-32 32 32 0 0 1-32 32z"},child:[]}]})(e)}function VW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M432 272a48.09 48.09 0 0 0-45.25 32h-39.22l-28.35-85.06a16 16 0 0 0-30.56.66l-44.51 155.76-52.33-314a16 16 0 0 0-31.3-1.25L99.51 304H48a16 16 0 0 0 0 32h64a16 16 0 0 0 15.52-12.12l45.34-181.37 51.36 308.12A16 16 0 0 0 239.1 464h.91a16 16 0 0 0 15.37-11.6l49.8-174.28 15.64 46.94A16 16 0 0 0 336 336h50.75A48 48 0 1 0 432 272z"},child:[]}]})(e)}function ZW(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinejoin:"round",strokeWidth:"32",d:"M160 336V48l32 16 32-16 31.94 16 32.37-16L320 64l31.79-16 31.93 16L416 48l32.01 16L480 48v224"},child:[]},{tag:"path",attr:{fill:"none",strokeLinejoin:"round",strokeWidth:"32",d:"M480 272v112a80 80 0 0 1-80 80 80 80 0 0 1-80-80v-48H48a15.86 15.86 0 0 0-16 16c0 64 6.74 112 80 112h288"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M224 144h192m-128 80h128"},child:[]}]})(e)}function K7(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"rect",attr:{width:"416",height:"416",x:"48",y:"48",fill:"none",strokeLinejoin:"round",strokeWidth:"32",rx:"96"},child:[]},{tag:"path",attr:{fill:"none",strokeLinejoin:"round",strokeWidth:"32",d:"M388.94 151.56c-24.46-22.28-68.72-51.4-132.94-51.4s-108.48 29.12-132.94 51.4a34.66 34.66 0 0 0-3.06 48.08l33.32 39.21a26.07 26.07 0 0 0 33.6 5.21c15.92-9.83 40.91-21.64 69.1-21.64s53.18 11.81 69.1 21.64a26.07 26.07 0 0 0 33.6-5.21L392 199.64a34.66 34.66 0 0 0-3.06-48.08z"},child:[]}]})(e)}function pv(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M456.69 421.39 362.6 327.3a173.81 173.81 0 0 0 34.84-104.58C397.44 126.38 319.06 48 222.72 48S48 126.38 48 222.72s78.38 174.72 174.72 174.72A173.81 173.81 0 0 0 327.3 362.6l94.09 94.09a25 25 0 0 0 35.3-35.3zM97.92 222.72a124.8 124.8 0 1 1 124.8 124.8 124.95 124.95 0 0 1-124.8-124.8z"},child:[]}]})(e)}function G7(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M262.29 192.31a64 64 0 1 0 57.4 57.4 64.13 64.13 0 0 0-57.4-57.4zM416.39 256a154.34 154.34 0 0 1-1.53 20.79l45.21 35.46a10.81 10.81 0 0 1 2.45 13.75l-42.77 74a10.81 10.81 0 0 1-13.14 4.59l-44.9-18.08a16.11 16.11 0 0 0-15.17 1.75A164.48 164.48 0 0 1 325 400.8a15.94 15.94 0 0 0-8.82 12.14l-6.73 47.89a11.08 11.08 0 0 1-10.68 9.17h-85.54a11.11 11.11 0 0 1-10.69-8.87l-6.72-47.82a16.07 16.07 0 0 0-9-12.22 155.3 155.3 0 0 1-21.46-12.57 16 16 0 0 0-15.11-1.71l-44.89 18.07a10.81 10.81 0 0 1-13.14-4.58l-42.77-74a10.8 10.8 0 0 1 2.45-13.75l38.21-30a16.05 16.05 0 0 0 6-14.08c-.36-4.17-.58-8.33-.58-12.5s.21-8.27.58-12.35a16 16 0 0 0-6.07-13.94l-38.19-30A10.81 10.81 0 0 1 49.48 186l42.77-74a10.81 10.81 0 0 1 13.14-4.59l44.9 18.08a16.11 16.11 0 0 0 15.17-1.75A164.48 164.48 0 0 1 187 111.2a15.94 15.94 0 0 0 8.82-12.14l6.73-47.89A11.08 11.08 0 0 1 213.23 42h85.54a11.11 11.11 0 0 1 10.69 8.87l6.72 47.82a16.07 16.07 0 0 0 9 12.22 155.3 155.3 0 0 1 21.46 12.57 16 16 0 0 0 15.11 1.71l44.89-18.07a10.81 10.81 0 0 1 13.14 4.58l42.77 74a10.8 10.8 0 0 1-2.45 13.75l-38.21 30a16.05 16.05 0 0 0-6.05 14.08c.33 4.14.55 8.3.55 12.47z"},child:[]}]})(e)}function Wd(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"m304 48 112 112-112 112m94.87-112H96m112 304L96 352l112-112m-94 112h302"},child:[]}]})(e)}function Fm(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M256 48C141.13 48 48 141.13 48 256s93.13 208 208 208 208-93.13 208-208S370.87 48 256 48zm96 240h-96a16 16 0 0 1-16-16V128a16 16 0 0 1 32 0v128h80a16 16 0 0 1 0 32z"}
8,child:[]}]})(e)}function mv(e){return dr({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"m112 112 20 320c.95 18.49 14.4 32 32 32h184c17.67 0 30.87-13.51 32-32l20-320"},child:[]},{tag:"path",attr:{strokeLinecap:"round",strokeMiterlimit:"10",strokeWidth:"32",d:"M80 112h352"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M192 112V72h0a23.93 23.93 0 0 1 24-24h80a23.93 23.93 0 0 1 24 24h0v40m-64 64v224m-72-224 8 224m136-224-8 224"},child:[]}]})(e)}function $W(e){return dr({tag:"svg",attr:{viewBox:"0 0 24 24",fill:"none"},child:[{tag:"path",attr:{opacity:"0.2",fillRule:"evenodd",clipRule:"evenodd",d:"M12 19C15.866 19 19 15.866 19 12C19 8.13401 15.866 5 12 5C8.13401 5 5 8.13401 5 12C5 15.866 8.13401 19 12 19ZM12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22Z",fill:"currentColor"},child:[]},{tag:"path",attr:{d:"M2 12C2 6.47715 6.47715 2 12 2V5C8.13401 5 5 8.13401 5 12H2Z",fill:"currentColor"},child:[]}]})(e)}const _6="data:image/webp;base64,UklGRhAPAABXRUJQVlA4WAoAAAAwAAAAdwAAdwAASUNDUMgBAAAAAAHIAAAAAAQwAABtbnRyUkdCIFhZWiAH4AABAAEAAAAAAABhY3NwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAA9tYAAQAAAADTLQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAlkZXNjAAAA8AAAACRyWFlaAAABFAAAABRnWFlaAAABKAAAABRiWFlaAAABPAAAABR3dHB0AAABUAAAABRyVFJDAAABZAAAAChnVFJDAAABZAAAAChiVFJDAAABZAAAAChjcHJ0AAABjAAAADxtbHVjAAAAAAAAAAEAAAAMZW5VUwAAAAgAAAAcAHMAUgBHAEJYWVogAAAAAAAAb6IAADj1AAADkFhZWiAAAAAAAABimQAAt4UAABjaWFlaIAAAAAAAACSgAAAPhAAAts9YWVogAAAAAAAA9tYAAQAAAADTLXBhcmEAAAAAAAQAAAACZmYAAPKnAAANWQAAE9AAAApbAAAAAAAAAABtbHVjAAAAAAAAAAEAAAAMZW5VUwAAACAAAAAcAEcAbwBvAGcAbABlACAASQBuAGMALgAgADIAMAAxADZWUDhMIg0AAC93wB0QV+MwkiSnmcFe2ETtzQJSEI4kSWqjbCQG3fTl/bO3ICAo8n80gmxb3BN8P3CYLscJL3EwYjvgKjq8xE6LOWrRQZ5p10YLl5/LWlyNFjdnGg15/kZDfocGNPI3+R0aZJqcEBIhgoZkSSSIBOYhIqE6BDEOREIVBJFQhRgHVXyJv0qCGAuRIKqToCEJgjAWogaEKsiQnxJEFQkaAgsCAEluo2ALHJS9nMs2xkHEe4yNVrZEKmF2kAWDdqJdZG/QHrkkjEEmR9f/H1Dd1VXVPX5ARP8dSpJUNRZEg0gQuL0Hmx9ARERERERERERERERERERERERERERERETEje72/sOi3x8CAED/qDjce9DdQERERERERERERERERERERERERERERMQW7nUfHPYBoKzqppnN5/P5vJnWE/Yrhw+6me61Mb4PiuFjqJrFcu2cc84555xzzjm3Xi2mE4Dh4XbnJpYAVLPlW+ecc8455/Sqb5fNGKCgghs1rb3h43+cr21v+UHpxdViDNDr3pirAsrZyjnnnHPOOeecU5rVCpoxHG3fhKvf9p+MF3xa8xW8GkN/+wbUqKP6SW1evljMmqau62kzmy9Xb9lFq810Chi/TK27mk0rYCI9qeu6rr4JnThrXs7H0GtvZd8dludp7awuagCYBImWuvfuajWfjgHOxnCy21ppzUTnvW1Glz/NSoD6fCUMiCpQNUOxTjuly/AmBmx6MTsr2Yw2L97Go2Hs4PkY4ORednza96WW4f2lKQFG4aqmkkwCBfuZqx3BDwIiCcuoLmH0cPuzAoTlFj6SRTlvrVv9cqXXvyhhdNAN4GVc5AnNNDnTx8PxWu31rISiGwk0H96c6FWefJwpfwqTtVoDRgedsNhCDaN2SCwcw6eZ8t/eKmtmUcLBr9jww3dqO1KTiWlCKc/1W3kAr2ooOhGMXDnnnHPOOacoigwA7lP6E1LmpU8Hn7BhGJX/yveeEmaK6ePUXx2O38ozU8OjjQAjf/Qwkiww69Vqdbm2X45PtpLyr/v0QzLKVqN7XJ4hKrUiZ6STgOmi6WJl61yZ9qP9ci3Ozsty0GHVhuOVffxeNCWMioPtTzY3N3Bjs/vJ3uEIqsbyMz/CUYKxuw9LUR7/Ccesh7u+mln51n+BYmfLYCw8GoDlYkpQbVdBj38Q+zeHR0xDfAHf8SsTchY75rG78zXMrtV+lnDP2sKfa0ls383hgGsIakOXDqYkpjDaS/MS9qBaezxRBvDEWEdpIc59mxYOYDLYSfZNtgblpdbbMRRq//jyeSmN5ILu8jy+MrXzPQzuZFGmISkYBKai3wwbcRzhOMpa+xFes3YypbV221TUK8MyiIS8ol+Nsu2pXvD+cqWKGlNuU5EucyC2WI/krM7RIM0wNrzNTAEtKB939WfE4aDpl7OG1weZXd0D8HXEgTwba6dtekYcjV7Ai355ZTCYy9En2e3D01r7uoCu/cwrfcExU+vtsdUeToSPNTcMIjn5ue5rZ8FyeA53gjSzdaYATsOr5T9dyENWzlby6Sic4xZ7AappeetgcQZ7sduR+XapKIeJo9vScqf74mh2gvqvucEgDgN8JnqUeRtZKUvk2t8WMGMsP+Nb8K1TO/6umEe3WvPuTp+L4/YCLt+WvRhW4Ft6NfncA966kttzZj//VkGOn93sZCOqTcItnn0/qFJSbuHhSl6d8NytYu1QSN9n0MFOf6K2lj+rkKQ8OHeuLqLvzyXM+BKx942Kj2dgyjmdLY8cIig1zs2fbkTfY7X7Bj7BbTIwNO/j+9Z+KF61/OAo5A+/iPzXgIhjSawHQR2o6OjxouWDmpI1Q+M+uKpgAtZIq62H+6CVLcngsSPC3l63jaMOM3cSAEVSAG+g24HY7BBMAPNyKXgAo4WP8H4Bsu7DtYCRA+yN/6u1QKa7wX2LbHkep7qXoVitEuYz9PaLidSZP3ikVit5A85oBE7fshUxhd10gPbjyVUbP2Jx7U/9y0Xa8Y6HEMUwoUrm/Czu2jmldA9T1i8wZxPax40nAmq8ggfsLJsAFo0bK+d86f6E9IuMk9xK2+g+WQkgeRKf/ciwbpHXasxPQqa3kFKiAg6WjjCVJDyR4Nyn5Sas8QE7yyaA+VpFFnOK0D/MqCCphI183WzvgYTZMGbmriBW1KI1x5O1znMp2Gls5mhx81c8oCelOSfMUJ4hgLRmYRoqMSU8SW0pdk60YB8WwrSv4DGDSAlFrFlSyqdystccKzA09eomLKWvjqbSUStnA2QEe4+cYdEW2PIpVtwEXOY7fu60J3lT/UawfUJt4TF/tmEejY4fKMEECSkSumewZURJdkcYUsLq+CAAEeazvNbOJheZoj2a5RMu44jNkdHaCGasZM4E4QkjNjvhB4dO833Z3pUNLi15g9z43UcRRS0oeIZ0xGPvZ0IEcBtmkKzLd/VEYpegBMMaYHO3EI/QGTb24buE1SbMIIyJIp0+CiboYQremg7RMpdfhgxX8UMYe8WhKKy2v5SkHBsmuq8YHIAL5WXGErSezmLRmoutvCW9axRG8t95x0KKc2TskmFiqk1gJYsIeeHSQQ0JoqVYVYoCFBaRt8WkS54lR8Mkd0xE4uX6Gn520WPPPG7Eb648XVjRZ4eGSky3huP/hfXPYwTGs+Lt05AKM31M+ByqhDuKwr+X4EdfSMlfi8au5f6fVD0TH8FleOTdlyCVZSOq8v940MuSpGxVXU+5nhFWAEmqoB++JL84RmxZPXsDN0tKzWQS6+eAmZGs/87PfVRTxlG6kyWxCYo9ChNmUDxICwT3oyXEPBVvtkcGiLzyyEfIlpScECLiwBugQsBysicjC0+tmZzCIiTAj7JRAfbPnIaRO3wAInvSyzbrtaKvgmpJvkx120LMYP1eGcLCu/ei/4dfVGyRV8rS28oQlppeMzFoWDYZJhS2Vm3OTo9eTXqS+UfM4FKs3E3J67EDV/XSuVVljKGHgNBU3dboxaDJ/SPmD74PcKWYIxs53Lyvgz84sEUCooAQwwwJvTW/0/u/fnkbjjwO9Sd2/5cHhHSTuAfXhIfR259w5SYdJBr8IyfPx+5R6H5W7P/F7iDdYJ5K83etuMUcgoxxbFP2Zj+m76LfyRZBEMZnlQR94bFW88dk7LIS734KQTEWRRFQI1LVQRXONNxohW4iGVyTt8Hh1QLLHVLc8fphYRX+dRUcJgUn28ziZnkoZDEDBl/i9zhGPHMvNPfpyxuQqTAWSooZRDrRYBE9Kq+vNHfxJEe2hlsCNcAQEJLO3DKX7NPnsd4XbP+2fihQA9QgI+3NaOfX0TtF0FEpgFr+Pj9eRDunEgEgCjKSVc1MAPF8rBjk38oOlI8Rt7KV0As7p6YgYwh5SnpYscwHta8oI1ZqUNKo6E2b4i9DHEoLeZJ5r3kgC+qtYuvSKTuPSNgU17YZ+TPyWfVAJvU7uas5CT18d9pvihuy36fX92bIm9FdLm/dKrch7z5gX2RZeIdX2t1kezPvxXV2W3e5ILYSY/+d+DzZGWIxYBg2VWWzw9DpU6A4g/fNFeZDpqd2hwKlROFgUPSLbYmRCSCaHbTRarKYmJ0ZqzC+LPJcgYUrxDvNWiAxEW1ZLp2Gokrvc38rxxXjaui/GlM/9qkFQwzdUkThBwODaTf6UaM3vDss+ZVh59RTP+KsbGebbdNS51zMPPPTztQVmWc6KHtWD
87+rEEIoNp+wOz218dSIaGuQ190CysZAnomiPX7nlI2ITNJjGyQJy+SYfCkTQ24Mw2Lvo+7m5ubm5tbHDx4eDaGamYmTwZanTfGI+vFKsdwphp7CR/LMByKtWViYnlYd+EackDqdvXjLZe2DrZrfFOd4TdQPHUUsS1SMgml1PJII0ebVv6+IkJrEwmLVntKmONOJHsK0LcZOqhMAZ9dJL0SGYmK+8MQDZsp6nahulkuEBDOTKDml8XTP4IuNmIrnIVfMYYsxR1orDMnEYZdZO4FSwtiOHK/VnCXZWDkSdJvZWJy109nX8JrJs99QzeTonZYpbOsEDtgXnYgKbzBkiWySkc+jon3qsP//grFYu/vDgJwGjkvwkXOmyuuITAWrwJ39bPvhEEpPhbdxXHITenwgIak0iue85bzuYUTDzsIjyhDAOAWBj5hAYqw583sye7G2AcuyJP5lvD+etRbjdS8u7UT+GqA6f7G8iqDTUhqYtS0xL06hqgHKer68fCtz6hdNFbpzHni6aQJ9rz1KwCP463zZcF1UVXV9VlW8D9MF6cFUtnXlS1v9v8aA/djVcjFvmmbaNM184WfUriMkKjzRw9P+HZMHNcOFwOtOlmgOI4sqIuG1fnEMVXMpFCTzzBmMtPZPIAvRFqAigcqhm9YXNYzU/x+1TTq5UwQYSf2/1ayCxzFT92YVHI44rXptQAgu0SNfcmP/T7dzGFDsyVk9bdjf6cLfjqqS/Z9uJ/f/6Vr5/+DO3mFx3GcAMur3i4cH2238fxAB",HW="data:image/webp;base64,UklGRsQOAABXRUJQVlA4WAoAAAAwAAAA/wAANgAASUNDUMgBAAAAAAHIAAAAAAQwAABtbnRyUkdCIFhZWiAH4AABAAEAAAAAAABhY3NwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAA9tYAAQAAAADTLQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAlkZXNjAAAA8AAAACRyWFlaAAABFAAAABRnWFlaAAABKAAAABRiWFlaAAABPAAAABR3dHB0AAABUAAAABRyVFJDAAABZAAAAChnVFJDAAABZAAAAChiVFJDAAABZAAAAChjcHJ0AAABjAAAADxtbHVjAAAAAAAAAAEAAAAMZW5VUwAAAAgAAAAcAHMAUgBHAEJYWVogAAAAAAAAb6IAADj1AAADkFhZWiAAAAAAAABimQAAt4UAABjaWFlaIAAAAAAAACSgAAAPhAAAts9YWVogAAAAAAAA9tYAAQAAAADTLXBhcmEAAAAAAAQAAAACZmYAAPKnAAANWQAAE9AAAApbAAAAAAAAAABtbHVjAAAAAAAAAAEAAAAMZW5VUwAAACAAAAAcAEcAbwBvAGcAbABlACAASQBuAGMALgAgADIAMAAxADZWUDhM1gwAAC//gA0QZwe52vbEyvvlSv4kM4O70wAtUgJF0ABs3d12zp5DAS4jtwk4kiSpdqrn/7czC1/Mkse31QV0BtnoMXjMZH5baBpI2ya7f80vQbYt7gn2Oixvdv7dw1fg4Svgy+ng33/7tGFuCfq8fHobJmZ5HWpoGgdvQ/vu0YIWDE7QgsFJWnD3pMVlHl+sBX9GCwZH+DNa0D8ChoPHDw2M0d/A6G9g3FxZ3wgY/Q0H/0b/CA4wisb+iTCKRjEAoygPTv8oR5c2PY+DrIFRFBz8Gxhnl0LkBUTWyCt5BSPPYOSZ9QObmAWRF/LK9bVSASMrZIWUQWSFrIK4vbWlDTYOCyYVEDFAjE6AiAEiOYjSEKQcGEQMMHaO7f1XCAscWCAoLTDJiYXolEIQc2BiBrG246UQBMcCQSkEFggQ5jiwIAQChDmCUggsAiMoRXAEIVjddgsGRzEHIShFSAh8MDAKQhASpRD4QATGHIFlgrOy5eaYg7AEwjwwAp9AgTHHHBGYUlgHQgSmFAKfEJRC4BM9wDsC74jAICyB8I7AEgiEdZRCBAb2t/9W3LgZZ1ptO5sNK8zMkcPMzMwM9gYnzMycpTCMWynMid0wg6SAwyBvlE7tXs3C+f4Rc8+5R9cQ69eI/kOQJDdusyXGog5qCQIgeOQDAAAAAAAAAFBYbd+rZj5Xq34+Z/qxq0UAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA/K5E2z7/fZoRERERZekvzx1b7KRnxd7vlXvKrbkz1ws75Nm0GUNcnnr1m1r1s2r9l8E563XCs7D3O+2eGf6lWvul+X/nK9X37y50vqsvGudeWn/hmQ/qqX1JbYe5
8H3W6i+t9LQU874ee1Ve51xbp8Y3vjw06WvpZCveHnijq/Z6IiLQTVx+vCTpYmisk2+yJgm2+1p9o91J+dKz0o7j6zSoIZ+j+ZrgxWKvVf1GojJzVqUqT6dkISzyvhVzNF/YvFgKOQ5ed/kNLkvl128701ZnCqB4Isd5X9kxxQHo0OmNY8vmkI8XhB4ivzgxt0dpZW/kGxw3LAp4OOlCsLaT9zRSb3A7mAdautseV8uYHk8AlH5FE0fhawwwW59xNtPTtLoGfddYEqfrHcgziOWCN43jNv6TiGPPEuLIe4ofus4U5j728tC/BI1oyKN1vFFU4iIj6RqceY2Sz/4zjOI7jOI7jOD63a0wkR5SM+28tDJ93YouZU/xH5D+JZqnVRiG9CrdLNBr1aFghjokY28R6EwijkCYLez/MyEcd8jujMatXBLNquol/FQzVibb2p13KhTge+O/Ex36GaEGtsF4q784c1QzDbEHtC3rAm9fBRGulo8nuNZYol0qlUqlUKpVKwYTHLJblNX+ryWZ+ecqoKE6Xf6he8M//EV5Mxj97zFjiMtVzTnRMqbNxr+JcG1xFM6Lea4o+mE/0Gf1vFf/8GViDaB8v97lcuOZOFTJxfEG8g+jENr6k3Bi445QVXJ+85qlJpZxcct7O4dihK9ChOHeXjkrEJdC+1ZnIqin3pbsMyYd2UTgt8XXmEWSfQ8JFU7avf355BCm95uU+uiOFwoUAlnzXDfBuDUQzPKmE+1F7bBfH5znO4KQ4PjEIzo/PXSQ6byBN+w8tKJCi3ehfzTQtHyhpHhKfV1j8kmaasjSXv+SPNH3rcEl0nTjeLDxnIE1vxi7cmT4/Q9b5AbfNbAwigpF2XexLDvIb/vkAuIQymV0sSZIkSZLkdUNm+SlJ0iTDNE4EwiHKXj+0tPUpQ46bfpTI3HboIYcccsghBR2iTd4iul0IZAMiswLClP7cIXU6yR10LNrvtF25IOVgrjNsVSGC8zOH6IbSA9BDouU3R4+IJYfktWl6koeuwYPOZar5pWmcB2f3bkfoIqJT8w/YFrGXFQ09mWXKMuwXPTKNTNXdyB1RFEVRZAMVVhlD2Y7yA3SQ4JoaHhKnLNRbHbDdjxDRcMrjg5GCQJZRNpxehKCPKBu4/c6UKNtJImOKc8O8L2Hl/6A1n9vkQLfmK/3IrTCrxYcq2FQMvQeJ6l3eeW4dK0qFj9AWQ33CEC5TULa64LbJSBdwqBVoGzeaGWOMMSYPYmSHRWZx/L1M1BcwWEZ7dyFY7EmWo4uwTDRS6kJh12GicmCjINbAtboKIQ5kRkz55BaZqRaSeVcB+JQVsyZ/Q9eBfs0slg7FsYrWQ7eEKjaJBv1efGsh52W2nTc2eWemwWkapS8yXcAdtrPyizssHcHzSaL+8CJhQRJmc4c2c5GwwhXKywo6bC1KoBIK7R4ms45C9A5+TyFSZVFKKz7drfjVIgHieEnxRQ/JOy2iRuSVb+V5QWBTNcvawEJSIPu64bzyrk0KLk1KAxUL6b1KpVKpVCplWcFCStRvuAIOHnZdQT8t3FtAiJkr6CjqmyqRPYgucom+bduS8aRDhJ//UvqYxdyKP8BzMCEQXGOI8ijbFUfTedIPbDvZtsJVFG22zUOnCApWuyxcVXyyWCwWi8sfbHIBCD1stAkjFrQvaG2r8uy9XKzjEuomul3ANqYwZoeaNef8MhuAtAQ6oVgsiqreQrQu42CH4mfsSYVAH1JqufovIgAVyRygjE/kOGCQldJrWD5E5DiLzGaVh7L8IVcaiQbNst5dzIqpDTzjjnPZh4RSqH8SLaZq+38kovl5c2s+wFY9f8215n+3mz09JId9zmE4m+anPwk6B2i1zMMQPkTKu2JleCp/fyO+7BP75a5br5r20EgeyHvhXdkl375n7kk84ePU2Zc6fywUr9aihgOiskLzDcr+oaGy0Auaj8mnVYVCLasPsfkwYhSm/EpH+H7KiuozGDiV6PxDDhGRw8kt6g/Uh3RIOqZtnPybjVhGiZXt+pftqxXw5IaMoIjukCgY67yUjC1Uw2NEVxSLRfdmJKBNJtSFGfyS61LbQyQlEnF+z2oRLXzeJ9/MrV7h+CplsgO4legwaLB9rEvyLZe1NAz7mgfahl4/tMis6eISl1Gf9SACQtc2tdbuBGgVaNiT8ljYrcGaVrwaRNztlMq6pN78hRbapE86ifH59VxSjweWs65dIbG1rZbykAorXVfOI5rnknLYwg+qdN8KLyV6VyloqVzAsma2LgJCuu/IWk5pEh0o4dp5lgeoTg8+crOENu3Ar/jEkpvU6j2BolYzMkku4q+M8MSDR2y5ghZqpPRWwIGo1UXdNNnbu4pwvs56aoveLejoKy7jWkkAbM/xtoy/RdzFVef4uXCysYqtxF3vEL21QoBg/Xc44JBQvLY5OASi27kGEq5En/eBM05Tg8vj2TQXktmvmLKJ2jfbGoaTV3rYbHkEZaJXlXEnh0MtyirxwYvKOKJy8pbd3d3d3csz0UuJzEVbCR6sRnZ8q807iXh7V+ZtFuRRpnQqhqiZlK0MrGJLMC92Ts2BZibCVAlHLH3cVAONjCg72sm4MuppOfOpwaiWpZpSCPeFovgHPYitqOTd0Otcqx/6uFMoZ0tQ4DjCLdSamBSMxrD9vFvI8bYQyu4sUDHuONLhnV2at7YDro27a+KdvJk1yHq5gWyeNMjh4U/uIx5JHYVJ17SYnKP1mXg9KkncvBxGJzcF4aNJkrhjz7Vk81zEFASzY+5spH82BpKLNpZKvs7tjbTZGLj9tMWw2FMOWf7AI11HJsnjoSR3U5LcEDC6ViwPZya9fHl3hHsuZG2Gho0Z2FPSPD95IjcQpYMqp8akl8j+YLckyRVZyToFreKftrVL0nJq3k5OsoX+1Xdg5BD9dyGKfEZ/TEcsFY6OUXsHO5jHXaIz8Z4t753rqOyVIvaab87GZICJtWrzrI27/YJp2YfNsKN5JwbJ70t+kzo8fz5oCR+Wzzr5tMl6dhMCdwMiBMsDcf7KCZgUMMGW7e75Idcs7pgOEIe+2uxuQhBp26ZcoZkcMNG2Wtp5J3Hkay56cxTPFrvwnDV5dyoyX3SZLDDBLtUd8db2i5wr07Z7XsQNznacwH5HMMu98ySBCVeXY1Nle131xunTr32k7my9ldtxdkHY23RW5SaDVXYOxse7Ll6bCozXNquFMvKbGWGl541cletU+295ik3uq3F3G+pXg6j3Z2dJ2m4/7lzHmT/o72v7bxZb70q7CVPenXR2X0+4wj4car/PsvrBXfcr+2+Hejre5vNl7/nQulvXATdq1cGG+g8I1VU64cbzIz6pV2u1zz6rfVat58N3W6S6C4//86AjntS0aGNB+z2IHfJkkxnC0yhzP8O/vLBL5/rfI+8B+urHXletD/7eGByszTp+k475j1ft92TwElq+h6PzyRc=",S6="/assets/AEX-LOGO-GRADIENT-DARK-120x120-BSD8m6uP.webp",WW="/assets/AEX-LOGOTEXT-GRADIENT-DARK-256x55-DMmKBBiy.webp",ro={MAINNET:"mainnet",DEVNET:"devnet",TESTNET:"testnet"},Y7="aztec_explorer_network",X7=e=>e&&Object.values(ro).includes(e),J7=()=>{const e=new URLSearchParams(window.location.search).get("network");return X7(e)?e:null},KW=()=>{try{const e=localStorage.getItem(Y7);if(X7(e))return e}catch(e){console.error("Error accessing localStorage:",e)}return ro.MAINNET},GW=()=>J7()||KW(),Q7=he.createContext(),YW=({children:e})=>{const[t,r]=he.useState(GW());he.useEffect(()=>{if(J7()!==t){const i=new URLSearchParams(window.location.search);i.set("network",t);const a=`${window.location.pathname}?${i.toString()}${window.location.hash}`;window.history.replaceState(null,"",a)}},[t]);const n=i=>{try{localStorage.setItem(Y7,i),r(i)}catch(a){console.error("Error saving network preference:",a),r(i)}};return M.jsx(Q7.Provider,{value:{network:t,setNetwork:n},children:e})},di=()=>{const e=he.useContext(Q7);if(!e)throw new Error("useNetwork must be used within a NetworkProvider");return e},ti=({to:e,children:t,...r})=>{const{network:n}=di();if(typeof e=="string"){const[i,a]=e.split("?"),s=new URLSearchParams(a||"");s.set("network",n);const o=`${i}?${s.toString()}`;return M.jsx(v6,{to:o,...r,children:t})}if(e&&typeof e=="object"){const i=new URLSearchParams(e.search||"");i.set("network",n);const a={...e,search:`?${i.toString()}`};return M.jsx(v6,{to:a,...r,children:t})}return M.jsx(v6,{to:e||"/",...r,children:t})},XW=()=>{const e=new Date().getFullYear(),t=[{label:"Contact Us",href:"#",disabled:!0},{label:"Brand Kit",href:"#",disabled:!0},{label:"Bug Report",href:"#",disabled:!0}],r=[{label:"Discord",href:"#",disabled:!0},{label:"X (Twitter)",href:"#",disabled:!0},{label:"GitHub",href:"#",disabled:!0}];return M.jsx("footer",{className:"bg-surface-main  w-full flex items-center justify-center",children:M.jsxs("div",{className:" w-full py-12",children:[M.jsxs("div",{className:"flex justify-between items-center mb-5 pb-10 border-b border-surface-border below-mobile:flex-col below-mobile:items-center below-mobile:gap-8",children:[M.jsxs(ti,{to:"/",className:"flex items-center gap-3",children:[M.jsx("img",{src:WW,alt:"Aztec Explorer",className:"min-h-[40px] max-h-[40px] hidden dark:block"}),M.jsx("img",{src:HW,alt:"Aztec Explorer",className:"min-h-[40px] max-h-[40px] block dark:hidden"})]}),M.jsxs("div",{className:"flex gap-16 text-xs below-mobile:gap-10 below-mobile:justify-center",children:[M.jsxs("div",{className:"flex flex-col gap-3",children:[M.jsx("h3",{className:"text-text-primary font-medium underline",children:"About Us"}),t.map(n=>M.jsx("a",{href:n.href,className:`text-text-muted transition-colors hover:text-brand-purple ${n.disabled?"cursor-not-allowed":""}`,children:n.label},n.label))]}),M.jsxs("div",{className:"flex flex-col gap-3",children:[M.jsx("h3",{className:"text-text-primary font-medium underline",children:"Socials"}),r.map(n=>M.jsx("a",{href:n.href,className:`text-text-muted transition-colors hover:text-brand-purple ${n.disabled?"cursor-not-allowed":""}`,children:n.label},n.label))]})]})]}),M.jsxs("div",{className:"flex justify-between items-center text-text-muted text-xs below-mobile:flex-col below-mobile:gap-2",children:[M.jsxs("p",{children:["\xA9 ",e," Pioneer Labs."]}),M.jsx("p",{children:"Version 2.4.0-alpha"})]})]})})},JW=globalThis||void 0||self;
8function QW(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var eC={exports:{}},On=eC.exports={},Jo,Qo;function k6(){throw new Error("setTimeout has not been defined")}function E6(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?Jo=setTimeout:Jo=k6}catch{Jo=k6}try{typeof clearTimeout=="function"?Qo=clearTimeout:Qo=E6}catch{Qo=E6}})();function tC(e){if(Jo===setTimeout)return setTimeout(e,0);if((Jo===k6||!Jo)&&setTimeout)return Jo=setTimeout,setTimeout(e,0);try{return Jo(e,0)}catch{try{return Jo.call(null,e,0)}catch{return Jo.call(this,e,0)}}}function eK(e){if(Qo===clearTimeout)return clearTimeout(e);if((Qo===E6||!Qo)&&clearTimeout)return Qo=clearTimeout,clearTimeout(e);try{return Qo(e)}catch{try{return Qo.call(null,e)}catch{return Qo.call(this,e)}}}var rc=[],Kd=!1,$f,gv=-1;function tK(){!Kd||!$f||(Kd=!1,$f.length?rc=$f.concat(rc):gv=-1,rc.length&&rC())}function rC(){if(!Kd){var e=tC(tK);Kd=!0;for(var t=rc.length;t;){for($f=rc,rc=[];++gv<t;)$f&&$f[gv].run();gv=-1,t=rc.length}$f=null,Kd=!1,eK(e)}}On.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];rc.push(new nC(e,t)),rc.length===1&&!Kd&&tC(rC)};function nC(e,t){this.fun=e,this.array=t}nC.prototype.run=function(){this.fun.apply(null,this.array)},On.title="browser",On.browser=!0,On.env={},On.argv=[],On.version="",On.versions={};function nc(){}On.on=nc,On.addListener=nc,On.once=nc,On.off=nc,On.removeListener=nc,On.removeAllListeners=nc,On.emit=nc,On.prependListener=nc,On.prependOnceListener=nc,On.listeners=function(e){return[]},On.binding=function(e){throw new Error("process.binding is not supported")},On.cwd=function(){return"/"},On.chdir=function(e){throw new Error("process.chdir is not supported")},On.umask=function(){return 0};var rK=eC.exports;const ot=QW(rK);function iC(e,t){return function(){return e.apply(t,arguments)}}const{toString:nK}=Object.prototype,{getPrototypeOf:M6}=Object,bv=(e=>t=>{const r=nK.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),no=e=>(e=e.toLowerCase(),t=>bv(t)===e),yv=e=>t=>typeof t===e,{isArray:Gd}=Array,Pm=yv("undefined");function iK(e){return e!==null&&!Pm(e)&&e.constructor!==null&&!Pm(e.constructor)&&Ya(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const aC=no("ArrayBuffer");function aK(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&aC(e.buffer),t}const sK=yv("string"),Ya=yv("function"),sC=yv("number"),vv=e=>e!==null&&typeof e=="object",oK=e=>e===!0||e===!1,wv=e=>{if(bv(e)!=="object")return!1;const t=M6(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},lK=no("Date"),cK=no("File"),uK=no("Blob"),fK=no("FileList"),hK=e=>vv(e)&&Ya(e.pipe),dK=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Ya(e.append)&&((t=bv(e))==="formdata"||t==="object"&&Ya(e.toString)&&e.toString()==="[object FormData]"))},pK=no("URLSearchParams"),[mK,gK,bK,yK]=["ReadableStream","Request","Response","Headers"].map(no),vK=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function zm(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,i;if(typeof e!="object"&&(e=[e]),Gd(e))for(n=0,i=e.length;n<i;n++)t.call(null,e[n],n,e);else{const a=r?Object.getOwnPropertyNames(e):Object.keys(e),s=a.length;let o;for(n=0;n<s;n++)o=a[n],t.call(null,e[o],o,e)}}function oC(e,t){t=t.toLowerCase();const r=Object.keys(e);let n=r.length,i;for(;n-- >0;)if(i=r[n],t===i.toLowerCase())return i;return null}const Hf=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:JW,lC=e=>!Pm(e)&&e!==Hf;function A6(){const{caseless:e}=lC(this)&&this||{},t={},r=(n,i)=>{const a=e&&oC(t,i)||i;wv(t[a])&&wv(n)?t[a]=A6(t[a],n):wv(n)?t[a]=A6({},n):Gd(n)?t[a]=n.slice():t[a]=n};for(let n=0,i=arguments.length;n<i;n++)arguments[n]&&zm(arguments[n],r);return t}const wK=(e,t,r,{allOwnKeys:n}={})=>(zm(t,(i,a)=>{r&&Ya(i)?e[a]=iC(i,r):e[a]=i},{allOwnKeys:n}),e),xK=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),_K=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},SK=(e,t,r,n)=>{let i,a,s;const o={};if(t=t||{},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),a=i.length;a-- >0;)s=i[a],(!n||n(s,e,t))&&!o[s]&&(t[s]=e[s],o[s]=!0);e=r!==!1&&M6(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},kK=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const n=e.indexOf(t,r);return n!==-1&&n===r},EK=e=>{if(!e)return null;if(Gd(e))return e;let t=e.length;if(!sC(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},MK=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&M6(Uint8Array)),AK=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let n;for(;(n=r.next())&&!n.done;){const i=n.value;t.call(e,i[0],i[1])}},CK=(e,t)=>{let r;const n=[];for(;(r=e.exec(t))!==null;)n.push(r);return n},TK=no("HTMLFormElement"),jK=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(t,r,n){return r.toUpperCase()+n}),cC=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),IK=no("RegExp"),uC=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};zm(r,(i,a)=>{let s;(s=t(i,a,e))!==!1&&(n[a]=s||i)}),Object.defineProperties(e,n)},OK=e=>{uC(e,(t,r)=>{if(Ya(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=e[r];if(Ya(n)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},BK=(e,t)=>{const r={},n=i=>
vendor: 5,163 bytes, line 8
8{i.forEach(a=>{r[a]=!0})};return Gd(e)?n(e):n(String(e).split(t)),r},RK=()=>{},NK=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t,C6="abcdefghijklmnopqrstuvwxyz",fC="0123456789",hC={DIGIT:fC,ALPHA:C6,ALPHA_DIGIT:C6+C6.toUpperCase()+fC},FK=(e=16,t=hC.ALPHA_DIGIT)=>{let r="";const{length:n}=t;for(;e--;)r+=t[Math.random()*n|0];return r};function PK(e){return!!(e&&Ya(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const zK=e=>{const t=new Array(10),r=(n,i)=>{if(vv(n)){if(t.indexOf(n)>=0)return;if(!("toJSON"in n)){t[i]=n;const a=Gd(n)?[]:{};return zm(n,(s,o)=>{const c=r(s,i+1);!Pm(c)&&(a[o]=c)}),t[i]=void 0,a}}return n};return r(e,0)},LK=no("AsyncFunction"),DK=e=>e&&(vv(e)||Ya(e))&&Ya(e.then)&&Ya(e.catch),dC=((e,t)=>e?setImmediate:t?((r,n)=>(Hf.addEventListener("message",({source:i,data:a})=>{i===Hf&&a===r&&n.length&&n.shift()()},!1),i=>{n.push(i),Hf.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",Ya(Hf.postMessage)),UK=typeof queueMicrotask<"u"?queueMicrotask.bind(Hf):typeof ot<"u"&&ot.nextTick||dC,Oe={isArray:Gd,isArrayBuffer:aC,isBuffer:iK,isFormData:dK,isArrayBufferView:aK,isString:sK,isNumber:sC,isBoolean:oK,isObject:vv,isPlainObject:wv,isReadableStream:mK,isRequest:gK,isResponse:bK,isHeaders:yK,isUndefined:Pm,isDate:lK,isFile:cK,isBlob:uK,isRegExp:IK,isFunction:Ya,isStream:hK,isURLSearchParams:pK,isTypedArray:MK,isFileList:fK,forEach:zm,merge:A6,extend:wK,trim:vK,stripBOM:xK,inherits:_K,toFlatObject:SK,kindOf:bv,kindOfTest:no,endsWith:kK,toArray:EK,forEachEntry:AK,matchAll:CK,isHTMLForm:TK,hasOwnProperty:cC,hasOwnProp:cC,reduceDescriptors:uC,freezeMethods:OK,toObjectSet:BK,toCamelCase:jK,noop:RK,toFiniteNumber:NK,findKey:oC,global:Hf,isContextDefined:lC,ALPHABET:hC,generateString:FK,isSpecCompliantForm:PK,toJSONObject:zK,isAsyncFn:LK,isThenable:DK,setImmediate:dC,asap:UK};var ri={},xv={};xv.byteLength=ZK,xv.toByteArray=HK,xv.fromByteArray=GK;for(var el=[],ks=[],qK=typeof Uint8Array<"u"?Uint8Array:Array,T6="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Yd=0,VK=T6.length;Yd<VK;++Yd)el[Yd]=T6[Yd],ks[T6.charCodeAt(Yd)]=Yd;ks[45]=62,ks[95]=63;function pC(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");r===-1&&(r=t);var n=r===t?0:4-r%4;return[r,n]}function ZK(e){var t=pC(e),r=t[0],n=t[1];return(r+n)*3/4-n}function $K(e,t,r){return(t+r)*3/4-r}function HK(e){var t,r=pC(e),n=r[0],i=r[1],a=new qK($K(e,n,i)),s=0,o=i>0?n-4:n,c;for(c=0;c<o;c+=4)t=ks[e.charCodeAt(c)]<<18|ks[e.charCodeAt(c+1)]<<12|ks[e.charCodeAt(c+2)]<<6|ks[e.charCodeAt(c+3)],a[s++]=t>>16&255,a[s++]=t>>8&255,a[s++]=t&255;return i===2&&(t=ks[e.charCodeAt(c)]<<2|ks[e.charCodeAt(c+1)]>>4,a[s++]=t&255),i===1&&(t=ks[e.charCodeAt(c)]<<10|ks[e.charCodeAt(c+1)]<<4|ks[e.charCodeAt(c+2)]>>2,a[s++]=t>>8&255,a[s++]=t&255),a}function WK(e){return el[e>>18&63]+el[e>>12&63]+el[e>>6&63]+el[e&63]}function KK(e,t,r){for(var n,i=[],a=t;a<r;a+=3)n=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(e[a+2]&255),i.push(WK(n));return i.join("")}function GK(e){for(var t,r=e.length,n=r%3,i=[],a=16383,s=0,o=r-n;s<o;s+=a)i.push(KK(e,s,s+a>o?o:s+a));return n===1?(t=e[r-1],i.push(el[t>>2]+el[t<<4&63]+"==")):n===2&&(t=(e[r-2]<<8)+e[r-1],i.push(el[t>>10]+el[t>>4&63]+el[t<<2&63]+"=")),i.join("")}var j6={};j6.read=function(e,t,r,n,i){var a,s,o=i*8-n-1,c=(1<<o)-1,l=c>>1,u=-7,d=r?i-1:0,p=r?-1:1,w=e[t+d];for(d+=p,a=w&(1<<-u)-1,w>>=-u,u+=o;u>0;a=a*256+e[t+d],d+=p,u-=8);for(s=a&(1<<-u)-1,a>>=-u,u+=n;u>0;s=s*256+e[t+d],d+=p,u-=8);if(a===0)a=1-l;else{if(a===c)return s?NaN:(w?-1:1)*(1/0);s=s+Math.pow(2,n),a=a-l}return(w?-1:1)*s*Math.pow(2,a-n)},j6.write=function(e,t,r,n,i,a){var s,o,c,l=a*8-i-1,u=(1<<l)-1,d=u>>1,p=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,w=n?0:a-1,O=n?1:-1,I=t<0||t===0&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(o=isNaN(t)?1:0,s=u):(s=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-s))<1&&(s--,c*=2),s+d>=1?t+=p/c:t+=p*Math.pow(2,1-d),t*c>=2&&(s++,c/=2),s+d>=u?(o=0,s=u):s+d>=1?(o=(t*c-1)*Math.pow(2,i),s=s+d):(o=t*Math.pow(2,d-1)*Math.pow(2,i),s=0));i>=8;e[r+w]=o&255,w+=O,o/=256,i-=8);for(s=s<<i|o,l+=i;l>0;e[r+w]=s&255,w+=O,s/=256,l-=8);e[r+w-O]|=I*128},function(e){const t=xv,r=j6,n=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=u,e.SlowBuffer=Z,e.INSPECT_MAX_BYTES=50;const i=2147483647;e.kMaxLength=i;const{Uint8Array:a,ArrayBuffer:s,SharedArrayBuffer:o}=globalThis;u.TYPED_ARRAY_SUPPORT=c(),!u.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function c(){try{const k=new a(1),L={foo:function(){return 42}};return Object.setPrototypeOf(L,a.prototype),Object.setPrototypeOf(k,L),k.foo()===42}catch{return!1}}Object.defineProperty(u.prototype,"parent",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.buffer}}),Object.defineProperty(u.prototype,"offset",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.byteOffset}});function l(k){if(k>
vendor: 21,078 bytes, line 8
8i)throw new RangeError('The value "'+k+'" is invalid for option "size"');const L=new a(k);return Object.setPrototypeOf(L,u.prototype),L}function u(k,L,q){if(typeof k=="number"){if(typeof L=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return O(k)}return d(k,L,q)}u.poolSize=8192;function d(k,L,q){if(typeof k=="string")return I(k,L);if(s.isView(k))return C(k);if(k==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof k);if(we(k,s)||k&&we(k.buffer,s)||typeof o<"u"&&(we(k,o)||k&&we(k.buffer,o)))return j(k,L,q);if(typeof k=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const ie=k.valueOf&&k.valueOf();if(ie!=null&&ie!==k)return u.from(ie,L,q);const fe=N(k);if(fe)return fe;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof k[Symbol.toPrimitive]=="function")return u.from(k[Symbol.toPrimitive]("string"),L,q);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof k)}u.from=function(k,L,q){return d(k,L,q)},Object.setPrototypeOf(u.prototype,a.prototype),Object.setPrototypeOf(u,a);function p(k){if(typeof k!="number")throw new TypeError('"size" argument must be of type number');if(k<0)throw new RangeError('The value "'+k+'" is invalid for option "size"')}function w(k,L,q){return p(k),k<=0?l(k):L!==void 0?typeof q=="string"?l(k).fill(L,q):l(k).fill(L):l(k)}u.alloc=function(k,L,q){return w(k,L,q)};function O(k){return p(k),l(k<0?0:P(k)|0)}u.allocUnsafe=function(k){return O(k)},u.allocUnsafeSlow=function(k){return O(k)};function I(k,L){if((typeof L!="string"||L==="")&&(L="utf8"),!u.isEncoding(L))throw new TypeError("Unknown encoding: "+L);const q=X(k,L)|0;let ie=l(q);const fe=ie.write(k,L);return fe!==q&&(ie=ie.slice(0,fe)),ie}function R(k){const L=k.length<0?0:P(k.length)|0,q=l(L);for(let ie=0;ie<L;ie+=1)q[ie]=k[ie]&255;return q}function C(k){if(we(k,a)){const L=new a(k);return j(L.buffer,L.byteOffset,L.byteLength)}return R(k)}function j(k,L,q){if(L<0||k.byteLength<L)throw new RangeError('"offset" is outside of buffer bounds');if(k.byteLength<L+(q||0))throw new RangeError('"length" is outside of buffer bounds');let ie;return L===void 0&&q===void 0?ie=new a(k):q===void 0?ie=new a(k,L):ie=new a(k,L,q),Object.setPrototypeOf(ie,u.prototype),ie}function N(k){if(u.isBuffer(k)){const L=P(k.length)|0,q=l(L);return q.length===0||k.copy(q,0,0,L),q}if(k.length!==void 0)return typeof k.length!="number"||ke(k.length)?l(0):R(k);if(k.type==="Buffer"&&Array.isArray(k.data))return R(k.data)}function P(k){if(k>=i)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return k|0}function Z(k){return+k!=k&&(k=0),u.alloc(+k)}u.isBuffer=function(k){return k!=null&&k._isBuffer===!0&&k!==u.prototype},u.compare=function(k,L){if(we(k,a)&&(k=u.from(k,k.offset,k.byteLength)),we(L,a)&&(L=u.from(L,L.offset,L.byteLength)),!u.isBuffer(k)||!u.isBuffer(L))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(k===L)return 0;let q=k.length,ie=L.length;for(let fe=0,be=Math.min(q,ie);fe<be;++fe)if(k[fe]!==L[fe]){q=k[fe],ie=L[fe];break}return q<ie?-1:ie<q?1:0},u.isEncoding=function(k){switch(String(k).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},u.concat=function(k,L){if(!Array.isArray(k))throw new TypeError('"list" argument must be an Array of Buffers');if(k.length===0)return u.alloc(0);let q;if(L===void 0)for(L=0,q=0;q<k.length;++q)L+=k[q].length;const ie=u.allocUnsafe(L);let fe=0;for(q=0;q<k.length;++q){let be=k[q];if(we(be,a))fe+be.length>ie.length?(u.isBuffer(be)||(be=u.from(be)),be.copy(ie,fe)):a.prototype.set.call(ie,be,fe);else if(u.isBuffer(be))be.copy(ie,fe);else throw new TypeError('"list" argument must be an Array of Buffers');fe+=be.length}return ie};function X(k,L){if(u.isBuffer(k))return k.length;if(s.isView(k)||we(k,s))return k.byteLength;if(typeof k!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof k);const q=k.length,ie=arguments.length>2&&arguments[2]===!0;if(!ie&&q===0)return 0;let fe=!1;for(;;)switch(L){case"ascii":case"latin1":case"binary":return q;case"utf8":case"utf-8":return De(k).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return q*2;case"hex":return q>>>1;case"base64":return Fe(k).length;default:if(fe)return ie?-1:De(k).length;L=(""+L).toLowerCase(),fe=!0}}u.byteLength=X;function re(k,L,q){let ie=!1;if((L===void 0||L<0)&&(L=0),L>this.length||((q===void 0||q>this.length)&&(q=this.length),q<=0)||(q>>>=0,L>>>=0,q<=L))return"";for(k||(k="utf8");;)switch(k){case"hex":return F(this,L,q);case"utf8":case"utf-8":return T(this,L,q);case"ascii":return x(this,L,q);case"latin1":case"binary":return v(this,L,q);case"base64":return B(this,L,q);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Q(this,L,q);default:if(ie)throw new TypeError("Unknown encoding: "+k);k=(k+"").toLowerCase(),ie=!0}}u.prototype._isBuffer=!0;function ne(k,L,q){const ie=k[L];k[L]=k[q],k[q]=ie}u.prototype.swap16=function(){const k=this.length;if(k%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let L=0;L<k;L+=2)ne(this,L,L+1);return this},u.prototype.swap32=function(){const k=this.length;if(k%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let L=0;L<k;L+=4)ne(this,L,L+3),ne(this,L+1,L+2);return this},u.prototype.swap64=function(){const k=this.length;if(k%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let L=0;L<k;L+=8)ne(this,L,L+7),ne(this,L+1,L+6),ne(this,L+2,L+5),ne(this,L+3,L+4);return this},u.prototype.toString=function(){const k=this.length;return k===0?"":arguments.length===0?T(this,0,k):re.apply(this,arguments)},u.prototype.toLocaleString=u.prototype.toString,u.prototype.equals=function(k){if(!u.isBuffer(k))throw new TypeError("Argument must be a Buffer");return this===k?!0:u.compare(this,k)===0},u.prototype.inspect=function(){let k="";const L=e.INSPECT_MAX_BYTES;return k=this.toString("hex",0,L).replace(/(.{2})/g,"$1 ").trim(),this.length>L&&(k+=" ... "),"<Buffer "+k+">"},n&&(u.prototype[n]=u.prototype.inspect),u.prototype.compare=function(k,L,q,ie,fe){if(we(k,a)&&(k=u.from(k,k.offset,k.byteLength)),!u.isBuffer(k))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof k);if(L===void 0&&(L=0),q===void 0&&(q=k?k.length:0),ie===void 0&&(ie=0),fe===void 0&&(fe=this.length),L<0||q>k.length||ie<0||fe>this.length)throw new RangeError("out of range index");if(ie>=fe&&L>=q)return 0;if(ie>=fe)return-1;if(L>=q)return 1;if(L>>>=0,q>>>=0,ie>>>=0,fe>>>=0,this===k)return 0;let be=fe-ie,Ce=q-L;const ze=Math.min(be,Ce),Ie=this.slice(ie,fe),qe=k.slice(L,q);for(let it=0;it<ze;++it)if(Ie[it]!==qe[it]){be=Ie[it],Ce=qe[it];break}return be<Ce?-1:Ce<be?1:0};function ae(k,L,q,ie,fe){if(k.length===0)return-1;if(typeof q=="string"?(ie=q,q=0):q>2147483647?q=2147483647:q<-2147483648&&(q=-2147483648),q=+q,ke(q)&&(q=fe?0:k.length-1),q<0&&(q=k.length+q),q>=k.length){if(fe)return-1;q=k.length-1}else if(q<0)if(fe)q=0;else return-1;if(typeof L=="string"&&(L=u.from(L,ie)),u.isBuffer(L))return L.length===0?-1:ue(k,L,q,ie,fe);if(typeof L=="number")return L=L&255,typeof a.prototype.indexOf=="function"?fe?a.prototype.indexOf.call(k,L,q):a.prototype.lastIndexOf.call(k,L,q):ue(k,[L],q,ie,fe);throw new TypeError("val must be string, number or Buffer")}function ue(k,L,q,ie,fe){let be=1,Ce=k.length,ze=L.length;if(ie!==void 0&&(ie=String(ie).toLowerCase(),ie==="ucs2"||ie==="ucs-2"||ie==="utf16le"||ie==="utf-16le")){if(k.length<2||L.length<2)return-1;be=2,Ce/=2,ze/=2,q/=2}function Ie(it,Ve){return be===1?it[Ve]:it.readUInt16BE(Ve*be)}let qe;if(fe){let it=-1;for(qe=q;qe<Ce;qe++)if(Ie(k,qe)===Ie(L,it===-1?0:qe-it)){if(it===-1&&(it=qe),qe-it+1===ze)return it*be}else it!==-1&&(qe-=qe-it),it=-1}else for(q+ze>Ce&&(q=Ce-ze),qe=q;qe>=0;qe--){let it=!0;for(let Ve=0;Ve<ze;Ve++)if(Ie(k,qe+Ve)!==Ie(L,Ve)){it=!1;break}if(it)return qe}return-1}u.prototype.includes=function(k,L,q){return this.indexOf(k,L,q)!==-1},u.prototype.indexOf=function(k,L,q){return ae(this,k,L,q,!0)},u.prototype.lastIndexOf=function(k,L,q){return ae(this,k,L,q,!1)};function m(k,L,q,ie){q=Number(q)||0;const fe=k.length-q;ie?(ie=Number(ie),ie>fe&&(ie=fe)):ie=fe;const be=L.length;ie>be/2&&(ie=be/2);let Ce;for(Ce=0;Ce<ie;++Ce){const ze=parseInt(L.substr(Ce*2,2),16);if(ke(ze))return Ce;k[q+Ce]=ze}return Ce}function A(k,L,q,ie){return ge(De(L,k.length-q),k,q,ie)}function f(k,L,q,ie){return ge(Ke(L),k,q,ie)}function g(k,L,q,ie){return ge(Fe(L),k,q,ie)}function _(k,L,q,ie){return ge(ut(L,k.length-q),k,q,ie)}u.prototype.write=function(k,L,q,ie){if(L===void 0)ie="utf8",q=this.length,L=0;else if(q===void 0&&typeof L=="string")ie=L,q=this.length,L=0;else if(isFinite(L))L=L>>>0,isFinite(q)?(q=q>>>0,ie===void 0&&(ie="utf8")):(ie=q,q=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const fe=this.length-L;if((q===void 0||q>fe)&&(q=fe),k.length>0&&(q<0||L<0)||L>this.length)throw new RangeError("Attempt to write outside buffer bounds");ie||(ie="utf8");let be=!1;for(;;)switch(ie){case"hex":return m(this,k,L,q);case"utf8":case"utf-8":return A(this,k,L,q);case"ascii":case"latin1":case"binary":return f(this,k,L,q);case"base64":return g(this,k,L,q);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return _(this,k,L,q);default:if(be)throw new TypeError("Unknown encoding: "+ie);ie=(""+ie).toLowerCase(),be=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function B(k,L,q){return L===0&&q===k.length?t.fromByteArray(k):t.fromByteArray(k.slice(L,q))}function T(k,L,q){q=Math.min(k.length,q);const ie=[];let fe=L;for(;fe<q;){const be=k[fe];let Ce=null,ze=be>239?4:be>223?3:be>191?2:1;if(fe+ze<=q){let Ie,qe,it,Ve;switch(ze){case 1:be<128&&(Ce=be);break;case 2:Ie=k[fe+1],(Ie&192)===128&&(Ve=(be&31)<<6|Ie&63,Ve>127&&(Ce=Ve));break;case 3:Ie=k[fe+1],qe=k[fe+2],(Ie&192)===128&&(qe&192)===128&&(Ve=(be&15)<<12|(Ie&63)<<6|qe&63,Ve>2047&&(Ve<55296||Ve>57343)&&(Ce=Ve));break;case 4:Ie=k[fe+1],qe=k[fe+2],it=k[fe+3],(Ie&192)===128&&(qe&192)===128&&(it&192)===128&&(Ve=(be&15)<<18|(Ie&63)<<12|(qe&63)<<6|it&63,Ve>65535&&Ve<1114112&&(Ce=Ve))}}Ce===null?(Ce=65533,ze=1):Ce>65535&&(Ce-=65536,ie.push(Ce>>>10&1023|55296),Ce=56320|Ce&1023),ie.push(Ce),fe+=ze}return h(ie)}const S=4096;function h(k){const L=k.length;if(L<=S)return String.fromCharCode.apply(String,k);let q="",ie=0;for(;ie<L;)q+=String.fromCharCode.apply(String,k.slice(ie,ie+=S));return q}function x(k,L,q){let ie="";q=Math.min(k.length,q);for(let fe=L;fe<q;++fe)ie+=String.fromCharCode(k[fe]&127);return ie}function v(k,L,q){let ie="";q=Math.min(k.length,q);for(let fe=L;fe<q;++fe)ie+=String.fromCharCode(k[fe]);return ie}function F(k,L,q){const ie=k.length;(!L||L<0)&&(L=0),(!q||q<0||q>ie)&&(q=ie);let fe="";for(let be=L;be<q;++be)fe+=Ne[k[be]];return fe}function Q(k,L,q){const ie=k.slice(L,q);let fe="";for(let be=0;be<ie.length-1;be+=2)fe+=String.fromCharCode(ie[be]+ie[be+1]*256);return fe}u.prototype.slice=function(k,L){const q=this.length;k=~~k,L=L===void 0?q:~~L,k<0?(k+=q,k<0&&(k=0)):k>q&&(k=q),L<0?(L+=q,L<0&&(L=0)):L>q&&(L=q),L<k&&(L=k);const ie=this.subarray(k,L);return Object.setPrototypeOf(ie,u.prototype),ie};function G(k,L,q){if(k%1!==0||k<0)throw new RangeError("offset is not uint");if(k+L>q)throw new RangeError("Trying to access beyond buffer length")}u.prototype.readUintLE=u.prototype.readUIntLE=function(k,L,q){k=k>>>0,L=L>>>0,q||G(k,L,this.length);let ie=this[k],fe=1,be=0;for(;++be<L&&(fe*=256);)ie+=this[k+be]*fe;return ie},u.prototype.readUintBE=u.prototype.readUIntBE=function(k,L,q){k=k>>>0,L=L>>>0,q||G(k,L,this.length);let ie=this[k+--L],fe=1;for(;L>0&&(fe*=256);)ie+=this[k+--L]*fe;return ie},u.prototype.readUint8=u.prototype.readUInt8=function(k,L){return k=k>>>0,L||G(k,1,this.length),this[k]},u.prototype.readUint16LE=u.prototype.readUInt16LE=function(k,L){return k=k>>>0,L||G(k,2,this.length),this[k]|this[k+1]<<8},u.prototype.readUint16BE=u.prototype.readUInt16BE=function(k,L){return k=k>>>0,L||G(k,2,this.length),this[k]<<8|this[k+1]},u.prototype.readUint32LE=u.prototype.readUInt32LE=function(k,L){return k=k>>>0,L||G(k,4,this.length),(this[k]|this[k+1]<<8|this[k+2]<<16)+this[k+3]*16777216},u.prototype.readUint32BE=u.prototype.readUInt32BE=function(k,L){return k=k>>>0,L||G(k,4,this.length),this[k]*16777216+(this[k+1]<<16|this[k+2]<<8|this[k+3])},u.prototype.readBigUInt64LE=z(function(k){k=k>>>0,xe(k,"offset");const L=this[k],q=this[k+7];(L===void 0||q===void 0)&&Te(k,this.length-8);const ie=L+this[++k]*2**8+this[++k]*2**16+this[++k]*2**24,fe=this[++k]+this[++k]*2**8+this[++k]*2**16+q*2**24;return BigInt(ie)+(BigInt(fe)<<BigInt(32))}),u.prototype.readBigUInt64BE=z(function(k){k=k>>>0,xe(k,"offset");const L=this[k],q=this[k+7];(L===void 0||q===void 0)&&Te(k,this.length-8);const ie=L*2**24+this[++k]*2**16+this[++k]*2**8+this[++k],fe=this[++k]*2**24+this[++k]*2**16+this[++k]*2**8+q;return(BigInt(ie)<<BigInt(32))+BigInt(fe)}),u.prototype.readIntLE=function(k,L,q){k=k>>>0,L=L>>>0,q||G(k,L,this.length);let ie=this[k],fe=1,be=0;for(;++be<L&&(fe*=256);)ie+=this[k+be]*fe;return fe*=128,ie>=fe&&(ie-=Math.pow(2,8*L)),ie},u.prototype.readIntBE=function(k,L,q){k=k>>>0,L=L>>>0,q||G(k,L,this.length);let ie=L,fe=1,be=this[k+--ie];for(;ie>0&&(fe*=256);)be+=this[k+--ie]*fe;return fe*=128,be>=fe&&(be-=Math.pow(2,8*L)),be},u.prototype.readInt8=function(k,L){return k=k>>>0,L||G(k,1,this.length),this[k]&128?(255-this[k]+1)*-1:this[k]},u.prototype.readInt16LE=function(k,L){k=k>>>0,L||G(k,2,this.length);const q=this[k]|this[k+1]<<8;return q&32768?q|4294901760:q},u.prototype.readInt16BE=function(k,L){k=k>>>0,L||G(k,2,this.length);const q=this[k+1]|this[k]<<8;return q&32768?q|4294901760:q},u.prototype.readInt32LE=function(k,L){return k=k>>>0,L||G(k,4,this.length),this[k]|this[k+1]<<8|this[k+2]<<16|this[k+3]<<24},u.prototype.readInt32BE=function(k,L){return k=k>>>0,L||G(k,4,this.length),this[k]<<24|this[k+1]<<16|this[k+2]<<8|this[k+3]},u.prototype.readBigInt64LE=z(function(k){k=k>>>0,xe(k,"offset");const L=this[k],q=this[k+7];(L===void 0||q===void 0)&&Te(k,this.length-8);const ie=this[k+4]+this[k+5]*2**8+this[k+6]*2**16+(q<<24);return(BigInt(ie)<<BigInt(32))+BigInt(L+this[++k]*256+this[++k]*65536+this[++k]*16777216)}),u.prototype.readBigInt64BE=z(function(k){k=k>>>0,xe(k,"offset");const L=this[k],q=this[k+7];(L===void 0||q===void 0)&&Te(k,this.length-8);const ie=(L<<24)+this[++k]*2**16+this[++k]*2**8+this[++k];return(BigInt(ie)<<BigInt(32))+BigInt(this[++k]*16777216+this[++k]*65536+this[++k]*256+q)}),u.prototype.readFloatLE=function(k,L){return k=k>>>0,L||G(k,4,this.length),r.read(this,k,!0,23,4)},u.prototype.readFloatBE=function(k,L){return k=k>>>0,L||G(k,4,this.length),r.read(this,k,!1,23,4)},u.prototype.readDoubleLE=function(k,L){return k=k>>>0,L||G(k,8,this.length),r.read(this,k,!0,52,8)},u.prototype.readDoubleBE=function(k,L){return k=k>>>0,L||G(k,8,this.length),r.read(this,k,!1,52,8)};function J(k,L,q,ie,fe,be){if(!u.isBuffer(k))throw new TypeError('"buffer" argument must be a Buffer instance');if(L>fe||L<be)throw new RangeError('"value" argument is out of bounds');if(q+ie>k.length)throw new RangeError("Index out of range")}u.prototype.writeUintLE=u.prototype.writeUIntLE=function(k,L,q,ie){if(k=+k,L=L>>>0,q=q>>>0,!ie){const Ce=Math.pow(2,8*q)-1;J(this,k,L,q,Ce,0)}let fe=1,be=0;for(this[L]=k&255;++be<q&&(fe*=256);)this[L+be]=k/fe&255;return L+q},u.prototype.writeUintBE=u.prototype.writeUIntBE=function(k,L,q,ie){if(k=+k,L=L>>>0,q=q>>>0,!ie){const Ce=Math.pow(2,8*q)-1;J(this,k,L,q,Ce,0)}let fe=q-1,be=1;for(this[L+fe]=k&255;--fe>=0&&(be*=256);)this[L+fe]=k/be&255;return L+q},u.prototype.writeUint8=u.prototype.writeUInt8=function(k,L,q){return k=+k,L=L>>>0,q||J(this,k,L,1,255,0),this[L]=k&255,L+1},u.prototype.writeUint16LE=u.prototype.writeUInt16LE=function(k,L,q){return k=+k,L=L>>>0,q||J(this,k,L,2,65535,0),this[L]=k&255,this[L+1]=k>>>8,L+2},u.prototype.writeUint16BE=u.prototype.writeUInt16BE=function(k,L,q){return k=+k,L=L>>>0,q||J(this,k,L,2,65535,0),this[L]=k>>>8,this[L+1]=k&255,L+2},u.prototype.writeUint32LE=u.prototype.writeUInt32LE=function(k,L,q){return k=+k,L=L>>>0,q||J(this,k,L,4,4294967295,0),this[L+3]=k>>>24,this[L+2]=k>>>16,this[L+1]=k>>>8,this[L]=k&255,L+4},u.prototype.writeUint32BE=u.prototype.writeUInt32BE=function(k,L,q){return k=+k,L=L>>>0,q||J(this,k,L,4,4294967295,0),this[L]=k>>>24,this[L+1]=k>>>16,this[L+2]=k>>>8,this[L+3]=k&255,L+4};function Y(k,L,q,ie,fe){Ue(L,ie,fe,k,q,7);let be=Number(L&BigInt(4294967295));k[q++]=be,be=be>>8,k[q++]=be,be=be>>8,k[q++]=be,be=be>>8,k[q++]=be;let Ce=Number(L>>BigInt(32)&BigInt(4294967295));return k[q++]=Ce,Ce=Ce>>8,k[q++]=Ce,Ce=Ce>>8,k[q++]=Ce,Ce=Ce>>8,k[q++]=Ce,q}function V(k,L,q,ie,fe){Ue(L,ie,fe,k,q,7);let be=Number(L&BigInt(4294967295));k[q+7]=be,be=be>>8,k[q+6]=be,be=be>>8,k[q+5]=be,be=be>>8,k[q+4]=be;let Ce=Number(L>>BigInt(32)&BigInt(4294967295));return k[q+3]=Ce,Ce=Ce>>8,k[q+2]=Ce,Ce=Ce>>8,k[q+1]=Ce,Ce=Ce>>8,k[q]=Ce,q+8}u.prototype.writeBigUInt64LE=z(function(k,L=0){return Y(this,k,L,BigInt(0),BigInt("0xffffffffffffffff"))}),u.prototype.writeBigUInt64BE=z(function(k,L=0){return V(this,k,L,BigInt(0),BigInt("0xffffffffffffffff"))}),u.prototype.writeIntLE=function(k,L,q,ie){if(k=+k,L=L>>>0,!ie){const ze=Math.pow(2,8*q-1);J(this,k,L,q,ze-1,-ze)}let fe=0,be=1,Ce=0;for(this[L]=k&255;++fe<q&&(be*=256);)k<0&&Ce===0&&this[L+fe-1]!==0&&(Ce=1),this[L+fe]=(k/be>>0)-Ce&255;return L+q},u.prototype.writeIntBE=function(k,L,q,ie){if(k=+k,L=L>>>0,!ie){const ze=Math.pow(2,8*q-1);J(this,k,L,q,ze-1,-ze)}let fe=q-1,be=1,Ce=0;for(this[L+fe]=k&255;--fe>=0&&(be*=256);)k<0&&Ce===0&&this[L+fe+1]!==0&&(Ce=1),this[L+fe]=(k/be>>0)-Ce&255;return L+q},u.prototype.writeInt8=function(k,L,q){return k=+k,L=L>>>0,q||J(this,k,L,1,127,-128),k<0&&(k=255+k+1),this[L]=k&255,L+1},u.prototype.writeInt16LE=function(k,L,q){return k=+k,L=L>>>0,q||J(this,k,L,2,32767,-32768),this[L]=k&255,this[L+1]=k>>>8,L+2},u.prototype.writeInt16BE=function(k,L,q){return k=+k,L=L>>>0,q||J(this,k,L,2,32767,-32768),this[L]=k>>>8,this[L+1]=k&255,L+2},u.prototype.writeInt32LE=function(k,L,q){return k=+k,L=L>>>0,q||J(this,k,L,4,2147483647,-2147483648),this[L]=k&255,this[L+1]=k>>>8,this[L+2]=k>>>16,this[L+3]=k>>>24,L+4},u.prototype.writeInt32BE=function(k,L,q){return k=+k,L=L>>>0,q||J(this,k,L,4,2147483647,-2147483648),k<0&&(k=4294967295+k+1),this[L]=k>>>24,this[L+1]=k>>>16,this[L+2]=k>>>8,this[L+3]=k&255,L+4},u.prototype.writeBigInt64LE=z(function(k,L=0){return Y(this,k,L,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),u.prototype.writeBigInt64BE=z(function(k,L=0){return V(this,k,L,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function W(k,L,q,ie,fe,be){if(q+ie>k.length)throw new RangeError("Index out of range");if(q<0)throw new RangeError("Index out of range")}function ce(k,L,q,ie,fe){return L=+L,q=q>>>0,fe||W(k,L,q,4),r.write(k,L,q,ie,23,4),q+4}u.prototype.writeFloatLE=function(k,L,q){return ce(this,k,L,!0,q)},u.prototype.writeFloatBE=function(k,L,q){return ce(this,k,L,!1,q)};function pe(k,L,q,ie,fe){return L=+L,q=q>>>0,fe||W(k,L,q,8),r.write(k,L,q,ie,52,8),q+8}u.prototype.writeDoubleLE=function(k,L,q){return pe(this,k,L,!0,q)},u.prototype.writeDoubleBE=function(k,L,q){return pe(this,k,L,!1,q)},u.prototype.copy=function(k,L,q,ie){if(!u.isBuffer(k))throw new TypeError("argument should be a Buffer");if(q||(q=0),!ie&&ie!==0&&(ie=this.length),L>=k.length&&(L=k.length),L||(L=0),ie>0&&ie<q&&(ie=q),ie===q||k.length===0||this.length===0)return 0;if(L<0)throw new RangeError("targetStart out of bounds");if(q<0||q>=this.length)throw new RangeError("Index out of range");if(ie<0)throw new RangeError("sourceEnd out of bounds");ie>this.length&&(ie=this.length),k.length-L<ie-q&&(ie=k.length-L+q);const fe=ie-q;return this===k&&typeof a.prototype.copyWithin=="function"?this.copyWithin(L,q,ie):a.prototype.set.call(k,this.subarray(q,ie),L),fe},u.prototype.fill=function(k,L,q,ie){if(typeof k=="string"){if(typeof L=="string"?(ie=L,L=0,q=this.length):typeof q=="string"&&(ie=q,q=this.length),ie!==void 0&&typeof ie!="string")throw new TypeError("encoding must be a string");if(typeof ie=="string"&&!u.isEncoding(ie))throw new TypeError("Unknown encoding: "+ie);if(k.length===1){const be=k.charCodeAt(0);(ie==="utf8"&&be<128||ie==="latin1")&&(k=be)}}else typeof k=="number"?k=k&255:typeof k=="boolean"&&(k=Number(k));if(L<0||this.length<L||this.length<q)throw new RangeError("Out of range index");if(q<=L)return this;L=L>>>0,q=q===void 0?this.length:q>>>0,k||(k=0);let fe;if(typeof k=="number")for(fe=L;fe<q;++fe)this[fe]=k;else{const be=u.isBuffer(k)?k:u.from(k,ie),Ce=be.length;
vendor: 2,111 bytes, line 8
8if(Ce===0)throw new TypeError('The value "'+k+'" is invalid for argument "value"');for(fe=0;fe<q-L;++fe)this[fe+L]=be[fe%Ce]}return this};const ee={};function se(k,L,q){ee[k]=class extends q{constructor(){super(),Object.defineProperty(this,"message",{value:L.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${k}]`,this.stack,delete this.name}get code(){return k}set code(ie){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:ie,writable:!0})}toString(){return`${this.name} [${k}]: ${this.message}`}}}se("ERR_BUFFER_OUT_OF_BOUNDS",function(k){return k?`${k} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),se("ERR_INVALID_ARG_TYPE",function(k,L){return`The "${k}" argument must be of type number. Received type ${typeof L}`},TypeError),se("ERR_OUT_OF_RANGE",function(k,L,q){let ie=`The value of "${k}" is out of range.`,fe=q;return Number.isInteger(q)&&Math.abs(q)>4294967296?fe=ve(String(q)):typeof q=="bigint"&&(fe=String(q),(q>BigInt(2)**BigInt(32)||q<-(BigInt(2)**BigInt(32)))&&(fe=ve(fe)),fe+="n"),ie+=` It must be ${L}. Received ${fe}`,ie},RangeError);function ve(k){let L="",q=k.length;const ie=k[0]==="-"?1:0;for(;q>=ie+4;q-=3)L=`_${k.slice(q-3,q)}${L}`;return`${k.slice(0,q)}${L}`}function _e(k,L,q){xe(L,"offset"),(k[L]===void 0||k[L+q]===void 0)&&Te(L,k.length-(q+1))}function Ue(k,L,q,ie,fe,be){if(k>q||k<L){const Ce=typeof L=="bigint"?"n":"";let ze;throw L===0||L===BigInt(0)?ze=`>= 0${Ce} and < 2${Ce} ** ${(be+1)*8}${Ce}`:ze=`>= -(2${Ce} ** ${(be+1)*8-1}${Ce}) and < 2 ** ${(be+1)*8-1}${Ce}`,new ee.ERR_OUT_OF_RANGE("value",ze,k)}_e(ie,fe,be)}function xe(k,L){if(typeof k!="number")throw new ee.ERR_INVALID_ARG_TYPE(L,"number",k)}function Te(k,L,q){throw Math.floor(k)!==k?(xe(k,q),new ee.ERR_OUT_OF_RANGE("offset","an integer",k)):L<0?new ee.ERR_BUFFER_OUT_OF_BOUNDS:new ee.ERR_OUT_OF_RANGE("offset",`>= 0 and <= ${L}`,k)}const $e=/[^+/0-9A-Za-z-_]/g;function Ae(k){if(k=k.split("=")[0],k=k.trim().replace($e,""),k.length<2)return"";for(;k.length%4!==0;)k=k+"=";return k}function De(k,L){L=L||1/0;let q;
8const ie=k.length;let fe=null;const be=[];for(let Ce=0;Ce<ie;++Ce){if(q=k.charCodeAt(Ce),q>55295&&q<57344){if(!fe){if(q>56319){(L-=3)>-1&&be.push(239,191,189);continue}else if(Ce+1===ie){(L-=3)>-1&&be.push(239,191,189);continue}fe=q;continue}if(q<56320){(L-=3)>-1&&be.push(239,191,189),fe=q;continue}q=(fe-55296<<10|q-56320)+65536}else fe&&(L-=3)>-1&&be.push(239,191,189);if(fe=null,q<128){if((L-=1)<0)break;be.push(q)}else if(q<2048){if((L-=2)<0)break;be.push(q>>6|192,q&63|128)}else if(q<65536){if((L-=3)<0)break;be.push(q>>12|224,q>>6&63|128,q&63|128)}else if(q<1114112){if((L-=4)<0)break;be.push(q>>18|240,q>>12&63|128,q>>6&63|128,q&63|128)}else throw new Error("Invalid code point")}return be}function Ke(k){const L=[];for(let q=0;q<k.length;++q)L.push(k.charCodeAt(q)&255);return L}function ut(k,L){let q,ie,fe;const be=[];for(let Ce=0;Ce<k.length&&!((L-=2)<0);++Ce)q=k.charCodeAt(Ce),ie=q>>8,fe=q%256,be.push(fe),be.push(ie);return be}function Fe(k){return t.toByteArray(Ae(k))}function ge(k,L,q,ie){let fe;for(fe=0;fe<ie&&!(fe+q>=L.length||fe>=k.length);++fe)L[fe+q]=k[fe];return fe}function we(k,L){return k instanceof L||k!=null&&k.constructor!=null&&k.constructor.name!=null&&k.constructor.name===L.name}function ke(k){return k!==k}const Ne=function(){const k="0123456789abcdef",L=new Array(256);for(let q=0;q<16;++q){const ie=q*16;for(let fe=0;fe<16;++fe)L[ie+fe]=k[q]+k[fe]}return L}();function z(k){return typeof BigInt>"u"?H:k}function H(){throw new Error("BigInt not supported")}}(ri);const je=ri.Buffer,YK=ri.Blob,XK=ri.BlobOptions,I6=ri.Buffer,JK=ri.File,QK=ri.FileOptions,eG=ri.INSPECT_MAX_BYTES,tG=ri.SlowBuffer,rG=ri.TranscodeEncoding,nG=ri.atob,iG=ri.btoa,aG=ri.constants,sG=ri.isAscii,oG=ri.isUtf8,lG=ri.kMaxLength,cG=ri.kStringMaxLength,uG=ri.resolveObjectURL,fG=ri.transcode,hG=Object.freeze(Object.defineProperty({__proto__:null,Blob:YK,BlobOptions:XK,Buffer:I6,File:JK,FileOptions:QK,INSPECT_MAX_BYTES:eG,SlowBuffer:tG,TranscodeEncoding:rG,atob:nG,btoa:iG,constants:aG,default:je,isAscii:sG,isUtf8:oG,kMaxLength:lG,kStringMaxLength:cG,resolveObjectURL:uG,transcode:fG},Symbol.toStringTag,{value:"Module"}));function Xt(e,t,r,n,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),i&&(this.response=i,this.status=i.status?i.status:null)}Oe.inherits(Xt,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:Oe.toJSONObject(this.config),code:this.code,status:this.status}}});const mC=Xt.prototype,gC={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{gC[e]={value:e}}),Object.defineProperties(Xt,gC),Object.defineProperty(mC,"isAxiosError",{value:!0}),Xt.from=(e,t,r,n,i,a)=>{const s=Object.create(mC);return Oe.toFlatObject(e,s,function(o){return o!==Error.prototype},o=>o!=="isAxiosError"),Xt.call(s,e.message,t,r,n,i),s.cause=e,s.name=e.name,a&&Object.assign(s,a),s};const dG=null;function O6(e){return Oe.isPlainObject(e)||Oe.isArray(e)}function bC(e){return Oe.endsWith(e,"[]")?e.slice(0,-2):e}function yC(e,t,r){return e?e.concat(t).map(function(n,i){return n=bC(n),!r&&i?"["+n+"]":n}).join(r?".":""):t}function pG(e){return Oe.isArray(e)&&!e.some(O6)}const mG=Oe.toFlatObject(Oe,{},null,function(e){return/^is[A-Z]/.test(e)});function _v(e,t,r){if(!Oe.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=Oe.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(w,O){return!Oe.isUndefined(O[w])});const n=r.metaTokens,i=r.visitor||l,a=r.dots,s=r.indexes,o=(r.Blob||typeof Blob<"u"&&Blob)&&Oe.isSpecCompliantForm(t);if(!Oe.isFunction(i))throw new TypeError("visitor must be a function");function c(w){if(w===null)return"";if(Oe.isDate(w))return w.toISOString();if(!o&&Oe.isBlob(w))throw new Xt("Blob is not supported. Use a Buffer instead.");
vendor: 4,124 bytes, line 8
8return Oe.isArrayBuffer(w)||Oe.isTypedArray(w)?o&&typeof Blob=="function"?new Blob([w]):je.from(w):w}function l(w,O,I){let R=w;if(w&&!I&&typeof w=="object"){if(Oe.endsWith(O,"{}"))O=n?O:O.slice(0,-2),w=JSON.stringify(w);else if(Oe.isArray(w)&&pG(w)||(Oe.isFileList(w)||Oe.endsWith(O,"[]"))&&(R=Oe.toArray(w)))return O=bC(O),R.forEach(function(C,j){!(Oe.isUndefined(C)||C===null)&&t.append(s===!0?yC([O],j,a):s===null?O:O+"[]",c(C))}),!1}return O6(w)?!0:(t.append(yC(I,O,a),c(w)),!1)}const u=[],d=Object.assign(mG,{defaultVisitor:l,convertValue:c,isVisitable:O6});function p(w,O){if(!Oe.isUndefined(w)){if(u.indexOf(w)!==-1)throw Error("Circular reference detected in "+O.join("."));u.push(w),Oe.forEach(w,function(I,R){(!(Oe.isUndefined(I)||I===null)&&i.call(t,I,Oe.isString(R)?R.trim():R,O,d))===!0&&p(I,O?O.concat(R):[R])}),u.pop()}}if(!Oe.isObject(e))throw new TypeError("data must be an object");return p(e),t}function vC(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function B6(e,t){this._pairs=[],e&&_v(e,this,t)}const wC=B6.prototype;wC.append=function(e,t){this._pairs.push([e,t])},wC.toString=function(e){const t=e?function(r){return e.call(this,r,vC)}:vC;return this._pairs.map(function(r){return t(r[0])+"="+t(r[1])},"").join("&")};function gG(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function xC(e,t,r){if(!t)return e;const n=r&&r.encode||gG,i=r&&r.serialize;let a;if(i?a=i(t,r):a=Oe.isURLSearchParams(t)?t.toString():new B6(t,r).toString(n),a){const s=e.indexOf("#");s!==-1&&(e=e.slice(0,s)),e+=(e.indexOf("?")===-1?"?":"&")+a}return e}class _C{constructor(){this.handlers=[]}use(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){Oe.forEach(this.handlers,function(r){r!==null&&t(r)})}}const SC={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},bG=typeof URLSearchParams<"u"?URLSearchParams:B6,yG=typeof FormData<"u"?FormData:null,vG=typeof Blob<"u"?Blob:null,wG={isBrowser:!0,classes:{URLSearchParams:bG,FormData:yG,Blob:vG},protocols:["http","https","file","blob","url","data"]},R6=typeof window<"u"&&typeof document<"u",N6=typeof navigator=="object"&&navigator||void 0,xG=R6&&(!N6||["ReactNative","NativeScript","NS"].indexOf(N6.product)<0),_G=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",SG=R6&&window.location.href||"http://localhost",kG=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:R6,hasStandardBrowserEnv:xG,hasStandardBrowserWebWorkerEnv:_G,navigator:N6,origin:SG},Symbol.toStringTag,{value:"Module"})),ka={...kG,...wG};function EG(e,t){return _v(e,new ka.classes.URLSearchParams,Object.assign({visitor:function(r,n,i,a){return ka.isNode&&Oe.isBuffer(r)?(this.append(n,r.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function MG(e){return Oe.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function AG(e){const t={},r=Object.keys(e);let n;const i=r.length;let a;for(n=0;n<i;n++)a=r[n],t[a]=e[a];return t}function kC(e){function t(r,n,i,a){let s=r[a++];if(s==="__proto__")return!0;const o=Number.isFinite(+s),c=a>=r.length;return s=!s&&Oe.isArray(i)?i.length:s,c?(Oe.hasOwnProp(i,s)?i[s]=[i[s],n]:i[s]=n,!o):((!i[s]||!Oe.isObject(i[s]))&&(i[s]=[]),t(r,n,i[s],a)&&Oe.isArray(i[s])&&(i[s]=AG(i[s])),!o)}if(Oe.isFormData(e)&&Oe.isFunction(e.entries)){const r={};return Oe.forEachEntry(e,(n,i)=>{t(MG(n),i,r,0)}),r}return null}function CG(e,t,r){if(Oe.isString(e))try{return(t||JSON.parse)(e),Oe.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(0,JSON.stringify)(e)}const Lm={transitional:SC,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const r=t.getContentType()||"",n=r.indexOf("application/json")>-1,i=Oe.isObject(e);
vendor: 4,680 bytes, lines 8-10
8if(i&&Oe.isHTMLForm(e)&&(e=new FormData(e)),Oe.isFormData(e))return n?JSON.stringify(kC(e)):e;if(Oe.isArrayBuffer(e)||Oe.isBuffer(e)||Oe.isStream(e)||Oe.isFile(e)||Oe.isBlob(e)||Oe.isReadableStream(e))return e;if(Oe.isArrayBufferView(e))return e.buffer;if(Oe.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let a;if(i){if(r.indexOf("application/x-www-form-urlencoded")>-1)return EG(e,this.formSerializer).toString();if((a=Oe.isFileList(e))||r.indexOf("multipart/form-data")>-1){const s=this.env&&this.env.FormData;return _v(a?{"files[]":e}:e,s&&new s,this.formSerializer)}}return i||n?(t.setContentType("application/json",!1),CG(e)):e}],transformResponse:[function(e){const t=this.transitional||Lm.transitional,r=t&&t.forcedJSONParsing,n=this.responseType==="json";if(Oe.isResponse(e)||Oe.isReadableStream(e))return e;if(e&&Oe.isString(e)&&(r&&!this.responseType||n)){const i=!(t&&t.silentJSONParsing)&&n;try{return JSON.parse(e)}catch(a){if(i)throw a.name==="SyntaxError"?Xt.from(a,Xt.ERR_BAD_RESPONSE,this,null,this.response):a}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:ka.classes.FormData,Blob:ka.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};Oe.forEach(["delete","get","head","post","put","patch"],e=>{Lm.headers[e]={}});const TG=Oe.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),jG=e=>{const t={};let r,n,i;return e&&e.split(`
9`).forEach(function(a){i=a.indexOf(":"),r=a.substring(0,i).trim().toLowerCase(),n=a.substring(i+1).trim(),!(!r||t[r]&&TG[r])&&(r==="set-cookie"?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)}),t},EC=Symbol("internals");function Dm(e){return e&&String(e).trim().toLowerCase()}function Sv(e){return e===!1||e==null?e:Oe.isArray(e)?e.map(Sv):String(e)}function IG(e){const t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(e);)t[n[1]]=n[2];return t}const OG=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function F6(e,t,r,n,i){if(Oe.isFunction(n))return n.call(this,t,r);if(i&&(t=r),!!Oe.isString(t)){if(Oe.isString(n))return t.indexOf(n)!==-1;if(Oe.isRegExp(n))return n.test(t)}}function BG(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,r,n)=>r.toUpperCase()+n)}function RG(e,t){const r=Oe.toCamelCase(" "+t);["get","set","has"].forEach(n=>{Object.defineProperty(e,n+r,{value:function(i,a,s){return this[n].call(this,t,i,a,s)},configurable:!0})})}class Ea{constructor(t){t&&this.set(t)}set(t,r,n){const i=this;function a(o,c,l){const u=Dm(c);if(!u)throw new Error("header name must be a non-empty string");const d=Oe.findKey(i,u);(!d||i[d]===void 0||l===!0||l===void 0&&i[d]!==!1)&&(i[d||c]=Sv(o))}const s=(o,c)=>Oe.forEach(o,(l,u)=>a(l,u,c));if(Oe.isPlainObject(t)||t instanceof this.constructor)s(t,r);else if(Oe.isString(t)&&(t=t.trim())&&!OG(t))s(jG(t),r);else if(Oe.isHeaders(t))for(const[o,c]of t.entries())a(c,o,n);else t!=null&&a(r,t,n);return this}get(t,r){if(t=Dm(t),t){const n=Oe.findKey(this,t);if(n){const i=this[n];if(!r)return i;if(r===!0)return IG(i);if(Oe.isFunction(r))return r.call(this,i,n);if(Oe.isRegExp(r))return r.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,r){if(t=Dm(t),t){const n=Oe.findKey(this,t);return!!(n&&this[n]!==void 0&&(!r||F6(this,this[n],n,r)))}return!1}delete(t,r){const n=this;let i=!1;function a(s){if(s=Dm(s),s){const o=Oe.findKey(n,s);o&&(!r||F6(n,n[o],o,r))&&(delete n[o],i=!0)}}return Oe.isArray(t)?t.forEach(a):a(t),i}clear(t){const r=Object.keys(this);let n=r.length,i=!1;for(;n--;){const a=r[n];(!t||F6(this,this[a],a,t,!0))&&(delete this[a],i=!0)}return i}normalize(t){const r=this,n={};return Oe.forEach(this,(i,a)=>{const s=Oe.findKey(n,a);if(s){r[s]=Sv(i),delete r[a];return}const o=t?BG(a):String(a).trim();o!==a&&delete r[a],r[o]=Sv(i),n[o]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const r=Object.create(null);return Oe.forEach(this,(n,i)=>{n!=null&&n!==!1&&(r[i]=t&&Oe.isArray(n)?n.join(", "):n)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,r])=>t+": "+r).join(`
10`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const n=new this(t);return r.forEach(i=>
10n.set(i)),n}static accessor(t){const r=(this[EC]=this[EC]={accessors:{}}).accessors,n=this.prototype;function i(a){const s=Dm(a);r[s]||(RG(n,a),r[s]=!0)}return Oe.isArray(t)?t.forEach(i):i(t),this}}Ea.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Oe.reduceDescriptors(Ea.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}}),Oe.freezeMethods(Ea);function P6(e,t){const r=this||Lm,n=t||r,i=Ea.from(n.headers);let a=n.data;return Oe.forEach(e,function(s){a=s.call(r,a,i.normalize(),t?t.status:void 0)}),i.normalize(),a}function MC(e){return!!(e&&e.__CANCEL__)}function Xd(e,t,r){Xt.call(this,e??"canceled",Xt.ERR_CANCELED,t,r),this.name="CanceledError"}Oe.inherits(Xd,Xt,{__CANCEL__:!0});function AC(e,t,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?e(r):t(new Xt("Request failed with status code "+r.status,[Xt.ERR_BAD_REQUEST,Xt.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function NG(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function FG(e,t){e=e||10;const r=new Array(e),n=new Array(e);let i=0,a=0,s;return t=t!==void 0?t:1e3,function(o){const c=Date.now(),l=n[a];s||(s=c),r[i]=o,n[i]=c;let u=a,d=0;for(;u!==i;)d+=r[u++],u=u%e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),c-s<t)return;const p=l&&c-l;return p?Math.round(d*1e3/p):void 0}}function PG(e,t){let r=0,n=1e3/t,i,a;const s=(o,c=Date.now())=>{r=c,i=null,a&&(clearTimeout(a),a=null),e.apply(null,o)};return[(...o)=>{const c=Date.now(),l=c-r;l>=n?s(o,c):(i=o,a||(a=setTimeout(()=>{a=null,s(i)},n-l)))},()=>i&&s(i)]}const kv=(e,t,r=3)=>{let n=0;const i=FG(50,250);return PG(a=>{const s=a.loaded,o=a.lengthComputable?a.total:void 0,c=s-n,l=i(c),u=s<=o;n=s;const d={loaded:s,total:o,progress:o?s/o:void 0,bytes:c,rate:l||void 0,estimated:l&&o&&u?(o-s)/l:void 0,event:a,lengthComputable:o!=null,[t?"download":"upload"]:!0};e(d)},r)},CC=(e,t)=>{const r=e!=null;return[n=>t[0]({lengthComputable:r,total:e,loaded:n}),t[1]]},TC=e=>(...t)=>Oe.asap(()=>e(...t)),zG=ka.hasStandardBrowserEnv?function(){const e=ka.navigator&&/(msie|trident)/i.test(ka.navigator.userAgent),t=document.createElement("a");let r;function n(i){let a=i;return e&&(t.setAttribute("href",a),a=t.href),t.setAttribute("href",a),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:t.pathname.charAt(0)==="/"?t.pathname:"/"+t.pathname}}return r=n(window.location.href),function(i){const a=Oe.isString(i)?n(i):i;return a.protocol===r.protocol&&a.host===r.host}}():function(){return function(){return!0}}(),LG=ka.hasStandardBrowserEnv?{write(e,t,r,n,i,a){const s=[e+"="+encodeURIComponent(t)];Oe.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),Oe.isString(n)&&s.push("path="+n),Oe.isString(i)&&s.push("domain="+i),a===!0&&s.push("secure"),document.cookie=s.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function DG(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function UG(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function jC(e,t){return e&&!DG(t)?UG(e,t):t}const IC=e=>e instanceof Ea?{...e}:e;function Wf(e,t){t=t||{};const r={};function n(l,u,d){return Oe.isPlainObject(l)&&Oe.isPlainObject(u)?Oe.merge.call({caseless:d},l,u):Oe.isPlainObject(u)?Oe.merge({},u):Oe.isArray(u)?u.slice():u}function i(l,u,d){if(Oe.isUndefined(u)){if(!Oe.isUndefined(l))return n(void 0,l,d)}else return n(l,u,d)}function a(l,u){if(!Oe.isUndefined(u))return n(void 0,u)}function s(l,u){if(Oe.isUndefined(u)){if(!Oe.isUndefined(l))return n(void 0,l)}else return n(void 0,u)}function o(l,u,d){if(d in t)return n(l,u);if(d in e)return n(void 0,l)}const c={url:a,method:a,data:a,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:o,headers:(l,u)=>i(IC(l),IC(u),!0)};return Oe.forEach(Object.keys(Object.assign({},e,t)),function(l){const u=c[l]||i,d=u(e[l],t[l],l);Oe.isUndefined(d)&&u!==o||(r[l]=d)}),r}const OC=e=>{const t=Wf({},e);let{data:r,withXSRFToken:n,xsrfHeaderName:i,xsrfCookieName:a,headers:s,auth:o}=t;t.headers=s=Ea.from(s),t.url=xC(jC(t.baseURL,t.url),e.params,e.paramsSerializer),o&&s.set("Authorization","Basic "+btoa((o.username||"")+":"+(o.password?unescape(encodeURIComponent(o.password)):"")));let c;if(Oe.isFormData(r)){if(ka.hasStandardBrowserEnv||ka.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if((c=s.getContentType())!==!1){const[l,...u]=c?c.split(";").map(d=>
vendor: 4,366 bytes, line 10
10d.trim()).filter(Boolean):[];s.setContentType([l||"multipart/form-data",...u].join("; "))}}if(ka.hasStandardBrowserEnv&&(n&&Oe.isFunction(n)&&(n=n(t)),n||n!==!1&&zG(t.url))){const l=i&&a&&LG.read(a);l&&s.set(i,l)}return t},qG=typeof XMLHttpRequest<"u",VG=qG&&function(e){return new Promise(function(t,r){const n=OC(e);let i=n.data;const a=Ea.from(n.headers).normalize();let{responseType:s,onUploadProgress:o,onDownloadProgress:c}=n,l,u,d,p,w;function O(){p&&p(),w&&w(),n.cancelToken&&n.cancelToken.unsubscribe(l),n.signal&&n.signal.removeEventListener("abort",l)}let I=new XMLHttpRequest;I.open(n.method.toUpperCase(),n.url,!0),I.timeout=n.timeout;function R(){if(!I)return;const j=Ea.from("getAllResponseHeaders"in I&&I.getAllResponseHeaders()),N={data:!s||s==="text"||s==="json"?I.responseText:I.response,status:I.status,statusText:I.statusText,headers:j,config:e,request:I};AC(function(P){t(P),O()},function(P){r(P),O()},N),I=null}"onloadend"in I?I.onloadend=R:I.onreadystatechange=function(){!I||I.readyState!==4||I.status===0&&!(I.responseURL&&I.responseURL.indexOf("file:")===0)||setTimeout(R)},I.onabort=function(){I&&(r(new Xt("Request aborted",Xt.ECONNABORTED,e,I)),I=null)},I.onerror=function(){r(new Xt("Network Error",Xt.ERR_NETWORK,e,I)),I=null},I.ontimeout=function(){let j=n.timeout?"timeout of "+n.timeout+"ms exceeded":"timeout exceeded";const N=n.transitional||SC;n.timeoutErrorMessage&&(j=n.timeoutErrorMessage),r(new Xt(j,N.clarifyTimeoutError?Xt.ETIMEDOUT:Xt.ECONNABORTED,e,I)),I=null},i===void 0&&a.setContentType(null),"setRequestHeader"in I&&Oe.forEach(a.toJSON(),function(j,N){I.setRequestHeader(N,j)}),Oe.isUndefined(n.withCredentials)||(I.withCredentials=!!n.withCredentials),s&&s!=="json"&&(I.responseType=n.responseType),c&&([d,w]=kv(c,!0),I.addEventListener("progress",d)),o&&I.upload&&([u,p]=kv(o),I.upload.addEventListener("progress",u),I.upload.addEventListener("loadend",p)),(n.cancelToken||n.signal)&&(l=j=>{I&&(r(!j||j.type?new Xd(null,e,I):j),I.abort(),I=null)},n.cancelToken&&n.cancelToken.subscribe(l),n.signal&&(n.signal.aborted?l():n.signal.addEventListener("abort",l)));const C=NG(n.url);if(C&&ka.protocols.indexOf(C)===-1){r(new Xt("Unsupported protocol "+C+":",Xt.ERR_BAD_REQUEST,e));return}I.send(i||null)})},ZG=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let n=new AbortController,i;const a=function(l){if(!i){i=!0,o();const u=l instanceof Error?l:this.reason;n.abort(u instanceof Xt?u:new Xd(u instanceof Error?u.message:u))}};let s=t&&setTimeout(()=>{s=null,a(new Xt(`timeout ${t} of ms exceeded`,Xt.ETIMEDOUT))},t);const o=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(l=>{l.unsubscribe?l.unsubscribe(a):l.removeEventListener("abort",a)}),e=null)};e.forEach(l=>l.addEventListener("abort",a));const{signal:c}=n;return c.unsubscribe=()=>Oe.asap(o),c}},$G=function*(e,t){let r=e.byteLength;if(r<t){yield e;return}let n=0,i;for(;n<r;)i=n+t,yield e.slice(n,i),n=i},HG=async function*(e,t){for await(const r of WG(e))yield*$G(r,t)},WG=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:r,value:n}=await t.read();if(r)break;yield n}}finally{await t.cancel()}},BC=(e,t,r,n)=>{const i=HG(e,t);let a=0,s,o=c=>{s||(s=!0,n&&n(c))};return new ReadableStream({async pull(c){try{const{done:l,value:u}=await i.next();if(l){o(),c.close();return}let d=u.byteLength;if(r){let p=a+=d;r(p)}c.enqueue(new Uint8Array(u))}catch(l){throw o(l),l}},cancel(c){return o(c),i.return()}},{highWaterMark:2})},Ev=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",RC=Ev&&typeof ReadableStream=="function",KG=Ev&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),NC=(e,...t)=>{try{return!!e(...t)}catch{return!1}},GG=RC&&NC(()=>{let e=!1;const t=new Request(ka.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),FC=64*1024,z6=RC&&NC(()=>Oe.isReadableStream(new Response("").body)),Mv={stream:z6&&(e=>e.body)};Ev&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!Mv[t]&&(Mv[t]=Oe.isFunction(e[t])?r=>r[t]():(r,n)=>{throw new Xt(`Response type '${t}' is not supported`,Xt.ERR_NOT_SUPPORT,n)})})})(new Response);const YG=async e=>{if(e==null)return 0;if(Oe.isBlob(e))return e.size;
vendor: 4,185 bytes, lines 10-12
10if(Oe.isSpecCompliantForm(e))return(await new Request(ka.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(Oe.isArrayBufferView(e)||Oe.isArrayBuffer(e))return e.byteLength;if(Oe.isURLSearchParams(e)&&(e=e+""),Oe.isString(e))return(await KG(e)).byteLength},XG=async(e,t)=>Oe.toFiniteNumber(e.getContentLength())??YG(t),JG=Ev&&(async e=>{let{url:t,method:r,data:n,signal:i,cancelToken:a,timeout:s,onDownloadProgress:o,onUploadProgress:c,responseType:l,headers:u,withCredentials:d="same-origin",fetchOptions:p}=OC(e);l=l?(l+"").toLowerCase():"text";let w=ZG([i,a&&a.toAbortSignal()],s),O;const I=w&&w.unsubscribe&&(()=>{w.unsubscribe()});let R;try{if(c&&GG&&r!=="get"&&r!=="head"&&(R=await XG(u,n))!==0){let Z=new Request(t,{method:"POST",body:n,duplex:"half"}),X;if(Oe.isFormData(n)&&(X=Z.headers.get("content-type"))&&u.setContentType(X),Z.body){const[re,ne]=CC(R,kv(TC(c)));n=BC(Z.body,FC,re,ne)}}Oe.isString(d)||(d=d?"include":"omit");const C="credentials"in Request.prototype;O=new Request(t,{...p,signal:w,method:r.toUpperCase(),headers:u.normalize().toJSON(),body:n,duplex:"half",credentials:C?d:void 0});let j=await fetch(O);const N=z6&&(l==="stream"||l==="response");if(z6&&(o||N&&I)){const Z={};["status","statusText","headers"].forEach(ae=>{Z[ae]=j[ae]});const X=Oe.toFiniteNumber(j.headers.get("content-length")),[re,ne]=o&&CC(X,kv(TC(o),!0))||[];j=new Response(BC(j.body,FC,re,()=>{ne&&ne(),I&&I()}),Z)}l=l||"text";let P=await Mv[Oe.findKey(Mv,l)||"text"](j,e);return!N&&I&&I(),await new Promise((Z,X)=>{AC(Z,X,{data:P,headers:Ea.from(j.headers),status:j.status,statusText:j.statusText,config:e,request:O})})}catch(C){throw I&&I(),C&&C.name==="TypeError"&&/fetch/i.test(C.message)?Object.assign(new Xt("Network Error",Xt.ERR_NETWORK,e,O),{cause:C.cause||C}):Xt.from(C,C&&C.code,e,O)}}),L6={http:dG,xhr:VG,fetch:JG};Oe.forEach(L6,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const PC=e=>`- ${e}`,QG=e=>Oe.isFunction(e)||e===null||e===!1,zC={getAdapter:e=>{e=Oe.isArray(e)?e:[e];const{length:t}=e;let r,n;const i={};for(let a=0;a<t;a++){r=e[a];let s;if(n=r,!QG(r)&&(n=L6[(s=String(r)).toLowerCase()],n===void 0))throw new Xt(`Unknown adapter '${s}'`);if(n)break;i[s||"#"+a]=n}if(!n){const a=Object.entries(i).map(([o,c])=>`adapter ${o} `+(c===!1?"is not supported by the environment":"is not available in the build"));let s=t?a.length>1?`since :
11`+a.map(PC).join(`
12`):" "+PC(a[0]):"as no adapter specified";throw new Xt("There is no suitable adapter to dispatch the request "+s,"ERR_NOT_SUPPORT")}return n},adapters:L6};function D6(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Xd(null,e)}function LC(e){return D6(e),e.headers=Ea.from(e.headers),e.data=P6.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),zC.getAdapter(e.adapter||Lm.adapter)(e).then(function(t){return D6(e),t.data=P6.call(e,e.transformResponse,t),t.headers=Ea.from(t.headers),t},function(t){return MC(t)||(D6(e),t&&t.response&&(t.response.data=P6.call(e,e.transformResponse,t.response),t.response.headers=Ea.from(t.response.headers))),Promise.reject(t)})}const DC="1.7.7",U6={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{U6[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const UC={};U6.transitional=function(e,t,r){function n(i,a){return"[Axios v"+DC+"] Transitional option '"+i+"'"+a+(r?". "+r:"")}return(i,a,s)=>{if(e===!1)throw new Xt(n(a," has been removed"+(t?" in "+t:"")),Xt.ERR_DEPRECATED);return t&&!UC[a]&&(UC[a]=!0,console.warn(n(a," has been deprecated since v"+t+" and will be removed in the near future"))),e?e(i,a,s):!0}};function eY(e,t,r){if(typeof e!="object")throw new Xt("options must be an object",Xt.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let i=n.length;for(;i-- >0;){const a=n[i],s=t[a];if(s){const o=e[a],c=o===void 0||s(o,a,e);if(c!==!0)throw new Xt("option "+a+" must be "+c,Xt.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new Xt("Unknown option "+a,Xt.ERR_BAD_OPTION)}}const q6={assertOptions:eY,validators:U6}
12,vu=q6.validators;class Kf{constructor(t){this.defaults=t,this.interceptors={request:new _C,response:new _C}}async request(t,r){try{return await this._request(t,r)}catch(n){if(n instanceof Error){let i;Error.captureStackTrace?Error.captureStackTrace(i={}):i=new Error;const a=i.stack?i.stack.replace(/^.+\n/,""):"";try{n.stack?a&&!String(n.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(n.stack+=`
13`+a):n.stack=a}catch{}}throw n}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=Wf(this.defaults,r);const{transitional:n,paramsSerializer:i,headers:a}=r;n!==void 0&&q6.assertOptions(n,{silentJSONParsing:vu.transitional(vu.boolean),forcedJSONParsing:vu.transitional(vu.boolean),clarifyTimeoutError:vu.transitional(vu.boolean)},!1),i!=null&&(Oe.isFunction(i)?r.paramsSerializer={serialize:i}:q6.assertOptions(i,{encode:vu.function,serialize:vu.function},!0)),r.method=(r.method||this.defaults.method||"get").toLowerCase();let s=a&&Oe.merge(a.common,a[r.method]);a&&Oe.forEach(["delete","get","head","post","put","patch","common"],O=>{delete a[O]}),r.headers=Ea.concat(s,a);const o=[];let c=!0;this.interceptors.request.forEach(function(O){typeof O.runWhen=="function"&&O.runWhen(r)===!1||(c=c&&O.synchronous,o.unshift(O.fulfilled,O.rejected))});const l=[];this.interceptors.response.forEach(function(O){l.push(O.fulfilled,O.rejected)});let u,d=0,p;if(!c){const O=[LC.bind(this),void 0];for(O.unshift.apply(O,o),O.push.apply(O,l),p=O.length,u=Promise.resolve(r);d<p;)u=u.then(O[d++],O[d++]);return u}p=o.length;let w=r;for(d=0;d<p;){const O=o[d++],I=o[d++];try{w=O(w)}
vendor: 1,906 bytes, line 13
13catch(R){I.call(this,R);break}}try{u=LC.call(this,w)}catch(O){return Promise.reject(O)}for(d=0,p=l.length;d<p;)u=u.then(l[d++],l[d++]);return u}getUri(t){t=Wf(this.defaults,t);const r=jC(t.baseURL,t.url);return xC(r,t.params,t.paramsSerializer)}}Oe.forEach(["delete","get","head","options"],function(e){Kf.prototype[e]=function(t,r){return this.request(Wf(r||{},{method:e,url:t,data:(r||{}).data}))}}),Oe.forEach(["post","put","patch"],function(e){function t(r){return function(n,i,a){return this.request(Wf(a||{},{method:e,headers:r?{"Content-Type":"multipart/form-data"}:{},url:n,data:i}))}}Kf.prototype[e]=t(),Kf.prototype[e+"Form"]=t(!0)});class V6{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(i){r=i});const n=this;this.promise.then(i=>{if(!n._listeners)return;let a=n._listeners.length;for(;a-- >0;)n._listeners[a](i);n._listeners=null}),this.promise.then=i=>{let a;const s=new Promise(o=>{n.subscribe(o),a=o}).then(i);return s.cancel=function(){n.unsubscribe(a)},s},t(function(i,a,s){n.reason||(n.reason=new Xd(i,a,s),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const t=new AbortController,r=n=>{t.abort(n)};return this.subscribe(r),t.signal.unsubscribe=()=>this.unsubscribe(r),t.signal}static source(){let t;return{token:new V6(function(r){t=r}),cancel:t}}}function tY(e){return function(t){return e.apply(null,t)}}function rY(e){return Oe.isObject(e)&&e.isAxiosError===!0}const Z6={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,Parti
13alContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Z6).forEach(([e,t])=>{Z6[t]=e});function qC(e){const t=new Kf(e),r=iC(Kf.prototype.request,t);return Oe.extend(r,Kf.prototype,t,{allOwnKeys:!0}),Oe.extend(r,t,null,{allOwnKeys:!0}),r.create=function(n){return qC(Wf(e,n))},r}const yr=qC(Lm);yr.Axios=Kf,yr.CanceledError=Xd,yr.CancelToken=V6,yr.isCancel=MC,yr.VERSION=DC,yr.toFormData=_v,yr.AxiosError=Xt,yr.Cancel=yr.CanceledError,yr.all=function(e){return Promise.all(e)},yr.spread=tY,yr.isAxiosError=rY,yr.mergeConfig=Wf,yr.AxiosHeaders=Ea,yr.formToJSON=e=>
13kC(Oe.isHTMLForm(e)?new FormData(e):e),yr.getAdapter=zC.getAdapter,yr.HttpStatusCode=Z6,yr.default=yr;const Vi="https://api.aztecexplorer.xyz",nY="https://mainnet-api.aztecexplorer.xyz",iY="https://testnet-api.aztecexplorer.xyz",aY="https://devnet-api.aztecexplorer.xyz",Zi=e=>e===ro.MAINNET?nY:e===ro.TESTNET?iY:aY,sY=async(e,t)=>{try{const r=t?Zi(t):Vi;return(await yr.get(`${r}/blocks/getByHash/${e}`)).data}catch(r){throw console.error("Error fetching block by hash:",r),r}},VC=async(e,t,r={},n)=>{try{const i=n?Zi(n):Vi,a={page:e,limit:t},{sort:s,order:o,startTimestamp:c,endTimestamp:l,minTotalFees:u,maxTotalFees:d,minTxCount:p,maxTxCount:w}=r;return s&&(a.sort=s),o&&(a.order=o),c&&(a.startTimestamp=c),l&&(a.endTimestamp=l),u&&(a.minTotalFees=u),d&&(a.maxTotalFees=d),p&&(a.minTxCount=p),w&&(a.maxTxCount=w),(await yr.get(`${i}/blocks/get`,{params:a})).data}catch(i){throw console.error("Error fetching blocks:",i),i}},oY=async(e,t)=>{try{const r=t?Zi(t):Vi;return(await yr.get(`${r}/transactions/getByBlockNumber/${e}`)).data}catch(r){throw console.error("Error fetching transactions by block number:",r),r}},ZC=async(e,t)=>{try{const r=t?Zi(t):Vi;return(await yr.get(`${r}/pendingTransactions/getByHash/${e}`)).data}catch(r){throw console.error("Error fetching pending transaction by hash:",r),r}},$C=async(e,t)=>{try{const r=t?Zi(t):Vi;return(await yr.get(`${r}/transactions/getByHash/${e}`)).data}catch(r){throw console.error("Error fetching transaction by hash:",r),r}},HC=async(e,t,r={},n)=>{try{const i=n?Zi(n):Vi,a={page:e,limit:t},{sort:s,order:o,startTimestamp:c,endTimestamp:l,minIndex:u,maxIndex:d,minTransactionFee:p,maxTransactionFee:w,minBlockNumber:O,maxBlockNumber:I}=r;return s&&(a.sort=s),o&&(a.order=o),c&&(a.startTimestamp=c),l&&(a.endTimestamp=l),u&&(a.minIndex=u),d&&(a.maxIndex=d),p&&(a.minTransactionFee=p),w&&(a.maxTransactionFee=w),O&&(a.minBlockNumber=O),I&&(a.maxBlockNumber=I),(await yr.get(`${i}/transactions/get`,{params:a})).data}catch(i){throw console.error("Error fetching transactions:",i),i}},lY=async e=>{try{const t=e?Zi(e):Vi;return(await yr.get(`${t}/blocks/count`)).data}catch(t){throw console.error("Error fetching transactions:",t),t}},cY=async e=>{try{const t=e?Zi(e):Vi;return(await yr.get(`${t}/transactions/count`)).data}catch(t){throw console.error("Error fetching transactions:",t),t}},uY=async(e,t)=>{try{const r=t?Zi(t):Vi;return(await yr.get(`${r}/accounts/getByAddress/${e}`)).data}catch(r){throw console.error("Error fetching block by number:",r),r}},fY=async(e="1",t="10",r={},n)=>{try{const i=n?Zi(n):Vi,a={page:e,limit:t},{sort:s="blockNumber",order:o="desc",minVersion:c,maxVersion:l,minBlockNumber:u,maxBlockNumber:d,startCreationTimestamp:p,endCreationTimestamp:w,...O}=r;return s&&(a.sort=s),o&&(a.order=o),c&&(a.minVersion=c),l&&(a.maxVersion=l),u&&(a.minBlockNumber=u),d&&(a.maxBlockNumber=d),p&&(a.startCreationTimestamp=p),w&&(a.endCreationTimestamp=w),Object.keys(O).forEach(I=>{a[I]=O[I]}),(await yr.get(`${i}/accounts/get`,{params:a})).data}catch(i){throw console.error("Error fetching addresses:",i),i}},hY=async e=>{try{const t=e?Zi(e):Vi;return(await yr.get(`${t}/accounts/count`)).data}catch(t){throw console.error("Error fetching address count:",t),t}},dY=async(e,t)=>{try{const r=t?Zi(t):Vi;return(await yr.get(`${r}/contractClass/getById/${e}`)).data}catch(r){throw console.error("Error fetching class:",r),r}},pY=async(e="1",t="10",r={},n)=>{try{const i=n?Zi(n):Vi,a={page:e,limit:t},{sort:s="blockNumber",order:o="desc",minVersion:c,maxVersion:l,minBlockNumber:u,maxBlockNumber:d,startCreationTimestamp:p,endCreationTimestamp:w,...O}=r;return s&&(a.sort=s),o&&(a.order=o),c&&(a.minVersion=c),l&&(a.maxVersion=l),u&&(a.minBlockNumber=u),d&&(a.maxBlockNumber=d),p&&(a.startCreationTimestamp=p),w&&(a.endCreationTimestamp=w),Object.keys(O).forEach(I=>{a[I]=O[I]}),(await yr.get(`${i}/contractClass/get`,{params:a})).data}catch(i){throw console.error("Error fetching classes:",i),i}},mY=async e=>{try{const t=e?Zi(e):Vi;return(await yr.get(`${t}/contractClass/count`)).data}catch(t){throw console.error("Error fetching contract class count:",t),t}},gY=async(e,t)=>{try{const r=t?Zi(t):Vi;return(await yr.get(`${r}/search/${e}`)).data}catch(r){throw console.error("Error fetching block by hash:",r),r}},bY=async e=>{try{const t=e?Zi(e):Vi;return(await yr.get(`${t}/stats`)).data}catch(t){throw console.error(`Error fetching stats for ${e} :`,t),t}};function WC(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(r=WC(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function KC(){for(var e,t,r=0,n="",i=arguments.length;r<i;r++)(e=arguments[r])&&(t=WC(e))&&(n&&(n+=" "),n+=t);return n}const GC=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,YC=KC,Av=(e,t)=>
vendor: 6,109 bytes, line 13
13r=>{var n;if((t==null?void 0:t.variants)==null)return YC(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:i,defaultVariants:a}=t,s=Object.keys(i).map(l=>{const u=r==null?void 0:r[l],d=a==null?void 0:a[l];if(u===null)return null;const p=GC(u)||GC(d);return i[l][p]}),o=r&&Object.entries(r).reduce((l,u)=>{let[d,p]=u;return p===void 0||(l[d]=p),l},{}),c=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((l,u)=>{let{class:d,className:p,...w}=u;return Object.entries(w).every(O=>{let[I,R]=O;return Array.isArray(R)?R.includes({...a,...o}[I]):{...a,...o}[I]===R})?[...l,d,p]:l},[]);return YC(e,s,c,r==null?void 0:r.class,r==null?void 0:r.className)},yY=(e,t)=>{const r=new Array(e.length+t.length);for(let n=0;n<e.length;n++)r[n]=e[n];for(let n=0;n<t.length;n++)r[e.length+n]=t[n];return r},vY=(e,t)=>({classGroupId:e,validator:t}),XC=(e=new Map,t=null,r)=>({nextPart:e,validators:t,classGroupId:r}),Cv="-",JC=[],wY="arbitrary..",xY=e=>{const t=SY(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:i=>{if(i.startsWith("[")&&i.endsWith("]"))return _Y(i);const a=i.split(Cv),s=a[0]===""&&a.length>1?1:0;return QC(a,s,t)},getConflictingClassGroupIds:(i,a)=>{if(a){const s=n[i],o=r[i];return s?o?yY(o,s):s:o||JC}return r[i]||JC}}},QC=(e,t,r)=>{if(e.length-t===0)return r.classGroupId;const n=e[t],i=r.nextPart.get(n);if(i){const c=QC(e,t+1,i);if(c)return c}const a=r.validators;if(a===null)return;const s=t===0?e.join(Cv):e.slice(t).join(Cv),o=a.length;for(let c=0;c<o;c++){const l=a[c];if(l.validator(s))return l.classGroupId}},_Y=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),r=t.indexOf(":"),n=t.slice(0,r);return n?wY+n:void 0})(),SY=e=>{const{theme:t,classGroups:r}=e;return kY(r,t)},kY=(e,t)=>{const r=XC();for(const n in e){const i=e[n];$6(i,r,n,t)}return r},$6=(e,t,r,n)=>{const i=e.length;for(let a=0;a<i;a++){const s=e[a];EY(s,t,r,n)}},EY=(e,t,r,n)=>{if(typeof e=="string"){MY(e,t,r);return}if(typeof e=="function"){AY(e,t,r,n);return}CY(e,t,r,n)},MY=(e,t,r)=>{const n=e===""?t:eT(t,e);n.classGroupId=r},AY=(e,t,r,n)=>{if(TY(e)){$6(e(n),t,r,n);return}t.validators===null&&(t.validators=[]),t.validators.push(vY(r,e))},CY=(e,t,r,n)=>{const i=Object.entries(e),a=i.length;for(let s=0;s<a;s++){const[o,c]=i[s];$6(c,eT(t,o),r,n)}},eT=(e,t)=>{let r=e;const n=t.split(Cv),i=n.length;for(let a=0;a<i;a++){const s=n[a];let o=r.nextPart.get(s);o||(o=XC(),r.nextPart.set(s,o)),r=o}return r},TY=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,jY=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=Object.create(null),n=Object.create(null);const i=(a,s)=>{r[a]=s,t++,t>e&&(t=0,n=r,r=Object.create(null))};return{get(a){let s=r[a];if(s!==void 0)return s;if((s=n[a])!==void 0)return i(a,s),s},set(a,s){a in r?r[a]=s:i(a,s)}}},H6="!",tT=":",IY=[],rT=(e,t,r,n,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:r,maybePostfixModifierPosition:n,isExternal:i}),OY=e=>{const{prefix:t,experimentalParseClassName:r}=e;let n=i=>{const a=[];let s=0,o=0,c=0,l;const u=i.length;for(let I=0;I<u;I++){const R=i[I];if(s===0&&o===0){if(R===tT){a.push(i.slice(c,I)),c=I+1;continue}if(R==="/"){l=I;continue}}R==="["?s++:R==="]"?s--:R==="("?o++:R===")"&&o--}const d=a.length===0?i:i.slice(c);let p=d,w=!1;d.endsWith(H6)?(p=d.slice(0,-1),w=!0):d.startsWith(H6)&&(p=d.slice(1),w=!0);const O=l&&l>c?l-c:void 0;return rT(a,w,p,O)};if(t){const i=t+tT,a=n;n=s=>s.startsWith(i)?a(s.slice(i.length)):rT(IY,!1,s,void 0,!0)}if(r){const i=n;n=a=>r({className:a,parseClassName:i})}return n},BY=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((r,n)=>{t.set(r,1e6+n)}),r=>{const n=[];let i=[];for(let a=0;a<r.length;a++){const s=r[a],o=s[0]==="[",c=t.has(s);o||c?(i.length>0&&(i.sort(),n.push(...i),i=[]),n.push(s)):i.push(s)}return i.length>0&&(i.sort(),n.push(...i)),n}},RY=e=>({cache:jY(e.cacheSize),parseClassName:OY(e),sortModifiers:BY(e),...xY(e)}),NY=/\s+/,FY=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:i,sortModifiers:a}=t,s=[],o=e.trim().split(NY);let c="";for(let l=o.length-1;l>=0;l-=1){const u=o[l],{isExternal:d,modifiers:p,hasImportantModifier:w,baseClassName:O,maybePostfixModifierPosition:I}=r(u);if(d){c=u+(c.length>0?" "+c:c);continue}let R=!!I,C=n(R?O.substring(0,I):O);if(!C){if(!R){c=u+(c.length>0?" "+c:c);continue}if(C=n(O),!C){c=u+(c.length>0?" "+c:c);continue}R=!1}const j=p.length===0?"":p.length===1?p[0]:a(p).join(":"),N=w?j+H6:j,P=N+C;if(s.indexOf(P)>-1)continue;s.push(P);const Z=i(C,R);for(let X=0;X<Z.length;++X){const re=Z[X];s.push(N+re)}c=u+(c.length>0?" "+c:c)}return c},PY=(...e)=>{let t=0,r,n,i="";for(;t<e.length;)(r=e[t++])&&(n=nT(r))&&(i&&(i+=" "),i+=n);return i},nT=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=nT(e[n]))&&(r&&(r+=" "),r+=t);return r},zY=(e,...t)=>{let r,n,i,a;const s=c=>{const l=t.reduce((u,d)=>d(u),e());return r=RY(l),n=r.cache.get,i=r.cache.set,a=o,o(c)},o=c=>{const l=n(c);if(l)return l;const u=FY(c,r);return i(c,u),u};return a=s,(...c)=>a(PY(...c))},LY=[],ni=e=>{const t=r=>r[e]||LY;return t.isThemeGetter=!0,t},iT=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,aT=/^\((?:(\w[\w-]*):)?(.+)\)$/i,DY=/^\d+\/\d+$/,UY=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,qY=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,VY=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,ZY=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,$Y=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Jd=e=>DY.test(e),sr=e=>!!e&&!Number.isNaN(Number(e)),wu=e=>!!e&&Number.isInteger(Number(e)),W6=e=>e.endsWith("%")&&sr(e.slice(0,-1)),ic=e=>UY.test(e),HY=()=>!0,WY=e=>qY.test(e)&&!VY.test(e),sT=()=>!1,KY=e=>ZY.test(e),GY=e=>$Y.test(e),YY=e=>!bt(e)&&!yt(e),XY=e=>Qd(e,fT,sT),bt=e=>iT.test(e),Gf=e=>Qd(e,hT,WY),K6=e=>Qd(e,rX,sr),oT=e=>Qd(e,cT,sT),JY=e=>Qd(e,uT,GY),Tv=e=>Qd(e,dT,KY),yt=e=>aT.test(e),Um=e=>e0(e,hT),QY=e=>e0(e,nX),lT=e=>e0(e,cT),eX=e=>e0(e,fT),tX=e=>e0(e,uT),jv=e=>e0(e,dT,!0),Qd=(e,t,r)=>{const n=iT.exec(e);
vendor: 4,489 bytes, line 13
13return n?n[1]?t(n[1]):r(n[2]):!1},e0=(e,t,r=!1)=>{const n=aT.exec(e);return n?n[1]?t(n[1]):r:!1},cT=e=>e==="position"||e==="percentage",uT=e=>e==="image"||e==="url",fT=e=>e==="length"||e==="size"||e==="bg-size",hT=e=>e==="length",rX=e=>e==="number",nX=e=>e==="family-name",dT=e=>e==="shadow",iX=()=>{const e=ni("color"),t=ni("font"),r=ni("text"),n=ni("font-weight"),i=ni("tracking"),a=ni("leading"),s=ni("breakpoint"),o=ni("container"),c=ni("spacing"),l=ni("radius"),u=ni("shadow"),d=ni("inset-shadow"),p=ni("text-shadow"),w=ni("drop-shadow"),O=ni("blur"),I=ni("perspective"),R=ni("aspect"),C=ni("ease"),j=ni("animate"),N=()=>["auto","avoid","all","avoid-page","page","left","right","column"],P=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],Z=()=>[...P(),yt,bt],X=()=>["auto","hidden","clip","visible","scroll"],re=()=>["auto","contain","none"],ne=()=>[yt,bt,c],ae=()=>[Jd,"full","auto",...ne()],ue=()=>[wu,"none","subgrid",yt,bt],m=()=>["auto",{span:["full",wu,yt,bt]},wu,yt,bt],A=()=>[wu,"auto",yt,bt],f=()=>["auto","min","max","fr",yt,bt],g=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],_=()=>["start","end","center","stretch","center-safe","end-safe"],B=()=>["auto",...ne()],T=()=>[Jd,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...ne()],S=()=>[e,yt,bt],h=()=>[...P(),lT,oT,{position:[yt,bt]}],x=()=>["no-repeat",{repeat:["","x","y","space","round"]}],v=()=>["auto","cover","contain",eX,XY,{size:[yt,bt]}],F=()=>[W6,Um,Gf],Q=()=>["","none","full",l,yt,bt],G=()=>["",sr,Um,Gf],J=()=>["solid","dashed","dotted","double"],Y=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],V=()=>[sr,W6,lT,oT],W=()=>["","none",O,yt,bt],ce=()=>["none",sr,yt,bt],pe=()=>["none",sr,yt,bt],ee=()=>[sr,yt,bt],se=()=>[Jd,"full",...ne()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[ic],breakpoint:[ic],color:[HY],container:[ic],"drop-shadow":[ic],ease:["in","out","in-out"],font:[YY],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[ic],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[ic],shadow:[ic],spacing:["px",sr],text:[ic],"text-shadow":[ic],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Jd,bt,yt,R]}],container:["container"],columns:[{columns:[sr,bt,yt,o]}],"break-after":[{"break-after":N()}],"break-before":[{"break-before":N()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:Z()}],overflow:[{overflow:X()}],"overflow-x":[{"overflow-x":X()}],"overflow-y":[{"overflow-y":X()}],overscroll:[{overscroll:re()}],"overscroll-x":[{"overscroll-x":re()}],"overscroll-y":[{"overscroll-y":re()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:ae()}],"inset-x":[{"inset-x":ae()}],"inset-y":[{"inset-y":ae()}],start:[{start:ae()}],end:[{end:ae()}],top:[{top:ae()}],right:[{right:ae()}],bottom:[{bottom:ae()}],left:[{left:ae()}],visibility:["visible","invisible","collapse"],z:[{z:[wu,"auto",yt,bt]}],basis:[{basis:[Jd,"full","auto",o,...ne()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[sr,Jd,"auto","initial","none",bt]}],grow:[{grow:["",sr,yt,bt]}],shrink:[{shrink:["",sr,yt,bt]}],order:[{order:[wu,"first","last","none",yt,bt]}],"grid-cols":[{"grid-cols":ue()}],"col-start-end":[{col:m()}],"col-start":[{"col-start":A()}
vendor: 11,029 bytes, line 13
13],"col-end":[{"col-end":A()}],"grid-rows":[{"grid-rows":ue()}],"row-start-end":[{row:m()}],"row-start":[{"row-start":A()}],"row-end":[{"row-end":A()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":f()}],"auto-rows":[{"auto-rows":f()}],gap:[{gap:ne()}],"gap-x":[{"gap-x":ne()}],"gap-y":[{"gap-y":ne()}],"justify-content":[{justify:[...g(),"normal"]}],"justify-items":[{"justify-items":[..._(),"normal"]}],"justify-self":[{"justify-self":["auto",..._()]}],"align-content":[{content:["normal",...g()]}],"align-items":[{items:[..._(),{baseline:["","last"]}]}],"align-self":[{self:["auto",..._(),{baseline:["","last"]}]}],"place-content":[{"place-content":g()}],"place-items":[{"place-items":[..._(),"baseline"]}],"place-self":[{"place-self":["auto",..._()]}],p:[{p:ne()}],px:[{px:ne()}],py:[{py:ne()}],ps:[{ps:ne()}],pe:[{pe:ne()}],pt:[{pt:ne()}],pr:[{pr:ne()}],pb:[{pb:ne()}],pl:[{pl:ne()}],m:[{m:B()}],mx:[{mx:B()}],my:[{my:B()}],ms:[{ms:B()}],me:[{me:B()}],mt:[{mt:B()}],mr:[{mr:B()}],mb:[{mb:B()}],ml:[{ml:B()}],"space-x":[{"space-x":ne()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":ne()}],"space-y-reverse":["space-y-reverse"],size:[{size:T()}],w:[{w:[o,"screen",...T()]}],"min-w":[{"min-w":[o,"screen","none",...T()]}],"max-w":[{"max-w":[o,"screen","none","prose",{screen:[s]},...T()]}],h:[{h:["screen","lh",...T()]}],"min-h":[{"min-h":["screen","lh","none",...T()]}],"max-h":[{"max-h":["screen","lh",...T()]}],"font-size":[{text:["base",r,Um,Gf]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[n,yt,K6]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",W6,bt]}],"font-family":[{font:[QY,bt,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[i,yt,bt]}],"line-clamp":[{"line-clamp":[sr,"none",yt,K6]}],leading:[{leading:[a,...ne()]}],"list-image":[{"list-image":["none",yt,bt]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",yt,bt]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:S()}],"text-color":[{text:S()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...J(),"wavy"]}],"text-decoration-thickness":[{decoration:[sr,"from-font","auto",yt,Gf]}],"text-decoration-color":[{decoration:S()}],"underline-offset":[{"underline-offset":[sr,"auto",yt,bt]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:ne()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",yt,bt]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",yt,bt]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:h()}],"bg-repeat":[{bg:x()}],"bg-size":[{bg:v()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},wu,yt,bt],radial:["",yt,bt],conic:[wu,yt,bt]},tX,JY]}],"bg-color":[{bg:S()}],"gradient-from-pos":[{from:F()}],"gradient-via-pos":[{via:F()}],"gradient-to-pos":[{to:F()}],"gradient-from":[{from:S()}],"gradient-via":[{via:S()}],"gradient-to":[{to:S()}],rounded:[{rounded:Q()}],"rounded-s":[{"rounded-s":Q()}],"rounded-e":[{"rounded-e":Q()}],"rounded-t":[{"rounded-t":Q()}],"rounded-r":[{"rounded-r":Q()}],"rounded-b":[{"rounded-b":Q()}],"rounded-l":[{"rounded-l":Q()}],"rounded-ss":[{"rounded-ss":Q()}],"rounded-se":[{"rounded-se":Q()}],"rounded-ee":[{"rounded-ee":Q()}],"rounded-es":[{"rounded-es":Q()}],"rounded-tl":[{"rounded-tl":Q()}],"rounded-tr":[{"rounded-tr":Q()}],"rounded-br":[{"rounded-br":Q()}],"rounded-bl":[{"rounded-bl":Q()}],"border-w":[{border:G()}],"border-w-x":[{"border-x":G()}],"border-w-y":[{"border-y":G()}],"border-w-s":[{"border-s":G()}],"border-w-e":[{"border-e":G()}],"border-w-t":[{"border-t":G()}],"border-w-r":[{"border-r":G()}],"border-w-b":[{"border-b":G()}],"border-w-l":[{"border-l":G()}],"divide-x":[{"divide-x":G()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":G()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...J(),"hidden","none"]}],"divide-style":[{divide:[...J(),"hidden","none"]}],"border-color":[{border:S()}],"border-color-x":[{"border-x":S()}],"border-color-y":[{"border-y":S()}],"border-color-s":[{"border-s":S()}],"border-color-e":[{"border-e":S()}],"border-color-t":[{"border-t":S()}],"border-color-r":[{"border-r":S()}],"border-color-b":[{"border-b":S()}],"border-color-l":[{"border-l":S()}],"divide-color":[{divide:S()}],"outline-style":[{outline:[...J(),"none","hidden"]}],"outline-offset":[{"outline-offset":[sr,yt,bt]}],"outline-w":[{outline:["",sr,Um,Gf]}],"outline-color":[{outline:S()}],shadow:[{shadow:["","none",u,jv,Tv]}],"shadow-color":[{shadow:S()}],"inset-shadow":[{"inset-shadow":["none",d,jv,Tv]}],"inset-shadow-color":[{"inset-shadow":S()}],"ring-w":[{ring:G()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:S()}],"ring-offset-w":[{"ring-offset":[sr,Gf]}],"ring-offset-color":[{"ring-offset":S()}],"inset-ring-w":[{"inset-ring":G()}],"inset-ring-color":[{"inset-ring":S()}],"text-shadow":[{"text-shadow":["none",p,jv,Tv]}],"text-shadow-color":[{"text-shadow":S()}],opacity:[{opacity:[sr,yt,bt]}],"mix-blend":[{"mix-blend":[...Y(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":Y()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[sr]}],"mask-image-linear-from-pos":[{"mask-linear-from":V()}],"mask-image-linear-to-pos":[{"mask-linear-to":V()}],"mask-image-linear-from-color":[{"mask-linear-from":S()}],"mask-image-linear-to-color":[{"mask-linear-to":S()}],"mask-image-t-from-pos":[{"mask-t-from":V()}],"mask-image-t-to-pos":[{"mask-t-to":V()}],"mask-image-t-from-color":[{"mask-t-from":S()}],"mask-image-t-to-color":[{"mask-t-to":S()}],"mask-image-r-from-pos":[{"mask-r-from":V()}],"mask-image-r-to-pos":[{"mask-r-to":V()}],"mask-image-r-from-color":[{"mask-r-from":S()}],"mask-image-r-to-color":[{"mask-r-to":S()}],"mask-image-b-from-pos":[{"mask-b-from":V()}],"mask-image-b-to-pos":[{"mask-b-to":V()}],"mask-image-b-from-color":[{"mask-b-from":S()}],"mask-image-b-to-color":[{"mask-b-to":S()}],"mask-image-l-from-pos":[{"mask-l-from":V()}],"mask-image-l-to-pos":[{"mask-l-to":V()}],"mask-image-l-from-color":[{"mask-l-from":S()}],"mask-image-l-to-color":[{"mask-l-to":S()}],"mask-image-x-from-pos":[{"mask-x-from":V()}],"mask-image-x-to-pos":[{"mask-x-to":V()}],"mask-image-x-from-color":[{"mask-x-from":S()}],"mask-image-x-to-color":[{"mask-x-to":S()}],"mask-image-y-from-pos":[{"mask-y-from":V()}],"mask-image-y-to-pos":[{"mask-y-to":V()}],"mask-image-y-from-color":[{"mask-y-from":S()}],"mask-image-y-to-color":[{"mask-y-to":S()}],"mask-image-radial":[{"mask-radial":[yt,bt]}],"mask-image-radial-from-pos":[{"mask-radial-from":V()}],"mask-image-radial-to-pos":[{"mask-radial-to":V()}],"mask-image-radial-from-color":[{"mask-radial-from":S()}],"mask-image-radial-to-color":[{"mask-radial-to":S()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":P()}],"mask-image-conic-pos":[{"mask-conic":[sr]}],"mask-image-conic-from-pos":[{"mask-conic-from":V()}],"mask-image-conic-to-pos":[{"mask-conic-to":V()}],"mask-image-conic-from-color":[{"mask-conic-from":S()}],"mask-image-conic-to-color":[{"mask-conic-to":S()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:h()}],"mask-repeat":[{mask:x()}],"mask-size":[{mask:v()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",yt,bt]}],filter:[{filter:["","none",yt,bt]}],blur:[{blur:W()}],brightness:[{brightness:[sr,yt,bt]}],contrast:[{contrast:[sr,yt,bt]}],"drop-shadow":[{"drop-shadow":["","none",w,jv,Tv]}],"drop-shadow-color":[{"drop-shadow":S()}],grayscale:[{grayscale:["",sr,yt,bt]}],"hue-rotate":[{"hue-rotate":[sr,yt,bt]}],invert:[{invert:["",sr,yt,bt]}],saturate:[{saturate:[sr,yt,bt]}],sepia:[{sepia:["",sr,yt,bt]}],"backdrop-filter":[{"backdrop-filter":["","none",yt,bt]}],"backdrop-blur":[{"backdrop-blur":W()}],"backdrop-brightness":[{"backdrop-brightness":[sr,yt,bt]}],"backdrop-contrast":[{"backdrop-contrast":[sr,yt,bt]}],"backdrop-grayscale":[{"backdrop-grayscale":["",sr,yt,bt]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[sr,yt,bt]}],"backdrop-invert":[{"backdrop-invert":["",sr,yt,bt]}],"backdrop-opacity":[{"backdrop-opacity":[sr,yt,bt]}],"backdrop-saturate":[{"backdrop-saturate":[sr,yt,bt]}],"backdrop-sepia":[{"backdrop-sepia":["",sr,yt,bt]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":ne()}],"border-spacing-x":[{"border-spacing-x":ne()}],"border-spacing-y":[{"border-spacing-y":ne()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",yt,bt]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[sr,"initial",yt,bt]}],ease:[{ease:["linear","initial",C,yt,bt]}],delay:[{delay:[sr,yt,bt]}],animate:[{animate:["none",j,yt,bt]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[I,yt,bt]}],"perspective-origin":[{"perspective-origin":Z()}],rotate:[{rotate:ce()}],"rotate-x":[{"rotate-x":ce()}],"rotate-y":[{"rotate-y":ce()}],"rotate-z":[{"rotate-z":ce()}],scale:[{scale:pe()}],"scale-x":[{"scale-x":pe()}],"scale-y":[{"scale-y":pe()}],"scale-z":[{"scale-z":pe()}],"scale-3d":["scale-3d"],skew:[{skew:ee()}],"skew-x":[{"skew-x":ee()}],"skew-y":[{"skew-y":ee()}],transform:[{transform:[yt,bt,"","none","gpu","cpu"]}],"transform-origin":[{origin:Z()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:se()}],"translate-x":[{"translate-x":se()}],"translate-y":[{"translate-y":se()}],"translate-z":[{"translate-z":se()}],"translate-none":["translate-none"],accent:[{accent:S()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:S()}
13],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",yt,bt]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":ne()}],"scroll-mx":[{"scroll-mx":ne()}],"scroll-my":[{"scroll-my":ne()}],"scroll-ms":[{"scroll-ms":ne()}],"scroll-me":[{"scroll-me":ne()}],"scroll-mt":[{"scroll-mt":ne()}],"scroll-mr":[{"scroll-mr":ne()}],"scroll-mb":[{"scroll-mb":ne()}],"scroll-ml":[{"scroll-ml":ne()}],"scroll-p":[{"scroll-p":ne()}],"scroll-px":[{"scroll-px":ne()}],"scroll-py":[{"scroll-py":ne()}],"scroll-ps":[{"scroll-ps":ne()}],"scroll-pe":[{"scroll-pe":ne()}],"scroll-pt":[{"scroll-pt":ne()}],"scroll-pr":[{"scroll-pr":ne()}],"scroll-pb":[{"scroll-pb":ne()}],"scroll-pl":[{"scroll-pl":ne()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",yt,bt]}],fill:[{fill:["none",...S()]}],"stroke-w":[{stroke:[sr,Um,Gf,K6]}],stroke:[{stroke:["none",...S()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},aX=zY(iX);function mt(...e){return aX(KC(e))}function tl(e,t=5,r=5){return e?e.length<=t+r+3?e:`${e.slice(0,t)}...${e.slice(-r)}`:""}const Xa={brand:{purple:"#8C7EFF",pink:"#EDA1FF",blue:"#466CF7",orange:"#FF7764",green:"#31A67B",yellow:"#FFA43B",red:"#FF3B3F"},text:{muted:"#9CA3AF",mutedAlpha50:"rgba(156, 163, 175, 0.5)"},surface:{border:"#1f212d"},chart:{tooltipBg:"rgba(0, 0, 0, 0.8)",tooltipBorder:"rgba(255, 255, 255, 0.1)",white:"#fff"}},sX=Av("inline-flex items-center justify-center text-xs font-medium transition-colors",{variants:{variant:{purple:"bg-brand-purple/10 text-brand-purple",orange:"bg-brand-orange/10 text-brand-orange",green:"bg-brand-green/10 text-brand-green",pink:"bg-brand-pink/10 text-brand-pink",blue:"bg-brand-blue/10 text-brand-blue",yellow:"bg-brand-yellow/10 text-brand-yellow",red:"bg-brand-red/10 text-brand-red",default:"bg-surface-border text-text-body"},rounded:{full:"rounded-full",soft:"rounded-md"},border:{true:"",false:"border-0"},size:{sm:"px-2 py-0.5 text-[10px]",md:"px-3 py-1"},icon:{true:"p-0.5",false:""}},compoundVariants:[{variant:"purple",border:!0,className:"border border-brand-purple/5"},{variant:"orange",border:!0,className:"border border-brand-orange/5"},{variant:"green",border:!0,className:"border border-brand-green/5"},{variant:"pink",border:!0,className:"border border-brand-pink/5"},{variant:"blue",border:!0,className:"border border-brand-blue/5"},{variant:"yellow",border:!0,className:"border border-brand-yellow/5"},{variant:"red",border:!0,className:"border border-brand-red/5"},{variant:"default",border:!0,className:"border border-surface-border"}],defaultVariants:{variant:"default",rounded:"soft",border:!0,size:"md",icon:!1}}),oX={finalized:"green",proven:"green",preconfirmed:"yellow",pen
13ding:"yellow",reorged:"red"},vr=({children:e,variant:t="default",status:r=null,rounded:n="soft",border:i=!0,size:a="md",icon:s=!1,className:o})=>{const c=t==="status"?oX[r==null?void 0:r.toLowerCase()]||"green":t,l=s?void 0:a;return M.jsx("div",{className:mt(sX({variant:c,rounded:n,border:i,size:l,icon:s}),t==="status"&&"text-[10px]",o),children:e})},lX=Av("flex items-center gap-1.5 justify-center font-sans transition-colors duration-300 disabled:cursor-not-allowed disabled:opacity-50 focus:outline-none",{variants:{variant:{purple:"bg-brand-purple hover:bg-brand-purple/90 text-white border border-transparent shadow-lg shadow-brand-purple/20",green:"bg-brand-green hover:bg-brand-green/90 text-white border border-transparent shadow-lg shadow-brand-green/10",blue:"bg-brand-blue hover:bg-brand-blue/90 text-white border border-transparent shadow-lg shadow-brand-blue/10",orange:"bg-brand-orange hover:bg-brand-orange/90 text-white border border-transparent shadow-lg shadow-brand-orange/10",yellow:"bg-brand-yellow hover:bg-brand-yellow/90 text-white border border-transparent shadow-lg shadow-brand-yellow/10",pink:"bg-brand-pink hover:bg-brand-pink/90 text-white border border-transparent shadow-lg shadow-brand-pink/10",red:"bg-brand-red hover:bg-brand-red/90 text-white border border-transparent shadow-lg shadow-brand-red/10",gray:"bg-surface-card text-text-muted border border-surface-border hover:text-text-primary hover:bg-surface-border/50",ghost:"bg-transparent text-text-muted border border-transparent hover:text-text-primary hover:bg-surface-hover",link:"bg-transparent border-0 text-brand-purple p-0 h-auto hover:underline"},size:{xs:"h-[26px] text-[9px] px-2",sm:"h-[32px] text-[10px] px-3",md:"h-[36px] text-[12px] px-4",lg:"h-[44px] text-[14px] px-5",icon:"h-[28px] w-[28px] p-0"},roundness:{none:"rounded-none",soft:"rounded-md",medium:"rounded-lg",full:"rounded-full"}},compoundVariants:[{variant:"link",className:"h-auto p-0"}],defaultVariants:{variant:"gray",size:"md",roundness:"medium"}}),St=({variant:e="gray",size:t="md",roundness:r="medium",className:n,children:i,disabled:a=!1,to:s=null,href:o=null,iconBefore:c=null,iconAfter:l=null,...u})=>{const d=M.jsxs(M.Fragment,{children:[c&&M.jsx("span",{className:"flex-shrink-0",children:c}),i,l&&M.jsx("span",{className:"flex-shrink-0",children:l})]}),p=mt(lX({variant:e,size:t,roundness:r}),n);return s?M.jsx(ti,{to:s,className:p,...u,children:d}):o?M.jsx("a",{href:o,className:p,...u,children:d}):M.jsx("button",{className:p,disabled:a,...u,children:d})},xu=({value:e,className:t})=>{const[r,n]=he.useState(!1),i=a=>{a.preventDefault(),a.stopPropagation(),navigator.clipboard&&e&&navigator.clipboard.writeText(e).then(()=>{n(!0),setTimeout(()=>n(!1),1500)}).catch(s=>{console.error("Failed to copy:",s)})};return M.jsx("button",{onClick:i,className:mt("p-1 rounded transition-all duration-200",r?"text-brand-green scale-110":"text-text-muted hover:text-text-primary hover:bg-surface-hover",t),title:r?"Copied!":"Copy to clipboard",children:r?M.jsx(Rm,{className:"w-3.5 h-3.5"}):M.jsx(PW,{className:"w-3.5 h-3.5"})})};var cX=typeof Element<"u",uX=typeof Map=="function",fX=typeof Set=="function",hX=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function Iv(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var r,n,i;if(Array.isArray(e)){if(r=e.length,r!=t.length)return!1;for(n=r;n--!==0;)if(!Iv(e[n],t[n]))return!1;return!0}var a;if(uX&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(a=e.entries();!(n=a.next()).done;)if(!t.has(n.value[0]))return!1;for(a=e.entries();!(n=a.next()).done;)if(!Iv(n.value[1],t.get(n.value[0])))return!1;return!0}if(fX&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(a=e.entries();!(n=a.next()).done;)if(!t.has(n.value[0]))return!1;return!0}if(hX&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(r=e.length,r!=t.length)return!1;for(n=r;n--!==0;)if(e[n]!==t[n])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(i=Object.keys(e),r=i.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[n]))return!1;if(cX&&e instanceof Element)return!1;for(n=r;n--!==0;)if(!((i[n]==="_owner"||i[n]==="__v"||i[n]==="__o")&&e.$$typeof)&&!Iv(e[i[n]],t[i[n]]))return!1;return!0}return e!==e&&t!==t}var dX=function(e,t){try{return Iv(e,t)}catch(r){if((r.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw r}};const pX=Nr(dX);var mX=function(e,t,r,n,i,a,s,o){if(!e){var c;if(t===void 0)c=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[r,n,i,a,s,o],u=0;c=new Error(t.replace(/%s/g,function(){return l[u++]})),c.name="Invariant Violation"}throw c.framesToPop=1,c}},gX=mX;const pT=Nr(gX);var bX=function(e,t,r,n){var i=r?r.call(n,e,t):void 0;if(i!==void 0)return!!i;if(e===t)return!0;
13if(typeof e!="object"||!e||typeof t!="object"||!t)return!1;var a=Object.keys(e),s=Object.keys(t);if(a.length!==s.length)return!1;for(var o=Object.prototype.hasOwnProperty.bind(t),c=0;c<a.length;c++){var l=a[c];if(!o(l))return!1;var u=e[l],d=t[l];if(i=r?r.call(n,u,d,l):void 0,i===!1||i===void 0&&u!==d)return!1}return!0};const yX=Nr(bX);var mT=(e=>(e.BASE="base",e.BODY="body",e.HEAD="head",e.HTML="html",e.LINK="link",e.META="meta",e.NOSCRIPT="noscript",e.SCRIPT="script",e.STYLE="style",e.TITLE="title",e.FRAGMENT="Symbol(react.fragment)",e))(mT||{}),G6={link:{rel:["amphtml","canonical","alternate"]},script:{type:["application/ld+json"]},meta:{charset:"",name:["generator","robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]}},gT=Object.values(mT),Y6={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},vX=Object.entries(Y6).reduce((e,[t,r])=>(e[r]=t,e),{}),io="data-rh",t0={DEFAULT_TITLE:"defaultTitle",DEFER:"defer",ENCODE_SPECIAL_CHARACTERS:"encodeSpecialCharacters",ON_CHANGE_CLIENT_STATE:"onChangeClientState",TITLE_TEMPLATE:"titleTemplate",PRIORITIZE_SEO_TAGS:"prioritizeSeoTags"},r0=(e,t)=>{for(let r=e.length-1;r>=0;r-=1){const n=e[r];if(Object.prototype.hasOwnProperty.call(n,t))return n[t]}return null},wX=e=>{let t=r0(e,"title");const r=r0(e,t0.TITLE_TEMPLATE);if(Array.isArray(t)&&(t=t.join("")),r&&t)return r.replace(/%s/g,()=>t);const n=r0(e,t0.DEFAULT_TITLE);return t||n||void 0},xX=e=>r0(e,t0.ON_CHANGE_CLIENT_STATE)||(()=>{}),X6=(e,t)=>t.filter(r=>typeof r[e]<"u").map(r=>r[e]).reduce((r,n)=>({...r,...n}),{}),_X=(e,t)=>t.filter(r=>typeof r.base<"u").map(r=>r.base).reverse().reduce((r,n)=>{if(!r.length){const i=Object.keys(n);for(let a=0;a<i.length;a+=1){const s=i[a].toLowerCase();if(e.indexOf(s)!==-1&&n[s])return r.concat(n)}}return r},[]),SX=e=>console&&typeof console.warn=="function"&&console.warn(e),qm=(e,t,r)=>{const n={};return r.filter(i=>Array.isArray(i[e])?!0:(typeof i[e]<"u"&&SX(`Helmet: ${e} should be of type "Array". Instead found type "${typeof i[e]}"`),!1)).map(i=>i[e]).reverse().reduce((i,a)=>{const s={};a.filter(c=>{let l;const u=Object.keys(c);for(let p=0;p<u.length;p+=1){const w=u[p],O=w.toLowerCase();t.indexOf(O)!==-1&&!(l==="rel"&&c[l].toLowerCase()==="canonical")&&!(O==="rel"&&c[O].toLowerCase()==="stylesheet")&&(l=O),t.indexOf(w)!==-1&&(w==="innerHTML"||w==="cssText"||w==="itemprop")&&(l=w)}if(!l||!c[l])return!1;const d=c[l].toLowerCase();return n[l]||(n[l]={}),s[l]||(s[l]={}),n[l][d]?!1:(s[l][d]=!0,!0)}).reverse().forEach(c=>i.push(c));const o=Object.keys(s);for(let c=0;c<o.length;c+=1){const l=o[c],u={...n[l],...s[l]};n[l]=u}return i},[]).reverse()},kX=(e,t)=>{if(Array.isArray(e)&&e.length){for(let r=0;r<e.length;r+=1)if(e[r][t])return!0}return!1},EX=e=>({baseTag:_X(["href"],e),bodyAttributes:X6("bodyAttributes",e),defer:r0(e,t0.DEFER),encode:r0(e,t0.ENCODE_SPECIAL_CHARACTERS),htmlAttributes:X6("htmlAttributes",e),linkTags:qm("link",["rel","href"],e),metaTags:qm("meta",["name","charset","http-equiv","property","itemprop"],e),noscriptTags:qm("noscript",["innerHTML"],e),onChangeClientState:xX(e),scriptTags:qm("script",["src","innerHTML"],e),styleTags:qm("style",["cssText"],e),title:wX(e),titleAttributes:X6("titleAttributes",e),prioritizeSeoTags:kX(e,t0.PRIORITIZE_SEO_TAGS)}),bT=e=>Array.isArray(e)?e.join(""):e,MX=(e,t)=>{const r=Object.keys(e);for(let n=0;n<r.length;n+=1)if(t[r[n]]&&t[r[n]].includes(e[r[n]]))return!0;return!1},J6=(e,t)=>Array.isArray(e)?e.reduce((r,n)=>(MX(n,t)?r.priority.push(n):r.default.push(n),r),{priority:[],default:[]}):{default:e,priority:[]},yT=(e,t)=>({...e,[t]:void 0}),AX=["noscript","script","style"],Q6=(e,t=!0)=>t===!1?String(e):String(e).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;"),vT=e=>Object.keys(e).reduce((t,r)=>{const n=typeof e[r]<"u"?`${r}="${e[r]}"`:`${r}`;return t?`${t} ${n}`:n},""),CX=(e,t,r,n)=>{const i=vT(r),a=bT(t);return i?`<${e} ${io}="true" ${i}>${Q6(a,n)}</${e}>`:`<${e} ${io}="true">${Q6(a,n)}</${e}>`},TX=(e,t,r=!0)=>t.reduce((n,i)=>{const a=i,s=Object.keys(a).filter(l=>!(l==="innerHTML"||l==="cssText")).reduce((l,u)=>{const d=typeof a[u]>
13"u"?u:`${u}="${Q6(a[u],r)}"`;return l?`${l} ${d}`:d},""),o=a.innerHTML||a.cssText||"",c=AX.indexOf(e)===-1;return`${n}<${e} ${io}="true" ${s}${c?"/>":`>${o}</${e}>`}`},""),wT=(e,t={})=>Object.keys(e).reduce((r,n)=>{const i=Y6[n];return r[i||n]=e[n],r},t),jX=(e,t,r)=>{const n={key:t,[io]:!0},i=wT(r,n);return[Ei.createElement("title",i,t)]},Ov=(e,t)=>t.map((r,n)=>{const i={key:n,[io]:!0};return Object.keys(r).forEach(a=>{const s=Y6[a]||a;if(s==="innerHTML"||s==="cssText"){const o=r.innerHTML||r.cssText;i.dangerouslySetInnerHTML={__html:o}}else i[s]=r[a]}),Ei.createElement(e,i)}),Es=(e,t,r=!0)=>{switch(e){case"title":return{toComponent:()=>jX(e,t.title,t.titleAttributes),toString:()=>CX(e,t.title,t.titleAttributes,r)};case"bodyAttributes":case"htmlAttributes":return{toComponent:()=>wT(t),toString:()=>vT(t)};default:return{toComponent:()=>Ov(e,t),toString:()=>TX(e,t,r)}}},IX=({metaTags:e,linkTags:t,scriptTags:r,encode:n})=>{const i=J6(e,G6.meta),a=J6(t,G6.link),s=J6(r,G6.script);return{priorityMethods:{toComponent:()=>[...Ov("meta",i.priority),...Ov("link",a.priority),...Ov("script",s.priority)],toString:()=>`${Es("meta",i.priority,n)} ${Es("link",a.priority,n)} ${Es("script",s.priority,n)}`},metaTags:i.default,linkTags:a.default,scriptTags:s.default}},OX=e=>{const{baseTag:t,bodyAttributes:r,encode:n=!0,htmlAttributes:i,noscriptTags:a,styleTags:s,title:o="",titleAttributes:c,prioritizeSeoTags:l}=e;let{linkTags:u,metaTags:d,scriptTags:p}=e,w={toComponent:()=>{},toString:()=>""};return l&&({priorityMethods:w,linkTags:u,metaTags:d,scriptTags:p}=IX(e)),{priority:w,base:Es("base",t,n),bodyAttributes:Es("bodyAttributes",r,n),htmlAttributes:Es("htmlAttributes",i,n),link:Es("link",u,n),meta:Es("meta",d,n),noscript:Es("noscript",a,n),script:Es("script",p,n),style:Es("style",s,n),title:Es("title",{title:o,titleAttributes:c},n)}},e5=OX,Bv=[],xT=!!(typeof window<"u"&&window.document&&window.document.createElement),t5=class{constructor(e,t){te(this,"instances",[]);te(this,"canUseDOM",xT);te(this,"context");te(this,"value",{setHelmet:e=>{this.context.helmet=e},helmetInstances:{get:()=>this.canUseDOM?Bv:this.instances,add:e=>{(this.canUseDOM?Bv:this.instances).push(e)},remove:e=>{const t=(this.canUseDOM?Bv:this.instances).indexOf(e);(this.canUseDOM?Bv:this.instances).splice(t,1)}}});this.context=e,this.canUseDOM=t||!1,t||(e.helmet=e5({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))}},BX={},_T=Ei.createContext(BX),ST=(Gh=class extends he.Component{constructor(r){super(r);te(this,"helmetData");this.helmetData=new t5(this.props.context||{},Gh.canUseDOM)}render(){return Ei.createElement(_T.Provider,{value:this.helmetData.value},this.props.children)}},te(Gh,"canUseDOM",xT),Gh),n0=(e,t)=>{const r=document.head||document.querySelector("head"),n=r.querySelectorAll(`${e}[${io}]`),i=[].slice.call(n),a=[];let s;return t&&t.length&&t.forEach(o=>{const c=document.createElement(e);for(const l in o)if(Object.prototype.hasOwnProperty.call(o,l))if(l==="innerHTML")c.innerHTML=o.innerHTML;else if(l==="cssText")c.styleSheet?c.styleSheet.cssText=o.cssText:c.appendChild(document.createTextNode(o.cssText));else{const u=l,d=typeof o[u]>"u"?"":o[u];c.setAttribute(l,d)}c.setAttribute(io,"true"),i.some((l,u)=>(s=u,c.isEqualNode(l)))?i.splice(s,1):a.push(c)}
13),i.forEach(o=>{var c;return(c=o.parentNode)==null?void 0:c.removeChild(o)}),a.forEach(o=>r.appendChild(o)),{oldTags:i,newTags:a}},r5=(e,t)=>{const r=document.getElementsByTagName(e)[0];if(!r)return;const n=r.getAttribute(io),i=n?n.split(","):[],a=[...i],s=Object.keys(t);for(const o of s){const c=t[o]||"";r.getAttribute(o)!==c&&r.setAttribute(o,c),i.indexOf(o)===-1&&i.push(o);const l=a.indexOf(o);l!==-1&&a.splice(l,1)}for(let o=a.length-1;o>=0;o-=1)r.removeAttribute(a[o]);i.length===a.length?r.removeAttribute(io):r.getAttribute(io)!==s.join(",")&&r.setAttribute(io,s.join(","))},RX=(e,t)=>{typeof e<"u"&&document.title!==e&&(document.title=bT(e)),r5("title",t)},kT=(e,t)=>{const{baseTag:r,bodyAttributes:n,htmlAttributes:i,linkTags:a,metaTags:s,noscriptTags:o,onChangeClientState:c,scriptTags:l,styleTags:u,title:d,titleAttributes:p}=e;r5("body",n),r5("html",i),RX(d,p);const w={baseTag:n0("base",r),linkTags:n0("link",a),metaTags:n0("meta",s),noscriptTags:n0("noscript",o),scriptTags:n0("script",l),styleTags:n0("style",u)},O={},I={};
13Object.keys(w).forEach(R=>{const{newTags:C,oldTags:j}=w[R];C.length&&(O[R]=C),j.length&&(I[R]=w[R].oldTags)}),t&&t(),c(e,O,I)},Vm=null,NX=e=>{Vm&&cancelAnimationFrame(Vm),e.defer?Vm=requestAnimationFrame(()=>{kT(e,()=>{Vm=null})}):(kT(e),Vm=null)},FX=NX,ET=class extends he.Component{constructor(){super(...arguments);te(this,"rendered",!1)}shouldComponentUpdate(t){return!yX(t,this.props)}componentDidUpdate(){this.emitChange()}componentWillUnmount(){const{helmetInstances:t}=this.props.context;t.remove(this),this.emitChange()}emitChange(){const{helmetInstances:t,setHelmet:r}=this.props.context;let n=null;const i=EX(t.get().map(a=>{const s={...a.props};return delete s.context,s}));ST.canUseDOM?FX(i):e5&&(n=e5(i)),r(n)}init(){if(this.rendered)return;this.rendered=!0;const{helmetInstances:t}=this.props.context;t.add(this),this.emitChange()}render(){return this.init(),null}},PX=(uE=class extends he.Component{shouldComponentUpdate(e){return!pX(yT(this.props,"helmetData"),yT(e,"helmetData"))}mapNestedChildrenToProps(e,t){if(!t)return null;switch(e.type){case"script":case"noscript":return{innerHTML:t};case"style":return{cssText:t};default:throw new Error(`<${e.type} /> elements are self-closing and can not contain children. Refer to our API for more information.`)}}flattenArrayTypeChildren(e,t,r,n){return{...t,[e.type]:[...t[e.type]||[],{...r,...this.mapNestedChildrenToProps(e,n)}]}}mapObjectTypeChildren(e,t,r,n){switch(e.type){case"title":return{...t,[e.type]:n,titleAttributes:{...r}};case"body":return{...t,bodyAttributes:{...r}};case"html":return{...t,htmlAttributes:{...r}};default:return{...t,[e.type]:{...r}}}}mapArrayTypeChildrenToProps(e,t){let r={...t};return Object.keys(e).forEach(n=>{r={...r,[n]:e[n]}}),r}warnOnInvalidChildren(e,t){return pT(gT.some(r=>e.type===r),typeof e.type=="function"?"You may be attempting to nest <Helmet> components within each other, which is not allowed. Refer to our API for more information.":`Only elements types ${gT.join(", ")} are allowed. Helmet does not support rendering <${e.type}> elements. Refer to our API for more information.`),pT(!t||typeof t=="string"||Array.isArray(t)&&!t.some(r=>typeof r!="string"),`Helmet expects a string as a child of <${e.type}>. Did you forget to wrap your children in braces? ( <${e.type}>{\`\`}</${e.type}> ) Refer to our API for more information.`),!0}mapChildrenToProps(e,t){let r={};return Ei.Children.forEach(e,n=>{if(!n||!n.props)return;const{children:i,...a}=n.props,s=Object.keys(a).reduce((c,l)=>(c[vX[l]||l]=a[l],c),{});let{type:o}=n;
13switch(typeof o=="symbol"?o=o.toString():this.warnOnInvalidChildren(n,i),o){case"Symbol(react.fragment)":t=this.mapChildrenToProps(i,t);break;case"link":case"meta":case"noscript":case"script":case"style":r=this.flattenArrayTypeChildren(n,r,s,i);break;default:t=this.mapObjectTypeChildren(n,t,s,i);break}}),this.mapArrayTypeChildrenToProps(r,t)}render(){const{children:e,...t}=this.props;let r={...t},{helmetData:n}=t;if(e&&(r=this.mapChildrenToProps(e,r)),n&&!(n instanceof t5)){const i=n;n=new t5(i.context,!0),delete r.helmetData}return n?Ei.createElement(ET,{...r,context:n.value}):Ei.createElement(_T.Consumer,null,i=>Ei.createElement(ET,{...r,context:i}))}},te(uE,"defaultProps",{defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1}),uE);const ao="https://aztecexplorer.xyz",n5={"/":{title:"Aztec Explorer | Aztec Network Blockchain Explorer",description:"Explore the Aztec Network blockchain with Aztec Explorer. View transactions, blocks, accounts, and other network statistics on the privacy-focused L2.",keywords:"Aztec, Aztec Network, blockchain explorer, explorer, scan, aztec scanner, aztec explorer, crypto, privacy, L2, zero knowledge, zk, transactions, blocks",structuredData:{"@context":"https://schema.org","@type":"WebSite",name:"Aztec Explorer",alternateName:"Aztec Network Explorer",url:ao,description:"Explore the Aztec Network blockchain with Aztec Explorer. View transactions, blocks, accounts, and other network statistics on the privacy-focused L2.",potentialAction:{"@type":"SearchAction",target:{"@type":"EntryPoint",urlTemplate:`${ao}/search?q={search_term_string}`},"query-input":"required name=search_term_string"},publisher:{"@type":"Organization",name:"Aztec Explorer",url:ao}}},"/blocks":{title:"Blocks | Aztec Explorer",description:"Browse all blocks on the Aztec Network. View block details, transactions, and network statistics.",keywords:"Aztec blocks, blockchain blocks, Aztec Network, block explorer, crypto blocks",structuredData:{"@context":"https://schema.org","@type":"CollectionPage",name:"Aztec Network Blocks",description:"Browse all blocks on the Aztec Network. View block details, transactions, and network statistics.",url:`${ao}/blocks`,isPartOf:{"@type":"WebSite",name:"Aztec Explorer",url:ao}}},"/transactions":{title:"Transactions | Aztec Explorer",description:"Browse all transactions on the Aztec Network. View transaction details, status, and network activity.",keywords:"Aztec transactions, blockchain transactions, Aztec Network, transaction explorer, crypto transactions",structuredData:{"@context":"https://schema.org","@type":"CollectionPage",name:"Aztec Network Transactions",description:"Browse all transactions on the Aztec Network. View transaction details, status, and network activity.",url:`${ao}/transactions`,isPartOf:{"@type":"WebSite",name:"Aztec Explorer",url:ao}}},"/addresses":{title:"Addresses | Aztec Explorer",description:"Browse addresses on the Aztec Network. View address details, transactions, and account information.",keywords:"Aztec addresses, blockchain addresses, Aztec Network, address explorer, crypto addresses",structuredData:{"@context":"https://schema.org","@type":"CollectionPage",name:"Aztec Network Addresses",description:"Browse addresses on the Aztec Network. View address details, transactions, and account information.",url:`${ao}/addresses`,isPartOf:{"@type":"WebSite",name:"Aztec Explorer",url:ao}}},"/classes":{title:"Classes | Aztec Explorer",description:"Browse smart contract classes on the Aztec Network. View class details, instances, and contract information.",keywords:"Aztec classes, smart contracts, Aztec Network, contract explorer, crypto contracts",structuredData:{"@context":"https://schema.org","@type":"CollectionPage",name:"Aztec Network Contract Classes",description:"Browse smart contract classes on the Aztec Network. View class details, instances, and contract information.",url:`${ao}/classes`,isPartOf:{"@type":"WebSite",name:"Aztec Explorer",url:ao}}},"/block":{title:"Block Details | Aztec Explorer",description:"View detailed information about this block on the Aztec Network including transactions, timestamp, and fees.",keywords:"Aztec block, block details, Aztec Network, blockchain block"},"/tx":{title:"Transaction Details | Aztec Explorer",description:"View detailed information about this transaction on the Aztec Network including status, fees, and block 
13inclusion.",keywords:"Aztec transaction, transaction details, Aztec Network, blockchain transaction"},"/address":{title:"Address Details | Aztec Explorer",description:"View detailed information about this address on the Aztec Network including balance, transactions, and contract class.",keywords:"Aztec address, address details, Aztec Network, blockchain address, contract"},"/class":{title:"Contract Class Details | Aztec Explorer",description:"View detailed information about this contract class on the Aztec Network including artifact hash, version, and instances.",keywords:"Aztec class, contract class, Aztec Network, smart contract"}},zX=e=>{if(n5[e])return n5[e];const t=["/block","/tx","/address","/class"];for(const r of t)if(e.startsWith(r+"/"))return n5[r];return{title:"Aztec Explorer | Aztec Network Blockchain Explorer",description:"Explore the Aztec Network with Aztec Explorer. View transactions, blocks, accounts, and other network statistics on the privacy-focused L2.",keywords:"Aztec, Aztec Network, blockchain explorer, explorer, scan, aztec scanner, aztec explorer, crypto, privacy, L2, zero knowledge, zk, transactions, blocks",structuredData:null}},Ms=({route:e=null,title:t,description:r,keywords:n,image:i="https://aztecexplorer.xyz/metaCard.png",structuredData:a,noindex:s=!1})=>{const o=to(),c=`https://aztecexplorer.xyz${o.pathname}`,l=e?zX(e):{},u=t||l.title||"Aztec Explorer | Aztec Network Blockchain Explorer",d=r||l.description||"Explore the Aztec Network with Aztec Explorer. View transactions, blocks, accounts, and other network statistics on the privacy-focused L2.",p=n||l.keywords||"Aztec, Aztec Network, blockchain explorer, explorer, scan, aztec scanner, aztec explorer, crypto, privacy, L2, zero knowledge, zk, transactions, blocks",w=a||l.structuredData||null,O=o.pathname.match(/\/(tx|address|block|class)\/[a-zA-Z0-9]+/),I=s||O;return M.jsxs(PX,{children:[M.jsx("title",{children:u}),M.jsx("meta",{name:"description",content:d}),M.jsx("meta",{name:"keywords",content:p}),I&&M.jsx("meta",{name:"robots",content:"noindex, nofollow"}),M.jsx("link",{rel:"canonical",href:c}),M.jsx("meta",{property:"og:title",content:u}),M.jsx("meta",{property:"og:description",content:d}),M.jsx("meta",{property:"og:url",content:c}),M.jsx("meta",{property:"og:image",content:i}),M.jsx("meta",{property:"og:image:width",content:"1200"}),M.jsx("meta",{property:"og:image:height",content:"630"}),M.jsx("meta",{property:"og:type",content:"website"}),M.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),M.jsx("meta",{name:"twitter:title",content:u}),M.jsx("meta",{name:"twitter:description",content:d}),M.jsx("meta",{name:"twitter:image",content:i}),w&&M.jsx("script",{type:"application/ld+json",children:JSON.stringify(w)})]})},LX=()=>M.jsxs(M.Fragment,{children:[M.jsx(Ms,{title:"404 - Page Not Found | Aztec Explorer",description:"The page you are looking for could not be found on Aztec Explorer.",keywords:"404, page not found, error, Aztec Explorer"}),M.jsxs("div",{className:"flex flex-col items-center justify-center text-center h-full p-12 m-6 border-2 border-dashed border-surface-border rounded-xl bg-surface-main/30",children:[M.jsx("div",{className:"w-20 h-20 rounded-full bg-brand-purple/10 flex items-center justify-center mb-6",children:M.jsx("span",{className:"text-4xl font-bold text-brand-purple",children:"404"})}),M.jsx("h1",{className:"text-xl font-semibold text-text-primary mb-2",children:"Page Not Found"}),M.jsx("p",{className:"text-sm text-text-muted max-w-md mb-6",children:"The page you are looking for might have been removed, had its name changed, or is temporarily unavailable."}),M.jsx(St,{variant:"purple",size:"md",roundness:"medium",to:"/",children:"Go to Homepage"})]})]}),pi=({message:e,type:t,currentNetwork:r,children:n})=>{const i=e||"An error occurred",a=r==="DEVNET"?"TESTNET":"DEVNET",s=e!=null&&e.includes("Block")?"block":e!=null&&e.includes("Transaction")?"transaction":e!=null&&e.includes("Address")?"address":e!=null&&e.includes("Class")?"class":"item",o=s==="class"?"classes":s==="address"?"addresses":`${s}s`,c=t==="not_found";return M.jsxs("div",{className:"flex flex-col items-center justify-center text-center p-12 border-2 border-dashed border-surface-border rounded-xl bg-surface-border/50",children:[M.jsx("div",{className:`w-16 h-16 rounded-full flex items-center justify-center mb-4 shadow-inner ${c?"bg-surface-card":"bg-brand-red/20"}`,children:c?M.jsx(pv,{className:"w-8 h-8 text-brand-purple"}):M.jsx(BW,{className:"w-8 h-8 text-brand-red"})}),M.jsx("h4",{className:"text-lg font-medium text-text-primary mb-2",children:i}),c&&M.jsxs("p",{className:"text-sm text-text-muted max-w-md mb-2",children:["The requested ",s," could not be found.",r&&M.jsxs(M.Fragment,{children:[" ","This may exist on a different network. Try switching to"," ",M.jsx("span",{className:"text-text-primary font-medium",children:a})," ","using the network selector."]})]}),t==="general_error"&&M.jsx("p",{className:"text-sm text-text-muted max-w-md mb-2",children:"Please try again later or check your network connection."}),n,M.jsxs("div",{className:"flex gap-3 mt-6",children:[M.jsx(St,{variant:"gray",size:"md",roundness:"medium",to:"/",children:"Go to Home"}),c&&s!=="item"&&M.jsxs(St,{variant:"purple",size:"md",roundness:"medium",to:`/${o}`,children:["View All ",o.charAt(0).toUpperCase()+o.slice(1)]})]})]})},DX=({dataType:e="data",minHeight:t,columns:r=[],isEmpty:n=!1})=>{const i=r.length>0?r.slice(0,5).map(s=>s.label||s.key):["Hash","Block","Age","Index","Fee"],a=e==="data"?"item":e.replace(/s$/,"");return M.jsxs("div",{className:"flex flex-col items-center justify-center text-center h-full p-12 m-6 border-2 border-dashed border-surface-border rounded-xl bg-surface-main/30",style:{minHeight:t?`${t}px`:void 0},children:[M.jsx("div",{className:"w-16 h-16 rounded-full bg-surface-border flex items-center justify-center mb-4 shadow-inner",children:M.jsx(pv,{className:"w-8 h-8 text-text-muted"})}),M.jsx("h4",{className:"text-lg font-medium text-text-primary mb-2",children:n?`No ${e}
13 found`:`Couldn't fetch ${e}`}),M.jsx("p",{className:"text-sm text-text-muted max-w-md",children:n?`This ${a==="transaction"?"block":"section"} doesn't contain any ${e}.`:"Please try again later or check your network connection."}),!n&&M.jsxs("div",{className:"mt-8 w-full max-w-4xl opacity-50 pointer-events-none blur-[1px]",children:[M.jsx("div",{className:"text-xs text-text-muted font-bold uppercase tracking-wider mb-4 px-4",style:{display:"grid",gridTemplateColumns:`repeat(${i.length}, 1fr)`},children:i.map((s,o)=>M.jsx("div",{children:s},o))}),[1,2,3].map(s=>M.jsx("div",{className:"py-3 px-4 border-b border-surface-border",style:{display:"grid",gridTemplateColumns:`repeat(${i.length}, 1fr)`},children:i.map((o,c)=>M.jsx("div",{className:"h-2 bg-surface-border rounded",style:{width:`${40+c*17%40}px`}},c))},s))]})]})};function Zm(e){const t=new Date(e);if(isNaN(t.getTime()))return console.error("Cannot convert time. The date string may be in an incorrect format."),"Invalid date format";const r=new Date-t,n=1e3,i=n*60,a=i*60,s=a*24,o=s*7,c=s*30,l=s*365;return r>=l?`${Math.floor(r/l)} y`:r>=c?`${Math.floor(r/c)} mo`:r>=o?`${Math.floor(r/o)} w`:r>=s?`${Math.floor(r/s)} d`:r>=a?`${Math.floor(r/a)} h`:r>=i?`${Math.floor(r/i)} min`:`${Math.floor(r/n)} sec`}function UX(e){const t=new Date(e),r=t.getUTCFullYear(),n=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"][t.getUTCMonth()],i=String(t.getUTCDate()).padStart(2,"0"),a=t.getUTCHours()%12||12,s=String(t.getUTCMinutes()).padStart(2,"0"),o=String(t.getUTCSeconds()).padStart(2,"0"),c=t.getUTCHours()>=12?"PM":"AM";return`${n}-${i}-${r} ${a}:${s}:${o} ${c} UTC`}const qX=Av("w-full border outline-none text-text-primary placeholder:text-text-muted disabled:cursor-not-allowed disabled:opacity-50 transition-colors duration-200 bg-surface-card",{variants:{variant:{default:"",filter:"text-[12px] placeholder:opacity-65 caret-brand-purple"},height:{sm:"h-[32px] text-xs px-3",md:"h-[40px] text-sm px-4",lg:"h-[48px] text-sm px-4"},roundness:{none:"rounded-none",soft:"rounded-md",medium:"rounded-xl",full:"rounded-full"},error:{true:"border-brand-red focus:border-brand-red",false:"border-surface-border focus:border-brand-purple/50"}},defaultVariants:{variant:"default",height:"md",roundness:"medium",error:!1}}),Vr=he.forwardRef(({variant:e="default",height:t="md",roundness:r="medium",className:n,containerClassName:i,leftIcon:a=null,rightIcon:s=null,rightElement:o=null,error:c=!1,disabled:l=!1,type:u="text",...d},p)=>{const w=()=>e==="filter"?a?"pl-8 pr-2":"px-2.5":a&&s?"pl-11 pr-11":a?o?"pl-11 pr-2":"pl-11 pr-4":s?"pl-4 pr-11":o?"pl-4 pr-2":"";return M.jsxs("div",{className:mt("relative flex items-center",i),children:[a&&M.jsx("div",{className:mt("absolute top-1/2 -translate-y-1/2 pointer-events-none text-text-muted",e==="filter"?"left-2":"left-4"),children:a}),M.jsx("input",{ref:p,type:u,className:mt(qX({variant:e,height:t,roundness:r,error:c}),w(),n),disabled:l,...d}),s&&!o&&M.jsx("div",{className:mt("absolute top-1/2 -translate-y-1/2 text-text-muted",e==="filter"?"right-2":"right-4"),children:s}),o&&M.jsx("div",{className:mt("absolute top-1/2 -translate-y-1/2",t==="lg"?"right-2":"right-1"),children:o})]})});Vr.displayName="Input";const VX=["Su","Mo","Tu","We","Th","Fr","Sa"],ZX=["January","February","March","April","May","June","July","August","September","October","November","December"],Rv=({value:e,onChange:t,max:r,label:n})=>{const i=he.useRef(null),a=28,s=he.useRef(!1),o=he.useRef(0),c=he.useRef(0),[l,u]=he.useState(0);he.useEffect(()=>{const O=parseInt(e,10);u(-O*a)},[e,a]);const d=O=>{s.current=!0,o.current=O.clientY,c.current=l,O.preventDefault()},p=O=>{if(!s.current)return;const I=O.clientY-o.current,R=c.current+I;u(R);const C=r+1;let j=Math.round(-R/a);j=(j%C+C)%C;const N=String(j).padStart(2,"0");N!==e&&t(N)},w=()=>{if(!s.current)return;s.current=!1;const O=parseInt(e,10);u(-O*a)};return he.useEffect(()=>(document.addEventListener("mousemove",p),document.addEventListener("mouseup",w),()=>{document.removeEventListener("mousemove",p),document.removeEventListener("mouseup",w)}),[l,e,r]),M.jsxs("div",{className:"flex flex-col items-center",style:{width:"45px"},children:[M.jsx("div",{className:"text-[8px] text-text-muted font-bold mb-1",children:n}),M.jsxs("div",{className:"relative w-full h-20 overflow-hidden",children:[M.jsx("div",{className:"absolute inset-0 flex items-center justify-center pointer-events-none",children:M.jsx("div",{className:"w-full h-7 bg-brand-purple/20 border-y border-brand-purple/50"})}),M.jsx("div",{ref:i,onMouseDown:d,className:"absolute inset-0 cursor-grab active:cursor-grabbing select-none",style:{transform:`translateY(calc(50% - 14px + ${l}
13px))`,transition:s.current?"none":"transform 0.2s ease-out"},children:Array.from({length:r*3+3},(O,I)=>{const R=((I-r)%(r+1)+(r+1))%(r+1),C=String(R).padStart(2,"0"),j=C===e;return M.jsx("div",{className:mt("flex items-center justify-center text-[10px] transition-all duration-150",j?"text-text-primary font-bold":"text-text-muted opacity-40"),style:{height:a},children:C},I)})})]})]})},i5=he.forwardRef(({selected:e,onChange:t,placeholder:r="Select date range and time",className:n,size:i="sm",...a},s)=>{const[o,c]=he.useState(!1),[l,u]=he.useState(new Date),[d,p]=he.useState((e==null?void 0:e.startDate)||null),[w,O]=he.useState((e==null?void 0:e.endDate)||null),[I,R]=he.useState((e==null?void 0:e.startHour)||"00"),[C,j]=he.useState((e==null?void 0:e.startMinute)||"00"),[N,P]=he.useState((e==null?void 0:e.endHour)||"23"),[Z,X]=he.useState((e==null?void 0:e.endMinute)||"59"),re=he.useRef(null);he.useEffect(()=>{e&&(p(e.startDate||null),O(e.endDate||null),R(e.startHour||"00"),j(e.startMinute||"00"),P(e.endHour||"23"),X(e.endMinute||"59"),e.startDate&&u(new Date(e.startDate)))},[e]),he.useEffect(()=>{const h=x=>{re.current&&!re.current.contains(x.target)&&c(!1)};return document.addEventListener("mousedown",h),()=>document.removeEventListener("mousedown",h)},[]);const ne=h=>{const x=h.getFullYear(),v=h.getMonth(),F=new Date(x,v,1),Q=new Date(x,v+1,0).getDate(),G=F.getDay(),J=[];for(let Y=0;Y<G;Y++)J.push(null);for(let Y=1;Y<=Q;Y++)J.push(new Date(x,v,Y));return J},ae=h=>{h&&(!d||d&&w?(p(h),O(null)):h<d?p(h):O(h))},ue=()=>{if(d){const h=new Date(d);h.setHours(parseInt(I,10),parseInt(C,10),0,0);const x=w?new Date(w):new Date(d);x.setHours(parseInt(N,10),parseInt(Z,10),59,999),t({startDate:h,endDate:x,startHour:I,startMinute:C,endHour:N,endMinute:Z}),c(!1)}},m=()=>{u(new Date(l.getFullYear(),l.getMonth()-1))},A=()=>{u(new Date(l.getFullYear(),l.getMonth()+1))},f=()=>{if(!d)return r;const h=d.toLocaleDateString(),x=w?w.toLocaleDateString():h;return`${h} ${I}:${C} - ${x} ${N}:${Z}`},g=h=>
13{if(!h)return!1;const x=new Date;return h.getDate()===x.getDate()&&h.getMonth()===x.getMonth()&&h.getFullYear()===x.getFullYear()},_=(h,x)=>!h||!x?!1:h.getDate()===x.getDate()&&h.getMonth()===x.getMonth()&&h.getFullYear()===x.getFullYear(),B=h=>!h||!d||!w?!1:h>=d&&h<=w,T=h=>h&&d&&_(h,d),S=h=>h&&w&&_(h,w);return M.jsxs("div",{ref:re,className:"relative",children:[M.jsx("button",{ref:s,type:"button",onClick:()=>c(!o),className:mt("w-full border outline-none text-text-primary placeholder:text-text-muted disabled:cursor-not-allowed disabled:opacity-50 transition-colors duration-200 text-left","bg-surface-card rounded-md border-surface-border focus:border-brand-purple/50",i==="sm"&&"h-[32px] text-[10px] px-2",i==="md"&&"h-[40px] text-sm px-3",!d&&"text-text-muted",n),...a,children:f()}),o&&M.jsxs("div",{className:"absolute z-50 mt-1 bg-surface-card border border-surface-border rounded-lg shadow-lg p-3 w-[280px]",children:[M.jsxs("div",{className:"flex items-center justify-between mb-3",children:[M.jsx("button",{type:"button",onClick:m,className:"p-1 hover:bg-surface-hover rounded text-text-muted hover:text-text-primary transition-colors",children:M.jsx("svg",{className:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:M.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M15 19l-7-7 7-7"})})}),M.jsxs("div",{className:"text-[11px] font-bold text-text-primary",children:[ZX[l.getMonth()]," ",l.getFullYear()]}),M.jsx("button",{type:"button",onClick:A,className:"p-1 hover:bg-surface-hover rounded text-text-muted hover:text-text-primary transition-colors",children:M.jsx("svg",{className:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:M.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5l7 7-7 7"})})})]}),M.jsx("div",{className:"grid grid-cols-7 gap-1 mb-2",children:VX.map(h=>M.jsx("div",{className:"text-center text-[9px] font-bold text-text-muted",children:h},h))}),M.jsx("div",{className:"grid grid-cols-7 gap-1 mb-3",children:ne(l).map((h,x)=>M.jsx("button",{type:"button",onClick:()=>ae(h),disabled:!h,className:mt("aspect-square flex items-center justify-center text-[10px] rounded transition-colors relative",!h&&"invisible",h&&!B(h)&&!T(h)&&!S(h)&&"text-text-muted hover:bg-surface-hover hover:text-text-primary",h&&B(h)&&!T(h)&&!S(h)&&"bg-brand-purple/20 text-text-primary",h&&(T(h)||S(h))&&"bg-brand-purple text-white font-bold",h&&g(h)&&!T(h)&&!S(h)&&"border border-brand-purple/50"),children:h&&h.getDate()},x))}),M.jsxs("div",{className:"border-t border-surface-border pt-3",children:[M.jsxs("div",{className:"flex gap-4 mb-3",children:[M.jsxs("div",{className:"flex-1",children:[M.jsx("div",{className:"text-[9px] font-bold text-text-muted mb-2 text-center",children:"START TIME"}),M.jsxs("div",{className:"flex gap-1.5 justify-center",children:[M.jsx(Rv,{value:I,onChange:R,max:23,label:"Hr"}),M.jsx("div",{className:"text-text-muted text-[10px] flex items-center",children:":"}),M.jsx(Rv,{value:C,onChange:j,max:59,label:"Min"})]})]}),M.jsxs("div",{className:"flex-1",children:[M.jsx("div",{className:"text-[9px] font-bold text-text-muted mb-2 text-center",children:"END TIME"}),M.jsxs("div",{className:"flex gap-1.5 justify-center",children:[M.jsx(Rv,{value:N,onChange:P,max:23,label:"Hr"}),M.jsx("div",{className:"text-text-muted text-[10px] flex items-center",children:":"}),M.jsx(Rv,{value:Z,onChange:X,max:59,label:"Min"})]})]})]}),M.jsx("button",{type:"button",onClick:ue,disabled:!d,className:"w-full h-8 bg-brand-purple hover:bg-brand-purple/90 text-white text-[10px] rounded transition-colors disabled:opacity-50 disabled:cursor-not-allowed",children:"Apply"})]})]})]})});i5.displayName="DateTimePicker";let kt,MT,ac;kt={panel:"w-[300px] absolute top-0 right-0 h-full bg-surface-main border-l border-surface-border shadow-lg z-50 overflow-y-auto transition-all duration-300 bg-[#101115] rounded-xl",panelContent:"p-4",panelHeader:"flex justify-between items-center mb-4 border-b border-surface-border p-4 bg-surface-card/80",panelTitle:"text-[14px] font-bold text-text-primary",closeButton:"text-text-muted hover:text-text-primary transition-colors",filterSections:"flex flex-col gap-6",sectionContainer:"filter-section",sectionHeader:"text-text-muted font-bold text-[11px] pb-1  flex justify-between",clearLink:"text-brand-purple font-normal hover:underline cursor-pointer",sectionContent:"flex flex-col gap-2 mt-2",label:"text-text-muted font-bold text-[11px] pb-1",inputContainer:"mt-2",buttonContainer:"flex w-full gap-2 pt-2",quickFilterContainer:"flex text-[10px] gap-1 flex-wrap"},MT=({filters:e,setFilters:t,filterTypes:r=[],isOpen:n,setIsOpen:i})=>{const a=he.useRef(null);he.useEffect(()=>{const R=C=>{var N;const j=(N=C.target.closest("button"))==null?void 0:N.classList.contains("filter-toggle-button");a.current&&!a.current.contains(C.target)&&!j&&n&&i(!1)};return document.addEventListener("mousedown",R),()=>{document.removeEventListener("mousedown",R)}},[a,i,n]);const s=R=>{switch(R){case"timestamp":return o();case"creationTimestamp":return O();case"fee":return c();case"txCount":return l();case"txFee":return u();case"index":return d();case"blockNumber":return p();case"version":return w();default:return null}},o=()=>{const[R,C]=he.useState(null),[j,N]=he.useState(null);return M.jsxs("div",{className:kt.sectionContainer,children:[M.jsxs("h2",{className:kt.sectionHeader,children:["TIME RANGE",M.jsx("div",{onClick:()=>{t({...e,startTimestamp:"",endTimestamp:""}),C(null),N(null)},className:kt.clearLink,children:"Clear"})]}),M.jsxs("div",{className:kt.sectionContent,children:[M.jsxs("div",{className:kt.quickFilterContainer,children:[M.jsx(St,{onClick:()=>{t({...e,endTimestamp:new Date(Date.now()).toISOString(),startTimestamp:new Date(Date.now()-1e3*60*60).toISOString()})},variant:"gray",size:"sm",roundness:"full",children:"Last 1H"}),M.jsx(St,{onClick:()=>{t({...e,endTimestamp:new Date(Date.now()).toISOString(),startTimestamp:new Date(Date.now()-1e3*60*60*24).toISOString()})},variant:"gray",size:"sm",roundness:"full",children:"Last 24H"}),M.jsx(St,{onClick:()=>{t({...e,endTimestamp:new Date(Date.now()).toISOString(),startTimestamp:new Date(Date.now()-1e3*60*60*24*7).toISOString()})},variant:"gray",size:"sm",roundness:"full",children:"Last 7D"})]}),M.jsxs("div",{className:kt.inputContainer,children:[M.jsx("h3",{className:kt.label,children:"SELECT TIME RANGE"}),M.jsx(i5,{selected:R,onChange:P=>{C(P.startDate),N(P.endDate)},placeholder:"Select date and time range",size:"sm",className:"mb-1 text-[12px]"})]}),M.jsx(St,{onClick:()=>
13{if(R||j){const P={...e};R?P.startTimestamp=R.toISOString():P.startTimestamp=new Date("2021-01-01T00:00:00").toISOString(),j?P.endTimestamp=j.toISOString():P.endTimestamp=new Date().toISOString(),t(P)}},variant:"green",size:"sm",className:"w-full mt-2",children:"Apply Custom Range"})]})]})},c=()=>{const[R,C]=he.useState(""),[j,N]=he.useState("");return M.jsxs("div",{className:kt.sectionContainer,children:[M.jsxs("h2",{className:kt.sectionHeader,children:["FEE RANGE",M.jsx("div",{onClick:()=>{t({...e,minFee:"",maxFee:""})},className:kt.clearLink,children:"Clear"})]}),M.jsx("div",{className:kt.sectionContent,children:M.jsxs("div",{className:"flex flex-col gap-1",children:[M.jsx(Vr,{placeholder:"Min Fee",value:R,onChange:P=>C(P.target.value),variant:"filter",size:"sm",className:"mb-1"}),M.jsx(Vr,{placeholder:"Max Fee",value:j,onChange:P=>N(P.target.value),variant:"filter",size:"sm",className:"mb-1"}),M.jsx(St,{onClick:()=>{t({...e,minFee:R,maxFee:j})},variant:"green",size:"sm",className:"w-full mt-2",children:"Apply"})]})})]})},l=()=>{const[R,C]=he.useState(""),[j,N]=he.useState("");return M.jsxs("div",{className:kt.sectionContainer,children:[M.jsxs("h2",{className:kt.sectionHeader,children:["TRANSACTION COUNT",M.jsx("div",{onClick:()=>{t({...e,minTxCount:"",maxTxCount:""})},className:kt.clearLink,children:"Clear"})]}),M.jsx("div",{className:kt.sectionContent,children:M.jsxs("div",{className:"flex flex-col gap-1",children:[M.jsx(Vr,{placeholder:"Min Tx Count",value:R,onChange:P=>C(P.target.value),variant:"filter",size:"sm",className:"mb-1"}),M.jsx(Vr,{placeholder:"Max Tx Count",value:j,onChange:P=>N(P.target.value),variant:"filter",size:"sm",className:"mb-1"}),M.jsx(St,{onClick:()=>{t({...e,minTxCount:R,maxTxCount:j})},variant:"green",size:"sm",className:"w-full mt-2",children:"Apply"})]})})]})},u=()=>{const[R,C]=he.useState(""),[j,N]=he.useState("");return M.jsxs("div",{className:kt.sectionContainer,children:[M.jsxs("h2",{className:kt.sectionHeader,children:["Transaction Fee",M.jsx("div",{onClick:()=>{t({...e,minTxFee:"",maxTxFee:""})},className:kt.clearLink,children:"Clear"})]}),M.jsx("div",{className:kt.sectionContent,children:M.jsxs("div",{children:[M.jsxs("div",{children:[M.jsx("h3",{className:kt.label,children:"Min Tx Fee"}),M.jsx(Vr,{placeholder:"Min Tx Fee",value:R,onChange:P=>C(P.target.value),variant:"filter",size:"sm",className:"mb-1"})]}),M.jsxs("div",{children:[M.jsx("h3",{className:kt.label,children:"Max Tx Fee"}),M.jsx(Vr,{placeholder:"Max Tx Fee",value:j,onChange:P=>N(P.target.value),variant:"filter",size:"sm",className:"mb-1"})]}),M.jsx(St,{onClick:()=>{t({...e,minTxFee:R,maxTxFee:j})},variant:"purple",size:"sm",className:"w-full mt-2",children:"Apply"})]})})]})},d=()=>{const[R,C]=he.useState(""),[j,N]=he.useState("");return M.jsxs("div",{className:kt.sectionContainer,children:[M.jsxs("h2",{className:kt.sectionHeader,children:["Index Range",M.jsx("div",{onClick:()=>{t({...e,minIndex:"",maxIndex:""})},className:kt.clearLink,children:"Clear"})]}),M.jsx("div",{className:kt.sectionContent,children:M.jsxs("div",{children:[M.jsxs("div",{children:[M.jsx("h3",{className:kt.label,children:"Min Index"}),M.jsx(Vr,{placeholder:"Min Index",value:R,onChange:P=>C(P.target.value),variant:"filter",size:"sm",className:"mb-1"})]}),M.jsxs("div",{children:[M.jsx("h3",{className:kt.label,children:"Max Index"}),M.jsx(Vr,{placeholder:"Max Index",value:j,onChange:P=>N(P.target.value),variant:"filter",size:"sm",className:"mb-1"})]}),M.jsx(St,{onClick:()=>{t({...e,minIndex:R,maxIndex:j})},variant:"purple",size:"sm",className:"w-full mt-2",children:"Apply"})]})})]})},p=()=>{const[R,C]=he.useState(""),[j,N]=he.useState("");return M.jsxs("div",{className:kt.sectionContainer,children:[M.jsxs("h2",{className:kt.sectionHeader,children:["Block Number Range",M.jsx("div",{onClick:()=>{t({...e,minBlockNumber:"",maxBlockNumber:""}),C(""),N("")},className:kt.clearLink,children:"Clear"})]}),M.jsxs("div",{className:kt.sectionContent,children:[M.jsxs("div",{className:kt.inputContainer,children:[M.jsx("h3",{className:kt.label,children:"Min Block Number"}),M.jsx(Vr,{type:"number",placeholder:"Min Block Number",value:R,onChange:P=>C(P.target.value),variant:"filter",size:"sm",className:"mb-1"})]}),M.jsxs("div",{className:kt.inputContainer,children:[M.jsx("h3",{className:kt.label,children:"Max Block Number"}),M.jsx(Vr,{type:"number",placeholder:"Max Block Number",value:j,onChange:P=>N(P.target.value),variant:"filter",size:"sm",className:"mb-1"})]}),M.jsx(St,{onClick:()=>{(R||j)&&t({...e,minBlockNumber:R||void 0,maxBlockNumber:j||void 0})},variant:"purple",size:"sm",className:"w-full mt-2",children:"Apply"})]})]})},w=()=>{const[R,C]=he.useState(""),[j,N]=he.useState("");return M.jsxs("div",{className:kt.sectionContainer,children:[M.jsxs("h2",{className:kt.sectionHeader,children:["Version Range",M.jsx("div",{onClick:()=>{t({...e,minVersion:"",maxVersion:""}),C(""),N("")},className:kt.clearLink,children:"Clear"})]}),M.jsxs("div",{className:kt.sectionContent,children:[M.jsxs("div",{className:kt.inputContainer,children:[M.jsx("h3",{className:kt.label,children:"Min Version"}),M.jsx(Vr,{type:"number",placeholder:"Min Version",value:R,onChange:P=>C(P.target.value),variant:"filter",size:"sm",className:"mb-1"})]}),M.jsxs("div",{className:kt.inputContainer,children:[M.jsx("h3",{className:kt.label,children:"Max Version"}),M.jsx(Vr,{type:"number",placeholder:"Max Version",value:j,onChange:P=>N(P.target.value),variant:"filter",size:"sm",className:"mb-1"})]}),M.jsx(St,{onClick:()=>{(R||j)&&t({...e,minVersion:R||void 0,maxVersion:j||void 0})},variant:"purple",size:"sm",className:"w-full mt-2",children:"Apply"})]})]})},O=()=>{const[R,C]=he.useState(null),[j,N]=he.useState(null);return M.jsxs("div",{className:kt.sectionContainer,children:[M.jsxs("h2",{className:kt.sectionHeader,children:["Creation Time Range",M.jsx("div",{onClick:()=>{t({...e,startCreationTimestamp:"",endCreationTimestamp:""}),C(null),N(null)},className:kt.clearLink,children:"Clear"})]}),M.jsxs("div",{className:kt.sectionContent,children:[M.jsxs("div",{className:kt.quickFilterContainer,children:[M.jsx(St,{onClick:()=>{t({...e,endCreationTimestamp:new Date(Date.now()).toISOString(),startCreationTimestamp:new Date(Date.now()-1e3*60*60).toISOString()})},variant:"gray",size:"sm",roundness:"full",className:"!h-auto !px-2 !py-1 !text-[10px]",children:"Last 1H"}),M.jsx(St,{onClick:()=>{t({...e,endCreationTimestamp:new Date(Date.now()).toISOString(),startCreationTimestamp:new Date(Date.now()-1e3*60*60*24).toISOString()})},variant:"gray",size:"sm",roundness:"full",className:"!h-auto !px-2 !py-1 !text-[10px]",children:"Last 24H"}),M.jsx(St,{onClick:()=>{t({...e,endCreationTimestamp:new Date(Date.now()).toISOString(),startCreationTimestamp:new Date(Date.now()-1e3*60*60*24*7).toISOString()})},variant:"gray",size:"sm",roundness:"full",className:"!h-auto !px-2 !py-1 !text-[10px]",children:"Last 7D"})]}),M.jsxs("div",{className:kt.inputContainer,children:[M.jsx("h3",{className:kt.label,children:"SELECT TIME RANGE"}),M.jsx(i5,{selected:R,onChange:P=>{C(P.startDate),N(P.endDate)},placeholder:"Select date and time range",size:"sm",className:"mb-1 text-[12px]"})]}),M.jsx(St,{onClick:()=>
13{if(R||j){const P={...e};R&&(P.startCreationTimestamp=R.toISOString()),j&&(P.endCreationTimestamp=j.toISOString()),t(P)}},variant:"purple",size:"sm",className:"w-full mt-2",children:"Apply"})]})]})},I=()=>Object.keys(e).some(R=>R==="sort"||R==="order"?!1:e[R]!==""&&e[R]!==void 0);return M.jsx(M.Fragment,{children:M.jsxs("div",{ref:a,className:`${kt.panel} ${n?"translate-x-0":"translate-x-full"}`,children:[M.jsxs("div",{className:kt.panelHeader,children:[M.jsx("h1",{className:kt.panelTitle,children:"Filters"}),M.jsx(St,{onClick:()=>i(!1),variant:"ghost",size:"sm",className:"!p-1 !h-auto",children:M.jsx(Hd,{className:"text-[20px]"})})]}),M.jsxs("div",{className:kt.panelContent,children:[I()&&M.jsx(St,{onClick:()=>{const{sort:R,order:C}=e;t({sort:R,order:C})},variant:"link",className:"text-brand-purple hover:text-brand-blue font-medium text-[12px] mb-4",children:"Clear All Filters"}),M.jsx("div",{className:kt.filterSections,children:r.map(R=>M.jsx("div",{children:s(R)},R))})]})]})})},Qr=({className:e})=>M.jsx("div",{className:`w-full h-40 bg-surface-border/50 animate-pulse rounded-lg overflow-hidden relative ${e}`,children:M.jsx("div",{className:"absolute top-0 left-0 w-full h-full bg-gradient-to-r from-transparent via-brand-purple/20 to-transparent animate-shimmer"})}),ac=({data:e=[],columns:t=[],variant:r="detailed",loading:n=!1,error:i=null,sortable:a=!1,currentSort:s=null,onSort:o=null,filters:c=null,setFilters:l=null,filterTypes:u=[],isFilterPanelOpen:d=!1,setIsFilterPanelOpen:p=null,title:w=null,titleIcon:O=null,viewAllLink:I=null,limit:R=20,className:C,theme:j="block",animatedRows:N=null})=>{var T;const P={block:{bg:"bg-brand-blue/10",text:"text-brand-blue",borderTop:"border-t-brand-blue/20"},tx:{bg:"bg-brand-purple/10",text:"text-brand-purple",borderTop:"border-t-brand-purple/20"}},Z=S=>{const h=S.toLowerCase();return h.includes("hash")?"hash":h.includes("address")||h==="feerecipient"||h==="origin"?"address":h.includes("timestamp")||h==="age"||h==="created"?"timestamp":h.includes("status")?"status":h.includes("fee")||h.includes("balance")?"fee":h==="number"||h==="blocknumber"?"number":h.includes("txcount")||h==="index"?"count":"text"},X=(S,h,x)=>{const v=S[h.key],F=h.type||Z(h.key),Q=h.prefix||"";if(!v&&v!==0)return null;switch(F){case"blockLink":return M.jsx(ti,{to:`/block/${S.blockHash||S.hash||v}`,className:mt("text-brand-blue font-mono font-medium hover:underline",j==="block"?"text-base":"text-sm"),children:v});case"txLink":return M.jsxs("div",{className:"flex items-center gap-1",children:[M.jsx(ti,{to:`/tx/${v}`,className:mt("text-text-primary font-mono hover:underline hover:text-brand-purple duration-300",j==="tx"?"text-sm font-medium":"text-xs"),children:tl(v)}),M.jsx(xu,{value:v,className:"opacity-0 group-hover/row:opacity-100"})]});case"hashDisplay":return M.jsxs("div",{className:"flex items-center gap-1",children:[M.jsx("span",{className:"text-text-primary text-xs font-mono hover:text-brand-purple hover:underline duration-300",children:tl(v)}),M.jsx(xu,{value:v,className:"opacity-0 group-hover/row:opacity-100"})]});case"age":return M.jsxs("div",{className:"flex items-center gap-1 text-text-muted text-[11px]",children:[M.jsx(Fm,{className:"w-3 h-3"}),Zm(v)]});case"addressDisplay":return M.jsxs("span",{className:"text-text-muted font-mono text-[11px]",children:[Q,tl(v)]});case"status":return M.jsx(vr,{variant:"status",status:v,children:v||"Finalized"});case"fee":return M.jsxs("div",{className:"text-text-faint text-[11px] font-mono hover:text-brand-orange/50 duration-300",children:[M.jsx("p",{className:"inline-block text-text-muted ",children:"Fee:"})," ",v]});default:return M.jsxs("span",{className:"text-text-primary text-sm",children:[Q,v]})}},re=(S,h,x)=>{if(S.linkTo)return S.linkTo(h,x);switch(S.key){case"id":return`/class/${h}`;case"hash":return x.blockNumber!==void 0?`/tx/${h}`:`/block/${h}`;case"blockHash":return`/block/${h}`;case"txHash":return`/tx/${h}`;case"contractClassID":return`/class/${h}`;case"address":case"deployer":case"feeRecipient":case"origin":return`/address/${h}`;default:return null}},ne=(S,h)=>{var G;const x=h[S.key],v=S.type||Z(S.key),F=S.cellClassName||"",Q=F.includes("text-");switch(v){case"hash":const J=re(S,x,h);return!J||S.linkTo===null||S.linkTo===!1?M.jsxs("div",{className:"overflow-hidden text-ellipsis flex gap-1 items-center",children:[M.jsx("span",{className:mt("font-mono",Q?F:"text-text-primary"),children:tl(x)}),M.jsx(xu,{value:x,className:"opacity-0 group-hover/row:opacity-100"})]}):M.jsxs("div",{className:"overflow-hidden text-ellipsis flex gap-1 items-center",children:[M.jsx(ti,{to:J,className:mt("font-mono hover:underline underline-offset-2 transition-colors",Q?F:"text-brand-purple"),children:tl(x)}),M.jsx(xu,{value:x,className:"opacity-0 group-hover/row:opacity-100"})]});case"address":const Y=re(S,x,h);return M.jsxs("div",{className:"overflow-hidden text-ellipsis flex gap-1 items-center",children:[M.jsx(ti,{to:Y,className:mt("font-mono hover:underline underline-offset-2 transition-colors",Q?F:"text-brand-purple"),children:tl(x)}),M.jsx(xu,{value:x,className:"opacity-0 group-hover/row:opacity-100"})]});case"timestamp":return M.jsxs("div",{className:"flex items-center gap-1.5 text-text-muted text-sm",children:[M.jsx(Fm,{className:"w-3.5 h-3.5"}),Zm(x)]});case"status":return M.jsx(vr,{variant:"status",status:x,children:x||"Finalized"});case"fee":const V=(G=x==null?void 0:x.startsWith)!=null&&G.call(x,"0x")?BigInt(x).toString():x;return M.jsx("div",{className:"text-brand-orange font-mono",children:V});case"number":return M.jsx(ti,{to:`/block/${h.hash}`,children:M.jsx(vr,{variant:"default",border:!1,className:"text-brand-blue font-mono hover:underline",children:x})});case"count":return M.jsx("div",{className:mt("text-text-primary font-mono",F),children:x});case"nullifier":return M.jsxs("div",{className:mt("flex items-center gap-2",F),children:[M.jsx("div",{className:"overflow-hidden text-ellipsis text-text-primary font-mono flex-1 min-w-0",children:x}),M.jsx(xu,{value:x,className:"opacity-0 group-hover/row:opacity-100 flex-shrink-0"})]});default:return M.jsx("div",{className:mt("text-text-primary",F),children:x})}},ae=()=>r==="compact"?M.jsx("div",{className:"w-full border-b border-surface-border h-[40px] min-h-[40px] flex justify-between items-center px-4 text-[11px] font-medium text-text-muted uppercase tracking-wide below-mobile:hidden",children:t.map(S=>M.jsx("div",{style:{width:S.width},className:mt("flex items-center font-semibold",S.align==="right"&&"justify-end"),children:S.label},S.key||S.label))}):M.jsx(M.Fragment,{children:M.jsx("div",{className:"bg-surface-card/80 flex px-4 text-[11px] font-semibold uppercase tracking-wide justify-between below-lg:text-[10px] below-mobile:hidden text-text-muted h-[45px] items-center border-b border-surface-border",children:t.map((S,h)=>M.jsx("div",{style:{width:S.width},className:mt("flex items-center",S.sortable&&"hover:text-text-primary curs
13or-pointer"),children:S.sortable&&a?M.jsx("span",{className:mt("transition-colors",s===S.sortKey&&"text-text-primary"),onClick:()=>o&&o(S.sortKey),children:S.label}):M.jsx("span",{children:S.label})},`${S.key}-${h}`))})}),ue=S=>{var h,x;return N?(h=N.newIds)!=null&&h.has(S)?"animate-slide-in-top":(x=N.exitingIds)!=null&&x.has(S)?"animate-slide-out-bottom":"":""},m=()=>M.jsx("div",{className:"flex flex-col w-full below-mobile:hidden overflow-hidden",children:e.map((S,h)=>{const x=S.hash||S.id,v=ue(x);return M.jsx("div",{className:mt("group/row flex justify-between items-center w-full px-4 h-[67px] border-b border-surface-border last:border-b-0 hover:bg-surface-hover/50 transition-colors cursor-pointer",v),children:t.map(F=>M.jsx("div",{style:{width:F.width},className:mt("flex flex-col gap-0.5",F.align==="right"&&"items-end"),children:F.group?F.group.map((Q,G)=>M.jsx("div",{children:X(S,Q)},Q.key||G)):X(S,{key:F.key,type:F.type})},F.key||F.label))},x||h)})}),A=()=>{const S=h=>j==="tx"?`/tx/${h.hash}`:`/block/${h.hash}`;return M.jsx("div",{className:"hidden below-mobile:flex flex-col overflow-hidden",children:e.map((h,x)=>{const v=h.hash||h.id,F=ue(v);return M.jsxs(ti,{to:S(h),className:mt("group/row flex flex-col gap-3 px-4 py-4 border-b border-surface-border last:border-b-0 hover:bg-surface-hover/50 transition-colors",x===0&&"rounded-t-xl",x===e.length-1&&"rounded-b-xl",F),children:[M.jsxs("div",{className:"flex justify-between items-center",children:[M.jsxs("div",{className:"flex items-center gap-2",children:[j==="block"?M.jsxs(vr,{variant:"default",border:!1,className:"text-brand-blue font-mono font-semibold",children:["#",h.number]}):M.jsx("span",{className:"text-text-primary font-mono text-sm",children:tl(h.hash)}),M.jsx(xu,{value:h.hash,className:"opacity-50"})]}),h.finalityStatus&&M.jsx(vr,{variant:"status",status:h.finalityStatus,children:h.finalityStatus})]}),M.jsxs("div",{className:"flex justify-between items-center text-xs",children:[M.jsxs("div",{className:"flex items-center gap-1 text-text-muted",children:[M.jsx(Fm,{className:"w-3 h-3"}),Zm(h.timestamp)]}),j==="tx"&&h.blockNumber&&M.jsxs("span",{className:"text-brand-blue font-mono",children:["Block #",h.blockNumber]}),j==="block"&&h.txCount!==void 0&&M.jsxs("span",{className:"text-text-muted",children:[h.txCount," txs"]})]}),M.jsxs("div",{className:"flex justify-between items-center text-xs",children:[j==="tx"&&h.transactionFee&&M.jsxs("span",{className:"text-brand-orange font-mono",children:["Fee: ",h.transactionFee]}),j==="block"&&M.jsx("span",{className:"text-text-muted font-mono text-[11px]",children:tl(h.hash,8,8)})]})]},v||x)})})},f=()=>r==="compact"?m():M.jsx("div",{className:"flex flex-col",children:e.map((S,h)=>M.jsx("div",{className:"group/row below-mobile:hidden flex justify-between items-center px-4 text-xs h-[45px] border-b border-surface-border last:border-b-0 hover:bg-surface-hover transition-colors",children:t.map((x,v)=>M.jsx("div",{style:{width:x.width},children:ne(x,S)},`${x.key}-${v}`))},S.hash||S.id||h))}),g=()=>{if(r==="compact")return A();const S=[...t].filter(h=>h.mobile!==!1).sort((h,x)=>{var v,F;return(((v=h.mobile)==null?void 0:v.order)||999)-(((F=x.mobile)==null?void 0:F.order)||999)});return M.jsx("div",{className:"flex flex-col",children:e.map((h,x)=>M.jsx(ti,{to:`/${t[0].key==="hash"?"block":"transaction"}/${h[t[0].key]}`,className:mt("hidden below-mobile:flex px-4 py-4 text-xs border-b border-surface-border last:border-b-0 hover:bg-surface-hover/50 transition-colors",x===0&&"rounded-t-xl",x===e.length-1&&"rounded-b-xl"),children:M.jsx("div",{className:"flex flex-col gap-2 justify-between w-full",children:S.map(v=>{var G,J;const F=h[v.key],Q=v.type||Z(v.key);return(G=v.mobile)!=null&&G.prominent&&Q==="number"?M.jsxs("div",{className:"flex w-full justify-between items-center",children:[M.jsx(vr,{variant:"blue",className:"text-nowrap text-xl",children:F}),h.finalityStatus&&M.jsx(vr,{variant:"status",status:h.finalityStatus,children:h.finalityStatus||"Finalized"})]},v.key):((J=v.mobile)==null?void 0:J.showLabel)!==!1?M.jsxs("div",{className:"flex gap-2 justify-between items-center",children:[M.jsx("span",{className:"text-text-muted text-sm",children:v.label}),M.jsx("span",{className:mt("text-sm",Q==="hash"||Q==="address"?"text-brand-purple font-mono":"text-text-primary"),children:Q==="hash"||Q==="address"?tl(F):
13Q==="timestamp"?Zm(F):Q==="fee"?M.jsx(vr,{variant:"orange",children:F}):F})]},v.key):null})})},h.hash||h.id||x))})},_=()=>r==="compact"?M.jsxs(M.Fragment,{children:[M.jsx("div",{className:"flex flex-col below-mobile:hidden",children:Array.from({length:R},(S,h)=>M.jsxs("div",{className:"flex justify-between items-center w-full px-4 py-3 border-b border-surface-border last:border-b-0",children:[M.jsx(Qr,{className:"!h-10 !w-20"}),M.jsx(Qr,{className:"!h-10 !w-32"}),M.jsx(Qr,{className:"!h-6 !w-24"})]},h))}),M.jsx("div",{className:"hidden below-mobile:flex flex-col",children:Array.from({length:R},(S,h)=>M.jsxs("div",{className:"flex flex-col gap-3 px-4 py-4 border-b border-surface-border last:border-b-0",children:[M.jsxs("div",{className:"flex justify-between items-center",children:[M.jsx(Qr,{className:"!h-6 !w-24"}),M.jsx(Qr,{className:"!h-5 !w-16"})]}),M.jsxs("div",{className:"flex justify-between items-center",children:[M.jsx(Qr,{className:"!h-4 !w-20"}),M.jsx(Qr,{className:"!h-4 !w-16"})]}),M.jsx(Qr,{className:"!h-4 !w-32"})]},h))})]}):M.jsxs(M.Fragment,{children:[M.jsx("div",{className:"flex flex-col below-mobile:hidden",children:Array.from({length:R},(S,h)=>M.jsxs("div",{className:"flex justify-between items-center px-4 h-[45px] border-b border-surface-border last:border-b-0",children:[M.jsx(Qr,{className:"!h-5 !w-32"}),M.jsx(Qr,{className:"!h-5 !w-24"}),M.jsx(Qr,{className:"!h-5 !w-20"}),M.jsx(Qr,{className:"!h-5 !w-16"})]},h))}),M.jsx("div",{className:"hidden below-mobile:flex flex-col",children:Array.from({length:R},(S,h)=>M.jsxs("div",{className:"flex flex-col gap-3 px-4 py-4 border-b border-surface-border last:border-b-0",children:[M.jsxs("div",{className:"flex justify-between items-center",children:[M.jsx(Qr,{className:"!h-6 !w-28"}),M.jsx(Qr,{className:"!h-5 !w-16"})]}),M.jsxs("div",{className:"flex justify-between items-center",children:[M.jsx(Qr,{className:"!h-4 !w-24"}),M.jsx(Qr,{className:"!h-4 !w-20"})]}),M.jsxs("div",{className:"flex justify-between items-center",children:[M.jsx(Qr,{className:"!h-4 !w-32"}),M.jsx(Qr,{className:"!h-4 !w-16"})]})]},h))})]}),B=(S=!1)=>{const h=r==="compact"?200:R*12,x=(w==null?void 0:w.toLowerCase())||"data";return M.jsx(DX,{dataType:x,minHeight:h,columns:t,isEmpty:S})};return M.jsxs("div",{className:mt("flex flex-col w-full bg-surface-card/50 border border-surface-border rounded-xl",(T=P[j])==null?void 0:T.borderTop,C),children:[(w||I)&&M.jsxs("div",{className:"flex justify-between items-center py-4 px-4 border-b border-surface-border bg-surface-card/80 rounded-t-xl",children:[M.jsxs("div",{className:"flex items-center gap-2",children:[O&&M.jsx("div",{className:mt("p-1.5 rounded-md",P[j].bg,P[j].text),children:O}),w&&M.jsx("h2",{className:"text-text-primary text-sm font-bold",children:w})]}),I&&M.jsx(St,{to:I,variant:"ghost",size:"sm",className:"group uppercase tracking-wide rounded-md",iconAfter:M.jsx("div",{className:"text-sm transition-transform group-hover:translate-x-0.5",children:"\xBB"}),children:"View All"})]}),ae(),i?B(!1):e.length===0&&!n?B(!0):M.jsxs("div",{className:"relative overflow-hidden",style:{minHeight:r==="detailed"?"900px":void 0},children:[r==="detailed"&&l&&M.jsx(MT,{filters:c,setFilters:l,filterTypes:u,isOpen:d,setIsOpen:p}),n?_():M.jsxs(M.Fragment,{children:[f(),g()]})]})]})};var $m=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Yf=typeof window>"u"||"Deno"in globalThis;function As(){}function $X(e,t){return typeof e=="function"?e(t):e}function a5(e){return typeof e=="number"&&e>=0&&e!==1/0}function AT(e,t){return Math.max(e+(t||0)-Date.now(),0)}function i0(e,t){return typeof e=="function"?e(t):e}function so(e,t){return typeof e=="function"?e(t):e}function CT(e,t){const{type:r="all",exact:n,fetchStatus:i,predicate:a,queryKey:s,stale:o}=e;if(s){if(n){if(t.queryHash!==s5(s,t.options))return!1}else if(!Wm(t.queryKey,s))return!1}if(r!=="all"){const c=t.isActive();if(r==="active"&&!c||r==="inactive"&&c)return!1}return!(typeof o=="boolean"&&t.isStale()!==o||i&&i!==t.state.fetchStatus||a&&!a(t))}function TT(e,t){const{exact:r,status:n,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(r){if(Hm(t.options.mutationKey)!==Hm(a))return!1}else if(!Wm(t.options.mutationKey,a))return!1}return!(n&&t.state.status!==n||i&&!i(t))}function s5(e,t){return((t==null?void 0:t.queryKeyHashFn)||Hm)(e)}function Hm(e){return JSON.stringify(e,(t,r)=>l5(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function Wm(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(r=>Wm(e[r],t[r])):!1}function jT(e,t){if(e===t)return e;const r=IT(e)&&IT(t);if(r||l5(e)&&l5(t)){const n=r?e:Object.keys(e),i=n.length,a=r?t:Object.keys(t),s=a.length,o=r?[]:{};let c=0;for(let l=0;l<s;l++){const u=r?l:a[l];(!r&&n.includes(u)||r)&&e[u]===void 0&&t[u]===void 0?(o[u]=void 0,c++):(o[u]=jT(e[u],t[u]),o[u]===e[u]&&e[u]!==void 0&&c++)}return i===s&&c===i?e:o}return t}function o5(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const r in e)if(e[r]!==t[r])return!1;return!0}function IT(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function l5(e){if(!OT(e))return!1;const t=e.constructor;if(t===void 0)return!0;const r=t.prototype;return!(!OT(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function OT(e){return Object.prototype.toString.call(e)==="[object Object]"}function HX(e){return new Promise(t=>{setTimeout(t,e)})}function c5(e,t,r){return typeof r.structuralSharing=="function"?r.structuralSharing(e,t):r.structuralSharing!==!1?jT(e,t):t}function WX(e,t,r=0){const n=[...e,t];return r&&n.length>r?n.slice(1):n}function KX(e,t,r=0){const n=[t,...e];return r&&n.length>r?n.slice(0,-1):n}var u5=Symbol();function BT(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===u5?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var GX=(Mq=class extends $m{constructor(){super();qt(this,Yh);qt(this,uf);qt(this,bp);vt(this,bp,t=>{if(!Yf&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){Se(this,uf)||this.setEventListener(Se(this,bp))}onUnsubscribe(){var t;this.hasListeners()||((t=Se(this,uf))==null||t.call(this),vt(this,uf,void 0))}setEventListener(t){var r;vt(this,bp,t),(r=Se(this,uf))==null||r.call(this),vt(this,uf,t(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(t){Se(this,Yh)!==t&&(vt(this,Yh,t),this.onFocus())}onFocus(){const t=this.isFocused();
vendor: 13,940 bytes, line 13
13this.listeners.forEach(r=>{r(t)})}isFocused(){var t;return typeof Se(this,Yh)=="boolean"?Se(this,Yh):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},Yh=new WeakMap,uf=new WeakMap,bp=new WeakMap,Mq),f5=new GX,YX=(Aq=class extends $m{constructor(){super();qt(this,yp,!0);qt(this,ff);qt(this,vp);vt(this,vp,t=>{if(!Yf&&window.addEventListener){const r=()=>t(!0),n=()=>t(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",n)}}})}onSubscribe(){Se(this,ff)||this.setEventListener(Se(this,vp))}onUnsubscribe(){var t;this.hasListeners()||((t=Se(this,ff))==null||t.call(this),vt(this,ff,void 0))}setEventListener(t){var r;vt(this,vp,t),(r=Se(this,ff))==null||r.call(this),vt(this,ff,t(this.setOnline.bind(this)))}setOnline(t){Se(this,yp)!==t&&(vt(this,yp,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return Se(this,yp)}},yp=new WeakMap,ff=new WeakMap,vp=new WeakMap,Aq),Nv=new YX;function h5(){let e,t;const r=new Promise((i,a)=>{e=i,t=a});r.status="pending",r.catch(()=>{});function n(i){Object.assign(r,i),delete r.resolve,delete r.reject}return r.resolve=i=>{n({status:"fulfilled",value:i}),e(i)},r.reject=i=>{n({status:"rejected",reason:i}),t(i)},r}function XX(e){return Math.min(1e3*2**e,3e4)}function RT(e){return(e??"online")==="online"?Nv.isOnline():!0}var NT=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function d5(e){return e instanceof NT}function FT(e){let t=!1,r=0,n=!1,i;const a=h5(),s=I=>{var R;n||(p(new NT(I)),(R=e.abort)==null||R.call(e))},o=()=>{t=!0},c=()=>{t=!1},l=()=>f5.isFocused()&&(e.networkMode==="always"||Nv.isOnline())&&e.canRun(),u=()=>RT(e.networkMode)&&e.canRun(),d=I=>{var R;n||(n=!0,(R=e.onSuccess)==null||R.call(e,I),i==null||i(),a.resolve(I))},p=I=>{var R;n||(n=!0,(R=e.onError)==null||R.call(e,I),i==null||i(),a.reject(I))},w=()=>new Promise(I=>{var R;i=C=>{(n||l())&&I(C)},(R=e.onPause)==null||R.call(e)}).then(()=>{var I;i=void 0,n||((I=e.onContinue)==null||I.call(e))}),O=()=>{if(n)return;let I;const R=r===0?e.initialPromise:void 0;try{I=R??e.fn()}catch(C){I=Promise.reject(C)}Promise.resolve(I).then(d).catch(C=>{var X;if(n)return;const j=e.retry??(Yf?0:3),N=e.retryDelay??XX,P=typeof N=="function"?N(r,C):N,Z=j===!0||typeof j=="number"&&r<j||typeof j=="function"&&j(r,C);if(t||!Z){p(C);return}r++,(X=e.onFail)==null||X.call(e,r,C),HX(P).then(()=>l()?void 0:w()).then(()=>{t?p(C):O()})})};return{promise:a,cancel:s,continue:()=>(i==null||i(),a),cancelRetry:o,continueRetry:c,canStart:u,start:()=>(u()?O():w().then(O),a)}}var JX=e=>setTimeout(e,0);function QX(){let e=[],t=0,r=o=>{o()},n=o=>{o()},i=JX;const a=o=>{t?e.push(o):i(()=>{r(o)})},s=()=>{const o=e;e=[],o.length&&i(()=>{n(()=>{o.forEach(c=>{r(c)})})})};return{batch:o=>{let c;t++;try{c=o()}finally{t--,t||s()}return c},batchCalls:o=>(...c)=>{a(()=>{o(...c)})},schedule:a,setNotifyFunction:o=>{r=o},setBatchNotifyFunction:o=>{n=o},setScheduler:o=>{i=o}}}var Ti=QX(),PT=(Cq=class{constructor(){qt(this,Xh)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),a5(this.gcTime)&&vt(this,Xh,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Yf?1/0:5*60*1e3))}clearGcTimeout(){Se(this,Xh)&&(clearTimeout(Se(this,Xh)),vt(this,Xh,void 0))}},Xh=new WeakMap,Cq),eJ=(Tq=class extends PT{constructor(t){super();qt(this,Po);qt(this,wp);qt(this,xp);qt(this,$s);qt(this,Jh);qt(this,aa);qt(this,m1);qt(this,Qh);vt(this,Qh,!1),vt(this,m1,t.defaultOptions),this.setOptions(t.options),this.observers=[],vt(this,Jh,t.client),vt(this,$s,Se(this,Jh).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,vt(this,wp,tJ(this.options)),this.state=t.state??Se(this,wp),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=Se(this,aa))==null?void 0:t.promise}setOptions(t){this.options={...Se(this,m1),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&Se(this,$s).remove(this)}setData(t,r){const n=c5(this.state.data,t,this.options);return Vt(this,Po,Kc).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(t,r){Vt(this,Po,Kc).call(this,{type:"setState",state:t,setStateOptions:r})}cancel(t){var n,i;const r=(n=Se(this,aa))==null?void 0:n.promise;return(i=Se(this,aa))==null||i.cancel(t),r?r.then(As).catch(As):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(Se(this,wp))}isActive(){return this.observers.some(t=>so(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===u5||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return this.state.isInvalidated?!0:this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0}isStaleByTime(t=0){return this.state.isInvalidated||this.state.data===void 0||!AT(this.state.dataUpdatedAt,t)}onFocus(){var t,r;(t=this.observers.find(n=>n.shouldFetchOnWindowFocus()))==null||t.refetch({cancelRefetch:!1}),(r=Se(this,aa))==null||r.continue()}onOnline(){var t,r;(t=this.observers.find(n=>n.shouldFetchOnReconnect()))==null||t.refetch({cancelRefetch:!1}),(r=Se(this,aa))==null||r.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),Se(this,$s).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(Se(this,aa)&&(Se(this,Qh)?Se(this,aa).cancel({revert:!0}):Se(this,aa).cancelRetry()),this.scheduleGc()),Se(this,$s).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Vt(this,Po,Kc).call(this,{type:"invalidate"})}fetch(t,r){var c,l,u;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(Se(this,aa))return Se(this,aa).continueRetry(),Se(this,aa).promise}if(t&&this.setOptions(t),!this.options.queryFn){const d=this.observers.find(p=>p.options.queryFn);d&&this.setOptions(d.options)}const n=new AbortController,i=d=>{Object.defineProperty(d,"signal",{enumerable:!0,get:()=>(vt(this,Qh,!0),n.signal)})},a=()=>{const d=BT(this.options,r),p={client:Se(this,Jh),queryKey:this.queryKey,meta:this.meta};return i(p),vt(this,Qh,!1),this.options.persister?this.options.persister(d,p,this):d(p)},s={fetchOptions:r,options:this.options,queryKey:this.queryKey,client:Se(this,Jh),state:this.state,fetchFn:a};i(s),(c=this.options.behavior)==null||c.onFetch(s,this),vt(this,xp,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((l=s.fetchOptions)==null?void 0:l.meta))&&Vt(this,Po,Kc).call(this,{type:"fetch",meta:(u=s.fetchOptions)==null?void 0:u.meta});const o=d=>{var p,w,O,I;d5(d)&&d.silent||Vt(this,Po,Kc).call(this,{type:"error",error:d}),d5(d)||((w=(p=Se(this,$s).config).onError)==null||w.call(p,d,this),(I=(O=Se(this,$s).config).onSettled)==null||I.call(O,this.state.data,d,this)),this.scheduleGc()};return vt(this,aa,FT({initialPromise:r==null?void 0:r.initialPromise,fn:s.fetchFn,abort:n.abort.bind(n),onSuccess:d=>{var p,w,O,I;if(d===void 0){o(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(d)}catch(R){o(R);return}(w=(p=Se(this,$s).config).onSuccess)==null||w.call(p,d,this),(I=(O=Se(this,$s).config).onSettled)==null||I.call(O,d,this.state.error,this),this.scheduleGc()},onError:o,onFail:(d,p)=>{Vt(this,Po,Kc).call(this,{type:"failed",failureCount:d,error:p})},onPause:()=>{Vt(this,Po,Kc).call(this,{type:"pause"})},onContinue:()=>{Vt(this,Po,Kc).call(this,{type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode,canRun:()=>!0})),Se(this,aa).start()}},wp=new WeakMap,xp=new WeakMap,$s=new WeakMap,Jh=new WeakMap,aa=new WeakMap,m1=new WeakMap,Qh=new WeakMap,Po=new WeakSet,Kc=function(t){const r=n=>{switch(t.type){case"failed":return{...n,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...zT(n.data,this.options),fetchMeta:t.meta??null};case"success":return{...n,data:t.data,dataUpdateCount:n.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const i=t.error;return d5(i)&&i.revert&&Se(this,xp)?{...Se(this,xp),fetchStatus:"idle"}:{...n,error:i,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...t.state}}};this.state=r(this.state),Ti.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),Se(this,$s).notify({query:this,type:"updated",action:t})})},Tq);function zT(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:RT(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function tJ(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,r=t!==void 0,n=r?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var rJ=(jq=class extends $m{constructor(t={}){super();qt(this,Rl);this.config=t,vt(this,Rl,new Map)}build(t,r,n){const i=r.queryKey,a=r.queryHash??s5(i,r);let s=this.get(a);return s||(s=new eJ({client:t,queryKey:i,queryHash:a,options:t.defaultQueryOptions(r),state:n,defaultOptions:t.getQueryDefaults(i)}),this.add(s)),s}add(t){Se(this,Rl).has(t.queryHash)||(Se(this,Rl).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const r=Se(this,Rl).get(t.queryHash);r&&(t.destroy(),r===t&&Se(this,Rl).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Ti.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return Se(this,Rl).get(t)}getAll(){return[...Se(this,Rl).values()]}find(t){const r={exact:!0,...t};return this.getAll().find(n=>CT(r,n))}findAll(t={}){const r=this.getAll();return Object.keys(t).length>0?r.filter(n=>CT(t,n)):r}notify(t){Ti.batch(()=>{this.listeners.forEach(r=>{r(t)})})}onFocus(){Ti.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Ti.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},Rl=new WeakMap,jq),nJ=(Iq=class extends PT{constructor(t){super();qt(this,Fl);qt(this,Nl);qt(this,pa);qt(this,ed);this.mutationId=t.mutationId,vt(this,pa,t.mutationCache),vt(this,Nl,[]),this.state=t.state||iJ(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){Se(this,Nl).includes(t)||(Se(this,Nl).push(t),this.clearGcTimeout(),Se(this,pa).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){vt(this,Nl,Se(this,Nl).filter(r=>r!==t)),this.scheduleGc(),Se(this,pa).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){Se(this,Nl).length||(this.state.status==="pending"?this.scheduleGc():Se(this,pa).remove(this))}continue(){var t;return((t=Se(this,ed))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var a,s,o,c,l,u,d,p,w,O,I,R,C,j,N,P,Z,X,re,ne;const r=()=>{Vt(this,Fl,Af).call(this,{type:"continue"})};vt(this,ed,FT({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(ae,ue)=>{Vt(this,Fl,Af).call(this,{type:"failed",failureCount:ae,error:ue})},onPause:()=>{Vt(this,Fl,Af).call(this,{type:"pause"})},onContinue:r,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>Se(this,pa).canRun(this)}));const n=this.state.status==="pending",i=!Se(this,ed).canStart();try{if(n)r();else{Vt(this,Fl,Af).call(this,{type:"pending",variables:t,isPaused:i}),await((s=(a=Se(this,pa).config).onMutate)==null?void 0:s.call(a,t,this));const ue=await((c=(o=this.options).onMutate)==null?void 0:c.call(o,t));ue!==this.state.context&&Vt(this,Fl,Af).call(this,{type:"pending",context:ue,variables:t,isPaused:i})}const ae=await Se(this,ed).start();return await((u=(l=Se(this,pa).config).onSuccess)==null?void 0:u.call(l,ae,t,this.state.context,this)),await((p=(d=this.options).onSuccess)==null?void 0:p.call(d,ae,t,this.state.context)),await((O=(w=Se(this,pa).config).onSettled)==null?void 0:O.call(w,ae,null,this.state.variables,this.state.context,this)),await((R=(I=this.options).onSettled)==null?void 0:R.call(I,ae,null,t,this.state.context)),Vt(this,Fl,Af).call(this,{type:"success",data:ae}),ae}catch(ae){try{throw await((j=(C=Se(this,pa).config).onError)==null?void 0:j.call(C,ae,t,this.state.context,this)),await((P=(N=this.options).onError)==null?void 0:P.call(N,ae,t,this.state.context)),await((X=(Z=Se(this,pa).config).onSettled)==null?void 0:X.call(Z,void 0,ae,this.state.variables,this.state.context,this)),await((ne=(re=this.options).onSettled)==null?void 0:ne.call(re,void 0,ae,t,this.state.context)),ae}finally{Vt(this,Fl,Af).call(this,{type:"error",error:ae})}}finally{Se(this,pa).runNext(this)}}},Nl=new WeakMap,pa=new WeakMap,ed=new WeakMap,Fl=new WeakSet,Af=function(t){const r=n=>{switch(t.type){case"failed":return{...n,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};
13case"pending":return{...n,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...n,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:t.error,failureCount:n.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Ti.batch(()=>{Se(this,Nl).forEach(n=>{n.onMutationUpdate(t)}),Se(this,pa).notify({mutation:this,type:"updated",action:t})})},Iq);function iJ(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var aJ=(Oq=class extends $m{constructor(t={}){super();qt(this,Uc);qt(this,zo);qt(this,g1);this.config=t,vt(this,Uc,new Set),vt(this,zo,new Map),vt(this,g1,0)}build(t,r,n){const i=new nJ({mutationCache:this,mutationId:++X2(this,g1)._,options:t.defaultMutationOptions(r),state:n});return this.add(i),i}add(t){Se(this,Uc).add(t);const r=Fv(t);if(typeof r=="string"){const n=Se(this,zo).get(r);n?n.push(t):Se(this,zo).set(r,[t])}this.notify({type:"added",mutation:t})}remove(t){if(Se(this,Uc).delete(t)){const r=Fv(t);if(typeof r=="string"){const n=Se(this,zo).get(r);if(n)if(n.length>1){const i=n.indexOf(t);i!==-1&&n.splice(i,1)}else n[0]===t&&Se(this,zo).delete(r)}}this.notify({type:"removed",mutation:t})}canRun(t){var n;const r=Fv(t);if(typeof r=="string"){const i=(n=Se(this,zo).get(r))==null?void 0:n.find(a=>a.state.status==="pending");return!i||i===t}else return!0}runNext(t){var n,i;const r=Fv(t);return typeof r=="string"?((i=(n=Se(this,zo).get(r))==null?void 0:n.find(a=>a!==t&&a.state.isPaused))==null?void 0:i.continue())??Promise.resolve():Promise.resolve()}clear(){Ti.batch(()=>{Se(this,Uc).forEach(t=>{this.notify({type:"removed",mutation:t})}),Se(this,Uc).clear(),Se(this,zo).clear()})}getAll(){return Array.from(Se(this,Uc))}find(t){const r={exact:!0,...t};return this.getAll().find(n=>TT(r,n))}findAll(t={}){return this.getAll().filter(r=>TT(t,r))}notify(t){Ti.batch(()=>{this.listeners.forEach(r=>{r(t)})})}resumePausedMutations(){const t=this.getAll().filter(r=>
vendor: 16,503 bytes, line 13
13r.state.isPaused);return Ti.batch(()=>Promise.all(t.map(r=>r.continue().catch(As))))}},Uc=new WeakMap,zo=new WeakMap,g1=new WeakMap,Oq);function Fv(e){var t;return(t=e.options.scope)==null?void 0:t.id}function LT(e){return{onFetch:(t,r)=>{var u,d,p,w,O;const n=t.options,i=(p=(d=(u=t.fetchOptions)==null?void 0:u.meta)==null?void 0:d.fetchMore)==null?void 0:p.direction,a=((w=t.state.data)==null?void 0:w.pages)||[],s=((O=t.state.data)==null?void 0:O.pageParams)||[];let o={pages:[],pageParams:[]},c=0;const l=async()=>{let I=!1;const R=N=>{Object.defineProperty(N,"signal",{enumerable:!0,get:()=>(t.signal.aborted?I=!0:t.signal.addEventListener("abort",()=>{I=!0}),t.signal)})},C=BT(t.options,t.fetchOptions),j=async(N,P,Z)=>{if(I)return Promise.reject();if(P==null&&N.pages.length)return Promise.resolve(N);const X={client:t.client,queryKey:t.queryKey,pageParam:P,direction:Z?"backward":"forward",meta:t.options.meta};R(X);const re=await C(X),{maxPages:ne}=t.options,ae=Z?KX:WX;return{pages:ae(N.pages,re,ne),pageParams:ae(N.pageParams,P,ne)}};if(i&&a.length){const N=i==="backward",P=N?sJ:DT,Z={pages:a,pageParams:s},X=P(n,Z);o=await j(Z,X,N)}else{const N=e??a.length;do{const P=c===0?s[0]??n.initialPageParam:DT(n,o);if(c>0&&P==null)break;o=await j(o,P),c++}while(c<N)}return o};t.options.persister?t.fetchFn=()=>{var I,R;return(R=(I=t.options).persister)==null?void 0:R.call(I,l,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=l}}}function DT(e,{pages:t,pageParams:r}){const n=t.length-1;return t.length>0?e.getNextPageParam(t[n],t,r[n],r):void 0}function sJ(e,{pages:t,pageParams:r}){var n;return t.length>0?(n=e.getPreviousPageParam)==null?void 0:n.call(e,t[0],t,r[0],r):void 0}var oJ=(Bq=class{constructor(e={}){qt(this,Cn);qt(this,hf);qt(this,df);qt(this,_p);qt(this,Sp);qt(this,pf);qt(this,kp);qt(this,Ep);vt(this,Cn,e.queryCache||new rJ),vt(this,hf,e.mutationCache||new aJ),vt(this,df,e.defaultOptions||{}),vt(this,_p,new Map),vt(this,Sp,new Map),vt(this,pf,0)}mount(){X2(this,pf)._++,Se(this,pf)===1&&(vt(this,kp,f5.subscribe(async e=>{e&&(await this.resumePausedMutations(),Se(this,Cn).onFocus())})),vt(this,Ep,Nv.subscribe(async e=>{e&&(await this.resumePausedMutations(),Se(this,Cn).onOnline())})))}unmount(){var e,t;X2(this,pf)._--,Se(this,pf)===0&&((e=Se(this,kp))==null||e.call(this),vt(this,kp,void 0),(t=Se(this,Ep))==null||t.call(this),vt(this,Ep,void 0))}isFetching(e){return Se(this,Cn).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return Se(this,hf).findAll({...e,status:"pending"}).length}getQueryData(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=Se(this,Cn).get(t.queryHash))==null?void 0:r.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),r=Se(this,Cn).build(this,t),n=r.state.data;return n===void 0?this.fetchQuery(e):(e.revalidateIfStale&&r.isStaleByTime(i0(t.staleTime,r))&&this.prefetchQuery(t),Promise.resolve(n))}getQueriesData(e){return Se(this,Cn).findAll(e).map(({queryKey:t,state:r})=>{const n=r.data;return[t,n]})}setQueryData(e,t,r){var s;const n=this.defaultQueryOptions({queryKey:e}),i=(s=Se(this,Cn).get(n.queryHash))==null?void 0:s.state.data,a=$X(t,i);if(a!==void 0)return Se(this,Cn).build(this,n).setData(a,{...r,manual:!0})}setQueriesData(e,t,r){return Ti.batch(()=>Se(this,Cn).findAll(e).map(({queryKey:n})=>[n,this.setQueryData(n,t,r)]))}getQueryState(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=Se(this,Cn).get(t.queryHash))==null?void 0:r.state}removeQueries(e){const t=Se(this,Cn);Ti.batch(()=>{t.findAll(e).forEach(r=>{t.remove(r)})})}resetQueries(e,t){const r=Se(this,Cn);return Ti.batch(()=>(r.findAll(e).forEach(n=>{n.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const r={revert:!0,...t},n=Ti.batch(()=>Se(this,Cn).findAll(e).map(i=>i.cancel(r)));return Promise.all(n).then(As).catch(As)}invalidateQueries(e,t={}){return Ti.batch(()=>(Se(this,Cn).findAll(e).forEach(r=>{r.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const r={...t,cancelRefetch:t.cancelRefetch??!0},n=Ti.batch(()=>Se(this,Cn).findAll(e).filter(i=>!i.isDisabled()).map(i=>{let a=i.fetch(void 0,r);return r.throwOnError||(a=a.catch(As)),i.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(n).then(As)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const r=Se(this,Cn).build(this,t);return r.isStaleByTime(i0(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(As).catch(As)}fetchInfiniteQuery(e){return e.behavior=LT(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(As).catch(As)}ensureInfiniteQueryData(e){return e.behavior=LT(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Nv.isOnline()?Se(this,hf).resumePausedMutations():Promise.resolve()}getQueryCache(){return Se(this,Cn)}getMutationCache(){return Se(this,hf)}getDefaultOptions(){return Se(this,df)}setDefaultOptions(e){vt(this,df,e)}setQueryDefaults(e,t){Se(this,_p).set(Hm(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...Se(this,_p).values()],r={};return t.forEach(n=>{Wm(e,n.queryKey)&&Object.assign(r,n.defaultOptions)}),r}setMutationDefaults(e,t){Se(this,Sp).set(Hm(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...Se(this,Sp).values()],r={};return t.forEach(n=>{Wm(e,n.mutationKey)&&Object.assign(r,n.defaultOptions)}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t={...Se(this,df).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=s5(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===u5&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...Se(this,df).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){Se(this,Cn).clear(),Se(this,hf).clear()}},Cn=new WeakMap,hf=new WeakMap,df=new WeakMap,_p=new WeakMap,Sp=new WeakMap,pf=new WeakMap,kp=new WeakMap,Ep=new WeakMap,Bq),lJ=(Rq=class extends $m{constructor(t,r){super();qt(this,Or);qt(this,Da);qt(this,xr);qt(this,b1);qt(this,ma);qt(this,td);qt(this,Mp);qt(this,mf);qt(this,gf);qt(this,y1);qt(this,Ap);qt(this,Cp);qt(this,rd);qt(this,nd);qt(this,bf);qt(this,Tp,new Set);this.options=r,vt(this,Da,t),vt(this,gf,null),vt(this,mf,h5()),this.options.experimental_prefetchInRender||Se(this,mf).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(r)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(Se(this,xr).addObserver(this),UT(Se(this,xr),this.options)?Vt(this,Or,U1).call(this):this.updateResult(),Vt(this,Or,t9).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return p5(Se(this,xr),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return p5(Se(this,xr),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,Vt(this,Or,r9).call(this),Vt(this,Or,n9).call(this),Se(this,xr).removeObserver(this)}setOptions(t){const r=this.options,n=Se(this,xr);if(this.options=Se(this,Da).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof so(this.options.enabled,Se(this,xr))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");Vt(this,Or,i9).call(this),Se(this,xr).setOptions(this.options),r._defaulted&&!o5(this.options,r)&&Se(this,Da).getQueryCache().notify({type:"observerOptionsUpdated",query:Se(this,xr),observer:this});const i=this.hasListeners();i&&qT(Se(this,xr),n,this.options,r)&&Vt(this,Or,U1).call(this),this.updateResult(),i&&(Se(this,xr)!==n||so(this.options.enabled,Se(this,xr))!==so(r.enabled,Se(this,xr))||i0(this.options.staleTime,Se(this,xr))!==i0(r.staleTime,Se(this,xr)))&&Vt(this,Or,JE).call(this);const a=Vt(this,Or,QE).call(this);i&&(Se(this,xr)!==n||so(this.options.enabled,Se(this,xr))!==so(r.enabled,Se(this,xr))||a!==Se(this,bf))&&Vt(this,Or,e9).call(this,a)}getOptimisticResult(t){const r=Se(this,Da).getQueryCache().build(Se(this,Da),t),n=this.createResult(r,t);return uJ(this,n)&&(vt(this,ma,n),vt(this,Mp,this.options),vt(this,td,Se(this,xr).state)),n}getCurrentResult(){return Se(this,ma)}trackResult(t,r){const n={};return Object.keys(t).forEach(i=>{Object.defineProperty(n,i,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(i),r==null||r(i),t[i])})}),n}trackProp(t){Se(this,Tp).add(t)}getCurrentQuery(){return Se(this,xr)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const r=Se(this,Da).defaultQueryOptions(t),n=Se(this,Da).getQueryCache().build(Se(this,Da),r);return n.fetch().then(()=>this.createResult(n,r))}fetch(t){return Vt(this,Or,U1).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),Se(this,ma)))}createResult(t,r){var re;const n=Se(this,xr),i=this.options,a=Se(this,ma),s=Se(this,td),o=Se(this,Mp),c=t!==n?t.state:Se(this,b1),{state:l}=t;let u={...l},d=!1,p;if(r._optimisticResults){const ne=this.hasListeners(),ae=!ne&&UT(t,r),ue=ne&&qT(t,n,r,i);(ae||ue)&&(u={...u,...zT(l.data,t.options)}),r._optimisticResults==="isRestoring"&&(u.fetchStatus="idle")}let{error:w,errorUpdatedAt:O,status:I}=u;p=u.data;let R=!1;if(r.placeholderData!==void 0&&p===void 0&&I==="pending"){let ne;a!=null&&a.isPlaceholderData&&r.placeholderData===(o==null?void 0:o.placeholderData)?(ne=a.data,R=!0):ne=typeof r.placeholderData=="function"?r.placeholderData((re=Se(this,Cp))==null?void 0:re.state.data,Se(this,Cp)):r.placeholderData,ne!==void 0&&(I="success",p=c5(a==null?void 0:a.data,ne,r),d=!0)}if(r.select&&p!==void 0&&!R)if(a&&p===(s==null?void 0:s.data)&&r.select===Se(this,y1))p=Se(this,Ap);else try{vt(this,y1,r.select),p=r.select(p),p=c5(a==null?void 0:a.data,p,r),vt(this,Ap,p),vt(this,gf,null)}catch(ne){vt(this,gf,ne)}Se(this,gf)&&(w=Se(this,gf),p=Se(this,Ap),O=Date.now(),I="error");const C=u.fetchStatus==="fetching",j=I==="pending",N=I==="error",P=j&&C,Z=p!==void 0,X={status:I,fetchStatus:u.fetchStatus,isPending:j,isSuccess:I==="success",isError:N,isInitialLoading:P,isLoading:P,data:p,dataUpdatedAt:u.dataUpdatedAt,error:w,errorUpdatedAt:O,failureCount:u.fetchFailureCount,failureReason:u.fetchFailureReason,errorUpdateCount:u.errorUpdateCount,isFetched:u.dataUpdateCount>0||u.errorUpdateCount>0,isFetchedAfterMount:u.dataUpdateCount>c.dataUpdateCount||u.errorUpdateCount>c.errorUpdateCount,isFetching:C,isRefetching:C&&!j,isLoadingError:N&&!Z,isPaused:u.fetchStatus==="paused",isPlaceholderData:d,isRefetchError:N&&Z,isStale:m5(t,r),refetch:this.refetch,promise:Se(this,mf)};if(this.options.experimental_prefetchInRender){const ne=m=>{X.status==="error"?m.reject(X.error):X.data!==void 0&&m.resolve(X.data)},ae=()=>{const m=vt(this,mf,X.promise=h5());ne(m)},ue=Se(this,mf);switch(ue.status){case"pending":t.queryHash===n.queryHash&&ne(ue);break;case"fulfilled":(X.status==="error"||X.data!==ue.value)&&ae();break;case"rejected":(X.status!=="error"||X.error!==ue.reason)&&ae();break}}return X}updateResult(){const t=Se(this,ma),r=this.createResult(Se(this,xr),this.options);if(vt(this,td,Se(this,xr).state),vt(this,Mp,this.options),Se(this,td).data!==void 0&&vt(this,Cp,Se(this,xr)),o5(r,t))return;vt(this,ma,r);const n=()=>{if(!t)return!0;const{notifyOnChangeProps:i}=this.options,a=typeof i=="function"?i():i;if(a==="all"||!a&&!Se(this,Tp).size)return!0;const s=new Set(a??Se(this,Tp));return this.options.throwOnError&&s.add("error"),Object.keys(Se(this,ma)).some(o=>{const c=o;return Se(this,ma)[c]!==t[c]&&s.has(c)})};Vt(this,Or,XV).call(this,{listeners:n()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&Vt(this,Or,t9).call(this)}},Da=new WeakMap,xr=new WeakMap,b1=new WeakMap,ma=new WeakMap,td=new WeakMap,Mp=new WeakMap,mf=new WeakMap,gf=new WeakMap,y1=new WeakMap,Ap=new WeakMap,Cp=new WeakMap,rd=new WeakMap,nd=new WeakMap,bf=new WeakMap,Tp=new WeakMap,Or=new WeakSet,U1=function(t){Vt(this,Or,i9).call(this);let r=Se(this,xr).fetch(this.options,t);return t!=null&&t.throwOnError||(r=r.catch(As)),r},JE=function(){Vt(this,Or,r9).call(this);const t=i0(this.options.staleTime,Se(this,xr));if(Yf||Se(this,ma).isStale||!a5(t))return;const r=AT(Se(this,ma).dataUpdatedAt,t)+1;vt(this,rd,setTimeout(()=>{Se(this,ma).isStale||this.updateResult()},r))},QE=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(Se(this,xr)):this.options.refetchInterval)??!1},e9=function(t){Vt(this,Or,n9).call(this),vt(this,bf,t),!(Yf||so(this.options.enabled,Se(this,xr))===!1||!a5(Se(this,bf))||Se(this,bf)===0)&&vt(this,nd,setInterval(()=>{(this.options.refetchIntervalInBackground||f5.isFocused())&&Vt(this,Or,U1).call(this)},Se(this,bf)))},t9=function(){Vt(this,Or,JE).call(this),Vt(this,Or,e9).call(this,Vt(this,Or,QE).call(this))},r9=function(){Se(this,rd)&&(clearTimeout(Se(this,rd)),vt(this,rd,void 0))},n9=function(){Se(this,nd)&&(clearInterval(Se(this,nd)),vt(this,nd,void 0))},i9=function(){const t=Se(this,Da).getQueryCache().build(Se(this,Da),this.options);if(t===Se(this,xr))return;const r=Se(this,xr);vt(this,xr,t),vt(this,b1,t.state),this.hasListeners()&&(r==null||r.removeObserver(this),t.addObserver(this))},XV=function(t){Ti.batch(()=>{t.listeners&&this.listeners.forEach(r=>{r(Se(this,ma))}),Se(this,Da).getQueryCache().notify({query:Se(this,xr),type:"observerResultsUpdated"})})},Rq);function cJ(e,t){return so(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function UT(e,t){return cJ(e,t)||e.state.data!==void 0&&p5(e,t,t.refetchOnMount)}function p5(e,t,r){if(so(t.enabled,e)!==!1){const n=typeof r=="function"?r(e):r;return n==="always"||n!==!1&&m5(e,t)}return!1}function qT(e,t,r,n){return(e!==t||so(n.enabled,e)===!1)&&(!r.suspense||e.state.status!=="error")&&m5(e,r)}function m5(e,t){return so(t.enabled,e)!==!1&&e.isStaleByTime(i0(t.staleTime,e))}function uJ(e,t){return!o5(e.getCurrentResult(),t)}var VT=he.createContext(void 0),ZT=e=>{const t=he.useContext(VT);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},fJ=({client:e,children:t})=>(he.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),M.jsx(VT.Provider,{value:e,children:t})),$T=he.createContext(!1),hJ=()=>he.useContext($T);$T.Provider;function dJ(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var pJ=he.createContext(dJ()),mJ=()=>he.useContext(pJ);function gJ(e,t){return typeof e=="function"?e(...t):!!e}function HT(){}var bJ=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},yJ=e=>{he.useEffect(()=>{e.clearReset()},[e])},vJ=({result:e,errorResetBoundary:t,throwOnError:r,query:n,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&n&&(i&&e.data===void 0||gJ(r,[e.error,n])),wJ=e=>{const t=e.staleTime;e.suspense&&(e.staleTime=typeof t=="function"?(...r)=>Math.max(t(...r),1e3):Math.max(t??1e3,1e3),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3)))},xJ=(e,t)=>e.isLoading&&e.isFetching&&!t,_J=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,WT=(e,t,r)=>t.fetchOptimistic(e).catch(()=>{r.clearReset()});function SJ(e,t,r){var d,p,w,O,I,R;const n=ZT(),i=hJ(),a=mJ(),s=n.defaultQueryOptions(e);(p=(d=n.getDefaultOptions().queries)==null?void 0:d._experimental_beforeQuery)==null||p.call(d,s),s._optimisticResults=i?"isRestoring":"optimistic",wJ(s),bJ(s,a),yJ(a);const o=!n.getQueryCache().get(s.queryHash),[c]=he.useState(()=>new t(n,s)),l=c.getOptimisticResult(s),u=!i&&e.subscribed!==!1;if(he.useSyncExternalStore(he.useCallback(C=>{const j=u?c.subscribe(Ti.batchCalls(C)):HT;return c.updateResult(),j},[c,u]),()=>c.getCurrentResult(),()=>c.getCurrentResult()),he.useEffect(()=>{c.setOptions(s)},[s,c]),_J(s,l))throw WT(s,c,a);if(vJ({result:l,errorResetBoundary:a,throwOnError:s.throwOnError,query:n.getQueryCache().get(s.queryHash),suspense:s.suspense}))throw l.error;return(O=(w=n.getDefaultOptions().queries)==null?void 0:w._experimental_afterQuery)==null||O.call(w,s,l),s.experimental_prefetchInRender&&!Yf&&xJ(l,i
13)&&((R=o?WT(s,c,a):(I=n.getQueryCache().get(s.queryHash))==null?void 0:I.promise)==null||R.catch(HT).finally(()=>{c.updateResult()})),s.notifyOnChangeProps?l:c.trackResult(l)}function Vn(e,t){return SJ(e,lJ)}const KT=10,kJ=()=>{var O;const[e,t]=he.useState(null),{network:r}=di(),[n,i]=he.useState([]),[a,s]=he.useState(new Set),[o,c]=he.useState(new Set),l=he.useRef([]),u=he.useRef(!0),d=Vn({queryKey:["latestBlocks",r],queryFn:()=>VC(1,KT,{},r),refetchInterval:35e3,onError:I=>{console.error("Failed to fetch blocks:",I),t("Failed to fetch blocks. Please try again later.")}}),p=((O=d.data)==null?void 0:O.blocks)||[],w=he.useRef(r);return he.useEffect(()=>{if(p.length===0)return;w.current!==r&&(w.current=r,u.current=!0,l.current=[]);const I=l.current,R=new Set(I.map(j=>j.number)),C=p.filter(j=>!R.has(j.number));if(u.current||I.length===0||C.length===p.length)i(p),u.current=!1;else if(C.length>0){const j=new Set(p.map(re=>re.number)),N=I.filter(re=>!j.has(re.number)),P=new Set(C.map(re=>re.hash)),Z=new Set(N.map(re=>re.hash));s(P),c(Z),i(p);const X=setTimeout(()=>{s(new Set),c(new Set)},500);return()=>clearTimeout(X)}else i(p);l.current=p},[p,r]),M.jsx(ac,{data:n,columns:[{label:"Block",width:"25%",group:[{key:"number",type:"blockLink"},{key:"timestamp",type:"age"}]},{label:"Details",width:"45%",group:[{key:"hash",type:"hashDisplay"},{key:"feeRecipient",type:"addressDisplay",prefix:"Builder: "}]},{label:"Status",width:"30%",align:"right",group:[{key:"finalityStatus",type:"status"}]}],variant:"compact",loading:d.isLoading,error:e,title:"Latest Blocks",titleIcon:M.jsx(Zf,{className:"w-5 h-5"}),viewAllLink:"/blocks",limit:KT,animatedRows:{newIds:a,exitingIds:o}})},GT=10,EJ=()=>{var O;const[e,t]=he.useState(null),{network:r}=di(),[n,i]=he.useState([]),[a,s]=he.useState(new Set),[o,c]=he.useState(new Set),l=he.useRef([]),u=he.useRef(!0),d=Vn({queryKey:["latestTransactions",r],queryFn:()=>HC(1,GT,{},r),refetchInterval:35e3,onError:I=>{console.error("Failed to fetch transactions:",I),t("Failed to fetch transactions. Please try again later.")}}),p=((O=d.data)==null?void 0:O.transactions)||[],w=he.useRef(r);return he.useEffect(()=>{if(p.length===0)return;w.current!==r&&(w.current=r,u.current=!0,l.current=[]);const I=l.current,R=new Set(I.map(j=>j.hash)),C=p.filter(j=>!R.has(j.hash));if(u.current||I.length===0||C.length===p.length)i(p),u.current=!1;else if(C.length>0){const j=new Set(p.map(re=>re.hash)),N=I.filter(re=>!j.has(re.hash)),P=new Set(C.map(re=>re.hash)),Z=new Set(N.map(re=>re.hash));s(P),c(Z),i(p);const X=setTimeout(()=>{s(new Set),c(new Set)},500);return()=>clearTimeout(X)}else i(p);l.current=p},[p,r]),M.jsx(ac,{data:n,columns:[{label:"TX Hash",width:"30%",group:[{key:"hash",type:"txLink"},{key:"timestamp",type:"age"}]},{label:"Block Info",width:"40%",group:[{key:"blockNumber",type:"blockLink"},{key:"transactionFee",type:"fee"}]},{label:"Status",width:"30%",align:"right",group:[{key:"finalityStatus",type:"status"}]}],variant:"compact",loading:d.isLoading,error:e,title:"Latest Transactions",titleIcon:M.jsx(Wd,{className:"w-5 h-5"}),viewAllLink:"/transactions",limit:GT,theme:"tx",animatedRows:{newIds:a,exitingIds:o}})};var YT={exports:{}};(function(e,t){(function(r,n){e.exports=n()})(dt,function(){return function(r){var n={};function i(a){if(n[a])return n[a].exports;var s=n[a]={exports:{},id:a,loaded:!1};return r[a].call(s.exports,s,s.exports,i),s.loaded=!0,s.exports}return i.m=r,i.c=n,i.p="",i(0)}([function(r,n,i){const a=i(1),s=i(2),o=new Array(4);function c(I){for(let R=0;R<o.length;R++)o[R]=0;for(let R=0;R<I.length;R++)o[R%4]=(o[R%4]<<5)-o[R%4]+I.charCodeAt(R)}function l(){const I=o[0]^o[0]<<11;return o[0]=o[1],o[1]=o[2],o[2]=o[3],o[3]=o[3]^o[3]>>19^I^I>>8,(o[3]>>>0)/2147483648}
13function u(){const I=Math.floor(l()*360),R=l()*60+40,C=(l()+l()+l()+l())*25;return[I/360,R/100,C/100]}function d(I){const R=I,C=I,j=Math.ceil(R/2),N=R-j,P=[];for(let Z=0;Z<C;Z++){let X=[];for(let ne=0;ne<j;ne++)X[ne]=Math.floor(l()*2.3);const re=X.slice(0,N).reverse();X=X.concat(re);for(let ne=0;ne<X.length;ne++)P.push(X[ne])}return P}function p(I,R,C,j,N,P){for(let Z=0;Z<j;Z++)for(let X=0;X<N;X++)I.buffer[I.index(R+Z,C+X)]=P}function w(I){if(!I.seed)throw new Error("No seed provided");return c(I.seed),Object.assign({size:8,scale:16,color:u(),bgcolor:u(),spotcolor:u()},I)}function O(I){const R=w({seed:I.toLowerCase()}),C=d(R.size),j=Math.sqrt(C.length),N=new a(R.size*R.scale,R.size*R.scale,3);N.color(...s(...R.bgcolor));const P=N.color(...s(...R.color)),Z=N.color(...s(...R.spotcolor));for(let X=0;X<C.length;X++){const re=Math.floor(X/j),ne=X%j;if(C[X]){const ae=C[X]==1?P:Z;p(N,ne*R.scale,re*R.scale,R.scale,R.scale,ae)}}return`data:image/png;base64,${N.getBase64()}`}r.exports=O},function(r,n){r.exports=function(i,a,s){function o(j,N){for(var P=2;P<arguments.length;P++)for(var Z=0;Z<arguments[P].length;Z++)j[N++]=arguments[P].charAt(Z)}function c(j){return String.fromCharCode(j>>8&255,j&255)}function l(j){return String.fromCharCode(j>>24&255,j>>16&255,j>>8&255,j&255)}function u(j){return String.fromCharCode(j&255,j>>8&255)}this.width=i,this.height=a,this.depth=s,this.pix_size=a*(i+1),this.data_size=2+this.pix_size+5*Math.floor((65534+this.pix_size)/65535)+4,this.ihdr_offs=0,this.ihdr_size=25,this.plte_offs=this.ihdr_offs+this.ihdr_size,this.plte_size=8+3*s+4,this.trns_offs=this.plte_offs+this.plte_size,this.trns_size=8+s+4,this.idat_offs=this.trns_offs+this.trns_size,this.idat_size=8+this.data_size+4,this.iend_offs=this.idat_offs+this.idat_size,this.iend_size=12,this.buffer_size=this.iend_offs+this.iend_size,this.buffer=new Array,this.palette=new Object,this.pindex=0;for(var d=new Array,p=0;p<this.buffer_size;p++)this.buffer[p]="\0";o(this.buffer,this.ihdr_offs,l(this.ihdr_size-12),"IHDR",l(i),l(a),"\b�"),o(this.buffer,this.plte_offs,l(this.plte_size-12),"PLTE"),o(this.buffer,this.trns_offs,l(this.trns_size-12),"tRNS"),o(this.buffer,this.idat_offs,l(this.idat_size-12),"IDAT"),o(this.buffer,this.iend_offs,l(this.iend_size-12),"IEND");var w=30912;w+=31-w%31,o(this.buffer,this.idat_offs+8,c(w));for(var p=0;(p<<16)-1<this.pix_size;p++){var O,I;p+65535<this.pix_size?(O=65535,I="\0"):(O=this.pix_size-(p<<16)-p,I="�"),o(this.buffer,this.idat_offs+8+2+(p<<16)+(p<<2),I,u(O),u(~O))}for(var p=0;p<256;p++){for(var R=p,C=0;C<8;C++)R&1?R=-306674912^R>>1&2147483647:R=R>>1&2147483647;d[p]=R}this.index=function(j,N){var P=N*(this.width+1)+j+1,Z=this.idat_offs+8+2+5*Math.floor(P/65535+1)+P;return Z},this.color=function(j,N,P,Z){Z=Z>=0?Z:255;var X=((Z<<8|j)<<8|N)<<8|P;if(typeof this.palette[X]>"u"){if(this.pindex==this.depth)return"\0";var re=this.plte_offs+8+3*this.pindex;this.buffer[re+0]=String.fromCharCode(j),this.buffer[re+1]=String.fromCharCode(N),this.buffer[re+2]=String.fromCharCode(P),this.buffer[this.trns_offs+8+this.pindex]=String.fromCharCode(Z),this.palette[X]=String.fromCharCode(this.pindex++)}return this.palette[X]},this.getBase64=function(){var j=this.getDump(),N="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",P,Z,X,re,ne,ae,ue,m=j.length,A=0,f="";do P=j.charCodeAt(A),re=P>>2,Z=j.charCodeAt(A+1),ne=(P&3)<<4|Z>>4,X=j.charCodeAt(A+2),m<A+2?ae=64:ae=(Z&15)<<2|X>>6,m<A+3?ue=64:ue=X&63,f+=N.charAt(re)+N.charAt(ne)+N.charAt(ae)+N.charAt(ue);while((A+=3)<m);return f},this.getDump=function(){for(var j=65521,N=5552,P=1,Z=0,X=N,re=0;re<this.height;re++)for(var ne=-1;ne<this.width;ne++)P+=this.buffer[this.index(ne,re)].charCodeAt(0),Z+=P,(X-=1)==0&&(P%=j,Z%=j,X=N);P%=j,Z%=j,o(this.buffer,this.idat_offs+this.idat_size-8,l(Z<<16|P));function ae(ue,m,A){for(var f=-1,g=4;g<A-4;g+=1)f=d[(f^ue[m+g].charCodeAt(0))&255]^f>>8&16777215;o(ue,m+A-4,l(f^-1))}return ae(this.buffer,this.ihdr_offs,this.ihdr_size),ae(this.buffer,this.plte_offs,this.plte_size),ae(this.buffer,this.trns_offs,this.trns_size),ae(this.buffer,this.idat_offs,this.idat_size),ae(this.buffer,this.iend_offs,this.iend_size),`\x89PNG\r
14�
15`+this.buffer.join("")}}},function(r,n){function i(s,o,c){return c<0&&(c+=1),c>1&&(c-=1),c<.16666666666666666?s+(o-s)*6*c:c<.5?o:c<.6666666666666666?s+(o-s)*(.6666666666666666-c)*6:s}function a(s,o,c){let l,u,d;if(o==0)l=u=d=c;else{const p=c<.5?c*(1+o):c+o-c*o,w=2*c-p;l=i(w,p,s+.3333333333333333),u=i(w,p,s),d=i(w,p,s-.3333333333333333)}return[Math.round(l*255),Math.round(u*255),Math.round(d*255),255]}r.exports=a}])})})(YT);var MJ=YT.exports;const XT=Nr(MJ),AJ=({itemCount:e=10,className:t=""})=>M.jsx(M.Fragment,{children:Array.from({length:e},(r,n)=>M.jsx(Qr,{className:`h-[48px] ${t}`},n))}
15),CJ="aztec_explorer_tags_",JT="aztec_explorer_tag_settings",QT=715,Km={transaction:{label:"Transaction",route:e=>`/tx/${e}`},block:{label:"Block",route:e=>`/block/${e}`},address:{label:"Address",route:e=>`/address/${e}`},contractClass:{label:"Contract Class",route:e=>`/class/${e}`},other:{label:"Other",route:null}},TJ=Object.keys(Km),jJ=64,IJ=256,OJ=1160,BJ=64,RJ=32,NJ=256,FJ=/^0x[a-fA-F0-9]+$/,ej=["__proto__","constructor","prototype","__defineGetter__","__defineSetter__"],Pv=(e,t)=>!e||typeof e!="string"?null:e.replace(/[<>{}[\]\\|`$]/g,"").trim().slice(0,t)||null,tj=e=>!e||typeof e!="string"||e.length>OJ||ej.includes(e)?!1:FJ.test(e)||/^[a-zA-Z0-9_-]+$/.test(e),rj=e=>{if(!e||typeof e!="object")return null;const t={tag:Pv(e.tag,jJ),description:Pv(e.description,IJ),fieldLabel:Pv(e.fieldLabel,BJ)||"Unknown",pageType:Pv(e.pageType,RJ)||"Unknown",pagePath:typeof e.pagePath=="string"&&e.pagePath.startsWith("/")?e.pagePath.slice(0,NJ):null,valueType:TJ.includes(e.valueType)?e.valueType:null,createdAt:typeof e.createdAt=="number"?e.createdAt:Date.now(),updatedAt:Date.now()};return!t.tag&&!t.description?null:t},nj={displayTagsInsteadOfValues:!0,displayNotePopovers:!0,allowHoverEffects:!0},ij=e=>`${CJ}${e}`,PJ=()=>{try{const e=localStorage.getItem(JT);if(e)return{...nj,...JSON.parse(e)}}catch(e){console.error("Error loading settings from localStorage:",e)}return nj},zJ=e=>{try{localStorage.setItem(JT,JSON.stringify(e))}catch(t){console.error("Error saving settings to localStorage:",t)}},g5=e=>{try{const t=localStorage.getItem(ij(e));if(t)return JSON.parse(t)}catch(t){console.error("Error loading tags from localStorage:",t)}return{}},LJ=(e,t)=>{var r;try{return localStorage.setItem(ij(e),JSON.stringify(t)),{success:!0}}catch(n){console.error("Error saving tags to localStorage:",n);const i=n.name==="QuotaExceededError"||((r=n.message)==null?void 0:r.includes("quota"))||n.code===22;return{success:!1,error:i?"Storage limit reached. Please delete some notes to add new ones.":n.message,isQuotaError:i}}},aj=he.createContext(),DJ=({children:e})=>{const{network:t}=di(),[r,n]=he.useState(()=>g5(t)),[i,a]=he.useState(()=>PJ()),[s,o]=he.useState(null),[c,l]=he.useState(()=>typeof window<"u"?window.innerWidth<=QT:!1);he.useEffect(()=>{const ae=()=>{l(window.innerWidth<=QT)};return window.addEventListener("resize",ae),()=>window.removeEventListener("resize",ae)},[]);const u=he.useMemo(()=>c?{...i,displayNotePopovers:!1,allowHoverEffects:!1}:i,[i,c]);he.useEffect(()=>{n(g5(t))},[t]),he.useEffect(()=>{const ae=LJ(t,r);ae.success?o(null):o(ae.error)},[r,t]),he.useEffect(()=>{zJ(i)},[i]);const d=he.useCallback((ae,ue)=>{a(m=>({...m,[ae]:ue}))},[]),p=he.useCallback(ae=>ae&&r[ae]||null,[r]),w=he.useCallback(ae=>ae?!!r[ae]:!1,[r]),O=he.useCallback((ae,ue)=>{if(!tj(ae))return console.warn("Invalid tag value:",ae),{success:!1,error:"Invalid value format"};const m=rj({...ue,createdAt:void 0});return m?(n(A=>{var f;return{...A,[ae]:{...m,createdAt:((f=A[ae])==null?void 0:f.createdAt)||Date.now()}}}),{success:!0}):(console.warn("Tag or description must be provided"),{success:!1,error:"Tag or description required"})},[]),I=he.useCallback(ae=>{ae&&n(ue=>{const m={...ue};return delete m[ae],m})},[]),R=he.useCallback(()=>{n({})},[]),C=he.useCallback((ae,ue=10)=>{var f,g;if(!ae||typeof ae!="string")return[];const m=ae.toLowerCase().trim();if(!m)return[];const A=[];for(const[_,B]of Object.entries(r)){const T=(f=B.tag)==null?void 0:f.toLowerCase().includes(m),S=(g=B.description)==null?void 0:g.toLowerCase().includes(m),h=_.toLowerCase().includes(m);if((T||S||h)&&A.push({value:_,...B,matchScore:T?3:S?2:1}),A.length>=ue*2)break}return A.sort((_,B)=>B.matchScore-_.matchScore).slice(0,ue)},[r]),j=he.useCallback((ae,ue)=>{var m;return ue!=null&&ue.pagePath?ue.pagePath:ue!=null&&ue.valueType&&((m=Km[ue.valueType])!=null&&m.route)?Km[ue.valueType].route(ae):null},[]),N=he.useCallback(()=>Object.entries(r).map(([ae,ue])=>({value:ae,...ue})),[r]),P=he.useCallback(ae=>{const ue=g5(ae);return Object.entries(ue).map(([m,A])=>({value:m,...A}))},[]),Z=he.useCallback(()=>JSON.stringify(r,null,2),[r]),X=he.useCallback((ae,ue=!0)=>{try{const m=JSON.parse(ae);if(!m||typeof m!="object"||Array.isArray(m))return{success:!1,error:"Invalid format"};const A={};for(const[f,g]of Object.entries(m)){if(ej.includes(f)||!tj(f))continue;const _=rj(g);_&&(A[f]=_)}return Object.keys(A).length===0?{success:!1,error:"No valid tags found"}:(n(ue?f=>({...f,...A}):A),{success:!0})}catch(m){return console.error("Error importing tags:",m),{success:!1,error:"Invalid file format"}}},[]),re=he.useCallback((ae,ue)=>{const m=p(ae);return m!=null&&m.tag?m.tag:ue||ae},[p]),ne=he.useCallback(()=>{o(null)},[]);return M.jsx(aj.Provider,{value:{tags:r,getTag:p,hasTag:w,setTag:O,removeTag:I,clearAllTags:R,getAllTags:N,getTagsForNetwork:P,searchTags:C,getTagRoute:j,exportTags:Z,importTags:X,getDisplayValue:re,settings:u,rawSettings:i,updateSetting:d,isMobile:c,storageError:s,clearStorageError:ne},children:e})},a0=()=>{const e=he.useContext(aj);if(!e)throw new Error("useTags must be used within a TagProvider");return e},_u={blocks:{label:"Blocks",icon:Zf,route:"block"},transactions:{label:"Txs",icon:Wd,route:"tx"},accounts:{label:"Addresses",icon:Nm,route:"address"},contractClasses:{label:"Classes",icon:hv,route:"class"},tags:{label:"Notes",icon:dv,route:null}},UJ=10,sj={none:"rounded-none",soft:"rounded-lg",medium:"rounded-xl",full:"rounded-2xl"}
15,b5=({className:e,height:t="md",maxWidth:r,roundness:n="medium",activeFilters:i,onFiltersChange:a,showFiltersInDropdown:s=!0})=>{const[o,c]=he.useState(""),[l,u]=he.useState(""),[d,p]=he.useState(!1),[w,O]=he.useState(-1),[I,R]=he.useState(!1),[C,j]=he.useState([]),{network:N}=di(),{searchTags:P,getTagRoute:Z}=a0(),X=i!==void 0?i:C,re=a||j,ne=he.useRef(null),ae=he.useRef(null),ue=he.useRef(null),m=Y=>{re(V=>V.includes(Y)?V.filter(W=>W!==Y):[...V,Y]),O(-1)};he.useEffect(()=>{if(!o||Number(o)===0)return;const Y=setTimeout(()=>{u(o.toLowerCase()),p(!0),O(-1)},500);return()=>clearTimeout(Y)},[o]);const{data:A,isLoading:f,isFetching:g,isError:_}=Vn({queryKey:["search",l,N],queryFn:()=>gY(l,N),enabled:!!l,staleTime:3e4,refetchOnWindowFocus:!1}),B=f||g,T=he.useMemo(()=>{const Y=Object.keys(_u);if(X.length===0)return Y.reduce((W,ce)=>(W[ce]=2,W),{});const V=Math.floor(UJ/X.length);return Y.reduce((W,ce)=>(W[ce]=X.includes(ce)?V:0,W),{})},[X]),S=he.useMemo(()=>{if(!l)return[];const Y=T.tags||0;return Y===0&&X.length>0?[]:P(l,Y||2)},[l,T,X,P]),h=he.useMemo(()=>{const Y={};return Object.keys(_u).forEach(V=>{const W=T[V];if(V==="tags")Y[V]=S;else if(V==="transactions"&&A){const ce=A.transactions||[],pe=A.pendingTransactions||[];Y[V]=[...ce,...pe].slice(0,W)}else V!=="pendingTransactions"&&A&&(Y[V]=(A[V]||[]).slice(0,W))}),Y},[A,T,S]),x=he.useMemo(()=>{const Y=A&&Object.keys(_u).some(W=>{if(W==="tags")return!1;const ce=h[W];return ce&&ce.length>0}),V=S.length>0;return!Y&&!V},[A,h,S]),v=he.useMemo(()=>Object.values(h).reduce((Y,V)=>Y+((V==null?void 0:V.length)||0),0),[h]),F=(Y,V)=>V==="accounts"?`/address/${Y.address}`:V==="contractClasses"?`/class/${Y.contractClassID||Y.id}`:V==="transactions"?`/tx/${Y.hash}`:`/block/${Y.hash}`,Q=(Y,V)=>{Y&&(window.location.href=F(Y,V))};he.useEffect(()=>{const Y=V=>{if(!(!d||!A||v===0))switch(V.key){case"ArrowDown":V.preventDefault(),O(W=>W>=v-1?0:W+1);break;case"ArrowUp":V.preventDefault(),O(W=>W<=0?v-1:W-1);break;case"Enter":if(V.preventDefault(),w>=0){let W=-1,ce=null,pe=null;const ee=["tags","accounts","contractClasses","blocks","transactions"];for(const se of ee){const ve=h[se]||[];for(const _e of ve)if(W++,W===w){ce=_e,pe=se;break}if(ce)break}if(ce&&pe){if(pe==="tags"){const se=Z(ce.value,ce);se&&(window.location.href=se)}else Q(ce,pe);return}}R(!0);break}};return ae.current&&ae.current.addEventListener("keydown",Y),()=>{ae.current&&ae.current.removeEventListener("keydown",Y)}},[d,A,w,v,h]),he.useEffect(()=>{const Y=V=>{ne.current&&!ne.current.contains(V.target)&&ae.current!==V.target&&p(!1)};return document.addEventListener("mousedown",Y),()=>{document.removeEventListener("mousedown",Y)}},[]),he.useEffect(()=>{if(w>=0&&ue.current&&ne.current){if(w===0){ne.current.scrollTo({top:0,behavior:"smooth"});return}else if(w===v-1){ne.current.scrollTo({top:ne.current.scrollHeight,behavior:"smooth"});return}ue.current.scrollIntoView({behavior:"smooth",block:"nearest"})}},[w,v]),he.useEffect(()=>{if(I&&!B&&!x){const Y=["tags","accounts","contractClasses","blocks","transactions"];for(const V of Y){const W=h[V];if(W&&W.length>0){if(V==="tags"){const ce=Z(W[0].value,W[0]);if(ce){window.location.href=ce;break}continue}Q(W[0],V);break}}R(!1)}},[I,B,x,h,Z]);const G=()=>s?M.jsx("div",{className:"flex items-center gap-1 px-1 pb-3 border-b border-surface-border",children:Object.entries(_u).map(([Y,V])=>{var ee,se,ve;const W=V.icon,ce=X.includes(Y);let pe=!1;return Y==="tags"?pe=S.length>0:Y==="transactions"?pe=((ee=A==null?void 0:A.transactions)==null?void 0:ee.length)>0||((se=A==null?void 0:A.pendingTransactions)==null?void 0:se.length)>0:pe=((ve=A==null?void 0:A[Y])==null?void 0:ve.length)>0,M.jsxs("button",{onClick:()=>m(Y),className:mt("flex items-center gap-1.5 px-2 py-1 rounded-full text-[10px] font-medium transition-all border",ce?"bg-brand-purple text-white border-brand-purple":"bg-surface-main text-text-muted hover:bg-surface-hover hover:text-text-primary border-surface-border",!pe&&"opacity-50"),children:[M.jsx(W,{className:"w-3 h-3"}),V.label]},Y)})}):null,J=()=>{let Y=-1;const V=ee=>{const se=h[ee];if(!se||se.length===0)return null;const ve=_u[ee].icon,_e=ee==="contractClasses"?"Contract Classes":ee.charAt(0).toUpperCase()+ee.slice(1);return M.jsxs("div",{className:"flex flex-col gap-2",children:[M.jsxs("div",{className:"flex items-center gap-2 text-text-primary text-xs border-b pb-1 border-surface-border",children:[M.jsx(ve,{className:"w-3.5 h-3.5 text-text-muted"}),M.jsx("span",{className:"font-medium",children:_e}),M.jsxs("span",{className:"text-text-muted",children:["(",se.length,")"]})]}),se.map((Ue,xe)=>{if(!Ue)return null;Y++;const Te=Y===w,$e=ee==="contractClasses"?(Ue==null?void 0:Ue.id)||(Ue==null?void 0:Ue.contractClassID):ee==="accounts"?Ue.address:Ue.hash;return M.jsxs(ti,{onClick:()=>p(!1),to:F(Ue,ee),ref:Te?ue:null,className:mt("text-text-primary font-extralight rounded-md text-sm p-2 flex items-center gap-3 cursor-pointer overflow-hidden",Te?"bg-surface-border":"hover:bg-surface-hover"),onMouseEnter:()=>O(Y),children:[M.jsx("img",{className:"h-7 w-7 rounded-full flex-shrink-0",src:XT($e),alt:""}),M.jsx("p",{className:"font-normal truncate font-mono text-xs",children:$e})]},`${ee}-${xe}`)})]})},W=()=>{const ee=h.tags;if(!ee||ee.length===0)return null;const se=_u.tags.icon;return M.jsxs("div",{className:"flex flex-col gap-2",children:[M.jsxs("div",{className:"flex items-center gap-2 text-text-primary text-xs border-b pb-1 border-surface-border",children:[M.jsx(se,{className:"w-3.5 h-3.5 text-text-muted"}),M.jsx("span",{className:"font-medium",children:"Your Notes"}),M.jsxs("span",{className:"text-text-muted",children:["(",ee.length,")"]})]}),ee.map((ve,_e)=>{if(!ve)return null;Y++;const Ue=Y===w,xe=Z(ve.value,ve),Te=M.jsxs("div",{className:mt("text-text-primary font-extralight rounded-md text-sm p-2 flex items-center gap-3 overflow-hidden",Ue?"bg-surface-border":"hover:bg-surface-hover",xe?"cursor-pointer":"cursor-default"),onMouseEnter:()=>O(Y),children:[M.jsx("img",{className:"h-7 w-7 rounded-full flex-shrink-0",src:XT(ve.value),alt:""}),M.jsxs("div",{className:"flex flex-col min-w-0 flex-1",children:[M.jsxs("div",{className:"flex items-center gap-2",children:[ve.tag&&M.jsx("span",{className:"font-medium text-brand-purple text-xs",children:ve.tag}),M.jsx("span",{className:"font-mono text-[10px] text-text-muted truncate",children:tl(ve.value)})]}),ve.description&&M.jsx("p",{className:"text-[10px] text-text-muted truncate",children:ve.description})]})]});return xe?M.jsx(ti,{onClick:()=>p(!1),to:xe,ref:Ue?ue:null,children:Te},`tag-${_e}`):M.jsx("div",{ref:Ue?ue:null,children:Te},`tag-${_e}`)})]})},ce=()=>{const ee=X.length>0?`No ${X.map(se=>_u[se].label.toLowerCase()).join(", ")} found`:"Search does not match any blocks, transactions or contracts!";return M.jsx("div",{className:"font-light text-text-muted text-sm py-2",children:ee})},pe=S.length>0&&!A;return M.jsxs("div",{ref:ne,className:mt("absolute top-[calc(100%+8px)] max-h-[60vh] w-full flex flex-col bg-surface-card border border-surface-border p-3 overflow-y-auto gap-3 backdrop-blur-lg",sj[n]||sj.medium,(!o||!d)&&"hidden"),children:[G(),B&&!pe?M.jsx(AJ,{itemCount:5}):x||_?M.jsx(M.Fragment,{children:ce()}):M.jsxs("div",{className:"flex flex-col gap-4",children:[W(),V("accounts"),V("contractClasses"),V("blocks"),V("transactions")]})]})};return M.jsxs("div",{className:mt("relative w-full max-w-[500px] z-30",e),children:[M.jsx(Vr,{ref:ae,height:t,roundness:n,value:o,onChange:Y=>c(Y.target.value),placeholder:"Search by Address, Tx Hash, Block, or Contract...",leftIcon:M.jsx(pv,{className:"h-5 w-5"}),rightElement:M.jsxs(St,{variant:"purple",size:"sm",roundness:n,iconBefore:B?M.jsx($W,{className:"h-4 w-4 animate-spin"}):null,children:["SEARCH ",M.jsx("span",{className:"mt-0.5",children:"\u21B5"})]}),onFocus:()=>p(!0),onKeyDown:Y=>{Y.key==="Enter"&&(!d||B)&&(Y.preventDefault(),R(!0))},containerClassName:mt("w-full",r)}),J()]})};function Gm(e){return e+.5|0}const Su=(e,t,r)=>
vendor: 6,244 bytes, line 15
15Math.max(Math.min(e,r),t);function Ym(e){return Su(Gm(e*2.55),0,255)}function ku(e){return Su(Gm(e*255),0,255)}function sc(e){return Su(Gm(e/2.55)/100,0,1)}function oj(e){return Su(Gm(e*100),0,100)}const Cs={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},y5=[..."0123456789ABCDEF"],qJ=e=>y5[e&15],VJ=e=>y5[(e&240)>>4]+y5[e&15],zv=e=>(e&240)>>4===(e&15),ZJ=e=>zv(e.r)&&zv(e.g)&&zv(e.b)&&zv(e.a);function $J(e){var t=e.length,r;return e[0]==="#"&&(t===4||t===5?r={r:255&Cs[e[1]]*17,g:255&Cs[e[2]]*17,b:255&Cs[e[3]]*17,a:t===5?Cs[e[4]]*17:255}:(t===7||t===9)&&(r={r:Cs[e[1]]<<4|Cs[e[2]],g:Cs[e[3]]<<4|Cs[e[4]],b:Cs[e[5]]<<4|Cs[e[6]],a:t===9?Cs[e[7]]<<4|Cs[e[8]]:255})),r}const HJ=(e,t)=>e<255?t(e):"";function WJ(e){var t=ZJ(e)?qJ:VJ;return e?"#"+t(e.r)+t(e.g)+t(e.b)+HJ(e.a,t):void 0}const KJ=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function lj(e,t,r){const n=t*Math.min(r,1-r),i=(a,s=(a+e/30)%12)=>r-n*Math.max(Math.min(s-3,9-s,1),-1);return[i(0),i(8),i(4)]}function GJ(e,t,r){const n=(i,a=(i+e/60)%6)=>r-r*t*Math.max(Math.min(a,4-a,1),0);return[n(5),n(3),n(1)]}function YJ(e,t,r){const n=lj(e,1,.5);let i;for(t+r>1&&(i=1/(t+r),t*=i,r*=i),i=0;i<3;i++)n[i]*=1-t-r,n[i]+=t;return n}function XJ(e,t,r,n,i){return e===i?(t-r)/n+(t<r?6:0):t===i?(r-e)/n+2:(e-t)/n+4}function v5(e){const t=e.r/255,r=e.g/255,n=e.b/255,i=Math.max(t,r,n),a=Math.min(t,r,n),s=(i+a)/2;let o,c,l;return i!==a&&(l=i-a,c=s>.5?l/(2-i-a):l/(i+a),o=XJ(t,r,n,l,i),o=o*60+.5),[o|0,c||0,s]}function w5(e,t,r,n){return(Array.isArray(t)?e(t[0],t[1],t[2]):e(t,r,n)).map(ku)}function x5(e,t,r){return w5(lj,e,t,r)}function JJ(e,t,r){return w5(YJ,e,t,r)}function QJ(e,t,r){return w5(GJ,e,t,r)}function cj(e){return(e%360+360)%360}function eQ(e){const t=KJ.exec(e);let r=255,n;if(!t)return;t[5]!==n&&(r=t[6]?Ym(+t[5]):ku(+t[5]));const i=cj(+t[2]),a=+t[3]/100,s=+t[4]/100;return t[1]==="hwb"?n=JJ(i,a,s):t[1]==="hsv"?n=QJ(i,a,s):n=x5(i,a,s),{r:n[0],g:n[1],b:n[2],a:r}}function tQ(e,t){var r=v5(e);r[0]=cj(r[0]+t),r=x5(r),e.r=r[0],e.g=r[1],e.b=r[2]}function rQ(e){if(!e)return;const t=v5(e),r=t[0],n=oj(t[1]),i=oj(t[2]);return e.a<255?`hsla(${r}, ${n}%, ${i}%, ${sc(e.a)})`:`hsl(${r}, ${n}%, ${i}%)`}const uj={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},fj={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0",lime:"ff00",limegYF:"32cd32",lRF:"faf0e6",magFta:"ff00ff",maPon:"800000",VaquamarRe:"66cdaa",VXe:"cd",VScEd:"ba55d3",VpurpN:"9370db",VsHgYF:"3cb371",VUXe:"7b68ee",VsprRggYF:"fa9a",VQe:"48d1cc",VviTetYd:"c71585",midnightXe:"191970",mRtcYam:"f5fffa",mistyPse:"ffe4e1",moccasR:"ffe4b5",navajowEte:"ffdead",navy:"80",Tdlace:"fdf5e6",Tive:"808000",TivedBb:"6b8e23",Sange:"ffa500",SangeYd:"ff4500",ScEd:"da70d6",pOegTMnPd:"eee8aa",pOegYF:"98fb98",pOeQe:"afeeee",pOeviTetYd:"db7093",papayawEp:"ffefd5",pHKpuff:"ffdab9",peru:"cd853f",pRk:"ffc0cb",plum:"dda0dd",powMrXe:"b0e0e6",purpN:"800080",YbeccapurpN:"663399",Yd:"ff0000",Psybrown:"bc8f8f",PyOXe:"4169e1",saddNbPwn:"8b4513",sOmon:"fa8072",sandybPwn:"f4a460",sHgYF:"2e8b57",sHshell:"fff5ee",siFna:"a0522d",silver:"c0c0c0",skyXe:"87ceeb",UXe:"6a5acd",UWay:"708090",UgYy:"708090",snow:"fffafa",sprRggYF:"ff7f",stAlXe:"4682b4",tan:"d2b48c",teO:"8080",tEstN:"d8bfd8",tomato:"ff6347",Qe:"40e0d0",viTet:"ee82ee",JHt:"f5deb3",wEte:"ffffff",wEtesmoke:"f5f5f5",Lw:"ffff00",LwgYF:"9acd32"};function nQ(){const e={},t=Object.keys(fj),r=Object.keys(uj);let n,i,a,s,o;for(n=0;n<t.length;n++){for(s=o=t[n],i=0;i<r.length;i++)a=r[i],o=o.replace(a,uj[a]);a=parseInt(fj[s],16),e[o]=[a>>16&255,a>>8&255,a&255]}return e}let Lv;function iQ(e){Lv||(Lv=nQ(),Lv.transparent=[0,0,0,0]);const t=Lv[e.toLowerCase()];return t&&{r:t[0],g:t[1],b:t[2],a:t.length===4?t[3]:255}}const aQ=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;function sQ(e){const t=aQ.exec(e);let r=255,n,i,a;if(t){if(t[7]!==n){const s=+t[7];r=t[8]?Ym(s):Su(s*255,0,255)}return n=+t[1],i=+t[3],a=+t[5],n=255&(t[2]?Ym(n):Su(n,0,255)),i=255&(t[4]?Ym(i):Su(i,0,255)),a=255&(t[6]?Ym(a):Su(a,0,255)),{r:n,g:i,b:a,a:r}}}function oQ(e){return e&&(e.a<255?`rgba(${e.r}, ${e.g}, ${e.b}, ${sc(e.a)})`:`rgb(${e.r}, ${e.g}, ${e.b})`)}const _5=e=>e<=.0031308?e*12.92:Math.pow(e,1/2.4)*1.055-.055,s0=e=>e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4);function lQ(e,t,r){const n=s0(sc(e.r)),i=s0(sc(e.g)),a=s0(sc(e.b));return{r:ku(_5(n+r*(s0(sc(t.r))-n))),g:ku(_5(i+r*(s0(sc(t.g))-i))),b:ku(_5(a+r*(s0(sc(t.b))-a))),a:e.a+r*(t.a-e.a)}}function Dv(e,t,r){if(e){let n=v5(e);n[t]=Math.max(0,Math.min(n[t]+n[t]*r,t===0?360:1)),n=x5(n),e.r=n[0],e.g=n[1],e.b=n[2]}}function hj(e,t){return e&&Object.assign(t||{},e)}function dj(e){var t={r:0,g:0,b:0,a:255};return Array.isArray(e)?e.length>=3&&(t={r:e[0],g:e[1],b:e[2],a:255},e.length>
vendor: 10,518 bytes, line 15
153&&(t.a=ku(e[3]))):(t=hj(e,{r:0,g:0,b:0,a:1}),t.a=ku(t.a)),t}function cQ(e){return e.charAt(0)==="r"?sQ(e):eQ(e)}class Xm{constructor(t){if(t instanceof Xm)return t;const r=typeof t;let n;r==="object"?n=dj(t):r==="string"&&(n=$J(t)||iQ(t)||cQ(t)),this._rgb=n,this._valid=!!n}get valid(){return this._valid}get rgb(){var t=hj(this._rgb);return t&&(t.a=sc(t.a)),t}set rgb(t){this._rgb=dj(t)}rgbString(){return this._valid?oQ(this._rgb):void 0}hexString(){return this._valid?WJ(this._rgb):void 0}hslString(){return this._valid?rQ(this._rgb):void 0}mix(t,r){if(t){const n=this.rgb,i=t.rgb;let a;const s=r===a?.5:r,o=2*s-1,c=n.a-i.a,l=((o*c===-1?o:(o+c)/(1+o*c))+1)/2;a=1-l,n.r=255&l*n.r+a*i.r+.5,n.g=255&l*n.g+a*i.g+.5,n.b=255&l*n.b+a*i.b+.5,n.a=s*n.a+(1-s)*i.a,this.rgb=n}return this}interpolate(t,r){return t&&(this._rgb=lQ(this._rgb,t._rgb,r)),this}clone(){return new Xm(this.rgb)}alpha(t){return this._rgb.a=ku(t),this}clearer(t){const r=this._rgb;return r.a*=1-t,this}greyscale(){const t=this._rgb,r=Gm(t.r*.3+t.g*.59+t.b*.11);return t.r=t.g=t.b=r,this}opaquer(t){const r=this._rgb;return r.a*=1+t,this}negate(){const t=this._rgb;return t.r=255-t.r,t.g=255-t.g,t.b=255-t.b,this}lighten(t){return Dv(this._rgb,2,t),this}darken(t){return Dv(this._rgb,2,-t),this}saturate(t){return Dv(this._rgb,1,t),this}desaturate(t){return Dv(this._rgb,1,-t),this}rotate(t){return tQ(this._rgb,t),this}}function oc(){}const uQ=(()=>{let e=0;return()=>e++})();function hr(e){return e==null}function cn(e){if(Array.isArray&&Array.isArray(e))return!0;const t=Object.prototype.toString.call(e);return t.slice(0,7)==="[object"&&t.slice(-6)==="Array]"}function pr(e){return e!==null&&Object.prototype.toString.call(e)==="[object Object]"}function En(e){return(typeof e=="number"||e instanceof Number)&&isFinite(+e)}function Ja(e,t){return En(e)?e:t}function Jt(e,t){return typeof e>"u"?t:e}const fQ=(e,t)=>typeof e=="string"&&e.endsWith("%")?parseFloat(e)/100:+e/t,pj=(e,t)=>typeof e=="string"&&e.endsWith("%")?parseFloat(e)/100*t:+e;function Wr(e,t,r){if(e&&typeof e.call=="function")return e.apply(r,t)}function Pr(e,t,r,n){let i,a,s;if(cn(e))for(a=e.length,i=0;i<a;i++)t.call(r,e[i],i);else if(pr(e))for(s=Object.keys(e),a=s.length,i=0;i<a;i++)t.call(r,e[s[i]],s[i])}function Uv(e,t){let r,n,i,a;if(!e||!t||e.length!==t.length)return!1;for(r=0,n=e.length;r<n;++r)if(i=e[r],a=t[r],i.datasetIndex!==a.datasetIndex||i.index!==a.index)return!1;return!0}function qv(e){if(cn(e))return e.map(qv);if(pr(e)){const t=Object.create(null),r=Object.keys(e),n=r.length;let i=0;for(;i<n;++i)t[r[i]]=qv(e[r[i]]);return t}return e}function mj(e){return["__proto__","prototype","constructor"].indexOf(e)===-1}function hQ(e,t,r,n){if(!mj(e))return;const i=t[e],a=r[e];pr(i)&&pr(a)?Jm(i,a,n):t[e]=qv(a)}function Jm(e,t,r){const n=cn(t)?t:[t],i=n.length;if(!pr(e))return e;r=r||{};const a=r.merger||hQ;let s;for(let o=0;o<i;++o){if(s=n[o],!pr(s))continue;const c=Object.keys(s);for(let l=0,u=c.length;l<u;++l)a(c[l],e,s,r)}return e}function Qm(e,t){return Jm(e,t,{merger:dQ})}function dQ(e,t,r){if(!mj(e))return;const n=t[e],i=r[e];pr(n)&&pr(i)?Qm(n,i):Object.prototype.hasOwnProperty.call(t,e)||(t[e]=qv(i))}const gj={"":e=>e,x:e=>e.x,y:e=>e.y};function pQ(e){const t=e.split("."),r=[];let n="";for(const i of t)n+=i,n.endsWith("\\")?n=n.slice(0,-1)+".":(r.push(n),n="");return r}function mQ(e){const t=pQ(e);return r=>{for(const n of t){if(n==="")break;r=r&&r[n]}return r}}function Eu(e,t){return(gj[t]||(gj[t]=mQ(t)))(e)}function S5(e){return e.charAt(0).toUpperCase()+e.slice(1)}const eg=e=>typeof e<"u",Mu=e=>typeof e=="function",bj=(e,t)=>{if(e.size!==t.size)return!1;for(const r of e)if(!t.has(r))return!1;return!0};function gQ(e){return e.type==="mouseup"||e.type==="click"||e.type==="contextmenu"}const rn=Math.PI,nn=2*rn,bQ=nn+rn,Vv=Number.POSITIVE_INFINITY,yQ=rn/180,Bn=rn/2,Xf=rn/4,yj=rn*2/3,Au=Math.log10,rl=Math.sign;function tg(e,t,r){return Math.abs(e-t)<r}function vj(e){const t=Math.round(e);e=tg(e,t,e/1e3)?t:e;const r=Math.pow(10,Math.floor(Au(e))),n=e/r;return(n<=1?1:n<=2?2:n<=5?5:10)*r}function vQ(e){const t=[],r=Math.sqrt(e);let n;for(n=1;n<r;n++)e%n===0&&(t.push(n),t.push(e/n));return r===(r|0)&&t.push(r),t.sort((i,a)=>i-a).pop(),t}function wQ(e){return typeof e=="symbol"||typeof e=="object"&&e!==null&&!(Symbol.toPrimitive in e||"toString"in e||"valueOf"in e)}function o0(e){return!wQ(e)&&!isNaN(parseFloat(e))&&isFinite(e)}function xQ(e,t){const r=Math.round(e);return r-t<=e&&r+t>=e}function wj(e,t,r){let n,i,a;for(n=0,i=e.length;n<i;n++)a=e[n][r],isNaN(a)||(t.min=Math.min(t.min,a),t.max=Math.max(t.max,a))}function oo(e){return e*(rn/180)}function k5(e){return e*(180/rn)}function xj(e){if(!En(e))return;let t=1,r=0;for(;Math.round(e*t)/t!==e;)t*=10,r++;return r}function _j(e,t){const r=t.x-e.x,n=t.y-e.y,i=Math.sqrt(r*r+n*n);let a=Math.atan2(n,r);return a<-.5*rn&&(a+=nn),{angle:a,distance:i}}function E5(e,t){return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}function _Q(e,t){return(e-t+bQ)%nn-rn}function Qa(e){return(e%nn+nn)%nn}function rg(e,t,r,n){const i=Qa(e),a=Qa(t),s=Qa(r),o=Qa(a-i),c=Qa(s-i),l=Qa(i-a),u=Qa(i-s);return i===a||i===s||n&&a===s||o>c&&l<u}function mi(e,t,r){return Math.max(t,Math.min(r,e))}function SQ(e){return mi(e,-32768,32767)}function lc(e,t,r,n=1e-6){return e>=Math.min(t,r)-n&&e<=Math.max(t,r)+n}function M5(e,t,r){r=r||(s=>e[s]<t);let n=e.length-1,i=0,a;for(;n-i>1;)a=i+n>>1,r(a)?i=a:n=a;return{lo:i,hi:n}}const cc=(e,t,r,n)=>M5(e,r,n?i=>{const a=e[i][t];return a<r||a===r&&e[i+1][t]===r}:i=>e[i][t]<r),kQ=(e,t,r)=>M5(e,r,n=>e[n][t]>=r);function EQ(e,t,r){let n=0,i=e.length;for(;n<i&&e[n]<t;)n++;for(;i>n&&e[i-1]>r;)i--;return n>0||i<e.length?e.slice(n,i):e}const Sj=["push","pop","shift","splice","unshift"];function MQ(e,t){if(e._chartjs){e._chartjs.listeners.push(t);return}Object.defineProperty(e,"_chartjs",{configurable:!0,enumerable:!1,value:{listeners:[t]}}),Sj.forEach(r=>{const n="_onData"+S5(r),i=e[r];Object.defineProperty(e,r,{configurable:!0,enumerable:!1,value(...a){const s=i.apply(this,a);return e._chartjs.listeners.forEach(o=>{typeof o[n]=="function"&&o[n](...a)}),s}})})}function kj(e,t){const r=e._chartjs;if(!r)return;const n=r.listeners,i=n.indexOf(t);i!==-1&&n.splice(i,1),!(n.length>0)&&(Sj.forEach(a=>{delete e[a]}),delete e._chartjs)}function Ej(e){const t=new Set(e);return t.size===e.length?e:Array.from(t)}const Mj=function(){return typeof window>"u"?function(e){return e()}:window.requestAnimationFrame}();function Aj(e,t){let r=[],n=!1;return function(...i){r=i,n||(n=!0,Mj.call(window,()=>{n=!1,e.apply(t,r)}))}}function AQ(e,t){let r;return function(...n){return t?(clearTimeout(r),r=setTimeout(e,t,n)):e.apply(this,n),t}}const A5=e=>e==="start"?"left":e==="end"?"right":"center",$i=(e,t,r)=>e==="start"?t:e==="end"?r:(t+r)/2,CQ=(e,t,r,n)=>e===(n?"left":"right")?r:e==="center"?(t+r)/2:t;function Cj(e,t,r){const n=t.length;let i=0,a=n;if(e._sorted){const{iScale:s,vScale:o,_parsed:c}=e,l=e.dataset&&e.dataset.options?e.dataset.options.spanGaps:null,u=s.axis,{min:d,max:p,minDefined:w,maxDefined:O}=s.getUserBounds();if(w){if(i=Math.min(cc(c,u,d).lo,r?n:cc(t,u,s.getPixelForValue(d)).lo),l){const I=c.slice(0,i+1).reverse().findIndex(R=>!hr(R[o.axis]));i-=Math.max(0,I)}i=mi(i,0,n-1)}if(O){let I=Math.max(cc(c,s.axis,p,!0).hi+1,r?0:cc(t,u,s.getPixelForValue(p),!0).hi+1);if(l){const R=c.slice(I-1).findIndex(C=>!hr(C[o.axis]));I+=Math.max(0,R)}a=mi(I,i,n)-i}else a=n-i}return{start:i,count:a}}function Tj(e){const{xScale:t,yScale:r,_scaleRanges:n}=e,i={xmin:t.min,xmax:t.max,ymin:r.min,ymax:r.max};if(!n)return e._scaleRanges=i,!0;const a=n.xmin!==t.min||n.xmax!==t.max||n.ymin!==r.min||n.ymax!==r.max;return Object.assign(n,i),a}const Zv=e=>e===0||e===1,jj=(e,t,r)=>-(Math.pow(2,10*(e-=1))*Math.sin((e-t)*nn/r)),Ij=(e,t,r)=>Math.pow(2,-10*e)*Math.sin((e-t)*nn/r)+1,ng={linear:e=>e,easeInQuad:e=>e*e,easeOutQuad:e=>-e*(e-2),easeInOutQuad:e=>(e/=.5)<1?.5*e*e:-.5*(--e*(e-2)-1),easeInCubic:e=>e*e*e,easeOutCubic:e=>(e-=1)*e*e+1,easeInOutCubic:e=>(e/=.5)<1?.5*e*e*e:.5*((e-=2)*e*e+2),easeInQuart:e=>e*e*e*e,easeOutQuart:e=>-((e-=1)*e*e*e-1),easeInOutQuart:e=>(e/=.5)<1?.5*e*e*e*e:-.5*((e-=2)*e*e*e-2),easeInQuint:e=>e*e*e*e*e,easeOutQuint:e=>(e-=1)*e*e*e*e+1,easeInOutQuint:e=>(e/=.5)<1?.5*e*e*e*e*e:.5*((e-=2)*e*e*e*e+2),easeInSine:e=>-Math.cos(e*Bn)+1,easeOutSine:e=>Math.sin(e*Bn),easeInOutSine:e=>-.5*(Math.cos(rn*e)-1),easeInExpo:e=>e===0?0:Math.pow(2,10*(e-1)),easeOutExpo:e=>e===1?1:-Math.pow(2,-10*e)+1,easeInOutExpo:e=>Zv(e)?e:e<.5?.5*Math.pow(2,10*(e*2-1)):.5*(-Math.pow(2,-10*(e*2-1))+2),easeInCirc:e=>e>=1?e:-(Math.sqrt(1-e*e)-1),easeOutCirc:e=>Math.sqrt(1-(e-=1)*e),easeInOutCirc:e=>(e/=.5)<1?-.5*(Math.sqrt(1-e*e)-1):.5*(Math.sqrt(1-(e-=2)*e)+1),easeInElastic:e=>Zv(e)?e:jj(e,.075,.3),easeOutElastic:e=>Zv(e)?e:Ij(e,.075,.3),easeInOutElastic(e){return Zv(e)?e:e<.5?.5*jj(e*2,.1125,.45):.5+.5*Ij(e*2-1,.1125,.45)},easeInBack(e){return e*e*((1.70158+1)*e-1.70158)},easeOutBack(e){return(e-=1)*e*((1.70158+1)*e+1.70158)+1},easeInOutBack(e){let t=1.70158;return(e/=.5)<1?.5*(e*e*(((t*=1.525)+1)*e-t)):.5*((e-=2)*e*(((t*=1.525)+1)*e+t)+2)},easeInBounce:e=>1-ng.easeOutBounce(1-e),easeOutBounce(e){return e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375},easeInOutBounce:e=>e<.5?ng.easeInBounce(e*2)*.5:ng.easeOutBounce(e*2-1)*.5+.5};function C5(e){if(e&&typeof e=="object"){const t=e.toString();return t==="[object CanvasPattern]"||t==="[object CanvasGradient]"}return!1}function Oj(e){return C5(e)?e:new Xm(e)}function T5(e){return C5(e)?e:new Xm(e).saturate(.5).darken(.1).hexString()}const TQ=["x","y","borderWidth","radius","tension"],jQ=["color","borderColor","backgroundColor"];function IQ(e){e.set("animation",{delay:void 0,duration:1e3,easing:"easeOutQuart",fn:void 0,from:void 0,loop:void 0,to:void 0,type:void 0}),e.describe("animation",{_fallback:!1,_indexable:!1,_scriptable:t=>t!=="onProgress"&&t!=="onComplete"&&t!=="fn"}),e.set("animations",{colors:{type:"color",properties:jQ},numbers:{type:"number",properties:TQ}}),e.describe("animations",{_fallback:"animation"}),e.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:t=>t|0}}}})}function OQ(e){e.set("layout",{autoPadding:!0,padding:{top:0,right:0,bottom:0,left:0}})}const Bj=new Map;
vendor: 72,574 bytes, line 15
15function BQ(e,t){t=t||{};const r=e+JSON.stringify(t);let n=Bj.get(r);return n||(n=new Intl.NumberFormat(e,t),Bj.set(r,n)),n}function ig(e,t,r){return BQ(t,r).format(e)}const Rj={values(e){return cn(e)?e:""+e},numeric(e,t,r){if(e===0)return"0";const n=this.chart.options.locale;let i,a=e;if(r.length>1){const l=Math.max(Math.abs(r[0].value),Math.abs(r[r.length-1].value));(l<1e-4||l>1e15)&&(i="scientific"),a=RQ(e,r)}const s=Au(Math.abs(a)),o=isNaN(s)?1:Math.max(Math.min(-1*Math.floor(s),20),0),c={notation:i,minimumFractionDigits:o,maximumFractionDigits:o};return Object.assign(c,this.options.ticks.format),ig(e,n,c)},logarithmic(e,t,r){if(e===0)return"0";const n=r[t].significand||e/Math.pow(10,Math.floor(Au(e)));return[1,2,3,5,10,15].includes(n)||t>.8*r.length?Rj.numeric.call(this,e,t,r):""}};function RQ(e,t){let r=t.length>3?t[2].value-t[1].value:t[1].value-t[0].value;return Math.abs(r)>=1&&e!==Math.floor(e)&&(r=e-Math.floor(e)),r}var $v={formatters:Rj};function NQ(e){e.set("scale",{display:!0,offset:!1,reverse:!1,beginAtZero:!1,bounds:"ticks",clip:!0,grace:0,grid:{display:!0,lineWidth:1,drawOnChartArea:!0,drawTicks:!0,tickLength:8,tickWidth:(t,r)=>r.lineWidth,tickColor:(t,r)=>r.color,offset:!1},border:{display:!0,dash:[],dashOffset:0,width:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:$v.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),e.route("scale.ticks","color","","color"),e.route("scale.grid","color","","borderColor"),e.route("scale.border","color","","borderColor"),e.route("scale.title","color","","color"),e.describe("scale",{_fallback:!1,_scriptable:t=>!t.startsWith("before")&&!t.startsWith("after")&&t!=="callback"&&t!=="parser",_indexable:t=>t!=="borderDash"&&t!=="tickBorderDash"&&t!=="dash"}),e.describe("scales",{_fallback:"scale"}),e.describe("scale.ticks",{_scriptable:t=>t!=="backdropPadding"&&t!=="callback",_indexable:t=>t!=="backdropPadding"})}const Jf=Object.create(null),j5=Object.create(null);function ag(e,t){if(!t)return e;const r=t.split(".");for(let n=0,i=r.length;n<i;++n){const a=r[n];e=e[a]||(e[a]=Object.create(null))}return e}function I5(e,t,r){return typeof t=="string"?Jm(ag(e,t),r):Jm(ag(e,""),t)}class FQ{constructor(t,r){this.animation=void 0,this.backgroundColor="rgba(0,0,0,0.1)",this.borderColor="rgba(0,0,0,0.1)",this.color="#666",this.datasets={},this.devicePixelRatio=n=>n.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(n,i)=>T5(i.backgroundColor),this.hoverBorderColor=(n,i)=>T5(i.borderColor),this.hoverColor=(n,i)=>T5(i.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0,includeInvisible:!1},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.drawActiveElementsOnTop=!0,this.describe(t),this.apply(r)}set(t,r){return I5(this,t,r)}get(t){return ag(this,t)}describe(t,r){return I5(j5,t,r)}override(t,r){return I5(Jf,t,r)}route(t,r,n,i){const a=ag(this,t),s=ag(this,n),o="_"+r;Object.defineProperties(a,{[o]:{value:a[r],writable:!0},[r]:{enumerable:!0,get(){const c=this[o],l=s[i];return pr(c)?Object.assign({},l,c):Jt(c,l)},set(c){this[o]=c}}})}apply(t){t.forEach(r=>r(this))}}var un=new FQ({_scriptable:e=>!e.startsWith("on"),_indexable:e=>e!=="events",hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}},[IQ,OQ,NQ]);function PQ(e){return!e||hr(e.size)||hr(e.family)?null:(e.style?e.style+" ":"")+(e.weight?e.weight+" ":"")+e.size+"px "+e.family}function Hv(e,t,r,n,i){let a=t[i];return a||(a=t[i]=e.measureText(i).width,r.push(i)),a>n&&(n=a),n}function zQ(e,t,r,n){n=n||{};let i=n.data=n.data||{},a=n.garbageCollect=n.garbageCollect||[];n.font!==t&&(i=n.data={},a=n.garbageCollect=[],n.font=t),e.save(),e.font=t;let s=0;const o=r.length;let c,l,u,d,p;for(c=0;c<o;c++)if(d=r[c],d!=null&&!cn(d))s=Hv(e,i,a,s,d);else if(cn(d))for(l=0,u=d.length;l<u;l++)p=d[l],p!=null&&!cn(p)&&(s=Hv(e,i,a,s,p));e.restore();const w=a.length/2;if(w>r.length){for(c=0;c<w;c++)delete i[a[c]];a.splice(0,w)}return s}function Qf(e,t,r){const n=e.currentDevicePixelRatio,i=r!==0?Math.max(r/2,.5):0;return Math.round((t-i)*n)/n+i}function Nj(e,t){!t&&!e||(t=t||e.getContext("2d"),t.save(),t.resetTransform(),t.clearRect(0,0,e.width,e.height),t.restore())}function O5(e,t,r,n){Fj(e,t,r,n,null)}function Fj(e,t,r,n,i){let a,s,o,c,l,u,d,p;const w=t.pointStyle,O=t.rotation,I=t.radius;let R=(O||0)*yQ;if(w&&typeof w=="object"&&(a=w.toString(),a==="[object HTMLImageElement]"||a==="[object HTMLCanvasElement]")){e.save(),e.translate(r,n),e.rotate(R),e.drawImage(w,-w.width/2,-w.height/2,w.width,w.height),e.restore();return}if(!(isNaN(I)||I<=0)){switch(e.beginPath(),w){default:i?e.ellipse(r,n,i/2,I,0,0,nn):e.arc(r,n,I,0,nn),e.closePath();break;case"triangle":u=i?i/2:I,e.moveTo(r+Math.sin(R)*u,n-Math.cos(R)*I),R+=yj,e.lineTo(r+Math.sin(R)*u,n-Math.cos(R)*I),R+=yj,e.lineTo(r+Math.sin(R)*u,n-Math.cos(R)*I),e.closePath();break;case"rectRounded":l=I*.516,c=I-l,s=Math.cos(R+Xf)*c,d=Math.cos(R+Xf)*(i?i/2-l:c),o=Math.sin(R+Xf)*c,p=Math.sin(R+Xf)*(i?i/2-l:c),e.arc(r-d,n-o,l,R-rn,R-Bn),e.arc(r+p,n-s,l,R-Bn,R),e.arc(r+d,n+o,l,R,R+Bn),e.arc(r-p,n+s,l,R+Bn,R+rn),e.closePath();break;case"rect":if(!O){c=Math.SQRT1_2*I,u=i?i/2:c,e.rect(r-u,n-c,2*u,2*c);break}R+=Xf;case"rectRot":d=Math.cos(R)*(i?i/2:I),s=Math.cos(R)*I,o=Math.sin(R)*I,p=Math.sin(R)*(i?i/2:I),e.moveTo(r-d,n-o),e.lineTo(r+p,n-s),e.lineTo(r+d,n+o),e.lineTo(r-p,n+s),e.closePath();break;case"crossRot":R+=Xf;case"cross":d=Math.cos(R)*(i?i/2:I),s=Math.cos(R)*I,o=Math.sin(R)*I,p=Math.sin(R)*(i?i/2:I),e.moveTo(r-d,n-o),e.lineTo(r+d,n+o),e.moveTo(r+p,n-s),e.lineTo(r-p,n+s);break;case"star":d=Math.cos(R)*(i?i/2:I),s=Math.cos(R)*I,o=Math.sin(R)*I,p=Math.sin(R)*(i?i/2:I),e.moveTo(r-d,n-o),e.lineTo(r+d,n+o),e.moveTo(r+p,n-s),e.lineTo(r-p,n+s),R+=Xf,d=Math.cos(R)*(i?i/2:I),s=Math.cos(R)*I,o=Math.sin(R)*I,p=Math.sin(R)*(i?i/2:I),e.moveTo(r-d,n-o),e.lineTo(r+d,n+o),e.moveTo(r+p,n-s),e.lineTo(r-p,n+s);break;case"line":s=i?i/2:Math.cos(R)*I,o=Math.sin(R)*I,e.moveTo(r-s,n-o),e.lineTo(r+s,n+o);break;case"dash":e.moveTo(r,n),e.lineTo(r+Math.cos(R)*(i?i/2:I),n+Math.sin(R)*I);break;case!1:e.closePath();break}e.fill(),t.borderWidth>0&&e.stroke()}}function uc(e,t,r){return r=r||.5,!t||e&&e.x>t.left-r&&e.x<t.right+r&&e.y>t.top-r&&e.y<t.bottom+r}function Wv(e,t){e.save(),e.beginPath(),e.rect(t.left,t.top,t.right-t.left,t.bottom-t.top),e.clip()}function Kv(e){e.restore()}function LQ(e,t,r,n,i){if(!t)return e.lineTo(r.x,r.y);if(i==="middle"){const a=(t.x+r.x)/2;e.lineTo(a,t.y),e.lineTo(a,r.y)}else i==="after"!=!!n?e.lineTo(t.x,r.y):e.lineTo(r.x,t.y);e.lineTo(r.x,r.y)}function DQ(e,t,r,n){if(!t)return e.lineTo(r.x,r.y);e.bezierCurveTo(n?t.cp1x:t.cp2x,n?t.cp1y:t.cp2y,n?r.cp2x:r.cp1x,n?r.cp2y:r.cp1y,r.x,r.y)}function UQ(e,t){t.translation&&e.translate(t.translation[0],t.translation[1]),hr(t.rotation)||e.rotate(t.rotation),t.color&&(e.fillStyle=t.color),t.textAlign&&(e.textAlign=t.textAlign),t.textBaseline&&(e.textBaseline=t.textBaseline)}function qQ(e,t,r,n,i){if(i.strikethrough||i.underline){const a=e.measureText(n),s=t-a.actualBoundingBoxLeft,o=t+a.actualBoundingBoxRight,c=r-a.actualBoundingBoxAscent,l=r+a.actualBoundingBoxDescent,u=i.strikethrough?(c+l)/2:l;e.strokeStyle=e.fillStyle,e.beginPath(),e.lineWidth=i.decorationWidth||2,e.moveTo(s,u),e.lineTo(o,u),e.stroke()}}function VQ(e,t){const r=e.fillStyle;e.fillStyle=t.color,e.fillRect(t.left,t.top,t.width,t.height),e.fillStyle=r}function eh(e,t,r,n,i,a={}){const s=cn(t)?t:[t],o=a.strokeWidth>0&&a.strokeColor!=="";let c,l;for(e.save(),e.font=i.string,UQ(e,a),c=0;c<s.length;++c)l=s[c],a.backdrop&&VQ(e,a.backdrop),o&&(a.strokeColor&&(e.strokeStyle=a.strokeColor),hr(a.strokeWidth)||(e.lineWidth=a.strokeWidth),e.strokeText(l,r,n,a.maxWidth)),e.fillText(l,r,n,a.maxWidth),qQ(e,r,n,l,a),n+=Number(i.lineHeight);e.restore()}function sg(e,t){const{x:r,y:n,w:i,h:a,radius:s}=t;e.arc(r+s.topLeft,n+s.topLeft,s.topLeft,1.5*rn,rn,!0),e.lineTo(r,n+a-s.bottomLeft),e.arc(r+s.bottomLeft,n+a-s.bottomLeft,s.bottomLeft,rn,Bn,!0),e.lineTo(r+i-s.bottomRight,n+a),e.arc(r+i-s.bottomRight,n+a-s.bottomRight,s.bottomRight,Bn,0,!0),e.lineTo(r+i,n+s.topRight),e.arc(r+i-s.topRight,n+s.topRight,s.topRight,0,-Bn,!0),e.lineTo(r+s.topLeft,n)}const ZQ=/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/,$Q=/^(normal|italic|initial|inherit|unset|(oblique( -?[0-9]?[0-9]deg)?))$/;function HQ(e,t){const r=(""+e).match(ZQ);if(!r||r[1]==="normal")return t*1.2;switch(e=+r[2],r[3]){case"px":return e;case"%":e/=100;break}return t*e}const WQ=e=>+e||0;function B5(e,t){const r={},n=pr(t),i=n?Object.keys(t):t,a=pr(e)?n?s=>Jt(e[s],e[t[s]]):s=>e[s]:()=>e;for(const s of i)r[s]=WQ(a(s));return r}function Pj(e){return B5(e,{top:"y",right:"x",bottom:"y",left:"x"})}function th(e){return B5(e,["topLeft","topRight","bottomLeft","bottomRight"])}function Hi(e){const t=Pj(e);return t.width=t.left+t.right,t.height=t.top+t.bottom,t}function ii(e,t){e=e||{},t=t||un.font;let r=Jt(e.size,t.size);typeof r=="string"&&(r=parseInt(r,10));let n=Jt(e.style,t.style);n&&!(""+n).match($Q)&&(console.warn('Invalid font style specified: "'+n+'"'),n=void 0);const i={family:Jt(e.family,t.family),lineHeight:HQ(Jt(e.lineHeight,t.lineHeight),r),size:r,style:n,weight:Jt(e.weight,t.weight),string:""};return i.string=PQ(i),i}function og(e,t,r,n){let i,a,s;for(i=0,a=e.length;i<a;++i)if(s=e[i],s!==void 0&&s!==void 0)return s}function KQ(e,t,r){const{min:n,max:i}=e,a=pj(t,(i-n)/2),s=(o,c)=>r&&o===0?0:o+c;return{min:s(n,-Math.abs(a)),max:s(i,a)}}function Cu(e,t){return Object.assign(Object.create(e),t)}function R5(e,t=[""],r,n,i=()=>e[0]){const a=r||e;typeof n>"u"&&(n=qj("_fallback",e));const s={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:e,_rootScopes:a,_fallback:n,_getTarget:i,override:o=>R5([o,...e],t,a,n)};return new Proxy(s,{deleteProperty(o,c){return delete o[c],delete o._keys,delete e[0][c],!0},get(o,c){return Lj(o,c,()=>ree(c,t,e,o))},getOwnPropertyDescriptor(o,c){return Reflect.getOwnPropertyDescriptor(o._scopes[0],c)},getPrototypeOf(){return Reflect.getPrototypeOf(e[0])},has(o,c){return Vj(o).includes(c)},ownKeys(o){return Vj(o)},set(o,c,l){const u=o._storage||(o._storage=i());return o[c]=u[c]=l,delete o._keys,!0}})}function l0(e,t,r,n){const i={_cacheable:!1,_proxy:e,_context:t,_subProxy:r,_stack:new Set,_descriptors:zj(e,n),setContext:a=>l0(e,a,r,n),override:a=>l0(e.override(a),t,r,n)};return new Proxy(i,{deleteProperty(a,s){return delete a[s],delete e[s],!0},get(a,s,o){return Lj(a,s,()=>YQ(a,s,o))},getOwnPropertyDescriptor(a,s){return a._descriptors.allKeys?Reflect.has(e,s)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(e,s)},getPrototypeOf(){return Reflect.getPrototypeOf(e)},has(a,s){return Reflect.has(e,s)},ownKeys(){return Reflect.ownKeys(e)},set(a,s,o){return e[s]=o,delete a[s],!0}})}function zj(e,t={scriptable:!0,indexable:!0}){const{_scriptable:r=t.scriptable,_indexable:n=t.indexable,_allKeys:i=t.allKeys}=e;return{allKeys:i,scriptable:r,indexable:n,isScriptable:Mu(r)?r:()=>r,isIndexable:Mu(n)?n:()=>n}}const GQ=(e,t)=>e?e+S5(t):t,N5=(e,t)=>pr(t)&&e!=="adapters"&&(Object.getPrototypeOf(t)===null||t.constructor===Object);function Lj(e,t,r){if(Object.prototype.hasOwnProperty.call(e,t)||t==="constructor")return e[t];const n=r();return e[t]=n,n}function YQ(e,t,r){const{_proxy:n,_context:i,_subProxy:a,_descriptors:s}=e;let o=n[t];return Mu(o)&&s.isScriptable(t)&&(o=XQ(t,o,e,r)),cn(o)&&o.length&&(o=JQ(t,o,e,s.isIndexable)),N5(t,o)&&(o=l0(o,i,a&&a[t],s)),o}function XQ(e,t,r,n){const{_proxy:i,_context:a,_subProxy:s,_stack:o}=r;if(o.has(e))throw new Error("Recursion detected: "+Array.from(o).join("->")+"->"+e);o.add(e);let c=t(a,s||n);return o.delete(e),N5(e,c)&&(c=F5(i._scopes,i,e,c)),c}function JQ(e,t,r,n){const{_proxy:i,_context:a,_subProxy:s,_descriptors:o}=r;if(typeof a.index<"u"&&n(e))return t[a.index%t.length];if(pr(t[0])){const c=t,l=i._scopes.filter(u=>u!==c);t=[];for(const u of c){const d=F5(l,i,e,u);t.push(l0(d,a,s&&s[e],o))}}return t}function Dj(e,t,r){return Mu(e)?e(t,r):e}const QQ=(e,t)=>e===!0?t:typeof e=="string"?Eu(t,e):void 0;function eee(e,t,r,n,i){for(const a of t){const s=QQ(r,a);if(s){e.add(s);const o=Dj(s._fallback,r,i);if(typeof o<"u"&&o!==r&&o!==n)return o}else if(s===!1&&typeof n<"u"&&r!==n)return null}return!1}function F5(e,t,r,n){const i=t._rootScopes,a=Dj(t._fallback,r,n),s=[...e,...i],o=new Set;o.add(n);let c=Uj(o,s,r,a||r,n);return c===null||typeof a<"u"&&a!==r&&(c=Uj(o,s,a,c,n),c===null)?!1:R5(Array.from(o),[""],i,a,()=>tee(t,r,n))}function Uj(e,t,r,n,i){for(;r;)r=eee(e,t,r,n,i);return r}function tee(e,t,r){const n=e._getTarget();t in n||(n[t]={});const i=n[t];return cn(i)&&pr(r)?r:i||{}}function ree(e,t,r,n){let i;for(const a of t)if(i=qj(GQ(a,e),r),typeof i<"u")return N5(e,i)?F5(r,n,e,i):i}function qj(e,t){for(const r of t){if(!r)continue;const n=r[e];if(typeof n<"u")return n}}function Vj(e){let t=e._keys;return t||(t=e._keys=nee(e._scopes)),t}function nee(e){const t=new Set;for(const r of e)for(const n of Object.keys(r).filter(i=>!i.startsWith("_")))t.add(n);return Array.from(t)}function Zj(e,t,r,n){const{iScale:i}=e,{key:a="r"}=this._parsing,s=new Array(n);let o,c,l,u;for(o=0,c=n;o<c;++o)l=o+r,u=t[l],s[o]={r:i.parse(Eu(u,a),l)};return s}const iee=Number.EPSILON||1e-14,c0=(e,t)=>t<e.length&&!e[t].skip&&e[t],$j=e=>e==="x"?"y":"x";function aee(e,t,r,n){const i=e.skip?t:e,a=t,s=r.skip?t:r,o=E5(a,i),c=E5(s,a);let l=o/(o+c),u=c/(o+c);l=isNaN(l)?0:l,u=isNaN(u)?0:u;const d=n*l,p=n*u;return{previous:{x:a.x-d*(s.x-i.x),y:a.y-d*(s.y-i.y)},next:{x:a.x+p*(s.x-i.x),y:a.y+p*(s.y-i.y)}}}function see(e,t,r){const n=e.length;let i,a,s,o,c,l=c0(e,0);for(let u=0;u<n-1;++u)if(c=l,l=c0(e,u+1),!(!c||!l)){if(tg(t[u],0,iee)){r[u]=r[u+1]=0;continue}i=r[u]/t[u],a=r[u+1]/t[u],o=Math.pow(i,2)+Math.pow(a,2),!(o<=9)&&(s=3/Math.sqrt(o),r[u]=i*s*t[u],r[u+1]=a*s*t[u])}}function oee(e,t,r="x"){const n=$j(r),i=e.length;let a,s,o,c=c0(e,0);for(let l=0;l<i;++l){if(s=o,o=c,c=c0(e,l+1),!o)continue;const u=o[r],d=o[n];s&&(a=(u-s[r])/3,o[`cp1${r}`]=u-a,o[`cp1${n}`]=d-a*t[l]),c&&(a=(c[r]-u)/3,o[`cp2${r}`]=u+a,o[`cp2${n}`]=d+a*t[l])}}function lee(e,t="x"){const r=$j(t),n=e.length,i=Array(n).fill(0),a=Array(n);let s,o,c,l=c0(e,0);for(s=0;s<n;++s)if(o=c,c=l,l=c0(e,s+1),!!c){if(l){const u=l[t]-c[t];i[s]=u!==0?(l[r]-c[r])/u:0}a[s]=o?l?rl(i[s-1])!==rl(i[s])?0:(i[s-1]+i[s])/2:i[s-1]:i[s]}see(e,i,a),oee(e,a,t)}function Gv(e,t,r){return Math.max(Math.min(e,r),t)}function cee(e,t){let r,n,i,a,s,o=uc(e[0],t);for(r=0,n=e.length;r<n;++r)s=a,a=o,o=r<n-1&&uc(e[r+1],t),a&&(i=e[r],s&&(i.cp1x=Gv(i.cp1x,t.left,t.right),i.cp1y=Gv(i.cp1y,t.top,t.bottom)),o&&(i.cp2x=Gv(i.cp2x,t.left,t.right),i.cp2y=Gv(i.cp2y,t.top,t.bottom)))}function uee(e,t,r,n,i){let a,s,o,c;if(t.spanGaps&&(e=e.filter(l=>!l.skip)),t.cubicInterpolationMode==="monotone")lee(e,i);else{let l=n?e[e.length-1]:e[0];for(a=0,s=e.length;a<s;++a)o=e[a],c=aee(l,o,e[Math.min(a+1,s-(n?0:1))%s],t.tension),o.cp1x=c.previous.x,o.cp1y=c.previous.y,o.cp2x=c.next.x,o.cp2y=c.next.y,l=o}t.capBezierPoints&&cee(e,r)}function P5(){return typeof window<"u"&&typeof document<"u"}function z5(e){let t=e.parentNode;return t&&t.toString()==="[object ShadowRoot]"&&(t=t.host),t}function Yv(e,t,r){let n;return typeof e=="string"?(n=parseInt(e,10),e.indexOf("%")!==-1&&(n=n/100*t.parentNode[r])):n=e,n}const Xv=e=>e.ownerDocument.defaultView.getComputedStyle(e,null);function fee(e,t){return Xv(e).getPropertyValue(t)}const hee=["top","right","bottom","left"];function rh(e,t,r){const n={};r=r?"-"+r:"";for(let i=0;i<4;i++){const a=hee[i];n[a]=parseFloat(e[t+"-"+a+r])||0}return n.width=n.left+n.right,n.height=n.top+n.bottom,n}const dee=(e,t,r)=>(e>0||t>0)&&(!r||!r.shadowRoot);function pee(e,t){const r=e.touches,n=r&&r.length?r[0]:e,{offsetX:i,offsetY:a}=n;let s=!1,o,c;if(dee(i,a,e.target))o=i,c=a;else{const l=t.getBoundingClientRect();o=n.clientX-l.left,c=n.clientY-l.top,s=!0}return{x:o,y:c,box:s}}function nh(e,t){if("native"in e)return e;const{canvas:r,currentDevicePixelRatio:n}=t,i=Xv(r),a=i.boxSizing==="border-box",s=rh(i,"padding"),o=rh(i,"border","width"),{x:c,y:l,box:u}=pee(e,r),d=s.left+(u&&o.left),p=s.top+(u&&o.top);let{width:w,height:O}=t;return a&&(w-=s.width+o.width,O-=s.height+o.height),{x:Math.round((c-d)/w*r.width/n),y:Math.round((l-p)/O*r.height/n)}}function mee(e,t,r){let n,i;if(t===void 0||r===void 0){const a=e&&z5(e);if(!a)t=e.clientWidth,r=e.clientHeight;else{const s=a.getBoundingClientRect(),o=Xv(a),c=rh(o,"border","width"),l=rh(o,"padding");t=s.width-l.width-c.width,r=s.height-l.height-c.height,n=Yv(o.maxWidth,a,"clientWidth"),i=Yv(o.maxHeight,a,"clientHeight")}}return{width:t,height:r,maxWidth:n||Vv,maxHeight:i||Vv}}const Jv=e=>Math.round(e*10)/10;function gee(e,t,r,n){const i=Xv(e),a=rh(i,"margin"),s=Yv(i.maxWidth,e,"clientWidth")||Vv,o=Yv(i.maxHeight,e,"clientHeight")||Vv,c=mee(e,t,r);let{width:l,height:u}=c;if(i.boxSizing==="content-box"){const d=rh(i,"border","width"),p=rh(i,"padding");l-=p.width+d.width,u-=p.height+d.height}return l=Math.max(0,l-a.width),u=Math.max(0,n?l/n:u-a.height),l=Jv(Math.min(l,s,c.maxWidth)),u=Jv(Math.min(u,o,c.maxHeight)),l&&!u&&(u=Jv(l/2)),(t!==void 0||r!==void 0)&&n&&c.height&&u>c.height&&(u=c.height,l=Jv(Math.floor(u*n))),{width:l,height:u}}function Hj(e,t,r){const n=t||1,i=Math.floor(e.height*n),a=Math.floor(e.width*n);e.height=Math.floor(e.height),e.width=Math.floor(e.width);const s=e.canvas;return s.style&&(r||!s.style.height&&!s.style.width)&&(s.style.height=`${e.height}px`,s.style.width=`${e.width}px`),e.currentDevicePixelRatio!==n||s.height!==i||s.width!==a?(e.currentDevicePixelRatio=n,s.height=i,s.width=a,e.ctx.setTransform(n,0,0,n,0,0),!0):!1}const bee=function(){let e=!1;try{const t={get passive(){return e=!0,!1}};P5()&&(window.addEventListener("test",null,t),window.removeEventListener("test",null,t))}catch{}return e}();function Wj(e,t){const r=fee(e,t),n=r&&r.match(/^(\d+)(\.\d+)?px$/);return n?+n[1]:void 0}function ih(e,t,r,n){return{x:e.x+r*(t.x-e.x),y:e.y+r*(t.y-e.y)}}function yee(e,t,r,n){return{x:e.x+r*(t.x-e.x),y:n==="middle"?r<.5?e.y:t.y:n==="after"?r<1?e.y:t.y:r>0?t.y:e.y}}function vee(e,t,r,n){const i={x:e.cp2x,y:e.cp2y},a={x:t.cp1x,y:t.cp1y},s=ih(e,i,r),o=ih(i,a,r),c=ih(a,t,r),l=ih(s,o,r),u=ih(o,c,r);return ih(l,u,r)}const wee=function(e,t){return{x(r){return e+e+t-r},setWidth(r){t=r},textAlign(r){return r==="center"?r:r==="right"?"left":"right"},xPlus(r,n){return r-n},leftForLtr(r,n){return r-n}}},xee=function(){return{x(e){return e},setWidth(e){},textAlign(e){return e},xPlus(e,t){return e+t},leftForLtr(e,t){return e}}};function u0(e,t,r){return e?wee(t,r):xee()}function Kj(e,t){let r,n;(t==="ltr"||t==="rtl")&&(r=e.canvas.style,n=[r.getPropertyValue("direction"),r.getPropertyPriority("direction")],r.setProperty("direction",t,"important"),e.prevTextDirection=n)}function Gj(e,t){t!==void 0&&(delete e.prevTextDirection,e.canvas.style.setProperty("direction",t[0],t[1]))}function Yj(e){return e==="angle"?{between:rg,compare:_Q,normalize:Qa}:{between:lc,compare:(t,r)=>t-r,normalize:t=>t}}function Xj({start:e,end:t,count:r,loop:n,style:i}){return{start:e%r,end:t%r,loop:n&&(t-e+1)%r===0,style:i}}function _ee(e,t,r){const{property:n,start:i,end:a}=r,{between:s,normalize:o}=Yj(n),c=t.length;let{start:l,end:u,loop:d}=e,p,w;if(d){for(l+=c,u+=c,p=0,w=c;p<w&&s(o(t[l%c][n]),i,a);++p)l--,u--;l%=c,u%=c}return u<l&&(u+=c),{start:l,end:u,loop:d,style:e.style}}function Jj(e,t,r){if(!r)return[e];const{property:n,start:i,end:a}=r,s=t.length,{compare:o,between:c,normalize:l}=Yj(n),{start:u,end:d,loop:p,style:w}=_ee(e,t,r),O=[];let I=!1,R=null,C,j,N;const P=()=>c(i,N,C)&&o(i,N)!==0,Z=()=>o(a,C)===0||c(a,N,C),X=()=>I||P(),re=()=>!I||Z();for(let ne=u,ae=u;ne<=d;++ne)j=t[ne%s],!j.skip&&(C=l(j[n]),C!==N&&(I=c(C,i,a),R===null&&X()&&(R=o(C,i)===0?ne:ae),R!==null&&re()&&(O.push(Xj({start:R,end:ne,loop:p,count:s,style:w})),R=null),ae=ne,N=C));return R!==null&&O.push(Xj({start:R,end:d,loop:p,count:s,style:w})),O}function Qj(e,t){const r=[],n=e.segments;for(let i=0;i<n.length;i++){const a=Jj(n[i],e.points,t);a.length&&r.push(...a)}return r}function See(e,t,r,n){let i=0,a=t-1;if(r&&!n)for(;i<t&&!e[i].skip;)i++;for(;i<t&&e[i].skip;)i++;for(i%=t,r&&(a+=i);a>i&&e[a%t].skip;)a--;return a%=t,{start:i,end:a}}function kee(e,t,r,n){const i=e.length,a=[];let s=t,o=e[t],c;for(c=t+1;c<=r;++c){const l=e[c%i];l.skip||l.stop?o.skip||(n=!1,a.push({start:t%i,end:(c-1)%i,loop:n}),t=s=l.stop?c:null):(s=c,o.skip&&(t=c)),o=l}return s!==null&&a.push({start:t%i,end:s%i,loop:n}),a}function Eee(e,t){const r=e.points,n=e.options.spanGaps,i=r.length;if(!i)return[];const a=!!e._loop,{start:s,end:o}=See(r,i,a,n);if(n===!0)return eI(e,[{start:s,end:o,loop:a}],r,t);const c=o<s?o+i:o,l=!!e._fullLoop&&s===0&&o===i-1;return eI(e,kee(r,s,c,l),r,t)}function eI(e,t,r,n){return!n||!n.setContext||!r?t:Mee(e,t,r,n)}function Mee(e,t,r,n){const i=e._chart.getContext(),a=tI(e.options),{_datasetIndex:s,options:{spanGaps:o}}=e,c=r.length,l=[];let u=a,d=t[0].start,p=d;function w(O,I,R,C){const j=o?-1:1;if(O!==I){for(O+=c;r[O%c].skip;)O-=j;for(;r[I%c].skip;)I+=j;O%c!==I%c&&(l.push({start:O%c,end:I%c,loop:R,style:C}),u=C,d=I%c)}}for(const O of t){d=o?d:O.start;let I=r[d%c],R;for(p=d+1;p<=O.end;p++){const C=r[p%c];R=tI(n.setContext(Cu(i,{type:"segment",p0:I,p1:C,p0DataIndex:(p-1)%c,p1DataIndex:p%c,datasetIndex:s}))),Aee(R,u)&&w(d,p-1,O.loop,u),I=C,u=R}d<p-1&&w(d,p-1,O.loop,u)}return l}function tI(e){return{backgroundColor:e.backgroundColor,borderCapStyle:e.borderCapStyle,borderDash:e.borderDash,borderDashOffset:e.borderDashOffset,borderJoinStyle:e.borderJoinStyle,borderWidth:e.borderWidth,borderColor:e.borderColor}}function Aee(e,t){if(!t)return!1;const r=[],n=function(i,a){return C5(a)?(r.includes(a)||r.push(a),r.indexOf(a)):a};return JSON.stringify(e,n)!==JSON.stringify(t,n)}function Qv(e,t,r){return e.options.clip?e[r]:t[r]}function Cee(e,t){const{xScale:r,yScale:n}=e;return r&&n?{left:Qv(r,t,"left"),right:Qv(r,t,"right"),top:Qv(n,t,"top"),bottom:Qv(n,t,"bottom")}:t}function rI(e,t){const r=t._clip;if(r.disabled)return!1;const n=Cee(t,e.chartArea);return{left:r.left===!1?0:n.left-(r.left===!0?0:r.left),right:r.right===!1?e.width:n.right+(r.right===!0?0:r.right),top:r.top===!1?0:n.top-(r.top===!0?0:r.top),bottom:r.bottom===!1?e.height:n.bottom+(r.bottom===!0?0:r.bottom)}}class Tee{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(t,r,n,i){const a=r.listeners[i],s=r.duration;a.forEach(o=>o({chart:t,initial:r.initial,numSteps:s,currentStep:Math.min(n-r.start,s)}))}_refresh(){this._request||(this._running=!0,this._request=Mj.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(t=Date.now()){let r=0;this._charts.forEach((n,i)=>{if(!n.running||!n.items.length)return;const a=n.items;let s=a.length-1,o=!1,c;for(;s>=0;--s)c=a[s],c._active?(c._total>n.duration&&(n.duration=c._total),c.tick(t),o=!0):(a[s]=a[a.length-1],a.pop());o&&(i.draw(),this._notify(i,n,t,"progress")),a.length||(n.running=!1,this._notify(i,n,t,"complete"),n.initial=!1),r+=a.length}),this._lastDate=t,r===0&&(this._running=!1)}_getAnims(t){const r=this._charts;let n=r.get(t);return n||(n={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},r.set(t,n)),n}listen(t,r,n){this._getAnims(t).listeners[r].push(n)}add(t,r){!r||!r.length||this._getAnims(t).items.push(...r)}has(t){return this._getAnims(t).items.length>0}start(t){const r=this._charts.get(t);r&&(r.running=!0,r.start=Date.now(),r.duration=r.items.reduce((n,i)=>Math.max(n,i._duration),0),this._refresh())}running(t){if(!this._running)return!1;const r=this._charts.get(t);return!(!r||!r.running||!r.items.length)}stop(t){const r=this._charts.get(t);if(!r||!r.items.length)return;const n=r.items;let i=n.length-1;for(;i>=0;--i)n[i].cancel();r.items=[],this._notify(t,r,Date.now(),"complete")}remove(t){return this._charts.delete(t)}}var fc=new Tee;const nI="transparent",jee={boolean(e,t,r){return r>.5?t:e},color(e,t,r){const n=Oj(e||nI),i=n.valid&&Oj(t||nI);return i&&i.valid?i.mix(n,r).hexString():t},number(e,t,r){return e+(t-e)*r}};class Iee{constructor(t,r,n,i){const a=r[n];i=og([t.to,i,a,t.from]);const s=og([t.from,a,i]);this._active=!0,this._fn=t.fn||jee[t.type||typeof s],this._easing=ng[t.easing]||ng.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=r,this._prop=n,this._from=s,this._to=i,this._promises=void 0}active(){return this._active}update(t,r,n){if(this._active){this._notify(!1);const i=this._target[this._prop],a=n-this._start,s=this._duration-a;this._start=n,this._duration=Math.floor(Math.max(s,t.duration)),this._total+=a,this._loop=!!t.loop,this._to=og([t.to,r,i,t.from]),this._from=og([t.from,i,r])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){const r=t-this._start,n=this._duration,i=this._prop,a=this._from,s=this._loop,o=this._to;let c;if(this._active=a!==o&&(s||r<n),!this._active){this._target[i]=o,this._notify(!0);return}if(r<0){this._target[i]=a;return}c=r/n%2,c=s&&c>1?2-c:c,c=this._easing(Math.min(1,Math.max(0,c))),this._target[i]=this._fn(a,o,c)}wait(){const t=this._promises||(this._promises=[]);return new Promise((r,n)=>{t.push({res:r,rej:n})})}_notify(t){const r=t?"res":"rej",n=this._promises||[];for(let i=0;i<n.length;i++)n[i][r]()}}class iI{constructor(t,r){this._chart=t,this._properties=new Map,this.configure(r)}configure(t){if(!pr(t))return;const r=Object.keys(un.animation),n=this._properties;Object.getOwnPropertyNames(t).forEach(i=>{const a=t[i];if(!pr(a))return;const s={};for(const o of r)s[o]=a[o];(cn(a.properties)&&a.properties||[i]).forEach(o=>{(o===i||!n.has(o))&&n.set(o,s)})})}_animateOptions(t,r){const n=r.options,i=Bee(t,n);if(!i)return[];const a=this._createAnimations(i,n);return n.$shared&&Oee(t.options.$animations,n).then(()=>{t.options=n},()=>{}),a}_createAnimations(t,r){const n=this._properties,i=[],a=t.$animations||(t.$animations={}),s=Object.keys(r),o=Date.now();let c;for(c=s.length-1;c>=0;--c){const l=s[c];if(l.charAt(0)==="$")continue;if(l==="options"){i.push(...this._animateOptions(t,r));continue}const u=r[l];let d=a[l];const p=n.get(l);if(d)if(p&&d.active()){d.update(p,u,o);continue}else d.cancel();if(!p||!p.duration){t[l]=u;continue}a[l]=d=new Iee(p,t,l,u),i.push(d)}return i}update(t,r){if(this._properties.size===0){Object.assign(t,r);return}const n=this._createAnimations(t,r);if(n.length)return fc.add(this._chart,n),!0}}function Oee(e,t){const r=[],n=Object.keys(t);for(let i=0;i<n.length;i++){const a=e[n[i]];a&&a.active()&&r.push(a.wait())}return Promise.all(r)}function Bee(e,t){if(!t)return;let r=e.options;if(!r){e.options=t;return}return r.$shared&&(e.options=r=Object.assign({},r,{$shared:!1,$animations:{}})),r}function aI(e,t){const r=e&&e.options||{},n=r.reverse,i=r.min===void 0?t:0,a=r.max===void 0?t:0;return{start:n?a:i,end:n?i:a}}function Ree(e,t,r){if(r===!1)return!1;const n=aI(e,r),i=aI(t,r);return{top:i.end,right:n.end,bottom:i.start,left:n.start}}function Nee(e){let t,r,n,i;return pr(e)?(t=e.top,r=e.right,n=e.bottom,i=e.left):t=r=n=i=e,{top:t,right:r,bottom:n,left:i,disabled:e===!1}}function sI(e,t){const r=[],n=e._getSortedDatasetMetas(t);let i,a;for(i=0,a=n.length;i<a;++i)r.push(n[i].index);return r}function oI(e,t,r,n={}){const i=e.keys,a=n.mode==="single";let s,o,c,l;if(t===null)return;let u=!1;for(s=0,o=i.length;s<o;++s){if(c=+i[s],c===r){if(u=!0,n.all)continue;break}l=e.values[c],En(l)&&(a||t===0||rl(t)===rl(l))&&(t+=l)}return!u&&!n.all?0:t}function Fee(e,t){const{iScale:r,vScale:n}=t,i=r.axis==="x"?"x":"y",a=n.axis==="x"?"x":"y",s=Object.keys(e),o=new Array(s.length);let c,l,u;for(c=0,l=s.length;c<l;++c)u=s[c],o[c]={[i]:u,[a]:e[u]};return o}function L5(e,t){const r=e&&e.options.stacked;return r||r===void 0&&t.stack!==void 0}function Pee(e,t,r){return`${e.id}.${t.id}.${r.stack||r.type}`}function zee(e){const{min:t,max:r,minDefined:n,maxDefined:i}=e.getUserBounds();return{min:n?t:Number.NEGATIVE_INFINITY,max:i?r:Number.POSITIVE_INFINITY}}function Lee(e,t,r){const n=e[t]||(e[t]={});return n[r]||(n[r]={})}function lI(e,t,r,n){for(const i of t.getMatchingVisibleMetas(n).reverse()){const a=e[i.index];if(r&&a>0||!r&&a<0)return i.index}return null}function cI(e,t){const{chart:r,_cachedMeta:n}=e,i=r._stacks||(r._stacks={}),{iScale:a,vScale:s,index:o}=n,c=a.axis,l=s.axis,u=Pee(a,s,n),d=t.length;let p;for(let w=0;w<d;++w){const O=t[w],{[c]:I,[l]:R}=O,C=O._stacks||(O._stacks={});p=C[l]=Lee(i,u,I),p[o]=R,p._top=lI(p,s,!0,n.type),p._bottom=lI(p,s,!1,n.type);const j=p._visualValues||(p._visualValues={});j[o]=R}}function D5(e,t){const r=e.scales;return Object.keys(r).filter(n=>r[n].axis===t).shift()}function Dee(e,t){return Cu(e,{active:!1,dataset:void 0,datasetIndex:t,index:t,mode:"default",type:"dataset"})}function Uee(e,t,r){return Cu(e,{active:!1,dataIndex:t,parsed:void 0,raw:void 0,element:r,index:t,mode:"default",type:"data"})}function lg(e,t){const r=e.controller.index,n=e.vScale&&e.vScale.axis;if(n){t=t||e._parsed;for(const i of t){const a=i._stacks;if(!a||a[n]===void 0||a[n][r]===void 0)return;delete a[n][r],a[n]._visualValues!==void 0&&a[n]._visualValues[r]!==void 0&&delete a[n]._visualValues[r]}}}const U5=e=>e==="reset"||e==="none",uI=(e,t)=>t?e:Object.assign({},e),qee=(e,t,r)=>e&&!t.hidden&&t._stacked&&{keys:sI(r,!0),values:null};class lo{constructor(t,r){this.chart=t,this._ctx=t.ctx,this.index=r,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.supportsDecimation=!1,this.$context=void 0,this._syncList=[],this.datasetElementType=new.target.datasetElementType,this.dataElementType=new.target.dataElementType,this.initialize()}initialize(){const t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=L5(t.vScale,t),this.addElements(),this.options.fill&&!this.chart.isPluginEnabled("filler")&&console.warn("Tried to use the 'fill' option without the 'Filler' plugin enabled. Please import and register the 'Filler' plugin and make sure it is not disabled in the options")}updateIndex(t){this.index!==t&&lg(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,r=this._cachedMeta,n=this.getDataset(),i=(d,p,w,O)=>d==="x"?p:d==="r"?O:w,a=r.xAxisID=Jt(n.xAxisID,D5(t,"x")),s=r.yAxisID=Jt(n.yAxisID,D5(t,"y")),o=r.rAxisID=Jt(n.rAxisID,D5(t,"r")),c=r.indexAxis,l=r.iAxisID=i(c,a,s,o),u=r.vAxisID=i(c,s,a,o);r.xScale=this.getScaleForId(a),r.yScale=this.getScaleForId(s),r.rScale=this.getScaleForId(o),r.iScale=this.getScaleForId(l),r.vScale=this.getScaleForId(u)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const r=this._cachedMeta;return t===r.iScale?r.vScale:r.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&kj(this._data,this),t._stacked&&lg(t)}_dataCheck(){const t=this.getDataset(),r=t.data||(t.data=[]),n=this._data;if(pr(r)){const i=this._cachedMeta;this._data=Fee(r,i)}else if(n!==r){if(n){kj(n,this);const i=this._cachedMeta;lg(i),i._parsed=[]}r&&Object.isExtensible(r)&&MQ(r,this),this._syncList=[],this._data=r}}addElements(){const t=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(t.dataset=new this.datasetElementType)}buildOrUpdateElements(t){const r=this._cachedMeta,n=this.getDataset();let i=!1;this._dataCheck();const a=r._stacked;r._stacked=L5(r.vScale,r),r.stack!==n.stack&&(i=!0,lg(r),r.stack=n.stack),this._resyncElements(t),(i||a!==r._stacked)&&(cI(this,r._parsed),r._stacked=L5(r.vScale,r))}configure(){const t=this.chart.config,r=t.datasetScopeKeys(this._type),n=t.getOptionScopes(this.getDataset(),r,!0);this.options=t.createResolver(n,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(t,r){const{_cachedMeta:n,_data:i}=this,{iScale:a,_stacked:s}=n,o=a.axis;let c=t===0&&r===i.length?!0:n._sorted,l=t>0&&n._parsed[t-1],u,d,p;if(this._parsing===!1)n._parsed=i,n._sorted=!0,p=i;else{cn(i[t])?p=this.parseArrayData(n,i,t,r):pr(i[t])?p=this.parseObjectData(n,i,t,r):p=this.parsePrimitiveData(n,i,t,r);const w=()=>d[o]===null||l&&d[o]<l[o];for(u=0;u<r;++u)n._parsed[u+t]=d=p[u],c&&(w()&&(c=!1),l=d);n._sorted=c}s&&cI(this,p)}parsePrimitiveData(t,r,n,i){const{iScale:a,vScale:s}=t,o=a.axis,c=s.axis,l=a.getLabels(),u=a===s,d=new Array(i);let p,w,O;for(p=0,w=i;p<w;++p)O=p+n,d[p]={[o]:u||a.parse(l[O],O),[c]:s.parse(r[O],O)};return d}parseArrayData(t,r,n,i){const{xScale:a,yScale:s}=t,o=new Array(i);let c,l,u,d;for(c=0,l=i;c<l;++c)u=c+n,d=r[u],o[c]={x:a.parse(d[0],u),y:s.parse(d[1],u)};return o}parseObjectData(t,r,n,i){const{xScale:a,yScale:s}=t,{xAxisKey:o="x",yAxisKey:c="y"}=this._parsing,l=new Array(i);let u,d,p,w;for(u=0,d=i;u<d;++u)p=u+n,w=r[p],l[u]={x:a.parse(Eu(w,o),p),y:s.parse(Eu(w,c),p)};return l}getParsed(t){return this._cachedMeta._parsed[t]}getDataElement(t){return this._cachedMeta.data[t]}applyStack(t,r,n){const i=this.chart,a=this._cachedMeta,s=r[t.axis],o={keys:sI(i,!0),values:r._stacks[t.axis]._visualValues};return oI(o,s,a.index,{mode:n})}updateRangeFromParsed(t,r,n,i){const a=n[r.axis];let s=a===null?NaN:a;const o=i&&n._stacks[r.axis];i&&o&&(i.values=o,s=oI(i,a,this._cachedMeta.index)),t.min=Math.min(t.min,s),t.max=Math.max(t.max,s)}getMinMax(t,r){const n=this._cachedMeta,i=n._parsed,a=n._sorted&&t===n.iScale,s=i.length,o=this._getOtherScale(t),c=qee(r,n,this.chart),l={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:u,max:d}=zee(o);let p,w;function O(){w=i[p];const I=w[o.axis];return!En(w[t.axis])||u>I||d<I}for(p=0;p<s&&!(!O()&&(this.updateRangeFromParsed(l,t,w,c),a));++p);if(a){for(p=s-1;p>=0;--p)if(!O()){this.updateRangeFromParsed(l,t,w,c);break}}return l}getAllParsedValues(t){const r=this._cachedMeta._parsed,n=[];let i,a,s;for(i=0,a=r.length;i<a;++i)s=r[i][t.axis],En(s)&&n.push(s);return n}getMaxOverflow(){return!1}getLabelAndValue(t){const r=this._cachedMeta,n=r.iScale,i=r.vScale,a=this.getParsed(t);return{label:n?""+n.getLabelForValue(a[n.axis]):"",value:i?""+i.getLabelForValue(a[i.axis]):""}}_update(t){const r=this._cachedMeta;this.update(t||"default"),r._clip=Nee(Jt(this.options.clip,Ree(r.xScale,r.yScale,this.getMaxOverflow())))}update(t){}draw(){const t=this._ctx,r=this.chart,n=this._cachedMeta,i=n.data||[],a=r.chartArea,s=[],o=this._drawStart||0,c=this._drawCount||i.length-o,l=this.options.drawActiveElementsOnTop;let u;for(n.dataset&&n.dataset.draw(t,a,o,c),u=o;u<o+c;++u){const d=i[u];d.hidden||(d.active&&l?s.push(d):d.draw(t,a))}for(u=0;u<s.length;++u)s[u].draw(t,a)}getStyle(t,r){const n=r?"active":"default";return t===void 0&&this._cachedMeta.dataset?this.resolveDatasetElementOptions(n):this.resolveDataElementOptions(t||0,n)}getContext(t,r,n){const i=this.getDataset();let a;if(t>=0&&t<this._cachedMeta.data.length){const s=this._cachedMeta.data[t];a=s.$context||(s.$context=Uee(this.getContext(),t,s)),a.parsed=this.getParsed(t),a.raw=i.data[t],a.index=a.dataIndex=t}else a=this.$context||(this.$context=Dee(this.chart.getContext(),this.index)),a.dataset=i,a.index=a.datasetIndex=this.index;return a.active=!!r,a.mode=n,a}resolveDatasetElementOptions(t){return this._resolveElementOptions(this.datasetElementType.id,t)}resolveDataElementOptions(t,r){return this._resolveElementOptions(this.dataElementType.id,r,t)}_resolveElementOptions(t,r="default",n){const i=r==="active",a=this._cachedDataOpts,s=t+"-"+r,o=a[s],c=this.enableOptionSharing&&eg(n);if(o)return uI(o,c);const l=this.chart.config,u=l.datasetElementScopeKeys(this._type,t),d=i?[`${t}Hover`,"hover",t,""]:[t,""],p=l.getOptionScopes(this.getDataset(),u),w=Object.keys(un.elements[t]),O=()=>this.getContext(n,i,r),I=l.resolveNamedOptions(p,w,O,d);return I.$shared&&(I.$shared=c,a[s]=Object.freeze(uI(I,c))),I}_resolveAnimations(t,r,n){const i=this.chart,a=this._cachedDataOpts,s=`animation-${r}`,o=a[s];if(o)return o;let c;if(i.options.animation!==!1){const u=this.chart.config,d=u.datasetAnimationScopeKeys(this._type,r),p=u.getOptionScopes(this.getDataset(),d);c=u.createResolver(p,this.getContext(t,n,r))}const l=new iI(i,c&&c.animations);return c&&c._cacheable&&(a[s]=Object.freeze(l)),l}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,r){return!r||U5(t)||this.chart._animationsDisabled}_getSharedOptions(t,r){const n=this.resolveDataElementOptions(t,r),i=this._sharedOptions,a=this.getSharedOptions(n),s=this.includeOptions(r,a)||a!==i;return this.updateSharedOptions(a,r,n),{sharedOptions:a,includeOptions:s}}updateElement(t,r,n,i){U5(i)?Object.assign(t,n):this._resolveAnimations(r,i).update(t,n)}updateSharedOptions(t,r,n){t&&!U5(r)&&this._resolveAnimations(void 0,r).update(t,n)}_setStyle(t,r,n,i){t.active=i;const a=this.getStyle(r,i);this._resolveAnimations(r,n,i).update(t,{options:!i&&this.getSharedOptions(a)||a})}removeHoverStyle(t,r,n){this._setStyle(t,n,"active",!1)}setHoverStyle(t,r,n){this._setStyle(t,n,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const r=this._data,n=this._cachedMeta.data;for(const[o,c,l]of this._syncList)this[o](c,l);this._syncList=[];const i=n.length,a=r.length,s=Math.min(a,i);s&&this.parse(0,s),a>i?this._insertElements(i,a-i,t):a<i&&this._removeElements(a,i-a)}_insertElements(t,r,n=!0){const i=this._cachedMeta,a=i.data,s=t+r;let o;const c=l=>{for(l.length+=r,o=l.length-1;o>=s;o--)l[o]=l[o-r]};for(c(a),o=t;o<s;++o)a[o]=new this.dataElementType;this._parsing&&c(i._parsed),this.parse(t,r),n&&this.updateElements(a,t,r,"reset")}updateElements(t,r,n,i){}_removeElements(t,r){const n=this._cachedMeta;if(this._parsing){const i=n._parsed.splice(t,r);n._stacked&&lg(n,i)}n.data.splice(t,r)}_sync(t){if(this._parsing)this._syncList.push(t);else{const[r,n,i]=t;this[r](n,i)}this.chart._dataChanges.push([this.index,...t])}_onDataPush(){const t=arguments.length;this._sync(["_insertElements",this.getDataset().data.length-t,t])}_onDataPop(){this._sync(["_removeElements",this._cachedMeta.data.length-1,1])}_onDataShift(){this._sync(["_removeElements",0,1])}_onDataSplice(t,r){r&&this._sync(["_removeElements",t,r]);const n=arguments.length-2;n&&this._sync(["_insertElements",t,n])}_onDataUnshift(){this._sync(["_insertElements",0,arguments.length])}}te(lo,"defaults",{}),te(lo,"datasetElementType",null),te(lo,"dataElementType",null);function Vee(e,t){if(!e._cache.$bar){const r=e.getMatchingVisibleMetas(t);let n=[];for(let i=0,a=r.length;i<a;i++)n=n.concat(r[i].controller.getAllParsedValues(e));e._cache.$bar=Ej(n.sort((i,a)=>i-a))}return e._cache.$bar}function Zee(e){const t=e.iScale,r=Vee(t,e.type);let n=t._length,i,a,s,o;const c=()=>{s===32767||s===-32768||(eg(o)&&(n=Math.min(n,Math.abs(s-o)||n)),o=s)};for(i=0,a=r.length;i<a;++i)s=t.getPixelForValue(r[i]),c();for(o=void 0,i=0,a=t.ticks.length;i<a;++i)s=t.getPixelForTick(i),c();return n}function $ee(e,t,r,n){const i=r.barThickness;let a,s;return hr(i)?(a=t.min*r.categoryPercentage,s=r.barPercentage):(a=i*n,s=1),{chunk:a/n,ratio:s,start:t.pixels[e]-a/2}}function Hee(e,t,r,n){const i=t.pixels,a=i[e];let s=e>0?i[e-1]:null,o=e<i.length-1?i[e+1]:null;const c=r.categoryPercentage;s===null&&(s=a-(o===null?t.end-t.start:o-a)),o===null&&(o=a+a-s);const l=a-(a-Math.min(s,o))/2*c;return{chunk:Math.abs(o-s)/2*c/n,ratio:r.barPercentage,start:l}}function Wee(e,t,r,n){const i=r.parse(e[0],n),a=r.parse(e[1],n),s=Math.min(i,a),o=Math.max(i,a);let c=s,l=o;Math.abs(s)>Math.abs(o)&&(c=o,l=s),t[r.axis]=l,t._custom={barStart:c,barEnd:l,start:i,end:a,min:s,max:o}}function fI(e,t,r,n){return cn(e)?Wee(e,t,r,n):t[r.axis]=r.parse(e,n),t}function hI(e,t,r,n){const i=e.iScale,a=e.vScale,s=i.getLabels(),o=i===a,c=[];let l,u,d,p;for(l=r,u=r+n;l<u;++l)p=t[l],d={},d[i.axis]=o||i.parse(s[l],l),c.push(fI(p,d,a,l));return c}function q5(e){return e&&e.barStart!==void 0&&e.barEnd!==void 0}function Kee(e,t,r){return e!==0?rl(e):(t.isHorizontal()?1:-1)*(t.min>=r?1:-1)}function Gee(e){let t,r,n,i,a;return e.horizontal?(t=e.base>e.x,r="left",n="right"):(t=e.base<e.y,r="bottom",n="top"),t?(i="end",a="start"):(i="start",a="end"),{start:r,end:n,reverse:t,top:i,bottom:a}}function Yee(e,t,r,n){let i=t.borderSkipped;const a={};if(!i){e.borderSkipped=a;return}if(i===!0){e.borderSkipped={top:!0,right:!0,bottom:!0,left:!0};return}const{start:s,end:o,reverse:c,top:l,bottom:u}=Gee(e);i==="middle"&&r&&(e.enableBorderRadius=!0,(r._top||0)===n?i=l:(r._bottom||0)===n?i=u:(a[dI(u,s,o,c)]=!0,i=l)),a[dI(i,s,o,c)]=!0,e.borderSkipped=a}function dI(e,t,r,n){return n?(e=Xee(e,t,r),e=pI(e,r,t)):e=pI(e,t,r),e}function Xee(e,t,r){return e===t?r:e===r?t:e}function pI(e,t,r){return e==="start"?t:e==="end"?r:e}function Jee(e,{inflateAmount:t},r){e.inflateAmount=t==="auto"?r===1?.33:0:t}class ew extends lo{parsePrimitiveData(t,r,n,i){return hI(t,r,n,i)}parseArrayData(t,r,n,i){return hI(t,r,n,i)}parseObjectData(t,r,n,i){const{iScale:a,vScale:s}=t,{xAxisKey:o="x",yAxisKey:c="y"}=this._parsing,l=a.axis==="x"?o:c,u=s.axis==="x"?o:c,d=[];let p,w,O,I;for(p=n,w=n+i;p<w;++p)I=r[p],O={},O[a.axis]=a.parse(Eu(I,l),p),d.push(fI(Eu(I,u),O,s,p));return d}updateRangeFromParsed(t,r,n,i){super.updateRangeFromParsed(t,r,n,i);const a=n._custom;a&&r===this._cachedMeta.vScale&&(t.min=Math.min(t.min,a.min),t.max=Math.max(t.max,a.max))}getMaxOverflow(){return 0}getLabelAndValue(t){const r=this._cachedMeta,{iScale:n,vScale:i}=r,a=this.getParsed(t),s=a._custom,o=q5(s)?"["+s.start+", "+s.end+"]":""+i.getLabelForValue(a[i.axis]);return{label:""+n.getLabelForValue(a[n.axis]),value:o}}initialize(){this.enableOptionSharing=!0,super.initialize();const t=this._cachedMeta;t.stack=this.getDataset().stack}update(t){const r=this._cachedMeta;this.updateElements(r.data,0,r.data.length,t)}updateElements(t,r,n,i){const a=i==="reset",{index:s,_cachedMeta:{vScale:o}}=this,c=o.getBasePixel(),l=o.isHorizontal(),u=this._getRuler(),{sharedOptions:d,includeOptions:p}=this._getSharedOptions(r,i);for(let w=r;w<r+n;w++){const O=this.getParsed(w),I=a||hr(O[o.axis])?{base:c,head:c}:this._calculateBarValuePixels(w),R=this._calculateBarIndexPixels(w,u),C=(O._stacks||{})[o.axis],j={horizontal:l,base:I.base,enableBorderRadius:!C||q5(O._custom)||s===C._top||s===C._bottom,x:l?I.head:R.center,y:l?R.center:I.head,height:l?R.size:Math.abs(I.size),width:l?Math.abs(I.size):R.size};p&&(j.options=d||this.resolveDataElementOptions(w,t[w].active?"active":i));const N=j.options||t[w].options;Yee(j,N,C,s),Jee(j,N,u.ratio),this.updateElement(t[w],w,j,i)}}_getStacks(t,r){const{iScale:n}=this._cachedMeta,i=n.getMatchingVisibleMetas(this._type).filter(u=>u.controller.options.grouped),a=n.options.stacked,s=[],o=this._cachedMeta.controller.getParsed(r),c=o&&o[n.axis],l=u=>{const d=u._parsed.find(w=>w[n.axis]===c),p=d&&d[u.vScale.axis];if(hr(p)||isNaN(p))return!0};for(const u of i)if(!(r!==void 0&&l(u))&&((a===!1||s.indexOf(u.stack)===-1||a===void 0&&u.stack===void 0)&&s.push(u.stack),u.index===t))break;return s.length||s.push(void 0),s}_getStackCount(t){return this._getStacks(void 0,t).length}_getStackIndex(t,r,n){const i=this._getStacks(t,n),a=r!==void 0?i.indexOf(r):-1;return a===-1?i.length-1:a}_getRuler(){const t=this.options,r=this._cachedMeta,n=r.iScale,i=[];let a,s;for(a=0,s=r.data.length;a<s;++a)i.push(n.getPixelForValue(this.getParsed(a)[n.axis],a));const o=t.barThickness;return{min:o||Zee(r),pixels:i,start:n._startPixel,end:n._endPixel,stackCount:this._getStackCount(),scale:n,grouped:t.grouped,ratio:o?1:t.categoryPercentage*t.barPercentage}}_calculateBarValuePixels(t){const{_cachedMeta:{vScale:r,_stacked:n,index:i},options:{base:a,minBarLength:s}}=this,o=a||0,c=this.getParsed(t),l=c._custom,u=q5(l);let d=c[r.axis],p=0,w=n?this.applyStack(r,c,n):d,O,I;w!==d&&(p=w-d,w=d),u&&(d=l.barStart,w=l.barEnd-l.barStart,d!==0&&rl(d)!==rl(l.barEnd)&&(p=0),p+=d);const R=!hr(a)&&!u?a:p;let C=r.getPixelForValue(R);if(this.chart.getDataVisibility(t)?O=r.getPixelForValue(p+w):O=C,I=O-C,Math.abs(I)<s){I=Kee(I,r,o)*s,d===o&&(C-=I/2);const j=r.getPixelForDecimal(0),N=r.getPixelForDecimal(1),P=Math.min(j,N),Z=Math.max(j,N);C=Math.max(Math.min(C,Z),P),O=C+I,n&&!u&&(c._stacks[r.axis]._visualValues[i]=r.getValueForPixel(O)-r.getValueForPixel(C))}if(C===r.getPixelForValue(o)){const j=rl(I)*r.getLineWidthForValue(o)/2;C+=j,I-=j}return{size:I,base:C,head:O,center:O+I/2}}_calculateBarIndexPixels(t,r){const n=r.scale,i=this.options,a=i.skipNull,s=Jt(i.maxBarThickness,1/0);let o,c;if(r.grouped){const l=a?this._getStackCount(t):r.stackCount,u=i.barThickness==="flex"?Hee(t,r,i,l):$ee(t,r,i,l),d=this._getStackIndex(this.index,this._cachedMeta.stack,a?t:void 0);o=u.start+u.chunk*d+u.chunk/2,c=Math.min(s,u.chunk*u.ratio)}else o=n.getPixelForValue(this.getParsed(t)[n.axis],t),c=Math.min(s,r.min*r.ratio);return{base:o-c/2,head:o+c/2,center:o,size:c}}draw(){const t=this._cachedMeta,r=t.vScale,n=t.data,i=n.length;let a=0;for(;a<i;++a)this.getParsed(a)[r.axis]!==null&&!n[a].hidden&&n[a].draw(this._ctx)}}te(ew,"id","bar"),te(ew,"defaults",{datasetElementType:!1,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:!0,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}}),te(ew,"overrides",{scales:{_index_:{type:"category",offset:!0,grid:{offset:!0}},_value_:{type:"linear",beginAtZero:!0}}});class tw extends lo{initialize(){this.enableOptionSharing=!0,super.initialize()}parsePrimitiveData(t,r,n,i){const a=super.parsePrimitiveData(t,r,n,i);for(let s=0;s<a.length;s++)a[s]._custom=this.resolveDataElementOptions(s+n).radius;return a}parseArrayData(t,r,n,i){const a=super.parseArrayData(t,r,n,i);for(let s=0;s<a.length;s++){const o=r[n+s];a[s]._custom=Jt(o[2],this.resolveDataElementOptions(s+n).radius)}return a}parseObjectData(t,r,n,i){const a=super.parseObjectData(t,r,n,i);for(let s=0;s<a.length;s++){const o=r[n+s];a[s]._custom=Jt(o&&o.r&&+o.r,this.resolveDataElementOptions(s+n).radius)}return a}getMaxOverflow(){const t=this._cachedMeta.data;let r=0;for(let n=t.length-1;n>=0;--n)r=Math.max(r,t[n].size(this.resolveDataElementOptions(n))/2);return r>0&&r}getLabelAndValue(t){const r=this._cachedMeta,n=this.chart.data.labels||[],{xScale:i,yScale:a}=r,s=this.getParsed(t),o=i.getLabelForValue(s.x),c=a.getLabelForValue(s.y),l=s._custom;return{label:n[t]||"",value:"("+o+", "+c+(l?", "+l:"")+")"}}update(t){const r=this._cachedMeta.data;this.updateElements(r,0,r.length,t)}updateElements(t,r,n,i){const a=i==="reset",{iScale:s,vScale:o}=this._cachedMeta,{sharedOptions:c,includeOptions:l}=this._getSharedOptions(r,i),u=s.axis,d=o.axis;for(let p=r;p<r+n;p++){const w=t[p],O=!a&&this.getParsed(p),I={},R=I[u]=a?s.getPixelForDecimal(.5):s.getPixelForValue(O[u]),C=I[d]=a?o.getBasePixel():o.getPixelForValue(O[d]);I.skip=isNaN(R)||isNaN(C),l&&(I.options=c||this.resolveDataElementOptions(p,w.active?"active":i),a&&(I.options.radius=0)),this.updateElement(w,p,I,i)}}resolveDataElementOptions(t,r){const n=this.getParsed(t);let i=super.resolveDataElementOptions(t,r);i.$shared&&(i=Object.assign({},i,{$shared:!1}));const a=i.radius;return r!=="active"&&(i.radius=0),i.radius+=Jt(n&&n._custom,a),i}}te(tw,"id","bubble"),te(tw,"defaults",{datasetElementType:!1,dataElementType:"point",animations:{numbers:{type:"number",properties:["x","y","borderWidth","radius"]}}}),te(tw,"overrides",{scales:{x:{type:"linear"},y:{type:"linear"}}});function Qee(e,t,r){let n=1,i=1,a=0,s=0;if(t<nn){const o=e,c=o+t,l=Math.cos(o),u=Math.sin(o),d=Math.cos(c),p=Math.sin(c),w=(N,P,Z)=>rg(N,o,c,!0)?1:Math.max(P,P*r,Z,Z*r),O=(N,P,Z)=>rg(N,o,c,!0)?-1:Math.min(P,P*r,Z,Z*r),I=w(0,l,d),R=w(Bn,u,p),C=O(rn,l,d),j=O(rn+Bn,u,p);n=(I-C)/2,i=(R-j)/2,a=-(I+C)/2,s=-(R+j)/2}return{ratioX:n,ratioY:i,offsetX:a,offsetY:s}}class ah extends lo{constructor(t,r){super(t,r),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,r){const n=this.getDataset().data,i=this._cachedMeta;if(this._parsing===!1)i._parsed=n;else{let a=c=>+n[c];if(pr(n[t])){const{key:c="value"}=this._parsing;a=l=>+Eu(n[l],c)}let s,o;for(s=t,o=t+r;s<o;++s)i._parsed[s]=a(s)}}_getRotation(){return oo(this.options.rotation-90)}_getCircumference(){return oo(this.options.circumference)}_getRotationExtents(){let t=nn,r=-nn;for(let n=0;n<this.chart.data.datasets.length;++n)if(this.chart.isDatasetVisible(n)&&this.chart.getDatasetMeta(n).type===this._type){const i=this.chart.getDatasetMeta(n).controller,a=i._getRotation(),s=i._getCircumference();t=Math.min(t,a),r=Math.max(r,a+s)}return{rotation:t,circumference:r-t}}update(t){const r=this.chart,{chartArea:n}=r,i=this._cachedMeta,a=i.data,s=this.getMaxBorderWidth()+this.getMaxOffset(a)+this.options.spacing,o=Math.max((Math.min(n.width,n.height)-s)/2,0),c=Math.min(fQ(this.options.cutout,o),1),l=this._getRingWeight(this.index),{circumference:u,rotation:d}=this._getRotationExtents(),{ratioX:p,ratioY:w,offsetX:O,offsetY:I}=Qee(d,u,c),R=(n.width-s)/p,C=(n.height-s)/w,j=Math.max(Math.min(R,C)/2,0),N=pj(this.options.radius,j),P=Math.max(N*c,0),Z=(N-P)/this._getVisibleDatasetWeightTotal();this.offsetX=O*N,this.offsetY=I*N,i.total=this.calculateTotal(),this.outerRadius=N-Z*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-Z*l,0),this.updateElements(a,0,a.length,t)}_circumference(t,r){const n=this.options,i=this._cachedMeta,a=this._getCircumference();return r&&n.animation.animateRotate||!this.chart.getDataVisibility(t)||i._parsed[t]===null||i.data[t].hidden?0:this.calculateCircumference(i._parsed[t]*a/nn)}updateElements(t,r,n,i){const a=i==="reset",s=this.chart,o=s.chartArea,c=s.options.animation,l=(o.left+o.right)/2,u=(o.top+o.bottom)/2,d=a&&c.animateScale,p=d?0:this.innerRadius,w=d?0:this.outerRadius,{sharedOptions:O,includeOptions:I}=this._getSharedOptions(r,i);let R=this._getRotation(),C;for(C=0;C<r;++C)R+=this._circumference(C,a);for(C=r;C<r+n;++C){const j=this._circumference(C,a),N=t[C],P={x:l+this.offsetX,y:u+this.offsetY,startAngle:R,endAngle:R+j,circumference:j,outerRadius:w,innerRadius:p};I&&(P.options=O||this.resolveDataElementOptions(C,N.active?"active":i)),R+=j,this.updateElement(N,C,P,i)}}calculateTotal(){const t=this._cachedMeta,r=t.data;let n=0,i;for(i=0;i<r.length;i++){const a=t._parsed[i];a!==null&&!isNaN(a)&&this.chart.getDataVisibility(i)&&!r[i].hidden&&(n+=Math.abs(a))}return n}calculateCircumference(t){const r=this._cachedMeta.total;return r>0&&!isNaN(t)?nn*(Math.abs(t)/r):0}getLabelAndValue(t){const r=this._cachedMeta,n=this.chart,i=n.data.labels||[],a=ig(r._parsed[t],n.options.locale);return{label:i[t]||"",value:a}}getMaxBorderWidth(t){let r=0;const n=this.chart;let i,a,s,o,c;if(!t){for(i=0,a=n.data.datasets.length;i<a;++i)if(n.isDatasetVisible(i)){s=n.getDatasetMeta(i),t=s.data,o=s.controller;break}}if(!t)return 0;for(i=0,a=t.length;i<a;++i)c=o.resolveDataElementOptions(i),c.borderAlign!=="inner"&&(r=Math.max(r,c.borderWidth||0,c.hoverBorderWidth||0));return r}getMaxOffset(t){let r=0;for(let n=0,i=t.length;n<i;++n){const a=this.resolveDataElementOptions(n);r=Math.max(r,a.offset||0,a.hoverOffset||0)}return r}_getRingWeightOffset(t){let r=0;for(let n=0;n<t;++n)this.chart.isDatasetVisible(n)&&(r+=this._getRingWeight(n));return r}_getRingWeight(t){return Math.max(Jt(this.chart.data.datasets[t].weight,1),0)}_getVisibleDatasetWeightTotal(){return this._getRingWeightOffset(this.chart.data.datasets.length)||1}}te(ah,"id","doughnut"),te(ah,"defaults",{datasetElementType:!1,dataElementType:"arc",animation:{animateRotate:!0,animateScale:!1},animations:{numbers:{type:"number",properties:["circumference","endAngle","innerRadius","outerRadius","startAngle","x","y","offset","borderWidth","spacing"]}},cutout:"50%",rotation:0,circumference:360,radius:"100%",spacing:0,indexAxis:"r"}),te(ah,"descriptors",{_scriptable:t=>t!=="spacing",_indexable:t=>t!=="spacing"&&!t.startsWith("borderDash")&&!t.startsWith("hoverBorderDash")}),te(ah,"overrides",{aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const r=t.data;if(r.labels.length&&r.datasets.length){const{labels:{pointStyle:n,color:i}}=t.legend.options;return r.labels.map((a,s)=>{const o=t.getDatasetMeta(0).controller.getStyle(s);return{text:a,fillStyle:o.backgroundColor,strokeStyle:o.borderColor,fontColor:i,lineWidth:o.borderWidth,pointStyle:n,hidden:!t.getDataVisibility(s),index:s}})}return[]}},onClick(t,r,n){n.chart.toggleDataVisibility(r.index),n.chart.update()}}}});class rw extends lo{initialize(){this.enableOptionSharing=!0,this.supportsDecimation=!0,super.initialize()}update(t){const r=this._cachedMeta,{dataset:n,data:i=[],_dataset:a}=r,s=this.chart._animationsDisabled;let{start:o,count:c}=Cj(r,i,s);this._drawStart=o,this._drawCount=c,Tj(r)&&(o=0,c=i.length),n._chart=this.chart,n._datasetIndex=this.index,n._decimated=!!a._decimated,n.points=i;const l=this.resolveDatasetElementOptions(t);this.options.showLine||(l.borderWidth=0),l.segment=this.options.segment,this.updateElement(n,void 0,{animated:!s,options:l},t),this.updateElements(i,o,c,t)}updateElements(t,r,n,i){const a=i==="reset",{iScale:s,vScale:o,_stacked:c,_dataset:l}=this._cachedMeta,{sharedOptions:u,includeOptions:d}=this._getSharedOptions(r,i),p=s.axis,w=o.axis,{spanGaps:O,segment:I}=this.options,R=o0(O)?O:Number.POSITIVE_INFINITY,C=this.chart._animationsDisabled||a||i==="none",j=r+n,N=t.length;let P=r>0&&this.getParsed(r-1);for(let Z=0;Z<N;++Z){const X=t[Z],re=C?X:{};if(Z<r||Z>=j){re.skip=!0;continue}const ne=this.getParsed(Z),ae=hr(ne[w]),ue=re[p]=s.getPixelForValue(ne[p],Z),m=re[w]=a||ae?o.getBasePixel():o.getPixelForValue(c?this.applyStack(o,ne,c):ne[w],Z);re.skip=isNaN(ue)||isNaN(m)||ae,re.stop=Z>0&&Math.abs(ne[p]-P[p])>R,I&&(re.parsed=ne,re.raw=l.data[Z]),d&&(re.options=u||this.resolveDataElementOptions(Z,X.active?"active":i)),C||this.updateElement(X,Z,re,i),P=ne}}getMaxOverflow(){const t=this._cachedMeta,r=t.dataset,n=r.options&&r.options.borderWidth||0,i=t.data||[];if(!i.length)return n;const a=i[0].size(this.resolveDataElementOptions(0)),s=i[i.length-1].size(this.resolveDataElementOptions(i.length-1));return Math.max(n,a,s)/2}draw(){const t=this._cachedMeta;t.dataset.updateControlPoints(this.chart.chartArea,t.iScale.axis),super.draw()}}te(rw,"id","line"),te(rw,"defaults",{datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1}),te(rw,"overrides",{scales:{_index_:{type:"category"},_value_:{type:"linear"}}});class cg extends lo{constructor(t,r){super(t,r),this.innerRadius=void 0,this.outerRadius=void 0}getLabelAndValue(t){const r=this._cachedMeta,n=this.chart,i=n.data.labels||[],a=ig(r._parsed[t].r,n.options.locale);return{label:i[t]||"",value:a}}parseObjectData(t,r,n,i){return Zj.bind(this)(t,r,n,i)}update(t){const r=this._cachedMeta.data;this._updateRadius(),this.updateElements(r,0,r.length,t)}getMinMax(){const t=this._cachedMeta,r={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY};return t.data.forEach((n,i)=>{const a=this.getParsed(i).r;!isNaN(a)&&this.chart.getDataVisibility(i)&&(a<r.min&&(r.min=a),a>r.max&&(r.max=a))}),r}_updateRadius(){const t=this.chart,r=t.chartArea,n=t.options,i=Math.min(r.right-r.left,r.bottom-r.top),a=Math.max(i/2,0),s=Math.max(n.cutoutPercentage?a/100*n.cutoutPercentage:1,0),o=(a-s)/t.getVisibleDatasetCount();this.outerRadius=a-o*this.index,this.innerRadius=this.outerRadius-o}updateElements(t,r,n,i){const a=i==="reset",s=this.chart,o=s.options.animation,c=this._cachedMeta.rScale,l=c.xCenter,u=c.yCenter,d=c.getIndexAngle(0)-.5*rn;let p=d,w;const O=360/this.countVisibleElements();for(w=0;w<r;++w)p+=this._computeAngle(w,i,O);for(w=r;w<r+n;w++){const I=t[w];let R=p,C=p+this._computeAngle(w,i,O),j=s.getDataVisibility(w)?c.getDistanceFromCenterForValue(this.getParsed(w).r):0;p=C,a&&(o.animateScale&&(j=0),o.animateRotate&&(R=C=d));const N={x:l,y:u,innerRadius:0,outerRadius:j,startAngle:R,endAngle:C,options:this.resolveDataElementOptions(w,I.active?"active":i)};this.updateElement(I,w,N,i)}}countVisibleElements(){const t=this._cachedMeta;let r=0;return t.data.forEach((n,i)=>{!isNaN(this.getParsed(i).r)&&this.chart.getDataVisibility(i)&&r++}),r}_computeAngle(t,r,n){return this.chart.getDataVisibility(t)?oo(this.resolveDataElementOptions(t,r).angle||n):0}}te(cg,"id","polarArea"),te(cg,"defaults",{dataElementType:"arc",animation:{animateRotate:!0,animateScale:!0},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0}),te(cg,"overrides",{aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const r=t.data;if(r.labels.length&&r.datasets.length){const{labels:{pointStyle:n,color:i}}=t.legend.options;return r.labels.map((a,s)=>{const o=t.getDatasetMeta(0).controller.getStyle(s);return{text:a,fillStyle:o.backgroundColor,strokeStyle:o.borderColor,fontColor:i,lineWidth:o.borderWidth,pointStyle:n,hidden:!t.getDataVisibility(s),index:s}})}return[]}},onClick(t,r,n){n.chart.toggleDataVisibility(r.index),n.chart.update()}}},scales:{r:{type:"radialLinear",angleLines:{display:!1},beginAtZero:!0,grid:{circular:!0},pointLabels:{display:!1},startAngle:0}}});class V5 extends ah{}te(V5,"id","pie"),te(V5,"defaults",{cutout:0,rotation:0,circumference:360,radius:"100%"});class nw extends lo{getLabelAndValue(t){const r=this._cachedMeta.vScale,n=this.getParsed(t);return{label:r.getLabels()[t],value:""+r.getLabelForValue(n[r.axis])}}parseObjectData(t,r,n,i){return Zj.bind(this)(t,r,n,i)}update(t){const r=this._cachedMeta,n=r.dataset,i=r.data||[],a=r.iScale.getLabels();if(n.points=i,t!=="resize"){const s=this.resolveDatasetElementOptions(t);this.options.showLine||(s.borderWidth=0);const o={_loop:!0,_fullLoop:a.length===i.length,options:s};this.updateElement(n,void 0,o,t)}this.updateElements(i,0,i.length,t)}updateElements(t,r,n,i){const a=this._cachedMeta.rScale,s=i==="reset";for(let o=r;o<r+n;o++){const c=t[o],l=this.resolveDataElementOptions(o,c.active?"active":i),u=a.getPointPositionForValue(o,this.getParsed(o).r),d=s?a.xCenter:u.x,p=s?a.yCenter:u.y,w={x:d,y:p,angle:u.angle,skip:isNaN(d)||isNaN(p),options:l};this.updateElement(c,o,w,i)}}}te(nw,"id","radar"),te(nw,"defaults",{datasetElementType:"line",dataElementType:"point",indexAxis:"r",showLine:!0,elements:{line:{fill:"start"}}}),te(nw,"overrides",{aspectRatio:1,scales:{r:{type:"radialLinear"}}});class iw extends lo{getLabelAndValue(t){const r=this._cachedMeta,n=this.chart.data.labels||[],{xScale:i,yScale:a}=r,s=this.getParsed(t),o=i.getLabelForValue(s.x),c=a.getLabelForValue(s.y);return{label:n[t]||"",value:"("+o+", "+c+")"}}update(t){const r=this._cachedMeta,{data:n=[]}=r,i=this.chart._animationsDisabled;let{start:a,count:s}=Cj(r,n,i);if(this._drawStart=a,this._drawCount=s,Tj(r)&&(a=0,s=n.length),this.options.showLine){this.datasetElementType||this.addElements();const{dataset:o,_dataset:c}=r;o._chart=this.chart,o._datasetIndex=this.index,o._decimated=!!c._decimated,o.points=n;const l=this.resolveDatasetElementOptions(t);l.segment=this.options.segment,this.updateElement(o,void 0,{animated:!i,options:l},t)}else this.datasetElementType&&(delete r.dataset,this.datasetElementType=!1);this.updateElements(n,a,s,t)}addElements(){const{showLine:t}=this.options;!this.datasetElementType&&t&&(this.datasetElementType=this.chart.registry.getElement("line")),super.addElements()}updateElements(t,r,n,i){const a=i==="reset",{iScale:s,vScale:o,_stacked:c,_dataset:l}=this._cachedMeta,u=this.resolveDataElementOptions(r,i),d=this.getSharedOptions(u),p=this.includeOptions(i,d),w=s.axis,O=o.axis,{spanGaps:I,segment:R}=this.options,C=o0(I)?I:Number.POSITIVE_INFINITY,j=this.chart._animationsDisabled||a||i==="none";let N=r>0&&this.getParsed(r-1);for(let P=r;P<r+n;++P){const Z=t[P],X=this.getParsed(P),re=j?Z:{},ne=hr(X[O]),ae=re[w]=s.getPixelForValue(X[w],P),ue=re[O]=a||ne?o.getBasePixel():o.getPixelForValue(c?this.applyStack(o,X,c):X[O],P);re.skip=isNaN(ae)||isNaN(ue)||ne,re.stop=P>0&&Math.abs(X[w]-N[w])>C,R&&(re.parsed=X,re.raw=l.data[P]),p&&(re.options=d||this.resolveDataElementOptions(P,Z.active?"active":i)),j||this.updateElement(Z,P,re,i),N=X}this.updateSharedOptions(d,i,u)}getMaxOverflow(){const t=this._cachedMeta,r=t.data||[];if(!this.options.showLine){let o=0;for(let c=r.length-1;c>=0;--c)o=Math.max(o,r[c].size(this.resolveDataElementOptions(c))/2);return o>0&&o}const n=t.dataset,i=n.options&&n.options.borderWidth||0;if(!r.length)return i;const a=r[0].size(this.resolveDataElementOptions(0)),s=r[r.length-1].size(this.resolveDataElementOptions(r.length-1));return Math.max(i,a,s)/2}}te(iw,"id","scatter"),te(iw,"defaults",{datasetElementType:!1,dataElementType:"point",showLine:!1,fill:!1}),te(iw,"overrides",{interaction:{mode:"point"},scales:{x:{type:"linear"},y:{type:"linear"}}});var ete=Object.freeze({__proto__:null,BarController:ew,BubbleController:tw,DoughnutController:ah,LineController:rw,PieController:V5,PolarAreaController:cg,RadarController:nw,ScatterController:iw});function sh(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}class Z5{constructor(t){te(this,"options");this.options=t||{}}static override(t){Object.assign(Z5.prototype,t)}init(){}formats(){return sh()}parse(){return sh()}format(){return sh()}add(){return sh()}diff(){return sh()}startOf(){return sh()}endOf(){return sh()}}var tte={_date:Z5};function rte(e,t,r,n){const{controller:i,data:a,_sorted:s}=e,o=i._cachedMeta.iScale,c=e.dataset&&e.dataset.options?e.dataset.options.spanGaps:null;if(o&&t===o.axis&&t!=="r"&&s&&a.length){const l=o._reversePixels?kQ:cc;if(n){if(i._sharedOptions){const u=a[0],d=typeof u.getRange=="function"&&u.getRange(t);if(d){const p=l(a,t,r-d),w=l(a,t,r+d);return{lo:p.lo,hi:w.hi}}}}else{const u=l(a,t,r);if(c){const{vScale:d}=i._cachedMeta,{_parsed:p}=e,w=p.slice(0,u.lo+1).reverse().findIndex(I=>!hr(I[d.axis]));u.lo-=Math.max(0,w);const O=p.slice(u.hi).findIndex(I=>!hr(I[d.axis]));u.hi+=Math.max(0,O)}return u}}return{lo:0,hi:a.length-1}}function ug(e,t,r,n,i){const a=e.getSortedVisibleDatasetMetas(),s=r[t];for(let o=0,c=a.length;o<c;++o){const{index:l,data:u}=a[o],{lo:d,hi:p}=rte(a[o],t,s,i);for(let w=d;w<=p;++w){const O=u[w];O.skip||n(O,l,w)}}}function nte(e){const t=e.indexOf("x")!==-1,r=e.indexOf("y")!==-1;return function(n,i){const a=t?Math.abs(n.x-i.x):0,s=r?Math.abs(n.y-i.y):0;return Math.sqrt(Math.pow(a,2)+Math.pow(s,2))}}function $5(e,t,r,n,i){const a=[];return!i&&!e.isPointInArea(t)||ug(e,r,t,function(s,o,c){!i&&!uc(s,e.chartArea,0)||s.inRange(t.x,t.y,n)&&a.push({element:s,datasetIndex:o,index:c})},!0),a}function ite(e,t,r,n){let i=[];function a(s,o,c){const{startAngle:l,endAngle:u}=s.getProps(["startAngle","endAngle"],n),{angle:d}=_j(s,{x:t.x,y:t.y});rg(d,l,u)&&i.push({element:s,datasetIndex:o,index:c})}return ug(e,r,t,a),i}function ate(e,t,r,n,i,a){let s=[];const o=nte(r);let c=Number.POSITIVE_INFINITY;function l(u,d,p){const w=u.inRange(t.x,t.y,i);if(n&&!w)return;const O=u.getCenterPoint(i);if(!(a||e.isPointInArea(O))&&!w)return;const I=o(t,O);I<c?(s=[{element:u,datasetIndex:d,index:p}],c=I):I===c&&s.push({element:u,datasetIndex:d,index:p})}return ug(e,r,t,l),s}function H5(e,t,r,n,i,a){return!a&&!e.isPointInArea(t)?[]:r==="r"&&!n?ite(e,t,r,i):ate(e,t,r,n,i,a)}function mI(e,t,r,n,i){const a=[],s=r==="x"?"inXRange":"inYRange";let o=!1;return ug(e,r,t,(c,l,u)=>{c[s]&&c[s](t[r],i)&&(a.push({element:c,datasetIndex:l,index:u}),o=o||c.inRange(t.x,t.y,i))}),n&&!o?[]:a}var ste={evaluateInteractionItems:ug,modes:{index(e,t,r,n){const i=nh(t,e),a=r.axis||"x",s=r.includeInvisible||!1,o=r.intersect?$5(e,i,a,n,s):H5(e,i,a,!1,n,s),c=[];return o.length?(e.getSortedVisibleDatasetMetas().forEach(l=>{const u=o[0].index,d=l.data[u];d&&!d.skip&&c.push({element:d,datasetIndex:l.index,index:u})}),c):[]},dataset(e,t,r,n){const i=nh(t,e),a=r.axis||"xy",s=r.includeInvisible||!1;let o=r.intersect?$5(e,i,a,n,s):H5(e,i,a,!1,n,s);if(o.length>0){const c=o[0].datasetIndex,l=e.getDatasetMeta(c).data;o=[];for(let u=0;u<l.length;++u)o.push({element:l[u],datasetIndex:c,index:u})}return o},point(e,t,r,n){const i=nh(t,e),a=r.axis||"xy",s=r.includeInvisible||!1;return $5(e,i,a,n,s)},nearest(e,t,r,n){const i=nh(t,e),a=r.axis||"xy",s=r.includeInvisible||!1;return H5(e,i,a,r.intersect,n,s)},x(e,t,r,n){const i=nh(t,e);return mI(e,i,"x",r.intersect,n)},y(e,t,r,n){const i=nh(t,e);return mI(e,i,"y",r.intersect,n)}}};const gI=["left","top","right","bottom"];function fg(e,t){return e.filter(r=>r.pos===t)}function bI(e,t){return e.filter(r=>gI.indexOf(r.pos)===-1&&r.box.axis===t)}function hg(e,t){return e.sort((r,n)=>{const i=t?n:r,a=t?r:n;return i.weight===a.weight?i.index-a.index:i.weight-a.weight})}function ote(e){const t=[];let r,n,i,a,s,o;for(r=0,n=(e||[]).length;r<n;++r)i=e[r],{position:a,options:{stack:s,stackWeight:o=1}}=i,t.push({index:r,box:i,pos:a,horizontal:i.isHorizontal(),weight:i.weight,stack:s&&a+s,stackWeight:o});return t}function lte(e){const t={};for(const r of e){const{stack:n,pos:i,stackWeight:a}=r;if(!n||!gI.includes(i))continue;const s=t[n]||(t[n]={count:0,placed:0,weight:0,size:0});s.count++,s.weight+=a}return t}function cte(e,t){const r=lte(e),{vBoxMaxWidth:n,hBoxMaxHeight:i}=t;let a,s,o;for(a=0,s=e.length;a<s;++a){o=e[a];const{fullSize:c}=o.box,l=r[o.stack],u=l&&o.stackWeight/l.weight;o.horizontal?(o.width=u?u*n:c&&t.availableWidth,o.height=i):(o.width=n,o.height=u?u*i:c&&t.availableHeight)}return r}function ute(e){const t=ote(e),r=hg(t.filter(l=>l.box.fullSize),!0),n=hg(fg(t,"left"),!0),i=hg(fg(t,"right")),a=hg(fg(t,"top"),!0),s=hg(fg(t,"bottom")),o=bI(t,"x"),c=bI(t,"y");return{fullSize:r,leftAndTop:n.concat(a),rightAndBottom:i.concat(c).concat(s).concat(o),chartArea:fg(t,"chartArea"),vertical:n.concat(i).concat(c),horizontal:a.concat(s).concat(o)}}function yI(e,t,r,n){return Math.max(e[r],t[r])+Math.max(e[n],t[n])}function vI(e,t){e.top=Math.max(e.top,t.top),e.left=Math.max(e.left,t.left),e.bottom=Math.max(e.bottom,t.bottom),e.right=Math.max(e.right,t.right)}function fte(e,t,r,n){const{pos:i,box:a}=r,s=e.maxPadding;if(!pr(i)){r.size&&(e[i]-=r.size);const d=n[r.stack]||{size:0,count:1};d.size=Math.max(d.size,r.horizontal?a.height:a.width),r.size=d.size/d.count,e[i]+=r.size}a.getPadding&&vI(s,a.getPadding());const o=Math.max(0,t.outerWidth-yI(s,e,"left","right")),c=Math.max(0,t.outerHeight-yI(s,e,"top","bottom")),l=o!==e.w,u=c!==e.h;return e.w=o,e.h=c,r.horizontal?{same:l,other:u}:{same:u,other:l}}function hte(e){const t=e.maxPadding;function r(n){const i=Math.max(t[n]-e[n],0);return e[n]+=i,i}e.y+=r("top"),e.x+=r("left"),r("right"),r("bottom")}function dte(e,t){const r=t.maxPadding;function n(i){const a={left:0,top:0,right:0,bottom:0};return i.forEach(s=>{a[s]=Math.max(t[s],r[s])}),a}return n(e?["left","right"]:["top","bottom"])}function dg(e,t,r,n){const i=[];let a,s,o,c,l,u;for(a=0,s=e.length,l=0;a<s;++a){o=e[a],c=o.box,c.update(o.width||t.w,o.height||t.h,dte(o.horizontal,t));const{same:d,other:p}=fte(t,r,o,n);l|=d&&i.length,u=u||p,c.fullSize||i.push(o)}return l&&dg(i,t,r,n)||u}function aw(e,t,r,n,i){e.top=r,e.left=t,e.right=t+n,e.bottom=r+i,e.width=n,e.height=i}function wI(e,t,r,n){const i=r.padding;let{x:a,y:s}=t;for(const o of e){const c=o.box,l=n[o.stack]||{count:1,placed:0,weight:1},u=o.stackWeight/l.weight||1;if(o.horizontal){const d=t.w*u,p=l.size||c.height;eg(l.start)&&(s=l.start),c.fullSize?aw(c,i.left,s,r.outerWidth-i.right-i.left,p):aw(c,t.left+l.placed,s,d,p),l.start=s,l.placed+=d,s=c.bottom}else{const d=t.h*u,p=l.size||c.width;eg(l.start)&&(a=l.start),c.fullSize?aw(c,a,i.top,p,r.outerHeight-i.bottom-i.top):aw(c,a,t.top+l.placed,p,d),l.start=a,l.placed+=d,a=c.right}}t.x=a,t.y=s}var Wi={addBox(e,t){e.boxes||(e.boxes=[]),t.fullSize=t.fullSize||!1,t.position=t.position||"top",t.weight=t.weight||0,t._layers=t._layers||function(){return[{z:0,draw(r){t.draw(r)}}]},e.boxes.push(t)},removeBox(e,t){const r=e.boxes?e.boxes.indexOf(t):-1;r!==-1&&e.boxes.splice(r,1)},configure(e,t,r){t.fullSize=r.fullSize,t.position=r.position,t.weight=r.weight},update(e,t,r,n){if(!e)return;const i=Hi(e.options.layout.padding),a=Math.max(t-i.width,0),s=Math.max(r-i.height,0),o=ute(e.boxes),c=o.vertical,l=o.horizontal;Pr(e.boxes,I=>{typeof I.beforeLayout=="function"&&I.beforeLayout()});const u=c.reduce((I,R)=>R.box.options&&R.box.options.display===!1?I:I+1,0)||1,d=Object.freeze({outerWidth:t,outerHeight:r,padding:i,availableWidth:a,availableHeight:s,vBoxMaxWidth:a/2/u,hBoxMaxHeight:s/2}),p=Object.assign({},i);vI(p,Hi(n));const w=Object.assign({maxPadding:p,w:a,h:s,x:i.left,y:i.top},i),O=cte(c.concat(l),d);dg(o.fullSize,w,d,O),dg(c,w,d,O),dg(l,w,d,O)&&dg(c,w,d,O),hte(w),wI(o.leftAndTop,w,d,O),w.x+=w.w,w.y+=w.h,wI(o.rightAndBottom,w,d,O),e.chartArea={left:w.left,top:w.top,right:w.left+w.w,bottom:w.top+w.h,height:w.h,width:w.w},Pr(o.chartArea,I=>{const R=I.box;Object.assign(R,e.chartArea),R.update(w.w,w.h,{left:0,top:0,right:0,bottom:0})})}};class xI{acquireContext(t,r){}releaseContext(t){return!1}addEventListener(t,r,n){}removeEventListener(t,r,n){}getDevicePixelRatio(){return 1}getMaximumSize(t,r,n,i){return r=Math.max(0,r||t.width),n=n||t.height,{width:r,height:Math.max(0,i?Math.floor(r/i):n)}}isAttached(t){return!0}updateConfig(t){}}class pte extends xI{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const sw="$chartjs",mte={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},_I=e=>e===null||e==="";function gte(e,t){const r=e.style,n=e.getAttribute("height"),i=e.getAttribute("width");if(e[sw]={initial:{height:n,width:i,style:{display:r.display,height:r.height,width:r.width}}},r.display=r.display||"block",r.boxSizing=r.boxSizing||"border-box",_I(i)){const a=Wj(e,"width");a!==void 0&&(e.width=a)}if(_I(n))if(e.style.height==="")e.height=e.width/(t||2);else{const a=Wj(e,"height");a!==void 0&&(e.height=a)}return e}const SI=bee?{passive:!0}:!1;function bte(e,t,r){e&&e.addEventListener(t,r,SI)}function yte(e,t,r){e&&e.canvas&&e.canvas.removeEventListener(t,r,SI)}function vte(e,t){const r=mte[e.type]||e.type,{x:n,y:i}=nh(e,t);return{type:r,chart:t,native:e,x:n!==void 0?n:null,y:i!==void 0?i:null}}function ow(e,t){for(const r of e)if(r===t||r.contains(t))return!0}function wte(e,t,r){const n=e.canvas,i=new MutationObserver(a=>{let s=!1;for(const o of a)s=s||ow(o.addedNodes,n),s=s&&!ow(o.removedNodes,n);s&&r()});return i.observe(document,{childList:!0,subtree:!0}),i}function xte(e,t,r){const n=e.canvas,i=new MutationObserver(a=>{let s=!1;for(const o of a)s=s||ow(o.removedNodes,n),s=s&&!ow(o.addedNodes,n);s&&r()});return i.observe(document,{childList:!0,subtree:!0}),i}const pg=new Map;let kI=0;function EI(){const e=window.devicePixelRatio;e!==kI&&(kI=e,pg.forEach((t,r)=>{r.currentDevicePixelRatio!==e&&t()}))}function _te(e,t){pg.size||window.addEventListener("resize",EI),pg.set(e,t)}function Ste(e){pg.delete(e),pg.size||window.removeEventListener("resize",EI)}function kte(e,t,r){const n=e.canvas,i=n&&z5(n);if(!i)return;const a=Aj((o,c)=>{const l=i.clientWidth;r(o,c),l<i.clientWidth&&r()},window),s=new ResizeObserver(o=>{const c=o[0],l=c.contentRect.width,u=c.contentRect.height;l===0&&u===0||a(l,u)});return s.observe(i),_te(e,a),s}function W5(e,t,r){r&&r.disconnect(),t==="resize"&&Ste(e)}function Ete(e,t,r){const n=e.canvas,i=Aj(a=>{e.ctx!==null&&r(vte(a,e))},e);return bte(n,t,i),i}class Mte extends xI{acquireContext(t,r){const n=t&&t.getContext&&t.getContext("2d");return n&&n.canvas===t?(gte(t,r),n):null}releaseContext(t){const r=t.canvas;if(!r[sw])return!1;const n=r[sw].initial;["height","width"].forEach(a=>{const s=n[a];hr(s)?r.removeAttribute(a):r.setAttribute(a,s)});const i=n.style||{};
vendor: 5,860 bytes, line 15
15return Object.keys(i).forEach(a=>{r.style[a]=i[a]}),r.width=r.width,delete r[sw],!0}addEventListener(t,r,n){this.removeEventListener(t,r);const i=t.$proxies||(t.$proxies={}),a={attach:wte,detach:xte,resize:kte}[r]||Ete;i[r]=a(t,r,n)}removeEventListener(t,r){const n=t.$proxies||(t.$proxies={}),i=n[r];i&&(({attach:W5,detach:W5,resize:W5}[r]||yte)(t,r,i),n[r]=void 0)}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,r,n,i){return gee(t,r,n,i)}isAttached(t){const r=t&&z5(t);return!!(r&&r.isConnected)}}function Ate(e){return!P5()||typeof OffscreenCanvas<"u"&&e instanceof OffscreenCanvas?pte:Mte}let hc=(v2=class{constructor(){te(this,"x");te(this,"y");te(this,"active",!1);te(this,"options");te(this,"$animations")}tooltipPosition(e){const{x:t,y:r}=this.getProps(["x","y"],e);return{x:t,y:r}}hasValue(){return o0(this.x)&&o0(this.y)}getProps(e,t){const r=this.$animations;if(!t||!r)return this;const n={};return e.forEach(i=>{n[i]=r[i]&&r[i].active()?r[i]._to:this[i]}),n}},te(v2,"defaults",{}),te(v2,"defaultRoutes"),v2);function Cte(e,t){const r=e.options.ticks,n=Tte(e),i=Math.min(r.maxTicksLimit||n,n),a=r.major.enabled?Ite(t):[],s=a.length,o=a[0],c=a[s-1],l=[];if(s>i)return Ote(t,l,a,s/i),l;const u=jte(a,t,i);if(s>0){let d,p;const w=s>1?Math.round((c-o)/(s-1)):null;for(lw(t,l,u,hr(w)?0:o-w,o),d=0,p=s-1;d<p;d++)lw(t,l,u,a[d],a[d+1]);return lw(t,l,u,c,hr(w)?t.length:c+w),l}return lw(t,l,u),l}function Tte(e){const t=e.options.offset,r=e._tickSize(),n=e._length/r+(t?0:1),i=e._maxLength/r;return Math.floor(Math.min(n,i))}function jte(e,t,r){const n=Bte(e),i=t.length/r;if(!n)return Math.max(i,1);const a=vQ(n);for(let s=0,o=a.length-1;s<o;s++){const c=a[s];if(c>i)return c}return Math.max(i,1)}function Ite(e){const t=[];let r,n;for(r=0,n=e.length;r<n;r++)e[r].major&&t.push(r);return t}function Ote(e,t,r,n){let i=0,a=r[0],s;for(n=Math.ceil(n),s=0;s<e.length;s++)s===a&&(t.push(e[s]),i++,a=r[i*n])}function lw(e,t,r,n,i){const a=Jt(n,0),s=Math.min(Jt(i,e.length),e.length);let o=0,c,l,u;for(r=Math.ceil(r),i&&(c=i-n,r=c/Math.floor(c/r)),u=a;u<0;)o++,u=Math.round(a+o*r);for(l=Math.max(a,0);l<s;l++)l===u&&(t.push(e[l]),o++,u=Math.round(a+o*r))}function Bte(e){const t=e.length;let r,n;if(t<2)return!1;for(n=e[0],r=1;r<t;++r)if(e[r]-e[r-1]!==n)return!1;return n}const Rte=e=>e==="left"?"right":e==="right"?"left":e,MI=(e,t,r)=>t==="top"||t==="left"?e[t]+r:e[t]-r,AI=(e,t)=>Math.min(t||e,e);function CI(e,t){const r=[],n=e.length/t,i=e.length;let a=0;for(;a<i;a+=n)r.push(e[Math.floor(a)]);return r}function Nte(e,t,r){const n=e.ticks.length,i=Math.min(t,n-1),a=e._startPixel,s=e._endPixel,o=1e-6;let c=e.getPixelForTick(i),l;if(!(r&&(n===1?l=Math.max(c-a,s-c):t===0?l=(e.getPixelForTick(1)-c)/2:l=(c-e.getPixelForTick(i-1))/2,c+=i<t?l:-l,c<a-o||c>s+o)))return c}function Fte(e,t){Pr(e,r=>{const n=r.gc,i=n.length/2;let a;if(i>t){for(a=0;a<i;++a)delete r.data[n[a]];n.splice(0,i)}})}function mg(e){return e.drawTicks?e.tickLength:0}function TI(e,t){if(!e.display)return 0;const r=ii(e.font,t),n=Hi(e.padding);return(cn(e.text)?e.text.length:1)*r.lineHeight+n.height}function Pte(e,t){return Cu(e,{scale:t,type:"scale"})}function zte(e,t,r){return Cu(e,{tick:r,index:t,type:"tick"})}function Lte(e,t,r){let n=A5(e);return(r&&t!=="right"||!r&&t==="right")&&(n=Rte(n)),n}function Dte(e,t,r,n){const{top:i,left:a,bottom:s,right:o,chart:c}=e,{chartArea:l,scales:u}=c;let d=0,p,w,O;const I=s-i,R=o-a;if(e.isHorizontal()){if(w=$i(n,a,o),pr(r)){const C=Object.keys(r)[0],j=r[C];O=u[C].getPixelForValue(j)+I-t}else r==="center"?O=(l.bottom+l.top)/2+I-t:O=MI(e,r,t);p=o-a}else{if(pr(r)){const C=Object.keys(r)[0],j=r[C];w=u[C].getPixelForValue(j)-R+t}else r==="center"?w=(l.left+l.right)/2-R+t:w=MI(e,r,t);O=$i(n,s,i),d=r==="left"?-Bn:Bn}return{titleX:w,titleY:O,maxWidth:p,rotation:d}}class oh extends hc{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=!1,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=!1,this.$context=void 0}init(t){this.options=t.setContext(this.getContext()),this.axis=t.axis,this._userMin=this.parse(t.min),this._userMax=this.parse(t.max),this._suggestedMin=this.parse(t.suggestedMin),this._suggestedMax=this.parse(t.suggestedMax)}parse(t,r){return t}getUserBounds(){let{_userMin:t,_userMax:r,_suggestedMin:n,_suggestedMax:i}=this;return t=Ja(t,Number.POSITIVE_INFINITY),r=Ja(r,Number.NEGATIVE_INFINITY),n=Ja(n,Number.POSITIVE_INFINITY),i=Ja(i,Number.NEGATIVE_INFINITY),{min:Ja(t,n),max:Ja(r,i),minDefined:En(t),maxDefined:En(r)}}getMinMax(t){let{min:r,max:n,minDefined:i,maxDefined:a}=this.getUserBounds(),s;if(i&&a)return{min:r,max:n};const o=this.getMatchingVisibleMetas();for(let c=0,l=o.length;c<l;++c)s=o[c].controller.getMinMax(this,t),i||(r=Math.min(r,s.min)),a||(n=Math.max(n,s.max));return r=a&&r>n?n:r,n=i&&r>n?r:n,{min:Ja(r,Ja(n,r)),max:Ja(n,Ja(r,n))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}
vendor: 104,993 bytes, lines 15-17
15getLabelItems(t=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(t))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){Wr(this.options.beforeUpdate,[this])}update(t,r,n){const{beginAtZero:i,grace:a,ticks:s}=this.options,o=s.sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=r,this._margins=n=Object.assign({left:0,right:0,top:0,bottom:0},n),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+n.left+n.right:this.height+n.top+n.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=KQ(this,a,i),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const c=o<this.ticks.length;this._convertTicksToLabels(c?CI(this.ticks,o):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),s.display&&(s.autoSkip||s.source==="auto")&&(this.ticks=Cte(this,this.ticks),this._labelSizes=null,this.afterAutoSkip()),c&&this._convertTicksToLabels(this.ticks),this.beforeFit(),this.fit(),this.afterFit(),this.afterUpdate()}configure(){let t=this.options.reverse,r,n;this.isHorizontal()?(r=this.left,n=this.right):(r=this.top,n=this.bottom,t=!t),this._startPixel=r,this._endPixel=n,this._reversePixels=t,this._length=n-r,this._alignToPixels=this.options.alignToPixels}afterUpdate(){Wr(this.options.afterUpdate,[this])}beforeSetDimensions(){Wr(this.options.beforeSetDimensions,[this])}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=0,this.right=this.width):(this.height=this.maxHeight,this.top=0,this.bottom=this.height),this.paddingLeft=0,this.paddingTop=0,this.paddingRight=0,this.paddingBottom=0}afterSetDimensions(){Wr(this.options.afterSetDimensions,[this])}_callHooks(t){this.chart.notifyPlugins(t,this.getContext()),Wr(this.options[t],[this])}beforeDataLimits(){this._callHooks("beforeDataLimits")}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits")}beforeBuildTicks(){this._callHooks("beforeBuildTicks")}buildTicks(){return[]}afterBuildTicks(){this._callHooks("afterBuildTicks")}beforeTickToLabelConversion(){Wr(this.options.beforeTickToLabelConversion,[this])}generateTickLabels(t){const r=this.options.ticks;let n,i,a;for(n=0,i=t.length;n<i;n++)a=t[n],a.label=Wr(r.callback,[a.value,n,t],this)}afterTickToLabelConversion(){Wr(this.options.afterTickToLabelConversion,[this])}beforeCalculateLabelRotation(){Wr(this.options.beforeCalculateLabelRotation,[this])}calculateLabelRotation(){const t=this.options,r=t.ticks,n=AI(this.ticks.length,t.ticks.maxTicksLimit),i=r.minRotation||0,a=r.maxRotation;let s=i,o,c,l;if(!this._isVisible()||!r.display||i>=a||n<=1||!this.isHorizontal()){this.labelRotation=i;return}const u=this._getLabelSizes(),d=u.widest.width,p=u.highest.height,w=mi(this.chart.width-d,0,this.maxWidth);o=t.offset?this.maxWidth/n:w/(n-1),d+6>o&&(o=w/(n-(t.offset?.5:1)),c=this.maxHeight-mg(t.grid)-r.padding-TI(t.title,this.chart.options.font),l=Math.sqrt(d*d+p*p),s=k5(Math.min(Math.asin(mi((u.highest.height+6)/o,-1,1)),Math.asin(mi(c/l,-1,1))-Math.asin(mi(p/l,-1,1)))),s=Math.max(i,Math.min(a,s))),this.labelRotation=s}afterCalculateLabelRotation(){Wr(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){Wr(this.options.beforeFit,[this])}fit(){const t={width:0,height:0},{chart:r,options:{ticks:n,title:i,grid:a}}=this,s=this._isVisible(),o=this.isHorizontal();if(s){const c=TI(i,r.options.font);if(o?(t.width=this.maxWidth,t.height=mg(a)+c):(t.height=this.maxHeight,t.width=mg(a)+c),n.display&&this.ticks.length){const{first:l,last:u,widest:d,highest:p}=this._getLabelSizes(),w=n.padding*2,O=oo(this.labelRotation),I=Math.cos(O),R=Math.sin(O);if(o){const C=n.mirror?0:R*d.width+I*p.height;t.height=Math.min(this.maxHeight,t.height+C+w)}else{const C=n.mirror?0:I*d.width+R*p.height;t.width=Math.min(this.maxWidth,t.width+C+w)}this._calculatePadding(l,u,R,I)}}this._handleMargins(),o?(this.width=this._length=r.width-this._margins.left-this._margins.right,this.height=t.height):(this.width=t.width,this.height=this._length=r.height-this._margins.top-this._margins.bottom)}_calculatePadding(t,r,n,i){const{ticks:{align:a,padding:s},position:o}=this.options,c=this.labelRotation!==0,l=o!=="top"&&this.axis==="x";if(this.isHorizontal()){const u=this.getPixelForTick(0)-this.left,d=this.right-this.getPixelForTick(this.ticks.length-1);let p=0,w=0;c?l?(p=i*t.width,w=n*r.height):(p=n*t.height,w=i*r.width):a==="start"?w=r.width:a==="end"?p=t.width:a!=="inner"&&(p=t.width/2,w=r.width/2),this.paddingLeft=Math.max((p-u+s)*this.width/(this.width-u),0),this.paddingRight=Math.max((w-d+s)*this.width/(this.width-d),0)}else{let u=r.height/2,d=t.height/2;a==="start"?(u=0,d=t.height):a==="end"&&(u=r.height,d=0),this.paddingTop=u+s,this.paddingBottom=d+s}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){Wr(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:r}=this.options;return r==="top"||r==="bottom"||t==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){this.beforeTickToLabelConversion(),this.generateTickLabels(t);let r,n;for(r=0,n=t.length;r<n;r++)hr(t[r].label)&&(t.splice(r,1),n--,r--);this.afterTickToLabelConversion()}_getLabelSizes(){let t=this._labelSizes;if(!t){const r=this.options.ticks.sampleSize;let n=this.ticks;r<n.length&&(n=CI(n,r)),this._labelSizes=t=this._computeLabelSizes(n,n.length,this.options.ticks.maxTicksLimit)}return t}_computeLabelSizes(t,r,n){const{ctx:i,_longestTextCache:a}=this,s=[],o=[],c=Math.floor(r/AI(r,n));let l=0,u=0,d,p,w,O,I,R,C,j,N,P,Z;for(d=0;d<r;d+=c){if(O=t[d].label,I=this._resolveTickFontOptions(d),i.font=R=I.string,C=a[R]=a[R]||{data:{},gc:[]},j=I.lineHeight,N=P=0,!hr(O)&&!cn(O))N=Hv(i,C.data,C.gc,N,O),P=j;else if(cn(O))for(p=0,w=O.length;p<w;++p)Z=O[p],!hr(Z)&&!cn(Z)&&(N=Hv(i,C.data,C.gc,N,Z),P+=j);s.push(N),o.push(P),l=Math.max(N,l),u=Math.max(P,u)}Fte(a,r);const X=s.indexOf(l),re=o.indexOf(u),ne=ae=>({width:s[ae]||0,height:o[ae]||0});return{first:ne(0),last:ne(r-1),widest:ne(X),highest:ne(re),widths:s,heights:o}}getLabelForValue(t){return t}getPixelForValue(t,r){return NaN}getValueForPixel(t){}getPixelForTick(t){const r=this.ticks;return t<0||t>r.length-1?null:this.getPixelForValue(r[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const r=this._startPixel+t*this._length;return SQ(this._alignToPixels?Qf(this.chart,r,0):r)}getDecimalForPixel(t){const r=(t-this._startPixel)/this._length;return this._reversePixels?1-r:r}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:r}=this;return t<0&&r<0?r:t>0&&r>0?t:0}getContext(t){const r=this.ticks||[];if(t>=0&&t<r.length){const n=r[t];return n.$context||(n.$context=zte(this.getContext(),t,n))}return this.$context||(this.$context=Pte(this.chart.getContext(),this))}_tickSize(){const t=this.options.ticks,r=oo(this.labelRotation),n=Math.abs(Math.cos(r)),i=Math.abs(Math.sin(r)),a=this._getLabelSizes(),s=t.autoSkipPadding||0,o=a?a.widest.width+s:0,c=a?a.highest.height+s:0;return this.isHorizontal()?c*n>o*i?o/n:c/i:c*i<o*n?c/n:o/i}_isVisible(){const t=this.options.display;return t!=="auto"?!!t:this.getMatchingVisibleMetas().length>0}_computeGridLineItems(t){const r=this.axis,n=this.chart,i=this.options,{grid:a,position:s,border:o}=i,c=a.offset,l=this.isHorizontal(),u=this.ticks.length+(c?1:0),d=mg(a),p=[],w=o.setContext(this.getContext()),O=w.display?w.width:0,I=O/2,R=function(_){return Qf(n,_,O)};let C,j,N,P,Z,X,re,ne,ae,ue,m,A;if(s==="top")C=R(this.bottom),X=this.bottom-d,ne=C-I,ue=R(t.top)+I,A=t.bottom;else if(s==="bottom")C=R(this.top),ue=t.top,A=R(t.bottom)-I,X=C+I,ne=this.top+d;else if(s==="left")C=R(this.right),Z=this.right-d,re=C-I,ae=R(t.left)+I,m=t.right;else if(s==="right")C=R(this.left),ae=t.left,m=R(t.right)-I,Z=C+I,re=this.left+d;else if(r==="x"){if(s==="center")C=R((t.top+t.bottom)/2+.5);else if(pr(s)){const _=Object.keys(s)[0],B=s[_];C=R(this.chart.scales[_].getPixelForValue(B))}ue=t.top,A=t.bottom,X=C+I,ne=X+d}else if(r==="y"){if(s==="center")C=R((t.left+t.right)/2);else if(pr(s)){const _=Object.keys(s)[0],B=s[_];C=R(this.chart.scales[_].getPixelForValue(B))}Z=C-I,re=Z-d,ae=t.left,m=t.right}const f=Jt(i.ticks.maxTicksLimit,u),g=Math.max(1,Math.ceil(u/f));for(j=0;j<u;j+=g){const _=this.getContext(j),B=a.setContext(_),T=o.setContext(_),S=B.lineWidth,h=B.color,x=T.dash||[],v=T.dashOffset,F=B.tickWidth,Q=B.tickColor,G=B.tickBorderDash||[],J=B.tickBorderDashOffset;N=Nte(this,j,c),N!==void 0&&(P=Qf(n,N,S),l?Z=re=ae=m=P:X=ne=ue=A=P,p.push({tx1:Z,ty1:X,tx2:re,ty2:ne,x1:ae,y1:ue,x2:m,y2:A,width:S,color:h,borderDash:x,borderDashOffset:v,tickWidth:F,tickColor:Q,tickBorderDash:G,tickBorderDashOffset:J}))}return this._ticksLength=u,this._borderValue=C,p}_computeLabelItems(t){const r=this.axis,n=this.options,{position:i,ticks:a}=n,s=this.isHorizontal(),o=this.ticks,{align:c,crossAlign:l,padding:u,mirror:d}=a,p=mg(n.grid),w=p+u,O=d?-u:w,I=-oo(this.labelRotation),R=[];let C,j,N,P,Z,X,re,ne,ae,ue,m,A,f="middle";if(i==="top")X=this.bottom-O,re=this._getXAxisLabelAlignment();else if(i==="bottom")X=this.top+O,re=this._getXAxisLabelAlignment();else if(i==="left"){const _=this._getYAxisLabelAlignment(p);re=_.textAlign,Z=_.x}else if(i==="right"){const _=this._getYAxisLabelAlignment(p);re=_.textAlign,Z=_.x}else if(r==="x"){if(i==="center")X=(t.top+t.bottom)/2+w;else if(pr(i)){const _=Object.keys(i)[0],B=i[_];X=this.chart.scales[_].getPixelForValue(B)+w}re=this._getXAxisLabelAlignment()}else if(r==="y"){if(i==="center")Z=(t.left+t.right)/2-w;else if(pr(i)){const _=Object.keys(i)[0],B=i[_];Z=this.chart.scales[_].getPixelForValue(B)}re=this._getYAxisLabelAlignment(p).textAlign}r==="y"&&(c==="start"?f="top":c==="end"&&(f="bottom"));const g=this._getLabelSizes();for(C=0,j=o.length;C<j;++C){N=o[C],P=N.label;const _=a.setContext(this.getContext(C));ne=this.getPixelForTick(C)+a.labelOffset,ae=this._resolveTickFontOptions(C),ue=ae.lineHeight,m=cn(P)?P.length:1;const B=m/2,T=_.color,S=_.textStrokeColor,h=_.textStrokeWidth;let x=re;s?(Z=ne,re==="inner"&&(C===j-1?x=this.options.reverse?"left":"right":C===0?x=this.options.reverse?"right":"left":x="center"),i==="top"?l==="near"||I!==0?A=-m*ue+ue/2:l==="center"?A=-g.highest.height/2-B*ue+ue:A=-g.highest.height+ue/2:l==="near"||I!==0?A=ue/2:l==="center"?A=g.highest.height/2-B*ue:A=g.highest.height-m*ue,d&&(A*=-1),I!==0&&!_.showLabelBackdrop&&(Z+=ue/2*Math.sin(I))):(X=ne,A=(1-m)*ue/2);let v;if(_.showLabelBackdrop){const F=Hi(_.backdropPadding),Q=g.heights[C],G=g.widths[C];let J=A-F.top,Y=0-F.left;switch(f){case"middle":J-=Q/2;break;case"bottom":J-=Q;break}switch(re){case"center":Y-=G/2;break;case"right":Y-=G;break;case"inner":C===j-1?Y-=G:C>0&&(Y-=G/2);break}v={left:Y,top:J,width:G+F.width,height:Q+F.height,color:_.backdropColor}}R.push({label:P,font:ae,textOffset:A,options:{rotation:I,color:T,strokeColor:S,strokeWidth:h,textAlign:x,textBaseline:f,translation:[Z,X],backdrop:v}})}return R}_getXAxisLabelAlignment(){const{position:t,ticks:r}=this.options;if(-oo(this.labelRotation))return t==="top"?"left":"right";let n="center";return r.align==="start"?n="left":r.align==="end"?n="right":r.align==="inner"&&(n="inner"),n}_getYAxisLabelAlignment(t){const{position:r,ticks:{crossAlign:n,mirror:i,padding:a}}=this.options,s=this._getLabelSizes(),o=t+a,c=s.widest.width;let l,u;return r==="left"?i?(u=this.right+a,n==="near"?l="left":n==="center"?(l="center",u+=c/2):(l="right",u+=c)):(u=this.right-o,n==="near"?l="right":n==="center"?(l="center",u-=c/2):(l="left",u=this.left)):r==="right"?i?(u=this.left+a,n==="near"?l="right":n==="center"?(l="center",u-=c/2):(l="left",u-=c)):(u=this.left+o,n==="near"?l="left":n==="center"?(l="center",u+=c/2):(l="right",u=this.right)):l="right",{textAlign:l,x:u}}_computeLabelArea(){if(this.options.ticks.mirror)return;const t=this.chart,r=this.options.position;if(r==="left"||r==="right")return{top:0,left:this.left,bottom:t.height,right:this.right};if(r==="top"||r==="bottom")return{top:this.top,left:0,bottom:this.bottom,right:t.width}}drawBackground(){const{ctx:t,options:{backgroundColor:r},left:n,top:i,width:a,height:s}=this;r&&(t.save(),t.fillStyle=r,t.fillRect(n,i,a,s),t.restore())}getLineWidthForValue(t){const r=this.options.grid;if(!this._isVisible()||!r.display)return 0;const n=this.ticks.findIndex(i=>i.value===t);return n>=0?r.setContext(this.getContext(n)).lineWidth:0}drawGrid(t){const r=this.options.grid,n=this.ctx,i=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let a,s;const o=(c,l,u)=>{!u.width||!u.color||(n.save(),n.lineWidth=u.width,n.strokeStyle=u.color,n.setLineDash(u.borderDash||[]),n.lineDashOffset=u.borderDashOffset,n.beginPath(),n.moveTo(c.x,c.y),n.lineTo(l.x,l.y),n.stroke(),n.restore())};if(r.display)for(a=0,s=i.length;a<s;++a){const c=i[a];r.drawOnChartArea&&o({x:c.x1,y:c.y1},{x:c.x2,y:c.y2},c),r.drawTicks&&o({x:c.tx1,y:c.ty1},{x:c.tx2,y:c.ty2},{color:c.tickColor,width:c.tickWidth,borderDash:c.tickBorderDash,borderDashOffset:c.tickBorderDashOffset})}}drawBorder(){const{chart:t,ctx:r,options:{border:n,grid:i}}=this,a=n.setContext(this.getContext()),s=n.display?a.width:0;if(!s)return;const o=i.setContext(this.getContext(0)).lineWidth,c=this._borderValue;let l,u,d,p;this.isHorizontal()?(l=Qf(t,this.left,s)-s/2,u=Qf(t,this.right,o)+o/2,d=p=c):(d=Qf(t,this.top,s)-s/2,p=Qf(t,this.bottom,o)+o/2,l=u=c),r.save(),r.lineWidth=a.width,r.strokeStyle=a.color,r.beginPath(),r.moveTo(l,d),r.lineTo(u,p),r.stroke(),r.restore()}drawLabels(t){if(!this.options.ticks.display)return;const r=this.ctx,n=this._computeLabelArea();n&&Wv(r,n);const i=this.getLabelItems(t);for(const a of i){const s=a.options,o=a.font,c=a.label,l=a.textOffset;eh(r,c,0,l,o,s)}n&&Kv(r)}drawTitle(){const{ctx:t,options:{position:r,title:n,reverse:i}}=this;if(!n.display)return;const a=ii(n.font),s=Hi(n.padding),o=n.align;let c=a.lineHeight/2;r==="bottom"||r==="center"||pr(r)?(c+=s.bottom,cn(n.text)&&(c+=a.lineHeight*(n.text.length-1))):c+=s.top;const{titleX:l,titleY:u,maxWidth:d,rotation:p}=Dte(this,c,r,o);eh(t,n.text,0,0,a,{color:n.color,maxWidth:d,rotation:p,textAlign:Lte(o,r,i),textBaseline:"middle",translation:[l,u]})}draw(t){this._isVisible()&&(this.drawBackground(),this.drawGrid(t),this.drawBorder(),this.drawTitle(),this.drawLabels(t))}_layers(){const t=this.options,r=t.ticks&&t.ticks.z||0,n=Jt(t.grid&&t.grid.z,-1),i=Jt(t.border&&t.border.z,0);return!this._isVisible()||this.draw!==oh.prototype.draw?[{z:r,draw:a=>{this.draw(a)}}]:[{z:n,draw:a=>{this.drawBackground(),this.drawGrid(a),this.drawTitle()}},{z:i,draw:()=>{this.drawBorder()}},{z:r,draw:a=>{this.drawLabels(a)}}]}getMatchingVisibleMetas(t){const r=this.chart.getSortedVisibleDatasetMetas(),n=this.axis+"AxisID",i=[];let a,s;for(a=0,s=r.length;a<s;++a){const o=r[a];o[n]===this.id&&(!t||o.type===t)&&i.push(o)}return i}_resolveTickFontOptions(t){const r=this.options.ticks.setContext(this.getContext(t));return ii(r.font)}_maxDigits(){const t=this._resolveTickFontOptions(0).lineHeight;return(this.isHorizontal()?this.width:this.height)/t}}class cw{constructor(t,r,n){this.type=t,this.scope=r,this.override=n,this.items=Object.create(null)}isForType(t){return Object.prototype.isPrototypeOf.call(this.type.prototype,t.prototype)}register(t){const r=Object.getPrototypeOf(t);let n;Vte(r)&&(n=this.register(r));const i=this.items,a=t.id,s=this.scope+"."+a;if(!a)throw new Error("class does not have id: "+t);return a in i||(i[a]=t,Ute(t,s,n),this.override&&un.override(t.id,t.overrides)),s}get(t){return this.items[t]}unregister(t){const r=this.items,n=t.id,i=this.scope;n in r&&delete r[n],i&&n in un[i]&&(delete un[i][n],this.override&&delete Jf[n])}}function Ute(e,t,r){const n=Jm(Object.create(null),[r?un.get(r):{},un.get(t),e.defaults]);un.set(t,n),e.defaultRoutes&&qte(t,e.defaultRoutes),e.descriptors&&un.describe(t,e.descriptors)}function qte(e,t){Object.keys(t).forEach(r=>{const n=r.split("."),i=n.pop(),a=[e].concat(n).join("."),s=t[r].split("."),o=s.pop(),c=s.join(".");un.route(a,i,c,o)})}function Vte(e){return"id"in e&&"defaults"in e}class Zte{constructor(){this.controllers=new cw(lo,"datasets",!0),this.elements=new cw(hc,"elements"),this.plugins=new cw(Object,"plugins"),this.scales=new cw(oh,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,r,n){[...r].forEach(i=>{const a=n||this._getRegistryForType(i);n||a.isForType(i)||a===this.plugins&&i.id?this._exec(t,a,i):Pr(i,s=>{const o=n||this._getRegistryForType(s);this._exec(t,o,s)})})}_exec(t,r,n){const i=S5(t);Wr(n["before"+i],[],n),r[t](n),Wr(n["after"+i],[],n)}_getRegistryForType(t){for(let r=0;r<this._typedRegistries.length;r++){const n=this._typedRegistries[r];if(n.isForType(t))return n}return this.plugins}_get(t,r,n){const i=r.get(t);if(i===void 0)throw new Error('"'+t+'" is not a registered '+n+".");return i}}var nl=new Zte;class $te{constructor(){this._init=[]}notify(t,r,n,i){r==="beforeInit"&&(this._init=this._createDescriptors(t,!0),this._notify(this._init,t,"install"));const a=i?this._descriptors(t).filter(i):this._descriptors(t),s=this._notify(a,t,r,n);return r==="afterDestroy"&&(this._notify(a,t,"stop"),this._notify(this._init,t,"uninstall")),s}_notify(t,r,n,i){i=i||{};for(const a of t){const s=a.plugin,o=s[n],c=[r,i,a.options];if(Wr(o,c,s)===!1&&i.cancelable)return!1}return!0}invalidate(){hr(this._cache)||(this._oldCache=this._cache,this._cache=void 0)}_descriptors(t){if(this._cache)return this._cache;const r=this._cache=this._createDescriptors(t);return this._notifyStateChanges(t),r}_createDescriptors(t,r){const n=t&&t.config,i=Jt(n.options&&n.options.plugins,{}),a=Hte(n);return i===!1&&!r?[]:Kte(t,a,i,r)}_notifyStateChanges(t){const r=this._oldCache||[],n=this._cache,i=(a,s)=>a.filter(o=>!s.some(c=>o.plugin.id===c.plugin.id));this._notify(i(r,n),t,"stop"),this._notify(i(n,r),t,"start")}}function Hte(e){const t={},r=[],n=Object.keys(nl.plugins.items);for(let a=0;a<n.length;a++)r.push(nl.getPlugin(n[a]));const i=e.plugins||[];for(let a=0;a<i.length;a++){const s=i[a];r.indexOf(s)===-1&&(r.push(s),t[s.id]=!0)}return{plugins:r,localIds:t}}function Wte(e,t){return!t&&e===!1?null:e===!0?{}:e}function Kte(e,{plugins:t,localIds:r},n,i){const a=[],s=e.getContext();for(const o of t){const c=o.id,l=Wte(n[c],i);l!==null&&a.push({plugin:o,options:Gte(e.config,{plugin:o,local:r[c]},l,s)})}return a}function Gte(e,{plugin:t,local:r},n,i){const a=e.pluginScopeKeys(t),s=e.getOptionScopes(n,a);return r&&t.defaults&&s.push(t.defaults),e.createResolver(s,i,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function K5(e,t){const r=un.datasets[e]||{};return((t.datasets||{})[e]||{}).indexAxis||t.indexAxis||r.indexAxis||"x"}function Yte(e,t){let r=e;return e==="_index_"?r=t:e==="_value_"&&(r=t==="x"?"y":"x"),r}function Xte(e,t){return e===t?"_index_":"_value_"}function jI(e){if(e==="x"||e==="y"||e==="r")return e}function Jte(e){if(e==="top"||e==="bottom")return"x";if(e==="left"||e==="right")return"y"}function G5(e,...t){if(jI(e))return e;for(const r of t){const n=r.axis||Jte(r.position)||e.length>1&&jI(e[0].toLowerCase());if(n)return n}throw new Error(`Cannot determine type of '${e}' axis. Please provide 'axis' or 'position' option.`)}function II(e,t,r){if(r[t+"AxisID"]===e)return{axis:t}}function Qte(e,t){if(t.data&&t.data.datasets){const r=t.data.datasets.filter(n=>n.xAxisID===e||n.yAxisID===e);if(r.length)return II(e,"x",r[0])||II(e,"y",r[0])}return{}}function ere(e,t){const r=Jf[e.type]||{scales:{}},n=t.scales||{},i=K5(e.type,t),a=Object.create(null);return Object.keys(n).forEach(s=>{const o=n[s];if(!pr(o))return console.error(`Invalid scale configuration for scale: ${s}`);if(o._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${s}`);const c=G5(s,o,Qte(s,e),un.scales[o.type]),l=Xte(c,i),u=r.scales||{};a[s]=Qm(Object.create(null),[{axis:c},o,u[c],u[l]])}),e.data.datasets.forEach(s=>{const o=s.type||e.type,c=s.indexAxis||K5(o,t),l=(Jf[o]||{}).scales||{};Object.keys(l).forEach(u=>{const d=Yte(u,c),p=s[d+"AxisID"]||d;a[p]=a[p]||Object.create(null),Qm(a[p],[{axis:d},n[p],l[u]])})}),Object.keys(a).forEach(s=>{const o=a[s];Qm(o,[un.scales[o.type],un.scale])}),a}function OI(e){const t=e.options||(e.options={});t.plugins=Jt(t.plugins,{}),t.scales=ere(e,t)}function BI(e){return e=e||{},e.datasets=e.datasets||[],e.labels=e.labels||[],e}function tre(e){return e=e||{},e.data=BI(e.data),OI(e),e}const RI=new Map,NI=new Set;function uw(e,t){let r=RI.get(e);return r||(r=t(),RI.set(e,r),NI.add(r)),r}const gg=(e,t,r)=>{const n=Eu(t,r);n!==void 0&&e.add(n)};let rre=class{constructor(e){this._config=tre(e),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(e){this._config.type=e}get data(){return this._config.data}set data(e){this._config.data=BI(e)}get options(){return this._config.options}set options(e){this._config.options=e}get plugins(){return this._config.plugins}update(){const e=this._config;this.clearCache(),OI(e)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(e){return uw(e,()=>[[`datasets.${e}`,""]])}datasetAnimationScopeKeys(e,t){return uw(`${e}.transition.${t}`,()=>[[`datasets.${e}.transitions.${t}`,`transitions.${t}`],[`datasets.${e}`,""]])}datasetElementScopeKeys(e,t){return uw(`${e}-${t}`,()=>[[`datasets.${e}.elements.${t}`,`datasets.${e}`,`elements.${t}`,""]])}pluginScopeKeys(e){const t=e.id,r=this.type;return uw(`${r}-plugin-${t}`,()=>[[`plugins.${t}`,...e.additionalOptionScopes||[]]])}_cachedScopes(e,t){const r=this._scopeCache;let n=r.get(e);return(!n||t)&&(n=new Map,r.set(e,n)),n}getOptionScopes(e,t,r){const{options:n,type:i}=this,a=this._cachedScopes(e,r),s=a.get(t);if(s)return s;const o=new Set;t.forEach(l=>{e&&(o.add(e),l.forEach(u=>gg(o,e,u))),l.forEach(u=>gg(o,n,u)),l.forEach(u=>gg(o,Jf[i]||{},u)),l.forEach(u=>gg(o,un,u)),l.forEach(u=>gg(o,j5,u))});const c=Array.from(o);return c.length===0&&c.push(Object.create(null)),NI.has(t)&&a.set(t,c),c}chartOptionScopes(){const{options:e,type:t}=this;return[e,Jf[t]||{},un.datasets[t]||{},{type:t},un,j5]}resolveNamedOptions(e,t,r,n=[""]){const i={$shared:!0},{resolver:a,subPrefixes:s}=FI(this._resolverCache,e,n);let o=a;if(ire(a,t)){i.$shared=!1,r=Mu(r)?r():r;const c=this.createResolver(e,r,s);o=l0(a,r,c)}for(const c of t)i[c]=o[c];return i}createResolver(e,t,r=[""],n){const{resolver:i}=FI(this._resolverCache,e,r);return pr(t)?l0(i,t,void 0,n):i}};function FI(e,t,r){let n=e.get(t);n||(n=new Map,e.set(t,n));const i=r.join();let a=n.get(i);return a||(a={resolver:R5(t,r),subPrefixes:r.filter(s=>!s.toLowerCase().includes("hover"))},n.set(i,a)),a}const nre=e=>pr(e)&&Object.getOwnPropertyNames(e).some(t=>Mu(e[t]));function ire(e,t){const{isScriptable:r,isIndexable:n}=zj(e);for(const i of t){const a=r(i),s=n(i),o=(s||a)&&e[i];if(a&&(Mu(o)||nre(o))||s&&cn(o))return!0}return!1}var are="4.4.9";const sre=["top","bottom","left","right","chartArea"];function PI(e,t){return e==="top"||e==="bottom"||sre.indexOf(e)===-1&&t==="x"}function zI(e,t){return function(r,n){return r[e]===n[e]?r[t]-n[t]:r[e]-n[e]}}function LI(e){const t=e.chart,r=t.options.animation;t.notifyPlugins("afterRender"),Wr(r&&r.onComplete,[e],t)}function ore(e){const t=e.chart,r=t.options.animation;Wr(r&&r.onProgress,[e],t)}function DI(e){return P5()&&typeof e=="string"?e=document.getElementById(e):e&&e.length&&(e=e[0]),e&&e.canvas&&(e=e.canvas),e}const fw={},UI=e=>{const t=DI(e);return Object.values(fw).filter(r=>r.canvas===t).pop()};function lre(e,t,r){const n=Object.keys(e);for(const i of n){const a=+i;if(a>=t){const s=e[i];delete e[i],(r>0||a>t)&&(e[a+r]=s)}}}function cre(e,t,r,n){return!r||e.type==="mouseout"?null:n?t:e}class dc{static register(...t){nl.add(...t),qI()}static unregister(...t){nl.remove(...t),qI()}constructor(t,r){const n=this.config=new rre(r),i=DI(t),a=UI(i);if(a)throw new Error("Canvas is already in use. Chart with ID '"+a.id+"' must be destroyed before the canvas with ID '"+a.canvas.id+"' can be reused.");const s=n.createResolver(n.chartOptionScopes(),this.getContext());this.platform=new(n.platform||Ate(i)),this.platform.updateConfig(n);const o=this.platform.acquireContext(i,s.aspectRatio),c=o&&o.canvas,l=c&&c.height,u=c&&c.width;if(this.id=uQ(),this.ctx=o,this.canvas=c,this.width=u,this.height=l,this._options=s,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new $te,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=AQ(d=>this.update(d),s.resizeDelay||0),this._dataChanges=[],fw[this.id]=this,!o||!c){console.error("Failed to create chart: can't acquire context from the given item");return}fc.listen(this,"complete",LI),fc.listen(this,"progress",ore),this._initialize(),this.attached&&this.update()}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:r},width:n,height:i,_aspectRatio:a}=this;return hr(t)?r&&a?a:i?n/i:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}get registry(){return nl}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():Hj(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return Nj(this.canvas,this.ctx),this}stop(){return fc.stop(this),this}resize(t,r){fc.running(this)?this._resizeBeforeDraw={width:t,height:r}:this._resize(t,r)}_resize(t,r){const n=this.options,i=this.canvas,a=n.maintainAspectRatio&&this.aspectRatio,s=this.platform.getMaximumSize(i,t,r,a),o=n.devicePixelRatio||this.platform.getDevicePixelRatio(),c=this.width?"resize":"attach";this.width=s.width,this.height=s.height,this._aspectRatio=this.aspectRatio,Hj(this,o,!0)&&(this.notifyPlugins("resize",{size:s}),Wr(n.onResize,[this,s],this),this.attached&&this._doResize(c)&&this.render())}ensureScalesHaveIDs(){const t=this.options.scales||{};Pr(t,(r,n)=>{r.id=n})}buildOrUpdateScales(){const t=this.options,r=t.scales,n=this.scales,i=Object.keys(n).reduce((s,o)=>(s[o]=!1,s),{});let a=[];r&&(a=a.concat(Object.keys(r).map(s=>{const o=r[s],c=G5(s,o),l=c==="r",u=c==="x";return{options:o,dposition:l?"chartArea":u?"bottom":"left",dtype:l?"radialLinear":u?"category":"linear"}}))),Pr(a,s=>{const o=s.options,c=o.id,l=G5(c,o),u=Jt(o.type,s.dtype);(o.position===void 0||PI(o.position,l)!==PI(s.dposition))&&(o.position=s.dposition),i[c]=!0;let d=null;if(c in n&&n[c].type===u)d=n[c];else{const p=nl.getScale(u);d=new p({id:c,type:u,ctx:this.ctx,chart:this}),n[d.id]=d}d.init(o,t)}),Pr(i,(s,o)=>{s||delete n[o]}),Pr(n,s=>{Wi.configure(this,s,s.options),Wi.addBox(this,s)})}_updateMetasets(){const t=this._metasets,r=this.data.datasets.length,n=t.length;if(t.sort((i,a)=>i.index-a.index),n>r){for(let i=r;i<n;++i)this._destroyDatasetMeta(i);t.splice(r,n-r)}this._sortedMetasets=t.slice(0).sort(zI("order","index"))}_removeUnreferencedMetasets(){const{_metasets:t,data:{datasets:r}}=this;t.length>r.length&&delete this._stacks,t.forEach((n,i)=>{r.filter(a=>a===n._dataset).length===0&&this._destroyDatasetMeta(i)})}buildOrUpdateControllers(){const t=[],r=this.data.datasets;let n,i;for(this._removeUnreferencedMetasets(),n=0,i=r.length;n<i;n++){const a=r[n];let s=this.getDatasetMeta(n);const o=a.type||this.config.type;if(s.type&&s.type!==o&&(this._destroyDatasetMeta(n),s=this.getDatasetMeta(n)),s.type=o,s.indexAxis=a.indexAxis||K5(o,this.options),s.order=a.order||0,s.index=n,s.label=""+a.label,s.visible=this.isDatasetVisible(n),s.controller)s.controller.updateIndex(n),s.controller.linkScales();else{const c=nl.getController(o),{datasetElementType:l,dataElementType:u}=un.datasets[o];Object.assign(c,{dataElementType:nl.getElement(u),datasetElementType:l&&nl.getElement(l)}),s.controller=new c(this,n),t.push(s.controller)}}return this._updateMetasets(),t}_resetElements(){Pr(this.data.datasets,(t,r)=>{this.getDatasetMeta(r).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const r=this.config;r.update();const n=this._options=r.createResolver(r.chartOptionScopes(),this.getContext()),i=this._animationsDisabled=!n.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0})===!1)return;const a=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let s=0;for(let l=0,u=this.data.datasets.length;l<u;l++){const{controller:d}=this.getDatasetMeta(l),p=!i&&a.indexOf(d)===-1;d.buildOrUpdateElements(p),s=Math.max(+d.getMaxOverflow(),s)}s=this._minPadding=n.layout.autoPadding?s:0,this._updateLayout(s),i||Pr(a,l=>{l.reset()}),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(zI("z","_idx"));const{_active:o,_lastEvent:c}=this;c?this._eventHandler(c,!0):o.length&&this._updateHoverStyles(o,o,!0),this.render()}_updateScales(){Pr(this.scales,t=>{Wi.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,r=new Set(Object.keys(this._listeners)),n=new Set(t.events);(!bj(r,n)||!!this._responsiveListeners!==t.responsive)&&(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:t}=this,r=this._getUniformDataChanges()||[];for(const{method:n,start:i,count:a}of r){const s=n==="_removeElements"?-a:a;lre(t,i,s)}}_getUniformDataChanges(){const t=this._dataChanges;if(!t||!t.length)return;this._dataChanges=[];const r=this.data.datasets.length,n=a=>new Set(t.filter(s=>s[0]===a).map((s,o)=>o+","+s.splice(1).join(","))),i=n(0);for(let a=1;a<r;a++)if(!bj(i,n(a)))return;return Array.from(i).map(a=>a.split(",")).map(a=>({method:a[1],start:+a[2],count:+a[3]}))}_updateLayout(t){if(this.notifyPlugins("beforeLayout",{cancelable:!0})===!1)return;Wi.update(this,this.width,this.height,t);const r=this.chartArea,n=r.width<=0||r.height<=0;this._layers=[],Pr(this.boxes,i=>{n&&i.position==="chartArea"||(i.configure&&i.configure(),this._layers.push(...i._layers()))},this),this._layers.forEach((i,a)=>{i._idx=a}),this.notifyPlugins("afterLayout")}_updateDatasets(t){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})!==!1){for(let r=0,n=this.data.datasets.length;r<n;++r)this.getDatasetMeta(r).controller.configure();for(let r=0,n=this.data.datasets.length;r<n;++r)this._updateDataset(r,Mu(t)?t({datasetIndex:r}):t);this.notifyPlugins("afterDatasetsUpdate",{mode:t})}}_updateDataset(t,r){const n=this.getDatasetMeta(t),i={meta:n,index:t,mode:r,cancelable:!0};this.notifyPlugins("beforeDatasetUpdate",i)!==!1&&(n.controller._update(r),i.cancelable=!1,this.notifyPlugins("afterDatasetUpdate",i))}render(){this.notifyPlugins("beforeRender",{cancelable:!0})!==!1&&(fc.has(this)?this.attached&&!fc.running(this)&&fc.start(this):(this.draw(),LI({chart:this})))}draw(){let t;if(this._resizeBeforeDraw){const{width:n,height:i}=this._resizeBeforeDraw;this._resizeBeforeDraw=null,this._resize(n,i)}if(this.clear(),this.width<=0||this.height<=0||this.notifyPlugins("beforeDraw",{cancelable:!0})===!1)return;const r=this._layers;for(t=0;t<r.length&&r[t].z<=0;++t)r[t].draw(this.chartArea);for(this._drawDatasets();t<r.length;++t)r[t].draw(this.chartArea);this.notifyPlugins("afterDraw")}_getSortedDatasetMetas(t){const r=this._sortedMetasets,n=[];let i,a;for(i=0,a=r.length;i<a;++i){const s=r[i];(!t||s.visible)&&n.push(s)}return n}getSortedVisibleDatasetMetas(){return this._getSortedDatasetMetas(!0)}_drawDatasets(){if(this.notifyPlugins("beforeDatasetsDraw",{cancelable:!0})===!1)return;const t=this.getSortedVisibleDatasetMetas();for(let r=t.length-1;r>=0;--r)this._drawDataset(t[r]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const r=this.ctx,n={meta:t,index:t.index,cancelable:!0},i=rI(this,t);this.notifyPlugins("beforeDatasetDraw",n)!==!1&&(i&&Wv(r,i),t.controller.draw(),i&&Kv(r),n.cancelable=!1,this.notifyPlugins("afterDatasetDraw",n))}isPointInArea(t){return uc(t,this.chartArea,this._minPadding)}getElementsAtEventForMode(t,r,n,i){const a=ste.modes[r];return typeof a=="function"?a(this,t,n,i):[]}getDatasetMeta(t){const r=this.data.datasets[t],n=this._metasets;let i=n.filter(a=>a&&a._dataset===r).pop();return i||(i={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:r&&r.order||0,index:t,_dataset:r,_parsed:[],_sorted:!1},n.push(i)),i}getContext(){return this.$context||(this.$context=Cu(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const r=this.data.datasets[t];if(!r)return!1;const n=this.getDatasetMeta(t);return typeof n.hidden=="boolean"?!n.hidden:!r.hidden}setDatasetVisibility(t,r){const n=this.getDatasetMeta(t);n.hidden=!r}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,r,n){const i=n?"show":"hide",a=this.getDatasetMeta(t),s=a.controller._resolveAnimations(void 0,i);eg(r)?(a.data[r].hidden=!n,this.update()):(this.setDatasetVisibility(t,n),s.update(a,{visible:n}),this.update(o=>o.datasetIndex===t?i:void 0))}hide(t,r){this._updateVisibility(t,r,!1)}show(t,r){this._updateVisibility(t,r,!0)}_destroyDatasetMeta(t){const r=this._metasets[t];r&&r.controller&&r.controller._destroy(),delete this._metasets[t]}_stop(){let t,r;for(this.stop(),fc.remove(this),t=0,r=this.data.datasets.length;t<r;++t)this._destroyDatasetMeta(t)}destroy(){this.notifyPlugins("beforeDestroy");const{canvas:t,ctx:r}=this;this._stop(),this.config.clearCache(),t&&(this.unbindEvents(),Nj(t,r),this.platform.releaseContext(r),this.canvas=null,this.ctx=null),delete fw[this.id],this.notifyPlugins("afterDestroy")}toBase64Image(...t){return this.canvas.toDataURL(...t)}bindEvents(){this.bindUserEvents(),this.options.responsive?this.bindResponsiveEvents():this.attached=!0}bindUserEvents(){const t=this._listeners,r=this.platform,n=(a,s)=>{r.addEventListener(this,a,s),t[a]=s},i=(a,s,o)=>{a.offsetX=s,a.offsetY=o,this._eventHandler(a)};Pr(this.options.events,a=>n(a,i))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,r=this.platform,n=(c,l)=>{r.addEventListener(this,c,l),t[c]=l},i=(c,l)=>{t[c]&&(r.removeEventListener(this,c,l),delete t[c])},a=(c,l)=>{this.canvas&&this.resize(c,l)};let s;const o=()=>{i("attach",o),this.attached=!0,this.resize(),n("resize",a),n("detach",s)};s=()=>{this.attached=!1,i("resize",a),this._stop(),this._resize(0,0),n("attach",o)},r.isAttached(this.canvas)?o():s()}unbindEvents(){Pr(this._listeners,(t,r)=>{this.platform.removeEventListener(this,r,t)}),this._listeners={},Pr(this._responsiveListeners,(t,r)=>{this.platform.removeEventListener(this,r,t)}),this._responsiveListeners=void 0}updateHoverStyle(t,r,n){const i=n?"set":"remove";let a,s,o,c;for(r==="dataset"&&(a=this.getDatasetMeta(t[0].datasetIndex),a.controller["_"+i+"DatasetHoverStyle"]()),o=0,c=t.length;o<c;++o){s=t[o];const l=s&&this.getDatasetMeta(s.datasetIndex).controller;l&&l[i+"HoverStyle"](s.element,s.datasetIndex,s.index)}}getActiveElements(){return this._active||[]}setActiveElements(t){const r=this._active||[],n=t.map(({datasetIndex:i,index:a})=>{const s=this.getDatasetMeta(i);if(!s)throw new Error("No dataset found at index "+i);return{datasetIndex:i,element:s.data[a],index:a}});!Uv(n,r)&&(this._active=n,this._lastEvent=null,this._updateHoverStyles(n,r))}notifyPlugins(t,r,n){return this._plugins.notify(this,t,r,n)}isPluginEnabled(t){return this._plugins._cache.filter(r=>r.plugin.id===t).length===1}_updateHoverStyles(t,r,n){const i=this.options.hover,a=(c,l)=>c.filter(u=>!l.some(d=>u.datasetIndex===d.datasetIndex&&u.index===d.index)),s=a(r,t),o=n?t:a(t,r);s.length&&this.updateHoverStyle(s,i.mode,!1),o.length&&i.mode&&this.updateHoverStyle(o,i.mode,!0)}_eventHandler(t,r){const n={event:t,replay:r,cancelable:!0,inChartArea:this.isPointInArea(t)},i=s=>(s.options.events||this.options.events).includes(t.native.type);if(this.notifyPlugins("beforeEvent",n,i)===!1)return;const a=this._handleEvent(t,r,n.inChartArea);return n.cancelable=!1,this.notifyPlugins("afterEvent",n,i),(a||n.changed)&&this.render(),this}_handleEvent(t,r,n){const{_active:i=[],options:a}=this,s=r,o=this._getActiveElements(t,i,n,s),c=gQ(t),l=cre(t,this._lastEvent,n,c);n&&(this._lastEvent=null,Wr(a.onHover,[t,o,this],this),c&&Wr(a.onClick,[t,o,this],this));const u=!Uv(o,i);return(u||r)&&(this._active=o,this._updateHoverStyles(o,i,r)),this._lastEvent=l,u}_getActiveElements(t,r,n,i){if(t.type==="mouseout")return[];if(!n)return r;const a=this.options.hover;return this.getElementsAtEventForMode(t,a.mode,a,i)}}te(dc,"defaults",un),te(dc,"instances",fw),te(dc,"overrides",Jf),te(dc,"registry",nl),te(dc,"version",are),te(dc,"getChart",UI);function qI(){return Pr(dc.instances,e=>e._plugins.invalidate())}function ure(e,t,r){const{startAngle:n,pixelMargin:i,x:a,y:s,outerRadius:o,innerRadius:c}=t;let l=i/o;e.beginPath(),e.arc(a,s,o,n-l,r+l),c>i?(l=i/c,e.arc(a,s,c,r+l,n-l,!0)):e.arc(a,s,i,r+Bn,n-Bn),e.closePath(),e.clip()}function fre(e){return B5(e,["outerStart","outerEnd","innerStart","innerEnd"])}function hre(e,t,r,n){const i=fre(e.options.borderRadius),a=(r-t)/2,s=Math.min(a,n*t/2),o=c=>{const l=(r-Math.min(a,c))*n/2;return mi(c,0,Math.min(a,l))};return{outerStart:o(i.outerStart),outerEnd:o(i.outerEnd),innerStart:mi(i.innerStart,0,s),innerEnd:mi(i.innerEnd,0,s)}}function f0(e,t,r,n){return{x:r+e*Math.cos(t),y:n+e*Math.sin(t)}}function hw(e,t,r,n,i,a){const{x:s,y:o,startAngle:c,pixelMargin:l,innerRadius:u}=t,d=Math.max(t.outerRadius+n+r-l,0),p=u>0?u+n+r+l:0;let w=0;const O=i-c;if(n){const _=u>0?u-n:0,B=d>0?d-n:0,T=(_+B)/2,S=T!==0?O*T/(T+n):O;w=(O-S)/2}const I=Math.max(.001,O*d-r/rn)/d,R=(O-I)/2,C=c+R+w,j=i-R-w,{outerStart:N,outerEnd:P,innerStart:Z,innerEnd:X}=hre(t,p,d,j-C),re=d-N,ne=d-P,ae=C+N/re,ue=j-P/ne,m=p+Z,A=p+X,f=C+Z/m,g=j-X/A;if(e.beginPath(),a){const _=(ae+ue)/2;if(e.arc(s,o,d,ae,_),e.arc(s,o,d,_,ue),P>0){const h=f0(ne,ue,s,o);e.arc(h.x,h.y,P,ue,j+Bn)}const B=f0(A,j,s,o);if(e.lineTo(B.x,B.y),X>0){const h=f0(A,g,s,o);e.arc(h.x,h.y,X,j+Bn,g+Math.PI)}const T=(j-X/p+(C+Z/p))/2;if(e.arc(s,o,p,j-X/p,T,!0),e.arc(s,o,p,T,C+Z/p,!0),Z>0){const h=f0(m,f,s,o);e.arc(h.x,h.y,Z,f+Math.PI,C-Bn)}const S=f0(re,C,s,o);if(e.lineTo(S.x,S.y),N>0){const h=f0(re,ae,s,o);e.arc(h.x,h.y,N,C-Bn,ae)}}else{e.moveTo(s,o);const _=Math.cos(ae)*d+s,B=Math.sin(ae)*d+o;e.lineTo(_,B);const T=Math.cos(ue)*d+s,S=Math.sin(ue)*d+o;e.lineTo(T,S)}e.closePath()}function dre(e,t,r,n,i){const{fullCircles:a,startAngle:s,circumference:o}=t;let c=t.endAngle;if(a){hw(e,t,r,n,c,i);for(let l=0;l<a;++l)e.fill();isNaN(o)||(c=s+(o%nn||nn))}return hw(e,t,r,n,c,i),e.fill(),c}function pre(e,t,r,n,i){const{fullCircles:a,startAngle:s,circumference:o,options:c}=t,{borderWidth:l,borderJoinStyle:u,borderDash:d,borderDashOffset:p}=c,w=c.borderAlign==="inner";if(!l)return;e.setLineDash(d||[]),e.lineDashOffset=p,w?(e.lineWidth=l*2,e.lineJoin=u||"round"):(e.lineWidth=l,e.lineJoin=u||"bevel");let O=t.endAngle;if(a){hw(e,t,r,n,O,i);for(let I=0;I<a;++I)e.stroke();isNaN(o)||(O=s+(o%nn||nn))}w&&ure(e,t,O),a||(hw(e,t,r,n,O,i),e.stroke())}class bg extends hc{constructor(r){super();te(this,"circumference");te(this,"endAngle");te(this,"fullCircles");te(this,"innerRadius");te(this,"outerRadius");te(this,"pixelMargin");te(this,"startAngle");this.options=void 0,this.circumference=void 0,this.startAngle=void 0,this.endAngle=void 0,this.innerRadius=void 0,this.outerRadius=void 0,this.pixelMargin=0,this.fullCircles=0,r&&Object.assign(this,r)}inRange(r,n,i){const a=this.getProps(["x","y"],i),{angle:s,distance:o}=_j(a,{x:r,y:n}),{startAngle:c,endAngle:l,innerRadius:u,outerRadius:d,circumference:p}=this.getProps(["startAngle","endAngle","innerRadius","outerRadius","circumference"],i),w=(this.options.spacing+this.options.borderWidth)/2,O=Jt(p,l-c),I=rg(s,c,l)&&c!==l,R=O>=nn||I,C=lc(o,u+w,d+w);return R&&C}getCenterPoint(r){const{x:n,y:i,startAngle:a,endAngle:s,innerRadius:o,outerRadius:c}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius"],r),{offset:l,spacing:u}=this.options,d=(a+s)/2,p=(o+c+u+l)/2;return{x:n+Math.cos(d)*p,y:i+Math.sin(d)*p}}tooltipPosition(r){return this.getCenterPoint(r)}draw(r){const{options:n,circumference:i}=this,a=(n.offset||0)/4,s=(n.spacing||0)/2,o=n.circular;if(this.pixelMargin=n.borderAlign==="inner"?.33:0,this.fullCircles=i>nn?Math.floor(i/nn):0,i===0||this.innerRadius<0||this.outerRadius<0)return;r.save();const c=(this.startAngle+this.endAngle)/2;r.translate(Math.cos(c)*a,Math.sin(c)*a);const l=1-Math.sin(Math.min(rn,i||0)),u=a*l;r.fillStyle=n.backgroundColor,r.strokeStyle=n.borderColor,dre(r,this,u,s,o),pre(r,this,u,s,o),r.restore()}}te(bg,"id","arc"),te(bg,"defaults",{borderAlign:"center",borderColor:"#fff",borderDash:[],borderDashOffset:0,borderJoinStyle:void 0,borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0,circular:!0}),te(bg,"defaultRoutes",{backgroundColor:"backgroundColor"}),te(bg,"descriptors",{_scriptable:!0,_indexable:r=>r!=="borderDash"});function VI(e,t,r=t){e.lineCap=Jt(r.borderCapStyle,t.borderCapStyle),e.setLineDash(Jt(r.borderDash,t.borderDash)),e.lineDashOffset=Jt(r.borderDashOffset,t.borderDashOffset),e.lineJoin=Jt(r.borderJoinStyle,t.borderJoinStyle),e.lineWidth=Jt(r.borderWidth,t.borderWidth),e.strokeStyle=Jt(r.borderColor,t.borderColor)}function mre(e,t,r){e.lineTo(r.x,r.y)}function gre(e){return e.stepped?LQ:e.tension||e.cubicInterpolationMode==="monotone"?DQ:mre}function ZI(e,t,r={}){const n=e.length,{start:i=0,end:a=n-1}=r,{start:s,end:o}=t,c=Math.max(i,s),l=Math.min(a,o),u=i<s&&a<s||i>o&&a>o;return{count:n,start:c,loop:t.loop,ilen:l<c&&!u?n+l-c:l-c}}function bre(e,t,r,n){const{points:i,options:a}=t,{count:s,start:o,loop:c,ilen:l}=ZI(i,r,n),u=gre(a);let{move:d=!0,reverse:p}=n||{},w,O,I;for(w=0;w<=l;++w)O=i[(o+(p?l-w:w))%s],!O.skip&&(d?(e.moveTo(O.x,O.y),d=!1):u(e,I,O,p,a.stepped),I=O);return c&&(O=i[(o+(p?l:0))%s],u(e,I,O,p,a.stepped)),!!c}function yre(e,t,r,n){const i=t.points,{count:a,start:s,ilen:o}=ZI(i,r,n),{move:c=!0,reverse:l}=n||{};let u=0,d=0,p,w,O,I,R,C;const j=P=>(s+(l?o-P:P))%a,N=()=>{I!==R&&(e.lineTo(u,R),e.lineTo(u,I),e.lineTo(u,C))};for(c&&(w=i[j(0)],e.moveTo(w.x,w.y)),p=0;p<=o;++p){if(w=i[j(p)],w.skip)continue;const P=w.x,Z=w.y,X=P|0;X===O?(Z<I?I=Z:Z>R&&(R=Z),u=(d*u+P)/++d):(N(),e.lineTo(P,Z),O=X,d=0,I=R=Z),C=Z}N()}function Y5(e){const t=e.options,r=t.borderDash&&t.borderDash.length;return!e._decimated&&!e._loop&&!t.tension&&t.cubicInterpolationMode!=="monotone"&&!t.stepped&&!r?yre:bre}function vre(e){return e.stepped?yee:e.tension||e.cubicInterpolationMode==="monotone"?vee:ih}function wre(e,t,r,n){let i=t._path;i||(i=t._path=new Path2D,t.path(i,r,n)&&i.closePath()),VI(e,t.options),e.stroke(i)}function xre(e,t,r,n){const{segments:i,options:a}=t,s=Y5(t);for(const o of i)VI(e,a,o.style),e.beginPath(),s(e,t,o,{start:r,end:r+n-1})&&e.closePath(),e.stroke()}const _re=typeof Path2D=="function";function Sre(e,t,r,n){_re&&!t.options.segment?wre(e,t,r,n):xre(e,t,r,n)}class Tu extends hc{constructor(t){super(),this.animated=!0,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=!1,this._pointsUpdated=!1,this._datasetIndex=void 0,t&&Object.assign(this,t)}updateControlPoints(t,r){const n=this.options;if((n.tension||n.cubicInterpolationMode==="monotone")&&!n.stepped&&!this._pointsUpdated){const i=n.spanGaps?this._loop:this._fullLoop;uee(this._points,n,t,i,r),this._pointsUpdated=!0}}set points(t){this._points=t,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=Eee(this,this.options.segment))}first(){const t=this.segments,r=this.points;return t.length&&r[t[0].start]}last(){const t=this.segments,r=this.points,n=t.length;return n&&r[t[n-1].end]}interpolate(t,r){const n=this.options,i=t[r],a=this.points,s=Qj(this,{property:r,start:i,end:i});if(!s.length)return;const o=[],c=vre(n);let l,u;for(l=0,u=s.length;l<u;++l){const{start:d,end:p}=s[l],w=a[d],O=a[p];if(w===O){o.push(w);continue}const I=Math.abs((i-w[r])/(O[r]-w[r])),R=c(w,O,I,n.stepped);R[r]=t[r],o.push(R)}return o.length===1?o[0]:o}pathSegment(t,r,n){return Y5(this)(t,this,r,n)}path(t,r,n){const i=this.segments,a=Y5(this);let s=this._loop;r=r||0,n=n||this.points.length-r;for(const o of i)s&=a(t,this,o,{start:r,end:r+n-1});return!!s}draw(t,r,n,i){const a=this.options||{};(this.points||[]).length&&a.borderWidth&&(t.save(),Sre(t,this,n,i),t.restore()),this.animated&&(this._pointsUpdated=!1,this._path=void 0)}}te(Tu,"id","line"),te(Tu,"defaults",{borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:3,capBezierPoints:!0,cubicInterpolationMode:"default",fill:!1,spanGaps:!1,stepped:!1,tension:0}),te(Tu,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"}),te(Tu,"descriptors",{_scriptable:!0,_indexable:t=>t!=="borderDash"&&t!=="fill"});function $I(e,t,r,n){const i=e.options,{[r]:a}=e.getProps([r],n);return Math.abs(t-a)<i.radius+i.hitRadius}class dw extends hc{constructor(r){super();te(this,"parsed");te(this,"skip");te(this,"stop");this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,r&&Object.assign(this,r)}inRange(r,n,i){const a=this.options,{x:s,y:o}=this.getProps(["x","y"],i);return Math.pow(r-s,2)+Math.pow(n-o,2)<Math.pow(a.hitRadius+a.radius,2)}inXRange(r,n){return $I(this,r,"x",n)}inYRange(r,n){return $I(this,r,"y",n)}getCenterPoint(r){const{x:n,y:i}=this.getProps(["x","y"],r);return{x:n,y:i}}size(r){r=r||this.options||{};let n=r.radius||0;n=Math.max(n,n&&r.hoverRadius||0);const i=n&&r.borderWidth||0;return(n+i)*2}draw(r,n){const i=this.options;this.skip||i.radius<.1||!uc(this,n,this.size(i)/2)||(r.strokeStyle=i.borderColor,r.lineWidth=i.borderWidth,r.fillStyle=i.backgroundColor,O5(r,i,this.x,this.y))}getRange(){const r=this.options||{};return r.radius+r.hitRadius}}te(dw,"id","point"),te(dw,"defaults",{borderWidth:1,hitRadius:1,hoverBorderWidth:1,hoverRadius:4,pointStyle:"circle",radius:3,rotation:0}),te(dw,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"});function HI(e,t){const{x:r,y:n,base:i,width:a,height:s}=e.getProps(["x","y","base","width","height"],t);let o,c,l,u,d;return e.horizontal?(d=s/2,o=Math.min(r,i),c=Math.max(r,i),l=n-d,u=n+d):(d=a/2,o=r-d,c=r+d,l=Math.min(n,i),u=Math.max(n,i)),{left:o,top:l,right:c,bottom:u}}function ju(e,t,r,n){return e?0:mi(t,r,n)}function kre(e,t,r){const n=e.options.borderWidth,i=e.borderSkipped,a=Pj(n);return{t:ju(i.top,a.top,0,r),r:ju(i.right,a.right,0,t),b:ju(i.bottom,a.bottom,0,r),l:ju(i.left,a.left,0,t)}}function Ere(e,t,r){const{enableBorderRadius:n}=e.getProps(["enableBorderRadius"]),i=e.options.borderRadius,a=th(i),s=Math.min(t,r),o=e.borderSkipped,c=n||pr(i);return{topLeft:ju(!c||o.top||o.left,a.topLeft,0,s),topRight:ju(!c||o.top||o.right,a.topRight,0,s),bottomLeft:ju(!c||o.bottom||o.left,a.bottomLeft,0,s),bottomRight:ju(!c||o.bottom||o.right,a.bottomRight,0,s)}}function Mre(e){const t=HI(e),r=t.right-t.left,n=t.bottom-t.top,i=kre(e,r/2,n/2),a=Ere(e,r/2,n/2);return{outer:{x:t.left,y:t.top,w:r,h:n,radius:a},inner:{x:t.left+i.l,y:t.top+i.t,w:r-i.l-i.r,h:n-i.t-i.b,radius:{topLeft:Math.max(0,a.topLeft-Math.max(i.t,i.l)),topRight:Math.max(0,a.topRight-Math.max(i.t,i.r)),bottomLeft:Math.max(0,a.bottomLeft-Math.max(i.b,i.l)),bottomRight:Math.max(0,a.bottomRight-Math.max(i.b,i.r))}}}}function X5(e,t,r,n){const i=t===null,a=r===null,s=e&&!(i&&a)&&HI(e,n);return s&&(i||lc(t,s.left,s.right))&&(a||lc(r,s.top,s.bottom))}function Are(e){return e.topLeft||e.topRight||e.bottomLeft||e.bottomRight}function Cre(e,t){e.rect(t.x,t.y,t.w,t.h)}function J5(e,t,r={}){const n=e.x!==r.x?-t:0,i=e.y!==r.y?-t:0,a=(e.x+e.w!==r.x+r.w?t:0)-n,s=(e.y+e.h!==r.y+r.h?t:0)-i;return{x:e.x+n,y:e.y+i,w:e.w+a,h:e.h+s,radius:e.radius}}class pw extends hc{constructor(t){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,this.inflateAmount=void 0,t&&Object.assign(this,t)}draw(t){const{inflateAmount:r,options:{borderColor:n,backgroundColor:i}}=this,{inner:a,outer:s}=Mre(this),o=Are(s.radius)?sg:Cre;t.save(),(s.w!==a.w||s.h!==a.h)&&(t.beginPath(),o(t,J5(s,r,a)),t.clip(),o(t,J5(a,-r,s)),t.fillStyle=n,t.fill("evenodd")),t.beginPath(),o(t,J5(a,r)),t.fillStyle=i,t.fill(),t.restore()}inRange(t,r,n){return X5(this,t,r,n)}inXRange(t,r){return X5(this,t,null,r)}inYRange(t,r){return X5(this,null,t,r)}getCenterPoint(t){const{x:r,y:n,base:i,horizontal:a}=this.getProps(["x","y","base","horizontal"],t);return{x:a?(r+i)/2:r,y:a?n:(n+i)/2}}getRange(t){return t==="x"?this.width/2:this.height/2}}te(pw,"id","bar"),te(pw,"defaults",{borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0}),te(pw,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"});var Tre=Object.freeze({__proto__:null,ArcElement:bg,BarElement:pw,LineElement:Tu,PointElement:dw});const Q5=["rgb(54, 162, 235)","rgb(255, 99, 132)","rgb(255, 159, 64)","rgb(255, 205, 86)","rgb(75, 192, 192)","rgb(153, 102, 255)","rgb(201, 203, 207)"],WI=Q5.map(e=>e.replace("rgb(","rgba(").replace(")",", 0.5)"));function KI(e){return Q5[e%Q5.length]}function GI(e){return WI[e%WI.length]}function jre(e,t){return e.borderColor=KI(t),e.backgroundColor=GI(t),++t}function Ire(e,t){return e.backgroundColor=e.data.map(()=>KI(t++)),t}function Ore(e,t){return e.backgroundColor=e.data.map(()=>GI(t++)),t}function Bre(e){let t=0;return(r,n)=>{const i=e.getDatasetMeta(n).controller;i instanceof ah?t=Ire(r,t):i instanceof cg?t=Ore(r,t):i&&(t=jre(r,t))}}function YI(e){let t;for(t in e)if(e[t].borderColor||e[t].backgroundColor)return!0;return!1}function Rre(e){return e&&(e.borderColor||e.backgroundColor)}function Nre(){return un.borderColor!=="rgba(0,0,0,0.1)"||un.backgroundColor!=="rgba(0,0,0,0.1)"}var Fre={id:"colors",defaults:{enabled:!0,forceOverride:!1},beforeLayout(e,t,r){if(!r.enabled)return;const{data:{datasets:n},options:i}=e.config,{elements:a}=i,s=YI(n)||Rre(i)||a&&YI(a)||Nre();if(!r.forceOverride&&s)return;const o=Bre(e);n.forEach(o)}};function Pre(e,t,r,n,i){const a=i.samples||n;if(a>=r)return e.slice(t,t+r);const s=[],o=(r-2)/(a-2);let c=0;const l=t+r-1;let u=t,d,p,w,O,I;for(s[c++]=e[u],d=0;d<a-2;d++){let R=0,C=0,j;const N=Math.floor((d+1)*o)+1+t,P=Math.min(Math.floor((d+2)*o)+1,r)+t,Z=P-N;for(j=N;j<P;j++)R+=e[j].x,C+=e[j].y;R/=Z,C/=Z;const X=Math.floor(d*o)+1+t,re=Math.min(Math.floor((d+1)*o)+1,r)+t,{x:ne,y:ae}=e[u];for(w=O=-1,j=X;j<re;j++)O=.5*Math.abs((ne-R)*(e[j].y-ae)-(ne-e[j].x)*(C-ae)),O>w&&(w=O,p=e[j],I=j);s[c++]=p,u=I}return s[c++]=e[l],s}function zre(e,t,r,n){let i=0,a=0,s,o,c,l,u,d,p,w,O,I;const R=[],C=t+r-1,j=e[t].x,N=e[C].x-j;for(s=t;s<t+r;++s){o=e[s],c=(o.x-j)/N*n,l=o.y;const P=c|0;if(P===u)l<O?(O=l,d=s):l>I&&(I=l,p=s),i=(a*i+o.x)/++a;else{const Z=s-1;if(!hr(d)&&!hr(p)){const X=Math.min(d,p),re=Math.max(d,p);X!==w&&X!==Z&&R.push({...e[X],x:i}),re!==w&&re!==Z&&R.push({...e[re],x:i})}s>0&&Z!==w&&R.push(e[Z]),R.push(o),u=P,a=0,O=I=l,d=p=w=s}}return R}function XI(e){if(e._decimated){const t=e._data;delete e._decimated,delete e._data,Object.defineProperty(e,"data",{configurable:!0,enumerable:!0,writable:!0,value:t})}}function JI(e){e.data.datasets.forEach(t=>{XI(t)})}function Lre(e,t){const r=t.length;let n=0,i;const{iScale:a}=e,{min:s,max:o,minDefined:c,maxDefined:l}=a.getUserBounds();return c&&(n=mi(cc(t,a.axis,s).lo,0,r-1)),l?i=mi(cc(t,a.axis,o).hi+1,n,r)-n:i=r-n,{start:n,count:i}}var Dre={id:"decimation",defaults:{algorithm:"min-max",enabled:!1},beforeElementsUpdate:(e,t,r)=>{if(!r.enabled){JI(e);return}const n=e.width;e.data.datasets.forEach((i,a)=>{const{_data:s,indexAxis:o}=i,c=e.getDatasetMeta(a),l=s||i.data;if(og([o,e.options.indexAxis])==="y"||!c.controller.supportsDecimation)return;const u=e.scales[c.xAxisID];if(u.type!=="linear"&&u.type!=="time"||e.options.parsing)return;let{start:d,count:p}=Lre(c,l);const w=r.threshold||4*n;if(p<=w){XI(i);return}hr(s)&&(i._data=l,delete i.data,Object.defineProperty(i,"data",{configurable:!0,enumerable:!0,get:function(){return this._decimated},set:function(I){this._data=I}}));let O;switch(r.algorithm){case"lttb":O=Pre(l,d,p,n,r);break;case"min-max":O=zre(l,d,p,n);break;default:throw new Error(`Unsupported decimation algorithm '${r.algorithm}'`)}i._decimated=O})},destroy(e){JI(e)}};function Ure(e,t,r){const n=e.segments,i=e.points,a=t.points,s=[];for(const o of n){let{start:c,end:l}=o;l=t4(c,l,i);const u=e4(r,i[c],i[l],o.loop);if(!t.segments){s.push({source:o,target:u,start:i[c],end:i[l]});continue}const d=Qj(t,u);for(const p of d){const w=e4(r,a[p.start],a[p.end],p.loop),O=Jj(o,i,w);for(const I of O)s.push({source:I,target:p,start:{[r]:QI(u,w,"start",Math.max)},end:{[r]:QI(u,w,"end",Math.min)}})}}return s}function e4(e,t,r,n){if(n)return;let i=t[e],a=r[e];return e==="angle"&&(i=Qa(i),a=Qa(a)),{property:e,start:i,end:a}}function qre(e,t){const{x:r=null,y:n=null}=e||{},i=t.points,a=[];return t.segments.forEach(({start:s,end:o})=>{o=t4(s,o,i);const c=i[s],l=i[o];n!==null?(a.push({x:c.x,y:n}),a.push({x:l.x,y:n})):r!==null&&(a.push({x:r,y:c.y}),a.push({x:r,y:l.y}))}),a}function t4(e,t,r){for(;t>e;t--){const n=r[t];if(!isNaN(n.x)&&!isNaN(n.y))break}return t}function QI(e,t,r,n){return e&&t?n(e[r],t[r]):e?e[r]:t?t[r]:0}function eO(e,t){let r=[],n=!1;return cn(e)?(n=!0,r=e):r=qre(e,t),r.length?new Tu({points:r,options:{tension:0},_loop:n,_fullLoop:n}):null}function tO(e){return e&&e.fill!==!1}function Vre(e,t,r){let n=e[t].fill;const i=[t];let a;if(!r)return n;for(;n!==!1&&i.indexOf(n)===-1;){if(!En(n))return n;if(a=e[n],!a)return!1;if(a.visible)return n;i.push(n),n=a.fill}return!1}function Zre(e,t,r){const n=Kre(e);if(pr(n))return isNaN(n.value)?!1:n;let i=parseFloat(n);return En(i)&&Math.floor(i)===i?$re(n[0],t,i,r):["origin","start","end","stack","shape"].indexOf(n)>=0&&n}function $re(e,t,r,n){return(e==="-"||e==="+")&&(r=t+r),r===t||r<0||r>=n?!1:r}function Hre(e,t){let r=null;return e==="start"?r=t.bottom:e==="end"?r=t.top:pr(e)?r=t.getPixelForValue(e.value):t.getBasePixel&&(r=t.getBasePixel()),r}function Wre(e,t,r){let n;return e==="start"?n=r:e==="end"?n=t.options.reverse?t.min:t.max:pr(e)?n=e.value:n=t.getBaseValue(),n}function Kre(e){const t=e.options,r=t.fill;let n=Jt(r&&r.target,r);return n===void 0&&(n=!!t.backgroundColor),n===!1||n===null?!1:n===!0?"origin":n}function Gre(e){const{scale:t,index:r,line:n}=e,i=[],a=n.segments,s=n.points,o=Yre(t,r);o.push(eO({x:null,y:t.bottom},n));for(let c=0;c<a.length;c++){const l=a[c];for(let u=l.start;u<=l.end;u++)Xre(i,s[u],o)}return new Tu({points:i,options:{}})}function Yre(e,t){const r=[],n=e.getMatchingVisibleMetas("line");for(let i=0;i<n.length;i++){const a=n[i];if(a.index===t)break;a.hidden||r.unshift(a.dataset)}return r}function Xre(e,t,r){const n=[];for(let i=0;i<r.length;i++){const a=r[i],{first:s,last:o,point:c}=Jre(a,t,"x");if(!(!c||s&&o)){if(s)n.unshift(c);else if(e.push(c),!o)break}}e.push(...n)}function Jre(e,t,r){const n=e.interpolate(t,r);if(!n)return{};const i=n[r],a=e.segments,s=e.points;let o=!1,c=!1;for(let l=0;l<a.length;l++){const u=a[l],d=s[u.start][r],p=s[u.end][r];if(lc(i,d,p)){o=i===d,c=i===p;break}}return{first:o,last:c,point:n}}class rO{constructor(t){this.x=t.x,this.y=t.y,this.radius=t.radius}pathSegment(t,r,n){const{x:i,y:a,radius:s}=this;return r=r||{start:0,end:nn},t.arc(i,a,s,r.end,r.start,!0),!n.bounds}interpolate(t){const{x:r,y:n,radius:i}=this,a=t.angle;return{x:r+Math.cos(a)*i,y:n+Math.sin(a)*i,angle:a}}}function Qre(e){const{chart:t,fill:r,line:n}=e;if(En(r))return ene(t,r);if(r==="stack")return Gre(e);if(r==="shape")return!0;const i=tne(e);return i instanceof rO?i:eO(i,n)}function ene(e,t){const r=e.getDatasetMeta(t);return r&&e.isDatasetVisible(t)?r.dataset:null}function tne(e){return(e.scale||{}).getPointPositionForValue?nne(e):rne(e)}function rne(e){const{scale:t={},fill:r}=e,n=Hre(r,t);if(En(n)){const i=t.isHorizontal();return{x:i?n:null,y:i?null:n}}return null}function nne(e){const{scale:t,fill:r}=e,n=t.options,i=t.getLabels().length,a=n.reverse?t.max:t.min,s=Wre(r,t,a),o=[];if(n.grid.circular){const c=t.getPointPositionForValue(0,a);return new rO({x:c.x,y:c.y,radius:t.getDistanceFromCenterForValue(s)})}for(let c=0;c<i;++c)o.push(t.getPointPositionForValue(c,s));return o}function r4(e,t,r){const n=Qre(t),{chart:i,index:a,line:s,scale:o,axis:c}=t,l=s.options,u=l.fill,d=l.backgroundColor,{above:p=d,below:w=d}=u||{},O=i.getDatasetMeta(a),I=rI(i,O);n&&s.points.length&&(Wv(e,r),ine(e,{line:s,target:n,above:p,below:w,area:r,scale:o,axis:c,clip:I}),Kv(e))}function ine(e,t){const{line:r,target:n,above:i,below:a,area:s,scale:o,clip:c}=t,l=r._loop?"angle":t.axis;e.save(),l==="x"&&a!==i&&(nO(e,n,s.top),iO(e,{line:r,target:n,color:i,scale:o,property:l,clip:c}),e.restore(),e.save(),nO(e,n,s.bottom)),iO(e,{line:r,target:n,color:a,scale:o,property:l,clip:c}),e.restore()}function nO(e,t,r){const{segments:n,points:i}=t;let a=!0,s=!1;e.beginPath();for(const o of n){const{start:c,end:l}=o,u=i[c],d=i[t4(c,l,i)];a?(e.moveTo(u.x,u.y),a=!1):(e.lineTo(u.x,r),e.lineTo(u.x,u.y)),s=!!t.pathSegment(e,o,{move:s}),s?e.closePath():e.lineTo(d.x,r)}e.lineTo(t.first().x,r),e.closePath(),e.clip()}function iO(e,t){const{line:r,target:n,property:i,color:a,scale:s,clip:o}=t,c=Ure(r,n,i);for(const{source:l,target:u,start:d,end:p}of c){const{style:{backgroundColor:w=a}={}}=l,O=n!==!0;e.save(),e.fillStyle=w,ane(e,s,o,O&&e4(i,d,p)),e.beginPath();const I=!!r.pathSegment(e,l);let R;if(O){I?e.closePath():aO(e,n,p,i);const C=!!n.pathSegment(e,u,{move:I,reverse:!0});R=I&&C,R||aO(e,n,d,i)}e.closePath(),e.fill(R?"evenodd":"nonzero"),e.restore()}}function ane(e,t,r,n){const i=t.chart.chartArea,{property:a,start:s,end:o}=n||{};if(a==="x"||a==="y"){let c,l,u,d;a==="x"?(c=s,l=i.top,u=o,d=i.bottom):(c=i.left,l=s,u=i.right,d=o),e.beginPath(),r&&(c=Math.max(c,r.left),u=Math.min(u,r.right),l=Math.max(l,r.top),d=Math.min(d,r.bottom)),e.rect(c,l,u-c,d-l),e.clip()}}function aO(e,t,r,n){const i=t.interpolate(r,n);i&&e.lineTo(i.x,i.y)}var sne={id:"filler",afterDatasetsUpdate(e,t,r){const n=(e.data.datasets||[]).length,i=[];let a,s,o,c;for(s=0;s<n;++s)a=e.getDatasetMeta(s),o=a.dataset,c=null,o&&o.options&&o instanceof Tu&&(c={visible:e.isDatasetVisible(s),index:s,fill:Zre(o,s,n),chart:e,axis:a.controller.options.indexAxis,scale:a.vScale,line:o}),a.$filler=c,i.push(c);for(s=0;s<n;++s)c=i[s],!(!c||c.fill===!1)&&(c.fill=Vre(i,s,r.propagate))},beforeDraw(e,t,r){const n=r.drawTime==="beforeDraw",i=e.getSortedVisibleDatasetMetas(),a=e.chartArea;for(let s=i.length-1;s>=0;--s){const o=i[s].$filler;o&&(o.line.updateControlPoints(a,o.axis),n&&o.fill&&r4(e.ctx,o,a))}},beforeDatasetsDraw(e,t,r){if(r.drawTime!=="beforeDatasetsDraw")return;const n=e.getSortedVisibleDatasetMetas();for(let i=n.length-1;i>=0;--i){const a=n[i].$filler;tO(a)&&r4(e.ctx,a,e.chartArea)}},beforeDatasetDraw(e,t,r){const n=t.meta.$filler;!tO(n)||r.drawTime!=="beforeDatasetDraw"||r4(e.ctx,n,e.chartArea)},defaults:{propagate:!0,drawTime:"beforeDatasetDraw"}};const sO=(e,t)=>{let{boxHeight:r=t,boxWidth:n=t}=e;return e.usePointStyle&&(r=Math.min(r,t),n=e.pointStyleWidth||Math.min(n,t)),{boxWidth:n,boxHeight:r,itemHeight:Math.max(t,r)}},one=(e,t)=>e!==null&&t!==null&&e.datasetIndex===t.datasetIndex&&e.index===t.index;class oO extends hc{constructor(t){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,r,n){this.maxWidth=t,this.maxHeight=r,this._margins=n,this.setDimensions(),this.buildLabels(),this.fit()}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=this._margins.left,this.right=this.width):(this.height=this.maxHeight,this.top=this._margins.top,this.bottom=this.height)}buildLabels(){const t=this.options.labels||{};let r=Wr(t.generateLabels,[this.chart],this)||[];t.filter&&(r=r.filter(n=>t.filter(n,this.chart.data))),t.sort&&(r=r.sort((n,i)=>t.sort(n,i,this.chart.data))),this.options.reverse&&r.reverse(),this.legendItems=r}fit(){const{options:t,ctx:r}=this;if(!t.display){this.width=this.height=0;return}const n=t.labels,i=ii(n.font),a=i.size,s=this._computeTitleHeight(),{boxWidth:o,itemHeight:c}=sO(n,a);let l,u;r.font=i.string,this.isHorizontal()?(l=this.maxWidth,u=this._fitRows(s,a,o,c)+10):(u=this.maxHeight,l=this._fitCols(s,i,o,c)+10),this.width=Math.min(l,t.maxWidth||this.maxWidth),this.height=Math.min(u,t.maxHeight||this.maxHeight)}_fitRows(t,r,n,i){const{ctx:a,maxWidth:s,options:{labels:{padding:o}}}=this,c=this.legendHitBoxes=[],l=this.lineWidths=[0],u=i+o;let d=t;a.textAlign="left",a.textBaseline="middle";let p=-1,w=-u;return this.legendItems.forEach((O,I)=>{const R=n+r/2+a.measureText(O.text).width;(I===0||l[l.length-1]+R+2*o>s)&&(d+=u,l[l.length-(I>0?0:1)]=0,w+=u,p++),c[I]={left:0,top:w,row:p,width:R,height:i},l[l.length-1]+=R+o}),d}_fitCols(t,r,n,i){const{ctx:a,maxHeight:s,options:{labels:{padding:o}}}=this,c=this.legendHitBoxes=[],l=this.columnSizes=[],u=s-t;let d=o,p=0,w=0,O=0,I=0;return this.legendItems.forEach((R,C)=>{const{itemWidth:j,itemHeight:N}=lne(n,r,a,R,i);C>0&&w+N+2*o>u&&(d+=p+o,l.push({width:p,height:w}),O+=p+o,I++,p=w=0),c[C]={left:O,top:w,col:I,width:j,height:N},p=Math.max(p,j),w+=N+o}),d+=p,l.push({width:p,height:w}),d}adjustHitBoxes(){if(!this.options.display)return;const t=this._computeTitleHeight(),{legendHitBoxes:r,options:{align:n,labels:{padding:i},rtl:a}}=this,s=u0(a,this.left,this.width);if(this.isHorizontal()){let o=0,c=$i(n,this.left+i,this.right-this.lineWidths[o]);for(const l of r)o!==l.row&&(o=l.row,c=$i(n,this.left+i,this.right-this.lineWidths[o])),l.top+=this.top+t+i,l.left=s.leftForLtr(s.x(c),l.width),c+=l.width+i}else{let o=0,c=$i(n,this.top+t+i,this.bottom-this.columnSizes[o].height);for(const l of r)l.col!==o&&(o=l.col,c=$i(n,this.top+t+i,this.bottom-this.columnSizes[o].height)),l.top=c,l.left+=this.left+i,l.left=s.leftForLtr(s.x(l.left),l.width),c+=l.height+i}}isHorizontal(){return this.options.position==="top"||this.options.position==="bottom"}draw(){if(this.options.display){const t=this.ctx;Wv(t,this),this._draw(),Kv(t)}}_draw(){const{options:t,columnSizes:r,lineWidths:n,ctx:i}=this,{align:a,labels:s}=t,o=un.color,c=u0(t.rtl,this.left,this.width),l=ii(s.font),{padding:u}=s,d=l.size,p=d/2;let w;this.drawTitle(),i.textAlign=c.textAlign("left"),i.textBaseline="middle",i.lineWidth=.5,i.font=l.string;const{boxWidth:O,boxHeight:I,itemHeight:R}=sO(s,d),C=function(X,re,ne){if(isNaN(O)||O<=0||isNaN(I)||I<0)return;i.save();const ae=Jt(ne.lineWidth,1);if(i.fillStyle=Jt(ne.fillStyle,o),i.lineCap=Jt(ne.lineCap,"butt"),i.lineDashOffset=Jt(ne.lineDashOffset,0),i.lineJoin=Jt(ne.lineJoin,"miter"),i.lineWidth=ae,i.strokeStyle=Jt(ne.strokeStyle,o),i.setLineDash(Jt(ne.lineDash,[])),s.usePointStyle){const ue={radius:I*Math.SQRT2/2,pointStyle:ne.pointStyle,rotation:ne.rotation,borderWidth:ae},m=c.xPlus(X,O/2),A=re+p;Fj(i,ue,m,A,s.pointStyleWidth&&O)}else{const ue=re+Math.max((d-I)/2,0),m=c.leftForLtr(X,O),A=th(ne.borderRadius);i.beginPath(),Object.values(A).some(f=>f!==0)?sg(i,{x:m,y:ue,w:O,h:I,radius:A}):i.rect(m,ue,O,I),i.fill(),ae!==0&&i.stroke()}i.restore()},j=function(X,re,ne){eh(i,ne.text,X,re+R/2,l,{strikethrough:ne.hidden,textAlign:c.textAlign(ne.textAlign)})},N=this.isHorizontal(),P=this._computeTitleHeight();N?w={x:$i(a,this.left+u,this.right-n[0]),y:this.top+u+P,line:0}:w={x:this.left+u,y:$i(a,this.top+P+u,this.bottom-r[0].height),line:0},Kj(this.ctx,t.textDirection);const Z=R+u;this.legendItems.forEach((X,re)=>{i.strokeStyle=X.fontColor,i.fillStyle=X.fontColor;const ne=i.measureText(X.text).width,ae=c.textAlign(X.textAlign||(X.textAlign=s.textAlign)),ue=O+p+ne;let m=w.x,A=w.y;c.setWidth(this.width),N?re>0&&m+ue+u>this.right&&(A=w.y+=Z,w.line++,m=w.x=$i(a,this.left+u,this.right-n[w.line])):re>0&&A+Z>this.bottom&&(m=w.x=m+r[w.line].width+u,w.line++,A=w.y=$i(a,this.top+P+u,this.bottom-r[w.line].height));const f=c.x(m);if(C(f,A,X),m=CQ(ae,m+O+p,N?m+ue:this.right,t.rtl),j(c.x(m),A,X),N)w.x+=ue+u;else if(typeof X.text!="string"){const g=l.lineHeight;w.y+=lO(X,g)+u}else w.y+=Z}),Gj(this.ctx,t.textDirection)}drawTitle(){const t=this.options,r=t.title,n=ii(r.font),i=Hi(r.padding);if(!r.display)return;const a=u0(t.rtl,this.left,this.width),s=this.ctx,o=r.position,c=n.size/2,l=i.top+c;let u,d=this.left,p=this.width;if(this.isHorizontal())p=Math.max(...this.lineWidths),u=this.top+l,d=$i(t.align,d,this.right-p);else{const O=this.columnSizes.reduce((I,R)=>Math.max(I,R.height),0);u=l+$i(t.align,this.top,this.bottom-O-t.labels.padding-this._computeTitleHeight())}const w=$i(o,d,d+p);s.textAlign=a.textAlign(A5(o)),s.textBaseline="middle",s.strokeStyle=r.color,s.fillStyle=r.color,s.font=n.string,eh(s,r.text,w,u,n)}_computeTitleHeight(){const t=this.options.title,r=ii(t.font),n=Hi(t.padding);return t.display?r.lineHeight+n.height:0}_getLegendItemAt(t,r){let n,i,a;if(lc(t,this.left,this.right)&&lc(r,this.top,this.bottom)){for(a=this.legendHitBoxes,n=0;n<a.length;++n)if(i=a[n],lc(t,i.left,i.left+i.width)&&lc(r,i.top,i.top+i.height))return this.legendItems[n]}return null}handleEvent(t){const r=this.options;if(!fne(t.type,r))return;const n=this._getLegendItemAt(t.x,t.y);if(t.type==="mousemove"||t.type==="mouseout"){const i=this._hoveredItem,a=one(i,n);i&&!a&&Wr(r.onLeave,[t,i,this],this),this._hoveredItem=n,n&&!a&&Wr(r.onHover,[t,n,this],this)}else n&&Wr(r.onClick,[t,n,this],this)}}function lne(e,t,r,n,i){const a=cne(n,e,t,r),s=une(i,n,t.lineHeight);return{itemWidth:a,itemHeight:s}}function cne(e,t,r,n){let i=e.text;return i&&typeof i!="string"&&(i=i.reduce((a,s)=>a.length>s.length?a:s)),t+r.size/2+n.measureText(i).width}function une(e,t,r){let n=e;return typeof t.text!="string"&&(n=lO(t,r)),n}function lO(e,t){const r=e.text?e.text.length:0;return t*r}function fne(e,t){return!!((e==="mousemove"||e==="mouseout")&&(t.onHover||t.onLeave)||t.onClick&&(e==="click"||e==="mouseup"))}var hne={id:"legend",_element:oO,start(e,t,r){const n=e.legend=new oO({ctx:e.ctx,options:r,chart:e});Wi.configure(e,n,r),Wi.addBox(e,n)},stop(e){Wi.removeBox(e,e.legend),delete e.legend},beforeUpdate(e,t,r){const n=e.legend;Wi.configure(e,n,r),n.options=r},afterUpdate(e){const t=e.legend;t.buildLabels(),t.adjustHitBoxes()},afterEvent(e,t){t.replay||e.legend.handleEvent(t.event)},defaults:{display:!0,position:"top",align:"center",fullSize:!0,reverse:!1,weight:1e3,onClick(e,t,r){const n=t.datasetIndex,i=r.chart;i.isDatasetVisible(n)?(i.hide(n),t.hidden=!0):(i.show(n),t.hidden=!1)},onHover:null,onLeave:null,labels:{color:e=>e.chart.options.color,boxWidth:40,padding:10,generateLabels(e){const t=e.data.datasets,{labels:{usePointStyle:r,pointStyle:n,textAlign:i,color:a,useBorderRadius:s,borderRadius:o}}=e.legend.options;return e._getSortedDatasetMetas().map(c=>{const l=c.controller.getStyle(r?0:void 0),u=Hi(l.borderWidth);return{text:t[c.index].label,fillStyle:l.backgroundColor,fontColor:a,hidden:!c.visible,lineCap:l.borderCapStyle,lineDash:l.borderDash,lineDashOffset:l.borderDashOffset,lineJoin:l.borderJoinStyle,lineWidth:(u.width+u.height)/4,strokeStyle:l.borderColor,pointStyle:n||l.pointStyle,rotation:l.rotation,textAlign:i||l.textAlign,borderRadius:s&&(o||l.borderRadius),datasetIndex:c.index}},this)}},title:{color:e=>e.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:e=>!e.startsWith("on"),labels:{_scriptable:e=>!["generateLabels","filter","sort"].includes(e)}}};class n4 extends hc{constructor(t){super(),this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,r){const n=this.options;if(this.left=0,this.top=0,!n.display){this.width=this.height=this.right=this.bottom=0;return}this.width=this.right=t,this.height=this.bottom=r;const i=cn(n.text)?n.text.length:1;this._padding=Hi(n.padding);const a=i*ii(n.font).lineHeight+this._padding.height;this.isHorizontal()?this.height=a:this.width=a}isHorizontal(){const t=this.options.position;return t==="top"||t==="bottom"}_drawArgs(t){const{top:r,left:n,bottom:i,right:a,options:s}=this,o=s.align;let c=0,l,u,d;return this.isHorizontal()?(u=$i(o,n,a),d=r+t,l=a-n):(s.position==="left"?(u=n+t,d=$i(o,i,r),c=rn*-.5):(u=a-t,d=$i(o,r,i),c=rn*.5),l=i-r),{titleX:u,titleY:d,maxWidth:l,rotation:c}}draw(){const t=this.ctx,r=this.options;if(!r.display)return;const n=ii(r.font),i=n.lineHeight/2+this._padding.top,{titleX:a,titleY:s,maxWidth:o,rotation:c}=this._drawArgs(i);eh(t,r.text,0,0,n,{color:r.color,maxWidth:o,rotation:c,textAlign:A5(r.align),textBaseline:"middle",translation:[a,s]})}}function dne(e,t){const r=new n4({ctx:e.ctx,options:t,chart:e});Wi.configure(e,r,t),Wi.addBox(e,r),e.titleBlock=r}var pne={id:"title",_element:n4,start(e,t,r){dne(e,r)},stop(e){const t=e.titleBlock;Wi.removeBox(e,t),delete e.titleBlock},beforeUpdate(e,t,r){const n=e.titleBlock;Wi.configure(e,n,r),n.options=r},defaults:{align:"center",display:!1,font:{weight:"bold"},fullSize:!0,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const mw=new WeakMap;var mne={id:"subtitle",start(e,t,r){const n=new n4({ctx:e.ctx,options:r,chart:e});Wi.configure(e,n,r),Wi.addBox(e,n),mw.set(e,n)},stop(e){Wi.removeBox(e,mw.get(e)),mw.delete(e)},beforeUpdate(e,t,r){const n=mw.get(e);Wi.configure(e,n,r),n.options=r},defaults:{align:"center",display:!1,font:{weight:"normal"},fullSize:!0,padding:0,position:"top",text:"",weight:1500},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const yg={average(e){if(!e.length)return!1;let t,r,n=new Set,i=0,a=0;for(t=0,r=e.length;t<r;++t){const s=e[t].element;if(s&&s.hasValue()){const o=s.tooltipPosition();n.add(o.x),i+=o.y,++a}}return a===0||n.size===0?!1:{x:[...n].reduce((s,o)=>s+o)/n.size,y:i/a}},nearest(e,t){if(!e.length)return!1;let r=t.x,n=t.y,i=Number.POSITIVE_INFINITY,a,s,o;for(a=0,s=e.length;a<s;++a){const c=e[a].element;if(c&&c.hasValue()){const l=c.getCenterPoint(),u=E5(t,l);u<i&&(i=u,o=c)}}if(o){const c=o.tooltipPosition();r=c.x,n=c.y}return{x:r,y:n}}};function il(e,t){return t&&(cn(t)?Array.prototype.push.apply(e,t):e.push(t)),e}function pc(e){return(typeof e=="string"||e instanceof String)&&e.indexOf(`
16`)>-1?e.split(`
17`):e}function gne(e,t){const{element:r,datasetIndex:n,index:i}=t,a=e.getDatasetMeta(n).controller,{label:s,value:o}=a.getLabelAndValue(i);return{chart:e,label:s,parsed:a.getParsed(i),raw:e.data.datasets[n].data[i],formattedValue:o,dataset:a.getDataset(),dataIndex:i,datasetIndex:n,element:r}}function cO(e,t){const r=e.chart.ctx,{body:n,footer:i,title:a}=e,{boxWidth:s,boxHeight:o}=t,c=ii(t.bodyFont),l=ii(t.titleFont),u=ii(t.footerFont),d=a.length,p=i.length,w=n.length,O=Hi(t.padding);let I=O.height,R=0,C=n.reduce((P,Z)=>P+Z.before.length+Z.lines.length+Z.after.length,0);if(C+=e.beforeBody.length+e.afterBody.length,d&&(I+=d*l.lineHeight+(d-1)*t.titleSpacing+t.titleMarginBottom),C){const P=t.displayColors?Math.max(o,c.lineHeight):c.lineHeight;I+=w*P+(C-w)*c.lineHeight+(C-1)*t.bodySpacing}p&&(I+=t.footerMarginTop+p*u.lineHeight+(p-1)*t.footerSpacing);let j=0;const N=function(P){R=Math.max(R,r.measureText(P).width+j)};return r.save(),r.font=l.string,Pr(e.title,N),r.font=c.string,Pr(e.beforeBody.concat(e.afterBody),N),j=t.displayColors?s+2+t.boxPadding:0,Pr(n,P=>{Pr(P.before,N),Pr(P.lines,N),Pr(P.after,N)}),j=0,r.font=u.string,Pr(e.footer,N),r.restore(),R+=O.width,{width:R,height:I}}function bne(e,t){const{y:r,height:n}=t;return r<n/2?"top":r>e.height-n/2?"bottom":"center"}function yne(e,t,r,n){const{x:i,width:a}=n,s=r.caretSize+r.caretPadding;if(e==="left"&&i+a+s>t.width||e==="right"&&i-a-s<0)return!0}function vne(e,t,r,n){const{x:i,width:a}=r,{width:s,chartArea:{left:o,right:c}}=e;let l="center";return n==="center"?l=i<=(o+c)/2?"left":"right":i<=a/2?l="left":i>=s-a/2&&(l="right"),yne(l,e,t,r)&&(l="center"),l}function uO(e,t,r){const n=r.yAlign||t.yAlign||bne(e,r);return{xAlign:r.xAlign||t.xAlign||vne(e,t,r,n),yAlign:n}}function wne(e,t){let{x:r,width:n}=e;return t==="right"?r-=n:t==="center"&&(r-=n/2),r}function xne(e,t,r){let{y:n,height:i}=e;return t==="top"?n+=r:t==="bottom"?n-=i+r:n-=i/2,n}function fO(e,t,r,n){const{caretSize:i,caretPadding:a,cornerRadius:s}=e,{xAlign:o,yAlign:c}=r,l=i+a,{topLeft:u,topRight:d,bottomLeft:p,bottomRight:w}=th(s);let O=wne(t,o);const I=xne(t,c,l);return c==="center"?o==="left"?O+=l:o==="right"&&(O-=l):o==="left"?O-=Math.max(u,p)+i:o==="right"&&(O+=Math.max(d,w)+i),{x:mi(O,0,n.width-t.width),y:mi(I,0,n.height-t.height)}}function gw(e,t,r){const n=Hi(r.padding);return t==="center"?e.x+e.width/2:t==="right"?e.x+e.width-n.right:e.x+n.left}function hO(e){return il([],pc(e))}function _ne(e,t,r){return Cu(e,{tooltip:t,tooltipItems:r,type:"tooltip"})}function dO(e,t){const r=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return r?e.override(r):e}const pO={beforeTitle:oc,title(e){if(e.length>0){const t=e[0],r=t.chart.data.labels,n=r?r.length:0;if(this&&this.options&&this.options.mode==="dataset")return t.dataset.label||"";if(t.label)return t.label;if(n>0&&t.dataIndex<n)return r[t.dataIndex]}return""},afterTitle:oc,beforeBody:oc,beforeLabel:oc,label(e){if(this&&this.options&&this.options.mode==="dataset")return e.label+": "+e.formattedValue||e.formattedValue;let t=e.dataset.label||"";t&&(t+=": ");const r=e.formattedValue;return hr(r)||(t+=r),t},labelColor(e){const t=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{borderColor:t.borderColor,backgroundColor:t.backgroundColor,borderWidth:t.borderWidth,borderDash:t.borderDash,borderDashOffset:t.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(e){const t=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{pointStyle:t.pointStyle,rotation:t.rotation}},afterLabel:oc,afterBody:oc,beforeFooter:oc,footer:oc,afterFooter:oc};function Ma(e,t,r,n){const i=e[t].call(r,n);return typeof i>"u"?pO[t].call(r,n):i}class i4 extends hc{constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const r=this.chart,n=this.options.setContext(this.getContext()),i=n.enabled&&r.options.animation&&n.animations,a=new iI(this.chart,i);return i._cacheable&&(this._cachedAnimations=Object.freeze(a)),a}getContext(){return this.$context||(this.$context=_ne(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,r){const{callbacks:n}=r,i=Ma(n,"beforeTitle",this,t),a=Ma(n,"title",this,t),s=Ma(n,"afterTitle",this,t);let o=[];return o=il(o,pc(i)),o=il(o,pc(a)),o=il(o,pc(s)),o}getBeforeBody(t,r){return hO(Ma(r.callbacks,"beforeBody",this,t))}getBody(t,r){const{callbacks:n}=r,i=[];return Pr(t,a=>{const s={before:[],lines:[],after:[]},o=dO(n,a);il(s.before,pc(Ma(o,"beforeLabel",this,a))),il(s.lines,Ma(o,"label",this,a)),il(s.after,pc(Ma(o,"afterLabel",this,a))),i.push(s)}),i}getAfterBody(t,r){return hO(Ma(r.callbacks,"afterBody",this,t))}getFooter(t,r){const{callbacks:n}=r,i=Ma(n,"beforeFooter",this,t),a=Ma(n,"footer",this,t),s=Ma(n,"afterFooter",this,t);let o=[];return o=il(o,pc(i)),o=il(o,pc(a)),o=il(o,pc(s)),o}_createItems(t){const r=this._active,n=this.chart.data,i=[],a=[],s=[];let o=[],c,l;for(c=0,l=r.length;c<l;++c)o.push(gne(this.chart,r[c]));return t.filter&&(o=o.filter((u,d,p)=>t.filter(u,d,p,n))),t.itemSort&&(o=o.sort((u,d)=>t.itemSort(u,d,n))),Pr(o,u=>{const d=dO(t.callbacks,u);i.push(Ma(d,"labelColor",this,u)),a.push(Ma(d,"labelPointStyle",this,u)),s.push(Ma(d,"labelTextColor",this,u))}),this.labelColors=i,this.labelPointStyles=a,this.labelTextColors=s,this.dataPoints=o,o}update(t,r){const n=this.options.setContext(this.getContext()),i=this._active;let a,s=[];if(!i.length)this.opacity!==0&&(a={opacity:0});else{const o=yg[n.position].call(this,i,this._eventPosition);s=this._createItems(n),this.title=this.getTitle(s,n),this.beforeBody=this.getBeforeBody(s,n),this.body=this.getBody(s,n),this.afterBody=this.getAfterBody(s,n),this.footer=this.getFooter(s,n);const c=this._size=cO(this,n),l=Object.assign({},o,c),u=uO(this.chart,n,l),d=fO(n,l,u,this.chart);this.xAlign=u.xAlign,this.yAlign=u.yAlign,a={opacity:1,x:d.x,y:d.y,width:c.width,height:c.height,caretX:o.x,caretY:o.y}}this._tooltipItems=s,this.$context=void 0,a&&this._resolveAnimations().update(this,a),t&&n.external&&n.external.call(this,{chart:this.chart,tooltip:this,replay:r})}drawCaret(t,r,n,i){const a=this.getCaretPosition(t,n,i);r.lineTo(a.x1,a.y1),r.lineTo(a.x2,a.y2),r.lineTo(a.x3,a.y3)}getCaretPosition(t,r,n){const{xAlign:i,yAlign:a}=this,{caretSize:s,cornerRadius:o}=n,{topLeft:c,topRight:l,bottomLeft:u,bottomRight:d}=th(o),{x:p,y:w}=t,{width:O,height:I}=r;let R,C,j,N,P,Z;return a==="center"?(P=w+I/2,i==="left"?(R=p,C=R-s,N=P+s,Z=P-s):(R=p+O,C=R+s,N=P-s,Z=P+s),j=R):(i==="left"?C=p+Math.max(c,u)+s:i==="right"?C=p+O-Math.max(l,d)-s:C=this.caretX,a==="top"?(N=w,P=N-s,R=C-s,j=C+s):(N=w+I,P=N+s,R=C+s,j=C-s),Z=N),{x1:R,x2:C,x3:j,y1:N,y2:P,y3:Z}}drawTitle(t,r,n){const i=this.title,a=i.length;let s,o,c;if(a){const l=u0(n.rtl,this.x,this.width);for(t.x=gw(this,n.titleAlign,n),r.textAlign=l.textAlign(n.titleAlign),r.textBaseline="middle",s=ii(n.titleFont),o=n.titleSpacing,r.fillStyle=n.titleColor,r.font=s.string,c=0;c<a;++c)r.fillText(i[c],l.x(t.x),t.y+s.lineHeight/2),t.y+=s.lineHeight+o,c+1===a&&(t.y+=n.titleMarginBottom-o)}}_drawColorBox(t,r,n,i,a){const s=this.labelColors[n],o=this.labelPointStyles[n],{boxHeight:c,boxWidth:l}=a,u=ii(a.bodyFont),d=gw(this,"left",a),p=i.x(d),w=c<u.lineHeight?(u.lineHeight-c)/2:0,O=r.y+w;if(a.usePointStyle){const I={radius:Math.min(l,c)/2,pointStyle:o.pointStyle,rotation:o.rotation,borderWidth:1},R=i.leftForLtr(p,l)+l/2,C=O+c/2;t.strokeStyle=a.multiKeyBackground,t.fillStyle=a.multiKeyBackground,O5(t,I,R,C),t.strokeStyle=s.borderColor,t.fillStyle=s.backgroundColor,O5(t,I,R,C)}else{t.lineWidth=pr(s.borderWidth)?Math.max(...Object.values(s.borderWidth)):s.borderWidth||1,t.strokeStyle=s.borderColor,t.setLineDash(s.borderDash||[]),t.lineDashOffset=s.borderDashOffset||0;const I=i.leftForLtr(p,l),R=i.leftForLtr(i.xPlus(p,1),l-2),C=th(s.borderRadius);Object.values(C).some(j=>j!==0)?(t.beginPath(),t.fillStyle=a.multiKeyBackground,sg(t,{x:I,y:O,w:l,h:c,radius:C}),t.fill(),t.stroke(),t.fillStyle=s.backgroundColor,t.beginPath(),sg(t,{x:R,y:O+1,w:l-2,h:c-2,radius:C}),t.fill()):(t.fillStyle=a.multiKeyBackground,t.fillRect(I,O,l,c),t.strokeRect(I,O,l,c),t.fillStyle=s.backgroundColor,t.fillRect(R,O+1,l-2,c-2))}t.fillStyle=this.labelTextColors[n]}drawBody(t,r,n){const{body:i}=this,{bodySpacing:a,bodyAlign:s,displayColors:o,boxHeight:c,boxWidth:l,boxPadding:u}=n,d=ii(n.bodyFont);let p=d.lineHeight,w=0;const O=u0(n.rtl,this.x,this.width),I=function(ne){r.fillText(ne,O.x(t.x+w),t.y+p/2),t.y+=p+a},R=O.textAlign(s);let C,j,N,P,Z,X,re;for(r.textAlign=s,r.textBaseline="middle",r.font=d.string,t.x=gw(this,R,n),r.fillStyle=n.bodyColor,Pr(this.beforeBody,I),w=o&&R!=="right"?s==="center"?l/2+u:l+2+u:0,P=0,X=i.length;P<X;++P){for(C=i[P],j=this.labelTextColors[P],r.fillStyle=j,Pr(C.before,I),N=C.lines,o&&N.length&&(this._drawColorBox(r,t,P,O,n),p=Math.max(d.lineHeight,c)),Z=0,re=N.length;Z<re;++Z)I(N[Z]),p=d.lineHeight;Pr(C.after,I)}w=0,p=d.lineHeight,Pr(this.afterBody,I),t.y-=a}drawFooter(t,r,n){const i=this.footer,a=i.length;let s,o;if(a){const c=u0(n.rtl,this.x,this.width);for(t.x=gw(this,n.footerAlign,n),t.y+=n.footerMarginTop,r.textAlign=c.textAlign(n.footerAlign),r.textBaseline="middle",s=ii(n.footerFont),r.fillStyle=n.footerColor,r.font=s.string,o=0;o<a;++o)r.fillText(i[o],c.x(t.x),t.y+s.lineHeight/2),t.y+=s.lineHeight+n.footerSpacing}}drawBackground(t,r,n,i){const{xAlign:a,yAlign:s}=this,{x:o,y:c}=t,{width:l,height:u}=n,{topLeft:d,topRight:p,bottomLeft:w,bottomRight:O}=th(i.cornerRadius);r.fillStyle=i.backgroundColor,r.strokeStyle=i.borderColor,r.lineWidth=i.borderWidth,r.beginPath(),r.moveTo(o+d,c),s==="top"&&this.drawCaret(t,r,n,i),r.lineTo(o+l-p,c),r.quadraticCurveTo(o+l,c,o+l,c+p),s==="center"&&a==="right"&&this.drawCaret(t,r,n,i),r.lineTo(o+l,c+u-O),r.quadraticCurveTo(o+l,c+u,o+l-O,c+u),s==="bottom"&&this.drawCaret(t,r,n,i),r.lineTo(o+w,c+u),r.quadraticCurveTo(o,c+u,o,c+u-w),s==="center"&&a==="left"&&this.drawCaret(t,r,n,i),r.lineTo(o,c+d),r.quadraticCurveTo(o,c,o+d,c),r.closePath(),r.fill(),i.borderWidth>0&&r.stroke()}_updateAnimationTarget(t){const r=this.chart,n=this.$animations,i=n&&n.x,a=n&&n.y;if(i||a){const s=yg[t.position].call(this,this._active,this._eventPosition);if(!s)return;const o=this._size=cO(this,t),c=Object.assign({},s,this._size),l=uO(r,t,c),u=fO(t,c,l,r);(i._to!==u.x||a._to!==u.y)&&(this.xAlign=l.xAlign,this.yAlign=l.yAlign,this.width=o.width,this.height=o.height,this.caretX=s.x,this.caretY=s.y,this._resolveAnimations().update(this,u))}}_willRender(){return!!this.opacity}draw(t){const r=this.options.setContext(this.getContext());let n=this.opacity;if(!n)return;this._updateAnimationTarget(r);const i={width:this.width,height:this.height},a={x:this.x,y:this.y};n=Math.abs(n)<.001?0:n;const s=Hi(r.padding),o=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;r.enabled&&o&&(t.save(),t.globalAlpha=n,this.drawBackground(a,t,i,r),Kj(t,r.textDirection),a.y+=s.top,this.drawTitle(a,t,r),this.drawBody(a,t,r),this.drawFooter(a,t,r),Gj(t,r.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,r){const n=this._active,i=t.map(({datasetIndex:o,index:c})=>{const l=this.chart.getDatasetMeta(o);if(!l)throw new Error("Cannot find a dataset at index "+o);return{datasetIndex:o,element:l.data[c],index:c}}),a=!Uv(n,i),s=this._positionChanged(i,r);(a||s)&&(this._active=i,this._eventPosition=r,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,r,n=!0){if(r&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const i=this.options,a=this._active||[],s=this._getActiveElements(t,a,r,n),o=this._positionChanged(s,t),c=r||!Uv(s,a)||o;return c&&(this._active=s,(i.enabled||i.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,r))),c}_getActiveElements(t,r,n,i){const a=this.options;if(t.type==="mouseout")return[];if(!i)return r.filter(o=>this.chart.data.datasets[o.datasetIndex]&&this.chart.getDatasetMeta(o.datasetIndex).controller.getParsed(o.index)!==void 0);const s=this.chart.getElementsAtEventForMode(t,a.mode,a,n);return a.reverse&&s.reverse(),s}_positionChanged(t,r){const{caretX:n,caretY:i,options:a}=this,s=yg[a.position].call(this,t,r);return s!==!1&&(n!==s.x||i!==s.y)}}te(i4,"positioners",yg);var Sne={id:"tooltip",_element:i4,positioners:yg,afterInit(e,t,r){r&&(e.tooltip=new i4({chart:e,options:r}))},beforeUpdate(e,t,r){e.tooltip&&e.tooltip.initialize(r)},reset(e,t,r){e.tooltip&&e.tooltip.initialize(r)},afterDraw(e){const t=e.tooltip;if(t&&t._willRender()){const r={tooltip:t};if(e.notifyPlugins("beforeTooltipDraw",{...r,cancelable:!0})===!1)return;t.draw(e.ctx),e.notifyPlugins("afterTooltipDraw",r)}},afterEvent(e,t){if(e.tooltip){const r=t.replay;e.tooltip.handleEvent(t.event,r,t.inChartArea)&&(t.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(e,t)=>t.bodyFont.size,boxWidth:(e,t)=>t.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:pO},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:e=>e!=="filter"&&e!=="itemSort"&&e!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]},kne=Object.freeze({__proto__:null,Colors:Fre,Decimation:Dre,Filler:sne,Legend:hne,SubTitle:mne,Title:pne,Tooltip:Sne});const Ene=(e,t,r,n)=>(typeof t=="string"?(r=e.push(t)-1,n.unshift({index:r,label:t})):isNaN(t)&&(r=null),r);function Mne(e,t,r,n){const i=e.indexOf(t);if(i===-1)return Ene(e,t,r,n);const a=e.lastIndexOf(t);return i!==a?r:i}const Ane=(e,t)=>e===null?null:mi(Math.round(e),0,t);function mO(e){const t=this.getLabels();return e>=0&&e<t.length?t[e]:e}class a4 extends oh{constructor(t){super(t),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(t){const r=this._addedLabels;if(r.length){const n=this.getLabels();for(const{index:i,label:a}of r)n[i]===a&&n.splice(i,1);this._addedLabels=[]}super.init(t)}parse(t,r){if(hr(t))return null;const n=this.getLabels();return r=isFinite(r)&&n[r]===t?r:Mne(n,t,Jt(r,t),this._addedLabels),Ane(r,n.length-1)}determineDataLimits(){const{minDefined:t,maxDefined:r}=this.getUserBounds();let{min:n,max:i}=this.getMinMax(!0);this.options.bounds==="ticks"&&(t||(n=0),r||(i=this.getLabels().length-1)),this.min=n,this.max=i}buildTicks(){const t=this.min,r=this.max,n=this.options.offset,i=[];let a=this.getLabels();a=t===0&&r===a.length-1?a:a.slice(t,r+1),this._valueRange=Math.max(a.length-(n?0:1),1),this._startValue=this.min-(n?.5:0);for(let s=t;s<=r;s++)i.push({value:s});return i}getLabelForValue(t){return mO.call(this,t)}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels)}getPixelForValue(t){return typeof t!="number"&&(t=this.parse(t)),t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getPixelForTick(t){const r=this.ticks;return t<0||t>r.length-1?null:this.getPixelForValue(r[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}}te(a4,"id","category"),te(a4,"defaults",{ticks:{callback:mO}});function Cne(e,t){const r=[],{bounds:n,step:i,min:a,max:s,precision:o,count:c,maxTicks:l,maxDigits:u,includeBounds:d}=e,p=i||1,w=l-1,{min:O,max:I}=t,R=!hr(a),C=!hr(s),j=!hr(c),N=(I-O)/(u+1);let P=vj((I-O)/w/p)*p,Z,X,re,ne;if(P<1e-14&&!R&&!C)return[{value:O},{value:I}];ne=Math.ceil(I/P)-Math.floor(O/P),ne>w&&(P=vj(ne*P/w/p)*p),hr(o)||(Z=Math.pow(10,o),P=Math.ceil(P*Z)/Z),n==="ticks"?(X=Math.floor(O/P)*P,re=Math.ceil(I/P)*P):(X=O,re=I),R&&C&&i&&xQ((s-a)/i,P/1e3)?(ne=Math.round(Math.min((s-a)/P,l)),P=(s-a)/ne,X=a,re=s):j?(X=R?a:X,re=C?s:re,ne=c-1,P=(re-X)/ne):(ne=(re-X)/P,tg(ne,Math.round(ne),P/1e3)?ne=Math.round(ne):ne=Math.ceil(ne));const ae=Math.max(xj(P),xj(X));Z=Math.pow(10,hr(o)?ae:o),X=Math.round(X*Z)/Z,re=Math.round(re*Z)/Z;let ue=0;for(R&&(d&&X!==a?(r.push({value:a}),X<a&&ue++,tg(Math.round((X+ue*P)*Z)/Z,a,gO(a,N,e))&&ue++):X<a&&ue++);ue<ne;++ue){const m=Math.round((X+ue*P)*Z)/Z;if(C&&m>s)break;r.push({value:m})}return C&&d&&re!==s?r.length&&tg(r[r.length-1].value,s,gO(s,N,e))?r[r.length-1].value=s:r.push({value:s}):(!C||re===s)&&r.push({value:re}),r}function gO(e,t,{horizontal:r,minRotation:n}){const i=oo(n),a=(r?Math.sin(i):Math.cos(i))||.001,s=.75*t*(""+e).length;return Math.min(t/a,s)}class bw extends oh{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,r){return hr(t)||(typeof t=="number"||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:r,maxDefined:n}=this.getUserBounds();let{min:i,max:a}=this;const s=c=>i=r?i:c,o=c=>a=n?a:c;if(t){const c=rl(i),l=rl(a);c<0&&l<0?o(0):c>0&&l>0&&s(0)}if(i===a){let c=a===0?1:Math.abs(a*.05);o(a+c),t||s(i-c)}this.min=i,this.max=a}getTickLimit(){const t=this.options.ticks;let{maxTicksLimit:r,stepSize:n}=t,i;return n?(i=Math.ceil(this.max/n)-Math.floor(this.min/n)+1,i>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${n} would result generating up to ${i} ticks. Limiting to 1000.`),i=1e3)):(i=this.computeTickLimit(),r=r||11),r&&(i=Math.min(r,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,r=t.ticks;let n=this.getTickLimit();n=Math.max(2,n);const i={maxTicks:n,bounds:t.bounds,min:t.min,max:t.max,precision:r.precision,step:r.stepSize,count:r.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:r.minRotation||0,includeBounds:r.includeBounds!==!1},a=this._range||this,s=Cne(i,a);return t.bounds==="ticks"&&wj(s,this,"value"),t.reverse?(s.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),s}configure(){const t=this.ticks;let r=this.min,n=this.max;if(super.configure(),this.options.offset&&t.length){const i=(n-r)/Math.max(t.length-1,1)/2;r-=i,n+=i}this._startValue=r,this._endValue=n,this._valueRange=n-r}getLabelForValue(t){return ig(t,this.chart.options.locale,this.options.ticks.format)}}class s4 extends bw{determineDataLimits(){const{min:t,max:r}=this.getMinMax(!0);this.min=En(t)?t:0,this.max=En(r)?r:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),r=t?this.width:this.height,n=oo(this.options.ticks.minRotation),i=(t?Math.sin(n):Math.cos(n))||.001,a=this._resolveTickFontOptions(0);return Math.ceil(r/Math.min(40,a.lineHeight/i))}getPixelForValue(t){return t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}}te(s4,"id","linear"),te(s4,"defaults",{ticks:{callback:$v.formatters.numeric}});const vg=e=>Math.floor(Au(e)),lh=(e,t)=>Math.pow(10,vg(e)+t);function bO(e){return e/Math.pow(10,vg(e))===1}function yO(e,t,r){const n=Math.pow(10,r),i=Math.floor(e/n);return Math.ceil(t/n)-i}function Tne(e,t){const r=t-e;let n=vg(r);for(;yO(e,t,n)>10;)n++;for(;yO(e,t,n)<10;)n--;return Math.min(n,vg(e))}function jne(e,{min:t,max:r}){t=Ja(e.min,t);const n=[],i=vg(t);let a=Tne(t,r),s=a<0?Math.pow(10,Math.abs(a)):1;const o=Math.pow(10,a),c=i>a?Math.pow(10,i):0,l=Math.round((t-c)*s)/s,u=Math.floor((t-c)/o/10)*o*10;let d=Math.floor((l-u)/Math.pow(10,a)),p=Ja(e.min,Math.round((c+u+d*Math.pow(10,a))*s)/s);for(;p<r;)n.push({value:p,major:bO(p),significand:d}),d>=10?d=d<15?15:20:d++,d>=20&&(a++,d=2,s=a>=0?1:s),p=Math.round((c+u+d*Math.pow(10,a))*s)/s;const w=Ja(e.max,p);return n.push({value:w,major:bO(w),significand:d}),n}class o4 extends oh{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._valueRange=0}parse(t,r){const n=bw.prototype.parse.apply(this,[t,r]);if(n===0){this._zero=!0;return}return En(n)&&n>0?n:null}determineDataLimits(){const{min:t,max:r}=this.getMinMax(!0);this.min=En(t)?Math.max(0,t):null,this.max=En(r)?Math.max(0,r):null,this.options.beginAtZero&&(this._zero=!0),this._zero&&this.min!==this._suggestedMin&&!En(this._userMin)&&(this.min=t===lh(this.min,0)?lh(this.min,-1):lh(this.min,0)),this.handleTickRangeOptions()}handleTickRangeOptions(){const{minDefined:t,maxDefined:r}=this.getUserBounds();let n=this.min,i=this.max;const a=o=>n=t?n:o,s=o=>i=r?i:o;n===i&&(n<=0?(a(1),s(10)):(a(lh(n,-1)),s(lh(i,1)))),n<=0&&a(lh(i,-1)),i<=0&&s(lh(n,1)),this.min=n,this.max=i}buildTicks(){const t=this.options,r={min:this._userMin,max:this._userMax},n=jne(r,this);return t.bounds==="ticks"&&wj(n,this,"value"),t.reverse?(n.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),n}getLabelForValue(t){return t===void 0?"0":ig(t,this.chart.options.locale,this.options.ticks.format)}configure(){const t=this.min;super.configure(),this._startValue=Au(t),this._valueRange=Au(this.max)-Au(t)}getPixelForValue(t){return(t===void 0||t===0)&&(t=this.min),t===null||isNaN(t)?NaN:this.getPixelForDecimal(t===this.min?0:(Au(t)-this._startValue)/this._valueRange)}getValueForPixel(t){const r=this.getDecimalForPixel(t);return Math.pow(10,this._startValue+r*this._valueRange)}}te(o4,"id","logarithmic"),te(o4,"defaults",{ticks:{callback:$v.formatters.logarithmic,major:{enabled:!0}}});function l4(e){const t=e.ticks;if(t.display&&e.display){const r=Hi(t.backdropPadding);return Jt(t.font&&t.font.size,un.font.size)+r.height}return 0}function Ine(e,t,r){return r=cn(r)?r:[r],{w:zQ(e,t.string,r),h:r.length*t.lineHeight}}function vO(e,t,r,n,i){return e===n||e===i?{start:t-r/2,end:t+r/2}:e<n||e>i?{start:t-r,end:t}:{start:t,end:t+r}}function One(e){const t={l:e.left+e._padding.left,r:e.right-e._padding.right,t:e.top+e._padding.top,b:e.bottom-e._padding.bottom},r=Object.assign({},t),n=[],i=[],a=e._pointLabels.length,s=e.options.pointLabels,o=s.centerPointLabels?rn/a:0;for(let c=0;c<a;c++){const l=s.setContext(e.getPointLabelContext(c));i[c]=l.padding;const u=e.getPointPosition(c,e.drawingArea+i[c],o),d=ii(l.font),p=Ine(e.ctx,d,e._pointLabels[c]);n[c]=p;const w=Qa(e.getIndexAngle(c)+o),O=Math.round(k5(w)),I=vO(O,u.x,p.w,0,180),R=vO(O,u.y,p.h,90,270);Bne(r,t,w,I,R)}e.setCenterPoint(t.l-r.l,r.r-t.r,t.t-r.t,r.b-t.b),e._pointLabelItems=Fne(e,n,i)}function Bne(e,t,r,n,i){const a=Math.abs(Math.sin(r)),s=Math.abs(Math.cos(r));let o=0,c=0;n.start<t.l?(o=(t.l-n.start)/a,e.l=Math.min(e.l,t.l-o)):n.end>t.r&&(o=(n.end-t.r)/a,e.r=Math.max(e.r,t.r+o)),i.start<t.t?(c=(t.t-i.start)/s,e.t=Math.min(e.t,t.t-c)):i.end>t.b&&(c=(i.end-t.b)/s,e.b=Math.max(e.b,t.b+c))}function Rne(e,t,r){const n=e.drawingArea,{extra:i,additionalAngle:a,padding:s,size:o}=r,c=e.getPointPosition(t,n+i+s,a),l=Math.round(k5(Qa(c.angle+Bn))),u=Lne(c.y,o.h,l),d=Pne(l),p=zne(c.x,o.w,d);return{visible:!0,x:c.x,y:u,textAlign:d,left:p,top:u,right:p+o.w,bottom:u+o.h}}function Nne(e,t){if(!t)return!0;const{left:r,top:n,right:i,bottom:a}=e;return!(uc({x:r,y:n},t)||uc({x:r,y:a},t)||uc({x:i,y:n},t)||uc({x:i,y:a},t))}function Fne(e,t,r){const n=[],i=e._pointLabels.length,a=e.options,{centerPointLabels:s,display:o}=a.pointLabels,c={extra:l4(a)/2,additionalAngle:s?rn/i:0};let l;for(let u=0;u<i;u++){c.padding=r[u],c.size=t[u];const d=Rne(e,u,c);n.push(d),o==="auto"&&(d.visible=Nne(d,l),d.visible&&(l=d))}return n}function Pne(e){return e===0||e===180?"center":e<180?"left":"right"}function zne(e,t,r){return r==="right"?e-=t:r==="center"&&(e-=t/2),e}function Lne(e,t,r){return r===90||r===270?e-=t/2:(r>270||r<90)&&(e-=t),e}function Dne(e,t,r){const{left:n,top:i,right:a,bottom:s}=r,{backdropColor:o}=t;if(!hr(o)){const c=th(t.borderRadius),l=Hi(t.backdropPadding);e.fillStyle=o;const u=n-l.left,d=i-l.top,p=a-n+l.width,w=s-i+l.height;Object.values(c).some(O=>O!==0)?(e.beginPath(),sg(e,{x:u,y:d,w:p,h:w,radius:c}),e.fill()):e.fillRect(u,d,p,w)}}function Une(e,t){const{ctx:r,options:{pointLabels:n}}=e;for(let i=t-1;i>=0;i--){const a=e._pointLabelItems[i];if(!a.visible)continue;const s=n.setContext(e.getPointLabelContext(i));Dne(r,s,a);const o=ii(s.font),{x:c,y:l,textAlign:u}=a;eh(r,e._pointLabels[i],c,l+o.lineHeight/2,o,{color:s.color,textAlign:u,textBaseline:"middle"})}}function wO(e,t,r,n){const{ctx:i}=e;if(r)i.arc(e.xCenter,e.yCenter,t,0,nn);else{let a=e.getPointPosition(0,t);i.moveTo(a.x,a.y);for(let s=1;s<n;s++)a=e.getPointPosition(s,t),i.lineTo(a.x,a.y)}}function qne(e,t,r,n,i){const a=e.ctx,s=t.circular,{color:o,lineWidth:c}=t;!s&&!n||!o||!c||r<0||(a.save(),a.strokeStyle=o,a.lineWidth=c,a.setLineDash(i.dash||[]),a.lineDashOffset=i.dashOffset,a.beginPath(),wO(e,r,s,n),a.closePath(),a.stroke(),a.restore())}function Vne(e,t,r){return Cu(e,{label:r,index:t,type:"pointLabel"})}class wg extends bw{constructor(t){super(t),this.xCenter=void 0,this.yCenter=void 0,this.drawingArea=void 0,this._pointLabels=[],this._pointLabelItems=[]}setDimensions(){const t=this._padding=Hi(l4(this.options)/2),r=this.width=this.maxWidth-t.width,n=this.height=this.maxHeight-t.height;this.xCenter=Math.floor(this.left+r/2+t.left),this.yCenter=Math.floor(this.top+n/2+t.top),this.drawingArea=Math.floor(Math.min(r,n)/2)}determineDataLimits(){const{min:t,max:r}=this.getMinMax(!1);this.min=En(t)&&!isNaN(t)?t:0,this.max=En(r)&&!isNaN(r)?r:0,this.handleTickRangeOptions()}computeTickLimit(){return Math.ceil(this.drawingArea/l4(this.options))}generateTickLabels(t){bw.prototype.generateTickLabels.call(this,t),this._pointLabels=this.getLabels().map((r,n)=>{const i=Wr(this.options.pointLabels.callback,[r,n],this);return i||i===0?i:""}).filter((r,n)=>this.chart.getDataVisibility(n))}fit(){const t=this.options;t.display&&t.pointLabels.display?One(this):this.setCenterPoint(0,0,0,0)}setCenterPoint(t,r,n,i){this.xCenter+=Math.floor((t-r)/2),this.yCenter+=Math.floor((n-i)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(t,r,n,i))}getIndexAngle(t){const r=nn/(this._pointLabels.length||1),n=this.options.startAngle||0;return Qa(t*r+oo(n))}getDistanceFromCenterForValue(t){if(hr(t))return NaN;const r=this.drawingArea/(this.max-this.min);return this.options.reverse?(this.max-t)*r:(t-this.min)*r}getValueForDistanceFromCenter(t){if(hr(t))return NaN;const r=t/(this.drawingArea/(this.max-this.min));return this.options.reverse?this.max-r:this.min+r}getPointLabelContext(t){const r=this._pointLabels||[];if(t>=0&&t<r.length){const n=r[t];return Vne(this.getContext(),t,n)}}getPointPosition(t,r,n=0){const i=this.getIndexAngle(t)-Bn+n;return{x:Math.cos(i)*r+this.xCenter,y:Math.sin(i)*r+this.yCenter,angle:i}}getPointPositionForValue(t,r){return this.getPointPosition(t,this.getDistanceFromCenterForValue(r))}getBasePosition(t){return this.getPointPositionForValue(t||0,this.getBaseValue())}getPointLabelPosition(t){const{left:r,top:n,right:i,bottom:a}=this._pointLabelItems[t];return{left:r,top:n,right:i,bottom:a}}drawBackground(){const{backgroundColor:t,grid:{circular:r}}=this.options;if(t){const n=this.ctx;n.save(),n.beginPath(),wO(this,this.getDistanceFromCenterForValue(this._endValue),r,this._pointLabels.length),n.closePath(),n.fillStyle=t,n.fill(),n.restore()}}drawGrid(){const t=this.ctx,r=this.options,{angleLines:n,grid:i,border:a}=r,s=this._pointLabels.length;let o,c,l;if(r.pointLabels.display&&Une(this,s),i.display&&this.ticks.forEach((u,d)=>{if(d!==0||d===0&&this.min<0){c=this.getDistanceFromCenterForValue(u.value);const p=this.getContext(d),w=i.setContext(p),O=a.setContext(p);qne(this,w,c,s,O)}}),n.display){for(t.save(),o=s-1;o>=0;o--){const u=n.setContext(this.getPointLabelContext(o)),{color:d,lineWidth:p}=u;!p||!d||(t.lineWidth=p,t.strokeStyle=d,t.setLineDash(u.borderDash),t.lineDashOffset=u.borderDashOffset,c=this.getDistanceFromCenterForValue(r.reverse?this.min:this.max),l=this.getPointPosition(o,c),t.beginPath(),t.moveTo(this.xCenter,this.yCenter),t.lineTo(l.x,l.y),t.stroke())}t.restore()}}drawBorder(){}drawLabels(){const t=this.ctx,r=this.options,n=r.ticks;if(!n.display)return;const i=this.getIndexAngle(0);let a,s;t.save(),t.translate(this.xCenter,this.yCenter),t.rotate(i),t.textAlign="center",t.textBaseline="middle",this.ticks.forEach((o,c)=>{if(c===0&&this.min>=0&&!r.reverse)return;const l=n.setContext(this.getContext(c)),u=ii(l.font);if(a=this.getDistanceFromCenterForValue(this.ticks[c].value),l.showLabelBackdrop){t.font=u.string,s=t.measureText(o.label).width,t.fillStyle=l.backdropColor;const d=Hi(l.backdropPadding);t.fillRect(-s/2-d.left,-a-u.size/2-d.top,s+d.width,u.size+d.height)}eh(t,o.label,0,-a,u,{color:l.color,strokeColor:l.textStrokeColor,strokeWidth:l.textStrokeWidth})}),t.restore()}drawTitle(){}}te(wg,"id","radialLinear"),te(wg,"defaults",{display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:!1},startAngle:0,ticks:{showLabelBackdrop:!0,callback:$v.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:!0,font:{size:10},callback(t){return t},padding:5,centerPointLabels:!1}}),te(wg,"defaultRoutes",{"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"}),te(wg,"descriptors",{angleLines:{_fallback:"grid"}});const yw={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Aa=Object.keys(yw);function xO(e,t){return e-t}function _O(e,t){if(hr(t))return null;const r=e._adapter,{parser:n,round:i,isoWeekday:a}=e._parseOpts;let s=t;return typeof n=="function"&&(s=n(s)),En(s)||(s=typeof n=="string"?r.parse(s,n):r.parse(s)),s===null?null:(i&&(s=i==="week"&&(o0(a)||a===!0)?r.startOf(s,"isoWeek",a):r.startOf(s,i)),+s)}function SO(e,t,r,n){const i=Aa.length;for(let a=Aa.indexOf(e);a<i-1;++a){const s=yw[Aa[a]],o=s.steps?s.steps:Number.MAX_SAFE_INTEGER;if(s.common&&Math.ceil((r-t)/(o*s.size))<=n)return Aa[a]}return Aa[i-1]}function Zne(e,t,r,n,i){for(let a=Aa.length-1;a>=Aa.indexOf(r);a--){const s=Aa[a];if(yw[s].common&&e._adapter.diff(i,n,s)>=t-1)return s}return Aa[r?Aa.indexOf(r):0]}function $ne(e){for(let t=Aa.indexOf(e)+1,r=Aa.length;t<r;++t)if(yw[Aa[t]].common)return Aa[t]}function kO(e,t,r){if(!r)e[t]=!0;else if(r.length){const{lo:n,hi:i}=M5(r,t),a=r[n]>=t?r[n]:r[i];e[a]=!0}}function Hne(e,t,r,n){const i=e._adapter,a=+i.startOf(t[0].value,n),s=t[t.length-1].value;let o,c;for(o=a;o<=s;o=+i.add(o,1,n))c=r[o],c>=0&&(t[c].major=!0);return t}function EO(e,t,r){const n=[],i={},a=t.length;let s,o;for(s=0;s<a;++s)o=t[s],i[o]=s,n.push({value:o,major:!1});return a===0||!r?n:Hne(e,n,i,r)}class xg extends oh{constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,r={}){const n=t.time||(t.time={}),i=this._adapter=new tte._date(t.adapters.date);i.init(r),Qm(n.displayFormats,i.formats()),this._parseOpts={parser:n.parser,round:n.round,isoWeekday:n.isoWeekday},super.init(t),this._normalized=r.normalized}parse(t,r){return t===void 0?null:_O(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const t=this.options,r=this._adapter,n=t.time.unit||"day";let{min:i,max:a,minDefined:s,maxDefined:o}=this.getUserBounds();function c(l){!s&&!isNaN(l.min)&&(i=Math.min(i,l.min)),!o&&!isNaN(l.max)&&(a=Math.max(a,l.max))}
17(!s||!o)&&(c(this._getLabelBounds()),(t.bounds!=="ticks"||t.ticks.source!=="labels")&&c(this.getMinMax(!1))),i=En(i)&&!isNaN(i)?i:+r.startOf(Date.now(),n),a=En(a)&&!isNaN(a)?a:+r.endOf(Date.now(),n)+1,this.min=Math.min(i,a-1),this.max=Math.max(i+1,a)}_getLabelBounds(){const t=this.getLabelTimestamps();let r=Number.POSITIVE_INFINITY,n=Number.NEGATIVE_INFINITY;return t.length&&(r=t[0],n=t[t.length-1]),{min:r,max:n}}buildTicks(){const t=this.options,r=t.time,n=t.ticks,i=n.source==="labels"?this.getLabelTimestamps():this._generate();t.bounds==="ticks"&&i.length&&(this.min=this._userMin||i[0],this.max=this._userMax||i[i.length-1]);const a=this.min,s=this.max,o=EQ(i,a,s);return this._unit=r.unit||(n.autoSkip?SO(r.minUnit,this.min,this.max,this._getLabelCapacity(a)):Zne(this,o.length,r.minUnit,this.min,this.max)),this._majorUnit=!n.major.enabled||this._unit==="year"?void 0:$ne(this._unit),this.initOffsets(i),t.reverse&&o.reverse(),EO(this,o,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(t=>+t.value))}initOffsets(t=[]){let r=0,n=0,i,a;this.options.offset&&t.length&&(i=this.getDecimalForValue(t[0]),t.length===1?r=1-i:r=(this.getDecimalForValue(t[1])-i)/2,a=this.getDecimalForValue(t[t.length-1]),t.length===1?n=a:n=(a-this.getDecimalForValue(t[t.length-2]))/2);const s=t.length<3?.5:.25;r=mi(r,0,s),n=mi(n,0,s),this._offsets={start:r,end:n,factor:1/(r+1+n)}}_generate(){const t=this._adapter,r=this.min,n=this.max,i=this.options,a=i.time,s=a.unit||SO(a.minUnit,r,n,this._getLabelCapacity(r)),o=Jt(i.ticks.stepSize,1),c=s==="week"?a.isoWeekday:!1,l=o0(c)||c===!0,u={};let d=r,p,w;if(l&&(d=+t.startOf(d,"isoWeek",c)),d=+t.startOf(d,l?"day":s),t.diff(n,r,s)>1e5*o)throw new Error(r+" and "+n+" are too far apart with stepSize of "+o+" "+s);const O=i.ticks.source==="data"&&this.getDataTimestamps();for(p=d,w=0;p<n;p=+t.add(p,o,s),w++)kO(u,p,O);return(p===n||i.bounds==="ticks"||w===1)&&kO(u,p,O),Object.keys(u).sort(xO).map(I=>+I)}getLabelForValue(t){const r=this._adapter,n=this.options.time;return n.tooltipFormat?r.format(t,n.tooltipFormat):r.format(t,n.displayFormats.datetime)}format(t,r){const n=this.options.time.displayFormats,i=this._unit,a=r||n[i];return this._adapter.format(t,a)}_tickFormatFunction(t,r,n,i){const a=this.options,s=a.ticks.callback;if(s)return Wr(s,[t,r,n],this);const o=a.time.displayFormats,c=this._unit,l=this._majorUnit,u=c&&o[c],d=l&&o[l],p=n[r],w=l&&d&&p&&p.major;return this._adapter.format(t,i||(w?d:u))}generateTickLabels(t){let r,n,i;for(r=0,n=t.length;r<n;++r)i=t[r],i.label=this._tickFormatFunction(i.value,r,t)}getDecimalForValue(t){return t===null?NaN:(t-this.min)/(this.max-this.min)}getPixelForValue(t){const r=this._offsets,n=this.getDecimalForValue(t);return this.getPixelForDecimal((r.start+n)*r.factor)}getValueForPixel(t){const r=this._offsets,n=this.getDecimalForPixel(t)/r.factor-r.end;return this.min+n*(this.max-this.min)}_getLabelSize(t){const r=this.options.ticks,n=this.ctx.measureText(t).width,i=oo(this.isHorizontal()?r.maxRotation:r.minRotation),a=Math.cos(i),s=Math.sin(i),o=this._resolveTickFontOptions(0).size;return{w:n*a+o*s,h:n*s+o*a}}_getLabelCapacity(t){const r=this.options.time,n=r.displayFormats,i=n[r.unit]||n.millisecond,a=this._tickFormatFunction(t,0,EO(this,[t],this._majorUnit),i),s=this._getLabelSize(a),o=Math.floor(this.isHorizontal()?this.width/s.w:this.height/s.h)-1;return o>0?o:1}getDataTimestamps(){let t=this._cache.data||[],r,n;if(t.length)return t;const i=this.getMatchingVisibleMetas();if(this._normalized&&i.length)return this._cache.data=i[0].controller.getAllParsedValues(this);for(r=0,n=i.length;r<n;++r)t=t.concat(i[r].controller.getAllParsedValues(this));return this._cache.data=this.normalize(t)}getLabelTimestamps(){const t=this._cache.labels||[];let r,n;if(t.length)return t;const i=this.getLabels();for(r=0,n=i.length;r<n;++r)t.push(_O(this,i[r]));return this._cache.labels=this._normalized?t:this.normalize(t)}normalize(t){return Ej(t.sort(xO))}}te(xg,"id","time"),te(xg,"defaults",{bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",callback:!1,major:{enabled:!1}}});function vw(e,t,r){let n=0,i=e.length-1,a,s,o,c;r?(t>=e[n].pos&&t<=e[i].pos&&({lo:n,hi:i}=cc(e,"pos",t)),{pos:a,time:o}=e[n],{pos:s,time:c}=e[i]):(t>=e[n].time&&t<=e[i].time&&({lo:n,hi:i}=cc(e,"time",t)),{time:a,pos:o}=e[n],{time:s,pos:c}=e[i]);const l=s-a;return l?o+(c-o)*(t-a)/l:o}class c4 extends xg{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),r=this._table=this.buildLookupTable(t);this._minPos=vw(r,this.min),this._tableRange=vw(r,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:r,max:n}=this,i=[],a=[];let s,o,c,l,u;for(s=0,o=t.length;s<o;++s)l=t[s],l>=r&&l<=n&&i.push(l);if(i.length<2)return[{time:r,pos:0},{time:n,pos:1}];for(s=0,o=i.length;s<o;++s)u=i[s+1],c=i[s-1],l=i[s],Math.round((u+c)/2)!==l&&a.push({time:l,pos:s/(o-1)});return a}_generate(){const t=this.min,r=this.max;let n=super.getDataTimestamps();return(!n.includes(t)||!n.length)&&n.splice(0,0,t),(!n.includes(r)||n.length===1)&&n.push(r),n.sort((i,a)=>i-a)}_getTimestampsForTable(){let t=this._cache.all||[];if(t.length)return t;const r=this.getDataTimestamps(),n=this.getLabelTimestamps();return r.length&&n.length?t=this.normalize(r.concat(n)):t=r.length?r:n,t=this._cache.all=t,t}getDecimalForValue(t){return(vw(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){const r=this._offsets,n=this.getDecimalForPixel(t)/r.factor-r.end;return vw(this._table,n*this._tableRange+this._minPos,!0)}}te(c4,"id","timeseries"),te(c4,"defaults",xg.defaults);var Wne=Object.freeze({__proto__:null,CategoryScale:a4,LinearScale:s4,LogarithmicScale:o4,RadialLinearScale:wg,TimeScale:xg,TimeSeriesScale:c4});const Kne=[ete,Tre,kne,Wne];function MO(e,t=18){if(!e)return"";let r=e.toString();const n=r.startsWith("-");n&&(r=r.slice(1)),r=r.padStart(t,"0");let[i,a]=[r.slice(0,r.length-t),r.slice(r.length-t)];return a=a.replace(/(0+)$/,""),`${n?"-":""}${i||"0"}${a?`.${a}`:""}`}const Gne={"bg-brand-green/10":"border-brand-green/30","bg-brand-purple/10":"border-brand-purple/30","bg-brand-orange/10":"border-brand-orange/30","bg-brand-blue/10":"border-brand-blue/30","bg-brand-yellow/10":"border-brand-yellow/30","bg-brand-pink/10":"border-brand-pink/30","bg-brand-red/10":"border-brand-red/30"},_g=({icon:e,iconColor:t="bg-brand-green/10",value:r,suffix:n,unit:i,label:a,isLoading:s=!1,onClick:o,className:c})=>{const l=Gne[t]||"border-surface-border";return M.jsxs("div",{onClick:o,className:mt("flex items-center gap-3 p-4 bg-surface-card/50 border border-surface-border rounded-xl transition-colors",o&&"cursor-pointer hover:bg-surface-hover",c),children:[M.jsx("div",{className:mt("h-10 w-10 flex items-center justify-center rounded-lg border",t,l),children:e}),M.jsxs("div",{className:"flex flex-col",children:[M.jsx("div",{className:"flex items-baseline gap-1",children:s?M.jsx(Qr,{className:"!h-6 !w-16"}):M.jsxs(M.Fragment,{children:[M.jsx("span",{className:"text-2xl font-bold text-text-primary",children:r}),n&&M.jsx("span",{className:"text-sm font-light text-text-primary",children:n}),i&&M.jsx("span",{className:"text-xs text-text-muted ml-1",children:i})]})}),M.jsx("div",{className:"text-[11px] text-text-muted uppercase tracking-wide",children:a})]})]})},AO={none:"rounded-none",soft:"rounded-lg",medium:"rounded-xl",full:"rounded-full"},CO={xs:"p-0.5 gap-0.5",sm:"p-0.5 gap-0.5",md:"p-1 gap-1",lg:"p-1.5 gap-1.5"},Sg=({items:e=[],activeKey:t,onChange:r,size:n="md",className:i,transparent:a=!1,roundness:s="medium",border:o=!0})=>M.jsx("div",{className:mt("flex items-center backdrop-blur-sm",AO[s]||AO.medium,CO[n]||CO.md,a?"bg-transparent":"bg-surface-card",o&&"border border-surface-border",i),children:e.map(c=>{const l=t===c.key,u=()=>{c.onClick?c.onClick(c.key):r&&r(c.key)};return M.jsx(St,{to:c.to,onClick:c.to?void 0:u,variant:"ghost",size:n,roundness:s,iconBefore:c.icon,className:mt(l?"bg-surface-border text-text-primary":"text-text-muted"),children:c.label},c.key)})});dc.register(...Kne);const u4=e=>e?e>=1e6?{value:(e/1e6).toFixed(1).replace(/\.0$/,""),suffix:"M"}:e>=1e3?{value:(e/1e3).toFixed(1).replace(/\.0$/,""),suffix:"k"}:{value:e.toString(),suffix:""}:{value:"-",suffix:""},Yne=[{key:"blockTime",label:"Block Time"},{key:"transactions",label:"Transactions"},{key:"gas",label:"Gas"},{key:"contracts",label:"Contracts"},{key:"classes",label:"Classes"}],Xne={blockTime:Xa.brand.green,transactions:Xa.brand.orange,gas:Xa.brand.purple,contracts:Xa.brand.blue,classes:Xa.brand.yellow},Jne=()=>{var j,N;const{network:e}=di(),t=he.useRef(null),r=he.useRef(null),n=he.useRef(null),[i,a]=he.useState("blockTime"),[s,o]=he.useState({width:0,height:0}),{data:c,isLoading:l}=Vn({queryKey:["stats",e],queryFn:()=>bY(e)}),u=(j=c==null?void 0:c.latestStats)==null?void 0:j[0],d=c,p=(()=>
17{if(!(c!=null&&c.latestStats)||c.latestStats.length===0)return{};const P={avgBlockTime:{},avgTxFee:{},txCount:{},accountCount:{},contractClassCount:{}};return[...c.latestStats].reverse().forEach(Z=>{P.avgBlockTime[Z.date]=Z.avgBlockTime,P.avgTxFee[Z.date]=Z.avgTxFee,P.txCount[Z.date]=Z.txCount,P.accountCount[Z.date]=Z.accountCount,P.contractClassCount[Z.date]=Z.contractClassCount}),P})();he.useEffect(()=>{if(!n.current)return;const P=new ResizeObserver(Z=>{const{width:X,height:re}=Z[0].contentRect;o({width:X,height:re})});return P.observe(n.current),()=>{P.disconnect()}},[n]),he.useEffect(()=>{if(!t.current||!p||Object.keys(p).length===0)return;r.current&&r.current.destroy();const P={blockTime:"avgBlockTime",transactions:"txCount",gas:"avgTxFee",contracts:"accountCount",classes:"contractClassCount"}[i],Z=p[P];if(!Z||Object.keys(Z).length===0)return;const X=Object.keys(Z);let re=Object.values(Z);const ne=X.map(T=>new Date(T).toLocaleDateString("en-US",{month:"short",day:"numeric"})),ae=Xne[i]||Xa.brand.green;i==="gas"&&(re=re.map(T=>parseFloat(MO(Math.round(T||0).toString(),9))));const ue=Math.min(...re),m=Math.max(...re),A=m-ue||1,f=t.current.getContext("2d"),g=s.height||300,_=f.createLinearGradient(0,0,0,g);_.addColorStop(0,ae+"40"),_.addColorStop(1,ae+"00");const B={blockTime:"Block Time (s)",transactions:"Transactions",gas:"Gas (gFJ)",contracts:"Contracts",classes:"Classes"};return r.current=new dc(f,{type:"line",data:{labels:ne,datasets:[{label:B[i],data:re,borderColor:ae,borderWidth:2,pointBackgroun
17dColor:ae,pointRadius:0,pointHoverRadius:4,tension:.4,fill:!0,backgroundColor:_}]},options:{responsive:!0,maintainAspectRatio:!1,interaction:{intersect:!1,mode:"index"},plugins:{legend:{display:!1},tooltip:{backgroundColor:Xa.chart.tooltipBg,titleColor:Xa.chart.white,bodyColor:Xa.chart.white,borderColor:Xa.chart.tooltipBorder,borderWidth:1,cornerRadius:8,padding:12,callbacks:{label:function(T){let S=T.dataset.label||"";return S&&(S+=": "),T.parsed.y!==null&&(i==="blockTime"?S+=T.parsed.y.toFixed(1)+"s":i==="gas"?S+=T.parsed.y.toFixed(2)+" gFJ":S+=T.parsed.y.toLocaleString()),S}}}},scales:{x:{grid:{display:!1},border:{display:!1},ticks:{color:Xa.text.mutedAlpha50,font:{size:11},maxRotation:0}},y:{position:"left",beginAtZero:!1,border:{display:!1},grid:{display:!1},min:Math.max(0,ue-A*.2),max:m+A*.2,ticks:{color:Xa.text.mutedAlpha50,font:{size:11},callback:function(T){return i==="blockTime"?Math.round(T):i==="gas"?T.toFixed(1):T.toLocaleString()}}}}}}),()=>{r.current&&r.current.destroy()}},[t,p,i,s]);const w={value:((N=u==null?void 0:u.avgBlockTime)==null?void 0:N.toFixed(1))||"-",suffix:"s"},O=u4(d==null?void 0:d.totalTxCount),I=u4(d==null?void 0:d.totalContractCount),R=u4(d==null?void 0:d.totalContractClassCount),C={value:u!=null&&u.avgTxFee?parseFloat(MO(Math.round(u.avgTxFee).toString(),9)).toFixed(2):"-",suffix:"",unit:"gF"};return M.jsxs("div",{className:"flex w-full below-lg:flex-col h-[400px] below-lg:h-auto",children:[M.jsxs("div",{className:"flex-1 bg-surface-card/50 border border-surface-border rounded-l-xl p-5 flex flex-col h-full border-t-brand-green/20 below-lg:rounded-b-none",children:[M.jsxs("div",{className:"flex below-mobile:flex-col below-mobile:gap-3 items-center justify-between mb-4",children:[M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx(VW,{className:"w-5 h-5 text-brand-green"}),M.jsx("div",{className:"text-sm font-bold text-text-primary uppercase tracking-wide",children:"Network Activity"})]}),M.jsx(Sg,{items:Yne,activeKey:i,onChange:a,size:"sm",roundness:""})]}),M.jsx("div",{ref:n,className:"flex-1 min-h-[300px]",children:l||!(c!=null&&c.latestStats)||c.latestStats.length===0?M.jsx("div",{className:"h-full w-full flex items-center justify-center",children:M.jsx(Qr,{className:"!h-full !w-full"})}):M.jsx("canvas",{ref:t,className:"w-full h-full"})})]}),M.jsxs("div",{className:"flex flex-col gap-0 w-[280px] below-lg:w-full below-lg:flex-row below-lg:flex-wrap h-full min-h-0",children:[M.jsx(_g,{icon:M.jsx(Fm,{className:"w-5 h-5 text-brand-green"}),iconColor:"bg-brand-green/10",value:w.value,suffix:w.suffix,label:"Avg Block Time",isLoading:l,onClick:()=>a("blockTime"),className:"flex-1 min-h-0 rounded-l-none rounded-br-none below-lg:rounded-tr-none below-lg:rounded-bl-xl border-l-0 below-lg:border-l border-t-brand-green/20 below-lg:border-t-0"}),M.jsx(_g,{icon:M.jsx(Wd,{className:"w-5 h-5 text-brand-orange"}),iconColor:"bg-brand-orange/10",value:O.value,suffix:O.suffix,label:"Total TXs",isLoading:l,onClick:()=>a("transactions"),className:"flex-1 min-h-0 rounded-none border-l-0 border-t-0"}),M.jsx(_g,{icon:M.jsx(Nm,{className:"w-5 h-5 text-brand-blue"}),iconColor:"bg-brand-blue/10",value:I.value,suffix:I.suffix,label:"Active Contracts",isLoading:l,onClick:()=>a("contracts"),className:"flex-1 min-h-0 rounded-none border-l-0 border-t-0"}),M.jsx(_g,{icon:M.jsx(hv,{className:"w-5 h-5 text-brand-yellow"}),iconColor:"bg-brand-yellow/10",value:R.value,suffix:R.suffix,label:"Total Classes",isLoading:l,onClick:()=>a("classes"),className:"flex-1 min-h-0 rounded-none border-l-0 border-t-0"}),M.jsx(_g,{icon:M.jsx(K7,{className:"w-5 h-5 text-brand-purple"}),iconColor:"bg-brand-purple/10",value:C.value,suffix:C.suffix,unit:C.unit,label:"Gas Tracker",isLoading:l,onClick:()=>a("gas"),className:"flex-1 min-h-0 rounded-l-none rounded-tr-none border-l-0 border-t-0"})]})]})},Qne=({texts:e=[],className:t,morphTime:r=1,cooldownTime:n=.25})=>{const i=he.useRef(null),a=he.useRef(null),s=he.useRef(null),o=he.useRef({textIndex:e.length-1,time:new Date,morph:0,cooldown:n}),c=he.useCallback(w=>{const O=i.current,I=a.current;if(!O||!I)return;const{textIndex:R}=o.current;I.style.filter=`blur(${Math.min(8/w-8,100)}px)`,I.style.opacity=`${Math.pow(w,.4)*100}%`;const C=1-w;O.style.filter=`blur(${Math.min(8/C-8,100)}px)`,O.style.opacity=`${Math.pow(C,.4)*100}%`,O.textContent=e[R%e.length],I.textContent=e[(R+1)%e.length]},[e]),l=he.useCallback(()=>{const w=o.current;w.morph-=w.cooldown,w.cooldown=0;let O=w.morph/r;O>1&&(w.cooldown=n,O=1),c(O)},[r,n,c]),u=he.useCallback(()=>{const w=i.current,O=a.current;!w||!O||(o.current.morph=0,O.style.filter="",O.style.opacity="100%",w.style.filter="",w.style.opacity="0%")},[]),d=he.useCallback(()=>{s.current=requestAnimationFrame(d);const w=o.current,O=new Date,I=w.cooldown>0,R=(O-w.time)/1e3;
17w.time=O,w.cooldown-=R,w.cooldown<=0?(I&&w.textIndex++,l()):u()},[l,u]);if(he.useEffect(()=>{if(e.length===0)return;const w=i.current,O=a.current;if(w&&O){const{textIndex:I}=o.current;w.textContent=e[I%e.length],O.textContent=e[(I+1)%e.length]}return d(),()=>{s.current&&cancelAnimationFrame(s.current)}},[e,d]),e.length===0)return null;const p=e.reduce((w,O)=>w.length>O.length?w:O,"");return M.jsxs(M.Fragment,{children:[M.jsxs("div",{className:mt("relative inline-block",t),style:{filter:"url(#threshold) blur(0.6px)"},children:[M.jsx("div",{ref:i,className:mt("absolute left-0 top-0 inline-block text-left select-none whitespace-nowrap",t)}),M.jsx("div",{ref:a,className:mt("absolute left-0 top-0 inline-block text-left select-none whitespace-nowrap",t)}),M.jsx("div",{className:"invisible whitespace-nowrap",children:p})]}),M.jsx("svg",{className:"absolute w-0 h-0",children:M.jsx("defs",{children:M.jsx("filter",{id:"threshold",x:"-50%",y:"-50%",width:"200%",height:"200%",children:M.jsx("feColorMatrix",{in:"SourceGraphic",type:"matrix",values:`1 0 0 0 0
18                      0 1 0 0 0
19                      0 0 1 0 0
20                      0 0 0 255 -140`})})})})]})},eie=()=>{const[e,t]=he.useState([]),r=n=>{t(i=>i.includes(n)?i.filter(a=>a!==n):[...i,n])};return M.jsxs(M.Fragment,{children:[M.jsx(Ms,{route:"/"}),M.jsxs("div",{className:"relative w-full flex flex-col",children:[M.jsx("div",{className:"flex items-center justify-center gap-8 py-12 below-lg:flex-col",children:M.jsxs("div",{className:"flex flex-col items-center justify-center gap-6 flex-1 max-w-[650px]",children:[M.jsxs("div",{className:"flex items-center gap-2 px-3 py-1.5 bg-surface-card border border-surface-border rounded-full w-fit",children:[M.jsx("span",{className:"w-2 h-2 bg-brand-green rounded-full animate-pulse"}),M.jsx("span",{className:"text-[10px] font-medium text-text-muted uppercase tracking-wide",children:"AZTEC NETWORK LIVE"})]}),M.jsxs("div",{className:"flex items-center justify-center gap-3 below-mobile:gap-2",children:[M.jsx("h1",{className:"text-6xl font-bold text-text-primary below-lg:text-5xl below-mobile:text-4xl",children:"Explore"}),M.jsx(Qne,{texts:["Aztec","Blocks","Contracts","Classes","Privacy","Nullifiers","Security","Logs","Nullifiers","Accounts"],morphTime:1,cooldownTime:.5,className:"text-6xl font-bold below-lg:text-5xl below-mobile:text-4xl bg-gradient-to-r from-brand-purple via-brand-blue to-brand-pink bg-[length:200%_auto] animate-gradient-x bg-clip-text text-transparent"})]}),M.jsx("p",{className:"text-text-muted text-md below-mobile:text-base text-center px-10",children:"Decode the private universe. Search transactions, blocks, and zero-knowledge proofs with Aztec Explorer."}),M.jsx(b5,{height:"lg",className:"max-w-full",activeFilters:e,onFiltersChange:t,showFiltersInDropdown:!1}),M.jsxs("div",{className:"flex flex-row below-mobile:flex-col items-center  justify-center gap-2 w-full below-mobile:w-full",children:[M.jsx("span",{className:"text-[10px] text-text-muted uppercase tracking-wide",children:"Quick Filters:"}),M.jsx("div",{className:"flex items-center gap-2 flex-wrap justify-center",children:Object.entries(_u).map(([n,i])=>{const a=i.icon,s=e.includes(n);return M.jsx(St,{onClick:()=>r(n),variant:s?"purple":"gray",size:"sm",roundness:"full",iconBefore:M.jsx(a,{className:"w-3.5 h-3.5"}),children:i.label},n)})})]})]})}),M.jsx("div",{className:"py-8",children:M.jsx(Jne,{})}),M.jsxs("div",{className:"flex justify-between gap-[2vw] py-[44px] w-full below-lg:flex-col below-mobile:gap-10",children:[M.jsx(kJ,{}),M.jsx(EJ,{})]})]})]})},tie=e=>{if(!e)return"";const t=e.split(","),r=[];return t.forEach((n,i)=>{const a=n.trim();if(a){const s=a.substring(0,66),o=a.length>66?`0x${a.substring(66)}`:"";s&&o&&r.push(`${i+1}: Slot: ${s}
21Value: ${o}`)}}),r.join(`
22
23`)},rie=Av("flex border",{variants:{variant:{elevated:"flex-col bg-surface-card border-brand-purple text-text-primary rounded-2xl gap-[10px]",flat:"flex-col bg-surface-card border-surface-border text-text-primary rounded-2xl",card:"justify-between items-center w-full text-[12px] border-surface-border"},padding:{none:"",sm:"",default:"",lg:""}},compoundVariants:[{variant:"elevated",padding:"sm",className:"p-3"},{variant:"elevated",padding:"default",className:"px-[29px] py-[35px]"},{variant:"elevated",padding:"lg",className:"px-[35px] py-[40px]"},{variant:"flat",padding:"sm",className:"p-2"},{variant:"flat",padding:"default",className:"p-4"},{variant:"flat",padding:"lg",className:"p-8"},{variant:"card",padding:"sm",className:"p-2"},{variant:"card",padding:"default",className:"px-[15px] py-[7px]"},{variant:"card",padding:"lg",className:"p-8"}],defaultVariants:{variant:"flat",padding:"default"}}),ch=({variant:e="flat",padding:t="default",rounded:r,className:n,children:i,...a})=>M.jsx("div",{className:mt(rie({variant:e,padding:t}),r,n),...a,children:i}),nie=e=>e.startsWith("/block/")?"Block":e.startsWith("/tx/")?"Transaction":e.startsWith("/address/")?"Address":e.startsWith("/class/")?"Class":"Unknown",iie=64,aie=64,sie=({existingTag:e,onSave:t,onCancel:r,onRemove:n,position:i})=>{const[a,s]=he.useState((e==null?void 0:e.tag)||""),[o,c]=he.useState((e==null?void 0:e.description)||""),[l,u]=he.useState(""),d=he.useRef(null);he.useEffect(()=>{var R;(R=d.current)==null||R.focus()},[]);const p=()=>
23{if(!a.trim()&&!o.trim()){u("Enter a tag or description");return}t({tag:a.trim()||null,description:o.trim()||null})},w=R=>{R.key==="Enter"&&!R.shiftKey?(R.preventDefault(),p()):R.key==="Escape"&&r()},O=R=>{const C=R.target.value;C.length<=iie&&(s(C),u(""))},I=R=>{const C=R.target.value;C.length<=aie&&(c(C),u(""))};return jm.createPortal(M.jsxs("div",{className:"fixed z-[9999] p-2 bg-surface-card border border-surface-border rounded-lg shadow-xl",style:{top:i.top,left:i.left},onClick:R=>R.stopPropagation(),children:[M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx(Vr,{ref:d,value:a,onChange:O,onKeyDown:w,placeholder:"Tag",height:"sm",roundness:"soft",error:!!l&&!a.trim()&&!o.trim(),className:"!w-[120px] !text-xs"}),M.jsx(Vr,{value:o,onChange:I,onKeyDown:w,placeholder:"Description",height:"sm",roundness:"soft",error:!!l&&!a.trim()&&!o.trim(),className:"!w-[140px] !text-xs"}),M.jsxs("div",{className:"flex items-center gap-1",children:[M.jsx("button",{onClick:p,className:"p-1.5 rounded-md text-brand-green hover:bg-brand-green/10 transition-colors",title:"Save",children:M.jsx(Rm,{className:"w-4 h-4"})}),M.jsx("button",{onClick:r,className:"p-1.5 rounded-md text-text-muted hover:bg-surface-hover hover:text-text-primary transition-colors",title:"Cancel",children:M.jsx(Hd,{className:"w-4 h-4"})}),e&&M.jsx("button",{onClick:n,className:"p-1.5 rounded-md text-brand-red hover:bg-brand-red/10 transition-colors",title:"Remove tag",children:M.jsx(mv,{className:"w-4 h-4"})})]})]}),l&&M.jsx("p",{className:"text-[10px] text-brand-red mt-1 ml-1",children:l})]}),document.body)},oie=({originalValue:e,tagData:t,position:r})=>jm.createPortal(M.jsxs("div",{className:"fixed z-[9999] p-2 bg-surface-card border border-surface-border rounded-lg shadow-xl w-[280px]",style:{top:r.top,left:r.left,transform:r.anchorBottom?"translateY(-100%)":"none"},onClick:n=>n.stopPropagation(),children:[t.tag&&M.jsxs("div",{className:"mb-1.5",children:[M.jsx("span",{className:"text-[10px] text-text-muted",children:"Original:"}),M.jsx("p",{className:"text-[11px] font-mono text-text-primary break-all",children:e})]}),t.description&&M.jsxs("div",{children:[M.jsx("span",{className:"text-[10px] text-text-muted",children:"Note:"}),M.jsx("p",{className:"text-xs text-text-primary break-words whitespace-pre-wrap",children:t.description})]})]}),document.body),lie=({value:e,fieldLabel:t="Unknown",children:r,className:n,disabled:i=!1})=>{const a=to(),{getTag:s,setTag:o,removeTag:c,settings:l}=a0(),[u,d]=he.useState(!1),[p,w]=he.useState(!1),[O,I]=he.useState(!1),[R,C]=he.useState({top:0,left:0}),[j,N]=he.useState({top:0,left:0,anchorBottom:!0}),P=he.useRef(null),Z=he.useRef(null),X=s(e),re=!!X,ne=he.useCallback(()=>{if(!P.current)return{top:0,left:0};const _=P.current.getBoundingClientRect(),B=60,T=380;let S=_.bottom+8,h=_.left;return S+B>window.innerHeight&&(S=_.top-B-8),h+T>window.innerWidth&&(h=window.innerWidth-T-16),h<16&&(h=16),{top:S,left:h}},[]),ae=he.useCallback(()=>{if(!P.current)return{top:0,left:0};const _=P.current.getBoundingClientRect(),B=280,T=12;let S=_.top-T,h=_.left,x=!0;return _.top<120&&(S=_.bottom+T,x=!1),h+B>window.innerWidth&&(h=window.innerWidth-B-16),h<16&&(h=16),{top:S,left:h,anchorBottom:x}},[]);he.useEffect(()=>{const _=B=>{if(P.current&&!P.current.contains(B.target)){const T=document.querySelectorAll('[class*="fixed z-[9999]"]');let S=!1;T.forEach(h=>{h.contains(B.target)&&(S=!0)}),S||w(!1)}};if(p)return document.addEventListener("mousedown",_),()=>document.removeEventListener("mousedown",_)},[p]);const ue=()=>{l.allowHoverEffects&&(d(!0),re&&!p&&l.displayNotePopovers&&(Z.current=setTimeout(()=>{N(ae()),I(!0)},300)))},m=()=>{d(!1),Z.current&&clearTimeout(Z.current),I(!1)},A=_=>{_.preventDefault(),_.stopPropagation(),C(ne()),w(!0),I(!1)},f=_=>{o(e,{..._,fieldLabel:t,pageType:nie(a.pathname),pagePath:a.pathname}),w(!1),d(!1)},g=()=>{c(e),w(!1),d(!1)};return i?M.jsx(M.Fragment,{children:r}):M.jsxs("div",{ref:P,className:mt("relative inline-flex items-center group/taggable",n),onMouseEnter:ue,onMouseLeave:m,children:[M.jsxs("div",{className:mt("relative transition-all duration-150 outline-dashed outline-1 outline-transparent roun
23ded-sm px-1",u&&!p&&" outline-1 outline-dashed outline-offset-2",u&&!re&&"outline-text-muted/50",u&&re&&"outline-brand-purple/50",re&&"text-brand-purple"),children:[r,re&&!u&&M.jsx("div",{className:"absolute -top-0 -right-2 w-1.5 h-1.5 bg-brand-purple rounded-full"})]}),u&&!p&&M.jsx("button",{onClick:A,className:"absolute -top-5 -left-5 p-2 group/btn",children:M.jsx("div",{className:mt("p-0.5 rounded-full transition-all duration-150","bg-surface-card border border-surface-border shadow-sm","group-hover/btn:bg-brand-purple group-hover/btn:border-brand-purple group-hover/btn:text-white",re?"text-brand-purple":"text-text-muted"),children:re?M.jsx(x6,{className:"w-3 h-3"}):M.jsx(fv,{className:"w-3 h-3"})})}),p&&M.jsx(sie,{existingTag:X,onSave:f,onCancel:()=>w(!1),onRemove:g,position:R}),O&&re&&!p&&M.jsx(oie,{originalValue:e,tagData:X,position:j})]})},cie=({value:e,fieldLabel:t="Unknown",children:r,className:n})=>{const{getTag:i,settings:a}=a0(),s=i(e),o=s!=null&&s.tag&&a.displayTagsInsteadOfValues?M.jsx("span",{className:"text-brand-purple font-medium",children:s.tag}):r;return M.jsx(lie,{value:e,fieldLabel:t,className:n,children:o})},uie=e=>e.startsWith("/block/")?"Block":e.startsWith("/tx/")?"Transaction":e.startsWith("/address/")?"Address":e.startsWith("/class/")?"Class":"Unknown",fie=64,hie=64,die=({existingTag:e,onSave:t,onCancel:r,onRemove:n,position:i})=>{const[a,s]=he.useState((e==null?void 0:e.tag)||""),[o,c]=he.useState((e==null?void 0:e.description)||""),[l,u]=he.useState(""),d=he.useRef(null);he.useEffect(()=>{var R;(R=d.current)==null||R.focus()},[]);const p=()=>{if(!a.trim()&&!o.trim()){u("Enter a tag or description");return}t({tag:a.trim()||null,description:o.trim()||null})},w=R=>{R.key==="Enter"&&!R.shiftKey?(R.preventDefault(),p()):R.key==="Escape"&&r()},O=R=>{const C=R.target.value;C.length<=fie&&(s(C),u(""))},I=R=>{const C=R.target.value;C.length<=hie&&(c(C),u(""))};return jm.createPortal(M.jsxs("div",{className:"fixed z-[9999] p-2 bg-surface-card border border-surface-border rounded-lg shadow-xl",style:{top:i.top,left:i.left},onClick:R=>R.stopPropagation(),children:[M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx(Vr,{ref:d,value:a,onChange:O,onKeyDown:w,placeholder:"Tag",height:"sm",roundness:"soft",error:!!l&&!a.trim()&&!o.trim(),className:"!w-[120px] !text-xs"}),M.jsx(Vr,{value:o,onChange:I,onKeyDown:w,placeholder:"Description",height:"sm",roundness:"soft",error:!!l&&!a.trim()&&!o.trim(),className:"!w-[140px] !text-xs"}),M.jsxs("div",{className:"flex items-center gap-1",children:[M.jsx("button",{onClick:p,className:"p-1.5 rounded-md text-brand-green hover:bg-brand-green/10 transition-colors",title:"Save",children:M.jsx(Rm,{className:"w-4 h-4"})}),M.jsx("button",{onClick:r,className:"p-1.5 rounded-md text-text-muted hover:bg-surface-hover hover:text-text-primary transition-colors",title:"Cancel",children:M.jsx(Hd,{className:"w-4 h-4"})}),e&&M.jsx("button",{onClick:n,className:"p-1.5 rounded-md text-brand-red hover:bg-brand-red/10 transition-colors",title:"Remove tag",children:M.jsx(mv,{className:"w-4 h-4"})})]})]}),l&&M.jsx("p",{className:"text-[10px] text-brand-red mt-1 ml-1",children:l})]}),document.body)},pie=({tagData:e,position:t})=>jm.createPortal(M.jsxs("div",{className:"fixed z-[9999] p-3 bg-surface-card border border-surface-border rounded-lg shadow-xl w-[280px]",style:{top:t.top,left:t.left},onClick:r=>r.stopPropagation(),children:[e.tag&&M.jsxs("div",{className:"mb-2",children:[M.jsx("span",{className:"text-[10px] text-text-muted uppercase tracking-wide",children:"Tag:"}),M.jsx("p",{className:"text-sm font-medium text-brand-purple",children:e.tag})]}),e.description&&M.jsxs("div",{children:[M.jsx("span",{className:"text-[10px] text-text-muted uppercase tracking-wide",children:"Note:"}),M.jsx("p",{className:"text-xs text-text-primary break-words whitespace-pre-wrap",children:e.description})]})]}),document.body),mie=({value:e="",tagValue:t,fieldLabel:r="Unknown",taggable:n=!1,readOnly:i=!0,variant:a="default",className:s,onChange:o,placeholder:c,rows:l,...u})=>{const d=to(),{getTag:p,setTag:w,removeTag:O,settings:I}=a0(),[R,C]=he.useState(!1),[j,N]=he.useState(!1),[P,Z]=he.useState(!1),[X,re]=he.useState({top:0,left:0}),[ne,ae]=he.useState({top:0,left:0}),ue=he.useRef(null),m=he.useRef(null),A=n&&t?p(t):null,f=!!A,g={default:mt("w-full h-[200px] p-3 font-light border border-surface-border bg-surface-main rounded-lg","resize-y leading-7 font-mono text-[12px]","focus:outline-none focus:border-brand-purple/50","text-text-primary",f&&n&&"border-brand-purple/30"),compact:mt("w-full h-[150px] p-2 font-light border border-surface-border bg-surface-main rounded-md","resize-y leading-6 font-mono text-[11px]","focus:outline-none focus:border-brand-purple/50","text-text-primary",f&&n&&"border-brand-purple/30")},_=he.useCallback(()=>
23{if(!ue.current)return{top:0,left:0};const F=ue.current.getBoundingClientRect(),Q=60,G=380;let J=F.top-Q-8,Y=F.left;return J<16&&(J=F.bottom+8),Y+G>window.innerWidth&&(Y=window.innerWidth-G-16),Y<16&&(Y=16),{top:J,left:Y}},[]),B=he.useCallback(()=>{if(!ue.current)return{top:0,left:0};const F=ue.current.getBoundingClientRect(),Q=280;let G=F.top-100-8,J=F.right-Q;return G<16&&(G=F.bottom+8),J<16&&(J=16),{top:G,left:J}},[]);he.useEffect(()=>{const F=Q=>{if(ue.current&&!ue.current.contains(Q.target)){const G=document.querySelectorAll('[class*="fixed z-[9999]"]');let J=!1;G.forEach(Y=>{Y.contains(Q.target)&&(J=!0)}),J||N(!1)}};if(j)return document.addEventListener("mousedown",F),()=>document.removeEventListener("mousedown",F)},[j]);const T=()=>{!n||!I.allowHoverEffects||(C(!0),f&&!j&&I.displayNotePopovers&&(m.current=setTimeout(()=>{ae(B()),Z(!0)},300)))},S=()=>{C(!1),m.current&&clearTimeout(m.current),Z(!1)},h=F=>{F.preventDefault(),F.stopPropagation(),re(_()),N(!0),Z(!1)},x=F=>{t&&(w(t,{...F,fieldLabel:r,pageType:uie(d.pathname),pagePath:d.pathname}),N(!1),C(!1))},v=()=>{t&&(O(t),N(!1),C(!1))};return n?M.jsxs("div",{ref:ue,className:"relative w-full",onMouseEnter:T,onMouseLeave:S,children:[n&&I.allowHoverEffects&&M.jsx("button",{onClick:h,className:mt("absolute top-2 right-2 z-10 p-1.5 rounded-md transition-all duration-150","border shadow-sm",f?"bg-brand-purple/10 border-brand-purple/30 text-brand-purple":"bg-surface-card border-surface-border text-text-muted",R&&!f&&"opacity-100",!R&&!f&&"opacity-0","hover:bg-brand-purple hover:border-brand-purple hover:text-white"),title:f?"Edit tag":"Add tag",children:f?M.jsx(x6,{className:"w-3.5 h-3.5"}):M.jsx(fv,{className:"w-3.5 h-3.5"})}),f&&A.tag&&M.jsxs("div",{className:"absolute top-2 left-2 z-10 flex items-center gap-1 px-2 py-0.5 bg-brand-purple/10 border border-brand-purple/30 rounded text-[10px] text-brand-purple font-medium",children:[M.jsx(dv,{className:"w-3 h-3"}),A.tag]}),M.jsx("textarea",{value:e,onChange:o,readOnly:i,placeholder:c,rows:l,className:mt(g[a]||g.default,f&&A.tag&&"pt-10",s),...u}),j&&M.jsx(die,{existingTag:A,onSave:x,onCancel:()=>N(!1),onRemove:v,position:X}),P&&f&&!j&&M.jsx(pie,{tagData:A,position:ne})]}):M.jsx("textarea",{value:e,onChange:o,readOnly:i,placeholder:c,rows:l,className:mt(g[a]||g.default,s),...u})},gie=e=>["hash","txHash","blockHash","address","deployer","feeRecipient","coinbaseAccount","contractClassID","id","nullifiers","noteHashes","l2ToL1Msgs","publicDataWrites"].includes(e),kg=({data:e={},fields:t=[],groups:r=null,isLoading:n=!1,className:i})=>{const a={container:"flex justify-between bg-surface-card h-[60px] px-4 below-lg:flex-col below-lg:gap-2 below-lg:items-start below-lg:h-auto below-lg:py-4 hover:bg-surface-hover cursor-pointer duration-200 last:rounded-b-2xl",label:"min-w-[250px] below-lg:min-w-[110px] font-bold font-sans text-[14px] text-nowrap text-text-muted flex items-center",value:"w-full overflow-hidden text-ellipsis font-normal font-mono text-[14px] flex items-center gap-2 below-lg:break-all text-text-primary pl-3",textareaContainer:"flex justify-between bg-surface-card h-auto items-start py-10 px-4 below-lg:flex-col below-lg:gap-2 last:rounded-b-2xl first:rounded-t-2xl",textareaLabel:"min-w-[250px] below-lg:min-w-[110px] font-bold font-sans text-[14px] text-nowrap text-text-muted self-start",textareaValue:"w-full"},s=(p,w)=>{switch(p){case"publicDataWrites":return w?tie(w):"";case"nullifiers":return w?w.split(",").map((O,I)=>`${I+1}: ${O.trim()}`).join(`
24`):"";case"publicFunctionCalldata":return Array.isArray(w)?w.map((O,I)=>`${I+1}: ${O}`).join(`
25`):w||"";case"uneencryptedLogs":case"encryptedLogs":case"contractClassLogs":if(!w||Array.isArray(w)&&w.length===0)return"No logs available";if(typeof w=="string"&&(w.trim().startsWith("{")||w.trim().startsWith("[")))try{const O=JSON.parse(w);return JSON.stringify(O,null,2)}catch{return w}if(typeof w=="object")try{return JSON.stringify(w,null,2)}catch{return w.toString()}return w;default:return w}},o=(p,w)=>{if(p.linkTo)return p.linkTo(w,e);switch(p.key){case"blockNumber":return e.blockHash?`/block/${e.blockHash}`:null;case"blockHash":return`/block/${w}`;case"txHash":return`/tx/${w}`;case"contractClassID":return`/class/${w}`;case"deployer":case"address":return`/address/${w}`;default:return null}},c=p=>{if(p.type)return p.type;const w=p.key;return["publicDataWrites","nullifiers","publicFunctionCalldata","uneencryptedLogs","encryptedLogs","contractClassLogs","data"].includes(w)?"textarea":w==="timestamp"||w==="creationTimestamp"?"timestamp":w==="finalityStatus"||w==="status"?"status":["blockNumber","blockHash","txHash","contractClassID","deployer"].includes(w)?"link":w==="number"?"number":w==="coinbaseAccount"?"coinbase":w.toLowerCase().includes("hash")||w==="id"?"hash":w==="feeRecipient"||w==="privateFunctionsRoot"?"address":(w.includes("fee")||w.includes("Fee"),"text")},l=p=>{if(p.showCopy!==void 0)return p.showCopy;const w=c(p);return w==="hash"||w==="address"},u=(p,w)=>{if(p.renderValue)return p.renderValue(w);const O=c(p),I=(R,C=w)=>gie(p.key)?M.jsx(cie,{value:C,fieldLabel:p.label,children:R}):R;if(O==="textarea"){const R=s(p.key,w),C=["publicDataWrites","nullifiers","uneencryptedLogs","encryptedLogs"].includes(p.key);return M.jsx(mie,{value:R||"",tagValue:C?`${p.key}:${(e==null?void 0:e.hash)||(e==null?void 0:e.id)||"unknown"}`:void 0,fieldLabel:p.label,taggable:C,readOnly:!0,className:"w-[70%] below-lg:w-full"})}switch(O){case"number":return M.jsx("div",{className:"text-brand-blue hover:underline",children:w});case"link":const R=o(p,w);return I(R?M.jsx(ti,{to:R,className:"text-brand-purple hover:text-brand-purple/80 underline-offset-2 transition-colors",children:w}):M.jsx("span",{children:w}));case"coinbase":return I(M.jsx("div",{className:"font-mono overflow-hidden text-ellipsis text-text-primary hover:underline",children:w}));case"hash":case"address":return I(M.jsx("div",{className:"font-mono overflow-hidden text-ellipsis text-brand-purple hover:underline",children:w}));case"status":return M.jsx(vr,{variant:"status",status:w,children:w});case"fee":return M.jsx(vr,{variant:"orange",roundness:"soft",className:"!px-2 py-1 !text-[10px]",children:w});case"timestamp":return M.jsxs("div",{className:"flex items-center gap-2 !font-sans text-text-primary",children:[M.jsx(Fm,{className:"h-5 w-5 text-text-muted"}),Zm(w)," (",UX(w),")"]});default:return w}},d=p=>{const w=t.find(Z=>Z.key===p);if(!w)return null;const O=e[w.key],I=O!=null&&String(O)!=="",R=l(w),C=c(w)==="textarea",
25j=C?a.textareaContainer:a.container,N=C?a.textareaLabel:a.label,P=C?a.textareaValue:a.value;return M.jsxs("div",{className:j,children:[M.jsx("div",{className:N,children:w.label}),M.jsxs("div",{className:P,children:[n?M.jsx(Qr,{className:"!h-[20px] !w-1/4"}):C?u(w,O||""):I?u(w,O):M.jsx("span",{className:"text-text-muted font-normal",children:"None"}),!n&&I&&R&&!C&&M.jsx(xu,{value:O}),!n&&I&&w.extraElements&&w.extraElements(O)]})]},w.key)};return r&&Array.isArray(r)?M.jsx("div",{className:mt("flex flex-col gap-8",i),children:r.map((p,w)=>{const O=typeof p=="object"&&!Array.isArray(p),I=O?p.fields:p,R=O?p.title:null,C=O?p.icon:null;return M.jsxs(ch,{variant:"flat",padding:"none",children:[R&&M.jsxs("div",{className:"flex items-center gap-2 px-4 h-[50px] bg-surface-card rounded-t-2xl",children:[C&&M.jsx("div",{className:"text-brand-purple",children:C}),M.jsx("h3",{className:"text-text-primary font-bold text-[12px] uppercase tracking-wide",children:R})]}),M.jsx("div",{className:"divide-y divide-surface-border rounded-2xl ",children:I.map(j=>d(j))})]},`group-${w}`)})}):M.jsx("div",{className:mt("flex flex-col gap-8",i),children:M.jsx(ch,{variant:"flat",padding:"none",children:M.jsx("div",{className:"divide-y divide-surface-border ",children:t.map(p=>d(p.key))})})})},Ts=({variant:e="detail",title:t,subtitle:r=null,showSearchBar:n=!0,className:i="",totalCount:a=null,itemLabel:s="Items",isLoading:o=!1,filterIndicators:c=null,filterButton:l=null})=>{const u=()=>e==="list"?M.jsxs("div",{className:"flex flex-col",children:[M.jsx("h1",{className:"w-min text-[28px] font-normal text-text-primary",children:t}),r?M.jsx("div",{className:"text-text-muted text-[10px]",children:r}):M.jsx("div",{className:"flex flex-col gap-2",children:M.jsxs("div",{className:"text-text-muted text-[10px] flex text-nowrap",children:[o||a===null?M.jsx(Qr,{className:"!h-[14px] !w-[25px] mr-1"}):`${a} `,s," found!"]})})]}):M.jsxs("div",{className:"flex flex-col w-full gap-2",children:[M.jsx("h1",{className:"font-sans text-[28px] w-full text-text-primary font-medium below-mobile:pb-4",children:t}),r&&M.jsx("div",{className:"text-text-muted text-[14px]",children:r})]});return M.jsxs("div",{className:i,children:[M.jsxs("div",{className:`flex justify-between items-center ${e==="list"?"pb-4":""}`,children:[u(),n&&M.jsxs("div",{className:`flex items-center justify-end gap-2 w-full ${e==="list"?"below-lg:hidden":"below-mobile:hidden"}`,children:[M.jsx(b5,{roundness:"medium"}),e==="list"&&l]})]}),n&&M.jsx(b5,{className:e==="list"?"hidden below-lg:flex mb-4":"hidden below-mobile:flex mb-4"}),e==="list"&&c&&M.jsx("div",{className:"w-full pb-2",children:c})]})},bie=()=>{const{hash:e}=$d(),[t,r]=he.useState(null),{network:n}=di(),i=Vn({queryKey:["transaction",e,n],queryFn:()=>$C(e,n),enabled:!!e,onError:u=>{console.error("Failed to fetch transaction:",u),r("Failed to fetch transaction. Please try again later.")}}),a=i.data||{},s=i.isLoading,o=[{key:"blockNumber",label:"Included in Block"},{key:"hash",label:"Transaction Hash"},{key:"finalityStatus",label:"Status"},{key:"timestamp",label:"Timestamp"},{key:"index",label:"Index"},{key:"transactionFee",label:"Transaction Fee"},{key:"noteHashes",label:"Note Hashes"},{key:"l2ToL1Msgs",label:"L2 to L1 Messages"},{key:"publicDataWrites",label:"Public Data Writes"},{key:"nullifiers",label:"Nullifiers"},{key:"uneencryptedLogs",label:"Unencrypted Logs"},{key:"encryptedLogs",label:"Encrypted Logs"}],c=[{title:"Summary",icon:M.jsx(vr,{variant:"blue",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(Wd,{className:"w-4 h-4"})}),fields:["blockNumber","hash","finalityStatus","timestamp"]},{title:"Transaction Details",icon:M.jsx(vr,{variant:"purple",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(ZW,{className:"w-4 h-4"})}),fields:["index","transactionFee","noteHashes","l2ToL1Msgs"]},{title:"Logs & Data",icon:M.jsx(vr,{variant:"green",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(DW,{className:"w-4 h-4"})}),fields:["publicDataWrites","nullifiers","uneencryptedLogs","encryptedLogs"]}],l=()=>e?!i.isLoading&&!i.error&&!i.data?M.jsx(pi,{message:"Transaction Not Found",type:"not_found",currentNetwork:n.name}):M.jsx(kg,{data:a,fields:o,groups:c,isLoading:s}):M.jsx(pi,{message:"Transaction Not Found",type:"not_found"});return M.jsxs("div",{className:"flex flex-col gap-4",children:[M.jsx(Ts,{variant:"detail",title:"Transaction",showSearchBar:!0}),t?M.jsx(pi,{message:t,type:"general_error"}):!i.isLoading&&!i.data?M.jsx(pi,{message:"Transaction Not Found",type:"not_found",currentNetwork:n.name}):l()]})},yie=()=>{const{hash:e}=$d(),[t,r]=he.useState(null),{network:n}=di(),i=Vn({queryKey:["pendingTransaction",e,n],queryFn:()=>ZC(e,n),enabled:!!e,onError:u=>{console.error("Failed to fetch pending transaction:",u),r("Failed to fetch pending transaction. Please try again later.")}}),a=i.data||[],s=i.isLoading,o=[{key:"hash",label:"Transaction Hash"},{key:"type",label:"Type",renderValue:u=>u||"Pending"},{key:"timestamp",label:"Timestamp"},{key:"data",label:"Transaction Data"},{key:"publicFunctionCalldata",label:"Public Function Calldata"},{key:"contractClassLogs",label:"Contract Class Logs"}],c=[{title:"Summary",icon:M.jsx(W7,{className:"w-6 h-6 p-0.5 rounded-md bg-brand-blue/10 text-brand-blue"}),fields:["hash","type","timestamp"]},{title:"Transaction Data",icon:M.jsx(zW,{className:"w-6 h-6 p-0.5 rounded-md bg-brand-purple/10 text-brand-purple"}),fields:["data","publicFunctionCalldata","contractClassLogs"]}],l=()=>e?!i.isLoading&&!i.error&&!i.data?M.jsx(pi,{message:"Pending Transaction Not Found",type:"not_found",currentNetwork:n.name}):M.jsx(kg,{data:a,fields:o,groups:c,isLoading:s}):M.jsx(pi,{message:"Pending Transaction Not Found",type:"not_found"});return M.jsxs("div",{className:"flex flex-col gap-4",children:[M.jsx(Ts,{variant:"detail",title:"Pending Transaction",showSearchBar:!0}),t?M.jsx(pi,{message:t,type:"general_error"}):!i.isLoading&&!i.data?M.jsx(pi,{message:"Pending Transaction Not Found",type:"not_found",currentNetwork:n.name}):l()]})},vie=()=>{const{hash:e}=$d(),[t,r]=he.useState(null),{network:n}=di(),i=Vn({queryKey:["transaction",e,n],queryFn:()=>$C(e,n),enabled:!!e,onError:c=>{console.error("Failed to fetch transaction:",c)},retry:!1}),a=Vn({queryKey:["pendingTransaction",e,n],queryFn:()=>ZC(e,n),enabled:!!e&&!i.isLoading&&!i.data,onError:c=>{console.error("Failed to fetch pending transaction:",c),r("Failed to fetch transaction. Please try again later.")}}),s=M.jsx(Ts,{variant:"detail",title:"Transaction",showSearchBar:!0});return console.log(i),t?M.jsxs("div",{className:"flex flex-col gap-4",children:[s,M.jsx(pi,{message:t,type:"general_error"})]}):i.data||i.isLoading?M.jsx(bie,{}):a.data||a.isLoading?M.jsx(yie,{}):!i.data&&!a.data?M.jsxs("div",{className:"flex flex-col gap-4",children:[s,M.jsx(pi,{message:"Transaction Not Found",type:"not_found",currentNetwork:n.name})]}):null},wie=()=>M.jsxs(M.Fragment,{children:[M.jsx(Ms,{route:"/transactions"}),M.jsx("div",{className:" px-[6.5vw] py-[73px] below-mobile:py-[40px] w-full font-",children:M.jsx(vie,{})})]}),TO=()=>{const[e,t]=he.useState(!1);he.useEffect(()=>{localStorage.getItem("theme")==="dark"&&(document.documentElement.classList.add("dark"),t(!0))},[]);const r=()=>{t(!e),e?(document.documentElement.classList.remove("dark"),localStorage.setItem("theme","light")):(document.documentElement.classList.add("dark"),localStorage.setItem("theme","dark"))};return M.jsx(St,{onClick:r,variant:"gray",size:"md",roundness:"full",className:"!p-0 w-[36px] min-w-[36px]",children:e?M.jsx(jW,{className:"min-w-5 min-h-5 w-5 h-5"}):M.jsx(TW,{className:"min-w-5 min-h-5 w-5 h-5"})})};function xie(e){return dr({tag:"svg",attr:{fill:"none",viewBox:"0 0 24 24",strokeWidth:"2",stroke:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"},child:[]}]})(e)}const jO=[{key:ro.MAINNET,label:"Aztec Mainnet",enabled:!0},{key:ro.TESTNET,label:"Aztec Testnet",enabled:!0},{key:ro.DEVNET,label:"Aztec Devnet",enabled:!0}],IO=()=>{const[e,t]=he.useState(!1),{network:r,setNetwork:n}=di(),i=he.useRef(null),a=jO.filter(o=>o.enabled),s=()=>{var o;return((o=jO.find(c=>c.key===r))==null?void 0:o.label)||"Select Network"};return he.useEffect(()=>{const o=c=>{i.current&&!i.current.contains(c.target)&&t(!1)};return document.addEventListener("mousedown",o),()=>{document.removeEventListener("mousedown",o)}},[]),M.jsxs("div",{ref:i,className:"relative",children:[M.jsx(St,{onClick:()=>t(!e),variant:"gray",size:"md",roundness:"soft",iconBefore:M.jsx("div",{className:"bg-brand-green h-2 w-2 rounded-full mr-1"}),iconAfter:M.jsx(yu,{className:"ml-3 text-text-muted rotate-90"}),className:"below-lg:hidden",children:s()}),M.jsxs(St,{onClick:()=>t(!e),variant:"gray",size:"md",roundness:"full",className:"hidden below-lg:flex !p-0 w-[36px] min-w-[36px] relative",children:[M.jsx(xie,{className:"min-w-5 min-h-5 w-5 h-5"}),M.jsx("div",{className:"absolute top-1 right-1 bg-brand-green h-2 w-2 rounded-full"})]}),e&&M.jsx("div",{className:"absolute top-[42px] left-0 z-10 w-max min-w-full flex flex-col gap-1 p-1 bg-surface-card border border-surface-border rounded-lg shadow-lg below-lg:right-0 below-lg:left-auto below-mobile:bottom-[42px] below-mobile:top-auto",children:a.map(o=>M.jsx(St,{onClick:()=>{n(o.key),t(!1)},variant:"ghost",size:"md",roundness:"soft",iconAfter:M.jsx(Rm,{className:"transition-opacity duration-200 text-brand-orange",style:{opacity:r===o.key?1:0},size:14}),className:r===o.key?"bg-surface-border text-text-primary":"",children:o.label},o.key))})]})},OO=[{key:"blocks",label:"Blocks",icon:M.jsx(Zf,{size:14}),to:"/blocks"},{key:"contracts",label:"Contracts",icon:M.jsx(Nm,{size:14}),to:"/addresses"},{key:"classes",label:"Classes",icon:M.jsx(hv,{size:14}
25),to:"/classes"},{key:"transactions",label:"Transactions",icon:M.jsx(Wd,{size:14}),to:"/transactions"}],_ie=e=>e.startsWith("/block")?"blocks":e.startsWith("/address")?"contracts":e.startsWith("/class")?"classes":e.startsWith("/transaction")?"transactions":null,Sie=()=>{const[e,t]=he.useState(!1),r=he.useRef(null),n=to(),i=_ie(n.pathname);he.useEffect(()=>{const c=l=>{r.current&&!r.current.contains(l.target)&&t(!1)};return document.addEventListener("mousedown",c),()=>{document.removeEventListener("mousedown",c)}},[]);const a=()=>M.jsxs("div",{className:"h-[100px] py-5 flex justify-between items-center w-full z-50  text-sm px-[6.5vw]",children:[M.jsxs(ti,{className:"z-50",to:"/",children:[M.jsx("img",{className:" h-[52px] w-[52px]  min-h-[52px] min-w-[52px] below-mobile-xs:h-[42px] below-mobile-xs:w-[42px] below-mobile-xs:min-h-[42px] below-mobile-xs:min-w-[42px] dark:hidden",src:_6}),M.jsx("img",{className:" h-[52px] w-[52px]  min-h-[52px] min-w-[52px] below-mobile-xs:h-[42px] below-mobile-xs:w-[42px] below-mobile-xs:min-h-[42px] below-mobile-xs:min-w-[42px] hidden dark:block",src:S6})]}),M.jsx("button",{onClick:()=>t(!0),className:"z-50 flex items-center justify-center w-[42px] min-w-[42px] h-[42px] rounded-full bg-surface-card border border-surface-border text-text-primary hover:bg-surface-hover transition-colors",children:M.jsx(qW,{className:"w-6 h-6"})})]}),s=()=>M.jsxs(M.Fragment,{children:[M.jsx("div",{className:`
26            ${e?"opacity-100":"opacity-0 pointer-events-none"}
27            fixed inset-0 bg-black/50 z-[99] transition-opacity duration-300
28          `,onClick:()=>t(!1)}),M.jsxs("div",{ref:r,className:`
29            ${!e&&"translate-x-full"}
30            fixed top-0 right-0 bg-surface-main dark:bg-surface-card w-[75%] max-w-[300px] h-full z-[100] px-6 py-8 flex flex-col gap-8 duration-300 border-l border-surface-border shadow-xl`,children:[M.jsxs("div",{className:"flex items-center justify-between",children:[M.jsxs(ti,{to:"/",onClick:()=>t(!1),children:[M.jsx("img",{className:"h-[40px] w-[40px] dark:hidden",src:_6,alt:"Logo"}),M.jsx("img",{className:"h-[40px] w-[40px] hidden dark:block",src:S6,alt:"Logo"})]}),M.jsx("button",{onClick:()=>t(!1),className:"w-10 h-10 flex items-center justify-center rounded-full bg-surface-hover text-text-muted hover:text-text-primary transition-colors",children:M.jsx("span",{className:"text-xl",children:"\xD7"})})]}),M.jsx("nav",{className:"flex flex-col gap-2 flex-1",children:OO.map(c=>{const l=i===c.key;return M.jsxs(ti,{to:c.to,onClick:()=>t(!1),className:`
31                    flex items-center gap-3 px-4 py-3 rounded-lg transition-colors
32                    ${l?"bg-brand-purple/10 text-brand-purple":"text-text-body hover:bg-surface-hover hover:text-text-primary"}
33                  `,children:[M.jsx("span",{className:l?"text-brand-purple":"text-text-muted",children:c.icon}),M.jsx("span",{className:"font-medium",children:c.label})]},c.key)})}),M.jsxs("div",{className:"flex items-center justify-between pt-4 border-t border-surface-border",children:[M.jsx(IO,{}),M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx(ti,{to:"/settings",onClick:()=>t(!1),className:"flex items-center justify-center w-[42px] h-[42px] rounded-full bg-surface-card border border-surface-border text-text-muted hover:text-text-primary hover:bg-surface-hover transition-colors",children:M.jsx(G7,{className:"w-5 h-5"})}),M.jsx(TO,{})]})]})]})]}),o=()=>M.jsxs("div",{className:"relative flex justify-between items-center w-full h-[84px] z-50",children:[M.jsxs(ti,{className:"z-10",to:"/",children:[M.jsx("img",{className:" h-[44px] w-[44px]  min-h-[44px] min-w-[44px] dark:hidden",src:_6}),M.jsx("img",{className:" h-[44px] w-[44px]  min-h-[44px] min-w-[44px] hidden dark:block",src:S6})]}),M.jsx(Sg,{items:OO,activeKey:i,size:"md",roundness:"full",className:"hidden above-mobile:flex shadow-sm absolute left-1/2 -translate-x-1/2"}),M.jsxs("div",{className:"flex justify-end items-center gap-2 z-10",children:[M.jsx(IO,{}),M.jsx(TO,{}),M.jsx(ti,{to:"/settings",className:"flex items-center justify-center w-[36px] h-[36px] rounded-full bg-surface-card border border-surface-border text-text-muted hover:text-text-primary hover:bg-surface-hover transition-colors",children:M.jsx(G7,{className:"w-[18px] h-[18px]"})})]})]});return M.jsxs(M.Fragment,{children:[M.jsx("div",{className:"hidden below-mobile:block",children:a()}),M.jsx("div",{className:"below-mobile:hidden",children:o()}),s()]})},Eg=()=>{const[e,t]=he.useState({}),[r,n]=he.useState(!1),i=()=>Object.keys(e).some(l=>
33l==="sort"||l==="order"?!1:e[l]!==""&&e[l]!==void 0),a=l=>({startTimestamp:"Start Time",endTimestamp:"End Time",startCreationTimestamp:"Start Creation Time",endCreationTimestamp:"End Creation Time",minFee:"Min Fee",maxFee:"Max Fee",minTxCount:"Min Tx Count",maxTxCount:"Max Tx Count",minTxFee:"Min Tx Fee",maxTxFee:"Max Tx Fee",minIndex:"Min Index",maxIndex:"Max Index",minBlockNumber:"Min Block",maxBlockNumber:"Max Block",minVersion:"Min Version",maxVersion:"Max Version",sort:"Sort"})[l]||l,s=l=>({blockNumber:"Block Number",timestamp:"Time",txCount:"Tx Count",fee:"Fee",index:"Index",hash:"Hash"})[l]||l,o=(l,u)=>l==="startTimestamp"||l==="endTimestamp"||l==="startCreationTimestamp"||l==="endCreationTimestamp"?new Date(u).toLocaleDateString():l==="sort"?s(u):u,c=l=>l==="asc"?M.jsx(NW,{size:12}):M.jsx(RW,{size:12});return{renderFilterElement:l=>{const u=(P,Z)=>{he.useEffect(()=>{const X=re=>{P.current&&!P.current.contains(re.target)&&Z()};return document.addEventListener("mousedown",X),()=>{document.removeEventListener("mousedown",X)}},[P,Z])},d=(P,Z)=>M.jsx(H7,{onClick:()=>Z(!P),className:"w-4 h-4 p-0.5 ml-1 text-text-muted hover:text-brand-purple cursor-pointer transition-colors"}),p=()=>{const[P,Z]=he.useState(!1),X=he.useRef(null);u(X,()=>Z(!1));const re=[{label:"Last 1H",ms:1e3*60*60},{label:"Last 24H",ms:1e3*60*60*24},{label:"Last 7D",ms:1e3*60*60*24*7},{label:"Last 1M",ms:1e3*60*60*24*30},{label:"Last 3M",ms:1e3*60*60*24*30*3},{label:"Last 6M",ms:1e3*60*60*24*30*6}];return M.jsxs(M.Fragment,{children:[d(P,Z),M.jsxs("div",{ref:X,className:mt("absolute top-[25px] w-[250px] bg-surface-card border border-surface-border rounded-lg p-3 z-50 flex flex-col shadow-lg",!P&&"hidden"),children:[M.jsxs("div",{className:"text-text-primary text-[10px] font-medium pb-2 border-b border-surface-border flex justify-between",children:["Duration",M.jsx("button",{onClick:()=>{t({...e,startTimestamp:"",endTimestamp:""}),Z(!1)},className:"text-brand-purple hover:underline cursor-pointer",children:"Clear"})]}),M.jsx("div",{className:"flex flex-wrap gap-1.5 pt-2",children:re.map(ne=>M.jsx("button",{onClick:()=>{t({...e,endTimestamp:new Date(Date.now()).toISOString(),startTimestamp:new Date(Date.now()-ne.ms).toISOString()}),Z(!1)},className:"px-2 py-0.5 text-[9px] rounded-full bg-surface-hover border border-surface-border text-text-muted hover:bg-brand-purple/10 hover:border-brand-purple/20 hover:text-brand-purple cursor-pointer transition-colors",children:ne.label},ne.label))})]})]})},w=()=>{const[P,Z]=he.useState(!1),[X,re]=he.useState(""),[ne,ae]=he.useState(""),ue=he.useRef(null);return u(ue,()=>Z(!1)),M.jsxs(M.Fragment,{children:[d(P,Z),M.jsxs("div",{ref:ue,className:mt("absolute top-[25px] -left-[100px] w-[250px] bg-surface-card border border-surface-border rounded-lg p-3 z-50 flex flex-col shadow-lg",!P&&"hidden"),children:[M.jsxs("div",{className:"text-text-primary text-[10px] font-medium pb-2 border-b border-surface-border flex justify-between items-center",children:["Fee Amount",M.jsx("button",{onClick:()=>{ae(""),re(""),t({...e,maxTotalFees:"",minTotalFees:""}),Z(!1)},className:"text-brand-purple hover:underline cursor-pointer",children:"Clear"})]}),M.jsxs("div",{className:"flex flex-col gap-2 pt-2",children:[M.jsx("input",{placeholder:"Min Fee",value:X,onChange:m=>re(m.target.value),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"}),M.jsx("input",{placeholder:"Max Fee",value:ne,onChange:m=>ae(m.target.value),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"})]}),M.jsxs("div",{className:"flex w-full gap-2 pt-3",children:[M.jsx(St,{size:"sm",variant:"purple",onClick:()=>{t({...e,maxTotalFees:ne,minTotalFees:X}),Z(!1)},className:"flex-1 !text-[10px]",children:"Apply"}),M.jsx(St,{size:"sm",variant:"gray",onClick:()=>Z(!1),className:"flex-1 !text-[10px]",children:"Cancel"})]})]})]})},O=()=>{const[P,Z]=he.useState(!1),[X,re]=he.useState(""),[ne,ae]=he.useState(""),ue=he.useRef(null);return u(ue,()=>Z(!1)),M.jsxs(M.Fragment,{children:[d(P,Z),M.jsxs("div",{ref:ue,className:mt("absolute top-[25px] -left-[100px] w-[250px] bg-surface-card border border-surface-border rounded-lg p-3 z-50 flex flex-col shadow-lg",!P&&"hidden"),children:[M.jsxs("div",{className:"text-text-primary text-[10px] font-medium pb-2 border-b border-surface-border flex justify-between items-center",children:["Transaction Count",M.jsx("button",{onClick:()=>{ae(""),re(""),t({...e,maxTxCount:"",minTxCount:""}),Z(!1)},className:"text-brand-purple hover:underline cursor-pointer",children:"Clear"})]}),M.jsxs("div",{className:"flex flex-col gap-2 pt-2",children:[M.jsx("input",{placeholder:"Min Count",value:X,onChange:m=>re(m.target.value),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"}),M.jsx("input",{placeholder:"Max Count",value:ne,onChange:m=>ae(m.target.value),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"})]}),M.jsxs("div",{className:"flex w-full gap-2 pt-3",children:[M.jsx(St,{size:"sm",variant:"purple",onClick:()=>{t({...e,maxTxCount:ne,minTxCount:X}),Z(!1)},className:"flex-1 !text-[10px]",children:"Apply"}),M.jsx(St,{size:"sm",variant:"gray",onClick:()=>Z(!1),className:"flex-1 !text-[10px]",children:"Cancel"})]})]})]})},I=()=>{const[P,Z]=he.useState(!1),[X,re]=he.useState(""),[ne,ae]=he.useState(""),ue=he.useRef(null);return u(ue,()=>Z(!1)),M.jsxs(M.Fragment,{children:[d(P,Z),M.jsxs("div",{ref:ue,className:mt("absolute top-[25px] -left-[100px] w-[250px] bg-surface-card border border-surface-border rounded-lg p-3 z-50 flex flex-col shadow-lg",!P&&"hidden"),children:[M.jsxs("div",{className:"text-text-primary text-[10px] font-medium pb-2 border-b border-surface-border flex justify-between items-center",children:["Transaction Fee",M.jsx("button",{onClick:()=>{ae(""),re(""),t({...e,maxTransactionFee:"",minTransactionFee:""}),Z(!1)},className:"text-brand-purple hover:underline cursor-pointer",children:"Clear"})]}),M.jsxs("div",{className:"flex flex-col gap-2 pt-2",children:[M.jsx("input",{placeholder:"Min Fee",value:X,onChange:m=>re(m.target.value),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"}),M.jsx("input",{placeholder:"Max Fee",value:ne,onChange:m=>ae(m.target.value),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"})]}),M.jsxs("div",{className:"flex w-full gap-2 pt-3",children:[M.jsx(St,{size:"sm",variant:"purple",onClick:()=>{t({...e,maxTransactionFee:ne,minTransactionFee:X}),Z(!1)},className:"flex-1 !text-[10px]",children:"Apply"}),M.jsx(St,{size:"sm",variant:"gray",onClick:()=>Z(!1),className:"flex-1 !text-[10px]",children:"Cancel"})]})]})]})},R=()=>{const[P,Z]=he.useState(!1),[X,re]=he.useState(""),[ne,ae]=he.useState(""),ue=he.useRef(null);return u(ue,()=>Z(!1)),M.jsxs(M.Fragment,{children:[d(P,Z),M.jsxs("div",{ref:ue,className:mt("absolute top-[25px] -left-[100px] w-[250px] bg-surface-card border border-surface-border rounded-lg p-3 z-50 flex flex-col shadow-lg",!P&&"hidden"),children:[M.jsxs("div",{className:"text-text-primary text-[10px] font-medium pb-2 border-b border-surface-border flex justify-between items-center",children:["Index Range",M.jsx("button",{onClick:()=>{ae(""),re(""),t({...e,maxIndex:"",minIndex:""}),Z(!1)},className:"text-brand-purple hover:underline cursor-pointer",children:"Clear"})]}),M.jsxs("div",{className:"flex flex-col gap-2 pt-2",children:[M.jsx("input",{placeholder:"Min Index",value:X,onChange:m=>re(m.target.value),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"}),M.jsx("input",{placeholder:"Max Index",value:ne,onChange:m=>ae(m.target.value),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"})]}),M.jsxs("div",{className:"flex w-full gap-2 pt-3",children:[M.jsx(St,{size:"sm",variant:"purple",onClick:()=>{t({...e,maxIndex:ne,minIndex:X}),Z(!1)},className:"flex-1 !text-[10px]",children:"Apply"}),M.jsx(St,{size:"sm",variant:"gray",onClick:()=>Z(!1),className:"flex-1 !text-[10px]",children:"Cancel"})]})]})]})},C=()=>{const[P,Z]=he.useState(!1),X=he.useRef(null);return u(X,()=>Z(!1)),M.jsxs(M.Fragment,{children:[d(P,Z),M.jsxs("div",{ref:X,className:mt("absolute top-[25px] w-[250px] bg-surface-card border border-surface-border rounded-lg p-3 z-50 flex flex-col shadow-lg",!P&&"hidden"),children:[M.jsxs("div",{className:"text-text-primary text-[10px] font-medium pb-2 border-b border-surface-border flex justify-between",children:["Block Number",M.jsx("button",{onClick:()=>{t({...e,minBlockNumber:"",maxBlockNumber:""}),Z(!1)},className:"text-brand-purple hover:underline cursor-pointer",children:"Clear"})]}),M.jsxs("div",{className:"flex flex-col gap-2 pt-2",children:[M.jsx("input",{type:"number",placeholder:"Min Block Number",value:e.minBlockNumber||"",onChange:re=>t({...e,minBlockNumber:re.target.value}),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"}),M.jsx("input",{type:"number",placeholder:"Max Block Number",value:e.maxBlockNumber||"",onChange:re=>t({...e,maxBlockNumber:re.target.value}),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"}),M.jsx(St,{size:"sm",variant:"purple",onClick:()=>Z(!1),className:"w-full !text-[10px]",children:"Apply"})]})]})]})},j=()=>{const[P,Z]=he.useState(!1),X=he.useRef(null);return u(X,()=>Z(!1)),M.jsxs(M.Fragment,{children:[d(P,Z),M.jsxs("div",{ref:X,className:mt("absolute top-[25px] w-[250px] bg-surface-card border border-surface-border rounded-lg p-3 z-50 flex flex-col shadow-lg",!P&&"hidden"),children:[M.jsxs("div",{className:"text-text-primary text-[10px] font-medium pb-2 border-b border-surface-border flex justify-between",children:["Version",M.jsx("button",{onClick:()=>{t({...e,minVersion:"",maxVersion:""}),Z(!1)},className:"text-brand-purple hover:underline cursor-pointer",children:"Clear"})]}),M.jsxs("div",{className:"flex flex-col gap-2 pt-2",children:[M.jsx("input",{type:"number",placeholder:"Min Version",value:e.minVersion||"",onChange:re=>t({...e,minVersion:re.target.value}),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"}),M.jsx("input",{type:"number",placeholder:"Max Version",value:e.maxVersion||"",onChange:re=>t({...e,maxVersion:re.target.value}),className:"w-full h-8 px-2 text-[10px] bg-surface-main border border-surface-border rounded-md text-text-primary placeholder:text-text-muted focus:outline-none focus:border-brand-purple/50"}),M.jsx(St,{size:"sm",variant:"purple",onClick:()=>Z(!1),className:"w-full !text-[10px]",children:"Apply"})]})]})]})},N=()=>{const[P,Z]=he.useState(!1),X=he.useRef(null);u(X,()=>Z(!1));const re=[{label:"Last 1H",ms:1e3*60*60},{label:"Last 24H",ms:1e3*60*60*24},{label:"Last 7D",ms:1e3*60*60*24*7},{label:"Last 1M",ms:1e3*60*60*24*30},{label:"Last 3M",ms:1e3*60*60*24*30*3},{label:"Last 6M",ms:1e3*60*60*24*30*6}];return M.jsxs(M.Fragment,{children:[d(P,Z),M.jsxs("div",{ref:X,className:mt("absolute top-[25px] w-[250px] bg-surface-card border border-surface-border rounded-lg p-3 z-50 flex flex-col shadow-lg",!P&&"hidden"),children:[M.jsxs("div",{className:"text-text-primary text-[10px] font-medium pb-2 border-b border-surface-border flex justify-between",children:["Creation Time",M.jsx("button",{onClick:()=>{t({...e,startCreationTimestamp:"",endCreationTimestamp:""}),Z(!1)},className:"text-brand-purple hover:underline cursor-pointer",children:"Clear"})]}),M.jsx("div",{className:"flex flex-wrap gap-1.5 pt-2",children:re.map(ne=>M.jsx("button",{onClick:()=>{t({...e,endCreationTimestamp:new Date(Date.now()).toISOString(),startCreationTimestamp:new Date(Date.now()-ne.ms).toISOString()}),Z(!1)},className:"px-2 py-0.5 text-[9px] rounded-full bg-surface-hover border border-surface-border text-text-muted hover:bg-brand-purple/10 hover:border-brand-purple/20 hover:text-brand-purple cursor-pointer transition-colors",children:ne.label},ne.label))})]})]})};return M.jsxs("div",{className:"relative ",children:[l=="timestamp"&&p(),l=="creationTimestamp"&&N(),l=="fee"&&w(),l=="txCount"&&O(),l=="txFee"&&I(),l=="index"&&R(),l=="blockNumber"&&C(),l=="version"&&j()]})},renderFilterButton:(l="")=>M.jsxs(St,{onClick:()=>n(!r),variant:i()?"purple":"gray",size:"md",iconBefore:M.jsx(H7,{className:"w-4 h-4"}),className:mt("filter-toggle-button text-[11px] gap-3 h-[40px] min-w-[87px]",l),children:["Filters",i()&&M.jsx("span",{className:"w-1.5 h-1.5 rounded-full bg-current"})]}),renderFilterIndicators:(l="")=>{const u=Object.entries(e).filter(([d,p])=>
33d==="order"?!1:p!==""&&p!==void 0);return u.length===0?null:M.jsxs("div",{className:mt("flex flex-wrap gap-2",l),children:[u.map(([d,p])=>d==="sort"?M.jsxs(vr,{variant:"purple",rounded:"soft",className:"gap-1 text-[10px]",children:[M.jsxs("span",{className:"flex items-center gap-1",children:[a(d),": ",o(d,p),c(e.order||"asc")]}),M.jsx("button",{onClick:()=>{const w={...e};delete w[d],delete w.order,t(w)},className:"text-text-muted hover:text-text-primary rounded-full border border-surface-border hover:border-text-muted h-4 w-4 flex items-center justify-center ml-1 transition-colors",children:M.jsx(Hd,{size:10})})]},d):M.jsxs(vr,{variant:"default",rounded:"soft",className:"gap-1 text-[10px]",children:[M.jsxs("span",{children:[a(d),": ",o(d,p)]}),M.jsx("button",{onClick:()=>{const w={...e};delete w[d],t(w)},className:"text-text-muted hover:text-text-primary rounded-full border border-surface-border hover:border-text-muted h-4 w-4 flex items-center justify-center ml-1 transition-colors",children:M.jsx(Hd,{size:10})})]},d)),u.length>0&&M.jsx("button",{onClick:()=>t({}),className:"text-[10px] text-text-muted hover:text-text-primary underline transition-colors",children:"Clear All"})]})},filters:e,setFilters:t,setSort:l=>{t({...e,sort:l,order:(e==null?void 0:e.sort)===l&&e.order==="desc"?"asc":"desc"})},currentSort:e==null?void 0:e.sort,isFilterPanelOpen:r,setIsFilterPanelOpen:n,hasActiveFilters:i}},kie=()=>{var O,I;const[e,t]=he.useState(null),{hash:r}=$d(),{network:n}=di(),i=Vn({queryKey:["block",r,n],queryFn:()=>sY(r,n),enabled:!!r,onError:R=>{console.error("Failed to fetch block:",R),t("Failed to fetch block. Please try again later.")}}),a=Vn({queryKey:["transactions",(O=i.data)==null?void 0:O.number,n],queryFn:()=>oY(i.data.number,n),enabled:!!((I=i.data)!=null&&I.number),onError:R=>{console.error("Failed to fetch transactions:",R),t("Failed to fetch transactions. Please try again later.")}}),s=i.data||[],o=a.data||[],c=i.isLoading||a.isLoading,{setSort:l,currentSort:u}=Eg(),d=[{key:"number",label:"Block Number"},{key:"hash",label:"Block Hash"},{key:"timestamp",label:"Timestamp"},{key:"finalityStatus",label:"Status"},{key:"txCount",label:"Transaction Count"},{key:"size",label:"Block Size"},{key:"feeRecipient",label:"Fee Recipient"},{key:"coinbaseAccount",label:"Coinbase Account"},{key:"totalFees",label:"Total Fees"},{key:"feePerDaGas",label:"Fee Per DA Gas"},{key:"feePerL2Gas",label:"Fee Per L2 Gas"},{key:"startStateHash",label:"Start State Hash"},{key:"endStateHash",label:"End State Hash"}],p=[{title:"Summary",icon:M.jsx(vr,{variant:"blue",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(Zf,{className:"w-4 h-4"})}),fields:["number","hash","timestamp","finalityStatus"]},{title:"Block Details",icon:M.jsx(vr,{variant:"green",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(Zf,{className:"w-4 h-4"})}),fields:["txCount","size","feeRecipient","coinbaseAccount"]},{title:"Fee Information",icon:M.jsx(vr,{variant:"yellow",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(K7,{className:"w-4 h-4"})}),fields:["totalFees","feePerDaGas","feePerL2Gas"]},{title:"State Hashes",icon:M.jsx(vr,{variant:"pink",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(w6,{className:"w-4 h-4"})}),fields:["startStateHash","endStateHash"]}],w=()=>r?!i.isLoading&&!i.error&&!i.data?M.jsx(pi,{message:"Block Not Found",type:"not_found",currentNetwork:n.name}):M.jsx(kg,{data:s,fields:d,groups:p,isLoading:c}):M.jsx(pi,{message:"Block Not Found",type:"not_found"});return M.jsxs("div",{className:"flex flex-col gap-4",children:[M.jsx(Ts,{variant:"detail",title:s.number?`Block #${s.number}`:"Block",showSearchBar:!0}),e?M.jsx(pi,{message:e,type:"general_error"}):!i.isLoading&&!i.data?M.jsx(pi,{message:"Block Not Found",type:"not_found",currentNetwork:n.name}):M.jsxs(M.Fragment,{children:[w(),i.data&&M.jsx("div",{className:"mt-4",children:M.jsx(ac,{data:o,title:"Transactions",titleIcon:M.jsx(Wd,{className:"w-4 h-4 "}),theme:"tx",columns:[{key:"hash",label:"Hash",width:"15%",type:"hash",cellClassName:"",mobile:{order:1,showLabel:!0}},{key:"blockNumber",label:"Block",width:"10%",type:"number",sortable:!0,sortKey:"blockNumber",mobile:{order:2,showLabel:!0}},{key:"timestamp",label:"Age",width:"10%",type:"timestamp",sortable:!0,sortKey:"timestamp",cellClassName:"",mobile:{order:3,showLabel:!0}},{key:"index",label:"Index",width:"5%",type:"count",sortable:!0,sortKey:"index",cellClassName:"",mobile:!1},{key:"nullifier",label:"Nullifier",width:"32%",type:"nullifier",cellClassName:" max-w-full overflow-ellipsis overflow-hidden",mobile:!1},{key:"transactionFee",label:"Fee",width:"10%",type:"fee",sortable:!0,sortKey:"transactionFee",cell
33ClassName:"",mobile:{order:4,showLabel:!0}}],variant:"detailed",loading:c,error:e,sortable:!0,currentSort:u,onSort:l,limit:20})})]})]})},Eie=()=>M.jsxs(M.Fragment,{children:[M.jsx(Ms,{route:"/blocks"}),M.jsx("div",{className:"px-[6.5vw] py-[73px] w-full below-lg:py-[40px]",children:M.jsx(kie,{})})]}),Mie=({addressInfo:e,isLoading:t})=>{const r=[{key:"address",label:"Address"},{key:"balance",label:"Balance"},{key:"isContract",label:"Is Contract",renderValue:i=>i?"Yes":"No"},{key:"contractClassID",label:"Class ID"},{key:"deployer",label:"Deployer"},{key:"version",label:"Version"},{key:"blockNumber",label:"Block Number"},{key:"blockHash",label:"Block Hash"},{key:"creationTimestamp",label:"Creation Time"},{key:"txHash",label:"Transaction Hash"},{key:"privateFunctionsRoot",label:"Private Functions Root"}],n=[{title:"Summary",icon:M.jsx(vr,{variant:"blue",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(W7,{className:"w-4 h-4"})}),fields:["address","balance","isContract"]},{title:"Contract Details",icon:M.jsx(vr,{variant:"pink",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(Nm,{className:"w-4 h-4"})}),fields:["contractClassID","deployer","version"]},{title:"Creation Info",icon:M.jsx(vr,{variant:"yellow",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(Zf,{className:"w-4 h-4"})}),fields:["blockNumber","blockHash","creationTimestamp","txHash"]},{title:"Functions",icon:M.jsx(vr,{variant:"purple",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(w6,{className:"w-4 h-4"})}),fields:["privateFunctionsRoot"]}];return M.jsx(kg,{data:e,fields:r,groups:n,isLoading:t})},Aie="modulepreload",Cie=function(e){return"/"+e},BO={},f4=function(e,t,r){let n=Promise.resolve();if(t&&t.length>0){document.getElementsByTagName("link");const a=document.querySelector("meta[property=csp-nonce]"),s=(a==null?void 0:a.nonce)||(a==null?void 0:a.getAttribute("nonce"));n=Promise.allSettled(t.map(o=>{if(o=Cie(o),o in BO)return;BO[o]=!0;const c=o.endsWith(".css"),l=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${o}"]${l}`))return;const u=document.createElement("link");if(u.rel=c?"stylesheet":Aie,c||(u.as="script"),u.crossOrigin="",u.href=o,s&&u.setAttribute("nonce",s),document.head.appendChild(u),c)return new Promise((d,p)=>{u.addEventListener("load",d),u.addEventListener("error",()=>p(new Error(`Unable to preload CSS for ${o}`)))})}))}function i(a){const s=new Event("vite:preloadError",{cancelable:!0});if(s.payload=a,window.dispatchEvent(s),!s.defaultPrevented)throw a}return n.then(a=>{for(const s of a||[])s.status==="rejected"&&i(s.reason);return e().catch(i)})};var Tie={},RO={742:(e,t)=>{t.byteLength=l,t.toByteArray=d,t.fromByteArray=O;for(var r=[],n=[],i=typeof Uint8Array<"u"?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,o=a.length;s<o;++s)r[s]=a[s],n[a.charCodeAt(s)]=s;n[45]=62,n[95]=63;function c(I){var R=I.length;if(R%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var C=I.indexOf("=");C===-1&&(C=R);var j=C===R?0:4-C%4;return[C,j]}function l(I){var R=c(I),C=R[0],j=R[1];return(C+j)*3/4-j}function u(I,R,C){return(R+C)*3/4-C}function d(I){var R,C=c(I),j=C[0],N=C[1],P=new i(u(I,j,N)),Z=0,X=N>0?j-4:j,re;for(re=0;re<X;re+=4)R=n[I.charCodeAt(re)]<<18|n[I.charCodeAt(re+1)]<<12|n[I.charCodeAt(re+2)]<<6|n[I.charCodeAt(re+3)],P[Z++]=R>>16&255,P[Z++]=R>>8&255,P[Z++]=R&255;return N===2&&(R=n[I.charCodeAt(re)]<<2|n[I.charCodeAt(re+1)]>>4,P[Z++]=R&255),N===1&&(R=n[I.charCodeAt(re)]<<10|n[I.charCodeAt(re+1)]<<4|n[I.charCodeAt(re+2)]>>2,P[Z++]=R>>8&255,P[Z++]=R&255),P}function p(I){return r[I>>18&63]+r[I>>12&63]+r[I>>6&63]+r[I&63]}function w(I,R,C){for(var j,N=[],P=R;P<C;P+=3)j=(I[P]<<16&16711680)+(I[P+1]<<8&65280)+(I[P+2]&255),N.push(p(j));return N.join("")}function O(I){for(var R,C=I.length,j=C%3,N=[],P=16383,Z=0,X=C-j;Z<X;Z+=P)N.push(w(I,Z,Z+P>X?X:Z+P));return j===1?(R=I[C-1],N.push(r[R>>2]+r[R<<4&63]+"==")):j===2&&(R=(I[C-2]<<8)+I[C-1],N.push(r[R>>10]+r[R>>4&63]+r[R<<2&63]+"=")),N.join("")}},764:(e,t,r)=>{const n=r(742),i=r(645),a=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;t.lW=l,t.h2=50;const s=2147483647;l.TYPED_ARRAY_SUPPORT=o(),!l.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function o(){try{const z=new Uint8Array(1),H={foo:function(){return 42}};return Object.setPrototypeOf(H,Uint8Array.prototype),Object.setPrototypeOf(z,H),z.foo()===42}catch{return!1}}Object.defineProperty(l.prototype,"parent",{enumerable:!0,get:function(){if(l.isBuffer(this))return this.buffer}}),Object.defineProperty(l.prototype,"offset",{enumerable:!0,get:function(){if(l.isBuffer(this))return this.byteOffset}});function c(z){if(z>
vendor: 6,142 bytes, line 33
33s)throw new RangeError('The value "'+z+'" is invalid for option "size"');const H=new Uint8Array(z);return Object.setPrototypeOf(H,l.prototype),H}function l(z,H,k){if(typeof z=="number"){if(typeof H=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return w(z)}return u(z,H,k)}l.poolSize=8192;function u(z,H,k){if(typeof z=="string")return O(z,H);if(ArrayBuffer.isView(z))return R(z);if(z==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof z);if(Fe(z,ArrayBuffer)||z&&Fe(z.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(Fe(z,SharedArrayBuffer)||z&&Fe(z.buffer,SharedArrayBuffer)))return C(z,H,k);if(typeof z=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const L=z.valueOf&&z.valueOf();if(L!=null&&L!==z)return l.from(L,H,k);const q=j(z);if(q)return q;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof z[Symbol.toPrimitive]=="function")return l.from(z[Symbol.toPrimitive]("string"),H,k);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof z)}l.from=function(z,H,k){return u(z,H,k)},Object.setPrototypeOf(l.prototype,Uint8Array.prototype),Object.setPrototypeOf(l,Uint8Array);function d(z){if(typeof z!="number")throw new TypeError('"size" argument must be of type number');if(z<0)throw new RangeError('The value "'+z+'" is invalid for option "size"')}function p(z,H,k){return d(z),z<=0?c(z):H!==void 0?typeof k=="string"?c(z).fill(H,k):c(z).fill(H):c(z)}l.alloc=function(z,H,k){return p(z,H,k)};function w(z){return d(z),c(z<0?0:N(z)|0)}l.allocUnsafe=function(z){return w(z)},l.allocUnsafeSlow=function(z){return w(z)};function O(z,H){if((typeof H!="string"||H==="")&&(H="utf8"),!l.isEncoding(H))throw new TypeError("Unknown encoding: "+H);const k=P(z,H)|0;let L=c(k);const q=L.write(z,H);return q!==k&&(L=L.slice(0,q)),L}function I(z){const H=z.length<0?0:N(z.length)|0,k=c(H);for(let L=0;L<H;L+=1)k[L]=z[L]&255;return k}function R(z){if(Fe(z,Uint8Array)){const H=new Uint8Array(z);return C(H.buffer,H.byteOffset,H.byteLength)}return I(z)}function C(z,H,k){if(H<0||z.byteLength<H)throw new RangeError('"offset" is outside of buffer bounds');if(z.byteLength<H+(k||0))throw new RangeError('"length" is outside of buffer bounds');let L;return H===void 0&&k===void 0?L=new Uint8Array(z):k===void 0?L=new Uint8Array(z,H):L=new Uint8Array(z,H,k),Object.setPrototypeOf(L,l.prototype),L}function j(z){if(l.isBuffer(z)){const H=N(z.length)|0,k=c(H);return k.length===0||z.copy(k,0,0,H),k}if(z.length!==void 0)return typeof z.length!="number"||ge(z.length)?c(0):I(z);if(z.type==="Buffer"&&Array.isArray(z.data))return I(z.data)}function N(z){if(z>=s)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s.toString(16)+" bytes");return z|0}l.isBuffer=function(z){return z!=null&&z._isBuffer===!0&&z!==l.prototype},l.compare=function(z,H){if(Fe(z,Uint8Array)&&(z=l.from(z,z.offset,z.byteLength)),Fe(H,Uint8Array)&&(H=l.from(H,H.offset,H.byteLength)),!l.isBuffer(z)||!l.isBuffer(H))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(z===H)return 0;let k=z.length,L=H.length;for(let q=0,ie=Math.min(k,L);q<ie;++q)if(z[q]!==H[q]){k=z[q],L=H[q];break}return k<L?-1:L<k?1:0},l.isEncoding=function(z){switch(String(z).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},l.concat=function(z,H){if(!Array.isArray(z))throw new TypeError('"list" argument must be an Array of Buffers');if(z.length===0)return l.alloc(0);let k;if(H===void 0)for(H=0,k=0;k<z.length;++k)H+=z[k].length;const L=l.allocUnsafe(H);let q=0;for(k=0;k<z.length;++k){let ie=z[k];if(Fe(ie,Uint8Array))q+ie.length>L.length?(l.isBuffer(ie)||(ie=l.from(ie)),ie.copy(L,q)):Uint8Array.prototype.set.call(L,ie,q);else if(l.isBuffer(ie))ie.copy(L,q);else throw new TypeError('"list" argument must be an Array of Buffers');q+=ie.length}return L};function P(z,H){if(l.isBuffer(z))return z.length;if(ArrayBuffer.isView(z)||Fe(z,ArrayBuffer))return z.byteLength;if(typeof z!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof z);const k=z.length,L=arguments.length>2&&arguments[2]===!0;if(!L&&k===0)return 0;let q=!1;for(;;)switch(H){case"ascii":case"latin1":case"binary":return k;case"utf8":case"utf-8":return $e(z).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return k*2;case"hex":return k>>>1;case"base64":return Ke(z).length;default:if(q)return L?-1:$e(z).length;H=(""+H).toLowerCase(),q=!0}}l.byteLength=P;function Z(z,H,k){let L=!1;if((H===void 0||H<0)&&(H=0),H>this.length||((k===void 0||k>this.length)&&(k=this.length),k<=0)||(k>>>=0,H>>>=0,k<=H))return"";for(z||(z="utf8");;)switch(z){case"hex":return x(this,H,k);case"utf8":case"utf-8":return _(this,H,k);case"ascii":return S(this,H,k);case"latin1":case"binary":return h(this,H,k);case"base64":return g(this,H,k);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return v(this,H,k);default:if(L)throw new TypeError("Unknown encoding: "+z);z=(z+"").toLowerCase(),L=!0}}l.prototype._isBuffer=!0;function X(z,H,k){const L=z[H];z[H]=z[k],z[k]=L}l.prototype.swap16=function(){const z=this.length;if(z%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let H=0;H<z;H+=2)X(this,H,H+1);return this},l.prototype.swap32=function(){const z=this.length;if(z%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let H=0;H<z;H+=4)X(this,H,H+3),X(this,H+1,H+2);return this},l.prototype.swap64=function(){const z=this.length;if(z%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let H=0;H<z;H+=8)X(this,H,H+7),X(this,H+1,H+6),X(this,H+2,H+5),X(this,H+3,H+4);return this},l.prototype.toString=function(){const z=this.length;return z===0?"":arguments.length===0?_(this,0,z):Z.apply(this,arguments)}
vendor: 14,269 bytes, line 33
33,l.prototype.toLocaleString=l.prototype.toString,l.prototype.equals=function(z){if(!l.isBuffer(z))throw new TypeError("Argument must be a Buffer");return this===z?!0:l.compare(this,z)===0},l.prototype.inspect=function(){let z="";const H=t.h2;return z=this.toString("hex",0,H).replace(/(.{2})/g,"$1 ").trim(),this.length>H&&(z+=" ... "),"<Buffer "+z+">"},a&&(l.prototype[a]=l.prototype.inspect),l.prototype.compare=function(z,H,k,L,q){if(Fe(z,Uint8Array)&&(z=l.from(z,z.offset,z.byteLength)),!l.isBuffer(z))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof z);if(H===void 0&&(H=0),k===void 0&&(k=z?z.length:0),L===void 0&&(L=0),q===void 0&&(q=this.length),H<0||k>z.length||L<0||q>this.length)throw new RangeError("out of range index");if(L>=q&&H>=k)return 0;if(L>=q)return-1;if(H>=k)return 1;if(H>>>=0,k>>>=0,L>>>=0,q>>>=0,this===z)return 0;let ie=q-L,fe=k-H;const be=Math.min(ie,fe),Ce=this.slice(L,q),ze=z.slice(H,k);for(let Ie=0;Ie<be;++Ie)if(Ce[Ie]!==ze[Ie]){ie=Ce[Ie],fe=ze[Ie];break}return ie<fe?-1:fe<ie?1:0};function re(z,H,k,L,q){if(z.length===0)return-1;if(typeof k=="string"?(L=k,k=0):k>2147483647?k=2147483647:k<-2147483648&&(k=-2147483648),k=+k,ge(k)&&(k=q?0:z.length-1),k<0&&(k=z.length+k),k>=z.length){if(q)return-1;k=z.length-1}else if(k<0)if(q)k=0;else return-1;if(typeof H=="string"&&(H=l.from(H,L)),l.isBuffer(H))return H.length===0?-1:ne(z,H,k,L,q);if(typeof H=="number")return H=H&255,typeof Uint8Array.prototype.indexOf=="function"?q?Uint8Array.prototype.indexOf.call(z,H,k):Uint8Array.prototype.lastIndexOf.call(z,H,k):ne(z,[H],k,L,q);throw new TypeError("val must be string, number or Buffer")}function ne(z,H,k,L,q){let ie=1,fe=z.length,be=H.length;if(L!==void 0&&(L=String(L).toLowerCase(),L==="ucs2"||L==="ucs-2"||L==="utf16le"||L==="utf-16le")){if(z.length<2||H.length<2)return-1;ie=2,fe/=2,be/=2,k/=2}function Ce(Ie,qe){return ie===1?Ie[qe]:Ie.readUInt16BE(qe*ie)}let ze;if(q){let Ie=-1;for(ze=k;ze<fe;ze++)if(Ce(z,ze)===Ce(H,Ie===-1?0:ze-Ie)){if(Ie===-1&&(Ie=ze),ze-Ie+1===be)return Ie*ie}else Ie!==-1&&(ze-=ze-Ie),Ie=-1}else for(k+be>fe&&(k=fe-be),ze=k;ze>=0;ze--){let Ie=!0;for(let qe=0;qe<be;qe++)if(Ce(z,ze+qe)!==Ce(H,qe)){Ie=!1;break}if(Ie)return ze}return-1}l.prototype.includes=function(z,H,k){return this.indexOf(z,H,k)!==-1},l.prototype.indexOf=function(z,H,k){return re(this,z,H,k,!0)},l.prototype.lastIndexOf=function(z,H,k){return re(this,z,H,k,!1)};function ae(z,H,k,L){k=Number(k)||0;const q=z.length-k;L?(L=Number(L),L>q&&(L=q)):L=q;const ie=H.length;L>ie/2&&(L=ie/2);let fe;for(fe=0;fe<L;++fe){const be=parseInt(H.substr(fe*2,2),16);if(ge(be))return fe;z[k+fe]=be}return fe}function ue(z,H,k,L){return ut($e(H,z.length-k),z,k,L)}function m(z,H,k,L){return ut(Ae(H),z,k,L)}function A(z,H,k,L){return ut(Ke(H),z,k,L)}function f(z,H,k,L){return ut(De(H,z.length-k),z,k,L)}l.prototype.write=function(z,H,k,L){if(H===void 0)L="utf8",k=this.length,H=0;else if(k===void 0&&typeof H=="string")L=H,k=this.length,H=0;else if(isFinite(H))H=H>>>0,isFinite(k)?(k=k>>>0,L===void 0&&(L="utf8")):(L=k,k=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const q=this.length-H;if((k===void 0||k>q)&&(k=q),z.length>0&&(k<0||H<0)||H>this.length)throw new RangeError("Attempt to write outside buffer bounds");L||(L="utf8");let ie=!1;for(;;)switch(L){case"hex":return ae(this,z,H,k);case"utf8":case"utf-8":return ue(this,z,H,k);case"ascii":case"latin1":case"binary":return m(this,z,H,k);case"base64":return A(this,z,H,k);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return f(this,z,H,k);default:if(ie)throw new TypeError("Unknown encoding: "+L);L=(""+L).toLowerCase(),ie=!0}},l.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function g(z,H,k){return H===0&&k===z.length?n.fromByteArray(z):n.fromByteArray(z.slice(H,k))}function _(z,H,k){k=Math.min(z.length,k);const L=[];let q=H;for(;q<k;){const ie=z[q];let fe=null,be=ie>239?4:ie>223?3:ie>191?2:1;if(q+be<=k){let Ce,ze,Ie,qe;switch(be){case 1:ie<128&&(fe=ie);break;case 2:Ce=z[q+1],(Ce&192)===128&&(qe=(ie&31)<<6|Ce&63,qe>127&&(fe=qe));break;case 3:Ce=z[q+1],ze=z[q+2],(Ce&192)===128&&(ze&192)===128&&(qe=(ie&15)<<12|(Ce&63)<<6|ze&63,qe>2047&&(qe<55296||qe>57343)&&(fe=qe));break;case 4:Ce=z[q+1],ze=z[q+2],Ie=z[q+3],(Ce&192)===128&&(ze&192)===128&&(Ie&192)===128&&(qe=(ie&15)<<18|(Ce&63)<<12|(ze&63)<<6|Ie&63,qe>65535&&qe<1114112&&(fe=qe))}}fe===null?(fe=65533,be=1):fe>65535&&(fe-=65536,L.push(fe>>>10&1023|55296),fe=56320|fe&1023),L.push(fe),q+=be}return T(L)}const B=4096;function T(z){const H=z.length;if(H<=B)return String.fromCharCode.apply(String,z);let k="",L=0;for(;L<H;)k+=String.fromCharCode.apply(String,z.slice(L,L+=B));return k}function S(z,H,k){let L="";k=Math.min(z.length,k);for(let q=H;q<k;++q)L+=String.fromCharCode(z[q]&127);return L}function h(z,H,k){let L="";k=Math.min(z.length,k);for(let q=H;q<k;++q)L+=String.fromCharCode(z[q]);return L}function x(z,H,k){const L=z.length;(!H||H<0)&&(H=0),(!k||k<0||k>L)&&(k=L);let q="";for(let ie=H;ie<k;++ie)q+=we[z[ie]];return q}function v(z,H,k){const L=z.slice(H,k);let q="";for(let ie=0;ie<L.length-1;ie+=2)q+=String.fromCharCode(L[ie]+L[ie+1]*256);return q}l.prototype.slice=function(z,H){const k=this.length;z=~~z,H=H===void 0?k:~~H,z<0?(z+=k,z<0&&(z=0)):z>k&&(z=k),H<0?(H+=k,H<0&&(H=0)):H>k&&(H=k),H<z&&(H=z);const L=this.subarray(z,H);return Object.setPrototypeOf(L,l.prototype),L};function F(z,H,k){if(z%1!==0||z<0)throw new RangeError("offset is not uint");if(z+H>k)throw new RangeError("Trying to access beyond buffer length")}l.prototype.readUintLE=l.prototype.readUIntLE=function(z,H,k){z=z>>>0,H=H>>>0,k||F(z,H,this.length);let L=this[z],q=1,ie=0;for(;++ie<H&&(q*=256);)L+=this[z+ie]*q;return L},l.prototype.readUintBE=l.prototype.readUIntBE=function(z,H,k){z=z>>>0,H=H>>>0,k||F(z,H,this.length);let L=this[z+--H],q=1;for(;H>0&&(q*=256);)L+=this[z+--H]*q;return L},l.prototype.readUint8=l.prototype.readUInt8=function(z,H){return z=z>>>0,H||F(z,1,this.length),this[z]},l.prototype.readUint16LE=l.prototype.readUInt16LE=function(z,H){return z=z>>>0,H||F(z,2,this.length),this[z]|this[z+1]<<8},l.prototype.readUint16BE=l.prototype.readUInt16BE=function(z,H){return z=z>>>0,H||F(z,2,this.length),this[z]<<8|this[z+1]},l.prototype.readUint32LE=l.prototype.readUInt32LE=function(z,H){return z=z>>>0,H||F(z,4,this.length),(this[z]|this[z+1]<<8|this[z+2]<<16)+this[z+3]*16777216},l.prototype.readUint32BE=l.prototype.readUInt32BE=function(z,H){return z=z>>>0,H||F(z,4,this.length),this[z]*16777216+(this[z+1]<<16|this[z+2]<<8|this[z+3])},l.prototype.readBigUInt64LE=ke(function(z){z=z>>>0,_e(z,"offset");const H=this[z],k=this[z+7];(H===void 0||k===void 0)&&Ue(z,this.length-8);const L=H+this[++z]*2**8+this[++z]*2**16+this[++z]*2**24,q=this[++z]+this[++z]*2**8+this[++z]*2**16+k*2**24;return BigInt(L)+(BigInt(q)<<BigInt(32))}),l.prototype.readBigUInt64BE=ke(function(z){z=z>>>0,_e(z,"offset");const H=this[z],k=this[z+7];(H===void 0||k===void 0)&&Ue(z,this.length-8);const L=H*2**24+this[++z]*2**16+this[++z]*2**8+this[++z],q=this[++z]*2**24+this[++z]*2**16+this[++z]*2**8+k;return(BigInt(L)<<BigInt(32))+BigInt(q)}),l.prototype.readIntLE=function(z,H,k){z=z>>>0,H=H>>>0,k||F(z,H,this.length);let L=this[z],q=1,ie=0;for(;++ie<H&&(q*=256);)L+=this[z+ie]*q;return q*=128,L>=q&&(L-=Math.pow(2,8*H)),L},l.prototype.readIntBE=function(z,H,k){z=z>>>0,H=H>>>0,k||F(z,H,this.length);let L=H,q=1,ie=this[z+--L];for(;L>0&&(q*=256);)ie+=this[z+--L]*q;return q*=128,ie>=q&&(ie-=Math.pow(2,8*H)),ie},l.prototype.readInt8=function(z,H){return z=z>>>0,H||F(z,1,this.length),this[z]&128?(255-this[z]+1)*-1:this[z]},l.prototype.readInt16LE=function(z,H){z=z>>>0,H||F(z,2,this.length);const k=this[z]|this[z+1]<<8;return k&32768?k|4294901760:k},l.prototype.readInt16BE=function(z,H){z=z>>>0,H||F(z,2,this.length);const k=this[z+1]|this[z]<<8;return k&32768?k|4294901760:k},l.prototype.readInt32LE=function(z,H){return z=z>>>0,H||F(z,4,this.length),this[z]|this[z+1]<<8|this[z+2]<<16|this[z+3]<<24},l.prototype.readInt32BE=function(z,H){return z=z>>>0,H||F(z,4,this.length),this[z]<<24|this[z+1]<<16|this[z+2]<<8|this[z+3]},l.prototype.readBigInt64LE=ke(function(z){z=z>>>0,_e(z,"offset");const H=this[z],k=this[z+7];(H===void 0||k===void 0)&&Ue(z,this.length-8);const L=this[z+4]+this[z+5]*2**8+this[z+6]*2**16+(k<<24);return(BigInt(L)<<BigInt(32))+BigInt(H+this[++z]*2**8+this[++z]*2**16+this[++z]*2**24)}),l.prototype.readBigInt64BE=ke(function(z){z=z>>>0,_e(z,"offset");const H=this[z],k=this[z+7];(H===void 0||k===void 0)&&Ue(z,this.length-8);const L=(H<<24)+this[++z]*2**16+this[++z]*2**8+this[++z];return(BigInt(L)<<BigInt(32))+BigInt(this[++z]*2**24+this[++z]*2**16+this[++z]*2**8+k)}),l.prototype.readFloatLE=function(z,H){return z=z>>>0,H||F(z,4,this.length),i.read(this,z,!0,23,4)},l.prototype.readFloatBE=function(z,H){return z=z>>>0,H||F(z,4,this.length),i.read(this,z,!1,23,4)},l.prototype.readDoubleLE=function(z,H){return z=z>>>0,H||F(z,8,this.length),i.read(this,z,!0,52,8)},l.prototype.readDoubleBE=function(z,H){return z=z>>>0,H||F(z,8,this.length),i.read(this,z,!1,52,8)};function Q(z,H,k,L,q,ie){if(!l.isBuffer(z))throw new TypeError('"buffer" argument must be a Buffer instance');if(H>q||H<ie)throw new RangeError('"value" argument is out of bounds');if(k+L>z.length)throw new RangeError("Index out of range")}l.prototype.writeUintLE=l.prototype.writeUIntLE=function(z,H,k,L){if(z=+z,H=H>>>0,k=k>>>0,!L){const fe=Math.pow(2,8*k)-1;Q(this,z,H,k,fe,0)}let q=1,ie=0;for(this[H]=z&255;++ie<k&&(q*=256);)this[H+ie]=z/q&255;return H+k},l.prototype.writeUintBE=l.prototype.writeUIntBE=function(z,H,k,L){if(z=+z,H=H>>>0,k=k>>>0,!L){const fe=Math.pow(2,8*k)-1;Q(this,z,H,k,fe,0)}let q=k-1,ie=1;for(this[H+q]=z&255;--q>=0&&(ie*=256);)this[H+q]=z/ie&255;return H+k},l.prototype.writeUint8=l.prototype.writeUInt8=function(z,H,k){return z=+z,H=H>>>0,k||Q(this,z,H,1,255,0),this[H]=z&255,H+1},l.prototype.writeUint16LE=l.prototype.writeUInt16LE=function(z,H,k){return z=+z,H=H>>>0,k||Q(this,z,H,2,65535,0),this[H]=z&255,this[H+1]=z>>>8,H+2},l.prototype.writeUint16BE=l.prototype.writeUInt16BE=function(z,H,k){return z=+z,H=H>>>0,k||Q(this,z,H,2,65535,0),this[H]=z>>>8,this[H+1]=z&255,H+2},l.prototype.writeUint32LE=l.prototype.writeUInt32LE=function(z,H,k){return z=+z,H=H>>>0,k||Q(this,z,H,4,4294967295,0),this[H+3]=z>>>24,this[H+2]=z>>>16,this[H+1]=z>>>8,this[H]=z&255,H+4},l.prototype.writeUint32BE=l.prototype.writeUInt32BE=function(z,H,k){return z=+z,H=H>>>0,k||Q(this,z,H,4,4294967295,0),this[H]=z>>>24,this[H+1]=z>>>16,this[H+2]=z>>>8,this[H+3]=z&255,H+4};function G(z,H,k,L,q){ve(H,L,q,z,k,7);let ie=Number(H&BigInt(4294967295));z[k++]=ie,ie=ie>>8,z[k++]=ie,ie=ie>>8,z[k++]=ie,ie=ie>>8,z[k++]=ie;let fe=Number(H>>BigInt(32)&BigInt(4294967295));return z[k++]=fe,fe=fe>>8,z[k++]=fe,fe=fe>>8,z[k++]=fe,fe=fe>>8,z[k++]=fe,k}function J(z,H,k,L,q){ve(H,L,q,z,k,7);let ie=Number(H&BigInt(4294967295));z[k+7]=ie,ie=ie>>8,z[k+6]=ie,ie=ie>>8,z[k+5]=ie,ie=ie>>8,z[k+4]=ie;let fe=Number(H>>BigInt(32)&BigInt(4294967295));return z[k+3]=fe,fe=fe>>8,z[k+2]=fe,fe=fe>>8,z[k+1]=fe,fe=fe>>8,z[k]=fe,k+8}l.prototype.writeBigUInt64LE=ke(function(z,H=0){return G(this,z,H,BigInt(0),BigInt("0xffffffffffffffff"))}),l.prototype.writeBigUInt64BE=ke(function(z,H=0){return J(this,z,H,BigInt(0),BigInt("0xffffffffffffffff"))}),l.prototype.writeIntLE=function(z,H,k,L){if(z=+z,H=H>>>0,!L){const be=Math.pow(2,8*k-1);Q(this,z,H,k,be-1,-be)}let q=0,ie=1,fe=0;for(this[H]=z&255;++q<k&&(ie*=256);)z<0&&fe===0&&this[H+q-1]!==0&&(fe=1),this[H+q]=(z/ie>>0)-fe&255;return H+k},l.prototype.writeIntBE=function(z,H,k,L){if(z=+z,H=H>>>0,!L){const be=Math.pow(2,8*k-1);Q(this,z,H,k,be-1,-be)}let q=k-1,ie=1,fe=0;for(this[H+q]=z&255;--q>=0&&(ie*=256);)z<0&&fe===0&&this[H+q+1]!==0&&(fe=1),this[H+q]=(z/ie>>0)-fe&255;return H+k},l.prototype.writeInt8=function(z,H,k){return z=+z,H=H>>>0,k||Q(this,z,H,1,127,-128),z<0&&(z=255+z+1),this[H]=z&255,H+1},l.prototype.writeInt16LE=function(z,H,k){return z=+z,H=H>>>0,k||Q(this,z,H,2,32767,-32768),this[H]=z&255,this[H+1]=z>>>8,H+2},l.prototype.writeInt16BE=function(z,H,k){return z=+z,H=H>>>0,k||Q(this,z,H,2,32767,-32768),this[H]=z>>>8,this[H+1]=z&255,H+2},l.prototype.writeInt32LE=function(z,H,k){return z=+z,H=H>>>0,k||Q(this,z,H,4,2147483647,-2147483648),this[H]=z&255,this[H+1]=z>>>8,this[H+2]=z>>>16,this[H+3]=z>>>24,H+4},l.prototype.writeInt32BE=function(z,H,k){return z=+z,H=H>>>0,k||Q(this,z,H,4,2147483647,-2147483648),z<0&&(z=4294967295+z+1),this[H]=z>>>24,this[H+1]=z>>>16,this[H+2]=z>>>8,this[H+3]=z&255,H+4},l.prototype.writeBigInt64LE=ke(function(z,H=0){return G(this,z,H,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),l.prototype.writeBigInt64BE=ke(function(z,H=0){return J(this,z,H,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function Y(z,H,k,L,q,ie){if(k+L>z.length)throw new RangeError("Index out of range");if(k<0)throw new RangeError("Index out of range")}function V(z,H,k,L,q){return H=+H,k=k>>>0,q||Y(z,H,k,4),i.write(z,H,k,L,23,4),k+4}l.prototype.writeFloatLE=function(z,H,k){return V(this,z,H,!0,k)},l.prototype.writeFloatBE=function(z,H,k){return V(this,z,H,!1,k)};function W(z,H,k,L,q){return H=+H,k=k>>>0,q||Y(z,H,k,8),i.write(z,H,k,L,52,8),k+8}l.prototype.writeDoubleLE=function(z,H,k){return W(this,z,H,!0,k)},l.prototype.writeDoubleBE=function(z,H,k){return W(this,z,H,!1,k)},l.prototype.copy=function(z,H,k,L){if(!l.isBuffer(z))throw new TypeError("argument should be a Buffer");if(k||(k=0),!L&&L!==0&&(L=this.length),H>=z.length&&(H=z.length),H||(H=0),L>0&&L<k&&(L=k),L===k||z.length===0||this.length===0)return 0;if(H<0)throw new RangeError("targetStart out of bounds");if(k<0||k>=this.length)throw new RangeError("Index out of range");if(L<0)throw new RangeError("sourceEnd out of bounds");L>this.length&&(L=this.length),z.length-H<L-k&&(L=z.length-H+k);const q=L-k;return this===z&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(H,k,L):Uint8Array.prototype.set.call(z,this.subarray(k,L),H),q},l.prototype.fill=function(z,H,k,L){if(typeof z=="string"){if(typeof H=="string"?(L=H,H=0,k=this.length):typeof k=="string"&&(L=k,k=this.length),L!==void 0&&typeof L!="str
33ing")throw new TypeError("encoding must be a string");if(typeof L=="string"&&!l.isEncoding(L))throw new TypeError("Unknown encoding: "+L);if(z.length===1){const ie=z.charCodeAt(0);(L==="utf8"&&ie<128||L==="latin1")&&(z=ie)}}else typeof z=="number"?z=z&255:typeof z=="boolean"&&(z=Number(z));if(H<0||this.length<H||this.length<k)throw new RangeError("Out of range index");if(k<=H)return this;H=H>>>0,k=k===void 0?this.length:k>>>0,z||(z=0);let q;if(typeof z=="number")for(q=H;q<k;++q)this[q]=z;else{const ie=l.isBuffer(z)?z:l.from(z,L),fe=ie.length;if(fe===0)throw new TypeError('The value "'+z+'" is invalid for argument "value"');for(q=0;q<k-H;++q)this[q+H]=ie[q%fe]}return this};const ce={};function pe(z,H,k){ce[z]=class extends k{constructor(){super(),Object.defineProperty(this,"message",{value:H.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${z}]`,this.stack,delete this.name}get code(){return z}set code(L){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:L,writable:!0})}toString(){return`${this.name} [${z}]: ${this.message}`}}}pe("ERR_BUFFER_OUT_OF_BOUNDS",function(z){return z?`${z} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),pe("ERR_INVALID_ARG_TYPE",function(z,H){return`The "${z}" argument must be of type number. Received type ${typeof H}`},TypeError),pe("ERR_OUT_OF_RANGE",function(z,H,k){let L=`The value of "${z}" is out of range.`,q=k;return Number.isInteger(k)&&Math.abs(k)>2**32?q=ee(String(k)):typeof k=="bigint"&&(q=String(k),(k>BigInt(2)**BigInt(32)||k<-(BigInt(2)**BigInt(32)))&&(q=ee(q)),q+="n"),L+=` It must be ${H}. Received ${q}`,L},RangeError);function ee(z){let H="",k=z.length;const L=z[0]==="-"?1:0;for(;k>=L+4;k-=3)H=`_${z.slice(k-3,k)}${H}`;return`${z.slice(0,k)}${H}`}function se(z,H,k){_e(H,"offset"),(z[H]===void 0||z[H+k]===void 0)&&Ue(H,z.length-(k+1))}function ve(z,H,k,L,q,ie){if(z>k||z<H){const fe=typeof H=="bigint"?"n":"";let be;throw H===0||H===BigInt(0)?be=`>= 0${fe} and < 2${fe} ** ${(ie+1)*8}${fe}`:be=`>= -(2${fe} ** ${(ie+1)*8-1}${fe}) and < 2 ** ${(ie+1)*8-1}${fe}`,new ce.ERR_OUT_OF_RANGE("value",be,z)}se(L,q,ie)}function _e(z,H){if(typeof z!="number")throw new ce.ERR_INVALID_ARG_TYPE(H,"number",z)}function Ue(z,H,k){throw Math.floor(z)!==z?(_e(z,k),new ce.ERR_OUT_OF_RANGE("offset","an integer",z)):H<0?new ce.ERR_BUFFER_OUT_OF_BOUNDS:new ce.ERR_OUT_OF_RANGE("offset",`>= 0 and <= ${H}`,z)}const xe=/[^+/0-9A-Za-z-_]/g;function Te(z){if(z=z.split("=")[0],z=z.trim().replace(xe,""),z.length<2)return"";for(;z.length%4!==0;)z=z+"=";return z}function $e(z,H){H=H||1/0;let k;const L=z.length;let q=null;const ie=[];for(let fe=0;fe<L;++fe){if(k=z.charCodeAt(fe),k>55295&&k<57344){if(!q){if(k>56319){(H-=3)>-1&&ie.push(239,191,189);continue}else if(fe+1===L){(H-=3)>-1&&ie.push(239,191,189);continue}q=k;continue}if(k<56320){(H-=3)>-1&&ie.push(239,191,189),q=k;continue}k=(q-55296<<10|k-56320)+65536}else q&&(H-=3)>-1&&ie.push(239,191,189);if(q=null,k<128){if((H-=1)<0)break;ie.push(k)}else if(k<2048){if((H-=2)<0)break;ie.push(k>>6|192,k&63|128)}else if(k<65536){if((H-=3)<0)break;ie.push(k>>12|224,k>>6&63|128,k&63|128)}else if(k<1114112){if((H-=4)<0)break;ie.push(k>>18|240,k>>12&63|128,k>>6&63|128,k&63|128)}else throw new Error("Invalid code point")}return ie}function Ae(z){const H=[];for(let k=0;k<z.length;++k)H.push(z.charCodeAt(k)&255);return H}function De(z,H){let k,L,q;const ie=[];for(let fe=0;fe<z.length&&!((H-=2)<0);++fe)k=z.charCodeAt(fe),L=k>>8,q=k%256,ie.push(q),ie.push(L);return ie}function Ke(z){return n.toByteArray(Te(z))}function ut(z,H,k,L){let q;for(q=0;q<L&&!(q+k>=H.length||q>=z.length);++q)H[q+k]=z[q];return q}function Fe(z,H){return z instanceof H||z!=null&&z.constructor!=null&&z.constructor.name!=null&&z.constructor.name===H.name}function ge(z){return z!==z}const we=function(){const z="0123456789abcdef",H=new Array(256);for(let k=0;k<16;++k){const L=k*16;for(let q=0;q<16;++q)H[L+q]=z[k]+z[q]}return H}();function ke(z){return typeof BigInt>"u"?Ne:z}function Ne(){throw new Error("BigInt not supported")}},227:(e,t,r)=>{t.formatArgs=i,t.save=a,t.load=s,t.useColors=n,t.storage=o(),t.destroy=(()=>{let l=!1;return()=>{l||(l=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33
33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function n(){return typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)?!0:typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)?!1:typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function i(l){if(l[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+l[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const u="color: "+this.color;l.splice(1,0,u,"color: inherit");let d=0,p=0;l[0].replace(/%[a-zA-Z%]/g,w=>{w!=="%%"&&(d++,w==="%c"&&(p=d))}),l.splice(p,0,u)}t.log=console.debug||console.log||(()=>{});function a(l){try{l?t.storage.setItem("debug",l):t.storage.removeItem("debug")}catch{}}function s(){let l;try{l=t.storage.getItem("debug")}catch{}return!l&&typeof ot<"u"&&"env"in ot&&(l=Tie.DEBUG),l}function o(){try{return localStorage}catch{}}e.exports=r(447)(t);const{formatters:c}=e.exports;c.j=function(l){try{return JSON.stringify(l)}catch(u){return"[UnexpectedJSONParseError]: "+u.message}}},447:(e,t,r)=>{function n(i){s.debug=s,s.default=s,s.coerce=p,s.disable=l,s.enable=c,s.enabled=u,s.humanize=r(824),s.destroy=w,Object.keys(i).forEac
vendor: 4,382 bytes, line 33
33h(O=>{s[O]=i[O]}),s.names=[],s.skips=[],s.formatters={};function a(O){let I=0;for(let R=0;R<O.length;R++)I=(I<<5)-I+O.charCodeAt(R),I|=0;return s.colors[Math.abs(I)%s.colors.length]}s.selectColor=a;function s(O){let I,R=null,C,j;function N(...P){if(!N.enabled)return;const Z=N,X=Number(new Date),re=X-(I||X);Z.diff=re,Z.prev=I,Z.curr=X,I=X,P[0]=s.coerce(P[0]),typeof P[0]!="string"&&P.unshift("%O");let ne=0;P[0]=P[0].replace(/%([a-zA-Z%])/g,(ae,ue)=>{if(ae==="%%")return"%";ne++;const m=s.formatters[ue];if(typeof m=="function"){const A=P[ne];ae=m.call(Z,A),P.splice(ne,1),ne--}return ae}),s.formatArgs.call(Z,P),(Z.log||s.log).apply(Z,P)}return N.namespace=O,N.useColors=s.useColors(),N.color=s.selectColor(O),N.extend=o,N.destroy=s.destroy,Object.defineProperty(N,"enabled",{enumerable:!0,configurable:!1,get:()=>R!==null?R:(C!==s.namespaces&&(C=s.namespaces,j=s.enabled(O)),j),set:P=>{R=P}}),typeof s.init=="function"&&s.init(N),N}function o(O,I){const R=s(this.namespace+(typeof I>"u"?":":I)+O);return R.log=this.log,R}function c(O){s.save(O),s.namespaces=O,s.names=[],s.skips=[];let I;const R=(typeof O=="string"?O:"").split(/[\s,]+/),C=R.length;for(I=0;I<C;I++)R[I]&&(O=R[I].replace(/\*/g,".*?"),O[0]==="-"?s.skips.push(new RegExp("^"+O.slice(1)+"$")):s.names.push(new RegExp("^"+O+"$")))}function l(){const O=[...s.names.map(d),...s.skips.map(d).map(I=>"-"+I)].join(",");return s.enable(""),O}function u(O){if(O[O.length-1]==="*")return!0;let I,R;for(I=0,R=s.skips.length;I<R;I++)if(s.skips[I].test(O))return!1;for(I=0,R=s.names.length;I<R;I++)if(s.names[I].test(O))return!0;return!1}function d(O){return O.toString().substring(2,O.toString().length-2).replace(/\.\*\?$/,"*")}function p(O){return O instanceof Error?O.stack||O.message:O}function w(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return s.enable(s.load()),s}e.exports=n},645:(e,t)=>{t.read=function(r,n,i,a,s){var o,c,l=s*8-a-1,u=(1<<l)-1,d=u>>1,p=-7,w=i?s-1:0,O=i?-1:1,I=r[n+w];for(w+=O,o=I&(1<<-p)-1,I>>=-p,p+=l;p>0;o=o*256+r[n+w],w+=O,p-=8);for(c=o&(1<<-p)-1,o>>=-p,p+=a;p>0;c=c*256+r[n+w],w+=O,p-=8);if(o===0)o=1-d;else{if(o===u)return c?NaN:(I?-1:1)*(1/0);c=c+Math.pow(2,a),o=o-d}return(I?-1:1)*c*Math.pow(2,o-a)},t.write=function(r,n,i,a,s,o){var c,l,u,d=o*8-s-1,p=(1<<d)-1,w=p>>1,O=s===23?Math.pow(2,-24)-Math.pow(2,-77):0,I=a?0:o-1,R=a?1:-1,C=n<0||n===0&&1/n<0?1:0;for(n=Math.abs(n),isNaN(n)||n===1/0?(l=isNaN(n)?1:0,c=p):(c=Math.floor(Math.log(n)/Math.LN2),n*(u=Math.pow(2,-c))<1&&(c--,u*=2),c+w>=1?n+=O/u:n+=O*Math.pow(2,1-w),n*u>=2&&(c++,u/=2),c+w>=p?(l=0,c=p):c+w>=1?(l=(n*u-1)*Math.pow(2,s),c=c+w):(l=n*Math.pow(2,w-1)*Math.pow(2,s),c=0));s>=8;r[i+I]=l&255,I+=R,l/=256,s-=8);for(c=c<<s|l,d+=s;d>0;r[i+I]=c&255,I+=R,c/=256,d-=8);r[i+I-R]|=C*128}},824:e=>{var t=1e3,r=t*60,n=r*60,i=n*24,a=i*7,s=i*365.25;e.exports=function(d,p){p=p||{};var w=typeof d;if(w==="string"&&d.length>0)return o(d);if(w==="number"&&isFinite(d))return p.long?l(d):c(d);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(d))};function o(d){if(d=String(d),!(d.length>100)){var p=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(d);if(p){var w=parseFloat(p[1]),O=(p[2]||"ms").toLowerCase();switch(O){case"years":case"year":case"yrs":case"yr":case"y":return w*s;case"weeks":case"week":case"w":return w*a;case"days":case"day":case"d":return w*i;case"hours":case"hour":case"hrs":case"hr":case"h":return w*n;case"minutes":case"minute":case"mins":case"min":case"m":return w*r;case"seconds":case"second":case"secs":case"sec":case"s":return w*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return w;default:return}}}}function c(d){var p=Math.abs(d);return p>=i?Math.round(d/i)+"d":p>=n?Math.round(d/n)+"h":p>=r?Math.round(d/r)+"m":p>=t?Math.round(d/t)+"s":d+"ms"}function l(d){var p=Math.abs(d);return p>=i?u(d,p,i,"day"):p>=n?u(d,p,n,"hour"):p>=r?u(d,p,r,"minute"):p>=t?u(d,p,t,"second"):d+" ms"}function u(d,p,w,O){var I=p>=w*1.5;return Math.round(d/w)+" "+O+(I?"s":"")}},477:e=>{e.exports=function(t,r,n,i){var a=self||window;try{try{var s;try{s=new a.Blob([t])}catch{var o=a.BlobBuilder||a.WebKitBlobBuilder||a.MozBlobBuilder||a.MSBlobBuilder;s=new o,s.append(t),s=s.getBlob()}
33var c=a.URL||a.webkitURL,l=c.createObjectURL(s),u=new a[r](l,n);return c.revokeObjectURL(l),u}catch{return new a[r]("data:application/javascript,".concat(encodeURIComponent(t)),n)}}catch{if(!i)throw Error("Inline worker is not supported");return new a[r](i,n)}}}},NO={};function Yt(e){var t=NO[e];if(t!==void 0)return t.exports;var r=NO[e]={exports:{}};return RO[e](r,r.exports,Yt),r.exports}Yt.m=RO,Yt.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return Yt.d(t,{a:t}),t},(()=>{var e=Object.getPrototypeOf?r=>Object.getPrototypeOf(r):r=>r.__proto__,t;Yt.t=function(r,n){if(n&1&&(r=this(r)),n&8||typeof r=="object"&&r&&(n&4&&r.__esModule||n&16&&typeof r.then=="function"))return r;var i=Object.create(null);Yt.r(i);var a={};t=t||[null,e({}),e([]),e(e)];for(var s=n&2&&r;typeof s=="object"&&!~t.indexOf(s);s=e(s))Object.getOwnPropertyNames(s).forEach(o=>a[o]=()=>r[o]);return a.default=()=>r,Yt.d(i,a),i}})(),Yt.d=(e,t)=>{for(var r in t)Yt.o(t,r)&&!Yt.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},Yt.f={},Yt.e=e=>Promise.all(Object.keys(Yt.f).reduce((t,r)=>(Yt.f[r](e,t),t),[])),Yt.u=e=>""+e+".6386c00ebfb22619e11b.js",Yt.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={},t="@aztec/bb.js:";Yt.l=(r,n,i,a)=>{if(e[r]){e[r].push(n);return}var s,o;if(i!==void 0)for(var c=document.getElementsByTagName("script"),l=0;l<c.length;l++){var u=c[l];if(u.getAttribute("src")==r||u.getAttribute("data-webpack")==t+i){s=u;break}}s||(o=!0,s=document.createElement("script"),s.type="module",s.charset="utf-8",s.timeout=120,Yt.nc&&s.setAttribute("nonce",Yt.nc),s.setAttribute("data-webpack",t+i),s.src=r),e[r]=[n];var d=(w,O)=>{s.onerror=s.onload=null,clearTimeout(p);var I=e[r];if(delete e[r],s.parentNode&&s.parentNode.removeChild(s),I&&I.forEach(R=>R(O)),w)return w(O)},p=setTimeout(d.bind(null,void 0,{type:"timeout",target:s}),12e4);s.onerror=d.bind(null,s.onerror),s.onload=d.bind(null,s.onload),o&&document.head.appendChild(s)}})(),Yt.r=e=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e;if(typeof import.meta.url=="string"&&(e=import.meta.url),!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),Yt.p=e})(),(()=>{var e={826:0};Yt.f.j=(n,i)=>{var a=Yt.o(e,n)?e[n]:void 0;if(a!==0)if(a)i.push(a[2]);else{var s=new Promise((u,d)=>a=e[n]=[u,d]);i.push(a[2]=s);var o=Yt.p+Yt.u(n),c=new Error,l=u=>{if(Yt.o(e,n)&&(a=e[n],a!==0&&(e[n]=void 0),a)){var d=u&&(u.type==="load"?"missing":u.type),p=u&&u.target&&u.target.src;c.message="Loading chunk "+n+` failed.
34(`+d+": "+p+")",c.name="ChunkLoadError",c.type=d,c.request=p,a[1](c)}};Yt.l(o,l,"chunk-"+n,n)}};var t=(n,i)=>{var[a,s,o]=i,c,l,u=0;if(a.some(p=>e[p]!==0)){for(c in s)Yt.o(s,c)&&(Yt.m[c]=s[c]);if(o)var d=o(Yt)}for(n&&n(i);u<a.length;u++)l=a[u],Yt.o(e,l)&&e[l]&&e[l][0](),e[l]=0},r=globalThis.webpackChunk_aztec_bb_js=globalThis.webpackChunk_aztec_bb_js||[];r.forEach(t.bind(null,0)),r.push=t.bind(null,r.push.bind(r))})();var es={};(()=>{Yt.d(es,{Dv:()=>U_e,Zh:()=>pd,AL:()=>Y2,tD:()=>y_e,i2:()=>d,Fr:()=>ie,pS:()=>p,ld:()=>V,yh:()=>D_e,_7:()=>L_e,H2:()=>LE,ly:()=>zE});function*e(){const b=[1,1,1,2,4,8,16,32,64];let E=0;for(;;)yield b[Math.min(E++,b.length-1)]}function*t(b){for(const E of b)yield E}async function r(b,E=e()){for(;;)try{return await b()}catch(y){const D=E.next().value;if(D===void 0)throw y;await new Promise(U=>setTimeout(U,D*1e3));continue}}class n{constructor(E){this.numPoints=E}
34async init(){await this.downloadG1Data(),await this.downloadG2Data()}async streamG1Data(){return(await this.fetchG1Data()).body}async streamG2Data(){return(await this.fetchG2Data()).body}async downloadG1Data(){const E=await this.fetchG1Data();return this.data=new Uint8Array(await E.arrayBuffer())}async downloadG2Data(){const E=await this.fetchG2Data();return this.g2Data=new Uint8Array(await E.arrayBuffer())}getG1Data(){return this.data}getG2Data(){return this.g2Data}async fetchG1Data(){if(this.numPoints===0)return new Response(new Uint8Array([]));const E=this.numPoints*64-1;return await r(()=>fetch("https://aztec-ignition.s3.amazonaws.com/MAIN%20IGNITION/flat/g1.dat",{headers:{Range:`bytes=0-${E}`},cache:"force-cache"}),t([5,5,5]))}async fetchG2Data(){return await r(()=>fetch("https://aztec-ignition.s3.amazonaws.com/MAIN%20IGNITION/flat/g2.dat",{cache:"force-cache"}),t([5,5,5]))}}class i{constructor(E){this.numPoints=E}async init(){await this.downloadG1Data()}async downloadG1Data(){const E=await this.fetchG1Data();return this.data=new Uint8Array(await E.arrayBuffer())}async streamG1Data(){return(await this.fetchG1Data()).body}getG1Data(){return this.data}async fetchG1Data(){if(this.numPoints===0)return new Response(new Uint8Array([]));const E=28,y=E+(this.numPoints*64-1);return await fetch("https://aztec-ignition.s3.amazonaws.com/TEST%20GRUMPKIN/monomial/transcript00.dat",{headers:{Range:`bytes=${E}-${y}`},cache:"force-cache"})}}function a(b){return new Promise((E,y)=>{b.oncomplete=b.onsuccess=()=>E(b.result),b.onabort=b.onerror=()=>y(b.error)})}function s(b,E){const y=indexedDB.open(b);y.onupgradeneeded=()=>y.result.createObjectStore(E);const D=a(y);return(U,$)=>D.then(oe=>$(oe.transaction(E,U).objectStore(E)))}let o;function c(){return o||(o=s("keyval-store","keyval")),o}function l(b,E=c()){return E("readonly",y=>a(y.get(b)))}function u(b,E,y=c()){return y("readwrite",D=>(D.put(E,b),a(D.transaction)))}class d{constructor(E){this.numPoints=E}static async new(E){const y=new d(E);return await y.init(),y}
34async init(){const E=await l("g1Data"),y=await l("g2Data"),D=new n(this.numPoints),U=this.numPoints*64;!E||E.length<U?(this.g1Data=await D.downloadG1Data(),await u("g1Data",this.g1Data)):this.g1Data=E,y?this.g2Data=y:(this.g2Data=await D.downloadG2Data(),await u("g2Data",this.g2Data))}getG1Data(){return this.g1Data}getG2Data(){return this.g2Data}}class p{constructor(E){this.numPoints=E}static async new(E){const y=new p(E);return await y.init(),y}async init(){const E=await l("grumpkinG1Data"),y=new i(this.numPoints),D=this.numPoints*64;!E||E.length<D?(this.g1Data=await y.downloadG1Data(),await u("grumpkinG1Data",this.g1Data)):this.g1Data=E}getG1Data(){return this.g1Data}}const w=Symbol("Comlink.proxy"),O=Symbol("Comlink.endpoint"),I=Symbol("Comlink.releaseProxy"),R=Symbol("Comlink.finalizer"),C=Symbol("Comlink.thrown"),j=b=>typeof b=="object"&&b!==null||typeof b=="function",N={canHandle:b=>j(b)&&b[w],serialize(b){const{port1:E,port2:y}=new MessageChannel;return re(b,E),[y,[y]]},deserialize(b){return b.start(),ue(b)}},P={canHandle:b=>j(b)&&C in b,serialize({value:b}){let E;return b instanceof Error?E={isError:!0,value:{message:b.message,name:b.name,stack:b.stack}}:E={isError:!1,value:b},[E,[]]},deserialize(b){throw b.isError?Object.assign(new Error(b.value.message),b.value):b.value}},Z=new Map([["proxy",N],["throw",P]]);function X(b,E){for(const y of b)if(E===y||y==="*"||y instanceof RegExp&&y.test(E))return!0;return!1}function re(b,E=globalThis,y=["*"]){E.addEventListener("message",function D(U){if(!U||!U.data)return;if(!X(y,U.origin)){console.warn(`Invalid origin '${U.origin}' for comlink proxy`);return}const{id:$,type:oe,path:de}=Object.assign({path:[]},U.data),Re=(U.data.argumentList||[]).map(G);let ye;try{const Ee=de.slice(0,-1).reduce((Pe,Le)=>Pe[Le],b),at=de.reduce((Pe,Le)=>Pe[Le],b);switch(oe){case"GET":ye=at;break;case"SET":Ee[de.slice(-1)[0]]=G(U.data.value),ye=!0;break;case"APPLY":ye=at.apply(Ee,Re);break;case"CONSTRUCT":{const Pe=new at(...Re);ye=F(Pe)}break;case"ENDPOINT":{const{port1:Pe,port2:Le}=new MessageChannel;re(b,Le),ye=v(Pe,[Pe])}break;case"RELEASE":ye=void 0;break;default:return}}catch(Ee){ye={value:Ee,[C]:0}}Promise.resolve(ye).catch(Ee=>({value:Ee,[C]:0})).then(Ee=>{const[at,Pe]=Q(Ee);E.postMessage(Object.assign(Object.assign({},at),{id:$}),Pe),oe==="RELEASE"&&(E.removeEventListener("message",D),ae(E),R in b&&typeof b[R]=="function"&&b[R]())}).catch(Ee=>{const[at,Pe]=Q({value:new TypeError("Unserializable return value"),[C]:0});E.postMessage(Object.assign(Object.assign({},at),{id:$}),Pe)})}),E.start&&E.start()}function ne(b){return b.constructor.name==="MessagePort"}function ae(b){ne(b)&&b.close()}function ue(b,E){return T(b,[],E)}function m(b){if(b)throw new Error("Proxy has been released and is not useable")}function A(b){return J(b,{type:"RELEASE"}).then(()=>{ae(b)})}const f=new WeakMap,g="FinalizationRegistry"in globalThis&&new FinalizationRegistry(b=>{const E=(f.get(b)||0)-1;f.set(b,E),E===0&&A(b)});function _(b,E){const y=(f.get(E)||0)+1;f.set(E,y),g&&g.register(b,E,b)}function B(b){g&&g.unregister(b)}function T(b,E=[],y=function(){}){let D=!1;const U=new Proxy(y,{get($,oe){if(m(D),oe===I)return()=>{B(U),A(b),D=!0};if(oe==="then"){if(E.length===0)return{then:()=>U};const de=J(b,{type:"GET",path:E.map(Re=>Re.toString())}).then(G);return de.then.bind(de)}return T(b,[...E,oe])},set($,oe,de){m(D);const[Re,ye]=Q(de);return J(b,{type:"SET",path:[...E,oe].map(Ee=>Ee.toString()),value:Re},ye).then(G)},apply($,oe,de){m(D);const Re=E[E.length-1];if(Re===O)return J(b,{type:"ENDPOINT"}).then(G);if(Re==="bind")return T(b,E.slice(0,-1));const[ye,Ee]=h(de);return J(b,{type:"APPLY",path:E.map(at=>at.toString()),argumentList:ye},Ee).then(G)},construct($,oe){m(D);const[de,Re]=h(oe);return J(b,{type:"CONSTRUCT",path:E.map(ye=>ye.toString()),argumentList:de},Re).then(G)}});return _(U,b),U}function S(b){return Array.prototype.concat.apply([],b)}function h(b){const E=b.map(Q);return[E.map(y=>y[0]),S(E.map(y=>y[1]))]}const x=new WeakMap;function v(b,E){return x.set(b,E),b}function F(b){return Object.assign(b,{[w]:!0})}function Q(b){for(const[E,y]of Z)if(y.canHandle(b)){const[D,U]=y.serialize(b);return[{type:"HANDLER",name:E,value:D},U]}return[{type:"RAW",value:b},x.get(b)||[]]}function G(b){switch(b.type){case"HANDLER":return Z.get(b.name).deserialize(b.value);case"RAW":return b.value}}function J(b,E,y){return new Promise(D=>{const U=Y();b.addEventListener("message",function $(oe){!oe.data||!oe.data.id||oe.data.id!==U||(b.removeEventListener("message",$),D(oe.data))}),b.start&&b.start(),b.postMessage(Object.assign({id:U},E),y)})}function Y(){return new Array(4).fill(0).map(()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16)).join("-")}class V extends Uint8Array{}function W(b){const E=new Uint8Array(1);return E[0]=b?1:0,E}function ce(b,E=4){const y=new Uint8Array(E);return new DataView(y.buffer).setUint32(y.byteLength-4,b,!1),y}function pe(b,E=4){const y=new Uint8Array(E);return new DataView(y.buffer).setInt32(y.byteLength-4,b,!1),y}function ee(b){const E=b.reduce((U,$)=>U+$.length,0),y=new Uint8Array(E);let D=0;for(const U of b)y.set(U,D),D+=U.length;return y}function se(b){return b.reduce((E,y)=>E+y.toString(16).padStart(2,"0"),"")}function ve(b){return ee([pe(b.length),b])}function _e(b,E=32){const y=new Uint8Array(E);for(let D=0;D<E;D++)y[E-D-1]=Number(b>>BigInt(D*8)&255n);return y}function Ue(b){return ee([ce(b.length),...b.flat()])}function xe(b){return Array.isArray(b)?Ue(b.map(xe)):b instanceof V?b:b instanceof Uint8Array?ve(b):typeof b=="boolean"?W(b):typeof b=="number"?ce(b):typeof b=="bigint"?_e(b):typeof b=="string"?ve(new TextEncoder().encode(b)):b.toBuffer()}class Te{constructor(E,y=0){this.buffer=E,this.index=y}static asReader(E){return E instanceof Te?E:new Te(E)}readNumber(){const E=new DataView(this.buffer.buffer,this.buffer.byteOffset+this.index,4);return this.index+=4,E.getUint32(0,!1)}readBoolean(){return this.index+=1,!!this.buffer.at(this.index-1)}readBytes(E){return this.index+=E,this.buffer.slice(this.index-E,this.index)}readNumberVector(){return this.readVector({fromBuffer:E=>E.readNumber()})}readVector(E){const y=this.readNumber(),D=new Array(y);for(let U=0;U<y;U++)D[U]=E.fromBuffer(this);return D}readArray(E,y){const D=new Array(E);for(let U=0;U<E;U++)D[U]=y.fromBuffer(this);return D}readObject(E){return E.fromBuffer(this)}peekBytes(E){return this.buffer.subarray(this.index,E?this.index+E:void 0)}readString(){return new TextDecoder().decode(this.readBuffer())}readBuffer(){const E=this.readNumber();return this.readBytes(E)}readMap(E){const y=this.readNumber(),D={};for(let U=0;U<y;U++){const $=this.readString(),oe=this.readObject(E);D[$]=oe}return D}}function $e(){return{SIZE_IN_BYTES:1,fromBuffer:b=>Te.asReader(b).readBoolean()}}function Ae(){return{SIZE_IN_BYTES:4,fromBuffer:b=>Te.asReader(b).readNumber()}}function De(b){return{fromBuffer:E=>Te.asReader(E).readVector(b)}}function Ke(){return{fromBuffer:b=>Te.asReader(b).readBuffer()}}function ut(){return{fromBuffer:b=>Te.asReader(b).readString()}}class Fe{constructor(E){this.value=E}static fromBuffer(E){const y=Te.asReader(E);return new this(y.readBytes(this.SIZE_IN_BYTES))}toBuffer(){return this.value}}Fe.SIZE_IN_BYTES=4;const ge=b=>{const E=(()=>
34{if(typeof window<"u"&&window.crypto)return window.crypto;if(typeof globalThis<"u"&&globalThis.crypto)return globalThis.crypto})();if(!E)throw new Error("randomBytes UnsupportedEnvironment");const y=new Uint8Array(b),D=65536;if(b>D)for(let U=0;U<b;U+=D)E.getRandomValues(y.subarray(U,U+D));else E.getRandomValues(y);return y};var we=Yt(764).lW;function ke(b){return(b.readBigUInt64BE(0)<<192n)+(b.readBigUInt64BE(8)<<128n)+(b.readBigUInt64BE(16)<<64n)+b.readBigUInt64BE(24)}function Ne(b){const E=we.from(b);return ke(E)}function z(b,E=32){if(E!=32)throw new Error(`Only 32 bytes supported for conversion from bigint to buffer, attempted byte length: ${E}`);const y=we.alloc(E);return y.writeBigUInt64BE(b>>192n,0),y.writeBigUInt64BE(b>>128n&0xffffffffffffffffn,8),y.writeBigUInt64BE(b>>64n&0xffffffffffffffffn,16),y.writeBigUInt64BE(b&0xffffffffffffffffn,24),y}function H(b,E=32){return new Uint8Array(z(b,E))}var k=Yt(764).lW,L,q;class ie{constructor(E){const y=typeof E=="bigint"?E:E instanceof k?ke(E):Ne(E);if(y>L.MAX_VALUE)throw new Error(`Value 0x${y.toString(16)} is greater or equal to field modulus.`);this.value=typeof E=="bigint"?H(E):E instanceof k?new Uint8Array(E):E}static random(){const E=Ne(ge(64))%L.MODULUS;return new this(E)}static fromBuffer(E){const y=Te.asReader(E);return new this(y.readBytes(this.SIZE_IN_BYTES))}static fromBufferReduce(E){const y=Te.asReader(E);return new this(Ne(y.readBytes(this.SIZE_IN_BYTES))%L.MODULUS)}static fromString(E){return this.fromBuffer(k.from(E.replace(/^0x/i,""),"hex"))}toBuffer(){return this.value}toString(){return"0x"+se(this.toBuffer())}equals(E){return this.value.every((y,D)=>y===E.value[D])}isZero(){return this.value.every(E=>E===0)}}L=ie,ie.ZERO=new L(0n),ie.MODULUS=0x30644e72e131a029b85045b68181585d2833e84879b9709143e1f593f0000001n,ie.MAX_VALUE=L.MODULUS-1n,ie.SIZE_IN_BYTES=32;class fe{constructor(E){if(this.value=E,E>q.MAX_VALUE)throw new Error(`Fq out of range ${E}.`)}static random(){const E=Ne(ge(64))%q.MODULUS;return new this(E)}static fromBuffer(E){const y=Te.asReader(E);return new this(Ne(y.readBytes(this.SIZE_IN_BYTES)))}static fromBufferReduce(E){const y=Te.asReader(E);return new this(Ne(y.readBytes(this.SIZE_IN_BYTES))%ie.MODULUS)}static fromString(E){return this.fromBuffer(k.from(E.replace(/^0x/i,""),"hex"))}toBuffer(){return z(this.value,q.SIZE_IN_BYTES)}toString(){return"0x"+this.value.toString(16)}equals(E){return this.value===E.value}isZero(){return this.value===0n}}q=fe,fe.MODULUS=0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47n,fe.MAX_VALUE=q.MODULUS-1n,fe.SIZE_IN_BYTES=32;var be=Yt(764).lW;class Ce{constructor(E,y){this.x=E,this.y=y}static random(){return new Ce(ie.random(),ie.random())}static fromBuffer(E){const y=Te.asReader(E);return new this(ie.fromBuffer(y),ie.fromBuffer(y))}static fromString(E){return Ce.fromBuffer(be.from(E.replace(/^0x/i,""),"hex"))}toBuffer(){return be.concat([this.x.toBuffer(),this.y.toBuffer()])}toString(){return"0x"+this.toBuffer().toString("hex")}equals(E){return this.x.equals(E.x)&&this.y.equals(E.y)}}Ce.SIZE_IN_BYTES=64,Ce.EMPTY=new Ce(ie.ZERO,ie.ZERO);class ze{constructor(E){this.buffer=E}static fromBuffer(E){const y=Te.asReader(E);return new ze(y.readBytes(this.SIZE_IN_BYTES))}static random(){return new ze(ge(this.SIZE_IN_BYTES))}toBuffer(){return this.buffer}}ze.SIZE_IN_BYTES=32;class Ie{constructor(E){this.buffer=E}static fromBuffer(E){const y=Te.asReader(E);return new Ie(y.readBytes(this.SIZE_IN_BYTES))}static random(){return new Ie(ge(this.SIZE_IN_BYTES))}toBuffer(){return this.buffer}}Ie.SIZE_IN_BYTES=128;function qe(b,E=!1){const y=new DataView(b.buffer,b.byteOffset,b.byteLength);let D=0,U=b.byteLength>>>2;E&&(U=y.getUint32(0,!1),D=4);const $=new Array(U);for(let oe=0;oe<U;oe++)$[oe]=y.getUint32(D,!1),D+=4;return $}class it{constructor(E){this.wasm=E}async pedersenCommit(E,y){const D=[E,y].map(xe),U=[Ce];return(await this.wasm.callWasmExport("pedersen_commit",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async pedersenHash(E,y){const D=[E,y].map(xe),U=[ie];return(await this.wasm.callWasmExport("pedersen_hash",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async pedersenHashes(E,y){const D=[E,y].map(xe),U=[ie];return(await this.wasm.callWasmExport("pedersen_hashes",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async pedersenHashBuffer(E,y){const D=[E,y].map(xe),U=[ie];return(await this.wasm.callWasmExport("pedersen_hash_buffer",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async poseidon2Hash(E){const y=[E].map(xe),D=[ie];return(await this.wasm.callWasmExport("poseidon2_hash",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async poseidon2HashAccumulate(E){const y=[E].map(xe),D=[ie];return(await this.wasm.callWasmExport("poseidon2_hash_accumulate",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async poseidon2Hashes(E){const y=[E].map(xe),D=[ie];return(await this.wasm.callWasmExport("poseidon2_hashes",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async poseidon2Permutation(E){const y=[E].map(xe),D=[De(ie)];return(await this.wasm.callWasmExport("poseidon2_permutation",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async blake2s(E){const y=[E].map(xe),D=[ze];return(await this.wasm.callWasmExport("blake2s",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async blake2sToField(E){const y=[E].map(xe),D=[ie];return(await this.wasm.callWasmExport("blake2s_to_field_",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async schnorrComputePublicKey(E){const y=[E].map(xe),D=[Ce];return(await this.wasm.callWasmExport("schnorr_compute_public_key",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async schnorrNegatePublicKey(E){const y=[E].map(xe),D=[Ce];return(await this.wasm.callWasmExport("schnorr_negate_public_key",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async schnorrConstructSignature(E,y){const D=[E,y].map(xe),U=[ze,ze];return(await this.wasm.callWasmExport("schnorr_construct_signature",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))}async schnorrVerifySignature(E,y,D,U){const $=[E,y,D,U].map(xe),oe=[$e()];return(await this.wasm.callWasmExport("schnorr_verify_signature",$,oe.map(de=>de.SIZE_IN_BYTES))).map((de,Re)=>oe[Re].fromBuffer(de))[0]}async schnorrMultisigCreateMultisigPublicKey(E){const y=[E].map(xe),D=[Ie];return(await this.wasm.callWasmExport("schnorr_multisig_create_multisig_public_key",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async schnorrMultisigValidateAndCombineSignerPubkeys(E){const y=[E].map(xe),D=[Ce,$e()];return(await this.wasm.callWasmExport("schnorr_multisig_validate_and_combine_signer_pubkeys",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))}async schnorrMultisigConstructSignatureRound1(){const E=[].map(xe),y=[Ie,Ie];return(await this.wasm.callWasmExport("schnorr_multisig_construct_signature_roun
34d_1",E,y.map(D=>D.SIZE_IN_BYTES))).map((D,U)=>y[U].fromBuffer(D))}async schnorrMultisigConstructSignatureRound2(E,y,D,U,$){const oe=[E,y,D,U,$].map(xe),de=[fe,$e()];return(await this.wasm.callWasmExport("schnorr_multisig_construct_signature_round_2",oe,de.map(Re=>Re.SIZE_IN_BYTES))).map((Re,ye)=>de[ye].fromBuffer(Re))}async schnorrMultisigCombineSignatures(E,y,D,U){const $=[E,y,D,U].map(xe),oe=[ze,ze,$e()];return(await this.wasm.callWasmExport("schnorr_multisig_combine_signatures",$,oe.map(de=>de.SIZE_IN_BYTES))).map((de,Re)=>oe[Re].fromBuffer(de))}async aesEncryptBufferCbc(E,y,D,U){const $=[E,y,D,U].map(xe),oe=[Ke()];return(await this.wasm.callWasmExport("aes_encrypt_buffer_cbc",$,oe.map(de=>de.SIZE_IN_BYTES))).map((de,Re)=>oe[Re].fromBuffer(de))[0]}async aesDecryptBufferCbc(E,y,D,U){const $=[E,y,D,U].map(xe),oe=[Ke()];return(await this.wasm.callWasmExport("aes_decrypt_buffer_cbc",$,oe.map(de=>de.SIZE_IN_BYTES))).map((de,Re)=>oe[Re].fromBuffer(de))[0]}async srsInitSrs(E,y,D){const U=[E,y,D].map(xe),$=[];(await this.wasm.callWasmExport("srs_init_srs",U,$.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>$[de].fromBuffer(oe))}async srsInitGrumpkinSrs(E,y){const D=[E,y].map(xe),U=[];(await this.wasm.callWasmExport("srs_init_grumpkin_srs",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))}async examplesSimpleCreateAndVerifyProof(){const E=[].map(xe),y=[$e()];return(await this.wasm.callWasmExport("examples_simple_create_and_verify_proof",E,y.map(D=>D.SIZE_IN_BYTES))).map((D,U)=>y[U].fromBuffer(D))[0]}async testThreads(E,y){const D=[E,y].map(xe),U=[Ae()];return(await this.wasm.callWasmExport("test_threads",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async commonInitSlabAllocator(E){const y=[E].map(xe),D=[];(await this.wasm.callWasmExport("common_init_slab_allocator",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))}async acirGetCircuitSizes(E,y,D){const U=[E,y,D].map(xe),$=[Ae(),Ae()];return(await this.wasm.callWasmExport("acir_get_circuit_sizes",U,$.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>$[de].fromBuffer(oe))}async acirGatesAztecClient(E){const y=[E].map(xe),D=[Ke()],U=await this.wasm.callWasmExport("acir_gates_aztec_client",y,D.map($=>$.SIZE_IN_BYTES));return qe(U[0],!0)}async acirNewAcirComposer(E){const y=[E].map(xe),D=[Fe];return(await this.wasm.callWasmExport("acir_new_acir_composer",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async acirDeleteAcirComposer(E){const y=[E].map(xe),D=[];(await this.wasm.callWasmExport("acir_delete_acir_composer",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))}async acirInitProvingKey(E,y,D){const U=[E,y,D].map(xe),$=[];(await this.wasm.callWasmExport("acir_init_proving_key",U,$.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>$[de].fromBuffer(oe))}async acirCreateProof(E,y,D,U){const $=[E,y,D,U].map(xe),oe=[Ke()];return(await this.wasm.callWasmExport("acir_create_proof",$,oe.map(de=>de.SIZE_IN_BYTES))).map((de,Re)=>oe[Re].fromBuffer(de))[0]}async acirProveAndVerifyUltraHonk(E,y,D){const U=[E,y,D].map(xe),$=[$e()];return(await this.wasm.callWasmExport("acir_prove_and_verify_ultra_honk",U,$.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>$[de].fromBuffer(oe))[0]}async acirProveAndVerifyMegaHonk(E,y,D){const U=[E,y,D].map(xe),$=[$e()];return(await this.wasm.callWasmExport("acir_prove_and_verify_mega_honk",U,$.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>$[de].fromBuffer(oe))[0]}async acirFoldAndVerifyProgramStack(E,y,D){const U=[E,y,D].map(xe),$=[$e()];return(await this.wasm.callWasmExport("acir_fold_and_verify_program_stack",U,$.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>$[de].fromBuffer(oe))[0]}async acirLoadVerificationKey(E,y){const D=[E,y].map(xe),U=[];(await this.wasm.callWasmExport("acir_load_verification_key",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))}async acirInitVerificationKey(E){const y=[E].map(xe),D=[];(await this.wasm.callWasmExport("acir_init_verification_key",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))}async acirGetVerificationKey(E){const y=[E].map(xe),D=[Ke()];return(await this.wasm.callWasmExport("acir_get_verification_key",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async acirGetProvingKey(E,y,D){const U=[E,y,D].map(xe),$=[Ke()];return(await this.wasm.callWasmExport("acir_get_proving_key",U,$.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>$[de].fromBuffer(oe))[0]}async acirVerifyProof(E,y){const D=[E,y].map(xe),U=[$e()];return(await this.wasm.callWasmExport("acir_verify_proof",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async acirGetSolidityVerifier(E){const y=[E].map(xe),D=[ut()];return(await this.wasm.callWasmExport("acir_get_solidity_verifier",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async acirSerializeProofIntoFields(E,y,D){const U=[E,y,D].map(xe),$=[De(ie)];return(await this.wasm.callWasmExport("acir_serialize_proof_into_fields",U,$.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>$[de].fromBuffer(oe))[0]}async acirSerializeVerificationKeyIntoFields(E){const y=[E].map(xe),D=[De(ie),ie];return(await this.wasm.callWasmExport("acir_serialize_verification_key_into_fields",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))}async acirProveAndVerifyAztecClient(E,y){const D=[E,y].map(xe),U=[$e()];return(await this.wasm.callWasmExport("acir_prove_and_verify_aztec_client",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async acirProveAztecClient(E,y){const D=[E,y].map(xe),U=[Ke(),Ke()],$=(await this.wasm.callWasmExport("acir_prove_aztec_client",D,U.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>U[de].fromBuffer(oe));return[$[0],$[1]]}async acirVerifyAztecClient(E,y){const D=[E,y].map(xe),U=[$e()];return(await this.wasm.callWasmExport("acir_verify_aztec_client",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async acirProveUltraHonk(E,y,D){const U=[E,y,D].map(xe),$=[Ke()];return(await this.wasm.callWasmExport("acir_prove_ultra_honk",U,$.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>$[de].fromBuffer(oe))[0]}async acirProveUltraKeccakHonk(E,y,D){const U=[E,y,D].map(xe),$=[Ke()];return(await this.wasm.callWasmExport("acir_prove_ultra_keccak_honk",U,$.map(oe=>oe.SIZE_IN_BYTES))).map((oe,de)=>$[de].fromBuffer(oe))[0]}async acirVerifyUltraHonk(E,y){const D=[E,y].map(xe),U=[$e()];return(await this.wasm.callWasmExport("acir_verify_ultra_honk",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async acirVerifyUltraKeccakHonk(E,y){const D=[E,y].map(xe),U=[$e()];return(await this.wasm.callWasmExport("acir_verify_ultra_keccak_honk",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async acirWriteVkUltraHonk(E,y){const D=[E,y].map(xe),U=[Ke()];return(await this.wasm.callWasmExport("acir_write_vk_ultra_honk",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async acirWriteVkUltraKeccakHonk(E,y){const D=[E,y].map(xe),U=[Ke()];return(await this.wasm.callWasmExport("acir_write_vk_ultra_keccak_honk",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async acirHonkSolidityVerifier(E,y){const D=[E,y].map(xe),U=[Ke()];return(await this.wasm.callWasmExport("acir_honk_solidity_verifier",D,U.map($=>$.SIZE_IN_BYTES))).map(($,oe)=>U[oe].fromBuffer($))[0]}async acirProofAsFieldsUltraHonk(E){const y=[E].map(xe),D=[De(ie)];return(await this.wasm.callWasmExport("acir_proof_as_fields_ultra_honk",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async acirVkAsFieldsUltraHonk(E){const y=[E].map(xe),D=[De(ie)];return(await this.wasm.callWasmExport("acir_vk_as_fields_ultra_honk",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}async acirVkAsFieldsMegaHonk(E){const y=[E].map(xe),D=[De(ie)];return(await this.wasm.callWasmExport("acir_vk_as_fields_mega_honk",y,D.map(U=>U.SIZE_IN_BYTES))).map((U,$)=>D[$].fromBuffer(U))[0]}}class Ve{constructor(E){this.wasm=E}pedersenCommit(E,y){const D=[E,y].map(xe),U=[Ce];return this.wasm.callWasmExport("pedersen_commit",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))[0]}pedersenHash(E,y){const D=[E,y].map(xe),U=[ie];return this.wasm.callWasmExport("pedersen_hash",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))[0]}pedersenHashes(E,y){const D=[E,y].map(xe),U=[ie];return this.wasm.callWasmExport("pedersen_hashes",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))[0]}pedersenHashBuffer(E,y){const D=[E,y].map(xe),U=[ie];return this.wasm.callWasmExport("pedersen_hash_buffer",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))[0]}poseidon2Hash(E){const y=[E].map(xe),D=[ie];return this.wasm.callWasmExport("poseidon2_hash",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}poseidon2HashAccumulate(E){const y=[E].map(xe),D=[ie];return this.wasm.callWasmExport("poseidon2_hash_accumulate",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}poseidon2Hashes(E){const y=[E].map(xe),D=[ie];return this.wasm.callWasmExport("poseidon2_hashes",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}poseidon2Permutation(E){const y=[E].map(xe),D=[De(ie)];return this.wasm.callWasmExport("poseidon2_permutation",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}blake2s(E){const y=[E].map(xe),D=[ze];return this.wasm.callWasmExport("blake2s",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}blake2sToField(E){const y=[E].map(xe),D=[ie];return this.wasm.callWasmExport("blake2s_to_field_",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}schnorrComputePublicKey(E){const y=[E].map(xe),D=[Ce];return this.wasm.callWasmExport("schnorr_compute_public_key",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}schnorrNegatePublicKey(E){const y=[E].map(xe),D=[Ce];return this.wasm.callWasmExport("schnorr_negate_public_key",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}schnorrConstructSignature(E,y){const D=[E,y].map(xe),U=[ze,ze];return this.wasm.callWasmExport("schnorr_construct_signature",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))}schnorrVerifySignature(E,y,D,U){const $=[E,y,D,U].map(xe),oe=[$e()];return this.wasm.callWasmExport("schnorr_verify_signature",$,oe.map(de=>de.SIZE_IN_BYTES)).map((de,Re)=>oe[Re].fromBuffer(de))[0]}schnorrMultisigCreateMultisigPublicKey(E){const y=[E].map(xe),D=[Ie];return this.wasm.callWasmExport("schnorr_multisig_create_multisig_public_key",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}schnorrMultisigValidateAndCombineSignerPubkeys(E){const y=[E].map(xe),D=[Ce,$e()];return this.wasm.callWasmExport("schnorr_multisig_validate_and_combine_signer_pubkeys",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))}schnorrMultisigConstructSignatureRound1(){const E=[].map(xe),y=[Ie,Ie];return this.wasm.callWasmExport("schnorr_multisig_construct_signature_roun
34d_1",E,y.map(D=>D.SIZE_IN_BYTES)).map((D,U)=>y[U].fromBuffer(D))}schnorrMultisigConstructSignatureRound2(E,y,D,U,$){const oe=[E,y,D,U,$].map(xe),de=[fe,$e()];return this.wasm.callWasmExport("schnorr_multisig_construct_signature_round_2",oe,de.map(Re=>Re.SIZE_IN_BYTES)).map((Re,ye)=>de[ye].fromBuffer(Re))}schnorrMultisigCombineSignatures(E,y,D,U){const $=[E,y,D,U].map(xe),oe=[ze,ze,$e()];return this.wasm.callWasmExport("schnorr_multisig_combine_signatures",$,oe.map(de=>de.SIZE_IN_BYTES)).map((de,Re)=>oe[Re].fromBuffer(de))}aesEncryptBufferCbc(E,y,D,U){const $=[E,y,D,U].map(xe),oe=[Ke()];return this.wasm.callWasmExport("aes_encrypt_buffer_cbc",$,oe.map(de=>de.SIZE_IN_BYTES)).map((de,Re)=>oe[Re].fromBuffer(de))[0]}aesDecryptBufferCbc(E,y,D,U){const $=[E,y,D,U].map(xe),oe=[Ke()];return this.wasm.callWasmExport("aes_decrypt_buffer_cbc",$,oe.map(de=>de.SIZE_IN_BYTES)).map((de,Re)=>oe[Re].fromBuffer(de))[0]}srsInitSrs(E,y,D){const U=[E,y,D].map(xe),$=[];this.wasm.callWasmExport("srs_init_srs",U,$.map(oe=>oe.SIZE_IN_BYTES)).map((oe,de)=>$[de].fromBuffer(oe))}srsInitGrumpkinSrs(E,y){const D=[E,y].map(xe),U=[];this.wasm.callWasmExport("srs_init_grumpkin_srs",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))}examplesSimpleCreateAndVerifyProof(){const E=[].map(xe),y=[$e()];return this.wasm.callWasmExport("examples_simple_create_and_verify_proof",E,y.map(D=>D.SIZE_IN_BYTES)).map((D,U)=>y[U].fromBuffer(D))[0]}testThreads(E,y){const D=[E,y].map(xe),U=[Ae()];return this.wasm.callWasmExport("test_threads",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))[0]}commonInitSlabAllocator(E){const y=[E].map(xe),D=[];this.wasm.callWasmExport("common_init_slab_allocator",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))}acirGetCircuitSizes(E,y,D){const U=[E,y,D].map(xe),$=[Ae(),Ae()];return this.wasm.callWasmExport("acir_get_circuit_sizes",U,$.map(oe=>oe.SIZE_IN_BYTES)).map((oe,de)=>$[de].fromBuffer(oe))}acirNewAcirComposer(E){const y=[E].map(xe),D=[Fe];return this.wasm.callWasmExport("acir_new_acir_composer",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}acirDeleteAcirComposer(E){const y=[E].map(xe),D=[];this.wasm.callWasmExport("acir_delete_acir_composer",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))}acirInitProvingKey(E,y,D){const U=[E,y,D].map(xe),$=[];this.wasm.callWasmExport("acir_init_proving_key",U,$.map(oe=>oe.SIZE_IN_BYTES)).map((oe,de)=>$[de].fromBuffer(oe))}acirCreateProof(E,y,D,U){const $=[E,y,D,U].map(xe),oe=[Ke()];return this.wasm.callWasmExport("acir_create_proof",$,oe.map(de=>de.SIZE_IN_BYTES)).map((de,Re)=>oe[Re].fromBuffer(de))[0]}acirProveAndVerifyUltraHonk(E,y,D){const U=[E,y,D].map(xe),$=[$e()];return this.wasm.callWasmExport("acir_prove_and_verify_ultra_honk",U,$.map(oe=>oe.SIZE_IN_BYTES)).map((oe,de)=>$[de].fromBuffer(oe))[0]}acirProveAndVerifyMegaHonk(E,y,D){const U=[E,y,D].map(xe),$=[$e()];return this.wasm.callWasmExport("acir_prove_and_verify_mega_honk",U,$.map(oe=>oe.SIZE_IN_BYTES)).map((oe,de)=>$[de].fromBuffer(oe))[0]}acirFoldAndVerifyProgramStack(E,y,D){const U=[E,y,D].map(xe),$=[$e()];return this.wasm.callWasmExport("acir_fold_and_verify_program_stack",U,$.map(oe=>oe.SIZE_IN_BYTES)).map((oe,de)=>$[de].fromBuffer(oe))[0]}acirLoadVerificationKey(E,y){const D=[E,y].map(xe),U=[];this.wasm.callWasmExport("acir_load_verification_key",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))}acirInitVerificationKey(E){const y=[E].map(xe),D=[];this.wasm.callWasmExport("acir_init_verification_key",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))}acirGetVerificationKey(E){const y=[E].map(xe),D=[Ke()];return this.wasm.callWasmExport("acir_get_verification_key",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}acirGetProvingKey(E,y,D){const U=[E,y,D].map(xe),$=[Ke()];return this.wasm.callWasmExport("acir_get_proving_key",U,$.map(oe=>oe.SIZE_IN_BYTES)).map((oe,de)=>$[de].fromBuffer(oe))[0]}acirVerifyProof(E,y){const D=[E,y].map(xe),U=[$e()];return this.wasm.callWasmExport("acir_verify_proof",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))[0]}acirGetSolidityVerifier(E){const y=[E].map(xe),D=[ut()];return this.wasm.callWasmExport("acir_get_solidity_verifier",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}acirSerializeProofIntoFields(E,y,D){const U=[E,y,D].map(xe),$=[De(ie)];return this.wasm.callWasmExport("acir_serialize_proof_into_fields",U,$.map(oe=>oe.SIZE_IN_BYTES)).map((oe,de)=>$[de].fromBuffer(oe))[0]}acirSerializeVerificationKeyIntoFields(E){const y=[E].map(xe),D=[De(ie),ie];return this.wasm.callWasmExport("acir_serialize_verification_key_into_fields",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))}acirProveUltraHonk(E,y,D){const U=[E,y,D].map(xe),$=[Ke()];return this.wasm.callWasmExport("acir_prove_ultra_honk",U,$.map(oe=>oe.SIZE_IN_BYTES)).map((oe,de)=>$[de].fromBuffer(oe))[0]}acirVerifyUltraHonk(E,y){const D=[E,y].map(xe),U=[$e()];return this.wasm.callWasmExport("acir_verify_ultra_honk",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))[0]}acirWriteVkUltraHonk(E,y){const D=[E,y].map(xe),U=[Ke()];return this.wasm.callWasmExport("acir_write_vk_ultra_honk",D,U.map($=>$.SIZE_IN_BYTES)).map(($,oe)=>U[oe].fromBuffer($))[0]}acirProofAsFieldsUltraHonk(E){const y=[E].map(xe),D=[De(ie)];return this.wasm.callWasmExport("acir_proof_as_fields_ultra_honk",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}acirVkAsFieldsUltraHonk(E){const y=[E].map(xe),D=[De(ie)];return this.wasm.callWasmExport("acir_vk_as_fields_ultra_honk",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}acirVkAsFieldsMegaHonk(E){const y=[E].map(xe),D=[De(ie)];return this.wasm.callWasmExport("acir_vk_as_fields_mega_honk",y,D.map(U=>U.SIZE_IN_BYTES)).map((U,$)=>D[$].fromBuffer(U))[0]}}var zt=Yt(227),wt=Yt.n(zt),Xe=Yt(477),Tt=Yt.n(Xe);function jt(){return Tt()(`/*! For license information please see main.worker.worker.js.LICENSE.txt */
35var __webpack_modules__ = {
36    227: (module, exports, __webpack_require__) => {
37        exports.formatArgs = formatArgs;
38        exports.save = save;
39        exports.load = load;
40        exports.useColors = useColors;
41        exports.storage = localstorage();
42        exports.destroy = (() => {
43            let warned = false;
vendor: 9,832 bytes, lines 44-245
44            return () => {
45                if (!warned) {
46                    warned = true;
47                    console.warn("Instance method \`debug.destroy()\` is deprecated and no longer does anything. It will be removed in the next major version of \`debug\`.");
48                }
49            };
50        })();
51        exports.colors = [ "#0000CC", "#0000FF", "#0033CC", "#0033FF", "#0066CC", "#0066FF", "#0099CC", "#0099FF", "#00CC00", "#00CC33", "#00CC66", "#00CC99", "#00CCCC", "#00CCFF", "#3300CC", "#3300FF", "#3333CC", "#3333FF", "#3366CC", "#3366FF", "#3399CC", "#3399FF", "#33CC00", "#33CC33", "#33CC66", "#33CC99", "#33CCCC", "#33CCFF", "#6600CC", "#6600FF", "#6633CC", "#6633FF", "#66CC00", "#66CC33", "#9900CC", "#9900FF", "#9933CC", "#9933FF", "#99CC00", "#99CC33", "#CC0000", "#CC0033", "#CC0066", "#CC0099", "#CC00CC", "#CC00FF", "#CC3300", "#CC3333", "#CC3366", "#CC3399", "#CC33CC", "#CC33FF", "#CC6600", "#CC6633", "#CC9900", "#CC9933", "#CCCC00", "#CCCC33", "#FF0000", "#FF0033", "#FF0066", "#FF0099", "#FF00CC", "#FF00FF", "#FF3300", "#FF3333", "#FF3366", "#FF3399", "#FF33CC", "#FF33FF", "#FF6600", "#FF6633", "#FF9900", "#FF9933", "#FFCC00", "#FFCC33" ];
52        function useColors() {
53            if (typeof window !== "undefined" && window.process && (window.process.type === "renderer" || window.process.__nwjs)) {
54                return true;
55            }
56            if (typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\\/(\\d+)/)) {
57                return false;
58            }
59            return typeof document !== "undefined" && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance || typeof window !== "undefined" && window.console && (window.console.firebug || window.console.exception && window.console.table) || typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\\/(\\d+)/) && parseInt(RegExp.$1, 10) >= 31 || typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\\/(\\d+)/);
60        }
61        function formatArgs(args) {
62            args[0] = (this.useColors ? "%c" : "") + this.namespace + (this.useColors ? " %c" : " ") + args[0] + (this.useColors ? "%c " : " ") + "+" + module.exports.humanize(this.diff);
63            if (!this.useColors) {
64                return;
65            }
66            const c = "color: " + this.color;
67            args.splice(1, 0, c, "color: inherit");
68            let index = 0;
69            let lastC = 0;
70            args[0].replace(/%[a-zA-Z%]/g, (match => {
71                if (match === "%%") {
72                    return;
73                }
74                index++;
75                if (match === "%c") {
76                    lastC = index;
77                }
78            }));
79            args.splice(lastC, 0, c);
80        }
81        exports.log = console.debug || console.log || (() => {});
82        function save(namespaces) {
83            try {
84                if (namespaces) {
85                    exports.storage.setItem("debug", namespaces);
86                } else {
87                    exports.storage.removeItem("debug");
88                }
89            } catch (error) {}
90        }
91        function load() {
92            let r;
93            try {
94                r = exports.storage.getItem("debug");
95            } catch (error) {}
96            if (!r && typeof process !== "undefined" && "env" in process) {
97                r = process.env.DEBUG;
98            }
99            return r;
100        }
101        function localstorage() {
102            try {
103                return localStorage;
104            } catch (error) {}
105        }
106        module.exports = __webpack_require__(447)(exports);
107        const {formatters} = module.exports;
108        formatters.j = function(v) {
109            try {
110                return JSON.stringify(v);
111            } catch (error) {
112                return "[UnexpectedJSONParseError]: " + error.message;
113            }
114        };
115    },
116    447: (module, __unused_webpack_exports, __webpack_require__) => {
117        function setup(env) {
118            createDebug.debug = createDebug;
119            createDebug.default = createDebug;
120            createDebug.coerce = coerce;
121            createDebug.disable = disable;
122            createDebug.enable = enable;
123            createDebug.enabled = enabled;
124            createDebug.humanize = __webpack_require__(824);
125            createDebug.destroy = destroy;
126            Object.keys(env).forEach((key => {
127                createDebug[key] = env[key];
128            }));
129            createDebug.names = [];
130            createDebug.skips = [];
131            createDebug.formatters = {};
132            function selectColor(namespace) {
133                let hash = 0;
134                for (let i = 0; i < namespace.length; i++) {
135                    hash = (hash << 5) - hash + namespace.charCodeAt(i);
136                    hash |= 0;
137                }
138                return createDebug.colors[Math.abs(hash) % createDebug.colors.length];
139            }
140            createDebug.selectColor = selectColor;
141            function createDebug(namespace) {
142                let prevTime;
143                let enableOverride = null;
144                let namespacesCache;
145                let enabledCache;
146                function debug(...args) {
147                    if (!debug.enabled) {
148                        return;
149                    }
150                    const self = debug;
151                    const curr = Number(new Date);
152                    const ms = curr - (prevTime || curr);
153                    self.diff = ms;
154                    self.prev = prevTime;
155                    self.curr = curr;
156                    prevTime = curr;
157                    args[0] = createDebug.coerce(args[0]);
158                    if (typeof args[0] !== "string") {
159                        args.unshift("%O");
160                    }
161                    let index = 0;
162                    args[0] = args[0].replace(/%([a-zA-Z%])/g, ((match, format) => {
163                        if (match === "%%") {
164                            return "%";
165                        }
166                        index++;
167                        const formatter = createDebug.formatters[format];
168                        if (typeof formatter === "function") {
169                            const val = args[index];
170                            match = formatter.call(self, val);
171                            args.splice(index, 1);
172                            index--;
173                        }
174                        return match;
175                    }));
176                    createDebug.formatArgs.call(self, args);
177                    const logFn = self.log || createDebug.log;
178                    logFn.apply(self, args);
179                }
180                debug.namespace = namespace;
181                debug.useColors = createDebug.useColors();
182                debug.color = createDebug.selectColor(namespace);
183                debug.extend = extend;
184                debug.destroy = createDebug.destroy;
185                Object.defineProperty(debug, "enabled", {
186                    enumerable: true,
187                    configurable: false,
188                    get: () => {
189                        if (enableOverride !== null) {
190                            return enableOverride;
191                        }
192                        if (namespacesCache !== createDebug.namespaces) {
193                            namespacesCache = createDebug.namespaces;
194                            enabledCache = createDebug.enabled(namespace);
195                        }
196                        return enabledCache;
197                    },
198                    set: v => {
199                        enableOverride = v;
200                    }
201                });
202                if (typeof createDebug.init === "function") {
203                    createDebug.init(debug);
204                }
205                return debug;
206            }
207            function extend(namespace, delimiter) {
208                const newDebug = createDebug(this.namespace + (typeof delimiter === "undefined" ? ":" : delimiter) + namespace);
209                newDebug.log = this.log;
210                return newDebug;
211            }
212            function enable(namespaces) {
213                createDebug.save(namespaces);
214                createDebug.namespaces = namespaces;
215                createDebug.names = [];
216                createDebug.skips = [];
217                let i;
218                const split = (typeof namespaces === "string" ? namespaces : "").split(/[\\s,]+/);
219                const len = split.length;
220                for (i = 0; i < len; i++) {
221                    if (!split[i]) {
222                        continue;
223                    }
224                    namespaces = split[i].replace(/\\*/g, ".*?");
225                    if (namespaces[0] === "-") {
226                        createDebug.skips.push(new RegExp("^" + namespaces.slice(1) + "$"));
227                    } else {
228                        createDebug.names.push(new RegExp("^" + namespaces + "$"));
229                    }
230                }
231            }
232            function disable() {
233                const namespaces = [ ...createDebug.names.map(toNamespace), ...createDebug.skips.map(toNamespace).map((namespace => "-" + namespace)) ].join(",");
234                createDebug.enable("");
235                return namespaces;
236            }
237            function enabled(name) {
238                if (name[name.length - 1] === "*") {
239                    return true;
240                }
241                let i;
242                let len;
243                for (i = 0, len = createDebug.skips.length; i < len; i++) {
244                    if (createDebug.skips[i].test(name)) {
245                        return false;
246                    }
247                }
248                for (i = 0, len = createDebug.names.length; i < len; i++) {
249                    if (createDebug.names[i].test(name)) {
250                        return true;
251                    }
252                }
253                return false;
254            }
255            function toNamespace(regexp) {
256                return regexp.toString().substring(2, regexp.toString().length - 2).replace(/\\.\\*\\?$/, "*");
257            }
258            function coerce(val) {
259                if (val instanceof Error) {
260                    return val.stack || val.message;
261                }
262                return val;
263            }
264            function destroy() {
265                console.warn("Instance method \`debug.destroy()\` is deprecated and no longer does anything. It will be removed in the next major version of \`debug\`.");
266            }
267            createDebug.enable(createDebug.load());
268            return createDebug;
269        }
270        module.exports = setup;
271    },
272    824: module => {
273        var s = 1e3;
274        var m = s * 60;
275        var h = m * 60;
276        var d = h * 24;
277        var w = d * 7;
278        var y = d * 365.25;
279        module.exports = function(val, options) {
280            options = options || {};
281            var type = typeof val;
282            if (type === "string" && val.length > 0) {
283                return parse(val);
284            } else if (type === "number" && isFinite(val)) {
285                return options.long ? fmtLong(val) : fmtShort(val);
286            }
287            throw new Error("val is not a non-empty string or a valid number. val=" + JSON.stringify(val));
288        };
289        function parse(str) {
290            str = String(str);
291            if (str.length > 100) {
292                return;
293            }
294            var match = /^(-?(?:\\d+)?\\.?\\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(str);
295            if (!match) {
296                return;
297            }
298            var n = parseFloat(match[1]);
299            var type = (match[2] || "ms").toLowerCase();
300            switch (type) {
301              case "years":
302              case "year":
303              case "yrs":
304              case "yr":
305              case "y":
306                return n * y;
307
308              case "weeks":
309              case "week":
310              case "w":
311                return n * w;
312
313              case "days":
314              case "day":
315              case "d":
316                return n * d;
317
318              case "hours":
319              case "hour":
320              case "hrs":
321              case "hr":
322              case "h":
323                return n * h;
324
325              case "minutes":
326              case "minute":
327              case "mins":
328              case "min":
329              case "m":
330                return n * m;
331
332              case "seconds":
333              case "second":
334              case "secs":
335              case "sec":
336              case "s":
337                return n * s;
338
339              case "milliseconds":
340              case "millisecond":
341              case "msecs":
342              case "msec":
343              case "ms":
344                return n;
345
346              default:
347                return undefined;
348            }
349        }
350        function fmtShort(ms) {
351            var msAbs = Math.abs(ms);
352            if (msAbs >= d) {
353                return Math.round(ms / d) + "d";
354            }
355            if (msAbs >= h) {
356                return Math.round(ms / h) + "h";
357            }
358            if (msAbs >= m) {
359                return Math.round(ms / m) + "m";
360            }
361            if (msAbs >= s) {
362                return Math.round(ms / s) + "s";
363            }
364            return ms + "ms";
365        }
366        function fmtLong(ms) {
367            var msAbs = Math.abs(ms);
368            if (msAbs >= d) {
369                return plural(ms, msAbs, d, "day");
370            }
371            if (msAbs >= h) {
372                return plural(ms, msAbs, h, "hour");
373            }
374            if (msAbs >= m) {
375                return plural(ms, msAbs, m, "minute");
376            }
377            if (msAbs >= s) {
378                return plural(ms, msAbs, s, "second");
379            }
380            return ms + " ms";
381        }
382        function plural(ms, msAbs, n, name) {
383            var isPlural = msAbs >= n * 1.5;
384            return Math.round(ms / n) + " " + name + (isPlural ? "s" : "");
385        }
386    },
387    477: module => {
388        module.exports = function(content, workerConstructor, workerOptions, url) {
389            var globalScope = self || window;
390            try {
391                try {
392                    var blob;
393                    try {
394                        blob = new globalScope.Blob([ content ]);
395                    } catch (e) {
396                        var BlobBuilder = globalScope.BlobBuilder || globalScope.WebKitBlobBuilder || globalScope.MozBlobBuilder || globalScope.MSBlobBuilder;
397                        blob = new BlobBuilder;
398                        blob.append(content);
399                        blob = blob.getBlob();
400                    }
401                    var URL = globalScope.URL || globalScope.webkitURL;
402                    var objectURL = URL.createObjectURL(blob);
403                    var worker = new globalScope[workerConstructor](objectURL, workerOptions);
404                    URL.revokeObjectURL(objectURL);
405                    return worker;
406                } catch (e) {
407                    return new globalScope[workerConstructor]("data:application/javascript,".concat(encodeURIComponent(content)), workerOptions);
408                }
409            } catch (e) {
410                if (!url) {
411                    throw Error("Inline worker is not supported");
412                }
413                return new globalScope[workerConstructor](url, workerOptions);
414            }
415        };
416    }
417};
418
419var __webpack_module_cache__ = {};
420
421function __webpack_require__(moduleId) {
422    var cachedModule = __webpack_module_cache__[moduleId];
423    if (cachedModule !== undefined) {
424        return cachedModule.exports;
425    }
426    var module = __webpack_module_cache__[moduleId] = {
427        exports: {}
428    };
429    __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
430    return module.exports;
431}
432
433(() => {
434    __webpack_require__.n = module => {
435        var getter = module && module.__esModule ? () => module["default"] : () => module;
436        __webpack_require__.d(getter, {
437            a: getter
438        });
439        return getter;
440    };
441})();
442
443(() => {
444    __webpack_require__.d = (exports, definition) => {
445        for (var key in definition) {
446            if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
447                Object.defineProperty(exports, key, {
448                    enumerable: true,
449                    get: definition[key]
450                });
451            }
452        }
453    };
454})();
455
456(() => {
457    __webpack_require__.o = (obj, prop) => Object.prototype.hasOwnProperty.call(obj, prop);
458})();
459
460var __webpack_exports__ = {};
461
462(() => {
463    const proxyMarker = Symbol("Comlink.proxy");
464    const createEndpoint = Symbol("Comlink.endpoint");
465    const releaseProxy = Symbol("Comlink.releaseProxy");
466    const finalizer = Symbol("Comlink.finalizer");
467    const throwMarker = Symbol("Comlink.thrown");
468    const isObject = val => typeof val === "object" && val !== null || typeof val === "function";
469    const proxyTransferHandler = {
470        canHandle: val => isObject(val) && val[proxyMarker],
471        serialize(obj) {
472            const {port1, port2} = new MessageChannel;
473            expose(obj, port1);
474            return [ port2, [ port2 ] ];
475        },
476        deserialize(port) {
477            port.start();
478            return wrap(port);
479        }
480    };
481    const throwTransferHandler = {
482        canHandle: value => isObject(value) && throwMarker in value,
483        serialize({value}) {
484            let serialized;
485            if (value instanceof Error) {
486                serialized = {
487                    isError: true,
488                    value: {
489                        message: value.message,
490                        name: value.name,
491                        stack: value.stack
492                    }
493                };
494            } else {
495                serialized = {
496                    isError: false,
497                    value
498                };
499            }
500            return [ serialized, [] ];
501        },
502        deserialize(serialized) {
503            if (serialized.isError) {
504                throw Object.assign(new Error(serialized.value.message), serialized.value);
505            }
506            throw serialized.value;
507        }
508    };
509    const transferHandlers = new Map([ [ "proxy", proxyTransferHandler ], [ "throw", throwTransferHandler ] ]);
510    function isAllowedOrigin(allowedOrigins, origin) {
511        for (const allowedOrigin of allowedOrigins) {
512            if (origin === allowedOrigin || allowedOrigin === "*") {
513                return true;
514            }
515            if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {
516                return true;
517            }
518        }
519        return false;
520    }
521    function expose(obj, ep = globalThis, allowedOrigins = [ "*" ]) {
522        ep.addEventListener("message", (function callback(ev) {
523            if (!ev || !ev.data) {
524                return;
525            }
526            if (!isAllowedOrigin(allowedOrigins, ev.origin)) {
527                console.warn(\`Invalid origin '\${ev.origin}' for comlink proxy\`);
528                return;
529            }
530            const {id, type, path} = Object.assign({
531                path: []
532            }, ev.data);
533            const argumentList = (ev.data.argumentList || []).map(fromWireValue);
534            let returnValue;
535            try {
536                const parent = path.slice(0, -1).reduce(((obj, prop) => obj[prop]), obj);
537                const rawValue = path.reduce(((obj, prop) => obj[prop]), obj);
538                switch (type) {
539                  case "GET":
540                    {
541                        returnValue = rawValue;
542                    }
543                    break;
544
545                  case "SET":
546                    {
547                        parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);
548                        returnValue = true;
549                    }
550                    break;
551
552                  case "APPLY":
553                    {
554                        returnValue = rawValue.apply(parent, argumentList);
555                    }
556                    break;
557
558                  case "CONSTRUCT":
559                    {
560                        const value = new rawValue(...argumentList);
561                        returnValue = proxy(value);
562                    }
563                    break;
564
565                  case "ENDPOINT":
566                    {
567                        const {port1, port2} = new MessageChannel;
568                        expose(obj, port2);
569                        returnValue = transfer(port1, [ port1 ]);
570                    }
571                    break;
572
573                  case "RELEASE":
574                    {
575                        returnValue = undefined;
576                    }
577                    break;
578
579                  default:
580                    return;
581                }
582            } catch (value) {
583                returnValue = {
584                    value,
585                    [throwMarker]: 0
586                };
587            }
588            Promise.resolve(returnValue).catch((value => ({
589                value,
590                [throwMarker]: 0
591            }))).then((returnValue => {
592                const [wireValue, transferables] = toWireValue(returnValue);
593                ep.postMessage(Object.assign(Object.assign({}, wireValue), {
594                    id
595                }), transferables);
596                if (type === "RELEASE") {
597                    ep.removeEventListener("message", callback);
598                    closeEndPoint(ep);
599                    if (finalizer in obj && typeof obj[finalizer] === "function") {
600                        obj[finalizer]();
601                    }
602                }
603            })).catch((error => {
604                const [wireValue, transferables] = toWireValue({
605                    value: new TypeError("Unserializable return value"),
606                    [throwMarker]: 0
607                });
608                ep.postMessage(Object.assign(Object.assign({}, wireValue), {
609                    id
610                }), transferables);
611            }));
612        }));
613        if (ep.start) {
614            ep.start();
615        }
616    }
617    function isMessagePort(endpoint) {
618        return endpoint.constructor.name === "MessagePort";
619    }
620    function closeEndPoint(endpoint) {
621        if (isMessagePort(endpoint)) endpoint.close();
622    }
623    function wrap(ep, target) {
624        return createProxy(ep, [], target);
625    }
626    function throwIfProxyReleased(isReleased) {
627        if (isReleased) {
628            throw new Error("Proxy has been released and is not useable");
629        }
630    }
631    function releaseEndpoint(ep) {
632        return requestResponseMessage(ep, {
633            type: "RELEASE"
634        }).then((() => {
635            closeEndPoint(ep);
636        }));
637    }
638    const proxyCounter = new WeakMap;
639    const proxyFinalizers = "FinalizationRegistry" in globalThis && new FinalizationRegistry((ep => {
640        const newCount = (proxyCounter.get(ep) || 0) - 1;
641        proxyCounter.set(ep, newCount);
642        if (newCount === 0) {
643            releaseEndpoint(ep);
644        }
645    }));
646    function registerProxy(proxy, ep) {
647        const newCount = (proxyCounter.get(ep) || 0) + 1;
648        proxyCounter.set(ep, newCount);
649        if (proxyFinalizers) {
650            proxyFinalizers.register(proxy, ep, proxy);
651        }
652    }
653    function unregisterProxy(proxy) {
654        if (proxyFinalizers) {
655            proxyFinalizers.unregister(proxy);
656        }
657    }
658    function createProxy(ep, path = [], target = function() {}) {
659        let isProxyReleased = false;
660        const proxy = new Proxy(target, {
661            get(_target, prop) {
662                throwIfProxyReleased(isProxyReleased);
663                if (prop === releaseProxy) {
664                    return () => {
665                        unregisterProxy(proxy);
666                        releaseEndpoint(ep);
667                        isProxyReleased = true;
668                    };
669                }
670                if (prop === "then") {
671                    if (path.length === 0) {
672                        return {
673                            then: () => proxy
674                        };
675                    }
676                    const r = requestResponseMessage(ep, {
677                        type: "GET",
678                        path: path.map((p => p.toString()))
679                    }).then(fromWireValue);
680                    return r.then.bind(r);
681                }
682                return createProxy(ep, [ ...path, prop ]);
683            },
684            set(_target, prop, rawValue) {
685                throwIfProxyReleased(isProxyReleased);
686                const [value, transferables] = toWireValue(rawValue);
687                return requestResponseMessage(ep, {
688                    type: "SET",
689                    path: [ ...path, prop ].map((p => p.toString())),
690                    value
691                }, transferables).then(fromWireValue);
692            },
693            apply(_target, _thisArg, rawArgumentList) {
694                throwIfProxyReleased(isProxyReleased);
695                const last = path[path.length - 1];
696                if (last === createEndpoint) {
697                    return requestResponseMessage(ep, {
698                        type: "ENDPOINT"
699                    }).then(fromWireValue);
700                }
701                if (last === "bind") {
702                    return createProxy(ep, path.slice(0, -1));
703                }
704                const [argumentList, transferables] = processArguments(rawArgumentList);
705                return requestResponseMessage(ep, {
706                    type: "APPLY",
707                    path: path.map((p => p.toString())),
708                    argumentList
709                }, transferables).then(fromWireValue);
710            },
711            construct(_target, rawArgumentList) {
712                throwIfProxyReleased(isProxyReleased);
713                const [argumentList, transferables] = processArguments(rawArgumentList);
714                return requestResponseMessage(ep, {
715                    type: "CONSTRUCT",
716                    path: path.map((p => p.toString())),
717                    argumentList
718                }, transferables).then(fromWireValue);
719            }
720        });
721        registerProxy(proxy, ep);
722        return proxy;
723    }
724    function myFlat(arr) {
725        return Array.prototype.concat.apply([], arr);
726    }
727    function processArguments(argumentList) {
728        const processed = argumentList.map(toWireValue);
729        return [ processed.map((v =>
729 v[0])), myFlat(processed.map((v => v[1]))) ];
730    }
731    const transferCache = new WeakMap;
732    function transfer(obj, transfers) {
733        transferCache.set(obj, transfers);
734        return obj;
735    }
736    function proxy(obj) {
737        return Object.assign(obj, {
738            [proxyMarker]: true
739        });
740    }
741    function windowEndpoint(w, context = globalThis, targetOrigin = "*") {
742        return {
743            postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),
744            addEventListener: context.addEventListener.bind(context),
745            removeEventListener: context.removeEventListener.bind(context)
746        };
747    }
748    function toWireValue(value) {
749        for (const [name, handler] of transferHandlers) {
750            if (handler.canHandle(value)) {
751                const [serializedValue, transferables] = handler.serialize(value);
752                return [ {
753                    type: "HANDLER",
754                    name,
755                    value: serializedValue
756                }, transferables ];
757            }
758        }
759        return [ {
760            type: "RAW",
761            value
762        }, transferCache.get(value) || [] ];
763    }
764    function fromWireValue(value) {
765        switch (value.type) {
766          case "HANDLER":
767            return transferHandlers.get(value.name).deserialize(value.value);
768
769          case "RAW":
770            return value.value;
771        }
772    }
773    function requestResponseMessage(ep, msg, transfers) {
774        return new Promise((resolve => {
775            const id = generateUUID();
776            ep.addEventListener("message", (function l(ev) {
777                if (!ev.data || !ev.data.id || ev.data.id !== id) {
778                    return;
779                }
780                ep.removeEventListener("message", l);
781                resolve(ev.data);
782            }));
783            if (ep.start) {
784                ep.start();
785            }
786            ep.postMessage(Object.assign({
787                id
788            }, msg), transfers);
789        }));
790    }
791    function generateUUID() {
792        return new Array(4).fill(0).map((() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))).join("-");
793    }
794    var browser = __webpack_require__(227);
795    var browser_default = __webpack_require__.n(browser);
796    function getSharedMemoryAvailable() {
797        const globalScope = typeof window !== "undefined" ? window : globalThis;
798        return typeof SharedArrayBuffer !== "undefined" && globalScope.crossOriginIsolated;
799    }
800    function getRemoteBarretenbergWasm(worker) {
801        return wrap(worker);
802    }
803    function getNumCpu() {
804        return navigator.hardwareConcurrency;
805    }
806    function threadLogger() {
807        return undefined;
808    }
809    function killSelf() {
810        self.close();
811    }
812    var inline = __webpack_require__(477);
813    var inline_default = __webpack_require__.n(inline);
814    function Worker_fn() {
815        return inline_default()('/*! For license information please see thread.worker.worker.worker.js.LICENSE.txt */\\nvar __webpack_modules__ = {\\n    227: (module, exports, __webpack_require__) => {\\n        exports.formatArgs = formatArgs;\\n        exports.save = save;\\n        exports.load = load;\\n        exports.useColors = useColors;\\n        exports.storage = localstorage();\\n        exports.destroy = (() => {\\n            let warned = false;\\n            return () => {\\n                if (!warned) {\\n                    warned = true;\\n                    console.warn("Instance method \`debug.destroy()\` is deprecated and no longer does anything. It will be removed in the next major version of \`debug\`.");\\n                }\\n            };\\n        })();\\n        exports.colors = [ "#0000CC", "#0000FF", "#0033CC", "#0033FF", "#0066CC", "#0066FF", "#0099CC", "#0099FF", "#00CC00", "#00CC33", "#00CC66", "#00CC99", "#00CCCC", "#00CCFF", "#3300CC", "#3300FF", "#3333CC", "#3333FF", "#3366CC", "#3366FF", "#3399CC", "#3399FF", "#33CC00", "#33CC33", "#33CC66", "#33CC99", "#33CCCC", "#33CCFF", "#6600CC", "#6600FF", "#6633CC", "#6633FF", "#66CC00", "#66CC33", "#9900CC", "#9900FF", "#9933CC", "#9933FF", "#99CC00", "#99CC33", "#CC0000", "#CC0033", "#CC0066", "#CC0099", "#CC00CC", "#CC00FF", "#CC3300", "#CC3333", "#CC3366", "#CC3399", "#CC33CC", "#CC33FF", "#CC6600", "#CC6633", "#CC9900", "#CC9933", "#CCCC00", "#CCCC33", "#FF0000", "#FF0033", "#FF0066", "#FF0099", "#FF00CC", "#FF00FF", "#FF3300", "#FF3333", "#FF3366", "#FF3399", "#FF33CC", "#FF33FF", "#FF6600", "#FF6633", "#FF9900", "#FF9933", "#FFCC00", "#FFCC33" ];\\n        function useColors() {\\n            if (typeof window !== "undefined" && window.process && (window.process.type === "renderer" || window.process.__nwjs)) {\\n                return true;\\n            }\\n            if (typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\\\\/(\\\\d+)/)) {\\n                return false;\\n            }\\n            return typeof document !== "undefined" && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance || typeof window !== "undefined" && window.console && (window.console.firebug || window.console.exception && window.console.table) || typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\\\\/(\\\\d+)/) && parseInt(RegExp.$1, 10) >= 31 || typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\\\\/(\\\\d+)/);\\n        }\\n        function formatArgs(args) {\\n            args[0] = (this.useColors ? "%c" : "") + this.namespace + (this.useColors ? " %c" : " ") + args[0] + (this.useColors ? "%c " : " ") + "+" + module.exports.humanize(this.diff);\\n            if (!this.useColors) {\\n                return;\\n            }\\n            const c = "color: " + this.color;\\n            args.splice(1, 0, c, "color: inherit");\\n            let index = 0;\\n            let lastC = 0;\\n            args[0].replace(/%[a-zA-Z%]/g, (match => {\\n                if (match === "%%") {\\n                    return;\\n                }\\n                index++;\\n                if (match === "%c") {\\n                    lastC = index;\\n                }\\n            }));\\n            args.splice(lastC, 0, c);\\n        }\\n        exports.log = console.debug || console.log || (() => {});\\n        function save(namespaces) {\\n            try {\\n                if (namespaces) {\\n                    exports.storage.setItem("debug", namespaces);\\n                } else {\\n                    exports.storage.removeItem("debug");\\n                }\\n            } catch (error) {}\\n        }\\n        function load() {\\n            let r;\\n            try {\\n                r = exports.storage.getItem("debug");\\n            } catch (error) {}\\n            if (!r && typeof process !== "undefined" && "env" in process) {\\n                r = process.env.DEBUG;\\n            }\\n            return r;\\n        }\\n        function localstorage() {\\n            try {\\n                return localStorage;\\n            } catch (error) {}\\n        }\\n        module.exports = __webpack_require__(447)(exports);\\n        const {formatters} = module.exports;\\n        formatters.j = function(v) {\\n            try {\\n                return JSON.stringify(v);\\n            } catch (error) {\\n                return "[UnexpectedJSONParseError]: " + error.message;\\n            }\\n        };\\n    },\\n    447: (module, __unused_webpack_exports, __webpack_require__) => {\\n        function setup(env) {\\n            createDebug.debug = createDebug;\\n            createDebug.default = createDebug;\\n            createDebug.coerce = coerce;\\n            createDebug.disable = disable;\\n            createDebug.enable = enable;\\n            createDebug.enabled = enabled;\\n            createDebug.humanize = __webpack_require__(824);\\n            createDebug.destroy = destroy;\\n            Object.keys(env).forEach((key => {\\n                createDebug[key] = env[key];\\n            }));\\n            createDebug.names = [];\\n            createDebug.skips = [];\\n            createDebug.formatters = {};\\n            function selectColor(namespace) {\\n                let hash = 0;\\n                for (let i = 0; i < namespace.length; i++) {\\n                    hash = (hash << 5) - hash + namespace.charCodeAt(i);\\n                    hash |= 0;\\n                }\\n                return createDebug.colors[Math.abs(hash) % createDebug.colors.length];\\n            }\\n            createDebug.selectColor = selectColor;\\n            function createDebug(namespace) {\\n                let prevTime;\\n                let enableOverride = null;\\n                let namespacesCache;\\n                let enabledCache;\\n                function debug(...args) {\\n                    if (!debug.enabled) {\\n                        return;\\n                    }\\n                    const self = debug;\\n                    const curr = Number(new Date);\\n                    const ms = curr - (prevTime || curr);\\n                    self.diff = ms;\\n                    self.prev = prevTime;\\n                    self.curr = curr;\\n                    prevTime = curr;\\n                    args[0] = createDebug.coerce(args[0]);\\n                    if (typeof args[0] !== "string") {\\n                        args.unshift("%O");\\n                    }\\n                    let index = 0;\\n                    args[0] = args[0].replace(/%([a-zA-Z%])/g, ((match, format) => {\\n                        if (match === "%%") {\\n                            return "%";\\n                        }\\n                        index++;\\n                        const formatter = createDebug.formatters[format];\\n                        if (typeof formatter === "function") {\\n                            const val = args[index];\\n                            match = formatter.call(self, val);\\n                            args.splice(index, 1);\\n                            index--;\\n                        }\\n                        return match;\\n                    }));\\n                    createDebug.formatArgs.call(self, args);\\n                    const logFn = self.log || createDebug.log;\\n                    logFn.apply(self, args);\\n                }\\n                debug.namespace = namespace;\\n                debug.useColors = createDebug.useColors();\\n                debug.color = createDebug.selectColor(namespace);\\n                debug.extend = extend;\\n                debug.destroy = createDebug.destroy;\\n                Object.defineProperty(debug, "enabled", {\\n                    enumerable: true,\\n                    configurable: false,\\n                    get: () => {\\n                        if (enableOverride !== null) {\\n                            return enableOverride;\\n                        }\\n                        if (namespacesCache !== createDebug.namespaces) {\\n                            namespacesCache = createDebug.namespaces;\\n                            enabledCache = createDebug.enabled(namespace);\\n                        }\\n                        return enabledCache;\\n                    },\\n                    set: v => {\\n                        enableOverride = v;\\n                    }\\n                });\\n                if (typeof createDebug.init === "function") {\\n                    createDebug.init(debug);\\n                }\\n                return debug;\\n            }\\n            function extend(namespace, delimiter) {\\n                const newDebug = createDebug(this.namespace + (typeof delimiter === "undefined" ? ":" : delimiter) + namespace);\\n                newDebug.log = this.log;\\n                return newDebug;\\n            }\\n            function enable(namespaces) {\\n                createDebug.save(namespaces);\\n                createDebug.namespaces = namespaces;\\n                createDebug.names = [];\\n                createDebug.skips = [];\\n                let i;\\n                const split = (typeof namespaces === "string" ? namespaces : "").split(/[\\\\s,]+/);\\n                const len = split.length;\\n                for (i = 0; i < len; i++) {\\n                    if (!split[i]) {\\n                        continue;\\n                    }\\n                    namespaces = split[i].replace(/\\\\*/g, ".*?");\\n                    if (namespaces[0] === "-") {\\n                        createDebug.skips.push(new RegExp("^" + namespaces.slice(1) + "$"));\\n                    } else {\\n                        createDebug.names.push(new RegExp("^" + namespaces + "$"));\\n                    }\\n                }\\n            }\\n            function disable() {\\n                const namespaces = [ ...createDebug.names.map(toNamespace), ...createDebug.skips.map(toNamespace).map((namespace => "-" + namespace)) ].join(",");\\n                createDebug.enable("");\\n                return namespaces;\\n            }\\n            function enabled(name) {\\n                if (name[name.length - 1] === "*") {\\n                    return true;\\n                }\\n                let i;\\n                let len;\\n                for (i = 0, len = createDebug.skips.length; i < len; i++) {\\n                    if (createDebug.skips[i].test(name)) {\\n                        return false;\\n                    }\\n                }\\n                for (i = 0, len = createDebug.names.length; i < len; i++) {\\n                    if (createDebug.names[i].test(name)) {\\n                        return true;\\n                    }\\n                }\\n                return false;\\n            }\\n            function toNamespace(regexp) {\\n                return regexp.toString().substring(2, regexp.toString().length - 2).replace(/\\\\.\\\\*\\\\?$/, "*");\\n            }\\n            function coerce(val) {\\n                if (val instanceof Error) {\\n                    return val.stack || val.message;\\n                }\\n                return val;\\n            }\\n            function destroy() {\\n                console.warn("Instance method \`debug.destroy()\` is deprecated and no longer does anything. It will be removed in the next major version of \`debug\`.");\\n            }\\n            createDebug.enable(createDebug.load());\\n            return createDebug;\\n        }\\n        module.exports = setup;\\n    },\\n    824: module => {\\n        var s = 1e3;\\n        var m = s * 60;\\n        var h = m * 60;\\n        var d = h * 24;\\n        var w = d * 7;\\n        var y = d * 365.25;\\n        module.exports = function(val, options) {\\n            options = options || {};\\n            var type = typeof val;\\n            if (type === "string" && val.length > 0) {\\n                return parse(val);\\n            } else if (type === "number" && isFinite(val)) {\\n                return options.long ? fmtLong(val) 
815: fmtShort(val);\\n            }\\n            throw new Error("val is not a non-empty string or a valid number. val=" + JSON.stringify(val));\\n        };\\n        function parse(str) {\\n            str = String(str);\\n            if (str.length > 100) {\\n                return;\\n            }\\n            var match = /^(-?(?:\\\\d+)?\\\\.?\\\\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(str);\\n            if (!match) {\\n                return;\\n            }\\n            var n = parseFloat(match[1]);\\n            var type = (match[2] || "ms").toLowerCase();\\n            switch (type) {\\n              case "years":\\n              case "year":\\n              case "yrs":\\n              case "yr":\\n              case "y":\\n                return n * y;\\n\\n              case "weeks":\\n              case "week":\\n              case "w":\\n                return n * w;\\n\\n              case "days":\\n              case "day":\\n              case "d":\\n                return n * d;\\n\\n              case "hours":\\n              case "hour":\\n              case "hrs":\\n              case "hr":\\n              case "h":\\n                return n * h;\\n\\n              case "minutes":\\n              case "minute":\\n              case "mins":\\n              case "min":\\n              case "m":\\n                return n * m;\\n\\n              case "seconds":\\n              case "second":\\n              case "secs":\\n              case "sec":\\n              case "s":\\n                return n * s;\\n\\n              case "milliseconds":\\n              case "millisecond":\\n              case "msecs":\\n              case "msec":\\n              case "ms":\\n                return n;\\n\\n              default:\\n                return undefined;\\n            }\\n        }\\n        function fmtShort(ms) {\\n            var msAbs = Math.abs(ms);\\n            if (msAbs >= d) {\\n                return Math.round(ms / d) + "d";\\n            }\\n            if (msAbs >= h) {\\n                return Math.round(ms / h) + "h";\\n            }\\n            if (msAbs >= m) {\\n                return Math.round(ms / m) + "m";\\n            }\\n            if (msAbs >= s) {\\n                return Math.round(ms / s) + "s";\\n            }\\n            return ms + "ms";\\n        }\\n        function fmtLong(ms) {\\n            var msAbs = Math.abs(ms);\\n            if (msAbs >= d) {\\n                return plural(ms, msAbs, d, "day");\\n            }\\n            if (msAbs >= h) {\\n                return plural(ms, msAbs, h, "hour");\\n            }\\n            if (msAbs >= m) {\\n                return plural(ms, msAbs, m, "minute");\\n            }\\n            if (msAbs >= s) {\\n                return plural(ms, msAbs, s, "second");\\n            }\\n            return ms + " ms";\\n        }\\n        function plural(ms, msAbs, n, name) {\\n            var isPlural = msAbs >= n * 1.5;\\n            return Math.round(ms / n) + " " + name + (isPlural ? "s" : "");\\n        }\\n    }\\n};\\n\\nvar __webpack_module_cache__ = {};\\n\\nfunction __webpack_require__(moduleId) {\\n    var cachedModule = __webpack_module_cache__[moduleId];\\n    if (cachedModule !== undefined) {\\n        return cachedModule.exports;\\n    }\\n    var module = __webpack_module_cache__[moduleId] = {\\n        exports: {}\\n    };\\n    __webpack_modules__[moduleId](module, module.exports, __webpack_require__);\\n    return module.exports;\\n}\\n\\n(() => {\\n    __webpack_require__.n = module => {\\n        var getter = module && module.__esModule ? () => module["default"] : () => module;\\n        __webpack_require__.d(getter, {\\n            a: getter\\n        });\\n        return getter;\\n    };\\n})();\\n\\n(() => {\\n    __webpack_require__.d = (exports, definition) => {\\n        for (var key in definition) {\\n            if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\\n                Object.defineProperty(exports, key, {\\n                    enumerable: true,\\n                    get: definition[key]\\n                });\\n            }\\n        }\\n    };\\n})();\\n\\n(() => {\\n    __webpack_require__.o = (obj, prop) => Object.prototype.hasOwnProperty.call(obj, prop);\\n})();\\n\\nvar __webpack_exports__ = {};\\n\\n(() => {\\n    const proxyMarker = Symbol("Comlink.proxy");\\n    const createEndpoint = Symbol("Comlink.endpoint");\\n    const releaseProxy = Symbol("Comlink.releaseProxy");\\n    const finalizer = Symbol("Comlink.finalizer");\\n    const throwMarker = Symbol("Comlink.thrown");\\n    const isObject = val => typeof val === "object" && val !== null || typeof val === "function";\\n    const proxyTransferHandler = {\\n        canHandle: val => isObject(val) && val[proxyMarker],\\n        serialize(obj) {\\n            const {port1, port2} = new MessageChannel;\\n            expose(obj, port1);\\n            return [ port2, [ port2 ] ];\\n        },\\n        deserialize(port) {\\n            port.start();\\n            return comlink_wrap(port);\\n        }\\n    };\\n    const throwTransferHandler = {\\n        canHandle: value => isObject(value) && throwMarker in value,\\n        serialize({value}) {\\n            let serialized;\\n            if (value instanceof Error) {\\n                serialized = {\\n                    isError: true,\\n                    value: {\\n                        message: value.message,\\n                        name: value.name,\\n                        stack: value.stack\\n                    }\\n                };\\n            } else {\\n                serialized = {\\n                    isError: false,\\n                    value\\n                };\\n            }
815\\n            return [ serialized, [] ];\\n        },\\n        deserialize(serialized) {\\n            if (serialized.isError) {\\n                throw Object.assign(new Error(serialized.value.message), serialized.value);\\n            }\\n            throw serialized.value;\\n        }\\n    };\\n    const transferHandlers = new Map([ [ "proxy", proxyTransferHandler ], [ "throw", throwTransferHandler ] ]);\\n    function isAllowedOrigin(allowedOrigins, origin) {\\n        for (const allowedOrigin of allowedOrigins) {\\n            if (origin === allowedOrigin || allowedOrigin === "*") {\\n                return true;\\n            }\\n            if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\\n                return true;\\n            }\\n        }\\n        return false;\\n    }\\n    function expose(obj, ep = globalThis, allowedOrigins = [ "*" ]) {\\n        ep.addEventListener("message", (function callback(ev) {\\n            if (!ev || !ev.data) {\\n                return;\\n            }\\n            if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\\n                console.warn(\`Invalid origin \\'\${ev.origin}\\' for comlink proxy\`);\\n                return;\\n            }\\n            const {id, type, path} = Object.assign({\\n                path: []\\n            }, ev.data);\\n            const argumentList = (ev.data.argumentList || []).map(fromWireValue);\\n            let returnValue;\\n            try {\\n                const parent = path.slice(0, -1).reduce(((obj, prop) => obj[prop]), obj);\\n                const rawValue = path.reduce(((obj, prop) => obj[prop]), obj);\\n                switch (type) {\\n                  case "GET":\\n                    {\\n                        returnValue = rawValue;\\n                    }\\n                    break;\\n\\n                  case "SET":\\n                    {\\n                        parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\\n                        returnValue = true;\\n                    }\\n                    break;\\n\\n                  case "APPLY":\\n                    {\\n                        returnValue = rawValue.apply(parent, argumentList);\\n                    }\\n                    break;\\n\\n                  case "CONSTRUCT":\\n                    {\\n                        const value = new rawValue(...argumentList);\\n                        returnValue = proxy(value);\\n                    }\\n                    break;\\n\\n                  case "ENDPOINT":\\n                    {\\n                        const {port1, port2} = new MessageChannel;\\n                        expose(obj, port2);\\n                        returnValue = transfer(port1, [ port1 ]);\\n                    }\\n                    break;\\n\\n                  case "RELEASE":\\n                    {\\n                        returnValue = undefined;\\n                    }\\n                    break;\\n\\n                  default:\\n                    return;\\n                }\\n            } catch (value) {\\n                returnValue = {\\n                    value,\\n                    [throwMarker]: 0\\n                };\\n            }\\n            Promise.resolve(returnValue).catch((value => ({\\n                value,\\n                [throwMarker]: 0\\n            }))).then((returnValue => {\\n                const [wireValue, transferables] = toWireValue(returnValue);\\n                ep.postMessage(Object.assign(Object.assign({}, wireValue), {\\n                    id\\n                }), transferables);\\n                if (type === "RELEASE") {\\n                    ep.removeEventListener("message", callback);\\n                    closeEndPoint(ep);\\n                    if (finalizer in obj && typeof obj[finalizer] === "function") {\\n                        obj[finalizer]();\\n                    }\\n                }\\n            })).catch((error => {\\n                const [wireValue, transferables] = toWireValue({\\n                    value: new TypeError("Unserializable return value"),\\n                    [throwMarker]: 0\\n                });\\n                ep.postMessage(Object.assign(Object.assign({}, wireValue), {\\n                    id\\n                }), transferables);\\n            }));\\n        }));\\n        if (ep.start) {\\n            ep.start();\\n        }\\n    }\\n    function isMessagePort(endpoint) {\\n        return endpoint.constructor.name === "MessagePort";\\n    }\\n    function closeEndPoint(endpoint) {\\n        if (isMessagePort(endpoint)) endpoint.close();\\n    }\\n    function comlink_wrap(ep, target) {\\n        return createProxy(ep, [], target);\\n    }\\n    function throwIfProxyReleased(isReleased) {\\n        if (isReleased) {\\n            throw new Error("Proxy has been released and is not useable");\\n        }\\n    }\\n    function releaseEndpoint(ep) {\\n        return requestResponseMessage(ep, {\\n            type: "RELEASE"\\n        }).then((() => {\\n            closeEndPoint(ep);\\n        }));\\n    }\\n    const proxyCounter = new WeakMap;\\n    const proxyFinalizers = "FinalizationRegistry" in globalThis && new FinalizationRegistry((ep => {\\n        const newCount = (proxyCounter.get(ep) || 0) - 1;\\n        proxyCounter.set(ep, newCount);\\n        if (newCount === 0) {\\n            releaseEndpoint(ep);\\n        }\\n    }));\\n    function registerProxy(proxy, ep) {\\n        const newCount = (proxyCounter.get(ep) || 0) + 1;\\n        proxyCounter.set(ep, newCount);\\n        if (proxyFinalizers) {\\n            proxyFinalizers.register(proxy, ep, proxy);\\n        }\\n    }\\n    function unregisterProxy(proxy) {\\n        if (proxyFinalizers) {\\n            proxyFinalizers.unregister(proxy);\\n        }\\n    }\\n    function createProxy(ep, path = [], target = function() {}) {\\n        let isProxyReleased = false;\\n        const proxy = new Proxy(target, {\\n            get(_target, prop) {\\n                throwIfProxyReleased(isProxyReleased);\\n                if (prop === releaseProxy) {\\n                    return () => {\\n                        unregisterProxy(proxy);\\n                        releaseEndpoint(ep);\\n                        isProxyReleased = true;\\n                    };\\n                }\\n                if (prop === "then") {\\n                    if (path.length === 0) {\\n                        return {\\n                            then: () => proxy\\n                        };\\n                    }\\n                    const r = requestResponseMessage(ep, {\\n                        type: "GET",\\n                        path: path.map((p => p.toString()))\\n                    }).then(fromWireValue);\\n                    return r.then.bind(r);\\n                }\\n                return createProxy(ep, [ ...path, prop ]);\\n            },\\n            set(_target, prop, rawValue) {\\n                throwIfProxyReleased(isProxyReleased);\\n                const [value, transferables] = toWireValue(rawValue);\\n                return requestResponseMessage(ep, {\\n                    type: "SET",\\n                    path: [ ...path, prop ].map((p => p.toString())),\\n                    value\\n                }, transferables).then(fromWireValue);\\n            },\\n            apply(_target, _thisArg, rawArgumentList) {\\n                throwIfProxyReleased(isProxyReleased);\\n                const last = path[path.length - 1];\\n                if (last === createEndpoint) {\\n                    return requestResponseMessage(ep, {\\n                        type: "ENDPOINT"\\n                    }).then(fromWireValue);\\n                }\\n                if (last === "bind") {\\n                    return createProxy(ep, path.slice(0, -1));\\n                }\\n                const [argumentList, transferables] = processArguments(rawArgumentList);\\n                return requestResponseMessage(ep, {\\n                    type: "APPLY",\\n                    path: path.map((p => p.toString())),\\n                    argumentList\\n                }, transferables).then(fromWireValue);\\n            },\\n            construct(_target, rawArgumentList) {\\n                throwIfProxyReleased(isProxyReleased);\\n                const [argumentList, transferables] = processArguments(rawArgumentList);\\n                return requestResponseMessage(ep, {\\n                    type: "CONSTRUCT",\\n                    path: path.map((p => p.toString())),\\n                    argumentList\\n                }, transferables).then(fromWireValue);\\n            }\\n        });\\n        registerProxy(proxy, ep);\\n        return proxy;\\n    }\\n    function myFlat(arr) {\\n        return Array.prototype.concat.apply([], arr);\\n    }\\n    function processArguments(argumentList) {\\n        const processed = argumentList.map(toWireValue);\\n        return [ processed.map((v =>
815 v[0])), myFlat(processed.map((v => v[1]))) ];\\n    }\\n    const transferCache = new WeakMap;\\n    function transfer(obj, transfers) {\\n        transferCache.set(obj, transfers);\\n        return obj;\\n    }\\n    function proxy(obj) {\\n        return Object.assign(obj, {\\n            [proxyMarker]: true\\n        });\\n    }\\n    function windowEndpoint(w, context = globalThis, targetOrigin = "*") {\\n        return {\\n            postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),\\n            addEventListener: context.addEventListener.bind(context),\\n            removeEventListener: context.removeEventListener.bind(context)\\n        };\\n    }\\n    function toWireValue(value) {\\n        for (const [name, handler] of transferHandlers) {\\n            if (handler.canHandle(value)) {\\n                const [serializedValue, transferables] = handler.serialize(value);\\n                return [ {\\n                    type: "HANDLER",\\n                    name,\\n                    value: serializedValue\\n                }, transferables ];\\n            }\\n        }\\n        return [ {\\n            type: "RAW",\\n            value\\n        }, transferCache.get(value) || [] ];\\n    }\\n    function fromWireValue(value) {\\n        switch (value.type) {\\n          case "HANDLER":\\n            return transferHandlers.get(value.name).deserialize(value.value);\\n\\n          case "RAW":\\n            return value.value;\\n        }\\n    }\\n    function requestResponseMessage(ep, msg, transfers) {\\n        return new Promise((resolve => {\\n            const id = generateUUID();\\n            ep.addEventListener("message", (function l(ev) {\\n                if (!ev.data || !ev.data.id || ev.data.id !== id) {\\n                    return;\\n                }\\n                ep.removeEventListener("message", l);\\n                resolve(ev.data);\\n            }));\\n            if (ep.start) {\\n                ep.start();\\n            }\\n            ep.postMessage(Object.assign({\\n                id\\n            }, msg), transfers);\\n        }));\\n    }\\n    function generateUUID() {\\n        return new Array(4).fill(0).map((() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))).join("-");\\n    }\\n    function getSharedMemoryAvailable() {\\n        const globalScope = typeof window !== "undefined" ? window : globalThis;\\n        return typeof SharedArrayBuffer !== "undefined" && globalScope.crossOriginIsolated;\\n    }\\n    function getRemoteBarretenbergWasm(worker) {\\n        return wrap(worker);\\n    }\\n    function getNumCpu() {\\n        return navigator.hardwareConcurrency;\\n    }\\n    function threadLogger() {\\n        return undefined;\\n    }\\n    function killSelf() {\\n        self.close();\\n    }\\n    var browser = __webpack_require__(227);\\n    var browser_default = __webpack_require__.n(browser);\\n    const randomBytes = len => {\\n        const getWebCrypto = () => {\\n            if (typeof window !== "undefined" && window.crypto) return window.crypto;\\n            if (typeof globalThis !== "undefined" && globalThis.crypto) return globalThis.crypto;\\n            return undefined;\\n        };\\n        const crypto = getWebCrypto();\\n        if (!crypto) {\\n            throw new Error("randomBytes UnsupportedEnvironment");\\n        }\\n        const buf = new Uint8Array(len);\\n        const MAX_BYTES = 65536;\\n        if (len > MAX_BYTES) {\\n            for (let generated = 0; generated < len; generated += MAX_BYTES) {\\n                crypto.getRandomValues(buf.subarray(generated, generated + MAX_BYTES));\\n            }\\n        } else {\\n            crypto.getRandomValues(buf);\\n        }\\n        return buf;\\n    };\\n    class BarretenbergWasmBase {\\n        constructor() {\\n            this.memStore = {};\\n            this.logger = browser_default()("bb.js:bb_wasm_base");\\n        }\\n        getImportObj(memory) {\\n            const importObj = {\\n                wasi_snapshot_preview1: {\\n                    random_get: (out, length) => {\\n                        out = out >>> 0;\\n                        const randomData = randomBytes(length);\\n                        const mem = this.getMemory();\\n                        mem.set(randomData, out);\\n                    },\\n                    clock_time_get: (a1, a2, out) => {\\n                        out = out >>> 0;\\n                        const ts = BigInt((new Date).getTime()) * 1000000n;\\n                        const view = new DataView(this.getMemory().buffer);\\n                        view.setBigUint64(out, ts, true);\\n                    },\\n                    proc_exit: () => {\\n                        this.logger("PANIC: proc_exit was called.");\\n                        throw new Error;\\n                    }\\n                },\\n                env: {\\n                    logstr: addr => {\\n                        const str = this.stringFromAddress(addr);\\n                        const m = this.getMemory();\\n                        const str2 = \`\${str} (mem: \${(m.length / (1024 * 1024)).toFixed(2)}MiB)\`;\\n                        this.logger(str2);\\n                    },\\n                    get_data: (keyAddr, outBufAddr) =>
815 {\\n                        const key = this.stringFromAddress(keyAddr);\\n                        outBufAddr = outBufAddr >>> 0;\\n                        const data = this.memStore[key];\\n                        if (!data) {\\n                            this.logger(\`get_data miss \${key}\`);\\n                            return;\\n                        }\\n                        this.writeMemory(outBufAddr, data);\\n                    },\\n                    set_data: (keyAddr, dataAddr, dataLength) => {\\n                        const key = this.stringFromAddress(keyAddr);\\n                        dataAddr = dataAddr >>> 0;\\n                        this.memStore[key] = this.getMemorySlice(dataAddr, dataAddr + dataLength);\\n                    },\\n                    memory\\n                }\\n            };\\n            return importObj;\\n        }\\n        exports() {\\n            return this.instance.exports;\\n        }\\n        call(name, ...args) {\\n            if (!this.exports()[name]) {\\n                throw new Error(\`WASM function \${name} not found.\`);\\n            }\\n            try {\\n                return this.exports()[name](...args) >>> 0;\\n            } catch (err) {\\n                const message = \`WASM function \${name} aborted, error: \${err}\`;\\n                this.logger(message);\\n                this.logger(err.stack);\\n                throw err;\\n            }\\n        }\\n        memSize() {\\n            return this.getMemory().length;\\n        }\\n        getMemorySlice(start, end) {\\n            return this.getMemory().subarray(start, end).slice();\\n        }\\n        writeMemory(offset, arr) {\\n            const mem = this.getMemory();\\n            mem.set(arr, offset);\\n        }\\n        getMemory() {\\n            return new Uint8Array(this.memory.buffer);\\n        }\\n        stringFromAddress(addr) {\\n            addr = addr >>> 0;\\n            const m = this.getMemory();\\n            let i = addr;\\n            for (;m[i] !== 0; ++i) ;\\n            const textDecoder = new TextDecoder("ascii");\\n            return textDecoder.decode(m.slice(addr, i));\\n        }\\n    }\\n    class BarretenbergWasmThread extends BarretenbergWasmBase {\\n        async initThread(module, memory) {\\n            this.logger = threadLogger() || this.logger;\\n            this.memory = memory;\\n            this.instance = await WebAssembly.instantiate(module, this.getImportObj(this.memory));\\n        }\\n        destroy() {\\n            killSelf();\\n        }\\n        getImportObj(memory) {\\n            const baseImports = super.getImportObj(memory);\\n            return {\\n                ...baseImports,\\n                wasi: {\\n                    "thread-spawn": () => {\\n                        this.logger("PANIC: threads cannot spawn threads!");\\n                        this.logger((new Error).stack);\\n                        killSelf();\\n                    }\\n                },\\n                env: {\\n                    ...baseImports.env,\\n                    env_hardware_concurrency: () => 1\\n                }\\n            };\\n        }\\n    }\\n    self.onmessage = function(e) {\\n        if (e.data.debug) {\\n            browser_default().enable(e.data.debug);\\n        }\\n    };\\n    expose(new BarretenbergWasmThread);\\n    self.postMessage({\\n        ready: true\\n    });\\n    const thread_worker = null;\\n})();', "Worker", undefined, undefined);
816    }
817    function createThreadWorker() {
818        const worker = new Worker_fn;
819        const debugStr = browser_default().disable();
820        browser_default().enable(debugStr);
821        worker.postMessage({
822            debug: debugStr
823        });
824        return worker;
825    }
826    const randomBytes = len => {
827        const getWebCrypto = () => {
828            if (typeof window !== "undefined" && window.crypto) return window.crypto;
829            if (typeof globalThis !== "undefined" && globalThis.crypto) return globalThis.crypto;
830            return undefined;
831        };
832        const crypto = getWebCrypto();
833        if (!crypto) {
834            throw new Error("randomBytes UnsupportedEnvironment");
835        }
836        const buf = new Uint8Array(len);
837        const MAX_BYTES = 65536;
838        if (len > MAX_BYTES) {
839            for (let generated = 0; generated < len; generated += MAX_BYTES) {
840                crypto.getRandomValues(buf.subarray(generated, generated + MAX_BYTES));
841            }
842        } else {
843            crypto.getRandomValues(buf);
844        }
845        return buf;
846    };
847    class BarretenbergWasmBase {
848        constructor() {
849            this.memStore = {};
850            this.logger = browser_default()("bb.js:bb_wasm_base");
851        }
852        getImportObj(memory) {
853            const importObj = {
854                wasi_snapshot_preview1: {
855                    random_get: (out, length) => {
856                        out = out >>> 0;
857                        const randomData = randomBytes(length);
858                        const mem = this.getMemory();
859                        mem.set(randomData, out);
860                    },
861                    clock_time_get: (a1, a2, out) => {
862                        out = out >>> 0;
863                        const ts = BigInt((new Date).getTime()) * 1000000n;
864                        const view = new DataView(this.getMemory().buffer);
865                        view.setBigUint64(out, ts, true);
866                    },
867                    proc_exit: () => {
868                        this.logger("PANIC: proc_exit was called.");
869                        throw new Error;
870                    }
871                },
872                env: {
873                    logstr: addr => {
874                        const str = this.stringFromAddress(addr);
875                        const m = this.getMemory();
876                        const str2 = \`\${str} (mem: \${(m.length / (1024 * 1024)).toFixed(2)}MiB)\`;
877                        this.logger(str2);
878                    },
879                    get_data: (keyAddr, outBufAddr) => {
880                        const key = this.stringFromAddress(keyAddr);
881                        outBufAddr = outBufAddr >>> 0;
882                        const data = this.memStore[key];
883                        if (!data) {
884                            this.logger(\`get_data miss \${key}\`);
885                            return;
886                        }
887                        this.writeMemory(outBufAddr, data);
888                    },
889                    set_data: (keyAddr, dataAddr, dataLength) => {
890                        const key = this.stringFromAddress(keyAddr);
891                        dataAddr = dataAddr >>> 0;
892                        this.memStore[key] = this.getMemorySlice(dataAddr, dataAddr + dataLength);
893                    },
894                    memory
895                }
896            };
897            return importObj;
898        }
899        exports() {
900            return this.instance.exports;
901        }
902        call(name, ...args) {
903            if (!this.exports()[name]) {
904                throw new Error(\`WASM function \${name} not found.\`);
905            }
906            try {
907                return this.exports()[name](...args) >>> 0;
908            } catch (err) {
909                const message = \`WASM function \${name} aborted, error: \${err}\`;
910                this.logger(message);
911                this.logger(err.stack);
912                throw err;
913            }
914        }
915        memSize() {
916            return this.getMemory().length;
917        }
918        getMemorySlice(start, end) {
919            return this.getMemory().subarray(start, end).slice();
920        }
921        writeMemory(offset, arr) {
922            const mem = this.getMemory();
923            mem.set(arr, offset);
924        }
925        getMemory() {
926            return new Uint8Array(this.memory.buffer);
927        }
928        stringFromAddress(addr) {
929            addr = addr >>> 0;
930            const m = this.getMemory();
931            let i = addr;
932            for (;m[i] !== 0; ++i) ;
933            const textDecoder = new TextDecoder("ascii");
934            return textDecoder.decode(m.slice(addr, i));
935        }
936    }
937    class HeapAllocator {
938        constructor(wasm) {
939            this.wasm = wasm;
940            this.allocs = [];
941            this.inScratchRemaining = 1024;
942            this.outScratchRemaining = 1024;
943        }
944        getInputs(buffers) {
945            return buffers.map((bufOrNum => {
946                if (typeof bufOrNum === "object") {
947                    if (bufOrNum.length <= this.inScratchRemaining) {
948                        const ptr = this.inScratchRemaining -= bufOrNum.length;
949                        this.wasm.writeMemory(ptr, bufOrNum);
950                        return ptr;
951                    } else {
952                        const ptr = this.wasm.call("bbmalloc", bufOrNum.length);
953                        this.wasm.writeMemory(ptr, bufOrNum);
954                        this.allocs.push(ptr);
955                        return ptr;
956                    }
957                } else {
958                    return bufOrNum;
959                }
960            }));
961        }
962        getOutputPtrs(outLens) {
963            return outLens.map((len => {
964                const size = len || 4;
965                if (size <= this.outScratchRemaining) {
966                    return this.outScratchRemaining -= size;
967                } else {
968                    const ptr = this.wasm.call("bbmalloc", size);
969                    this.allocs.push(ptr);
970                    return ptr;
971                }
972            }));
973        }
974        addOutputPtr(ptr) {
975            if (ptr >= 1024) {
976                this.allocs.push(ptr);
977            }
978        }
979        freeAll() {
980            for (const ptr of this.allocs) {
981                this.wasm.call("bbfree", ptr);
982            }
983        }
984    }
985    class BarretenbergWasmMain extends BarretenbergWasmBase {
986        constructor() {
987            super(...arguments);
988            this.workers = [];
989            this.remoteWasms = [];
990            this.nextWorker = 0;
991            this.nextThreadId = 1;
992        }
993        getNumThreads() {
994            return this.workers.length + 1;
995        }
996        async init(module, threads = Math.min(getNumCpu(), BarretenbergWasmMain.MAX_THREADS), logger = browser_default()("bb.js:bb_wasm"), initial = 32, maximum = 2 ** 16) {
997            this.logger = logger;
998            const initialMb = initial * 2 ** 16 / (1024 * 1024);
999            const maxMb = maximum * 2 ** 16 / (1024 * 1024);
1000            const shared = getSharedMemoryAvailable();
1001            this.logger(\`Initializing bb wasm: initial memory \${initial} pages \${initialMb}MiB; \` + \`max memory: \${maximum} pages, \${maxMb}MiB; \` + \`threads: \${threads}; shared memory: \${shared}\`);
1002            this.memory = new WebAssembly.Memory({
1003                initial,
1004                maximum,
1005                shared
1006            });
1007            const instance = await WebAssembly.instantiate(module, this.getImportObj(this.memory)
1007);
1008            this.instance = instance;
1009            this.call("_initialize");
1010            if (threads > 1) {
1011                this.logger(\`Creating \${threads} worker threads\`);
1012                this.workers = await Promise.all(Array.from({
1013                    length: threads - 1
1014                }).map(createThreadWorker));
1015                this.remoteWasms = await Promise.all(this.workers.map(getRemoteBarretenbergWasm));
1016                await Promise.all(this.remoteWasms.map((w => w.initThread(module, this.memory))));
1017            }
1018        }
1019        async destroy() {
1020            await Promise.all(this.workers.map((w => w.terminate())));
1021        }
1022        getImportObj(memory) {
1023            const baseImports = super.getImportObj(memory);
1024            return {
1025                ...baseImports,
1026                wasi: {
1027                    "thread-spawn": arg => {
1028                        arg = arg >>> 0;
1029                        const id = this.nextThreadId++;
1030                        const worker = this.nextWorker++ % this.remoteWasms.length;
1031                        this.remoteWasms[worker].call("wasi_thread_start", id, arg).catch(this.logger);
1032                        return id;
1033                    }
1034                },
1035                env: {
1036                    ...baseImports.env,
1037                    env_hardware_concurrency: () => this.remoteWasms.length + 1
1038                }
1039            };
1040        }
1041        callWasmExport(funcName, inArgs, outLens) {
1042            const alloc = new HeapAllocator(this);
1043            const inPtrs = alloc.getInputs(inArgs);
1044            const outPtrs = alloc.getOutputPtrs(outLens);
1045            this.call(funcName, ...inPtrs, ...outPtrs);
1046            const outArgs = this.getOutputArgs(outLens, outPtrs, alloc);
1047            alloc.freeAll();
1048            return outArgs;
1049        }
1050        getOutputArgs(outLens, outPtrs, alloc) {
1051            return outLens.map(((len, i) => {
1052                if (len) {
1053                    return this.getMemorySlice(outPtrs[i], outPtrs[i] + len);
1054                }
1055                const slice = this.getMemorySlice(outPtrs[i], outPtrs[i] + 4);
1056                const ptr = new DataView(slice.buffer, slice.byteOffset, slice.byteLength).getUint32(0, true);
1057                alloc.addOutputPtr(ptr);
1058                const lslice = this.getMemorySlice(ptr, ptr + 4);
1059                const length = new DataView(lslice.buffer, lslice.byteOffset, lslice.byteLength).getUint32(0, false);
1060                return this.getMemorySlice(ptr + 4, ptr + 4 + length);
1061            }));
1062        }
1063    }
1064    BarretenbergWasmMain.MAX_THREADS = 32;
1065    self.onmessage = function(e) {
1066        if (e.data.debug) {
1067            browser_default().enable(e.data.debug);
1068        }
1069    };
1070    expose(new BarretenbergWasmMain);
1071    self.postMessage({
1072        ready: true
1073    });
1074    const main_worker = null;
1075})();`,"Worker",void 0,void 0)}function Je(){const b=new jt,E=wt().disable();return wt().enable(E),b.postMessage({debug:E}),b}function Et(){const b=typeof window<"u"?window:globalThis;return typeof SharedArrayBuffer<"u"&&b.crossOriginIsolated}function Bt(b){return ue(b)}function Qe(){return navigator.hardwareConcurrency}function Lt(){return Tt()(`/*! For license information please see thread.worker.worker.js.LICENSE.txt */
1076var __webpack_modules__ = {
1077    227: (module, exports, __webpack_require__) => {
1078        exports.formatArgs = formatArgs;
1079        exports.save = save;
1080        exports.load = load;
1081        exports.useColors = useColors;
1082        exports.storage = localstorage();
1083        exports.destroy = (() => {
1084            let warned = false;
1085            return () => {
1086                if (!warned) {
1087                    warned = true;
1088                    console.warn("Instance method \`debug.destroy()\` is deprecated and no longer does anything. It will be removed in the next major version of \`debug\`.");
1089                }
1090            };
1091        })();
1092        exports.colors = [ "#0000CC", "#0000FF", "#0033CC", "#0033FF", "#0066CC", "#0066FF", "#0099CC", "#0099FF", "#00CC00", "#00CC33", "#00CC66", "#00CC99", "#00CCCC", "#00CCFF", "#3300CC", "#3300FF", "#3333CC", "#3333FF", "#3366CC", "#3366FF", "#3399CC", "#3399FF", "#33CC00", "#33CC33", "#33CC66", "#33CC99", "#33CCCC", "#33CCFF", "#6600CC", "#6600FF", "#6633CC", "#6633FF", "#66CC00", "#66CC33", "#9900CC", "#9900FF", "#9933CC", "#9933FF", "#99CC00", "#99CC33", "#CC0000", "#CC0033", "#CC0066", "#CC0099", "#CC00CC", "#CC00FF", "#CC3300", "#CC3333", "#CC3366", "#CC3399", "#CC33CC", "#CC33FF", "#CC6600", "#CC6633", "#CC9900", "#CC9933", "#CCCC00", "#CCCC33", "#FF0000", "#FF0033", "#FF0066", "#FF0099", "#FF00CC", "#FF00FF", "#FF3300", "#FF3333", "#FF3366", "#FF3399", "#FF33CC", "#FF33FF", "#FF6600", "#FF6633", "#FF9900", "#FF9933", "#FFCC00", "#FFCC33" ];
1093        function useColors() {
1094            if (typeof window !== "undefined" && window.process && (window.process.type === "renderer" || window.process.__nwjs)) {
1095                return true;
1096            }
1097            if (typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\\/(\\d+)/)) {
1098                return false;
vendor: 8,271 bytes, lines 1099-1286
1099            }
1100            return typeof document !== "undefined" && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance || typeof window !== "undefined" && window.console && (window.console.firebug || window.console.exception && window.console.table) || typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\\/(\\d+)/) && parseInt(RegExp.$1, 10) >= 31 || typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\\/(\\d+)/);
1101        }
1102        function formatArgs(args) {
1103            args[0] = (this.useColors ? "%c" : "") + this.namespace + (this.useColors ? " %c" : " ") + args[0] + (this.useColors ? "%c " : " ") + "+" + module.exports.humanize(this.diff);
1104            if (!this.useColors) {
1105                return;
1106            }
1107            const c = "color: " + this.color;
1108            args.splice(1, 0, c, "color: inherit");
1109            let index = 0;
1110            let lastC = 0;
1111            args[0].replace(/%[a-zA-Z%]/g, (match => {
1112                if (match === "%%") {
1113                    return;
1114                }
1115                index++;
1116                if (match === "%c") {
1117                    lastC = index;
1118                }
1119            }));
1120            args.splice(lastC, 0, c);
1121        }
1122        exports.log = console.debug || console.log || (() => {});
1123        function save(namespaces) {
1124            try {
1125                if (namespaces) {
1126                    exports.storage.setItem("debug", namespaces);
1127                } else {
1128                    exports.storage.removeItem("debug");
1129                }
1130            } catch (error) {}
1131        }
1132        function load() {
1133            let r;
1134            try {
1135                r = exports.storage.getItem("debug");
1136            } catch (error) {}
1137            if (!r && typeof process !== "undefined" && "env" in process) {
1138                r = process.env.DEBUG;
1139            }
1140            return r;
1141        }
1142        function localstorage() {
1143            try {
1144                return localStorage;
1145            } catch (error) {}
1146        }
1147        module.exports = __webpack_require__(447)(exports);
1148        const {formatters} = module.exports;
1149        formatters.j = function(v) {
1150            try {
1151                return JSON.stringify(v);
1152            } catch (error) {
1153                return "[UnexpectedJSONParseError]: " + error.message;
1154            }
1155        };
1156    },
1157    447: (module, __unused_webpack_exports, __webpack_require__) => {
1158        function setup(env) {
1159            createDebug.debug = createDebug;
1160            createDebug.default = createDebug;
1161            createDebug.coerce = coerce;
1162            createDebug.disable = disable;
1163            createDebug.enable = enable;
1164            createDebug.enabled = enabled;
1165            createDebug.humanize = __webpack_require__(824);
1166            createDebug.destroy = destroy;
1167            Object.keys(env).forEach((key => {
1168                createDebug[key] = env[key];
1169            }));
1170            createDebug.names = [];
1171            createDebug.skips = [];
1172            createDebug.formatters = {};
1173            function selectColor(namespace) {
1174                let hash = 0;
1175                for (let i = 0; i < namespace.length; i++) {
1176                    hash = (hash << 5) - hash + namespace.charCodeAt(i);
1177                    hash |= 0;
1178                }
1179                return createDebug.colors[Math.abs(hash) % createDebug.colors.length];
1180            }
1181            createDebug.selectColor = selectColor;
1182            function createDebug(namespace) {
1183                let prevTime;
1184                let enableOverride = null;
1185                let namespacesCache;
1186                let enabledCache;
1187                function debug(...args) {
1188                    if (!debug.enabled) {
1189                        return;
1190                    }
1191                    const self = debug;
1192                    const curr = Number(new Date);
1193                    const ms = curr - (prevTime || curr);
1194                    self.diff = ms;
1195                    self.prev = prevTime;
1196                    self.curr = curr;
1197                    prevTime = curr;
1198                    args[0] = createDebug.coerce(args[0]);
1199                    if (typeof args[0] !== "string") {
1200                        args.unshift("%O");
1201                    }
1202                    let index = 0;
1203                    args[0] = args[0].replace(/%([a-zA-Z%])/g, ((match, format) => {
1204                        if (match === "%%") {
1205                            return "%";
1206                        }
1207                        index++;
1208                        const formatter = createDebug.formatters[format];
1209                        if (typeof formatter === "function") {
1210                            const val = args[index];
1211                            match = formatter.call(self, val);
1212                            args.splice(index, 1);
1213                            index--;
1214                        }
1215                        return match;
1216                    }));
1217                    createDebug.formatArgs.call(self, args);
1218                    const logFn = self.log || createDebug.log;
1219                    logFn.apply(self, args);
1220                }
1221                debug.namespace = namespace;
1222                debug.useColors = createDebug.useColors();
1223                debug.color = createDebug.selectColor(namespace);
1224                debug.extend = extend;
1225                debug.destroy = createDebug.destroy;
1226                Object.defineProperty(debug, "enabled", {
1227                    enumerable: true,
1228                    configurable: false,
1229                    get: () => {
1230                        if (enableOverride !== null) {
1231                            return enableOverride;
1232                        }
1233                        if (namespacesCache !== createDebug.namespaces) {
1234                            namespacesCache = createDebug.namespaces;
1235                            enabledCache = createDebug.enabled(namespace);
1236                        }
1237                        return enabledCache;
1238                    },
1239                    set: v => {
1240                        enableOverride = v;
1241                    }
1242                });
1243                if (typeof createDebug.init === "function") {
1244                    createDebug.init(debug);
1245                }
1246                return debug;
1247            }
1248            function extend(namespace, delimiter) {
1249                const newDebug = createDebug(this.namespace + (typeof delimiter === "undefined" ? ":" : delimiter) + namespace);
1250                newDebug.log = this.log;
1251                return newDebug;
1252            }
1253            function enable(namespaces) {
1254                createDebug.save(namespaces);
1255                createDebug.namespaces = namespaces;
1256                createDebug.names = [];
1257                createDebug.skips = [];
1258                let i;
1259                const split = (typeof namespaces === "string" ? namespaces : "").split(/[\\s,]+/);
1260                const len = split.length;
1261                for (i = 0; i < len; i++) {
1262                    if (!split[i]) {
1263                        continue;
1264                    }
1265                    namespaces = split[i].replace(/\\*/g, ".*?");
1266                    if (namespaces[0] === "-") {
1267                        createDebug.skips.push(new RegExp("^" + namespaces.slice(1) + "$"));
1268                    } else {
1269                        createDebug.names.push(new RegExp("^" + namespaces + "$"));
1270                    }
1271                }
1272            }
1273            function disable() {
1274                const namespaces = [ ...createDebug.names.map(toNamespace), ...createDebug.skips.map(toNamespace).map((namespace => "-" + namespace)) ].join(",");
1275                createDebug.enable("");
1276                return namespaces;
1277            }
1278            function enabled(name) {
1279                if (name[name.length - 1] === "*") {
1280                    return true;
1281                }
1282                let i;
1283                let len;
1284                for (i = 0, len = createDebug.skips.length; i < len; i++) {
1285                    if (createDebug.skips[i].test(name)) {
1286                        return false;
vendor: 4,902 bytes, lines 1287-1445
1287                    }
1288                }
1289                for (i = 0, len = createDebug.names.length; i < len; i++) {
1290                    if (createDebug.names[i].test(name)) {
1291                        return true;
1292                    }
1293                }
1294                return false;
1295            }
1296            function toNamespace(regexp) {
1297                return regexp.toString().substring(2, regexp.toString().length - 2).replace(/\\.\\*\\?$/, "*");
1298            }
1299            function coerce(val) {
1300                if (val instanceof Error) {
1301                    return val.stack || val.message;
1302                }
1303                return val;
1304            }
1305            function destroy() {
1306                console.warn("Instance method \`debug.destroy()\` is deprecated and no longer does anything. It will be removed in the next major version of \`debug\`.");
1307            }
1308            createDebug.enable(createDebug.load());
1309            return createDebug;
1310        }
1311        module.exports = setup;
1312    },
1313    824: module => {
1314        var s = 1e3;
1315        var m = s * 60;
1316        var h = m * 60;
1317        var d = h * 24;
1318        var w = d * 7;
1319        var y = d * 365.25;
1320        module.exports = function(val, options) {
1321            options = options || {};
1322            var type = typeof val;
1323            if (type === "string" && val.length > 0) {
1324                return parse(val);
1325            } else if (type === "number" && isFinite(val)) {
1326                return options.long ? fmtLong(val) : fmtShort(val);
1327            }
1328            throw new Error("val is not a non-empty string or a valid number. val=" + JSON.stringify(val));
1329        };
1330        function parse(str) {
1331            str = String(str);
1332            if (str.length > 100) {
1333                return;
1334            }
1335            var match = /^(-?(?:\\d+)?\\.?\\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(str);
1336            if (!match) {
1337                return;
1338            }
1339            var n = parseFloat(match[1]);
1340            var type = (match[2] || "ms").toLowerCase();
1341            switch (type) {
1342              case "years":
1343              case "year":
1344              case "yrs":
1345              case "yr":
1346              case "y":
1347                return n * y;
1348
1349              case "weeks":
1350              case "week":
1351              case "w":
1352                return n * w;
1353
1354              case "days":
1355              case "day":
1356              case "d":
1357                return n * d;
1358
1359              case "hours":
1360              case "hour":
1361              case "hrs":
1362              case "hr":
1363              case "h":
1364                return n * h;
1365
1366              case "minutes":
1367              case "minute":
1368              case "mins":
1369              case "min":
1370              case "m":
1371                return n * m;
1372
1373              case "seconds":
1374              case "second":
1375              case "secs":
1376              case "sec":
1377              case "s":
1378                return n * s;
1379
1380              case "milliseconds":
1381              case "millisecond":
1382              case "msecs":
1383              case "msec":
1384              case "ms":
1385                return n;
1386
1387              default:
1388                return undefined;
1389            }
1390        }
1391        function fmtShort(ms) {
1392            var msAbs = Math.abs(ms);
1393            if (msAbs >= d) {
1394                return Math.round(ms / d) + "d";
1395            }
1396            if (msAbs >= h) {
1397                return Math.round(ms / h) + "h";
1398            }
1399            if (msAbs >= m) {
1400                return Math.round(ms / m) + "m";
1401            }
1402            if (msAbs >= s) {
1403                return Math.round(ms / s) + "s";
1404            }
1405            return ms + "ms";
1406        }
1407        function fmtLong(ms) {
1408            var msAbs = Math.abs(ms);
1409            if (msAbs >= d) {
1410                return plural(ms, msAbs, d, "day");
1411            }
1412            if (msAbs >= h) {
1413                return plural(ms, msAbs, h, "hour");
1414            }
1415            if (msAbs >= m) {
1416                return plural(ms, msAbs, m, "minute");
1417            }
1418            if (msAbs >= s) {
1419                return plural(ms, msAbs, s, "second");
1420            }
1421            return ms + " ms";
1422        }
1423        function plural(ms, msAbs, n, name) {
1424            var isPlural = msAbs >= n * 1.5;
1425            return Math.round(ms / n) + " " + name + (isPlural ? "s" : "");
1426        }
1427    }
1428};
1429
1430var __webpack_module_cache__ = {};
1431
1432function __webpack_require__(moduleId) {
1433    var cachedModule = __webpack_module_cache__[moduleId];
1434    if (cachedModule !== undefined) {
1435        return cachedModule.exports;
1436    }
1437    var module = __webpack_module_cache__[moduleId] = {
1438        exports: {}
1439    };
1440    __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
1441    return module.exports;
1442}
1443
1444(() => {
1445    __webpack_require__.n = module => {
1446        var getter = module && module.__esModule ? () => module["default"] : () => module;
1447        __webpack_require__.d(getter, {
1448            a: getter
1449        });
1450        return getter;
1451    };
1452})();
1453
1454(() => {
1455    __webpack_require__.d = (exports, definition) => {
1456        for (var key in definition) {
1457            if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
1458                Object.defineProperty(exports, key, {
1459                    enumerable: true,
1460                    get: definition[key]
1461                });
1462            }
1463        }
1464    };
1465})();
1466
1467(() => {
1468    __webpack_require__.o = (obj, prop) => Object.prototype.hasOwnProperty.call(obj, prop);
1469})();
1470
1471var __webpack_exports__ = {};
1472
1473(() => {
1474    const proxyMarker = Symbol("Comlink.proxy");
1475    const createEndpoint = Symbol("Comlink.endpoint");
1476    const releaseProxy = Symbol("Comlink.releaseProxy");
1477    const finalizer = Symbol("Comlink.finalizer");
1478    const throwMarker = Symbol("Comlink.thrown");
1479    const isObject = val => typeof val === "object" && val !== null || typeof val === "function";
1480    const proxyTransferHandler = {
1481        canHandle: val => isObject(val) && val[proxyMarker],
1482        serialize(obj) {
1483            const {port1, port2} = new MessageChannel;
1484            expose(obj, port1);
1485            return [ port2, [ port2 ] ];
1486        },
1487        deserialize(port) {
1488            port.start();
1489            return comlink_wrap(port);
1490        }
1491    };
1492    const throwTransferHandler = {
1493        canHandle: value => isObject(value) && throwMarker in value,
1494        serialize({value}) {
1495            let serialized;
1496            if (value instanceof Error) {
1497                serialized = {
1498                    isError: true,
1499                    value: {
1500                        message: value.message,
1501                        name: value.name,
1502                        stack: value.stack
1503                    }
1504                };
1505            } else {
1506                serialized = {
1507                    isError: false,
1508                    value
1509                };
1510            }
1511            return [ serialized, [] ];
1512        },
1513        deserialize(serialized) {
1514            if (serialized.isError) {
1515                throw Object.assign(new Error(serialized.value.message), serialized.value);
1516            }
1517            throw serialized.value;
1518        }
1519    };
1520    const transferHandlers = new Map([ [ "proxy", proxyTransferHandler ], [ "throw", throwTransferHandler ] ]);
1521    function isAllowedOrigin(allowedOrigins, origin) {
1522        for (const allowedOrigin of allowedOrigins) {
1523            if (origin === allowedOrigin || allowedOrigin === "*") {
1524                return true;
1525            }
1526            if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {
1527                return true;
1528            }
1529        }
1530        return false;
1531    }
1532    function expose(obj, ep = globalThis, allowedOrigins = [ "*" ]) {
1533        ep.addEventListener("message", (function callback(ev) {
1534            if (!ev || !ev.data) {
1535                return;
1536            }
1537            if (!isAllowedOrigin(allowedOrigins, ev.origin)) {
1538                console.warn(\`Invalid origin '\${ev.origin}' for comlink proxy\`);
1539                return;
1540            }
1541            const {id, type, path} = Object.assign({
1542                path: []
1543            }, ev.data);
1544            const argumentList = (ev.data.argumentList || []).map(fromWireValue);
1545            let returnValue;
1546            try {
1547                const parent = path.slice(0, -1).reduce(((obj, prop) => obj[prop]), obj);
1548                const rawValue = path.reduce(((obj, prop) => obj[prop]), obj);
1549                switch (type) {
1550                  case "GET":
1551                    {
1552                        returnValue = rawValue;
1553                    }
1554                    break;
1555
1556                  case "SET":
1557                    {
1558                        parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);
1559                        returnValue = true;
1560                    }
1561                    break;
1562
1563                  case "APPLY":
1564                    {
1565                        returnValue = rawValue.apply(parent, argumentList);
1566                    }
1567                    break;
1568
1569                  case "CONSTRUCT":
1570                    {
1571                        const value = new rawValue(...argumentList);
1572                        returnValue = proxy(value);
1573                    }
1574                    break;
1575
1576                  case "ENDPOINT":
1577                    {
1578                        const {port1, port2} = new MessageChannel;
1579                        expose(obj, port2);
1580                        returnValue = transfer(port1, [ port1 ]);
1581                    }
1582                    break;
1583
1584                  case "RELEASE":
1585                    {
1586                        returnValue = undefined;
1587                    }
1588                    break;
1589
1590                  default:
1591                    return;
1592                }
1593            } catch (value) {
1594                returnValue = {
1595                    value,
1596                    [throwMarker]: 0
1597                };
1598            }
1599            Promise.resolve(returnValue).catch((value => ({
1600                value,
1601                [throwMarker]: 0
1602            }))).then((returnValue => {
1603                const [wireValue, transferables] = toWireValue(returnValue);
1604                ep.postMessage(Object.assign(Object.assign({}, wireValue), {
1605                    id
1606                }), transferables);
1607                if (type === "RELEASE") {
1608                    ep.removeEventListener("message", callback);
1609                    closeEndPoint(ep);
1610                    if (finalizer in obj && typeof obj[finalizer] === "function") {
1611                        obj[finalizer]();
1612                    }
1613                }
1614            })).catch((error => {
1615                const [wireValue, transferables] = toWireValue({
1616                    value: new TypeError("Unserializable return value"),
1617                    [throwMarker]: 0
1618                });
1619                ep.postMessage(Object.assign(Object.assign({}, wireValue), {
1620                    id
1621                }), transferables);
1622            }));
1623        }));
1624        if (ep.start) {
1625            ep.start();
1626        }
1627    }
1628    function isMessagePort(endpoint) {
1629        return endpoint.constructor.name === "MessagePort";
1630    }
1631    function closeEndPoint(endpoint) {
1632        if (isMessagePort(endpoint)) endpoint.close();
1633    }
1634    function comlink_wrap(ep, target) {
1635        return createProxy(ep, [], target);
1636    }
1637    function throwIfProxyReleased(isReleased) {
1638        if (isReleased) {
1639            throw new Error("Proxy has been released and is not useable");
1640        }
1641    }
1642    function releaseEndpoint(ep) {
1643        return requestResponseMessage(ep, {
1644            type: "RELEASE"
1645        }).then((() => {
1646            closeEndPoint(ep);
1647        }));
1648    }
1649    const proxyCounter = new WeakMap;
1650    const proxyFinalizers = "FinalizationRegistry" in globalThis && new FinalizationRegistry((ep => {
1651        const newCount = (proxyCounter.get(ep) || 0) - 1;
1652        proxyCounter.set(ep, newCount);
1653        if (newCount === 0) {
1654            releaseEndpoint(ep);
1655        }
1656    }));
1657    function registerProxy(proxy, ep) {
1658        const newCount = (proxyCounter.get(ep) || 0) + 1;
1659        proxyCounter.set(ep, newCount);
1660        if (proxyFinalizers) {
1661            proxyFinalizers.register(proxy, ep, proxy);
1662        }
1663    }
1664    function unregisterProxy(proxy) {
1665        if (proxyFinalizers) {
1666            proxyFinalizers.unregister(proxy);
1667        }
1668    }
1669    function createProxy(ep, path = [], target = function() {}) {
1670        let isProxyReleased = false;
1671        const proxy = new Proxy(target, {
1672            get(_target, prop) {
1673                throwIfProxyReleased(isProxyReleased);
1674                if (prop === releaseProxy) {
1675                    return () => {
1676                        unregisterProxy(proxy);
1677                        releaseEndpoint(ep);
1678                        isProxyReleased = true;
1679                    };
1680                }
1681                if (prop === "then") {
1682                    if (path.length === 0) {
1683                        return {
1684                            then: () => proxy
1685                        };
1686                    }
1687                    const r = requestResponseMessage(ep, {
1688                        type: "GET",
1689                        path: path.map((p => p.toString()))
1690                    }).then(fromWireValue);
1691                    return r.then.bind(r);
1692                }
1693                return createProxy(ep, [ ...path, prop ]);
1694            },
1695            set(_target, prop, rawValue) {
1696                throwIfProxyReleased(isProxyReleased);
1697                const [value, transferables] = toWireValue(rawValue);
1698                return requestResponseMessage(ep, {
1699                    type: "SET",
1700                    path: [ ...path, prop ].map((p => p.toString())),
1701                    value
1702                }, transferables).then(fromWireValue);
1703            },
1704            apply(_target, _thisArg, rawArgumentList) {
1705                throwIfProxyReleased(isProxyReleased);
1706                const last = path[path.length - 1];
1707                if (last === createEndpoint) {
1708                    return requestResponseMessage(ep, {
1709                        type: "ENDPOINT"
1710                    }).then(fromWireValue);
1711                }
1712                if (last === "bind") {
1713                    return createProxy(ep, path.slice(0, -1));
1714                }
1715                const [argumentList, transferables] = processArguments(rawArgumentList);
1716                return requestResponseMessage(ep, {
1717                    type: "APPLY",
1718                    path: path.map((p => p.toString())),
1719                    argumentList
1720                }, transferables).then(fromWireValue);
1721            },
1722            construct(_target, rawArgumentList) {
1723                throwIfProxyReleased(isProxyReleased);
1724                const [argumentList, transferables] = processArguments(rawArgumentList);
1725                return requestResponseMessage(ep, {
1726                    type: "CONSTRUCT",
1727                    path: path.map((p => p.toString())),
1728                    argumentList
1729                }, transferables).then(fromWireValue);
1730            }
1731        });
1732        registerProxy(proxy, ep);
1733        return proxy;
1734    }
1735    function myFlat(arr) {
1736        return Array.prototype.concat.apply([], arr);
1737    }
1738    function processArguments(argumentList) {
1739        const processed = argumentList.map(toWireValue);
1740        return [ processed.map((v =>
1740 v[0])), myFlat(processed.map((v => v[1]))) ];
1741    }
1742    const transferCache = new WeakMap;
1743    function transfer(obj, transfers) {
1744        transferCache.set(obj, transfers);
1745        return obj;
1746    }
1747    function proxy(obj) {
1748        return Object.assign(obj, {
1749            [proxyMarker]: true
1750        });
1751    }
1752    function windowEndpoint(w, context = globalThis, targetOrigin = "*") {
1753        return {
1754            postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),
1755            addEventListener: context.addEventListener.bind(context),
1756            removeEventListener: context.removeEventListener.bind(context)
1757        };
1758    }
1759    function toWireValue(value) {
1760        for (const [name, handler] of transferHandlers) {
1761            if (handler.canHandle(value)) {
1762                const [serializedValue, transferables] = handler.serialize(value);
1763                return [ {
1764                    type: "HANDLER",
1765                    name,
1766                    value: serializedValue
1767                }, transferables ];
1768            }
1769        }
1770        return [ {
1771            type: "RAW",
1772            value
1773        }, transferCache.get(value) || [] ];
1774    }
1775    function fromWireValue(value) {
1776        switch (value.type) {
1777          case "HANDLER":
1778            return transferHandlers.get(value.name).deserialize(value.value);
1779
1780          case "RAW":
1781            return value.value;
1782        }
1783    }
1784    function requestResponseMessage(ep, msg, transfers) {
1785        return new Promise((resolve => {
1786            const id = generateUUID();
1787            ep.addEventListener("message", (function l(ev) {
1788                if (!ev.data || !ev.data.id || ev.data.id !== id) {
1789                    return;
1790                }
1791                ep.removeEventListener("message", l);
1792                resolve(ev.data);
1793            }));
1794            if (ep.start) {
1795                ep.start();
1796            }
1797            ep.postMessage(Object.assign({
1798                id
1799            }, msg), transfers);
1800        }));
1801    }
1802    function generateUUID() {
1803        return new Array(4).fill(0).map((() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))).join("-");
1804    }
1805    function getSharedMemoryAvailable() {
1806        const globalScope = typeof window !== "undefined" ? window : globalThis;
1807        return typeof SharedArrayBuffer !== "undefined" && globalScope.crossOriginIsolated;
1808    }
1809    function getRemoteBarretenbergWasm(worker) {
1810        return wrap(worker);
1811    }
1812    function getNumCpu() {
1813        return navigator.hardwareConcurrency;
1814    }
1815    function threadLogger() {
1816        return undefined;
1817    }
1818    function killSelf() {
1819        self.close();
1820    }
1821    var browser = __webpack_require__(227);
1822    var browser_default = __webpack_require__.n(browser);
1823    const randomBytes = len => {
1824        const getWebCrypto = () => {
1825            if (typeof window !== "undefined" && window.crypto) return window.crypto;
1826            if (typeof globalThis !== "undefined" && globalThis.crypto) return globalThis.crypto;
1827            return undefined;
1828        };
1829        const crypto = getWebCrypto();
1830        if (!crypto) {
1831            throw new Error("randomBytes UnsupportedEnvironment");
1832        }
1833        const buf = new Uint8Array(len);
1834        const MAX_BYTES = 65536;
1835        if (len > MAX_BYTES) {
1836            for (let generated = 0; generated < len; generated += MAX_BYTES) {
1837                crypto.getRandomValues(buf.subarray(generated, generated + MAX_BYTES));
1838            }
1839        } else {
1840            crypto.getRandomValues(buf);
1841        }
1842        return buf;
1843    };
1844    class BarretenbergWasmBase {
1845        constructor() {
1846            this.memStore = {};
1847            this.logger = browser_default()("bb.js:bb_wasm_base");
1848        }
1849        getImportObj(memory) {
1850            const importObj = {
1851                wasi_snapshot_preview1: {
1852                    random_get: (out, length) => {
1853                        out = out >>> 0;
1854                        const randomData = randomBytes(length);
1855                        const mem = this.getMemory();
1856                        mem.set(randomData, out);
1857                    },
1858                    clock_time_get: (a1, a2, out) => {
1859                        out = out >>> 0;
1860                        const ts = BigInt((new Date).getTime()) * 1000000n;
1861                        const view = new DataView(this.getMemory().buffer);
1862                        view.setBigUint64(out, ts, true);
1863                    },
1864                    proc_exit: () => {
1865                        this.logger("PANIC: proc_exit was called.");
1866                        throw new Error;
1867                    }
1868                },
1869                env: {
1870                    logstr: addr => {
1871                        const str = this.stringFromAddress(addr);
1872                        const m = this.getMemory();
1873                        const str2 = \`\${str} (mem: \${(m.length / (1024 * 1024)).toFixed(2)}MiB)\`;
1874                        this.logger(str2);
1875                    },
1876                    get_data: (keyAddr, outBufAddr) => {
1877                        const key = this.stringFromAddress(keyAddr);
1878                        outBufAddr = outBufAddr >>> 0;
1879                        const data = this.memStore[key];
1880                        if (!data) {
1881                            this.logger(\`get_data miss \${key}\`);
1882                            return;
1883                        }
1884                        this.writeMemory(outBufAddr, data);
1885                    },
1886                    set_data: (keyAddr, dataAddr, dataLength) => {
1887                        const key = this.stringFromAddress(keyAddr);
1888                        dataAddr = dataAddr >>> 0;
1889                        this.memStore[key] = this.getMemorySlice(dataAddr, dataAddr + dataLength);
1890                    },
1891                    memory
1892                }
1893            };
1894            return importObj;
1895        }
1896        exports() {
1897            return this.instance.exports;
1898        }
1899        call(name, ...args) {
1900            if (!this.exports()[name]) {
1901                throw new Error(\`WASM function \${name} not found.\`);
1902            }
1903            try {
1904                return this.exports()[name](...args) >>> 0;
1905            } catch (err) {
1906                const message = \`WASM function \${name} aborted, error: \${err}\`;
1907                this.logger(message);
1908                this.logger(err.stack);
1909                throw err;
1910            }
1911        }
1912        memSize() {
1913            return this.getMemory().length;
1914        }
1915        getMemorySlice(start, end) {
1916            return this.getMemory().subarray(start, end).slice();
1917        }
1918        writeMemory(offset, arr) {
1919            const mem = this.getMemory();
1920            mem.set(arr, offset);
1921        }
1922        getMemory() {
1923            return new Uint8Array(this.memory.buffer);
1924        }
1925        stringFromAddress(addr) {
1926            addr = addr >>> 0;
1927            const m = this.getMemory();
1928            let i = addr;
1929            for (;m[i] !== 0; ++i) ;
1930            const textDecoder = new TextDecoder("ascii");
1931            return textDecoder.decode(m.slice(addr, i));
1932        }
1933    }
1934    class BarretenbergWasmThread extends BarretenbergWasmBase {
1935        async initThread(module, memory) {
1936            this.logger = threadLogger() || this.logger;
1937            this.memory = memory;
1938            this.instance = await WebAssembly.instantiate(module, this.getImportObj(this.memory));
1939        }
1940        destroy() {
1941            killSelf();
1942        }
1943        getImportObj(memory) {
1944            const baseImports = super.getImportObj(memory);
1945            return {
1946                ...baseImports,
1947                wasi: {
1948                    "thread-spawn": () => {
1949                        this.logger("PANIC: threads cannot spawn threads!");
1950                        this.logger((new Error).stack);
1951                        killSelf();
1952                    }
1953                },
1954                env: {
1955                    ...baseImports.env,
1956                    env_hardware_concurrency: () => 1
1957                }
1958            };
1959        }
1960    }
1961    self.onmessage = function(e) {
1962        if (e.data.debug) {
1963            browser_default().enable(e.data.debug);
1964        }
1965    };
1966    expose(new BarretenbergWasmThread);
1967    self.postMessage({
1968        ready: true
1969    });
1970    const thread_worker = null;
1971})();`,"Worker",void 0,void 0)}function Dt(){const b=new Lt,E=wt().disable();return wt().enable(E),b.postMessage({debug:E}),b}class et{constructor(){this.memStore={},this.logger=wt()("bb.js:bb_wasm_base")}getImportObj(E){return{wasi_snapshot_preview1:{random_get:(y,D)=>{y=y>>>0;const U=ge(D);this.getMemory().set(U,y)},clock_time_get:(y,D,U)=>{U=U>>>0;const $=BigInt(new Date().getTime())*1000000n;new DataView(this.getMemory().buffer).setBigUint64(U,$,!0)},proc_exit:()=>{throw this.logger("PANIC: proc_exit was called."),new Error}},env:{logstr:y=>{const D=this.stringFromAddress(y),U=this.getMemory(),$=`${D} (mem: ${(U.length/(1024*1024)).toFixed(2)}MiB)`;this.logger($)},get_data:(y,D)=>{const U=this.stringFromAddress(y);D=D>>>0;const $=this.memStore[U];if(!$){this.logger(`get_data miss ${U}`);return}this.writeMemory(D,$)},set_data:(y,D,U)=>{const $=this.stringFromAddress(y);D=D>>>0,this.memStore[$]=this.getMemorySlice(D,D+U)},memory:E}}}exports(){return this.instance.exports}call(E,...y){if(!this.exports()[E])throw new Error(`WASM function ${E} not found.`);try{return this.exports()[E](...y)>>>0}catch(D){const U=`WASM function ${E} aborted, error: ${D}`;throw this.logger(U),this.logger(D.stack),D}}memSize(){return this.getMemory().length}getMemorySlice(E,y){return this.getMemory().subarray(E,y).slice()}writeMemory(E,y){this.getMemory().set(y,E)}getMemory(){return new Uint8Array(this.memory.buffer)}stringFromAddress(E){E=E>>>0;const y=this.getMemory();let D=E;for(;y[D]!==0;++D);return new TextDecoder("ascii").decode(y.slice(E,D))}}class Rt{constructor(E){this.wasm=E,this.allocs=[],this.inScratchRemaining=1024,this.outScratchRemaining=1024}getInputs(E){return E.map(y=>{if(typeof y=="object")if(y.length<=this.inScratchRemaining){const D=this.inScratchRemaining-=y.length;return this.wasm.writeMemory(D,y),D}else{const D=this.wasm.call("bbmalloc",y.length);return this.wasm.writeMemory(D,y),this.allocs.push(D),D}else return y})}getOutputPtrs(E){return E.map(y=>{const D=y||4;if(D<=this.outScratchRemaining)return this.outScratchRemaining-=D;{const U=this.wasm.call("bbmalloc",D);return this.allocs.push(U),U}})}addOutputPtr(E){E>=1024&&this.allocs.push(E)}freeAll(){for(const E of this.allocs)this.wasm.call("bbfree",E)}}class Mt extends et{constructor(){super(...arguments),this.workers=[],this.remoteWasms=[],this.nextWorker=0,this.nextThreadI
1971d=1}getNumThreads(){return this.workers.length+1}async init(E,y=Math.min(Qe(),Mt.MAX_THREADS),D=wt()("bb.js:bb_wasm"),U=32,$=65536){this.logger=D;const oe=U*2**16/(1024*1024),de=$*2**16/(1024*1024),Re=Et();this.logger(`Initializing bb wasm: initial memory ${U} pages ${oe}MiB; max memory: ${$} pages, ${de}MiB; threads: ${y}; shared memory: ${Re}`),this.memory=new WebAssembly.Memory({initial:U,maximum:$,shared:Re});const ye=await WebAssembly.instantiate(E,this.getImportObj(this.memory));this.instance=ye,this.call("_initialize"),y>1&&(this.logger(`Creating ${y} worker threads`),this.workers=await Promise.all(Array.from({length:y-1}).map(Dt)),this.remoteWasms=await Promise.all(this.workers.map(Bt)),await Promise.all(this.remoteWasms.map(Ee=>Ee.initThread(E,this.memory))))}async destroy(){await Promise.all(this.workers.map(E=>E.terminate()))}getImportObj(E){const y=super.getImportObj(E);return{...y,wasi:{"thread-spawn":D=>{D=D>>>0;const U=this.nextThreadId++,$=this.nextWorker++%this.remoteWasms.length;return this.remoteWasms[$].call("wasi_thread_start",U,D).catch(this.logger),U}},env:{...y.env,env_hardware_concurrency:()=>this.remoteWasms.length+1}}}callWasmExport(E,y,D){const U=new Rt(this),$=U.getInputs(y),oe=U.getOutputPtrs(D);this.call(E,...$,...oe);const de=this.getOutputArgs(D,oe,U);return U.freeAll(),de}getOutputArgs(E,y,D){return E.map((U,$)=>{if(U)return this.getMemorySlice(y[$],y[$]+U);const oe=this.getMemorySlice(y[$],y[$]+4),de=new DataView(oe.buffer,oe.byteOffset,oe.byteLength).getUint32(0,!0);D.addOutputPtr(de);const Re=this.getMemorySlice(de,de+4),ye=new DataView(Re.buffer,Re.byteOffset,Re.byteLength).getUint32(0,!1);return this.getMemorySlice(de+4,de+4+ye)})}}Mt.MAX_THREADS=32;const Ye=4,Nt=0,Ft=1,tt=2;function At(b){let E=b.length;for(;--E>=0;)b[E]=0}const It=0,xt=1,oi=2,li=3,ci=258,Rn=29,Sn=256,zr=Sn+1+Rn,mn=30,Nn=19,Kn=2*zr+1,sn=15,Fn=16,Tn=7,Pn=256,Gn=16,Zr=17,Yn=18,zn=new Uint8Array([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]),Ua=new Uint8Array([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]),Do=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),S2=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),fE=512,qa=new Array((zr+2)*2);At(qa);const sd=new Array(mn*2);At(sd);const Uo=new Array(fE);At(Uo);const vf=new Array(ci-li+1);At(vf);const Op=new Array(Rn);At(Op);const Bp=new Array(mn);At(Bp);function v1(b,E,y,D,U){this.static_tree=b,this.extra_bits=E,this.extra_base=y,this.elems=D,this.max_length=U,this.has_stree=b&&b.length}let k2,E2,w1;function x1(b,E){this.dyn_tree=b,this.max_code=0,this.stat_desc=E}const M2=b=>b<256?Uo[b]:Uo[256+(b>>>7)],wf=(b,E)=>{b.pending_buf[b.pending++]=E&255,b.pending_buf[b.pending++]=E>>>8&255},ui=(b,E,y)=>{b.bi_valid>Fn-y?(b.bi_buf|=E<<b.bi_valid&65535,wf(b,b.bi_buf),b.bi_buf=E>>Fn-b.bi_valid,b.bi_valid+=y-Fn):(b.bi_buf|=E<<b.bi_valid&65535,b.bi_valid+=y)},Ni=(b,E,y)=>{ui(b,y[E*2],y[E*2+1])},A2=(b,E)=>{let y=0;do y|=b&1,b>>>=1,y<<=1;while(--E>0);return y>>>1},hE=b=>{b.bi_valid===16?(wf(b,b.bi_buf),b.bi_buf=0,b.bi_valid=0):b.bi_valid>=8&&(b.pending_buf[b.pending++]=b.bi_buf&255,b.bi_buf>>=8,b.bi_valid-=8)},Dl=(b,E)=>{const y=E.dyn_tree,D=E.max_code,U=E.stat_desc.static_tree,$=E.stat_desc.has_stree,oe=E.stat_desc.extra_bits,de=E.stat_desc.extra_base,Re=E.stat_desc.max_length;let ye,Ee,at,Pe,Le,Br,Lr=0;for(Pe=0;Pe<=sn;Pe++)b.bl_count[Pe]=0;for(y[b.heap[b.heap_max]*2+1]=0,ye=b.heap_max+1;ye<Kn;ye++)Ee=b.heap[ye],Pe=y[y[Ee*2+1]*2+1]+1,Pe>Re&&(Pe=Re,Lr++),y[Ee*2+1]=Pe,!(Ee>D)&&(b.bl_count[Pe]++,Le=0,Ee>=de&&(Le=oe[Ee-de]),Br=y[Ee*2],b.opt_len+=Br*(Pe+Le),$&&(b.static_len+=Br*(U[Ee*2+1]+Le)));if(Lr!==0){do{for(Pe=Re-1;b.bl_count[Pe]===0;)Pe--;b.bl_count[Pe]--,b.bl_count[Pe+1]+=2,b.bl_count[Re]--,Lr-=2}while(Lr>0);for(Pe=Re;Pe!==0;Pe--)for(Ee=b.bl_count[Pe];Ee!==0;)at=b.heap[--ye],!(at>D)&&(y[at*2+1]!==Pe&&(b.opt_len+=(Pe-y[at*2+1])*y[at*2],y[at*2+1]=Pe),Ee--)}},C2=(b,E,y)=>{const D=new Array(sn+1);let U=0,$,oe;for($=1;$<=sn;$++)U=U+y[$-1]<<1,D[$]=U;for(oe=0;oe<=E;oe++){let de=b[oe*2+1];de!==0&&(b[oe*2]=A2(D[de]++,de))}},dE=()=>{let b,E,y,D,U;const $=new Array(sn+1);for(y=0,D=0;D<Rn-1;D++)for(Op[D]=y,b=0;b<1<<zn[D];b++)vf[y++]=D;for(vf[y-1]=D,U=0,D=0;D<16;D++)for(Bp[D]=U,b=0;b<1<<Ua[D];b++)Uo[U++]=D;for(U>>=7;D<mn;D++)for(Bp[D]=U<<7,b=0;b<1<<Ua[D]-7;b++)Uo[256+U++]=D;for(E=0;E<=sn;E++)$[E]=0;for(b=0;b<=143;)qa[b*2+1]=8,b++,$[8]++;for(;b<=255;)qa[b*2+1]=9,b++,$[9]++;for(;b<=279;)qa[b*2+1]=7,b++,$[7]++;for(;b<=287;)qa[b*2+1]=8,b++,$[8]++;for(C2(qa,zr+1,$),b=0;b<mn;b++)sd[b*2+1]=5,sd[b*2]=A2(b,5);
vendor: 2,979 bytes, line 1971
1971k2=new v1(qa,zn,Sn+1,zr,sn),E2=new v1(sd,Ua,0,mn,sn),w1=new v1(new Array(0),Do,0,Nn,Tn)},T2=b=>{let E;for(E=0;E<zr;E++)b.dyn_ltree[E*2]=0;for(E=0;E<mn;E++)b.dyn_dtree[E*2]=0;for(E=0;E<Nn;E++)b.bl_tree[E*2]=0;b.dyn_ltree[Pn*2]=1,b.opt_len=b.static_len=0,b.sym_next=b.matches=0},j2=b=>{b.bi_valid>8?wf(b,b.bi_buf):b.bi_valid>0&&(b.pending_buf[b.pending++]=b.bi_buf),b.bi_buf=0,b.bi_valid=0},I2=(b,E,y,D)=>{const U=E*2,$=y*2;return b[U]<b[$]||b[U]===b[$]&&D[E]<=D[y]},qo=(b,E,y)=>{const D=b.heap[y];let U=y<<1;for(;U<=b.heap_len&&(U<b.heap_len&&I2(E,b.heap[U+1],b.heap[U],b.depth)&&U++,!I2(E,D,b.heap[U],b.depth));)b.heap[y]=b.heap[U],y=U,U<<=1;b.heap[y]=D},_1=(b,E,y)=>{let D,U,$=0,oe,de;if(b.sym_next!==0)do D=b.pending_buf[b.sym_buf+$++]&255,D+=(b.pending_buf[b.sym_buf+$++]&255)<<8,U=b.pending_buf[b.sym_buf+$++],D===0?Ni(b,U,E):(oe=vf[U],Ni(b,oe+Sn+1,E),de=zn[oe],de!==0&&(U-=Op[oe],ui(b,U,de)),D--,oe=M2(D),Ni(b,oe,y),de=Ua[oe],de!==0&&(D-=Bp[oe],ui(b,D,de)));while($<b.sym_next);Ni(b,Pn,E)},S1=(b,E)=>{const y=E.dyn_tree,D=E.stat_desc.static_tree,U=E.stat_desc.has_stree,$=E.stat_desc.elems;let oe,de,Re=-1,ye;for(b.heap_len=0,b.heap_max=Kn,oe=0;oe<$;oe++)y[oe*2]!==0?(b.heap[++b.heap_len]=Re=oe,b.depth[oe]=0):y[oe*2+1]=0;for(;b.heap_len<2;)ye=b.heap[++b.heap_len]=Re<2?++Re:0,y[ye*2]=1,b.depth[ye]=0,b.opt_len--,U&&(b.static_len-=D[ye*2+1]);for(E.max_code=Re,oe=b.heap_len>>1;oe>=1;oe--)qo(b,y,oe);ye=$;do oe=b.heap[1],b.heap[1]=b.heap[b.heap_len--],qo(b,y,1),de=b.heap[1],b.heap[--b.heap_max]=oe,b.heap[--b.heap_max]=de,y[ye*2]=y[oe*2]+y[de*2],b.depth[ye]=(b.depth[oe]>=b.depth[de]?b.depth[oe]:b.depth[de])+1,y[oe*2+1]=y[de*2+1]=ye,b.heap[1]=ye++,qo(b,y,1);while(b.heap_len>=2);b.heap[--b.heap_max]=b.heap[1],Dl(b,E),C2(y,Re,b.bl_count)},od=(b,E,y)=>{let D,U=-1,$,oe=E[0*2+1],de=0,Re=7,ye=4;for(oe===0&&(Re=138,ye=3),E[(y+1)*2+1]=65535,D=0;D<=y;D++)$=oe,oe=E[(D+1)*2+1],!(++de<Re&&$===oe)&&(de<ye?b.bl_tree[$*2]+=de:$!==0?($!==U&&b.bl_tree[$*2]++,b.bl_tree[Gn*2]++):de<=10?b.bl_tree[Zr*2]++:b.bl_tree[Yn*2]++,de=0,U=$,oe===0?(Re=138,ye=3):$===oe?(Re=6,ye=3):(Re=7,ye=4))},O2=(b,E,y)=>{let D,U=-1,$,oe=E[0*2+1],de=0,Re=7,ye=4;for(oe===0&&(Re=138,ye=3),D=0;D<=y;D++)if($=oe,oe=E[(D+1)*2+1],!(++de<Re&&$===oe)){if(de<ye)do Ni(b,$,b.bl_tree);while(--de!==0);else $!==0?($!==U&&(Ni(b,$,b.bl_tree),de--),Ni(b,Gn,b.bl_tree),ui(b,de-3,2)):de<=10?(Ni(b,Zr,b.bl_tree),ui(b,de-3,3)):(Ni(b,Yn,b.bl_tree),ui(b,de-11,7));de=0,U=$,oe===0?(Re=138,ye=3):$===oe?(Re=6,ye=3):(Re=7,ye=4)}},k1=b=>{let E;for(od(b,b.dyn_ltree,b.l_desc.max_code),od(b,b.dyn_dtree,b.d_desc.max_code),S1(b,b.bl_desc),E=Nn-1;E>=3&&b.bl_tree[S2[E]*2+1]===0;E--);return b.opt_len+=3*(E+1)+5+5+4,E},pE=(b,E,y,D)=>{let U;for(ui(b,E-257,5),ui(b,y-1,5),ui(b,D-4,4),U=0;U<D;U++)ui(b,b.bl_tree[S2[U]*2+1],3);O2(b,b.dyn_ltree,E-1),O2(b,b.dyn_dtree,y-1)},B2=b=>{let E=4093624447,y;for(y=0;y<=31;y++,E>>>=1)if(E&1&&b.dyn_ltree[y*2]!==0)return Nt;if(b.dyn_ltree[9*2]!==0||b.dyn_ltree[10*2]!==0||b.dyn_ltree[13*2]!==0)return Ft;
vendor: 5,128 bytes, line 1971
1971for(y=32;y<Sn;y++)if(b.dyn_ltree[y*2]!==0)return Ft;return Nt};let E1=!1;const R2=b=>{E1||(dE(),E1=!0),b.l_desc=new x1(b.dyn_ltree,k2),b.d_desc=new x1(b.dyn_dtree,E2),b.bl_desc=new x1(b.bl_tree,w1),b.bi_buf=0,b.bi_valid=0,T2(b)},xf=(b,E,y,D)=>{ui(b,(It<<1)+(D?1:0),3),j2(b),wf(b,y),wf(b,~y),y&&b.pending_buf.set(b.window.subarray(E,E+y),b.pending),b.pending+=y},N2=b=>{ui(b,xt<<1,3),Ni(b,Pn,qa),hE(b)},mE=(b,E,y,D)=>{let U,$,oe=0;b.level>0?(b.strm.data_type===tt&&(b.strm.data_type=B2(b)),S1(b,b.l_desc),S1(b,b.d_desc),oe=k1(b),U=b.opt_len+3+7>>>3,$=b.static_len+3+7>>>3,$<=U&&(U=$)):U=$=y+5,y+4<=U&&E!==-1?xf(b,E,y,D):b.strategy===Ye||$===U?(ui(b,(xt<<1)+(D?1:0),3),_1(b,qa,sd)):(ui(b,(oi<<1)+(D?1:0),3),pE(b,b.l_desc.max_code+1,b.d_desc.max_code+1,oe+1),_1(b,b.dyn_ltree,b.dyn_dtree)),T2(b),D&&j2(b)},gE=(b,E,y)=>(b.pending_buf[b.sym_buf+b.sym_next++]=E,b.pending_buf[b.sym_buf+b.sym_next++]=E>>8,b.pending_buf[b.sym_buf+b.sym_next++]=y,E===0?b.dyn_ltree[y*2]++:(b.matches++,E--,b.dyn_ltree[(vf[y]+Sn+1)*2]++,b.dyn_dtree[M2(E)*2]++),b.sym_next===b.sym_end);var bE=R2,me=xf,Me=mE,Ze=gE,pt=N2,$r={_tr_init:bE,_tr_stored_block:me,_tr_flush_block:Me,_tr_tally:Ze,_tr_align:pt},Ht=(b,E,y,D)=>{let U=b&65535|0,$=b>>>16&65535|0,oe=0;for(;y!==0;){oe=y>2e3?2e3:y,y-=oe;do U=U+E[D++]|0,$=$+U|0;while(--oe);U%=65521,$%=65521}return U|$<<16|0};const gn=()=>{let b,E=[];for(var y=0;y<256;y++){b=y;for(var D=0;D<8;D++)b=b&1?3988292384^b>>>1:b>>>1;E[y]=b}return E},Xn=new Uint32Array(gn());var br=(b,E,y,D)=>{const U=Xn,$=D+y;b^=-1;for(let oe=D;oe<$;oe++)b=b>>>8^U[(b^E[oe])&255];return b^-1},Tr={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},Ln={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8};const{_tr_init:hs,_tr_stored_block:Jn,_tr_flush_block:Va,_tr_tally:Dn,_tr_align:Ul}=$r,{Z_NO_FLUSH:ki,Z_PARTIAL_FLUSH:Zc,Z_FULL_FLUSH:F2,Z_FINISH:Fi,Z_BLOCK:ld,Z_OK:Pi,Z_STREAM_END:Nq,Z_STREAM_ERROR:ql,Z_DATA_ERROR:Qwe,Z_BUF_ERROR:yE,Z_DEFAULT_COMPRESSION:exe,Z_FILTERED:txe,Z_HUFFMAN_ONLY:P2,Z_RLE:rxe,Z_FIXED:nxe,Z_DEFAULT_STRATEGY:ixe,Z_UNKNOWN:axe,Z_DEFLATED:z2}=Ln,sxe=9,oxe=15,lxe=8,vE=286,cxe=30,uxe=19,fxe=2*vE+1,hxe=15,_r=3,_f=258,Vl=_f+_r+1,dxe=32,Rp=42,wE=57,xE=69,_E=73,SE=91,kE=103,cd=113,M1=666,ba=1,Np=2,ud=3,Fp=4,pxe=3,fd=(b,E)=>(b.msg=Tr[E],E),Fq=b=>b*2-(b>4?9:0),Sf=b=>{let E=b.length;for(;--E>=0;)b[E]=0},mxe=b=>{let E,y,D,U=b.w_size;E=b.hash_size,D=E;do y=b.head[--D],b.head[D]=y>=U?y-U:0;while(--E);E=U,D=E;do y=b.prev[--D],b.prev[D]=y>=U?y-U:0;while(--E)};let kf=(b,E,y)=>(E<<b.hash_shift^y)&b.hash_mask;const ds=b=>{const E=b.state;let y=E.pending;y>b.avail_out&&(y=b.avail_out),y!==0&&(b.output.set(E.pending_buf.subarray(E.pending_out,E.pending_out+y),b.next_out),b.next_out+=y,E.pending_out+=y,b.total_out+=y,b.avail_out-=y,E.pending-=y,E.pending===0&&(E.pending_out=0))},ps=(b,E)=>{Va(b,b.block_start>=0?b.block_start:-1,b.strstart-b.block_start,E),b.block_start=b.strstart,ds(b.strm)},jr=(b,E)=>{b.pending_buf[b.pending++]=E},A1=(b,E)=>{b.pending_buf[b.pending++]=E>>>8&255,b.pending_buf[b.pending++]=E&255},EE=(b,E,y,D)=>{let U=b.avail_in;return U>D&&(U=D),U===0?0:(b.avail_in-=U,E.set(b.input.subarray(b.next_in,b.next_in+U),y),b.state.wrap===1?b.adler=Ht(b.adler,E,U,y):b.state.wrap===2&&(b.adler=br(b.adler,E,U,y)),b.next_in+=U,b.total_in+=U,U)},Pq=(b,E)=>{let y=b.max_chain_length,D=b.strstart,U,$,oe=b.prev_length,de=b.nice_match;const Re=b.strstart>b.w_size-Vl?b.strstart-(b.w_size-Vl):0,ye=b.window,Ee=b.w_mask,at=b.prev,Pe=b.strstart+_f;let Le=ye[D+oe-1],Br=ye[D+oe];b.prev_length>=b.good_match&&(y>>=2),de>b.lookahead&&(de=b.lookahead);do if(U=E,!(ye[U+oe]!==Br||ye[U+oe-1]!==Le||ye[U]!==ye[D]||ye[++U]!==ye[D+1])){D+=2,U++;do;while(ye[++D]===ye[++U]&&ye[++D]===ye[++U]&&ye[++D]===ye[++U]&&ye[++D]===ye[++U]&&ye[++D]===ye[++U]&&ye[++D]===ye[++U]&&ye[++D]===ye[++U]&&ye[++D]===ye[++U]&&D<Pe);if($=_f-(Pe-D),D=Pe-_f,$>oe){if(b.match_start=E,oe=$,$>=de)break;Le=ye[D+oe-1],Br=ye[D+oe]}}while((E=at[E&Ee])>Re&&--y!==0);return oe<=b.lookahead?oe:b.lookahead},Pp=b=>{const E=b.w_size;let y,D,U;do{if(D=b.window_size-b.lookahead-b.strstart,b.strstart>=E+(E-Vl)&&(b.window.set(b.window.subarray(E,E+E-D),0),b.match_start-=E,b.strstart-=E,b.block_start-=E,b.insert>b.strstart&&(b.insert=b.strstart),mxe(b),D+=E),b.strm.avail_in===0)break;if(y=EE(b.strm,b.window,b.strstart+b.lookahead,D),b.lookahead+=y,b.lookahead+b.insert>=_r)for(U=b.strstart-b.insert,b.ins_h=b.window[U],b.ins_h=kf(b,b.ins_h,b.window[U+1]);b.insert&&(b.ins_h=kf(b,b.ins_h,b.window[U+_r-1]),b.prev[U&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=U,U++,b.insert--,!(b.lookahead+b.insert<_r)););}while(b.lookahead<Vl&&b.strm.avail_in!==0)},zq=(b,E)=>{let y=b.pending_buf_size-5>
vendor: 36,473 bytes, line 1971
1971b.w_size?b.w_size:b.pending_buf_size-5,D,U,$,oe=0,de=b.strm.avail_in;do{if(D=65535,$=b.bi_valid+42>>3,b.strm.avail_out<$||($=b.strm.avail_out-$,U=b.strstart-b.block_start,D>U+b.strm.avail_in&&(D=U+b.strm.avail_in),D>$&&(D=$),D<y&&(D===0&&E!==Fi||E===ki||D!==U+b.strm.avail_in)))break;oe=E===Fi&&D===U+b.strm.avail_in?1:0,Jn(b,0,0,oe),b.pending_buf[b.pending-4]=D,b.pending_buf[b.pending-3]=D>>8,b.pending_buf[b.pending-2]=~D,b.pending_buf[b.pending-1]=~D>>8,ds(b.strm),U&&(U>D&&(U=D),b.strm.output.set(b.window.subarray(b.block_start,b.block_start+U),b.strm.next_out),b.strm.next_out+=U,b.strm.avail_out-=U,b.strm.total_out+=U,b.block_start+=U,D-=U),D&&(EE(b.strm,b.strm.output,b.strm.next_out,D),b.strm.next_out+=D,b.strm.avail_out-=D,b.strm.total_out+=D)}while(oe===0);return de-=b.strm.avail_in,de&&(de>=b.w_size?(b.matches=2,b.window.set(b.strm.input.subarray(b.strm.next_in-b.w_size,b.strm.next_in),0),b.strstart=b.w_size,b.insert=b.strstart):(b.window_size-b.strstart<=de&&(b.strstart-=b.w_size,b.window.set(b.window.subarray(b.w_size,b.w_size+b.strstart),0),b.matches<2&&b.matches++,b.insert>b.strstart&&(b.insert=b.strstart)),b.window.set(b.strm.input.subarray(b.strm.next_in-de,b.strm.next_in),b.strstart),b.strstart+=de,b.insert+=de>b.w_size-b.insert?b.w_size-b.insert:de),b.block_start=b.strstart),b.high_water<b.strstart&&(b.high_water=b.strstart),oe?Fp:E!==ki&&E!==Fi&&b.strm.avail_in===0&&b.strstart===b.block_start?Np:($=b.window_size-b.strstart,b.strm.avail_in>$&&b.block_start>=b.w_size&&(b.block_start-=b.w_size,b.strstart-=b.w_size,b.window.set(b.window.subarray(b.w_size,b.w_size+b.strstart),0),b.matches<2&&b.matches++,$+=b.w_size,b.insert>b.strstart&&(b.insert=b.strstart)),$>b.strm.avail_in&&($=b.strm.avail_in),$&&(EE(b.strm,b.window,b.strstart,$),b.strstart+=$,b.insert+=$>b.w_size-b.insert?b.w_size-b.insert:$),b.high_water<b.strstart&&(b.high_water=b.strstart),$=b.bi_valid+42>>3,$=b.pending_buf_size-$>65535?65535:b.pending_buf_size-$,y=$>b.w_size?b.w_size:$,U=b.strstart-b.block_start,(U>=y||(U||E===Fi)&&E!==ki&&b.strm.avail_in===0&&U<=$)&&(D=U>$?$:U,oe=E===Fi&&b.strm.avail_in===0&&D===U?1:0,Jn(b,b.block_start,D,oe),b.block_start+=D,ds(b.strm)),oe?ud:ba)},ME=(b,E)=>{let y,D;for(;;){if(b.lookahead<Vl){if(Pp(b),b.lookahead<Vl&&E===ki)return ba;if(b.lookahead===0)break}if(y=0,b.lookahead>=_r&&(b.ins_h=kf(b,b.ins_h,b.window[b.strstart+_r-1]),y=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),y!==0&&b.strstart-y<=b.w_size-Vl&&(b.match_length=Pq(b,y)),b.match_length>=_r)if(D=Dn(b,b.strstart-b.match_start,b.match_length-_r),b.lookahead-=b.match_length,b.match_length<=b.max_lazy_match&&b.lookahead>=_r){b.match_length--;do b.strstart++,b.ins_h=kf(b,b.ins_h,b.window[b.strstart+_r-1]),y=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart;while(--b.match_length!==0);b.strstart++}else b.strstart+=b.match_length,b.match_length=0,b.ins_h=b.window[b.strstart],b.ins_h=kf(b,b.ins_h,b.window[b.strstart+1]);else D=Dn(b,0,b.window[b.strstart]),b.lookahead--,b.strstart++;if(D&&(ps(b,!1),b.strm.avail_out===0))return ba}return b.insert=b.strstart<_r-1?b.strstart:_r-1,E===Fi?(ps(b,!0),b.strm.avail_out===0?ud:Fp):b.sym_next&&(ps(b,!1),b.strm.avail_out===0)?ba:Np},zp=(b,E)=>{let y,D,U;for(;;){if(b.lookahead<Vl){if(Pp(b),b.lookahead<Vl&&E===ki)return ba;if(b.lookahead===0)break}if(y=0,b.lookahead>=_r&&(b.ins_h=kf(b,b.ins_h,b.window[b.strstart+_r-1]),y=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),b.prev_length=b.match_length,b.prev_match=b.match_start,b.match_length=_r-1,y!==0&&b.prev_length<b.max_lazy_match&&b.strstart-y<=b.w_size-Vl&&(b.match_length=Pq(b,y),b.match_length<=5&&(b.strategy===txe||b.match_length===_r&&b.strstart-b.match_start>4096)&&(b.match_length=_r-1)),b.prev_length>=_r&&b.match_length<=b.prev_length){U=b.strstart+b.lookahead-_r,D=Dn(b,b.strstart-1-b.prev_match,b.prev_length-_r),b.lookahead-=b.prev_length-1,b.prev_length-=2;do++b.strstart<=U&&(b.ins_h=kf(b,b.ins_h,b.window[b.strstart+_r-1]),y=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart);while(--b.prev_length!==0);if(b.match_available=0,b.match_length=_r-1,b.strstart++,D&&(ps(b,!1),b.strm.avail_out===0))return ba}else if(b.match_available){if(D=Dn(b,0,b.window[b.strstart-1]),D&&ps(b,!1),b.strstart++,b.lookahead--,b.strm.avail_out===0)return ba}else b.match_available=1,b.strstart++,b.lookahead--}return b.match_available&&(D=Dn(b,0,b.window[b.strstart-1]),b.match_available=0),b.insert=b.strstart<_r-1?b.strstart:_r-1,E===Fi?(ps(b,!0),b.strm.avail_out===0?ud:Fp):b.sym_next&&(ps(b,!1),b.strm.avail_out===0)?ba:Np},gxe=(b,E)=>{let y,D,U,$;const oe=b.window;for(;;){if(b.lookahead<=_f){if(Pp(b),b.lookahead<=_f&&E===ki)return ba;if(b.lookahead===0)break}if(b.match_length=0,b.lookahead>=_r&&b.strstart>0&&(U=b.strstart-1,D=oe[U],D===oe[++U]&&D===oe[++U]&&D===oe[++U])){$=b.strstart+_f;do;while(D===oe[++U]&&D===oe[++U]&&D===oe[++U]&&D===oe[++U]&&D===oe[++U]&&D===oe[++U]&&D===oe[++U]&&D===oe[++U]&&U<$);b.match_length=_f-($-U),b.match_length>b.lookahead&&(b.match_length=b.lookahead)}if(b.match_length>=_r?(y=Dn(b,1,b.match_length-_r),b.lookahead-=b.match_length,b.strstart+=b.match_length,b.match_length=0):(y=Dn(b,0,b.window[b.strstart]),b.lookahead--,b.strstart++),y&&(ps(b,!1),b.strm.avail_out===0))return ba}return b.insert=0,E===Fi?(ps(b,!0),b.strm.avail_out===0?ud:Fp):b.sym_next&&(ps(b,!1),b.strm.avail_out===0)?ba:Np},bxe=(b,E)=>{let y;for(;;){if(b.lookahead===0&&(Pp(b),b.lookahead===0)){if(E===ki)return ba;break}if(b.match_length=0,y=Dn(b,0,b.window[b.strstart]),b.lookahead--,b.strstart++,y&&(ps(b,!1),b.strm.avail_out===0))return ba}return b.insert=0,E===Fi?(ps(b,!0),b.strm.avail_out===0?ud:Fp):b.sym_next&&(ps(b,!1),b.strm.avail_out===0)?ba:Np};function Zl(b,E,y,D,U){this.good_length=b,this.max_lazy=E,this.nice_length=y,this.max_chain=D,this.func=U}const C1=[new Zl(0,0,0,0,zq),new Zl(4,4,8,4,ME),new Zl(4,5,16,8,ME),new Zl(4,6,32,32,ME),new Zl(4,4,16,16,zp),new Zl(8,16,32,32,zp),new Zl(8,16,128,128,zp),new Zl(8,32,128,256,zp),new Zl(32,128,258,1024,zp),new Zl(32,258,258,4096,zp)],yxe=b=>{b.window_size=2*b.w_size,Sf(b.head),b.max_lazy_match=C1[b.level].max_lazy,b.good_match=C1[b.level].good_length,b.nice_match=C1[b.level].nice_length,b.max_chain_length=C1[b.level].max_chain,b.strstart=0,b.block_start=0,b.lookahead=0,b.insert=0,b.match_length=b.prev_length=_r-1,b.match_available=0,b.ins_h=0};function vxe(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=z2,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new Uint16Array(fxe*2),this.dyn_dtree=new Uint16Array((2*cxe+1)*2),this.bl_tree=new Uint16Array((2*uxe+1)*2),Sf(this.dyn_ltree),Sf(this.dyn_dtree),Sf(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(hxe+1),this.heap=new Uint16Array(2*vE+1),Sf(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(2*vE+1),Sf(this.depth),this.sym_buf=0,this.lit_bufsize=0,this.sym_next=0,this.sym_end=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}const T1=b=>{if(!b)return 1;const E=b.state;return!E||E.strm!==b||E.status!==Rp&&E.status!==wE&&E.status!==xE&&E.status!==_E&&E.status!==SE&&E.status!==kE&&E.status!==cd&&E.status!==M1?1:0},Lq=b=>{if(T1(b))return fd(b,ql);b.total_in=b.total_out=0,b.data_type=axe;const E=b.state;return E.pending=0,E.pending_out=0,E.wrap<0&&(E.wrap=-E.wrap),E.status=E.wrap===2?wE:E.wrap?Rp:cd,b.adler=E.wrap===2?0:1,E.last_flush=-2,hs(E),Pi},Dq=b=>{const E=Lq(b);return E===Pi&&yxe(b.state),E},wxe=(b,E)=>T1(b)||b.state.wrap!==2?ql:(b.state.gzhead=E,Pi),Uq=(b,E,y,D,U,$)=>{if(!b)return ql;let oe=1;if(E===exe&&(E=6),D<0?(oe=0,D=-D):D>15&&(oe=2,D-=16),U<1||U>sxe||y!==z2||D<8||D>15||E<0||E>9||$<0||$>nxe||D===8&&oe!==1)return fd(b,ql);D===8&&(D=9);const de=new vxe;return b.state=de,de.strm=b,de.status=Rp,de.wrap=oe,de.gzhead=null,de.w_bits=D,de.w_size=1<<de.w_bits,de.w_mask=de.w_size-1,de.hash_bits=U+7,de.hash_size=1<<de.hash_bits,de.hash_mask=de.hash_size-1,de.hash_shift=~~((de.hash_bits+_r-1)/_r),de.window=new Uint8Array(de.w_size*2),de.head=new Uint16Array(de.hash_size),de.prev=new Uint16Array(de.w_size),de.lit_bufsize=1<<U+6,de.pending_buf_size=de.lit_bufsize*4,de.pending_buf=new Uint8Array(de.pending_buf_size),de.sym_buf=de.lit_bufsize,de.sym_end=(de.lit_bufsize-1)*3,de.level=E,de.strategy=$,de.method=y,Dq(b)},xxe=(b,E)=>Uq(b,E,z2,oxe,lxe,ixe),_xe=(b,E)=>{if(T1(b)||E>ld||E<0)return b?fd(b,ql):ql;const y=b.state;if(!b.output||b.avail_in!==0&&!b.input||y.status===M1&&E!==Fi)return fd(b,b.avail_out===0?yE:ql);const D=y.last_flush;if(y.last_flush=E,y.pending!==0){if(ds(b),b.avail_out===0)return y.last_flush=-1,Pi}else if(b.avail_in===0&&Fq(E)<=Fq(D)&&E!==Fi)return fd(b,yE);if(y.status===M1&&b.avail_in!==0)return fd(b,yE);if(y.status===Rp&&y.wrap===0&&(y.status=cd),y.status===Rp){let U=z2+(y.w_bits-8<<4)<<8,$=-1;if(y.strategy>=P2||y.level<2?$=0:y.level<6?$=1:y.level===6?$=2:$=3,U|=$<<6,y.strstart!==0&&(U|=dxe),U+=31-U%31,A1(y,U),y.strstart!==0&&(A1(y,b.adler>>>16),A1(y,b.adler&65535)),b.adler=1,y.status=cd,ds(b),y.pending!==0)return y.last_flush=-1,Pi}if(y.status===wE){if(b.adler=0,jr(y,31),jr(y,139),jr(y,8),y.gzhead)jr(y,(y.gzhead.text?1:0)+(y.gzhead.hcrc?2:0)+(y.gzhead.extra?4:0)+(y.gzhead.name?8:0)+(y.gzhead.comment?16:0)),jr(y,y.gzhead.time&255),jr(y,y.gzhead.time>>8&255),jr(y,y.gzhead.time>>16&255),jr(y,y.gzhead.time>>24&255),jr(y,y.level===9?2:y.strategy>=P2||y.level<2?4:0),jr(y,y.gzhead.os&255),y.gzhead.extra&&y.gzhead.extra.length&&(jr(y,y.gzhead.extra.length&255),jr(y,y.gzhead.extra.length>>8&255)),y.gzhead.hcrc&&(b.adler=br(b.adler,y.pending_buf,y.pending,0)),y.gzindex=0,y.status=xE;else if(jr(y,0),jr(y,0),jr(y,0),jr(y,0),jr(y,0),jr(y,y.level===9?2:y.strategy>=P2||y.level<2?4:0),jr(y,pxe),y.status=cd,ds(b),y.pending!==0)return y.last_flush=-1,Pi}if(y.status===xE){if(y.gzhead.extra){let U=y.pending,$=(y.gzhead.extra.length&65535)-y.gzindex;for(;y.pending+$>y.pending_buf_size;){let de=y.pending_buf_size-y.pending;if(y.pending_buf.set(y.gzhead.extra.subarray(y.gzindex,y.gzindex+de),y.pending),y.pending=y.pending_buf_size,y.gzhead.hcrc&&y.pending>U&&(b.adler=br(b.adler,y.pending_buf,y.pending-U,U)),y.gzindex+=de,ds(b),y.pending!==0)return y.last_flush=-1,Pi;U=0,$-=de}let oe=new Uint8Array(y.gzhead.extra);y.pending_buf.set(oe.subarray(y.gzindex,y.gzindex+$),y.pending),y.pending+=$,y.gzhead.hcrc&&y.pending>U&&(b.adler=br(b.adler,y.pending_buf,y.pending-U,U)),y.gzindex=0}y.status=_E}if(y.status===_E){if(y.gzhead.name){let U=y.pending,$;do{if(y.pending===y.pending_buf_size){if(y.gzhead.hcrc&&y.pending>U&&(b.adler=br(b.adler,y.pending_buf,y.pending-U,U)),ds(b),y.pending!==0)return y.last_flush=-1,Pi;U=0}y.gzindex<y.gzhead.name.length?$=y.gzhead.name.charCodeAt(y.gzindex++)&255:$=0,jr(y,$)}while($!==0);y.gzhead.hcrc&&y.pending>U&&(b.adler=br(b.adler,y.pending_buf,y.pending-U,U)),y.gzindex=0}y.status=SE}if(y.status===SE){if(y.gzhead.comment){let U=y.pending,$;do{if(y.pending===y.pending_buf_size){if(y.gzhead.hcrc&&y.pending>U&&(b.adler=br(b.adler,y.pending_buf,y.pending-U,U)),ds(b),y.pending!==0)return y.last_flush=-1,Pi;U=0}y.gzindex<y.gzhead.comment.length?$=y.gzhead.comment.charCodeAt(y.gzindex++)&255:$=0,jr(y,$)}while($!==0);y.gzhead.hcrc&&y.pending>U&&(b.adler=br(b.adler,y.pending_buf,y.pending-U,U))}y.status=kE}if(y.status===kE){if(y.gzhead.hcrc){if(y.pending+2>y.pending_buf_size&&(ds(b),y.pending!==0))return y.last_flush=-1,Pi;jr(y,b.adler&255),jr(y,b.adler>>8&255),b.adler=0}if(y.status=cd,ds(b),y.pending!==0)return y.last_flush=-1,Pi}if(b.avail_in!==0||y.lookahead!==0||E!==ki&&y.status!==M1){let U=y.level===0?zq(y,E):y.strategy===P2?bxe(y,E):y.strategy===rxe?gxe(y,E):C1[y.level].func(y,E);if((U===ud||U===Fp)&&(y.status=M1),U===ba||U===ud)return b.avail_out===0&&(y.last_flush=-1),Pi;if(U===Np&&(E===Zc?Ul(y):E!==ld&&(Jn(y,0,0,!1),E===F2&&(Sf(y.head),y.lookahead===0&&(y.strstart=0,y.block_start=0,y.insert=0))),ds(b),b.avail_out===0))return y.last_flush=-1,Pi}return E!==Fi?Pi:y.wrap<=0?Nq:(y.wrap===2?(jr(y,b.adler&255),jr(y,b.adler>>8&255),jr(y,b.adler>>16&255),jr(y,b.adler>>24&255),jr(y,b.total_in&255),jr(y,b.total_in>>8&255),jr(y,b.total_in>>16&255),jr(y,b.total_in>>24&255)):(A1(y,b.adler>>>16),A1(y,b.adler&65535)),ds(b),y.wrap>0&&(y.wrap=-y.wrap),y.pending!==0?Pi:Nq)},Sxe=b=>{if(T1(b))return ql;const E=b.state.status;return b.state=null,E===cd?fd(b,Qwe):Pi},kxe=(b,E)=>{let y=E.length;if(T1(b))return ql;const D=b.state,U=D.wrap;if(U===2||U===1&&D.status!==Rp||D.lookahead)return ql;if(U===1&&(b.adler=Ht(b.adler,E,y,0)),D.wrap=0,y>=D.w_size){U===0&&(Sf(D.head),D.strstart=0,D.block_start=0,D.insert=0);let Re=new Uint8Array(D.w_size);Re.set(E.subarray(y-D.w_size,y),0),E=Re,y=D.w_size}const $=b.avail_in,oe=b.next_in,de=b.input;for(b.avail_in=y,b.next_in=0,b.input=E,Pp(D);D.lookahead>=_r;){let Re=D.strstart,ye=D.lookahead-(_r-1);do D.ins_h=kf(D,D.ins_h,D.window[Re+_r-1]),D.prev[Re&D.w_mask]=D.head[D.ins_h],D.head[D.ins_h]=Re,Re++;while(--ye);D.strstart=Re,D.lookahead=_r-1,Pp(D)}return D.strstart+=D.lookahead,D.block_start=D.strstart,D.insert=D.lookahead,D.lookahead=0,D.match_length=D.prev_length=_r-1,D.match_available=0,b.next_in=oe,b.input=de,b.avail_in=$,D.wrap=U,Pi};var Exe=xxe,Mxe=Uq,Axe=Dq,Cxe=Lq,Txe=wxe,jxe=_xe,Ixe=Sxe,Oxe=kxe,Bxe="pako deflate (from Nodeca project)",j1={deflateInit:Exe,deflateInit2:Mxe,deflateReset:Axe,deflateResetKeep:Cxe,deflateSetHeader:Txe,deflate:jxe,deflateEnd:Ixe,deflateSetDictionary:Oxe,deflateInfo:Bxe};const Rxe=(b,E)=>Object.prototype.hasOwnProperty.call(b,E);var Nxe=function(b){const E=Array.prototype.slice.call(arguments,1);for(;E.length;){const y=E.shift();if(y){if(typeof y!="object")throw new TypeError(y+"must be non-object");for(const D in y)Rxe(y,D)&&(b[D]=y[D])}}return b},Fxe=b=>{let E=0;for(let D=0,U=b.length;D<U;D++)E+=b[D].length;const y=new Uint8Array(E);for(let D=0,U=0,$=b.length;D<$;D++){let oe=b[D];y.set(oe,U),U+=oe.length}return y},L2={assign:Nxe,flattenChunks:Fxe};let qq=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{qq=!1}const I1=new Uint8Array(256);for(let b=0;b<256;b++)I1[b]=b>=252?6:b>=248?5:b>=240?4:b>=224?3:b>=192?2:1;I1[254]=I1[254]=1;var Pxe=b=>{if(typeof TextEncoder=="function"&&TextEncoder.prototype.encode)return new TextEncoder().encode(b);let E,y,D,U,$,oe=b.length,de=0;for(U=0;U<oe;U++)y=b.charCodeAt(U),(y&64512)===55296&&U+1<oe&&(D=b.charCodeAt(U+1),(D&64512)===56320&&(y=65536+(y-55296<<10)+(D-56320),U++)),de+=y<128?1:y<2048?2:y<65536?3:4;for(E=new Uint8Array(de),$=0,U=0;$<de;U++)y=b.charCodeAt(U),(y&64512)===55296&&U+1<oe&&(D=b.charCodeAt(U+1),(D&64512)===56320&&(y=65536+(y-55296<<10)+(D-56320),U++)),y<128?E[$++]=y:y<2048?(E[$++]=192|y>>>6,E[$++]=128|y&63):y<65536?(E[$++]=224|y>>>12,E[$++]=128|y>>>6&63,E[$++]=128|y&63):(E[$++]=240|y>>>18,E[$++]=128|y>>>12&63,E[$++]=128|y>>>6&63,E[$++]=128|y&63);return E};const zxe=(b,E)=>{if(E<65534&&b.subarray&&qq)return String.fromCharCode.apply(null,b.length===E?b:b.subarray(0,E));let y="";for(let D=0;D<E;D++)y+=String.fromCharCode(b[D]);return y};var Lxe=(b,E)=>{const y=E||b.length;if(typeof TextDecoder=="function"&&TextDecoder.prototype.decode)return new TextDecoder().decode(b.subarray(0,E));let D,U;const $=new Array(y*2);for(U=0,D=0;D<y;){let oe=b[D++];if(oe<128){$[U++]=oe;continue}let de=I1[oe];if(de>4){$[U++]=65533,D+=de-1;continue}for(oe&=de===2?31:de===3?15:7;de>1&&D<y;)oe=oe<<6|b[D++]&63,de--;if(de>1){$[U++]=65533;continue}oe<65536?$[U++]=oe:(oe-=65536,$[U++]=55296|oe>>10&1023,$[U++]=56320|oe&1023)}return zxe($,U)},Dxe=(b,E)=>{E=E||b.length,E>b.length&&(E=b.length);let y=E-1;for(;y>=0&&(b[y]&192)===128;)y--;return y<0||y===0?E:y+I1[b[y]]>E?y:E},O1={string2buf:Pxe,buf2string:Lxe,utf8border:Dxe};function Uxe(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}var Vq=Uxe;const Zq=Object.prototype.toString,{Z_NO_FLUSH:qxe,Z_SYNC_FLUSH:Vxe,Z_FULL_FLUSH:Zxe,Z_FINISH:$xe,Z_OK:D2,Z_STREAM_END:Hxe,Z_DEFAULT_COMPRESSION:Wxe,Z_DEFAULT_STRATEGY:Kxe,Z_DEFLATED:Gxe}=Ln;function B1(b){this.options=L2.assign({level:Wxe,method:Gxe,chunkSize:16384,windowBits:15,memLevel:8,strategy:Kxe},b||{});let E=this.options;E.raw&&E.windowBits>0?E.windowBits=-E.windowBits:E.gzip&&E.windowBits>0&&E.windowBits<16&&(E.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Vq,this.strm.avail_out=0;let y=j1.deflateInit2(this.strm,E.level,E.method,E.windowBits,E.memLevel,E.strategy);if(y!==D2)throw new Error(Tr[y]);if(E.header&&j1.deflateSetHeader(this.strm,E.header),E.dictionary){let D;if(typeof E.dictionary=="string"?D=O1.string2buf(E.dictionary):Zq.call(E.dictionary)==="[object ArrayBuffer]"?D=new Uint8Array(E.dictionary):D=E.dictionary,y=j1.deflateSetDictionary(this.strm,D),y!==D2)throw new Error(Tr[y]);this._dict_set=!0}}B1.prototype.push=function(b,E){const y=this.strm,D=this.options.chunkSize;let U,$;if(this.ended)return!1;for(E===~~E?$=E:$=E===!0?$xe:qxe,typeof b=="string"?y.input=O1.string2buf(b):Zq.call(b)==="[object ArrayBuffer]"?y.input=new Uint8Array(b):y.input=b,y.next_in=0,y.avail_in=y.input.length;;){if(y.avail_out===0&&(y.output=new Uint8Array(D),y.next_out=0,y.avail_out=D),($===Vxe||$===Zxe)&&y.avail_out<=6){this.onData(y.output.subarray(0,y.next_out)),y.avail_out=0;continue}if(U=j1.deflate(y,$),U===Hxe)return y.next_out>0&&this.onData(y.output.subarray(0,y.next_out)),U=j1.deflateEnd(this.strm),this.onEnd(U),this.ended=!0,U===D2;if(y.avail_out===0){this.onData(y.output);continue}if($>0&&y.next_out>0){this.onData(y.output.subarray(0,y.next_out)),y.avail_out=0;continue}if(y.avail_in===0)break}return!0},B1.prototype.onData=function(b){this.chunks.push(b)},B1.prototype.onEnd=function(b){b===D2&&(this.result=L2.flattenChunks(this.chunks)),this.chunks=[],this.err=b,this.msg=this.strm.msg};function AE(b,E){const y=new B1(E);if(y.push(b,!0),y.err)throw y.msg||Tr[y.err];return y.result}function Yxe(b,E){return E=E||{},E.raw=!0,AE(b,E)}function Xxe(b,E){return E=E||{},E.gzip=!0,AE(b,E)}var Jxe=B1,Qxe=AE,e2e=Yxe,t2e=Xxe,r2e=Ln,n2e={Deflate:Jxe,deflate:Qxe,deflateRaw:e2e,gzip:t2e,constants:r2e};const U2=16209,i2e=16191;var a2e=function(b,E){let y,D,U,$,oe,de,Re,ye,Ee,at,Pe,Le,Br,Lr,or,Gt,Wt,st,Kt,jn,ur,ir,lr,Ot;const ar=b.state;y=b.next_in,lr=b.input,D=y+(b.avail_in-5),U=b.next_out,Ot=b.output,$=U-(E-b.avail_out),oe=U+(b.avail_out-257),de=ar.dmax,Re=ar.wsize,ye=ar.whave,Ee=ar.wnext,at=ar.window,Pe=ar.hold,Le=ar.bits,Br=ar.lencode,Lr=ar.distcode,or=(1<<ar.lenbits)-1,Gt=(1<<ar.distbits)-1;e:do{Le<15&&(Pe+=lr[y++]<<Le,Le+=8,Pe+=lr[y++]<<Le,Le+=8),Wt=Br[Pe&or];t:for(;;){if(st=Wt>>>24,Pe>>>=st,Le-=st,st=Wt>>>16&255,st===0)Ot[U++]=Wt&65535;else if(st&16){Kt=Wt&65535,st&=15,st&&(Le<st&&(Pe+=lr[y++]<<Le,Le+=8),Kt+=Pe&(1<<st)-1,Pe>>>=st,Le-=st),Le<15&&(Pe+=lr[y++]<<Le,Le+=8,Pe+=lr[y++]<<Le,Le+=8),Wt=Lr[Pe&Gt];r:for(;;){if(st=Wt>>>24,Pe>>>=st,Le-=st,st=Wt>>>16&255,st&16){if(jn=Wt&65535,st&=15,Le<st&&(Pe+=lr[y++]<<Le,Le+=8,Le<st&&(Pe+=lr[y++]<<Le,Le+=8)),jn+=Pe&(1<<st)-1,jn>de){b.msg="invalid distance too far back",ar.mode=U2;break e}if(Pe>>>=st,Le-=st,st=U-$,jn>st){if(st=jn-st,st>ye&&ar.sane){b.msg="invalid distance too far back",ar.mode=U2;break e}if(ur=0,ir=at,Ee===0){if(ur+=Re-st,st<Kt){Kt-=st;do Ot[U++]=at[ur++];while(--st);ur=U-jn,ir=Ot}}else if(Ee<st){if(ur+=Re+Ee-st,st-=Ee,st<Kt){Kt-=st;do Ot[U++]=at[ur++];while(--st);if(ur=0,Ee<Kt){st=Ee,Kt-=st;do Ot[U++]=at[ur++];while(--st);ur=U-jn,ir=Ot}}}else if(ur+=Ee-st,st<Kt){Kt-=st;do Ot[U++]=at[ur++];while(--st);ur=U-jn,ir=Ot}for(;Kt>2;)Ot[U++]=ir[ur++],Ot[U++]=ir[ur++],Ot[U++]=ir[ur++],Kt-=3;Kt&&(Ot[U++]=ir[ur++],Kt>1&&(Ot[U++]=ir[ur++]))}else{ur=U-jn;do Ot[U++]=Ot[ur++],Ot[U++]=Ot[ur++],Ot[U++]=Ot[ur++],Kt-=3;while(Kt>2);Kt&&(Ot[U++]=Ot[ur++],Kt>1&&(Ot[U++]=Ot[ur++]))}}else if(st&64){b.msg="invalid distance code",ar.mode=U2;break e}else{Wt=Lr[(Wt&65535)+(Pe&(1<<st)-1)];continue r}break}}else if(st&64)if(st&32){ar.mode=i2e;break e}else{b.msg="invalid literal/length code",ar.mode=U2;break e}else{Wt=Br[(Wt&65535)+(Pe&(1<<st)-1)];continue t}break}}while(y<D&&U<oe);Kt=Le>>3,y-=Kt,Le-=Kt<<3,Pe&=(1<<Le)-1,b.next_in=y,b.next_out=U,b.avail_in=y<D?5+(D-y):5-(y-D),b.avail_out=U<oe?257+(oe-U):257-(U-oe),ar.hold=Pe,ar.bits=Le};const Lp=15,$q=852,Hq=592,Wq=0,CE=1,Kq=2,s2e=new Uint16Array([3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0]),o2e=new Uint8Array([16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78]),l2e=new Uint16Array([1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0]),c2e=new Uint8Array([16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]);var R1=(b,E,y,D,U,$,oe,de)=>{const Re=de.bits;let ye=0,Ee=0,at=0,Pe=0,Le=0,Br=0,Lr=0,or=0,Gt=0,Wt=0,st,Kt,jn,ur,ir,lr=null,Ot;const ar=new Uint16Array(Lp+1),zi=new Uint16Array(Lp+1);let $l=null,bs,$o,Wc;for(ye=0;ye<=Lp;ye++)ar[ye]=0;for(Ee=0;Ee<D;Ee++)ar[E[y+Ee]]++;for(Le=Re,Pe=Lp;Pe>=1&&ar[Pe]===0;Pe--);if(Le>Pe&&(Le=Pe),Pe===0)return U[$++]=1<<24|64<<16|0,U[$++]=1<<24|64<<16|0,de.bits=1,0;for(at=1;at<Pe&&ar[at]===0;at++);for(Le<at&&(Le=at),or=1,ye=1;ye<=Lp;ye++)if(or<<=1,or-=ar[ye],or<0)return-1;if(or>0&&(b===Wq||Pe!==1))return-1;for(zi[1]=0,ye=1;ye<Lp;ye++)zi[ye+1]=zi[ye]+ar[ye];for(Ee=0;Ee<D;Ee++)E[y+Ee]!==0&&(oe[zi[E[y+Ee]]++]=Ee);if(b===Wq?(lr=$l=oe,Ot=20):b===CE?(lr=s2e,$l=o2e,Ot=257):(lr=l2e,$l=c2e,Ot=0),Wt=0,Ee=0,ye=at,ir=$,Br=Le,Lr=0,jn=-1,Gt=1<<Le,ur=Gt-1,b===CE&&Gt>$q||b===Kq&&Gt>Hq)return 1;for(;;){bs=ye-Lr,oe[Ee]+1<Ot?($o=0,Wc=oe[Ee]):oe[Ee]>=Ot?($o=$l[oe[Ee]-Ot],Wc=lr[oe[Ee]-Ot]):($o=96,Wc=0),st=1<<ye-Lr,Kt=1<<Br,at=Kt;do Kt-=st,U[ir+(Wt>>Lr)+Kt]=bs<<24|$o<<16|Wc|0;while(Kt!==0);for(st=1<<ye-1;Wt&st;)st>>=1;if(st!==0?(Wt&=st-1,Wt+=st):Wt=0,Ee++,--ar[ye]===0){if(ye===Pe)break;ye=E[y+oe[Ee]]}if(ye>Le&&(Wt&ur)!==jn){for(Lr===0&&(Lr=Le),ir+=at,Br=ye-Lr,or=1<<Br;Br+Lr<Pe&&(or-=ar[Br+Lr],!(or<=0));)Br++,or<<=1;if(Gt+=1<<Br,b===CE&&Gt>$q||b===Kq&&Gt>Hq)return 1;jn=Wt&ur,U[jn]=Le<<24|Br<<16|ir-$|0}}return Wt!==0&&(U[ir+Wt]=ye-Lr<<24|64<<16|0),de.bits=Le,0};const u2e=0,Gq=1,Yq=2,{Z_FINISH:Xq,Z_BLOCK:f2e,Z_TREES:q2,Z_OK:hd,Z_STREAM_END:h2e,Z_NEED_DICT:d2e,Z_STREAM_ERROR:Vo,Z_DATA_ERROR:Jq,Z_MEM_ERROR:Qq,Z_BUF_ERROR:p2e,Z_DEFLATED:eV}=Ln,V2=16180,tV=16181,rV=16182,nV=16183,iV=16184,aV=16185,sV=16186,oV=16187,lV=16188,cV=16189,Z2=16190,$c=16191,TE=16192,uV=16193,jE=16194,fV=16195,hV=16196,dV=16197,pV=16198,$2=16199,H2=16200,mV=16201,gV=16202,bV=16203,yV=16204,vV=16205,IE=16206,wV=16207,xV=16208,bn=16209,_V=16210,SV=16211,m2e=852,g2e=592,b2e=15,kV=b=>(b>>>24&255)+(b>>>8&65280)+((b&65280)<<8)+((b&255)<<24);function y2e(){this.strm=null,this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}const dd=b=>{if(!b)return 1;const E=b.state;return!E||E.strm!==b||E.mode<V2||E.mode>SV?1:0},EV=b=>{if(dd(b))return Vo;const E=b.state;return b.total_in=b.total_out=E.total=0,b.msg="",E.wrap&&(b.adler=E.wrap&1),E.mode=V2,E.last=0,E.havedict=0,E.flags=-1,E.dmax=32768,E.head=null,E.hold=0,E.bits=0,E.lencode=E.lendyn=new Int32Array(m2e),E.distcode=E.distdyn=new Int32Array(g2e),E.sane=1,E.back=-1,hd},MV=b=>{if(dd(b))return Vo;const E=b.state;return E.wsize=0,E.whave=0,E.wnext=0,EV(b)},AV=(b,E)=>{let y;if(dd(b))return Vo;const D=b.state;return E<0?(y=0,E=-E):(y=(E>>4)+5,E<48&&(E&=15)),E&&(E<8||E>15)?Vo:(D.window!==null&&D.wbits!==E&&(D.window=null),D.wrap=y,D.wbits=E,MV(b))},CV=(b,E)=>{if(!b)return Vo;const y=new y2e;b.state=y,y.strm=b,y.window=null,y.mode=V2;const D=AV(b,E);return D!==hd&&(b.state=null),D},v2e=b=>CV(b,b2e);let TV=!0,OE,BE;const w2e=b=>{if(TV){OE=new Int32Array(512),BE=new Int32Array(32);let E=0;for(;E<144;)b.lens[E++]=8;for(;E<256;)b.lens[E++]=9;for(;E<280;)b.lens[E++]=7;for(;E<288;)b.lens[E++]=8;for(R1(Gq,b.lens,0,288,OE,0,b.work,{bits:9}),E=0;E<32;)b.lens[E++]=5;R1(Yq,b.lens,0,32,BE,0,b.work,{bits:5}),TV=!1}b.lencode=OE,b.lenbits=9,b.distcode=BE,b.distbits=5},jV=(b,E,y,D)=>{let U;const $=b.state;return $.window===null&&($.wsize=1<<$.wbits,$.wnext=0,$.whave=0,$.window=new Uint8Array($.wsize)),D>=$.wsize?($.window.set(E.subarray(y-$.wsize,y),0),$.wnext=0,$.whave=$.wsize):(U=$.wsize-$.wnext,U>D&&(U=D),$.window.set(E.subarray(y-D,y-D+U),$.wnext),D-=U,D?($.window.set(E.subarray(y-D,y),0),$.wnext=D,$.whave=$.wsize):($.wnext+=U,$.wnext===$.wsize&&($.wnext=0),$.whave<$.wsize&&($.whave+=U))),0},x2e=(b,E)=>{let y,D,U,$,oe,de,Re,ye,Ee,at,Pe,Le,Br,Lr,or=0,Gt,Wt,st,Kt,jn,ur,ir,lr;const Ot=new Uint8Array(4);let ar,zi;const $l=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(dd(b)||!b.output||!b.input&&b.avail_in!==0)return Vo;y=b.state,y.mode===$c&&(y.mode=TE),oe=b.next_out,U=b.output,Re=b.avail_out,$=b.next_in,D=b.input,de=b.avail_in,ye=y.hold,Ee=y.bits,at=de,Pe=Re,lr=hd;e:for(;;)switch(y.mode){case V2:if(y.wrap===0){y.mode=TE;break}for(;Ee<16;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}if(y.wrap&2&&ye===35615){y.wbits===0&&(y.wbits=15),y.check=0,Ot[0]=ye&255,Ot[1]=ye>>>8&255,y.check=br(y.check,Ot,2,0),ye=0,Ee=0,y.mode=tV;break}if(y.head&&(y.head.done=!1),!(y.wrap&1)||(((ye&255)<<8)+(ye>>8))%31){b.msg="incorrect header check",y.mode=bn;break}if((ye&15)!==eV){b.msg="unknown compression method",y.mode=bn;break}if(ye>>>=4,Ee-=4,ir=(ye&15)+8,y.wbits===0&&(y.wbits=ir),ir>15||ir>y.wbits){b.msg="invalid window size",y.mode=bn;break}y.dmax=1<<y.wbits,y.flags=0,b.adler=y.check=1,y.mode=ye&512?cV:$c,ye=0,Ee=0;break;case tV:for(;Ee<16;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}if(y.flags=ye,(y.flags&255)!==eV){b.msg="unknown compression method",y.mode=bn;break}if(y.flags&57344){b.msg="unknown header flags set",y.mode=bn;break}y.head&&(y.head.text=ye>>8&1),y.flags&512&&y.wrap&4&&(Ot[0]=ye&255,Ot[1]=ye>>>8&255,y.check=br(y.check,Ot,2,0)),ye=0,Ee=0,y.mode=rV;case rV:for(;Ee<32;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}y.head&&(y.head.time=ye),y.flags&512&&y.wrap&4&&(Ot[0]=ye&255,Ot[1]=ye>>>8&255,Ot[2]=ye>>>16&255,Ot[3]=ye>>>24&255,y.check=br(y.check,Ot,4,0)),ye=0,Ee=0,y.mode=nV;case nV:for(;Ee<16;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}y.head&&(y.head.xflags=ye&255,y.head.os=ye>>8),y.flags&512&&y.wrap&4&&(Ot[0]=ye&255,Ot[1]=ye>>>8&255,y.check=br(y.check,Ot,2,0)),ye=0,Ee=0,y.mode=iV;case iV:if(y.flags&1024){for(;Ee<16;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}y.length=ye,y.head&&(y.head.extra_len=ye),y.flags&512&&y.wrap&4&&(Ot[0]=ye&255,Ot[1]=ye>>>8&255,y.check=br(y.check,Ot,2,0)),ye=0,Ee=0}else y.head&&(y.head.extra=null);y.mode=aV;case aV:if(y.flags&1024&&(Le=y.length,Le>de&&(Le=de),Le&&(y.head&&(ir=y.head.extra_len-y.length,y.head.extra||(y.head.extra=new Uint8Array(y.head.extra_len)),y.head.extra.set(D.subarray($,$+Le),ir)),y.flags&512&&y.wrap&4&&(y.check=br(y.check,D,Le,$)),de-=Le,$+=Le,y.length-=Le),y.length))break e;y.length=0,y.mode=sV;case sV:if(y.flags&2048){if(de===0)break e;Le=0;do ir=D[$+Le++],y.head&&ir&&y.length<65536&&(y.head.name+=String.fromCharCode(ir));while(ir&&Le<de);if(y.flags&512&&y.wrap&4&&(y.check=br(y.check,D,Le,$)),de-=Le,$+=Le,ir)break e}else y.head&&(y.head.name=null);y.length=0,y.mode=oV;case oV:if(y.flags&4096){if(de===0)break e;Le=0;do ir=D[$+Le++],y.head&&ir&&y.length<65536&&(y.head.comment+=String.fromCharCode(ir));while(ir&&Le<de);if(y.flags&512&&y.wrap&4&&(y.check=br(y.check,D,Le,$)),de-=Le,$+=Le,ir)break e}else y.head&&(y.head.comment=null);y.mode=lV;case lV:if(y.flags&512){for(;Ee<16;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}if(y.wrap&4&&ye!==(y.check&65535)){b.msg="header crc mismatch",y.mode=bn;break}ye=0,Ee=0}y.head&&(y.head.hcrc=y.flags>>9&1,y.head.done=!0),b.adler=y.check=0,y.mode=$c;break;case cV:for(;Ee<32;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}b.adler=y.check=kV(ye),ye=0,Ee=0,y.mode=Z2;case Z2:if(y.havedict===0)return b.next_out=oe,b.avail_out=Re,b.next_in=$,b.avail_in=de,y.hold=ye,y.bits=Ee,d2e;b.adler=y.check=1,y.mode=$c;case $c:if(E===f2e||E===q2)break e;case TE:if(y.last){ye>>>=Ee&7,Ee-=Ee&7,y.mode=IE;break}for(;Ee<3;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}switch(y.last=ye&1,ye>>>=1,Ee-=1,ye&3){case 0:y.mode=uV;break;case 1:if(w2e(y),y.mode=$2,E===q2){ye>>>=2,Ee-=2;break e}break;case 2:y.mode=hV;break;case 3:b.msg="invalid block type",y.mode=bn}ye>>>=2,Ee-=2;break;case uV:for(ye>>>=Ee&7,Ee-=Ee&7;Ee<32;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}if((ye&65535)!==(ye>>>16^65535)){b.msg="invalid stored block lengths",y.mode=bn;break}if(y.length=ye&65535,ye=0,Ee=0,y.mode=jE,E===q2)break e;case jE:y.mode=fV;case fV:if(Le=y.length,Le){if(Le>de&&(Le=de),Le>Re&&(Le=Re),Le===0)break e;U.set(D.subarray($,$+Le),oe),de-=Le,$+=Le,Re-=Le,oe+=Le,y.length-=Le;break}y.mode=$c;break;case hV:for(;Ee<14;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}if(y.nlen=(ye&31)+257,ye>>>=5,Ee-=5,y.ndist=(ye&31)+1,ye>>>=5,Ee-=5,y.ncode=(ye&15)+4,ye>>>=4,Ee-=4,y.nlen>286||y.ndist>30){b.msg="too many length or distance symbols",y.mode=bn;break}y.have=0,y.mode=dV;case dV:for(;y.have<y.ncode;){for(;Ee<3;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}y.lens[$l[y.have++]]=ye&7,ye>>>=3,Ee-=3}for(;y.have<19;)y.lens[$l[y.have++]]=0;if(y.lencode=y.lendyn,y.lenbits=7,ar={bits:y.lenbits},lr=R1(u2e,y.lens,0,19,y.lencode,0,y.work,ar),y.lenbits=ar.bits,lr){b.msg="invalid code lengths set",y.mode=bn;break}y.have=0,y.mode=pV;case pV:for(;y.have<y.nlen+y.ndist;){for(;or=y.lencode[ye&(1<<y.lenbits)-1],Gt=or>>>24,Wt=or>>>16&255,st=or&65535,!(Gt<=Ee);){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}if(st<16)ye>>>=Gt,Ee-=Gt,y.lens[y.have++]=st;else{if(st===16){for(zi=Gt+2;Ee<zi;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}if(ye>>>=Gt,Ee-=Gt,y.have===0){b.msg="invalid bit length repeat",y.mode=bn;break}ir=y.lens[y.have-1],Le=3+(ye&3),ye>>>=2,Ee-=2}else if(st===17){for(zi=Gt+3;Ee<zi;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}ye>>>=Gt,Ee-=Gt,ir=0,Le=3+(ye&7),ye>>>=3,Ee-=3}else{for(zi=Gt+7;Ee<zi;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}ye>>>=Gt,Ee-=Gt,ir=0,Le=11+(ye&127),ye>>>=7,Ee-=7}if(y.have+Le>y.nlen+y.ndist){b.msg="invalid bit length repeat",y.mode=bn;break}for(;Le--;)y.lens[y.have++]=ir}}if(y.mode===bn)break;if(y.lens[256]===0){b.msg="invalid code -- missing end-of-block",y.mode=bn;break}if(y.lenbits=9,ar={bits:y.lenbits},lr=R1(Gq,y.lens,0,y.nlen,y.lencode,0,y.work,ar),y.lenbits=ar.bits,lr){b.msg="invalid literal/lengths set",y.mode=bn;break}if(y.distbits=6,y.distcode=y.distdyn,ar={bits:y.distbits},lr=R1(Yq,y.lens,y.nlen,y.ndist,y.distcode,0,y.work,ar),y.distbits=ar.bits,lr){b.msg="invalid distances set",y.mode=bn;break}if(y.mode=$2,E===q2)break e;case $2:y.mode=H2;case H2:if(de>=6&&Re>=258){b.next_out=oe,b.avail_out=Re,b.next_in=$,b.avail_in=de,y.hold=ye,y.bits=Ee,a2e(b,Pe),oe=b.next_out,U=b.output,Re=b.avail_out,$=b.next_in,D=b.input,de=b.avail_in,ye=y.hold,Ee=y.bits,y.mode===$c&&(y.back=-1);break}for(y.back=0;or=y.lencode[ye&(1<<y.lenbits)-1],Gt=or>>>24,Wt=or>>>16&255,st=or&65535,!(Gt<=Ee);){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}if(Wt&&!(Wt&240)){for(Kt=Gt,jn=Wt,ur=st;or=y.lencode[ur+((ye&(1<<Kt+jn)-1)>>Kt)],Gt=or>>>24,Wt=or>>>16&255,st=or&65535,!(Kt+Gt<=Ee);){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}ye>>>=Kt,Ee-=Kt,y.back+=Kt}if(ye>>>=Gt,Ee-=Gt,y.back+=Gt,y.length=st,Wt===0){y.mode=vV;break}if(Wt&32){y.back=-1,y.mode=$c;break}if(Wt&64){b.msg="invalid literal/length code",y.mode=bn;break}y.extra=Wt&15,y.mode=mV;case mV:if(y.extra){for(zi=y.extra;Ee<zi;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}y.length+=ye&(1<<y.extra)-1,ye>>>=y.extra,Ee-=y.extra,y.back+=y.extra}y.was=y.length,y.mode=gV;case gV:for(;or=y.distcode[ye&(1<<y.distbits)-1],Gt=or>>>24,Wt=or>>>16&255,st=or&65535,!(Gt<=Ee);){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}if(!(Wt&240)){for(Kt=Gt,jn=Wt,ur=st;or=y.distcode[ur+((ye&(1<<Kt+jn)-1)>>Kt)],Gt=or>>>24,Wt=or>>>16&255,st=or&65535,!(Kt+Gt<=Ee);){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}ye>>>=Kt,Ee-=Kt,y.back+=Kt}if(ye>>>=Gt,Ee-=Gt,y.back+=Gt,Wt&64){b.msg="invalid distance code",y.mode=bn;break}y.offset=st,y.extra=Wt&15,y.mode=bV;case bV:if(y.extra){for(zi=y.extra;Ee<zi;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}y.offset+=ye&(1<<y.extra)-1,ye>>>=y.extra,Ee-=y.extra,y.back+=y.extra}if(y.offset>y.dmax){b.msg="invalid distance too far back",y.mode=bn;break}y.mode=yV;case yV:if(Re===0)break e;if(Le=Pe-Re,y.offset>Le){if(Le=y.offset-Le,Le>y.whave&&y.sane){b.msg="invalid distance too far back",y.mode=bn;break}Le>y.wnext?(Le-=y.wnext,Br=y.wsize-Le):Br=y.wnext-Le,Le>y.length&&(Le=y.length),Lr=y.window}else Lr=U,Br=oe-y.offset,Le=y.length;Le>Re&&(Le=Re),Re-=Le,y.length-=Le;do U[oe++]=Lr[Br++];while(--Le);y.length===0&&(y.mode=H2);break;case vV:if(Re===0)break e;U[oe++]=y.length,Re--,y.mode=H2;break;case IE:if(y.wrap){for(;Ee<32;){if(de===0)break e;de--,ye|=D[$++]<<Ee,Ee+=8}if(Pe-=Re,b.total_out+=Pe,y.total+=Pe,y.wrap&4&&Pe&&(b.adler=y.check=y.flags?br(y.check,U,Pe,oe-Pe):Ht(y.check,U,Pe,oe-Pe)),Pe=Re,y.wrap&4&&(y.flags?ye:kV(ye))!==y.check){b.msg="incorrect data check",y.mode=bn;break}ye=0,Ee=0}y.mode=wV;case wV:if(y.wrap&&y.flags){for(;Ee<32;){if(de===0)break e;de--,ye+=D[$++]<<Ee,Ee+=8}if(y.wrap&4&&ye!==(y.total&4294967295)){b.msg="incorrect length check",y.mode=bn;break}ye=0,Ee=0}y.mode=xV;case xV:lr=h2e;break e;case bn:lr=Jq;break e;case _V:return Qq;case SV:default:return Vo}return b.next_out=oe,b.avail_out=Re,b.next_in=$,b.avail_in=de,y.hold=ye,y.bits=Ee,(y.wsize||Pe!==b.avail_out&&y.mode<bn&&(y.mode<IE||E!==Xq))&&jV(b,b.output,b.next_out,Pe-b.avail_out),at-=b.avail_in,Pe-=b.avail_out,b.total_in+=at,b.total_out+=Pe,y.total+=Pe,y.wrap&4&&Pe&&(b.adler=y.check=y.flags?br(y.check,U,Pe,b.next_out-Pe):Ht(y.check,U,Pe,b.next_out-Pe)),b.data_type=y.bits+(y.last?64:0)+(y.mode===$c?128:0)+(y.mode===$2||y.mode===jE?256:0),(at===0&&Pe===0||E===Xq)&&lr===hd&&(lr=p2e),lr},_2e=b=>{if(dd(b))return Vo;let E=b.state;return E.window&&(E.window=null),b.state=null,hd},S2e=(b,E)=>{if(dd(b))return Vo;const y=b.state;return y.wrap&2?(y.head=E,E.done=!1,hd):Vo},k2e=(b,E)=>{const y=E.length;let D,U,$;return dd(b)||(D=b.state,D.wrap!==0&&D.mode!==Z2)?Vo:D.mode===Z2&&(U=1,U=Ht(U,E,y,0),U!==D.check)?Jq:($=jV(b,E,y,y),$?(D.mode=_V,Qq):(D.havedict=1,hd))};var E2e=MV,M2e=AV,A2e=EV,C2e=v2e,T2e=CV,j2e=x2e,I2e=_2e,O2e=S2e,B2e=k2e,R2e="pako inflate (from Nodeca project)",Hc={inflateReset:E2e,inflateReset2:M2e,inflateResetKeep:A2e,inflateInit:C2e,inflateInit2:T2e,inflate:j2e,inflateEnd:I2e,inflateGetHeader:O2e,inflateSetDictionary:B2e,inflateInfo:R2e};function N2e(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}var F2e=N2e;const IV=Object.prototype.toString,{Z_NO_FLUSH:P2e,Z_FINISH:z2e,Z_OK:N1,Z_STREAM_END:RE,Z_NEED_DICT:NE,Z_STREAM_ERROR:L2e,Z_DATA_ERROR:OV,Z_MEM_ERROR:D2e}=Ln;function F1(b){this.options=L2.assign({chunkSize:65536,windowBits:15,to:""},b||{});const E=this.options;E.raw&&E.windowBits>=0&&E.windowBits<16&&(E.windowBits=-E.windowBits,E.windowBits===0&&(E.windowBits=-15)),E.windowBits>=0&&E.windowBits<16&&!(b&&b.windowBits)&&(E.windowBits+=32),E.windowBits>15&&E.windowBits<48&&(E.windowBits&15||(E.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Vq,this.strm.avail_out=0;let y=Hc.inflateInit2(this.strm,E.windowBits);if(y!==N1)throw new Error(Tr[y]);if(this.header=new F2e,Hc.inflateGetHeader(this.strm,this.header),E.dictionary&&(typeof E.dictionary=="string"?E.dictionary=O1.str
1971ing2buf(E.dictionary):IV.call(E.dictionary)==="[object ArrayBuffer]"&&(E.dictionary=new Uint8Array(E.dictionary)),E.raw&&(y=Hc.inflateSetDictionary(this.strm,E.dictionary),y!==N1)))throw new Error(Tr[y])}F1.prototype.push=function(b,E){const y=this.strm,D=this.options.chunkSize,U=this.options.dictionary;let $,oe,de;if(this.ended)return!1;for(E===~~E?oe=E:oe=E===!0?z2e:P2e,IV.call(b)==="[object ArrayBuffer]"?y.input=new Uint8Array(b):y.input=b,y.next_in=0,y.avail_in=y.input.length;;){for(y.avail_out===0&&(y.output=new Uint8Array(D),y.next_out=0,y.avail_out=D),$=Hc.inflate(y,oe),$===NE&&U&&($=Hc.inflateSetDictionary(y,U),$===N1?$=Hc.inflate(y,oe):$===OV&&($=NE));y.avail_in>0&&$===RE&&y.state.wrap>0&&b[y.next_in]!==0;)Hc.inflateReset(y),$=Hc.inflate(y,oe);switch($){case L2e:case OV:case NE:case D2e:return this.onEnd($),this.ended=!0,!1}if(de=y.avail_out,y.next_out&&(y.avail_out===0||$===RE))if(this.options.to==="string"){let Re=O1.utf8border(y.output,y.next_out),ye=y.next_out-Re,Ee=O1.buf2string(y.output,Re);y.next_out=ye,y.avail_out=D-ye,ye&&y.output.set(y.output.subarray(Re,Re+ye),0),this.onData(Ee)}else this.onData(y.output.length===y.next_out?y.output:y.output.subarray(0,y.next_out));if(!($===N1&&de===0)){if($===RE)return $=Hc.inflateEnd(this.strm),this.onEnd($),this.ended=!0,!0;if(y.avail_in===0)break}}return!0},F1.prototype.onData=function(b){this.chunks.push(b)},F1.prototype.onEnd=function(b){b===N1&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=L2.flattenChunks(this.chunks)),this.chunks=[],this.err=b,this.msg=this.strm.msg};function FE(b,E){const y=new F1(E);if(y.push(b),y.err)throw y.msg||Tr[y.err];return y.result}function U2e(b,E){return E=E||{},E.raw=!0,FE(b,E)}var q2e=F1,V2e=FE,Z2e=U2e,$2e=FE,H2e=Ln,W2e={Inflate:q2e,inflate:V2e,inflateRaw:Z2e,ungzip:$2e,constants:H2e};const{Deflate:K2e,deflate:G2e,deflateRaw:Y2e,gzip:X2e}=n2e,{Inflate:J2e,inflate:Q2e,inflateRaw:e_e,ungzip:t_e}=W2e;var r_e=K2e,n_e=G2e,i_e=Y2e,a_e=X2e,s_e=J2e,o_e=Q2e,l_e=e_e,c_e=t_e,u_e=Ln,f_e={Deflate:r_e,deflate:n_e,deflateRaw:i_e,gzip:a_e,Inflate:s_e,inflate:o_e,inflateRaw:l_e,ungzip:c_e,constants:u_e};async function h_e(b,E){let y;if(E){const $=b?"-threads":"",oe=E.split("/").slice(0,-1).join("/"),de=E.split("/").pop(),[Re,...ye]=de.split(".");y=`${oe}/${Re}${$}.${ye.join(".")}`}else y=b?(await f4(async()=>{const{default:$}=await import("./barretenberg-threads-Cg83TIXa.js");return{default:$}},[])).default:(await f4(async()=>{const{default:$}=await import("./barretenberg-BP4ocdmL.js");return{default:$}},[])).default;const D=await(await fetch(y)).arrayBuffer(),U=new Uint8Array(D);return U[0]===31&&U[1]===139&&U[2]===8?f_e.ungzip(U).buffer:U}async function BV(b=32,E,y=wt()("bb.js:fetch_mat")){const D=Et(),U=D?await d_e(y):1,$=Math.min(b,U,32);y(`Fetching bb wasm from ${E??"default location"}`);const oe=await h_e(D,E);y(`Compiling bb wasm of ${oe.byteLength} bytes`);const de=await WebAssembly.compile(oe);return y("Compilation of bb wasm complete"),{module:de,threads:$}}async function d_e(b){if(typeof navigator<"u"&&navigator.hardwareConcurrency)return navigator.hardwareConcurrency;try{return(await Yt.e(522).then(Yt.t.bind(Yt,522,23))).cpus().length}catch(E){return b(`Could not detect environment to query number of threads. Falling back to one thread. Error: ${E.message??E}`),1}}const p_e=4,PE=32;function zE(b,E){const y=b.slice(p_e),D=y.slice(0,E*PE);return{proof:y.slice(E*PE),publicInputs:D}}function LE(b,E){const y=ce((b.length+E.length)/PE);return Uint8Array.from([...y,...b,...E])}function DE(b){const E=UE(b.publicInputs);return Uint8Array.from([...E,...b.proof])}function W2(b){const E=[];for(let y=0;y<b.length;y+=32){const D=b.slice(y,y+32);E.push(D)}return E.map(g_e)}function UE(b){const E=b.map(b_e);return m_e(E)}function m_e(b){const E=b.reduce((U,$)=>U+$.length,0),y=new Uint8Array(E);let D=0;for(const U of b)y.set(U,D),D+=U.length;return y}function g_e(b){const E=[];return b.forEach(function(y){let D=y.toString(16);D.length%2&&(D="0"+D),E.push(D)}),"0x"+E.join("")}function b_e(b){const E=BigInt(b).toString(16).padStart(64,"0"),y=E.length/2,D=new Uint8Array(y);let U=0,$=0;for(;
1971U<y;)D[U]=parseInt(E.slice($,$+2),16),U+=1,$+=2;return D}class y_e{constructor(E={threads:1}){this.options=E}async instantiate(){if(!this.api){const E=await pd.new(this.options);await E.initSRSForCircuitSize(0),this.acirComposer=await E.acirNewAcirComposer(0),this.api=E}}async verifyUltraPlonkProof(E,y){await this.instantiate(),await this.api.acirLoadVerificationKey(this.acirComposer,new V(y));const D=DE(E);return await this.api.acirVerifyProof(this.acirComposer,D)}async verifyUltraHonkProof(E,y){await this.instantiate();const D=LE(UE(E.publicInputs),E.proof);return await this.api.acirVerifyUltraHonk(D,new V(y))}async destroy(){this.api&&await this.api.destroy()}}var ms=Uint8Array,P1=Uint16Array,v_e=Int32Array,RV=new ms([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]),NV=new ms([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]),w_e=new ms([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),FV=function(b,E){for(var y=new P1(31),D=0;D<31;++D)y[D]=E+=1<<b[D-1];for(var U=new v_e(y[30]),D=1;D<30;++D)for(var $=y[D];$<y[D+1];++$)U[$]=$-y[D]<<5|D;return{b:y,r:U}},PV=FV(RV,2),zV=PV.b,x_e=PV.r;zV[28]=258,x_e[258]=28;for(var __e=FV(NV,0),S_e=__e.b,LV=new P1(32768),on=0;on<32768;++on){var Ef=(on&43690)>>1|(on&21845)<<1;Ef=(Ef&52428)>>2|(Ef&13107)<<2,Ef=(Ef&61680)>>4|(Ef&3855)<<4,LV[on]=((Ef&65280)>>8|(Ef&255)<<8)>>1}for(var z1=function(E,y,D){for(var U=E.length,$=0,oe=new P1(y);$<U;++$)E[$]&&++oe[E[$]-1];var de=new P1(y);for($=1;$<y;++$)de[$]=de[$-1]+oe[$-1]<<1;var Re;{Re=new P1(1<<y);var ye=15-y;for($=0;$<U;++$)if(E[$])for(var Ee=$<<4|E[$],at=y-E[$],Pe=de[E[$]-1]++<<at,Le=Pe|(1<<at)-1;Pe<=Le;++Pe)Re[LV[Pe]>>ye]=Ee}return Re},L1=new ms(288),on=0;on<144;++on)L1[on]=8;for(var on=144;on<256;++on)L1[on]=9;for(var on=256;on<280;++on)L1[on]=7;for(var on=280;on<288;++on)L1[on]=8;for(var DV=new ms(32),on=0;on<32;++on)DV[on]=5;var k_e=z1(L1,9),E_e=z1(DV,5),qE=function(b){for(var E=b[0],y=1;y<b.length;++y)b[y]>E&&(E=b[y]);return E},Zo=function(b,E,y){var D=E/8|0;return(b[D]|b[D+1]<<8)>>(E&7)&y},VE=function(b,E){var y=E/8|0;return(b[y]|b[y+1]<<8|b[y+2]<<16)>>(E&7)},M_e=function(b){return(b+7)/8|0},A_e=function(b,E,y){return(y==null||y>b.length)&&(y=b.length),new ms(b.subarray(E,y))}
1971,C_e=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],gs=function(b,E,y){var D=new Error(E||C_e[b]);if(D.code=b,Error.captureStackTrace&&Error.captureStackTrace(D,gs),!y)throw D;return D},ZE=function(b,E,y,D){var U=b.length,$=0;if(!U||E.f&&!E.l)return y||new ms(0);var oe=!y,de=oe||E.i!=2,Re=E.i;oe&&(y=new ms(U*3));var ye=function(WV){var KV=y.length;if(WV>KV){var GV=new ms(Math.max(KV*2,WV));GV.set(y),y=GV}},Ee=E.f||0,at=E.p||0,Pe=E.b||0,Le=E.l,Br=E.d,Lr=E.m,or=E.n,Gt=U*8;do{if(!Le){Ee=Zo(b,at,1);var Wt=Zo(b,at+1,3);if(at+=3,Wt)if(Wt==1)Le=k_e,Br=E_e,Lr=9,or=5;else if(Wt==2){var st=Zo(b,at,31)+257,Kt=Zo(b,at+10,15)+4,jn=st+Zo(b,at+5,31)+1;at+=14;for(var ur=new ms(jn),ir=new ms(19),lr=0;lr<Kt;++lr)ir[w_e[lr]]=Zo(b,at+lr*3,7);at+=Kt*3;for(var Ot=qE(ir),ar=(1<<Ot)-1,zi=z1(ir,Ot),lr=0;lr<jn;){var $l=zi[Zo(b,at,ar)];at+=$l&15;var bs=$l>>4;if(bs<16)ur[lr++]=bs;else{var $o=0,Wc=0;for(bs==16?(Wc=3+Zo(b,at,3),at+=2,$o=ur[lr-1]):bs==17?(Wc=3+Zo(b,at,7),at+=3):bs==18&&(Wc=11+Zo(b,at,127),at+=7);Wc--;)ur[lr++]=$o}}var VV=ur.subarray(0,st),Mf=ur.subarray(st);Lr=qE(VV),or=qE(Mf),Le=z1(VV,Lr),Br=z1(Mf,or)}else gs(1);else{var bs=M_e(at)+4,HE=b[bs-4]|b[bs-3]<<8,WE=bs+HE;if(WE>U){Re&&gs(0);break}de&&ye(Pe+HE),y.set(b.subarray(bs,WE),Pe),E.b=Pe+=HE,E.p=at=WE*8,E.f=Ee;continue}if(at>Gt){Re&&gs(0);break}}de&&ye(Pe+131072);for(var V_e=(1<<Lr)-1,Z_e=(1<<or)-1,KE=at;;KE=at){var $o=Le[VE(b,at)&V_e],Dp=$o>>4;if(at+=$o&15,at>Gt){Re&&gs(0);break}if($o||gs(2),Dp<256)y[Pe++]=Dp;else if(Dp==256){KE=at,Le=null;break}else{var ZV=Dp-254;if(Dp>264){var lr=Dp-257,D1=RV[lr];ZV=Zo(b,at,(1<<D1)-1)+zV[lr],at+=D1}var GE=Br[VE(b,at)&Z_e],YE=GE>>4;GE||gs(3),at+=GE&15;var Mf=S_e[YE];if(YE>3){var D1=NV[YE];Mf+=VE(b,at)&(1<<D1)-1,at+=D1}if(at>Gt){Re&&gs(0);break}de&&ye(Pe+131072);var $V=Pe+ZV;if(Pe<Mf){var HV=$-Mf,$_e=Math.min(Mf,$V);for(HV+Pe<0&&gs(3);Pe<$_e;++Pe)y[Pe]=D[HV+Pe]}for(;Pe<$V;++Pe)y[Pe]=y[Pe-Mf]}}E.l=Le,E.p=KE,E.b=Pe,E.f=Ee,Le&&(Ee=1,E.m=Lr,E.d=Br,E.n=or)}while(!Ee);return Pe!=y.length&&oe?A_e(y,0,Pe):y.subarray(0,Pe)},T_e=new ms(0),j_e=function(b){(b[0]!=31||b[1]!=139||b[2]!=8)&&gs(6,"invalid gzip data");var E=b[3],y=10;E&4&&(y+=(b[10]|b[11]<<8)+2);for(var D=(E>>3&1)+(E>>4&1);D>0;D-=!b[y++]);return y+(E&2)},I_e=function(b){var E=b.length;return(b[E-4]|b[E-3]<<8|b[E-2]<<16|b[E-1]<<24)>>>0},O_e=function(b,E){return((b[0]&15)!=8||b[0]>>4>7||(b[0]<<8|b[1])%31)&&gs(6,"invalid zlib data"),(b[1]>>5&1)==+!E&&gs(6,"invalid zlib data: "+(b[1]&32?"need":"unexpected")+" dictionary"),(b[1]>>3&4)+2};function B_e(b,E){return ZE(b,{i:2},E,E)}function R_e(b,E){var y=j_e(b);return y+8>b.length&&gs(6,"invalid gzip data"),ZE(b.subarray(y,-8),{i:2},new ms(I_e(b)),E)}function N_e(b,E){return ZE(b.subarray(O_e(b,E),-4),{i:2},E,E)}function K2(b,E){return b[0]==31&&b[1]==139&&b[2]==8?R_e(b,E):(b[0]&15)!=8||b[0]>>4>7||(b[0]<<8|b[1])%31?B_e(b,E):N_e(b,E)}typeof TextEncoder<"u"&&new TextEncoder;var F_e=typeof TextDecoder<"u"&&new TextDecoder,P_e=0;try{F_e.decode(T_e,{stream:!0}),P_e=1}catch{}var UV=Yt(764).lW;class z_e extends Error{constructor(E){super(E)}}class L_e{constructor(E,y={threads:1},D={recursive:!1}){this.backendOptions=y,this.circuitOptions=D,this.acirUncompressedBytecode=qV(E)}async instantiate(){if(!this.api){const E=await pd.new(this.backendOptions),y=!1,[D,U]=await E.acirGetCircuitSizes(this.acirUncompressedBytecode,this.circuitOptions.recursive,y);await E.initSRSForCircuitSize(U),this.acirComposer=await E.acirNewAcirComposer(U),await E.acirInitProvingKey(this.acirComposer,this.acirUncompressedBytecode,this.circuitOptions.recursive),this.api=E}}async generateProof(E){await this.instantiate();const y=await this.api.acirCreateProof(this.acirComposer,this.acirUncompressedBytecode,this.circuitOptions.recursive,K2(E)),D=y.length-2144,U=y.slice(0,D),$=y.slice(D),oe=W2(U);return{proof:$,publicInputs:oe}}async generateRecursiveProofArtifacts(E,y=0){await this.instantiate();const D=DE(E),U=(await this.api.acirSerializeProofIntoFields(this.acirComposer,D,y)).slice(y);await this.api.acirInitVerificationKey(this.acirComposer);const $=await this.api.acirSerializeVerificationKeyIntoFields(this.acirComposer);return{proofAsFields:U.map(oe=>oe.toString()),vkAsFields:$[0].map(oe=>oe.toString()),vkHash:$[1].toString()}}async verifyProof(E){await this.instantiate(),await this.api.acirInitVerificationKey(this.acirComposer);const y=DE(E);
1971return await this.api.acirVerifyProof(this.acirComposer,y)}async getVerificationKey(){return await this.instantiate(),await this.api.acirInitVerificationKey(this.acirComposer),await this.api.acirGetVerificationKey(this.acirComposer)}async getSolidityVerifier(){return await this.instantiate(),await this.api.acirInitVerificationKey(this.acirComposer),await this.api.acirGetSolidityVerifier(this.acirComposer)}async destroy(){this.api&&await this.api.destroy()}}class D_e{constructor(E,y={threads:1},D={recursive:!1}){this.backendOptions=y,this.circuitOptions=D,this.acirUncompressedBytecode=qV(E)}async instantiate(){if(!this.api){const E=await pd.new(this.backendOptions);await E.acirInitSRS(this.acirUncompressedBytecode,this.circuitOptions.recursive,!0),this.api=E}}async generateProof(E,y){await this.instantiate();const D=await(y!=null&&y.keccak?this.api.acirProveUltraKeccakHonk.bind(this.api):this.api.acirProveUltraHonk.bind(this.api))(this.acirUncompressedBytecode,this.circuitOptions.recursive,K2(E)),U=await(y!=null&&y.keccak?this.api.acirWriteVkUltraKeccakHonk.bind(this.api):this.api.acirWriteVkUltraHonk.bind(this.api))(this.acirUncompressedBytecode,this.circuitOptions.recursive),$=await this.api.acirVkAsFieldsUltraHonk(new V(U)),oe=Number($[1].toString()),{proof:de,publicInputs:Re}=zE(D,oe),ye=W2(Re);return{proof:de,publicInputs:ye}}async generateProofForRecursiveAggregation(E,y){await this.instantiate();const D=await(y!=null&&y.keccak?this.api.acirProveUltraKeccakHonk.bind(this.api):this.api.acirProveUltraHonk.bind(this.api))(this.acirUncompressedBytecode,this.circuitOptions.recursive,K2(E)),U=await(y!=null&&y.keccak?this.api.acirWriteVkUltraKeccakHonk.bind(this.api):this.api.acirWriteVkUltraHonk.bind(this.api))(this.acirUncompressedBytecode,this.circuitOptions.recursive),$=await this.api.acirVkAsFieldsUltraHonk(new V(U)),oe=Number($[1].toString())-16,{proof:de,publicInputs:Re}=zE(D,oe),ye=W2(Re);return{proof:W2(de),publicInputs:ye}}async verifyProof(E,y){await this.instantiate();const D=LE(UE(E.publicInputs),E.proof),U=y!=null&&y.keccak?this.api.acirWriteVkUltraKeccakHonk.bind(this.api):this.api.acirWriteVkUltraHonk.bind(this.api),$=y!=null&&y.keccak?this.api.acirVerifyUltraKeccakHonk.bind(this.api):this.api.acirVerifyUltraHonk.bind(this.api),oe=await U(this.acirUncompressedBytecode,this.circuitOptions.recursive);return await $(D,new V(oe))}async getVerificationKey(E){return await this.instantiate(),E!=null&&E.keccak?await this.api.acirWriteVkUltraKeccakHonk(this.acirUncompressedBytecode,this.circuitOptions.recursive):await this.api.acirWriteVkUltraHonk(this.acirUncompressedBytecode,this.circuitOptions.recursive)}async getSolidityVerifier(E){await this.instantiate();const y=E??await this.api.acirWriteVkUltraHonk(this.acirUncompressedBytecode,this.circuitOptions.recursive);return await this.api.acirHonkSolidityVerifier(this.acirUncompressedBytecode,new V(y))}async generateRecursiveProofArtifacts(E,y){await this.instantiate();const D=await this.api.acirWriteVkUltraHonk(this.acirUncompressedBytecode,this.circuitOptions.recursive),U=await this.api.acirVkAsFieldsUltraHonk(D);return{proofAsFields:[],vkAsFields:U.map($=>$.toString()),vkHash:""}}async destroy(){this.api&&await this.api.destroy()}}class U_e{constructor(E,y={threads:1}){this.acirMsgpack=E,this.options=y}async instantiate(){if(!this.api){const E=await pd.new(this.options);await E.initSRSClientIVC(),this.api=E}}async prove(E){await this.instantiate();const y=await this.api.acirProveAztecClient(this.acirMsgpack,E),[D,U]=y;if(!await this.verify(D,U))throw new z_e("Failed to verify the private (ClientIVC) transaction proof!");return y}async verify(E,y){return await this.instantiate(),this.api.acirVerifyAztecClient(E,y)}async proveAndVerify(E){return await this.instantiate(),this.api.acirProveAndVerifyAztecClient(this.acirMsgpack,E)}async gates(){return await this.instantiate(),this.api.acirGatesAztecClient(this.acirMsgpack)}async destroy(){this.api&&await this.api.destroy()}}function qV(b){const E=q_e(b);return K2(E)}function q_e(b){if(typeof UV<"u"){const E=UV.from(b,"base64");return new Uint8Array(E.buffer,E.byteOffset,E.byteLength)}else{if(typeof atob=="function")return Uint8Array.from(atob(b),E=>E.charCodeAt(0));throw new Error("No implementation found for base64 decoding.")}}class pd extends it{constructor(E,y,D){super(y),this.worker=E,this.options=D}static async new(E={}){var oe,de;const y=Je(),D=Bt(y),{module:U,threads:$}=await BV(E.threads,E.wasmPath,E.logger);
1971return await D.init(U,$,F(E.logger??wt()("bb.js:bb_wasm_async")),(oe=E.memory)==null?void 0:oe.initial,(de=E.memory)==null?void 0:de.maximum),new pd(y,D,E)}async getNumThreads(){return await this.wasm.getNumThreads()}async initSRSForCircuitSize(E){const y=await d.new(E+1,this.options.crsPath,this.options.logger);await this.srsInitSrs(new V(y.getG1Data()),y.numPoints,new V(y.getG2Data()))}async initSRSClientIVC(){const E=await d.new(1048577,this.options.crsPath,this.options.logger),y=await p.new(2**16+1,this.options.crsPath,this.options.logger);await this.srsInitSrs(new V(E.getG1Data()),E.numPoints,new V(E.getG2Data())),await this.srsInitGrumpkinSrs(new V(y.getG1Data()),y.numPoints)}async acirInitSRS(E,y,D){const[U,$]=await this.acirGetCircuitSizes(E,y,D);return this.initSRSForCircuitSize($)}async destroy(){await this.wasm.destroy(),await this.worker.terminate()}}let $E,G2;class Y2 extends Ve{constructor(E){super(E)}static async new(E,y=wt()("bb.js:bb_wasm_sync")){const D=new Mt,{module:U,threads:$}=await BV(1,E,y);return await D.init(U,$,y),new Y2(D)}static async initSingleton(E,y=wt()("bb.js:bb_wasm_sync")){return $E||($E=Y2.new(E,y)),G2=await $E,G2}static getSingleton(){if(!G2)throw new Error("First call BarretenbergSync.initSingleton() on @aztec/bb.js module.");return G2}getWasm(){return this.wasm}}})(),es.Dv,es.Zh;var js=es.AL;es.tD,es.i2;var h4=es.Fr;es.pS,es.ld,es.yh,es._7,es.H2,es.ly;var ct={},FO={},d4=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var e={},t=Symbol("test"),r=Object(t);if(typeof t=="string"||Object.prototype.toString.call(t)!=="[object Symbol]"||Object.prototype.toString.call(r)!=="[object Symbol]")return!1;var n=42;e[t]=n;for(var i in e)return!1;if(typeof Object.keys=="function"&&Object.keys(e).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(e).length!==0)return!1;var a=Object.getOwnPropertySymbols(e);if(a.length!==1||a[0]!==t||!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var s=Object.getOwnPropertyDescriptor(e,t);if(s.value!==n||s.enumerable!==!0)return!1}return!0},jie=d4,ww=function(){return jie()&&!!Symbol.toStringTag},Iie=Object,Oie=Error,Bie=EvalError,Rie=RangeError,Nie=ReferenceError,PO=SyntaxError,mc=TypeError,Fie=URIError,Pie=Math.abs,zie=Math.floor,Lie=Math.max,Die=Math.min,Uie=Math.pow,qie=Math.round,Vie=Number.isNaN||function(e){return e!==e},Zie=Vie,$ie=function(e){return Zie(e)||e===0?e:e<0?-1:1},Hie=Object.getOwnPropertyDescriptor,xw=Hie;if(xw)try{xw([],"length")}catch{xw=null}var h0=xw,_w=Object.defineProperty||!1;if(_w)try{_w({},"a",{value:1})}catch{_w=!1}var Iu=_w,p4,zO;function Wie(){if(zO)return p4;zO=1;var e=typeof Symbol<"u"&&Symbol,t=d4;return p4=function(){return typeof e!="function"||typeof Symbol!="function"||typeof e("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:t()},p4}var LO,DO;function UO(){return DO||(DO=1,LO=typeof Reflect<"u"&&Reflect.getPrototypeOf||null),LO}var qO,VO;function Kie(){return VO||(VO=1,qO=Object),qO}var m4,ZO;function $O(){if(ZO)return m4;ZO=1;var e=Kie();return m4=e.getPrototypeOf||null,m4}var Gie="Function.prototype.bind called on incompatible ",Yie=Object.prototype.toString,Xie=Math.max,Jie="[object Function]",HO=function(e,t){for(var r=[],n=0;n<e.length;n+=1)r[n]=e[n];for(var i=0;i<t.length;i+=1)r[i+e.length]=t[i];return r},Qie=function(e,t){for(var r=[],n=t,i=0;n<e.length;n+=1,i+=1)r[i]=e[n];return r},eae=function(e,t){for(var r="",n=0;n<e.length;n+=1)r+=e[n],n+1<e.length&&(r+=t);return r},tae=function(e){var t=this;if(typeof t!="function"||Yie.apply(t)!==Jie)throw new TypeError(Gie+t);for(var r=Qie(arguments,1),n,i=function(){if(this instanceof n){var l=t.apply(this,HO(r,arguments));return Object(l)===l?l:this}return t.apply(e,HO(r,arguments))},a=Xie(0,t.length-r.length),s=[],o=0;o<a;o++)s[o]="$"+o;if(n=Function("binder","return function ("+eae(s,",")+"){ return binder.apply(this,arguments); }")(i),t.prototype){var c=function(){};c.prototype=t.prototype,n.prototype=new c,c.prototype=null}return n},rae=tae,gc=Function.prototype.bind||rae,g4=Function.prototype.call,b4=Function.prototype.apply,nae=typeof Reflect<"u"&&Reflect&&Reflect.apply,iae=gc,aae=b4,s
1971ae=g4,oae=nae,WO=oae||iae.call(sae,aae),lae=gc,cae=mc,uae=g4,fae=WO,y4=function(e){if(e.length<1||typeof e[0]!="function")throw new cae("a function is required");return fae(lae,uae,e)},v4,KO;function hae(){if(KO)return v4;KO=1;var e=y4,t=h0,r;try{r=[].__proto__===Array.prototype}catch(s){if(!s||typeof s!="object"||!("code"in s)||s.code!=="ERR_PROTO_ACCESS")throw s}var n=!!r&&t&&t(Object.prototype,"__proto__"),i=Object,a=i.getPrototypeOf;return v4=n&&typeof n.get=="function"?e([n.get]):typeof a=="function"?function(s){return a(s==null?s:i(s))}:!1,v4}var w4,GO;function YO(){if(GO)return w4;GO=1;var e=UO(),t=$O(),r=hae();return w4=e?function(n){return e(n)}:t?function(n){if(!n||typeof n!="object"&&typeof n!="function")throw new TypeError("getProto: not an object");return t(n)}:r?function(n){return r(n)}:null,w4}var dae=Function.prototype.call,pae=Object.prototype.hasOwnProperty,mae=gc,XO=mae.call(dae,pae),mr,gae=Iie,bae=Oie,yae=Bie,vae=Rie,wae=Nie,d0=PO,p0=mc,xae=Fie,_ae=Pie,Sae=zie,kae=Lie,Eae=Die,Mae=Uie,Aae=qie,Cae=$ie,JO=Function,x4=function(e){try{return JO('"use strict"; return ('+e+").constructor;")()}catch{}},Mg=h0,Tae=Iu,_4=function(){throw new p0},jae=Mg?function(){try{return arguments.callee,_4}catch{try{return Mg(arguments,"callee").get}catch{return _4}}}():_4,m0=Wie()(),gi=YO(),Iae=$O(),Oae=UO(),QO=b4,Ag=g4,g0={},Bae=typeof Uint8Array>"u"||!gi?mr:gi(Uint8Array),uh={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?mr:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?mr:ArrayBuffer,"%ArrayIteratorPrototype%":m0&&gi?gi([][Symbol.iterator]()):mr,"%AsyncFromSyncIteratorPrototype%":mr,"%AsyncFunction%":g0,"%AsyncGenerator%":g0,"%AsyncGeneratorFunction%":g0,"%AsyncIteratorPrototype%":g0,"%Atomics%":typeof Atomics>"u"?mr:Atomics,"%BigInt%":typeof BigInt>"u"?mr:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?mr:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?mr:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?mr:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":bae,"%eval%":eval,"%EvalError%":yae,"%Float16Array%":typeof Float16Array>"u"?mr:Float16Array,"%Float32Array%":typeof Float32Array>"u"?mr:Float32Array,"%Float64Array%":typeof Float64Array>"u"?mr:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?mr:FinalizationRegistry,"%Function%":JO,"%GeneratorFunction%":g0,"%Int8Array%":typeof Int8Array>"u"?mr:Int8Array,"%Int16Array%":typeof Int16Array>"u"?mr:Int16Array,"%Int32Array%":typeof Int32Array>
vendor: 5,753 bytes, line 1971
1971"u"?mr:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":m0&&gi?gi(gi([][Symbol.iterator]())):mr,"%JSON%":typeof JSON=="object"?JSON:mr,"%Map%":typeof Map>"u"?mr:Map,"%MapIteratorPrototype%":typeof Map>"u"||!m0||!gi?mr:gi(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":gae,"%Object.getOwnPropertyDescriptor%":Mg,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?mr:Promise,"%Proxy%":typeof Proxy>"u"?mr:Proxy,"%RangeError%":vae,"%ReferenceError%":wae,"%Reflect%":typeof Reflect>"u"?mr:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?mr:Set,"%SetIteratorPrototype%":typeof Set>"u"||!m0||!gi?mr:gi(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?mr:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":m0&&gi?gi(""[Symbol.iterator]()):mr,"%Symbol%":m0?Symbol:mr,"%SyntaxError%":d0,"%ThrowTypeError%":jae,"%TypedArray%":Bae,"%TypeError%":p0,"%Uint8Array%":typeof Uint8Array>"u"?mr:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?mr:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?mr:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?mr:Uint32Array,"%URIError%":xae,"%WeakMap%":typeof WeakMap>"u"?mr:WeakMap,"%WeakRef%":typeof WeakRef>"u"?mr:WeakRef,"%WeakSet%":typeof WeakSet>"u"?mr:WeakSet,"%Function.prototype.call%":Ag,"%Function.prototype.apply%":QO,"%Object.defineProperty%":Tae,"%Object.getPrototypeOf%":Iae,"%Math.abs%":_ae,"%Math.floor%":Sae,"%Math.max%":kae,"%Math.min%":Eae,"%Math.pow%":Mae,"%Math.round%":Aae,"%Math.sign%":Cae,"%Reflect.getPrototypeOf%":Oae};if(gi)try{null.error}catch(e){var Rae=gi(gi(e));uh["%Error.prototype%"]=Rae}var Nae=function e(t){var r;if(t==="%AsyncFunction%")r=x4("async function () {}");else if(t==="%GeneratorFunction%")r=x4("function* () {}");else if(t==="%AsyncGeneratorFunction%")r=x4("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if(t==="%AsyncIteratorPrototype%"){var i=e("%AsyncGenerator%");i&&gi&&(r=gi(i.prototype))}return uh[t]=r,r},eB={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Cg=gc,Sw=XO,Fae=Cg.call(Ag,Array.prototype.concat),Pae=Cg.call(QO,Array.prototype.splice),tB=Cg.call(Ag,String.prototype.replace),kw=Cg.call(Ag,String.prototype.slice),zae=Cg.call(Ag,RegExp.prototype.exec),Lae=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,Dae=/\\(\\)?/g,Uae=function(e){var t=kw(e,0,1),r=kw(e,-1);if(t==="%"&&r!=="%")throw new d0("invalid intrinsic syntax, expected closing `%`");if(r==="%"&&t!=="%")throw new d0("invalid intrinsic syntax, expected opening `%`");var n=[];return tB(e,Lae,function(i,a,s,o){n[n.length]=s?tB(o,Dae,"$1"):a||i}),n},qae=function(e,t){var r=e,n;if(Sw(eB,r)&&(n=eB[r],r="%"+n[0]+"%"),Sw(uh,r)){var i=uh[r];if(i===g0&&(i=Nae(r)),typeof i>"u"&&!t)throw new p0("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:n,name:r,value:i}}throw new d0("intrinsic "+e+" does not exist!")},al=function(e,t){if(typeof e!="string"||e.length===0)throw new p0("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof t!="boolean")throw new p0('"allowMissing" argument must be a boolean');
1971if(zae(/^%?[^%]*%?$/,e)===null)throw new d0("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=Uae(e),n=r.length>0?r[0]:"",i=qae("%"+n+"%",t),a=i.name,s=i.value,o=!1,c=i.alias;c&&(n=c[0],Pae(r,Fae([0,1],c)));for(var l=1,u=!0;l<r.length;l+=1){var d=r[l],p=kw(d,0,1),w=kw(d,-1);if((p==='"'||p==="'"||p==="`"||w==='"'||w==="'"||w==="`")&&p!==w)throw new d0("property names with quotes must have matching quotes");if((d==="constructor"||!u)&&(o=!0),n+="."+d,a="%"+n+"%",Sw(uh,a))s=uh[a];else if(s!=null){if(!(d in s)){if(!t)throw new p0("base intrinsic for "+e+" exists, but the property is not available.");return}if(Mg&&l+1>=r.length){var O=Mg(s,d);u=!!O,u&&"get"in O&&!("originalValue"in O.get)?s=O.get:s=s[d]}else u=Sw(s,d),s=s[d];u&&!o&&(uh[a]=s)}}return s},rB={exports:{}},nB=Iu,Vae=PO,b0=mc,iB=h0,aB=function(e,t,r){if(!e||typeof e!="object"&&typeof e!="function")throw new b0("`obj` must be an object or a function`");if(typeof t!="string"&&typeof t!="symbol")throw new b0("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new b0("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new b0("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new b0("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new b0("`loose`, if provided, must be a boolean");var n=arguments.length>3?arguments[3]:null,i=arguments.length>4?arguments[4]:null,a=arguments.length>5?arguments[5]:null,s=arguments.length>6?arguments[6]:!1,o=!!iB&&iB(e,t);if(nB)nB(e,t,{configurable:a===null&&o?o.configurable:!a,enumerable:n===null&&o?o.enumerable:!n,value:r,writable:i===null&&o?o.writable:!i});else if(s||!n&&!i&&!a)e[t]=r;else throw new Vae("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},S4=Iu,sB=function(){return!!S4};sB.hasArrayLengthDefineBug=function(){if(!S4)return null;try{return S4([],"length",{value:1}).length!==1}catch{return!0}};var oB=sB,Zae=al,lB=aB,$ae=oB(),cB=h0,uB=mc,Hae=Zae("%Math.floor%"),Tg=function(e,t){if(typeof e!="function")throw new uB("`fn` is not a function");if(typeof t!="number"||t<0||t>4294967295||Hae(t)!==t)throw new uB("`length` must be a positive 32-bit integer");var r=arguments.length>2&&!!arguments[2],n=!0,i=!0;if("length"in e&&cB){var a=cB(e,"length");a&&!a.configurable&&(n=!1),a&&!a.writable&&(i=!1)}return(n||i||!r)&&($ae?lB(e,"length",t,!0,!0):lB(e,"length",t)),e};(function(e){var t=gc,r=al,n=Tg,i=mc,a=r("%Function.prototype.apply%"),s=r("%Function.prototype.call%"),o=r("%Reflect.apply%",!0)||t.call(s,a),c=Iu,l=r("%Math.max%");e.exports=function(d){if(typeof d!="function")throw new i("a function is required");var p=o(t,s,arguments);return n(p,1+l(0,d.length-(arguments.length-1)),!0)};var u=function(){return o(t,a,arguments)};c?c(e.exports,"apply",{value:u}):e.exports.apply=u})(rB);var Wae=rB.exports,fB=al,hB=Wae,Kae=hB(fB("String.prototype.indexOf")),Gae=function(e,t){var r=fB(e,!!t);return typeof r=="function"&&Kae(e,".prototype.")>-1?hB(r):r},Yae=ww(),Xae=Gae,k4=Xae("Object.prototype.toString"),Ew=function(e){return Yae&&e&&typeof e=="object"&&Symbol.toStringTag in e?!1:k4(e)==="[object Arguments]"},dB=function(e){return Ew(e)?!0:e!==null&&typeof e=="object"&&typeof e.length=="number"&&e.length>=0&&k4(e)!=="[object Array]"&&k4(e.callee)==="[object Function]"},Jae=function(){return Ew(arguments)}();Ew.isLegacyArguments=dB;var Qae=Jae?Ew:dB,pB=al,mB=y4,ese=mB([pB("%String.prototype.indexOf%")]),E4=function(e,t){var r=pB(e,!!t);return typeof r=="function"&&ese(e,".prototype.")>-1?mB([r]):r},gB=E4,tse=ww(),rse=XO,nse=h0,M4;if(tse){var ise=gB("RegExp.prototype.exec"),bB={},A4=function(){throw bB},yB={toString:A4,valueOf:A4};typeof Symbol.toPrimitive=="symbol"&&(yB[Symbol.toPrimitive]=A4),M4=function(e){if(!e||typeof e!="object")return!1;var t=nse(e,"lastIndex"),r=t&&rse(t,"value");if(!r)return!1;try{ise(e,yB)}catch(n){return n===bB}
1971}}else{var ase=gB("Object.prototype.toString"),sse="[object RegExp]";M4=function(e){return!e||typeof e!="object"&&typeof e!="function"?!1:ase(e)===sse}}var ose=M4,lse=E4,cse=ose,use=lse("RegExp.prototype.exec"),fse=mc,hse=function(e){if(!cse(e))throw new fse("`regex` must be a RegExp");return function(t){return use(e,t)!==null}},vB=E4,dse=hse,pse=dse(/^\s*(?:function)?\*/),wB=ww(),C4=YO(),mse=vB("Object.prototype.toString"),gse=vB("Function.prototype.toString"),bse=function(){if(!wB)return!1;try{return Function("return function*() {}")()}catch{}},T4,yse=function(e){if(typeof e!="function")return!1;if(pse(gse(e)))return!0;if(!wB){var t=mse(e);return t==="[object GeneratorFunction]"}if(!C4)return!1;if(typeof T4>"u"){var r=bse();T4=r?C4(r):!1}return C4(e)===T4},xB=Function.prototype.toString,y0=typeof Reflect=="object"&&Reflect!==null&&Reflect.apply,j4,Mw;if(typeof y0=="function"&&typeof Object.defineProperty=="function")try{j4=Object.defineProperty({},"length",{get:function(){throw Mw}}),Mw={},y0(function(){throw 42},null,j4)}catch(e){e!==Mw&&(y0=null)}else y0=null;var vse=/^\s*class\b/,I4=function(e){try{var t=xB.call(e);return vse.test(t)}catch{return!1}},O4=function(e){try{return I4(e)?!1:(xB.call(e),!0)}catch{return!1}},Aw=Object.prototype.toString,wse="[object Object]",xse="[object Function]",_se="[object GeneratorFunction]",Sse="[object HTMLAllCollection]",kse="[object HTML document.all class]",Ese="[object HTMLCollection]",Mse=typeof Symbol=="function"&&!!Symbol.toStringTag,Ase=!(0 in[,]),B4=function(){return!1};if(typeof document=="object"){var Cse=document.all;Aw.call(Cse)===Aw.call(document.all)&&(B4=function(e){if((Ase||!e)&&(typeof e>"u"||typeof e=="object"))try{var t=Aw.call(e);return(t===Sse||t===kse||t===Ese||t===wse)&&e("")==null}catch{}return!1})}var Tse=y0?function(e){if(B4(e))return!0;if(!e||typeof e!="function"&&typeof e!="object")return!1;try{y0(e,null,j4)}catch(t){if(t!==Mw)return!1}return!I4(e)&&O4(e)}:function(e){if(B4(e))return!0;if(!e||typeof e!="function"&&typeof e!="object")return!1;if(Mse)return O4(e);if(I4(e))return!1;var t=Aw.call(e);return t!==xse&&t!==_se&&!/^\[object HTML/.test(t)?!1:O4(e)},jse=Tse,Ise=Object.prototype.toString,_B=Object.prototype.hasOwnProperty,Ose=function(e,t,r){for(var n=0,i=e.length;n<i;n++)_B.call(e,n)&&(r==null?t(e[n],n,e):t.call(r,e[n],n,e))},Bse=function(e,t,r){for(var n=0,i=e.length;n<i;n++)r==null?t(e.charAt(n),n,e):t.call(r,e.charAt(n),n,e)},Rse=function(e,t,r){for(var n in e)_B.call(e,n)&&(r==null?t(e[n],n,e):t.call(r,e[n],n,e))},Nse=function(e,t,r){if(!jse(t))throw new TypeError("iterator must be a function");var n;arguments.length>=3&&(n=r),Ise.call(e)==="[object Array]"?Ose(e,t,n):typeof e=="string"?Bse(e,t,n):Rse(e,t,n)},Fse=Nse,Pse=["Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"],R4=Pse,zse=typeof globalThis>"u"?dt:globalThis,Lse=function(){for(var e=[],t=0;t<R4.length;t++)typeof zse[R4[t]]=="function"&&(e[e.length]=R4[t]);return e}
1971,SB={exports:{}},Dse=gc,Use=b4,qse=WO,Vse=function(){return qse(Dse,Use,arguments)};(function(e){var t=Tg,r=Iu,n=y4,i=Vse;e.exports=function(a){var s=n(arguments),o=a.length-(arguments.length-1);return t(s,1+(o>0?o:0),!0)},r?r(e.exports,"apply",{value:i}):e.exports.apply=i})(SB);var N4=SB.exports,kB=al,EB=N4,Zse=EB(kB("String.prototype.indexOf")),$se=function(e,t){var r=kB(e,!!t);return typeof r=="function"&&Zse(e,".prototype.")>-1?EB(r):r},Cw=Fse,Hse=Lse,MB=N4,F4=$se,Tw=h0,Wse=F4("Object.prototype.toString"),AB=ww(),CB=typeof globalThis>"u"?dt:globalThis,P4=Hse(),z4=F4("String.prototype.slice"),L4=Object.getPrototypeOf,Kse=F4("Array.prototype.indexOf",!0)||function(e,t){for(var r=0;r<e.length;r+=1)if(e[r]===t)return r;return-1},jw={__proto__:null};AB&&Tw&&L4?Cw(P4,function(e){var t=new CB[e];if(Symbol.toStringTag in t){var r=L4(t),n=Tw(r,Symbol.toStringTag);if(!n){var i=L4(r);n=Tw(i,Symbol.toStringTag)}jw["$"+e]=MB(n.get)}}):Cw(P4,function(e){var t=new CB[e],r=t.slice||t.set;r&&(jw["$"+e]=MB(r))});var Gse=function(e){var t=!1;return Cw(jw,function(r,n){if(!t)try{"$"+r(e)===n&&(t=z4(n,1))}catch{}}),t},Yse=function(e){var t=!1;return Cw(jw,function(r,n){if(!t)try{r(e),t=z4(n,1)}catch{}}),t},TB=function(e){if(!e||typeof e!="object")return!1;if(!AB){var t=z4(Wse(e),8,-1);return Kse(P4,t)>-1?t:t!=="Object"?!1:Yse(e)}return Tw?Gse(e):null},Xse=TB,Jse=function(e){return!!Xse(e)};(function(e){var t=Qae,r=yse,n=TB,i=Jse;function a(Ae){return Ae.call.bind(Ae)}var s=typeof BigInt<"u",o=typeof Symbol<"u",c=a(Object.prototype.toString),l=a(Number.prototype.valueOf),u=a(String.prototype.valueOf),d=a(Boolean.prototype.valueOf);if(s)var p=a(BigInt.prototype.valueOf);if(o)var w=a(Symbol.prototype.valueOf);function O(Ae,De){if(typeof Ae!="object")return!1;try{return De(Ae),!0}catch{return!1}}e.isArgumentsObject=t,e.isGeneratorFunction=r,e.isTypedArray=i;function I(Ae){return typeof Promise<"u"&&Ae instanceof Promise||Ae!==null&&typeof Ae=="object"&&typeof Ae.then=="function"&&typeof Ae.catch=="function"}e.isPromise=I;function R(Ae){return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?ArrayBuffer.isView(Ae):i(Ae)||Q(Ae)}e.isArrayBufferView=R;function C(Ae){return n(Ae)==="Uint8Array"}e.isUint8Array=C;function j(Ae){return n(Ae)==="Uint8ClampedArray"}e.isUint8ClampedArray=j;function N(Ae){return n(Ae)==="Uint16Array"}e.isUint16Array=N;function P(Ae){return n(Ae)==="Uint32Array"}e.isUint32Array=P;function Z(Ae){return n(Ae)==="Int8Array"}e.isInt8Array=Z;function X(Ae){return n(Ae)==="Int16Array"}e.isInt16Array=X;function re(Ae){return n(Ae)==="Int32Array"}e.isInt32Array=re;function ne(Ae){return n(Ae)==="Float32Array"}e.isFloat32Array=ne;function ae(Ae){return n(Ae)==="Float64Array"}e.isFloat64Array=ae;function ue(Ae){return n(Ae)==="BigInt64Array"}e.isBigInt64Array=ue;function m(Ae){return n(Ae)==="BigUint64Array"}e.isBigUint64Array=m;function A(Ae){return c(Ae)==="[object Map]"}A.working=typeof Map<"u"&&A(new Map);function f(Ae){return typeof Map>"u"?!1:A.working?A(Ae):Ae instanceof Map}e.isMap=f;function g(Ae){return c(Ae)==="[object Set]"}g.working=typeof Set<"u"&&g(new Set);function _(Ae){return typeof Set>"u"?!1:g.working?g(Ae):Ae instanceof Set}e.isSet=_;function B(Ae){return c(Ae)==="[object WeakMap]"}B.working=typeof WeakMap<"u"&&B(new WeakMap);function T(Ae){return typeof WeakMap>"u"?!1:B.working?B(Ae):Ae instanceof WeakMap}e.isWeakMap=T;function S(Ae){return c(Ae)==="[object WeakSet]"}S.working=typeof WeakSet<"u"&&S(new WeakSet);function h(Ae){return S(Ae)}e.isWeakSet=h;function x(Ae){return c(Ae)==="[object ArrayBuffer]"}x.working=typeof ArrayBuffer<"u"&&x(new ArrayBuffer);function v(Ae){return typeof ArrayBuffer>"u"?!1:x.working?x(Ae):Ae instanceof ArrayBuffer}e.isArrayBuffer=v;function F(Ae){return c(Ae)==="[object DataView]"}F.working=typeof ArrayBuffer<"u"&&typeof DataView<"u"&&F(new DataView(new ArrayBuffer(1),0,1));function Q(Ae){return typeof DataView>"u"?!1:F.working?F(Ae):Ae instanceof DataView}e.isDataView=Q;var G=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:void 0;function J(Ae){return c(Ae)==="[object SharedArrayBuffer]"}function Y(Ae){return typeof G>"u"?!1:(typeof J.working>"u"&&(J.working=J(new G)),J.working?J(Ae):Ae instanceof G)}e.isSharedArrayBuffer=Y;function V(Ae){return c(Ae)==="[object AsyncFunction]"}e.isAsyncFunction=V;function W(Ae){return c(Ae)==="[object Map Iterator]"}e.isMapIterator=W;function ce(Ae){return c(Ae)==="[object Set Iterator]"}e.isSetIterator=ce;function pe(Ae){return c(Ae)==="[object Generator]"}e.isGeneratorObject=pe;function ee(Ae){return c(Ae)==="[object WebAssembly.Module]"}e.isWebAssemblyCompiledModule=ee;function se(Ae){return O(Ae,l)}e.isNumberObject=se;function ve(Ae){return O(Ae,u)}e.isStringObject=ve;function _e(Ae){return O(Ae,d)}e.isBooleanObject=_e;function Ue(Ae){return s&&O(Ae,p)}e.isBigIntObject=Ue;function xe(Ae){return o&&O(Ae,w)}e.isSymbolObject=xe;function Te(Ae){return se(Ae)||ve(Ae)||_e(Ae)||Ue(Ae)||xe(Ae)}e.isBoxedPrimitive=Te;function $e(Ae){return typeof Uint8Array<"u"&&(v(Ae)||Y(Ae))}e.isAnyArrayBuffer=$e,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(Ae){Object.defineProperty(e,Ae,{enumerable:!1,value:function(){throw new Error(Ae+" is not supported in userland")}})})})(FO);var Qse=function(e){return e&&typeof e=="object"&&typeof e.copy=="function"&&typeof e.fill=="function"&&typeof e.readUInt8=="function"},D4={exports:{}};typeof Object.create=="function"?D4.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:D4.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}};var Zt=D4.exports;(function(e){var t={},r=Object.getOwnPropertyDescriptors||function(Q){for(var G=Object.keys(Q),J={},Y=0;Y<G.length;Y++)J[G[Y]]=Object.getOwnPropertyDescriptor(Q,G[Y]);return J},n=/%[sdj%]/g;e.format=function(Q){if(!X(Q)){for(var G=[],J=0;J<arguments.length;J++)G.push(o(arguments[J]));return G.join(" ")}for(var J=1,Y=arguments,V=Y.length,W=String(Q).replace(n,function(ee){if(ee==="%%")return"%";if(J>=V)return ee;switch(ee){case"%s":return String(Y[J++]);case"%d":return Number(Y[J++]);case"%j":try{return JSON.stringify(Y[J++])}catch{return"[Circular]"}default:return ee}}),ce=Y[J];J<V;ce=Y[++J])N(ce)||!ue(ce)?W+=" "+ce:W+=" "+o(ce);return W},e.deprecate=function(Q,G){if(typeof ot<"u"&&ot.noDeprecation===!0)return Q;if(typeof ot>"u")return function(){return e.deprecate(Q,G).apply(this,arguments)};var J=!1;function Y(){if(!J){if(ot.throwDeprecation)throw new Error(G);ot.traceDeprecation?console.trace(G):console.error(G),J=!0}return Q.apply(this,arguments)}return Y};var i={},a=/^$/;if(t.NODE_DEBUG){var s=t.NODE_DEBUG;s=s.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),a=new RegExp("^"+s+"$","i")}e.debuglog=function(Q){if(Q=Q.toUpperCase(),!i[Q])if(a.test(Q)){var G=ot.pid;i[Q]=function(){var J=e.format.apply(e,arguments);console.error("%s %d: %s",Q,G,J)}}else i[Q]=function(){};return i[Q]};function o(Q,G){var J={seen:[],stylize:l};return arguments.length>=3&&(J.depth=arguments[2]),arguments.length>=4&&(J.colors=arguments[3]),j(G)?J.showHidden=G:G&&e._extend(J,G),ne(J.showHidden)&&(J.showHidden=!1),ne(J.depth)&&(J.depth=2),ne(J.colors)&&(J.colors=!1),ne(J.customInspect)&&(J.customInspect=!0),J.colors&&(J.stylize=c),d(J,Q,J.depth)}e.inspect=o,o.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},o.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function c(Q,G){var J=o.styles[G];return J?"\x1B["+o.colors[J][0]+"m"+Q+"\x1B["+o.colors[J][1]+"m":Q}function l(Q,G){return Q}function u(Q){var G={};return Q.forEach(function(J,Y){G[J]=!0}),G}function d(Q,G,J){if(Q.customInspect&&G&&f(G.inspect)&&G.inspect!==e.inspect&&!(G.constructor&&G.constructor.prototype===G)){var Y=G.inspect(J,Q);return X(Y)||(Y=d(Q,Y,J)),Y}var V=p(Q,G);if(V)return V;var W=Object.keys(G),ce=u(W);if(Q.showHidden&&(W=Object.getOwnPropertyNames(G)),A(G)&&(W.indexOf("message")>=0||W.indexOf("description")>=0))return w(G);if(W.length===0){if(f(G)){var pe=G.name?": "+G.name:"";return Q.stylize("[Function"+pe+"]","special")}if(ae(G))return Q.stylize(RegExp.prototype.toString.call(G),"regexp");if(m(G))return Q.stylize(Date.prototype.toString.call(G),"date");if(A(G))return w(G)}var ee="",se=!1,ve=["{","}"];if(C(G)&&(se=!0,ve=["[","]"]),f(G)){var _e=G.name?": "+G.name:"";ee=" [Function"+_e+"]"}if(ae(G)&&(ee=" "+RegExp.prototype.toString.call(G)),m(G)&&(ee=" "+Date.prototype.toUTCString.call(G)),A(G)&&(ee=" "+w(G)),W.length===0&&(!se||G.length==0))return ve[0]+ee+ve[1];if(J<0)return ae(G)?Q.stylize(RegExp.prototype.toString.call(G),"regexp"):Q.stylize("[Object]","special");Q.seen.push(G);var Ue;return se?Ue=O(Q,G,J,ce,W):Ue=W.map(function(xe){return I(Q,G,J,ce,xe,se)}),Q.seen.pop(),R(Ue,ee,ve)}function p(Q,G){if(ne(G))return Q.stylize("undefined","undefined");if(X(G)){var J="'"+JSON.stringify(G).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return Q.stylize(J,"string")}if(Z(G))return Q.stylize(""+G,"number");if(j(G))return Q.stylize(""+G,"boolean");if(N(G))return Q.stylize("null","null")}function w(Q){return"["+Error.prototype.toString.call(Q)+"]"}function O(Q,G,J,Y,V){for(var W=[],ce=0,pe=G.length;ce<pe;++ce)h(G,String(ce))?W.push(I(Q,G,J,Y,String(ce),!0)):W.push("");
1971return V.forEach(function(ee){ee.match(/^\d+$/)||W.push(I(Q,G,J,Y,ee,!0))}),W}function I(Q,G,J,Y,V,W){var ce,pe,ee;if(ee=Object.getOwnPropertyDescriptor(G,V)||{value:G[V]},ee.get?ee.set?pe=Q.stylize("[Getter/Setter]","special"):pe=Q.stylize("[Getter]","special"):ee.set&&(pe=Q.stylize("[Setter]","special")),h(Y,V)||(ce="["+V+"]"),pe||(Q.seen.indexOf(ee.value)<0?(N(J)?pe=d(Q,ee.value,null):pe=d(Q,ee.value,J-1),pe.indexOf(`
1972`)>-1&&(W?pe=pe.split(`
1973`).map(function(se){return"  "+se}).join(`
1974`).slice(2):pe=`
1975`+pe.split(`
1976`).map(function(se){return"   "+se}).join(`
1977`))):pe=Q.stylize("[Circular]","special")),ne(ce)){if(W&&V.match(/^\d+$/))return pe;ce=JSON.stringify(""+V),ce.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(ce=ce.slice(1,-1),ce=Q.stylize(ce,"name")):(ce=ce.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),ce=Q.stylize(ce,"string"))}return ce+": "+pe}function R(Q,G,J){var Y=Q.reduce(function(V,W){return W.indexOf(`
1978`)>=0,V+W.replace(/\u001b\[\d\d?m/g,"").length+1},0);return Y>60?J[0]+(G===""?"":G+`
1979 `)+" "+Q.join(`,
1980  `)+" "+J[1]:J[0]+G+" "+Q.join(", ")+" "+J[1]}e.types=FO;function C(Q){return Array.isArray(Q)}e.isArray=C;function j(Q){return typeof Q=="boolean"}e.isBoolean=j;function N(Q){return Q===null}e.isNull=N;function P(Q){return Q==null}e.isNullOrUndefined=P;function Z(Q){return typeof Q=="number"}e.isNumber=Z;function X(Q){return typeof Q=="string"}e.isString=X;function re(Q){return typeof Q=="symbol"}e.isSymbol=re;function ne(Q){return Q===void 0}e.isUndefined=ne;function ae(Q){return ue(Q)&&_(Q)==="[object RegExp]"}e.isRegExp=ae,e.types.isRegExp=ae;function ue(Q){return typeof Q=="object"&&Q!==null}e.isObject=ue;function m(Q){return ue(Q)&&_(Q)==="[object Date]"}e.isDate=m,e.types.isDate=m;function A(Q){return ue(Q)&&(_(Q)==="[object Error]"||Q instanceof Error)}e.isError=A,e.types.isNativeError=A;function f(Q){return typeof Q=="function"}e.isFunction=f;function g(Q){return Q===null||typeof Q=="boolean"||typeof Q=="number"||typeof Q=="string"||typeof Q=="symbol"||typeof Q>"u"}e.isPrimitive=g,e.isBuffer=Qse;function _(Q){return Object.prototype.toString.call(Q)}function B(Q){return Q<10?"0"+Q.toString(10):Q.toString(10)}var T=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function S(){var Q=new Date,G=[B(Q.getHours()),B(Q.getMinutes()),B(Q.getSeconds())].join(":");return[Q.getDate(),T[Q.getMonth()],G].join(" ")}e.log=function(){console.log("%s - %s",S(),e.format.apply(e,arguments))},e.inherits=Zt,e._extend=function(Q,G){if(!G||!ue(G))return Q;for(var J=Object.keys(G),Y=J.length;Y--;)Q[J[Y]]=G[J[Y]];return Q};function h(Q,G){return Object.prototype.hasOwnProperty.call(Q,G)}var x=typeof Symbol<"u"?Symbol("util.promisify.custom"):void 0;e.promisify=function(Q){if(typeof Q!="function")throw new TypeError('The "original" argument must be of type Function');if(x&&Q[x]){var G=Q[x];if(typeof G!="function")throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(G,x,{value:G,enumerable:!1,writable:!1,configurable:!0}),G}function G(){for(var J,Y,V=new Promise(function(pe,ee){J=pe,Y=ee}),W=[],ce=0;ce<arguments.length;ce++)W.push(arguments[ce]);W.push(function(pe,ee){pe?Y(pe):J(ee)});try{Q.apply(this,W)}catch(pe){Y(pe)}return V}return Object.setPrototypeOf(G,Object.getPrototypeOf(Q)),x&&Object.defineProperty(G,x,{value:G,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(G,r(Q))},e.promisify.custom=x;function v(Q,G){if(!Q){var J=new Error("Promise was rejected with a falsy value");J.reason=Q,Q=J}return G(Q)}function F(Q){if(typeof Q!="function")throw new TypeError('The "original" argument must be of type Function');function G(){for(var J=[],Y=0;Y<arguments.length;Y++)J.push(arguments[Y]);var V=J.pop();if(typeof V!="function")throw new TypeError("The last argument must be of type Function");var W=this,ce=function(){return V.apply(W,arguments)};Q.apply(this,J).then(function(pe){ot.nextTick(ce.bind(null,null,pe))},function(pe){ot.nextTick(v.bind(null,pe,ce))})}return Object.setPrototypeOf(G,Object.getPrototypeOf(Q)),Object.defineProperties(G,r(Q)),G}e.callbackify=F})(ct);function co(e){const t=e.toString("hex");return t.length===0?BigInt(0):BigInt(`0x${t}`)}function Ca(e,t){if(e<BigInt(0))throw new Error(`Cannot convert negative bigint ${e.toString()} to buffer with toBufferBE.`);const r=e.toString(16),n=je.from(r.padStart(t*2,"0").slice(0,t*2),"hex");if(n.length>t)throw new Error(`Number ${e.toString(16)} does not fit in ${t}`);return n}function jB(e){if(!/^(0x)?[0-9a-fA-F]*$/.test(e)||e.length%2!==0)throw new Error(`Invalid hex string: ${e}`);return je.from(e.replace(/^0x/i,""),"hex")}var tr={},U4={exports:{}},q4={exports:{}};const ji=Cf(hG);(function(e,t){var r=ji,n=r.Buffer;function i(s,o){for(var c in s)o[c]=s[c]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=r:(i(r,t),t.Buffer=a);function a(s,o,c){return n(s,o,c)}a.prototype=Object.create(n.prototype),i(n,a),a.from=function(s,o,c){if(typeof s=="number")throw new TypeError("Argument must not be a number");return n(s,o,c)},a.alloc=function(s,o,c){if(typeof s!="number")throw new TypeError("Argument must be a number");var l=n(s);
vendor: 4,567 bytes, lines 1980-1981
1980return o!==void 0?typeof c=="string"?l.fill(o,c):l.fill(o):l.fill(0),l},a.allocUnsafe=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return n(s)},a.allocUnsafeSlow=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(s)}})(q4,q4.exports);var Qt=q4.exports,V4=65536,eoe=4294967295;function toe(){throw new Error(`Secure random number generation is not supported by this browser.
1981Use Chrome, Firefox or Internet Explorer 11`)}var roe=Qt.Buffer,Iw=dt.crypto||dt.msCrypto;Iw&&Iw.getRandomValues?U4.exports=noe:U4.exports=toe;function noe(e,t){if(e>eoe)throw new RangeError("requested too many random bytes");var r=roe.allocUnsafe(e);if(e>0)if(e>V4)for(var n=0;n<e;n+=V4)Iw.getRandomValues(r.slice(n,n+V4));else Iw.getRandomValues(r);return typeof t=="function"?ot.nextTick(function(){t(null,r)}):r}var v0=U4.exports,Z4={exports:{}},$4={exports:{}},w0=typeof Reflect=="object"?Reflect:null,IB=w0&&typeof w0.apply=="function"?w0.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)},Ow;w0&&typeof w0.ownKeys=="function"?Ow=w0.ownKeys:Object.getOwnPropertySymbols?Ow=function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Ow=function(e){return Object.getOwnPropertyNames(e)};function ioe(e){console&&console.warn&&console.warn(e)}var OB=Number.isNaN||function(e){return e!==e};function Dr(){Dr.init.call(this)}$4.exports=Dr,$4.exports.once=loe,Dr.EventEmitter=Dr,Dr.prototype._events=void 0,Dr.prototype._eventsCount=0,Dr.prototype._maxListeners=void 0;var BB=10;function Bw(e){if(typeof e!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}Object.defineProperty(Dr,"defaultMaxListeners",{enumerable:!0,get:function(){return BB},set:function(e){if(typeof e!="number"||e<0||OB(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");BB=e}}),Dr.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},Dr.prototype.setMaxListeners=function(e){if(typeof e!="number"||e<0||OB(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this};function RB(e){return e._maxListeners===void 0?Dr.defaultMaxListeners:e._maxListeners}Dr.prototype.getMaxListeners=function(){return RB(this)},Dr.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var n=e==="error",i=this._events;if(i!==void 0)n=n&&i.error===void 0;else if(!n)return!1;if(n){var a;if(t.length>0&&(a=t[0]),a instanceof Error)throw a;var s=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw s.context=a,s}var o=i[e];if(o===void 0)return!1;if(typeof o=="function")IB(o,this,t);else for(var c=o.length,l=LB(o,c),r=0;r<c;++r)IB(l[r],this,t);return!0};function NB(e,t,r,n){var i,a,s;if(Bw(r),a=e._events,a===void 0?(a=e._events=Object.create(null),e._eventsCount=0):(a.newListener!==void 0&&(e.emit("newListener",t,r.listener?r.listener:r),a=e._events),s=a[t]),s===void 0)s=a[t]=r,++e._eventsCount;else if(typeof s=="function"?s=a[t]=n?[r,s]:[s,r]:n?s.unshift(r):s.push(r),i=RB(e),i>0&&s.length>i&&!s.warned){s.warned=!0;var o=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");o.name="MaxListenersExceededWarning",o.emitter=e,o.type=t,o.count=s.length,ioe(o)}return e}Dr.prototype.addListener=function(e,t){return NB(this,e,t,!1)},Dr.prototype.on=Dr.prototype.addListener,Dr.prototype.prependListener=function(e,t){return NB(this,e,t,!0)};function aoe(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function FB(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},i=aoe.bind(n);return i.listener=r,n.wrapFn=i,i}Dr.prototype.once=function(e,t){return Bw(t),this.on(e,FB(this,e,t)),this},Dr.prototype.prependOnceListener=function(e,t){return Bw(t),this.prependListener(e,FB(this,e,t)),this},Dr.prototype.removeListener=function(e,t){var r,n,i,a,s;if(Bw(t),n=this._events,n===void 0)return this;if(r=n[e],r===void 0)return this;if(r===t||r.listener===t)--this._eventsCount===0?this._events=Object.create(null):(delete n[e],n.removeListener&&this.emit
vendor: 5,173 bytes, line 1981
1981("removeListener",e,r.listener||t));else if(typeof r!="function"){for(i=-1,a=r.length-1;a>=0;a--)if(r[a]===t||r[a].listener===t){s=r[a].listener,i=a;break}if(i<0)return this;i===0?r.shift():soe(r,i),r.length===1&&(n[e]=r[0]),n.removeListener!==void 0&&this.emit("removeListener",e,s||t)}return this},Dr.prototype.off=Dr.prototype.removeListener,Dr.prototype.removeAllListeners=function(e){var t,r,n;if(r=this._events,r===void 0)return this;if(r.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):r[e]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete r[e]),this;if(arguments.length===0){var i=Object.keys(r),a;for(n=0;n<i.length;++n)a=i[n],a!=="removeListener"&&this.removeAllListeners(a);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(t=r[e],typeof t=="function")this.removeListener(e,t);else if(t!==void 0)for(n=t.length-1;n>=0;n--)this.removeListener(e,t[n]);return this};function PB(e,t,r){var n=e._events;if(n===void 0)return[];var i=n[t];return i===void 0?[]:typeof i=="function"?r?[i.listener||i]:[i]:r?ooe(i):LB(i,i.length)}Dr.prototype.listeners=function(e){return PB(this,e,!0)},Dr.prototype.rawListeners=function(e){return PB(this,e,!1)},Dr.listenerCount=function(e,t){return typeof e.listenerCount=="function"?e.listenerCount(t):zB.call(e,t)},Dr.prototype.listenerCount=zB;function zB(e){var t=this._events;if(t!==void 0){var r=t[e];if(typeof r=="function")return 1;if(r!==void 0)return r.length}return 0}Dr.prototype.eventNames=function(){return this._eventsCount>0?Ow(this._events):[]};function LB(e,t){for(var r=new Array(t),n=0;n<t;++n)r[n]=e[n];return r}function soe(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}function ooe(e){for(var t=new Array(e.length),r=0;r<t.length;++r)t[r]=e[r].listener||e[r];return t}function loe(e,t){return new Promise(function(r,n){function i(s){e.removeListener(t,a),n(s)}function a(){typeof e.removeListener=="function"&&e.removeListener("error",i),r([].slice.call(arguments))}DB(e,t,a,{once:!0}),t!=="error"&&coe(e,i,{once:!0})})}function coe(e,t,r){typeof e.on=="function"&&DB(e,"error",t,r)}function DB(e,t,r,n){if(typeof e.on=="function")n.once?e.once(t,r):e.on(t,r);else if(typeof e.addEventListener=="function")e.addEventListener(t,function i(a){n.once&&e.removeEventListener(t,i),r(a)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e)}var jg=$4.exports,UB=jg.EventEmitter,H4,qB;function uoe(){if(qB)return H4;qB=1;function e(O,I){var R=Object.keys(O);if(Object.getOwnPropertySymbols){var C=Object.getOwnPropertySymbols(O);I&&(C=C.filter(function(j){return Object.getOwnPropertyDescriptor(O,j).enumerable})),R.push.apply(R,C)}return R}function t(O){for(var I=1;I<arguments.length;I++){var R=arguments[I]!=null?arguments[I]:{};I%2?e(Object(R),!0).forEach(function(C){r(O,C,R[C])}):Object.getOwnPropertyDescriptors?Object.defineProperties(O,Object.getOwnPropertyDescriptors(R)):e(Object(R)).forEach(function(C){Object.defineProperty(O,C,Object.getOwnPropertyDescriptor(R,C))})}return O}function r(O,I,R){return I=s(I),I in O?Object.defineProperty(O,I,{value:R,enumerable:!0,configurable:!0,writable:!0}):O[I]=R,O}function n(O,I){if(!(O instanceof I))throw new TypeError("Cannot call a class as a function")}function i(O,I){for(var R=0;R<I.length;R++){var C=I[R];C.enumerable=C.enumerable||!1,C.configurable=!0,"value"in C&&(C.writable=!0),Object.defineProperty(O,s(C.key),C)}}function a(O,I,R){return I&&i(O.prototype,I),Object.defineProperty(O,"prototype",{writable:!1}),O}function s(O){var I=o(O,"string");return typeof I=="symbol"?I:String(I)}function o(O,I){if(typeof O!="object"||O===null)return O;var R=O[Symbol.toPrimitive];if(R!==void 0){var C=R.call(O,I||"default");if(typeof C!="object")return C;throw new TypeError("@@toPrimitive must return a primitive value.")}return(I==="string"?String:Number)(O)}var c=ji,l=c.Buffer,u=ct,d=u.inspect,p=d&&d.custom||"inspect";function w(O,I,R){l.prototype.copy.call(O,I,R)}return H4=function(){function O(){n(this,O),this.head=null,this.tail=null,this.length=0}return a(O,[{key:"push",value:function(I){var R={data:I,next:null};this.length>0?this.tail.next=R:this.head=R,this.tail=R,++this.length}},{key:"unshift",value:function(I){var R={data:I,next:this.head};this.length===0&&(this.tail=R),this.head=R,++this.length}},{key:"shift",value:function(){if(this.length!==0){var I=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,I}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(I){if(this.length===0)return"";for(var R=this.head,C=""+R.data;R=R.next;)C+=I+R.data;return C}},{key:"concat",value:function(I){if(this.length===0)return l.alloc(0);for(var R=l.allocUnsafe(I>>>0),C=this.head,j=0;C;)w(C.data,R,j),j+=C.data.length,C=C.next;return R}},{key:"consume",value:function(I,R){var C;return I<this.head.data.length?(C=this.head.data.slice(0,I),this.head.data=this.head.data.slice(I)):I===this.head.data.length?C=this.shift():C=R?this._getString(I):this._getBuffer(
vendor: 29,707 bytes, line 1981
1981I),C}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(I){var R=this.head,C=1,j=R.data;for(I-=j.length;R=R.next;){var N=R.data,P=I>N.length?N.length:I;if(P===N.length?j+=N:j+=N.slice(0,I),I-=P,I===0){P===N.length?(++C,R.next?this.head=R.next:this.head=this.tail=null):(this.head=R,R.data=N.slice(P));break}++C}return this.length-=C,j}},{key:"_getBuffer",value:function(I){var R=l.allocUnsafe(I),C=this.head,j=1;for(C.data.copy(R),I-=C.data.length;C=C.next;){var N=C.data,P=I>N.length?N.length:I;if(N.copy(R,R.length-I,0,P),I-=P,I===0){P===N.length?(++j,C.next?this.head=C.next:this.head=this.tail=null):(this.head=C,C.data=N.slice(P));break}++j}return this.length-=j,R}},{key:p,value:function(I,R){return d(this,t(t({},R),{},{depth:0,customInspect:!1}))}}]),O}(),H4}function foe(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,ot.nextTick(W4,this,e)):ot.nextTick(W4,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(a){!t&&a?r._writableState?r._writableState.errorEmitted?ot.nextTick(Rw,r):(r._writableState.errorEmitted=!0,ot.nextTick(VB,r,a)):ot.nextTick(VB,r,a):t?(ot.nextTick(Rw,r),t(a)):ot.nextTick(Rw,r)}),this)}function VB(e,t){W4(e,t),Rw(e)}function Rw(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function hoe(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function W4(e,t){e.emit("error",t)}function doe(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}var ZB={destroy:foe,undestroy:hoe,errorOrDestroy:doe},fh={};function poe(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var $B={};function Is(e,t,r){r||(r=Error);function n(a,s,o){return typeof t=="string"?t:t(a,s,o)}var i=function(a){poe(s,a);function s(o,c,l){return a.call(this,n(o,c,l))||this}return s}(r);i.prototype.name=r.name,i.prototype.code=e,$B[e]=i}function HB(e,t){if(Array.isArray(e)){var r=e.length;return e=e.map(function(n){return String(n)}),r>2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:r===2?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}else return"of ".concat(t," ").concat(String(e))}function moe(e,t,r){return e.substr(0,t.length)===t}function goe(e,t,r){return(r===void 0||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}function boe(e,t,r){return typeof r!="number"&&(r=0),r+t.length>e.length?!1:e.indexOf(t,r)!==-1}Is("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'},TypeError),Is("ERR_INVALID_ARG_TYPE",function(e,t,r){var n;typeof t=="string"&&moe(t,"not ")?(n="must not be",t=t.replace(/^not /,"")):n="must be";var i;if(goe(e," argument"))i="The ".concat(e," ").concat(n," ").concat(HB(t,"type"));else{var a=boe(e,".")?"property":"argument";i='The "'.concat(e,'" ').concat(a," ").concat(n," ").concat(HB(t,"type"))}return i+=". Received type ".concat(typeof r),i},TypeError),Is("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),Is("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"}),Is("ERR_STREAM_PREMATURE_CLOSE","Premature close"),Is("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"}),Is("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),Is("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),Is("ERR_STREAM_WRITE_AFTER_END","write after end"),Is("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),Is("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError),Is("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),fh.codes=$B;var yoe=fh.codes.ERR_INVALID_OPT_VALUE;function voe(e,t,r){return e.highWaterMark!=null?e.highWaterMark:t?e[r]:null}function woe(e,t,r,n){var i=voe(t,n,r);if(i!=null){if(!(isFinite(i)&&Math.floor(i)===i)||i<0){var a=n?r:"highWaterMark";throw new yoe(a,i)}return Math.floor(i)}return e.objectMode?16:16384}var WB={getHighWaterMark:woe},KB=xoe;function xoe(e,t){if(K4("noDeprecation"))return e;var r=!1;function n(){if(!r){if(K4("throwDeprecation"))throw new Error(t);K4("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)}return n}function K4(e){try{if(!dt.localStorage)return!1}catch{return!1}var t=dt.localStorage[e];return t==null?!1:String(t).toLowerCase()==="true"}var G4,GB;function Y4(){if(GB)return G4;GB=1,G4=ne;function e(Y){var V=this;this.next=null,this.entry=null,this.finish=function(){J(V,Y)}}var t;ne.WritableState=X;var r={deprecate:KB},n=UB,i=ji.Buffer,a=(typeof dt<"u"?dt:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function s(Y){return i.from(Y)}function o(Y){return i.isBuffer(Y)||Y instanceof a}var c=ZB,l=WB,u=l.getHighWaterMark,d=fh.codes,p=d.ERR_INVALID_ARG_TYPE,w=d.ERR_METHOD_NOT_IMPLEMENTED,O=d.ERR_MULTIPLE_CALLBACK,I=d.ERR_STREAM_CANNOT_PIPE,R=d.ERR_STREAM_DESTROYED,C=d.ERR_STREAM_NULL_VALUES,j=d.ERR_STREAM_WRITE_AFTER_END,N=d.ERR_UNKNOWN_ENCODING,P=c.errorOrDestroy;Zt(ne,n);function Z(){}function X(Y,V,W){t=t||hh(),Y=Y||{},typeof W!="boolean"&&(W=V instanceof t),this.objectMode=!!Y.objectMode,W&&(this.objectMode=this.objectMode||!!Y.writableObjectMode),this.highWaterMark=u(this,Y,"writableHighWaterMark",W),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var ce=Y.decodeStrings===!1;this.decodeStrings=!ce,this.defaultEncoding=Y.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(pe){B(V,pe)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=Y.emitClose!==!1,this.autoDestroy=!!Y.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new e(this)}X.prototype.getBuffer=function(){for(var Y=this.bufferedRequest,V=[];Y;)V.push(Y),Y=Y.next;return V},function(){try{Object.defineProperty(X.prototype,"buffer",{get:r.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var re;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(re=Function.prototype[Symbol.hasInstance],Object.defineProperty(ne,Symbol.hasInstance,{value:function(Y){return re.call(this,Y)?!0:this!==ne?!1:Y&&Y._writableState instanceof X}})):re=function(Y){return Y instanceof this};function ne(Y){t=t||hh();var V=this instanceof t;if(!V&&!re.call(ne,this))return new ne(Y);this._writableState=new X(Y,this,V),this.writable=!0,Y&&(typeof Y.write=="function"&&(this._write=Y.write),typeof Y.writev=="function"&&(this._writev=Y.writev),typeof Y.destroy=="function"&&(this._destroy=Y.destroy),typeof Y.final=="function"&&(this._final=Y.final)),n.call(this)}ne.prototype.pipe=function(){P(this,new I)};function ae(Y,V){var W=new j;P(Y,W),ot.nextTick(V,W)}function ue(Y,V,W,ce){var pe;return W===null?pe=new C:typeof W!="string"&&!V.objectMode&&(pe=new p("chunk",["string","Buffer"],W)),pe?(P(Y,pe),ot.nextTick(ce,pe),!1):!0}ne.prototype.write=function(Y,V,W){var ce=this._writableState,pe=!1,ee=!ce.objectMode&&o(Y);return ee&&!i.isBuffer(Y)&&(Y=s(Y)),typeof V=="function"&&(W=V,V=null),ee?V="buffer":V||(V=ce.defaultEncoding),typeof W!="function"&&(W=Z),ce.ending?ae(this,W):(ee||ue(this,ce,Y,W))&&(ce.pendingcb++,pe=A(this,ce,ee,Y,V,W)),pe},ne.prototype.cork=function(){this._writableState.corked++},ne.prototype.uncork=function(){var Y=this._writableState;Y.corked&&(Y.corked--,!Y.writing&&!Y.corked&&!Y.bufferProcessing&&Y.bufferedRequest&&h(this,Y))},ne.prototype.setDefaultEncoding=function(Y){if(typeof Y=="string"&&(Y=Y.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((Y+"").toLowerCase())>-1))throw new N(Y);return this._writableState.defaultEncoding=Y,this},Object.defineProperty(ne.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function m(Y,V,W){return!Y.objectMode&&Y.decodeStrings!==!1&&typeof V=="string"&&(V=i.from(V,W)),V}Object.defineProperty(ne.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function A(Y,V,W,ce,pe,ee){if(!W){var se=m(V,ce,pe);ce!==se&&(W=!0,pe="buffer",ce=se)}var ve=V.objectMode?1:ce.length;V.length+=ve;var _e=V.length<V.highWaterMark;if(_e||(V.needDrain=!0),V.writing||V.corked){var Ue=V.lastBufferedRequest;V.lastBufferedRequest={chunk:ce,encoding:pe,isBuf:W,callback:ee,next:null},Ue?Ue.next=V.lastBufferedRequest:V.bufferedRequest=V.lastBufferedRequest,V.bufferedRequestCount+=1}else f(Y,V,!1,ve,ce,pe,ee);return _e}function f(Y,V,W,ce,pe,ee,se){V.writelen=ce,V.writecb=se,V.writing=!0,V.sync=!0,V.destroyed?V.onwrite(new R("write")):W?Y._writev(pe,V.onwrite):Y._write(pe,ee,V.onwrite),V.sync=!1}function g(Y,V,W,ce,pe){--V.pendingcb,W?(ot.nextTick(pe,ce),ot.nextTick(Q,Y,V),Y._writableState.errorEmitted=!0,P(Y,ce)):(pe(ce),Y._writableState.errorEmitted=!0,P(Y,ce),Q(Y,V))}function _(Y){Y.writing=!1,Y.writecb=null,Y.length-=Y.writelen,Y.writelen=0}function B(Y,V){var W=Y._writableState,ce=W.sync,pe=W.writecb;if(typeof pe!="function")throw new O;if(_(W),V)g(Y,W,ce,V,pe);else{var ee=x(W)||Y.destroyed;!ee&&!W.corked&&!W.bufferProcessing&&W.bufferedRequest&&h(Y,W),ce?ot.nextTick(T,Y,W,ee,pe):T(Y,W,ee,pe)}}function T(Y,V,W,ce){W||S(Y,V),V.pendingcb--,ce(),Q(Y,V)}function S(Y,V){V.length===0&&V.needDrain&&(V.needDrain=!1,Y.emit("drain"))}function h(Y,V){V.bufferProcessing=!0;var W=V.bufferedRequest;if(Y._writev&&W&&W.next){var ce=V.bufferedRequestCount,pe=new Array(ce),ee=V.corkedRequestsFree;ee.entry=W;for(var se=0,ve=!0;W;)pe[se]=W,W.isBuf||(ve=!1),W=W.next,se+=1;pe.allBuffers=ve,f(Y,V,!0,V.length,pe,"",ee.finish),V.pendingcb++,V.lastBufferedRequest=null,ee.next?(V.corkedRequestsFree=ee.next,ee.next=null):V.corkedRequestsFree=new e(V),V.bufferedRequestCount=0}else{for(;W;){var _e=W.chunk,Ue=W.encoding,xe=W.callback,Te=V.objectMode?1:_e.length;if(f(Y,V,!1,Te,_e,Ue,xe),W=W.next,V.bufferedRequestCount--,V.writing)break}W===null&&(V.lastBufferedRequest=null)}V.bufferedRequest=W,V.bufferProcessing=!1}ne.prototype._write=function(Y,V,W){W(new w("_write()"))},ne.prototype._writev=null,ne.prototype.end=function(Y,V,W){var ce=this._writableState;return typeof Y=="function"?(W=Y,Y=null,V=null):typeof V=="function"&&(W=V,V=null),Y!=null&&this.write(Y,V),ce.corked&&(ce.corked=1,this.uncork()),ce.ending||G(this,ce,W),this},Object.defineProperty(ne.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function x(Y){return Y.ending&&Y.length===0&&Y.bufferedRequest===null&&!Y.finished&&!Y.writing}function v(Y,V){Y._final(function(W){V.pendingcb--,W&&P(Y,W),V.prefinished=!0,Y.emit("prefinish"),Q(Y,V)})}function F(Y,V){!V.prefinished&&!V.finalCalled&&(typeof Y._final=="function"&&!V.destroyed?(V.pendingcb++,V.finalCalled=!0,ot.nextTick(v,Y,V)):(V.prefinished=!0,Y.emit("prefinish")))}function Q(Y,V){var W=x(V);if(W&&(F(Y,V),V.pendingcb===0&&(V.finished=!0,Y.emit("finish"),V.autoDestroy))){var ce=Y._readableState;(!ce||ce.autoDestroy&&ce.endEmitted)&&Y.destroy()}return W}function G(Y,V,W){V.ending=!0,Q(Y,V),W&&(V.finished?ot.nextTick(W):Y.once("finish",W)),V.ended=!0,Y.writable=!1}function J(Y,V,W){var ce=Y.entry;for(Y.entry=null;ce;){var pe=ce.callback;V.pendingcb--,pe(W),ce=ce.next}V.corkedRequestsFree.next=Y}return Object.defineProperty(ne.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(Y){this._writableState&&(this._writableState.destroyed=Y)}}),ne.prototype.destroy=c.destroy,ne.prototype._undestroy=c.undestroy,ne.prototype._destroy=function(Y,V){V(Y)},G4}var X4,YB;function hh(){if(YB)return X4;YB=1;var e=Object.keys||function(l){var u=[];for(var d in l)u.push(d);return u};X4=s;var t=r8(),r=Y4();Zt(s,t);for(var n=e(r.prototype),i=0;i<n.length;i++){var a=n[i];s.prototype[a]||(s.prototype[a]=r.prototype[a])}function s(l){if(!(this instanceof s))return new s(l);t.call(this,l),r.call(this,l),this.allowHalfOpen=!0,l&&(l.readable===!1&&(this.readable=!1),l.writable===!1&&(this.writable=!1),l.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",o)))}Object.defineProperty(s.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(s.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(s.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function o(){this._writableState.ended||ot.nextTick(c,this)}function c(l){l.end()}return Object.defineProperty(s.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(l){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=l,this._writableState.destroyed=l)}}),X4}var Ig={},J4=Qt.Buffer,XB=J4.isEncoding||function(e){switch(e=""+e,e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function _oe(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function Soe(e){var t=_oe(e);if(typeof t!="string"&&(J4.isEncoding===XB||!XB(e)))throw new Error("Unknown encoding: "+e);return t||e}Ig.StringDecoder=Og;function Og(e){this.encoding=Soe(e);var t;switch(this.encoding){case"utf16le":this.text=Toe,this.end=joe,t=4;break;case"utf8":this.fillLast=Moe,t=4;break;case"base64":this.text=Ioe,this.end=Ooe,t=3;break;default:this.write=Boe,this.end=Roe;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=J4.allocUnsafe(t)}Og.prototype.write=function(e){if(e.length===0)return"";var t,r;if(this.lastNeed){if(t=this.fillLast(e),t===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},Og.prototype.end=Coe,Og.prototype.text=Aoe,Og.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length};function Q4(e){return e<=127?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function koe(e,t,r){var n=t.length-1;if(n<r)return 0;var i=Q4(t[n]);return i>=0?(i>0&&(e.lastNeed=i-1),i):--n<r||i===-2?0:(i=Q4(t[n]),i>=0?(i>0&&(e.lastNeed=i-2),i):--n<r||i===-2?0:(i=Q4(t[n]),i>=0?(i>0&&(i===2?i=0:e.lastNeed=i-3),i):0))}function Eoe(e,t,r){if((t[0]&192)!==128)return e.lastNeed=0,"\uFFFD";if(e.lastNeed>1&&t.length>1){if((t[1]&192)!==128)return e.lastNeed=1,"\uFFFD";if(e.lastNeed>2&&t.length>2&&(t[2]&192)!==128)return e.lastNeed=2,"\uFFFD"}}function Moe(e){var t=this.lastTotal-this.lastNeed,r=Eoe(this,e);if(r!==void 0)return r;if(this.lastNeed<=e.length)return e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length}function Aoe(e,t){var r=koe(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)}function Coe(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"\uFFFD":t}function Toe(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function joe(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function Ioe(e,t){var r=(e.length-t)%3;return r===0?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function Ooe(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function Boe(e){return e.toString(this.encoding)}function Roe(e){return e&&e.length?this.write(e):""}var JB=fh.codes.ERR_STREAM_PREMATURE_CLOSE;function Noe(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=new Array(r),i=0;i<r;i++)n[i]=arguments[i];e.apply(this,n)}}}function Foe(){}function Poe(e){return e.setHeader&&typeof e.abort=="function"}function QB(e,t,r){if(typeof t=="function")return QB(e,null,t);t||(t={}),r=Noe(r||Foe);var n=t.readable||t.readable!==!1&&e.readable,i=t.writable||t.writable!==!1&&e.writable,a=function(){e.writable||o()},s=e._writableState&&e._writableState.finished,o=function(){i=!1,s=!0,n||r.call(e)},c=e._readableState&&e._readableState.endEmitted,l=function(){n=!1,c=!0,i||r.call(e)},u=function(w){r.call(e,w)},d=function(){var w;if(n&&!c)return(!e._readableState||!e._readableState.ended)&&(w=new JB),r.call(e,w);if(i&&!s)return(!e._writableState||!e._writableState.ended)&&(w=new JB),r.call(e,w)},p=function(){e.req.on("finish",o)};return Poe(e)?(e.on("complete",o),e.on("abort",d),e.req?p():e.on("request",p)):i&&!e._writableState&&(e.on("end",a),e.on("close",a)),e.on("end",l),e.on("finish",o),t.error!==!1&&e.on("error",u),e.on("close",d),function(){e.removeListener("complete",o),e.removeListener("abort",d),e.removeListener("request",p),e.req&&e.req.removeListener("finish",o),e.removeListener("end",a),e.removeListener("close",a),e.removeListener("finish",o),e.removeListener("end",l),e.removeListener("error",u),e.removeListener("close",d)}}var Nw=QB,e8,eR;function zoe(){if(eR)return e8;eR=1;var e;function t(N,P,Z){return P=r(P),P in N?Object.defineProperty(N,P,{value:Z,enumerable:!0,configurable:!0,writable:!0}):N[P]=Z,N}function r(N){var P=n(N,"string");return typeof P=="symbol"?P:String(P)}function n(N,P){if(typeof N!="object"||N===null)return N;var Z=N[Symbol.toPrimitive];if(Z!==void 0){var X=Z.call(N,P||"default");if(typeof X!="object")return X;throw new TypeError("@@toPrimitive must return a primitive value.")}return(P==="string"?String:Number)(N)}var i=Nw,a=Symbol("lastResolve"),s=Symbol("lastReject"),o=Symbol("error"),c=Symbol("ended"),l=Symbol("lastPromise"),u=Symbol("handlePromise"),d=Symbol("stream");function p(N,P){return{value:N,done:P}}function w(N){var P=N[a];if(P!==null){var Z=N[d].read();Z!==null&&(N[l]=null,N[a]=null,N[s]=null,P(p(Z,!1)))}}function O(N){ot.nextTick(w,N)}function I(N,P){return function(Z,X){N.then(function(){if(P[c]){Z(p(void 0,!0));return}P[u](Z,X)},X)}}var R=Object.getPrototypeOf(function(){}),C=Object.setPrototypeOf((e={get stream(){return this[d]},next:function(){var N=this,P=this[o];if(P!==null)return Promise.reject(P);if(this[c])return Promise.resolve(p(void 0,!0));if(this[d].destroyed)return new Promise(function(ne,ae){ot.nextTick(function(){N[o]?ae(N[o]):ne(p(void 0,!0))})});var Z=this[l],X;if(Z)X=new Promise(I(Z,this));else{var re=this[d].read();if(re!==null)return Promise.resolve(p(re,!1));X=new Promise(this[u])}return this[l]=X,X}},t(e,Symbol.asyncIterator,function(){return this}),t(e,"return",function(){var N=this;return new Promise(function(P,Z){N[d].destroy(null,function(X){if(X){Z(X);return}P(p(void 0,!0))})})}),e),R),j=function(N){var P,Z=Object.create(C,(P={},t(P,d,{value:N,writable:!0}),t(P,a,{value:null,writable:!0}),t(P,s,{value:null,writable:!0}),t(P,o,{value:null,writable:!0}),t(P,c,{value:N._readableState.endEmitted,writable:!0}),t(P,u,{value:function(X,re){var ne=Z[d].read();ne?(Z[l]=null,Z[a]=null,Z[s]=null,X(p(ne,!1))):(Z[a]=X,Z[s]=re)},writable:!0}),P));return Z[l]=null,i(N,function(X){if(X&&X.code!=="ERR_STREAM_PREMATURE_CLOSE"){var re=Z[s];re!==null&&(Z[l]=null,Z[a]=null,Z[s]=null,re(X)),Z[o]=X;return}var ne=Z[a];ne!==null&&(Z[l]=null,Z[a]=null,Z[s]=null,ne(p(void 0,!0))),Z[c]=!0}),N.on("readable",O.bind(null,Z)),Z};return e8=j,e8}var tR,rR;function Loe(){return rR||(rR=1,tR=function(){throw new Error("Readable.from is not available in the browser")}),tR}var t8,nR;function r8(){if(nR)return t8;nR=1,t8=ae;var e;ae.ReadableState=ne,jg.EventEmitter;var t=function(ee,se){return ee.listeners(se).length},r=UB,n=ji.Buffer,i=(typeof dt<"u"?dt:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function a(ee){return n.from(ee)}function s(ee){return n.isBuffer(ee)||ee instanceof i}var o=ct,c;o&&o.debuglog?c=o.debuglog("stream"):c=function(){};var l=uoe(),u=ZB,d=WB,p=d.getHighWaterMark,w=fh.codes,O=w.ERR_INVALID_ARG_TYPE,I=w.ERR_STREAM_PUSH_AFTER_EOF,R=w.ERR_METHOD_NOT_IMPLEMENTED,C=w.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,j,N,P;Zt(ae,r);var Z=u.errorOrDestroy,X=["error","close","destroy","pause","resume"];function re(ee,se,ve){if(typeof ee.prependListener=="function")return ee.prependListener(se,ve);!ee._events||!ee._events[se]?ee.on(se,ve):Array.isArray(ee._events[se])?ee._events[se].unshift(ve):ee._events[se]=[ve,ee._events[se]]}function ne(ee,se,ve){e=e||hh(),ee=ee||{},typeof ve!="boolean"&&(ve=se instanceof e),this.objectMode=!!ee.objectMode,ve&&(this.objectMode=this.objectMode||!!ee.readableObjectMode),this.highWaterMark=p(this,ee,"readableHighWaterMark",ve),this.buffer=new l,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=ee.emitClose!==!1,this.autoDestroy=!!ee.autoDestroy,this.destroyed=!1,this.defaultEncoding=ee.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,ee.encoding&&(j||(j=Ig.StringDecoder),this.decoder=new j(ee.encoding),this.encoding=ee.encoding)}function ae(ee){if(e=e||hh(),!(this instanceof ae))return new ae(ee);var se=this instanceof e;this._readableState=new ne(ee,this,se),this.readable=!0,ee&&(typeof ee.read=="function"&&(this._read=ee.read),typeof ee.destroy=="function"&&(this._destroy=ee.destroy)),r.call(this)}Object.defineProperty(ae.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(ee){this._readableState&&(this._readableState.destroyed=ee)}}),ae.prototype.destroy=u.destroy,ae.prototype._undestroy=u.undestroy,ae.prototype._destroy=function(ee,se){se(ee)},ae.prototype.push=function(ee,se){var ve=this._readableState,_e;return ve.objectMode?_e=!0:typeof ee=="string"&&(se=se||ve.defaultEncoding,se!==ve.encoding&&(ee=n.from(ee,se),se=""),_e=!0),ue(this,ee,se,!1,_e)},ae.prototype.unshift=function(ee){return ue(this,ee,null,!0,!1)};function ue(ee,se,ve,_e,Ue){c("readableAddChunk",se);var xe=ee._readableState;if(se===null)xe.reading=!1,B(ee,xe);else{var Te;if(Ue||(Te=A(xe,se)),Te)Z(ee,Te);else if(xe.objectMode||se&&se.length>0)if(typeof se!="string"&&!xe.objectMode&&Object.getPrototypeOf(se)!==n.prototype&&(se=a(se)),_e)xe.endEmitted?Z(ee,new C):m(ee,xe,se,!0);else if(xe.ended)Z(ee,new I);else{if(xe.destroyed)return!1;xe.reading=!1,xe.decoder&&!ve?(se=xe.decoder.write(se),xe.objectMode||se.length!==0?m(ee,xe,se,!1):h(ee,xe)):m(ee,xe,se,!1)}else _e||(xe.reading=!1,h(ee,xe))}return!xe.ended&&(xe.length<xe.highWaterMark||xe.length===0)}function m(ee,se,ve,_e){se.flowing&&se.length===0&&!se.sync?(se.awaitDrain=0,ee.emit("data",ve)):(se.length+=se.objectMode?1:ve.length,_e?se.buffer.unshift(ve):se.buffer.push(ve),se.needReadable&&T(ee)),h(ee,se)}function A(ee,se){var ve;return!s(se)&&typeof se!="string"&&se!==void 0&&!ee.objectMode&&(ve=new O("chunk",["string","Buffer","Uint8Array"],se)),ve}ae.prototype.isPaused=function(){return this._readableState.flowing===!1},ae.prototype.setEncoding=function(ee){j||(j=Ig.StringDecoder);var se=new j(ee);this._readableState.decoder=se,this._readableState.encoding=this._readableState.decoder.encoding;for(var ve=this._readableState.buffer.head,_e="";ve!==null;)_e+=se.write(ve.data),ve=ve.next;return this._readableState.buffer.clear(),_e!==""&&this._readableState.buffer.push(_e),this._readableState.length=_e.length,this};var f=1073741824;function g(ee){return ee>=f?ee=f:(ee--,ee|=ee>>>1,ee|=ee>>>2,ee|=ee>>>4,ee|=ee>>>8,ee|=ee>>>16,ee++),ee}function _(ee,se){return ee<=0||se.length===0&&se.ended?0:se.objectMode?1:ee!==ee?se.flowing&&se.length?se.buffer.head.data.length:se.length:(ee>se.highWaterMark&&(se.highWaterMark=g(ee)),ee<=se.length?ee:se.ended?se.length:(se.needReadable=!0,0))}ae.prototype.read=function(ee){c("read",ee),ee=parseInt(ee,10);var se=this._readableState,ve=ee;if(ee!==0&&(se.emittedReadable=!1),ee===0&&se.needReadable&&((se.highWaterMark!==0?se.length>=se.highWaterMark:se.length>0)||se.ended))return c("read: emitReadable",se.length,se.ended),se.length===0&&se.ended?W(this):T(this),null;if(ee=_(ee,se),ee===0&&se.ended)return se.length===0&&W(this),null;var _e=se.needReadable;c("need readable",_e),(se.length===0||se.length-ee<se.highWaterMark)&&(_e=!0,c("length less than watermark",_e)),se.ended||se.reading?(_e=!1,c("reading or ended",_e)):_e&&(c("do read"),se.reading=!0,se.sync=!0,se.length===0&&(se.needReadable=!0),this._read(se.highWaterMark),se.sync=!1,se.reading||(ee=_(ve,se)));var Ue;return ee>0?Ue=V(ee,se):Ue=null,Ue===null?(se.needReadable=se.length<=se.highWaterMark,ee=0):(se.length-=ee,se.awaitDrain=0),se.length===0&&(se.ended||(se.needReadable=!0),ve!==ee&&se.ended&&W(this)),Ue!==null&&this.emit("data",Ue),Ue};function B(ee,se){if(c("onEofChunk"),!se.ended){if(se.decoder){var ve=se.decoder.end();ve&&ve.length&&(se.buffer.push(ve),se.length+=se.objectMode?1:ve.length)}se.ended=!0,se.sync?T(ee):(se.needReadable=!1,se.emittedReadable||(se.emittedReadable=!0,S(ee)))}}function T(ee){var se=ee._readableState;c("emitReadable",se.needReadable,se.emittedReadable),se.needReadable=!1,se.emittedReadable||(c("emitReadable",se.flowing),se.emittedReadable=!0,ot.nextTick(S,ee))}function S(ee){var se=ee._readableState;c("emitReadable_",se.destroyed,se.length,se.ended),!se.destroyed&&(se.length||se.ended)&&(ee.emit("readable"),se.emittedReadable=!1),se.needReadable=!se.flowing&&!se.ended&&se.length<=se.highWaterMark,Y(ee)}function h(ee,se){se.readingMore||(se.readingMore=!0,ot.nextTick(x,ee,se))}function x(ee,se){for(;!se.reading&&!se.ended&&(se.length<se.highWaterMark||se.flowing&&se.length===0);){var ve=se.length;if(c("maybeReadMore read 0"),ee.read(0),ve===se.length)break}se.readingMore=!1}ae.prototype._read=function(ee){Z(this,new R("_read()"))},ae.prototype.pipe=function(ee,se){var ve=this,_e=this._readableState;switch(_e.pipesCount){case 0:_e.pipes=ee;break;case 1:_e.pipes=[_e.pipes,ee];break;default:_e.pipes.push(ee);break}_e.pipesCount+=1,c("pipe count=%d opts=%j",_e.pipesCount,se);var Ue=(!se||se.end!==!1)&&ee!==ot.stdout&&ee!==ot.stderr,xe=Ue?$e:ke;_e.endEmitted?ot.nextTick(xe):ve.once("end",xe),ee.on("unpipe",Te);function Te(Ne,z){c("onunpipe"),Ne===ve&&z&&z.hasUnpiped===!1&&(z.hasUnpiped=!0,Ke())}function $e(){c("onend"),ee.end()}var Ae=v(ve);ee.on("drain",Ae);var De=!1;function Ke(){c("cleanup"),ee.removeListener("close",ge),ee.removeListener("finish",we),ee.removeListener("drain",Ae),ee.removeListener("error",Fe),ee.removeListener("unpipe",Te),ve.removeListener("end",$e),ve.removeListener("end",ke),ve.removeListener("data",ut),De=!0,_e.awaitDrain&&(!ee._writableState||ee._writableState.needDrain)&&Ae()}ve.on("data",ut);function ut(Ne){c("ondata");var z=ee.write(Ne);c("dest.write",z),z===!1&&((_e.pipesCount===1&&_e.pipes===ee||_e.pipesCount>1&&pe(_e.pipes,ee)!==-1)&&!De&&(c("false write response, pause",_e.awaitDrain),_e.awaitDrain++),ve.pause())}function Fe(Ne){c("onerror",Ne),ke(),ee.removeListener("error",Fe),t(ee,"error")===0&&Z(ee,Ne)}re(ee,"error",Fe);function ge(){ee.removeListener("finish",we),ke()}ee.once("close",ge);function we(){c("onfinish"),ee.removeListener("close",ge),ke()}ee.once("finish",we);function ke(){c("unpipe"),ve.unpipe(ee)}return ee.emit("pipe",ve),_e.flowing||(c("pipe resume"),ve.resume()),ee};function v(ee){return function(){var se=ee._readableState;c("pipeOnDrain",se.awaitDrain),se.awaitDrain&&se.awaitDrain--,se.awaitDrain===0&&t(ee,"data")&&(se.flowing=!0,Y(ee))}}ae.prototype.unpipe=function(ee){var se=this._readableState,ve={hasUnpiped:!1};if(se.pipesCount===0)return this;if(se.pipesCount===1)return ee&&ee!==se.pipes?this:(ee||(ee=se.pipes),se.pipes=null,
vendor: 4,349 bytes, line 1981
1981se.pipesCount=0,se.flowing=!1,ee&&ee.emit("unpipe",this,ve),this);if(!ee){var _e=se.pipes,Ue=se.pipesCount;se.pipes=null,se.pipesCount=0,se.flowing=!1;for(var xe=0;xe<Ue;xe++)_e[xe].emit("unpipe",this,{hasUnpiped:!1});return this}var Te=pe(se.pipes,ee);return Te===-1?this:(se.pipes.splice(Te,1),se.pipesCount-=1,se.pipesCount===1&&(se.pipes=se.pipes[0]),ee.emit("unpipe",this,ve),this)},ae.prototype.on=function(ee,se){var ve=r.prototype.on.call(this,ee,se),_e=this._readableState;return ee==="data"?(_e.readableListening=this.listenerCount("readable")>0,_e.flowing!==!1&&this.resume()):ee==="readable"&&!_e.endEmitted&&!_e.readableListening&&(_e.readableListening=_e.needReadable=!0,_e.flowing=!1,_e.emittedReadable=!1,c("on readable",_e.length,_e.reading),_e.length?T(this):_e.reading||ot.nextTick(Q,this)),ve},ae.prototype.addListener=ae.prototype.on,ae.prototype.removeListener=function(ee,se){var ve=r.prototype.removeListener.call(this,ee,se);return ee==="readable"&&ot.nextTick(F,this),ve},ae.prototype.removeAllListeners=function(ee){var se=r.prototype.removeAllListeners.apply(this,arguments);return(ee==="readable"||ee===void 0)&&ot.nextTick(F,this),se};function F(ee){var se=ee._readableState;se.readableListening=ee.listenerCount("readable")>0,se.resumeScheduled&&!se.paused?se.flowing=!0:ee.listenerCount("data")>0&&ee.resume()}function Q(ee){c("readable nexttick read 0"),ee.read(0)}ae.prototype.resume=function(){var ee=this._readableState;return ee.flowing||(c("resume"),ee.flowing=!ee.readableListening,G(this,ee)),ee.paused=!1,this};function G(ee,se){se.resumeScheduled||(se.resumeScheduled=!0,ot.nextTick(J,ee,se))}function J(ee,se){c("resume",se.reading),se.reading||ee.read(0),se.resumeScheduled=!1,ee.emit("resume"),Y(ee),se.flowing&&!se.reading&&ee.read(0)}ae.prototype.pause=function(){return c("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(c("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function Y(ee){var se=ee._readableState;for(c("flow",se.flowing);se.flowing&&ee.read()!==null;);}ae.prototype.wrap=function(ee){var se=this,ve=this._readableState,_e=!1;ee.on("end",function(){if(c("wrapped end"),ve.decoder&&!ve.ended){var Te=ve.decoder.end();Te&&Te.length&&se.push(Te)}se.push(null)}),ee.on("data",function(Te){if(c("wrapped data"),ve.decoder&&(Te=ve.decoder.write(Te)),!(ve.objectMode&&Te==null)&&!(!ve.objectMode&&(!Te||!Te.length))){var $e=se.push(Te);$e||(_e=!0,ee.pause())}});for(var Ue in ee)this[Ue]===void 0&&typeof ee[Ue]=="function"&&(this[Ue]=function(Te){return function(){return ee[Te].apply(ee,arguments)}}(Ue));for(var xe=0;xe<X.length;xe++)ee.on(X[xe],this.emit.bind(this,X[xe]));return this._read=function(Te){c("wrapped _read",Te),_e&&(_e=!1,ee.resume())},this},typeof Symbol=="function"&&(ae.prototype[Symbol.asyncIterator]=function(){return N===void 0&&(N=zoe()),N(this)}),Object.defineProperty(ae.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(ae.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(ae.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(ee){this._readableState&&(this._readableState.flowing=ee)}}),ae._fromList=V,Object.defineProperty(ae.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function V(ee,se){if(se.length===0)return null;var ve;return se.objectMode?ve=se.buffer.shift():!ee||ee>=se.length?(se.decoder?ve=se.buffer.join(""):se.buffer.length===1?ve=se.buffer.first():ve=se.buffer.concat(se.length),se.buffer.clear()):ve=se.buffer.consume(ee,se.decoder),ve}function W(ee){var se=ee._readableState;c("endReadable",se.endEmitted),se.endEmitted||(se.ended=!0,ot.nextTick(ce,se,ee))}function ce(ee,se){if(c("endReadableNT",ee.endEmitted,ee.length),!ee.endEmitted&&ee.length===0&&(ee.endEmitted=!0,se.readable=!1,se.emit("end"),ee.autoDestroy)){var ve=se._writableState;(!ve||ve.autoDestroy&&ve.finished)&&se.destroy()}}typeof Symbol=="function"&&(ae.from=function(ee,se){return P===void 0&&(P=Loe()),P(ae,ee,se)});function pe(ee,se){for(var ve=0,_e=ee.length;ve<_e;ve++)if(ee[ve]===se)return ve;return-1}return t8}
1981var n8=bc,Fw=fh.codes,Doe=Fw.ERR_METHOD_NOT_IMPLEMENTED,Uoe=Fw.ERR_MULTIPLE_CALLBACK,qoe=Fw.ERR_TRANSFORM_ALREADY_TRANSFORMING,Voe=Fw.ERR_TRANSFORM_WITH_LENGTH_0,Pw=hh();Zt(bc,Pw);function Zoe(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(n===null)return this.emit("error",new Uoe);r.writechunk=null,r.writecb=null,t!=null&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function bc(e){if(!(this instanceof bc))return new bc(e);Pw.call(this,e),this._transformState={afterTransform:Zoe.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&(typeof e.transform=="function"&&(this._transform=e.transform),typeof e.flush=="function"&&(this._flush=e.flush)),this.on("prefinish",$oe)}function $oe(){var e=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(t,r){iR(e,t,r)}):iR(this,null,null)}bc.prototype.push=function(e,t){return this._transformState.needTransform=!1,Pw.prototype.push.call(this,e,t)},bc.prototype._transform=function(e,t,r){r(new Doe("_transform()"))},bc.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},bc.prototype._read=function(e){var t=this._transformState;t.writechunk!==null&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},bc.prototype._destroy=function(e,t){Pw.prototype._destroy.call(this,e,function(r){t(r)})};function iR(e,t,r){if(t)return e.emit("error",t);if(r!=null&&e.push(r),e._writableState.length)throw new Voe;if(e._transformState.transforming)throw new qoe;return e.push(null)}var aR=Bg,sR=n8;Zt(Bg,sR);function Bg(e){if(!(this instanceof Bg))return new Bg(e);sR.call(this,e)}Bg.prototype._transform=function(e,t,r){r(null,e)};var i8;function Hoe(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}var oR=fh.codes,Woe=oR.ERR_MISSING_ARGS,Koe=oR.ERR_STREAM_DESTROYED;function Goe(e){if(e)throw e}function Yoe(e){return e.setHeader&&typeof e.abort=="function"}function Xoe(e,t,r,n){n=Hoe(n);var i=!1;e.on("close",function(){i=!0}),i8===void 0&&(i8=Nw),i8(e,{readable:t,writable:r},function(s){if(s)return n(s);i=!0,n()});var a=!1;return function(s){if(!i&&!a){if(a=!0,Yoe(e))return e.abort();if(typeof e.destroy=="function")return e.destroy();n(s||new Koe("pipe"))}}}function lR(e){e()}function Joe(e,t){return e.pipe(t)}function Qoe(e){return!e.length||typeof e[e.length-1]!="function"?Goe:e.pop()}function ele(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];var n=Qoe(t);if(Array.isArray(t[0])&&(t=t[0]),t.length<2)throw new Woe("streams");var i,a=t.map(function(s,o){var c=o<t.length-1,l=o>0;return Xoe(s,c,l,function(u){i||(i=u),u&&a.forEach(lR),!c&&(a.forEach(lR),n(i))})});return t.reduce(Joe)}var cR=ele;(function(e,t){t=e.exports=r8(),t.Stream=t,t.Readable=t,t.Writable=Y4(),t.Duplex=hh(),t.Transform=n8,t.PassThrough=aR,t.finished=Nw,t.pipeline=cR})(Z4,Z4.exports);var uR=Z4.exports,zw=Qt.Buffer,fR=uR.Transform,tle=Zt;function rle(e,t){if(!zw.isBuffer(e)&&typeof e!="string")throw new TypeError(t+" must be a string or a buffer")}function Ou(e){fR.call(this),this._block=zw.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}tle(Ou,fR),Ou.prototype._transform=function(e,t,r){var n=null;try{this.update(e,t)}catch(i){n=i}r(n)},Ou.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(r){t=r}e(t)},Ou.prototype.update=function(e,t){if(rle(e,"Data"),this._finalized)throw new Error("Digest already called");zw.isBuffer(e)||(e=zw.from(e,t));for(var r=this._block,n=0;this._blockOffset+e.length-n>=this._blockSize;){for(var i=this._blockOffset;i<this._blockSize;)r[i++]=e[n++];this._update(),this._blockOffset=0}for(;n<e.length;)r[this._blockOffset++]=e[n++];for(var a=0,s=e.length*8;s>0;++a)this._length[a]+=s,s=this._length[a]/4294967296|0,s>0&&(this._length[a]-=4294967296*s);return this},Ou.prototype._update=function(){throw new Error("_update is not implemented")},Ou.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();e!==void 0&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return t},Ou.prototype._digest=function(){throw new Error("_digest is not implemented")};var nle=Ou,ile=Zt,hR=nle,ale=Qt.Buffer,sle=new Array(16);function Lw(){hR.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}ile(Lw,hR),Lw.prototype._update=function(){for(var e=sle,t=0;t<16;++t)e[t]=this._block.readInt32LE(t*4);var r=this._a,n=this._b,i=this._c,a=this._d;r=Ki(r,n,i,a,e[0],3614090360,7),a=Ki(a,r,n,i,e[1],3905402710,12),i=Ki(i,a,r,n,e[2],606105819,17),n=Ki(n,i,a,r,e[3],3250441966,22),r=Ki(r,n,i,a,e[4],4118548399,7),a=Ki(a,r,n,i,e[5],1200080426,12),i=Ki(i,a,r,n,e[6],2821735955,17),n=Ki(n,i,a,r,e[7],4249261313,22),r=Ki(r,n,i,a,e[8],1770035416,7),a=Ki(a,r,n,i,e[9],2336552879,12),i=Ki(i,a,r,n,e[10],4294925233,17),n=Ki(n,i,a,r,e[11],2304563134,22),r=Ki(r,n,i,a,e[12],1804603682,7),a=Ki(a,r,n,i,e[13],4254626195,12),i=Ki(i,a,r,n,e[14],2792965006,17),n=Ki(n,i,a,r,e[15],1236535329,22),r=Gi(r,n,i,a,e[1],4129170786,5),a=Gi(a,r,n,i,e[6],3225465664,9),i=Gi(i,a,r,n,e[11],643717713,14),n=Gi(n,i,a,r,e[0],3921069994,20),r=Gi(r,n,i,a,e[5],3593408605,5),a=Gi(a,r,n,i,e[10],38016083,9),i=Gi(i,a,r,n,e[15],3634488961,14),n=Gi(n,i,a,r,e[4],3889429448,20),r=Gi(r,n,i,a,e[9],568446438,5),a=Gi(a,r,n,i,e[14],3275163606,9),i=Gi(i,a,r,n,e[3],4107603335,14),n=Gi(n,i,a,r,e[8],1163531501,20),r=Gi(r,n,i,a,e[13],2850285829,5),a=Gi(a,r,n,i,e[2],4243563512,9),i=Gi(i,a,r,n,e[7],1735328473,14),n=Gi(n,i,a,r,e[12],2368359562,20),r=Y
1981i(r,n,i,a,e[5],4294588738,4),a=Yi(a,r,n,i,e[8],2272392833,11),i=Yi(i,a,r,n,e[11],1839030562,16),n=Yi(n,i,a,r,e[14],4259657740,23),r=Yi(r,n,i,a,e[1],2763975236,4),a=Yi(a,r,n,i,e[4],1272893353,11),i=Yi(i,a,r,n,e[7],4139469664,16),n=Yi(n,i,a,r,e[10],3200236656,23),r=Yi(r,n,i,a,e[13],681279174,4),a=Yi(a,r,n,i,e[0],3936430074,11),i=Yi(i,a,r,n,e[3],3572445317,16),n=Yi(n,i,a,r,e[6],76029189,23),r=Yi(r,n,i,a,e[9],3654602809,4),a=Yi(a,r,n,i,e[12],3873151461,11),i=Yi(i,a,r,n,e[15],530742520,16),n=Yi(n,i,a,r,e[2],3299628645,23),r=Xi(r,n,i,a,e[0],4096336452,6),a=Xi(a,r,n,i,e[7],1126891415,10),i=Xi(i,a,r,n,e[14],2878612391,15),n=Xi(n,i,a,r,e[5],4237533241,21),r=Xi(r,n,i,a,e[12],1700485571,6),a=Xi(a,r,n,i,e[3],2399980690,10),i=Xi(i,a,r,n,e[10],4293915773,15),n=Xi(n,i,a,r,e[1],2240044497,21),r=Xi(r,n,i,a,e[8],1873313359,6),a=Xi(a,r,n,i,e[15],4264355552,10),i=Xi(i,a,r,n,e[6],2734768916,15),n=Xi(n,i,a,r,e[13],1309151649,21),r=Xi(r,n,i,a,e[4],4149444226,6),a=Xi(a,r,n,i,e[11],3174756917,10),i=Xi(i,a,r,n,e[2],718787259,15),n=Xi(n,i,a,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+i|0,this._d=this._d+a|0},Lw.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=ale.allocUnsafe(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e};function Dw(e,t){return e<<t|e>>>32-t}function Ki(e,t,r,n,i,a,s){return Dw(e+(t&r|~t&n)+i+a|0,s)+t|0}function Gi(e,t,r,n,i,a,s){return Dw(e+(t&n|r&~n)+i+a|0,s)+t|0}function Yi(e,t,r,n,i,a,s){return Dw(e+(t^r^n)+i+a|0,s)+t|0}function Xi(e,t,r,n,i,a,s){return Dw(e+(r^(t|~n))+i+a|0,s)+t|0}var a8=Lw,Uw=Qt.Buffer,dR=uR.Transform,ole=Zt;function lle(e,t){if(!Uw.isBuffer(e)&&typeof e!="string")throw new TypeError(t+" must be a string or a buffer")}function Bu(e){dR.call(this),this._block=Uw.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}ole(Bu,dR),Bu.prototype._transform=function(e,t,r){var n=null;try{this.update(e,t)}catch(i){n=i}r(n)},Bu.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(r){t=r}e(t)},Bu.prototype.update=function(e,t){if(lle(e,"Data"),this._finalized)throw new Error("Digest already called");Uw.isBuffer(e)||(e=Uw.from(e,t));for(var r=this._block,n=0;this._blockOffset+e.length-n>=this._blockSize;){for(var i=this._blockOffset;i<this._blockSize;)r[i++]=e[n++];this._update(),this._blockOffset=0}for(;n<e.length;)r[this._blockOffset++]=e[n++];for(var a=0,s=e.length*8;s>0;++a)this._length[a]+=s,s=this._length[a]/4294967296|0,s>0&&(this._length[a]-=4294967296*s);return this},Bu.prototype._update=function(){throw new Error("_update is not implemented")},Bu.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();e!==void 0&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return t},Bu.prototype._digest=function(){throw new Error("_digest is not implemented")};var cle=Bu,s8=ji.Buffer,ule=Zt,pR=cle,fle=new Array(16),Rg=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],Ng=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],Fg=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],Pg=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],zg=[0,1518500249,1859775393,2400959708,2840853838],Lg=[1352829926,1548603684,1836072691,2053994217,0];function qw(){pR.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}ule(qw,pR),qw.prototype._update=function(){for(var e=fle,t=0;t<16;++t)e[t]=this._block.readInt32LE(t*4);for(var r=this._a|0,n=this._b|0,i=this._c|0,a=this._d|0,s=this._e|0,o=this._a|0,c=this._b|0,l=this._c|0,u=this._d|0,d=this._e|0,p=0;p<80;p+=1){var w,O;
1981p<16?(w=mR(r,n,i,a,s,e[Rg[p]],zg[0],Fg[p]),O=vR(o,c,l,u,d,e[Ng[p]],Lg[0],Pg[p])):p<32?(w=gR(r,n,i,a,s,e[Rg[p]],zg[1],Fg[p]),O=yR(o,c,l,u,d,e[Ng[p]],Lg[1],Pg[p])):p<48?(w=bR(r,n,i,a,s,e[Rg[p]],zg[2],Fg[p]),O=bR(o,c,l,u,d,e[Ng[p]],Lg[2],Pg[p])):p<64?(w=yR(r,n,i,a,s,e[Rg[p]],zg[3],Fg[p]),O=gR(o,c,l,u,d,e[Ng[p]],Lg[3],Pg[p])):(w=vR(r,n,i,a,s,e[Rg[p]],zg[4],Fg[p]),O=mR(o,c,l,u,d,e[Ng[p]],Lg[4],Pg[p])),r=s,s=a,a=dh(i,10),i=n,n=w,o=d,d=u,u=dh(l,10),l=c,c=O}var I=this._b+i+u|0;this._b=this._c+a+d|0,this._c=this._d+s+o|0,this._d=this._e+r+c|0,this._e=this._a+n+l|0,this._a=I},qw.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=s8.alloc?s8.alloc(20):new s8(20);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e.writeInt32LE(this._e,16),e};function dh(e,t){return e<<t|e>>>32-t}function mR(e,t,r,n,i,a,s,o){return dh(e+(t^r^n)+a+s|0,o)+i|0}function gR(e,t,r,n,i,a,s,o){return dh(e+(t&r|~t&n)+a+s|0,o)+i|0}function bR(e,t,r,n,i,a,s,o){return dh(e+((t|~r)^n)+a+s|0,o)+i|0}function yR(e,t,r,n,i,a,s,o){return dh(e+(t&n|r&~n)+a+s|0,o)+i|0}function vR(e,t,r,n,i,a,s,o){return dh(e+(t^(r|~n))+a+s|0,o)+i|0}var o8=qw,wR={exports:{}},xR=Qt.Buffer;function Vw(e,t){this._block=xR.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}Vw.prototype.update=function(e,t){typeof e=="string"&&(t=t||"utf8",e=xR.from(e,t));for(var r=this._block,n=this._blockSize,i=e.length,a=this._len,s=0;s<i;){for(var o=a%n,c=Math.min(i-s,n-o),l=0;l<c;l++)r[o+l]=e[s+l];a+=c,s+=c,a%n===0&&this._update(r)}return this._len+=i,this},Vw.prototype.digest=function(e){var t=this._len%this._blockSize;this._block[t]=128,this._block.fill(0,t+1),t>=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=this._len*8;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(r&4294967295)>>>0,i=(r-n)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var a=this._hash();return e?a.toString(e):a},Vw.prototype._update=function(){throw new Error("_update must be implemented by subclass")};var x0=Vw,hle=Zt,_R=x0,dle=Qt.Buffer,ple=[1518500249,1859775393,-1894007588,-899497514],mle=new Array(80);function Dg(){this.init(),this._w=mle,_R.call(this,64,56)}hle(Dg,_R),Dg.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function gle(e){return e<<5|e>>>27}function ble(e){return e<<30|e>>>2}function yle(e,t,r,n){return e===0?t&r|~t&n:e===2?t&r|t&n|r&n:t^r^n}Dg.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,i=this._c|0,a=this._d|0,s=this._e|0,o=0;o<16;++o)t[o]=e.readInt32BE(o*4);for(;o<80;++o)t[o]=t[o-3]^t[o-8]^t[o-14]^t[o-16];for(var c=0;c<80;++c){var l=~~(c/20),u=gle(r)+yle(l,n,i,a)+s+t[c]+ple[l]|0;s=a,a=i,i=ble(n),n=r,r=u}this._a=r+this._a|0,this._b=n+this._b|0,this._c=i+this._c|0,this._d=a+this._d|0,this._e=s+this._e|0},Dg.prototype._hash=function(){var e=dle.allocUnsafe(20);return e.writeInt32BE(this._a|0,0),e.writeInt32BE(this._b|0,4),e.writeInt32BE(this._c|0,8),e.writeInt32BE(this._d|0,12),e.writeInt32BE(this._e|0,16),e};var vle=Dg,wle=Zt,SR=x0,xle=Qt.Buffer,_le=[1518500249,1859775393,-1894007588,-899497514],Sle=new Array(80);function Ug(){this.init(),this._w=Sle,SR.call(this,64,56)}wle(Ug,SR),Ug.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function kle(e){return e<<1|e>>>31}function Ele(e){return e<<5|e>>>27}function Mle(e){return e<<30|e>>>2}function Ale(e,t,r,n){return e===0?t&r|~t&n:e===2?t&r|t&n|r&n:t^r^n}Ug.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,i=this._c|0,a=this._d|0,s=this._e|0,o=0;o<16;++o)t[o]=e.readInt32BE(o*4);for(;o<80;++o)t[o]=kle(t[o-3]^t[o-8]^t[o-14]^t[o-16]);for(var c=0;c<80;++c){var l=~~(c/20),u=Ele(r)+Ale(l,n,i,a)+s+t[c]+_le[l]|0;s=a,a=i,i=Mle(n),n=r,r=u}this._a=r+this._a|0,this._b=n+this._b|0,this._c=i+this._c|0,this._d=a+this._d|0,this._e=s+this._e|0},Ug.prototype._hash=function(){var e=xle.allocUnsafe(20);return e.writeInt32BE(this._a|0,0),e.writeInt32BE(this._b|0,4),e.writeInt32BE(this._c|0,8),e.writeInt32BE(this._d|0,12),e.writeInt32BE(this._e|0,16),e};var Cle=Ug,Tle=Zt,kR=x0,jle=Qt.Buffer,Ile=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756
1981734187,3204031479,3329325298],Ole=new Array(64);function qg(){this.init(),this._w=Ole,kR.call(this,64,56)}Tle(qg,kR),qg.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this};function Ble(e,t,r){return r^e&(t^r)}function Rle(e,t,r){return e&t|r&(e|t)}function Nle(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function Fle(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function Ple(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}function zle(e){return(e>>>17|e<<15)^(e>>>19|e<<13)^e>>>10}qg.prototype._update=function(e){for(var t=this._w,r=this._a|0,n=this._b|0,i=this._c|0,a=this._d|0,s=this._e|0,o=this._f|0,c=this._g|0,l=this._h|0,u=0;u<16;++u)t[u]=e.readInt32BE(u*4);for(;u<64;++u)t[u]=zle(t[u-2])+t[u-7]+Ple(t[u-15])+t[u-16]|0;for(var d=0;d<64;++d){var p=l+Fle(s)+Ble(s,o,c)+Ile[d]+t[d]|0,w=Nle(r)+Rle(r,n,i)|0;l=c,c=o,o=s,s=a+p|0,a=i,i=n,n=r,r=p+w|0}this._a=r+this._a|0,this._b=n+this._b|0,this._c=i+this._c|0,this._d=a+this._d|0,this._e=s+this._e|0,this._f=o+this._f|0,this._g=c+this._g|0,this._h=l+this._h|0},qg.prototype._hash=function(){var e=jle.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e};var ER=qg,Lle=Zt,Dle=ER,Ule=x0,qle=Qt.Buffer,Vle=new Array(64);function Zw(){this.init(),this._w=Vle,Ule.call(this,64,56)}Lle(Zw,Dle),Zw.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},Zw.prototype._hash=function(){var e=qle.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e};var Zle=Zw,$le=Zt,MR=x0,Hle=Qt.Buffer,AR=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,
19811126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],Wle=new Array(160);function Vg(){this.init(),this._w=Wle,MR.call(this,128,112)}$le(Vg,MR),Vg.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this};function CR(e,t,r){return r^e&(t^r)}function TR(e,t,r){return e&t|r&(e|t)}function jR(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function IR(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function Kle(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function Gle(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function Yle(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function Xle(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function bi(e,t){return e>>>0<t>>>0?1:0}Vg.prototype._update=function(e){for(var t=this._w,r=this._ah|0,n=this._bh|0,i=this._ch|0,a=this._dh|0,s=this._eh|0,o=this._fh|0,c=this._gh|0,l=this._hh|0,u=this._al|0,d=this._bl|0,p=this._cl|0,w=this._dl|0,O=this._el|0,I=this._fl|0,R=this._gl|0,C=this._hl|0,j=0;j<32;j+=2)t[j]=e.readInt32BE(j*4),t[j+1]=e.readInt32BE(j*4+4);for(;j<160;j+=2){var N=t[j-30],P=t[j-15*2+1],Z=Kle(N,P),X=Gle(P,N);N=t[j-4],P=t[j-4+1];var re=Yle(N,P),ne=Xle(P,N),ae=t[j-7*2],ue=t[j-7*2+1],m=t[j-16*2],A=t[j-16*2+1],f=X+ue|0,g=Z+ae+bi(f,X)|0;f=f+ne|0,g=g+re+bi(f,ne)|0,f=f+A|0,g=g+m+bi(f,A)|0,t[j]=g,t[j+1]=f}for(var _=0;_<160;_+=2){g=t[_],f=t[_+1];var B=TR(r,n,i),T=TR(u,d,p),S=jR(r,u),h=jR(u,r),x=IR(s,O),v=IR(O,s),F=AR[_],Q=AR[_+1],G=CR(s,o,c),J=CR(O,I,R),Y=C+v|0,V=l+x+bi(Y,C)|0;Y=Y+J|0,V=V+G+bi(Y,J)|0,Y=Y+Q|0,V=V+F+bi(Y,Q)|0,Y=Y+f|0,V=V+g+bi(Y,f)|0;var W=h+T|0,ce=S+B+bi(W,h)|0;l=c,C=R,c=o,R=I,o=s,I=O,O=w+Y|0,s=a+V+bi(O,w)|0,a=i,w=p,i=n,p=d,n=r,d=u,u=Y+W|0,r=V+ce+bi(u,Y)|0}this._al=this._al+u|0,this._bl=this._bl+d|0,this._cl=this._cl+p|0,this._dl=this._dl+w|0,this._el=this._el+O|0,this._fl=this._fl+I|0,this._gl=this._gl+R|0,this._hl=this._hl+C|0,this._ah=this._ah+r+bi(this._al,u)|0,this._bh=this._bh+n+bi(this._bl,d)|0,this._ch=this._ch+i+bi(this._cl,p)|0,this._dh=this._dh+a+bi(this._dl,w)|0,this._eh=this._eh+s+bi(this._el,O)|0,this._fh=this._fh+o+bi(this._fl,I)|0,this._gh=this._gh+c+bi(this._gl,R)|0,this._hh=this._hh+l+bi(this._hl,C)|0},Vg.prototype._hash=function(){var e=Hle.allocUnsafe(64);function t(r,n,i){e.writeInt32BE(r,i),e.writeInt32BE(n,i+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e};var OR=Vg,Jle=Zt,Qle=OR,ece=x0,tce=Qt.Buffer,rce=new Array(160);function $w(){this.init(),this._w=rce,ece.call(this,128,112)}Jle($w,Qle),$w.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},$w.prototype._hash=function(){var e=tce.allocUnsafe(48);function t(r,n,i){e.writeInt32BE(r,i),e.writeInt32BE(n,i+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e};var nce=$w,ph=wR.exports=function(e){e=e.toLowerCase();var t=ph[e];if(!t)throw new Error(e+" is not supported (we accept pull requests)");return new t};ph.sha=vle,ph.sha1=Cle,ph.sha224=Zle,ph.sha256=ER,ph.sha384=nce,ph.sha512=OR;var l8=wR.exports,BR=Os,c8=jg.EventEmitter,ice=Zt;ice(Os,c8),Os.Readable=r8(),Os.Writable=Y4(),Os.Duplex=hh(),Os.Transform=n8,Os.PassThrough=aR,Os.finished=Nw,Os.pipeline=cR,Os.Stream=Os;function Os(){c8.call(this)}Os.prototype.pipe=function(e,t){var r=this;function n(u){e.writable&&e.write(u)===!1&&r.pause&&r.pause()}r.on("data",n);function i(){r.readable&&r.resume&&r.resume()}e.on("drain",i),!e._isStdio&&(!t||t.end!==!1)&&(r.on("end",s),r.on("close",o));var a=!1;function s(){a||(a=!0,e.end())}
1981function o(){a||(a=!0,typeof e.destroy=="function"&&e.destroy())}function c(u){if(l(),c8.listenerCount(this,"error")===0)throw u}r.on("error",c),e.on("error",c);function l(){r.removeListener("data",n),e.removeListener("drain",i),r.removeListener("end",s),r.removeListener("close",o),r.removeListener("error",c),e.removeListener("error",c),r.removeListener("end",l),r.removeListener("close",l),e.removeListener("close",l)}return r.on("end",l),r.on("close",l),e.on("close",l),e.emit("pipe",r),e};var yc=Qt.Buffer,RR=BR.Transform,ace=Ig.StringDecoder,sce=Zt;function uo(e){RR.call(this),this.hashMode=typeof e=="string",this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}sce(uo,RR);var oce=typeof Uint8Array<"u",lce=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u"&&ArrayBuffer.isView&&(yc.prototype instanceof Uint8Array||yc.TYPED_ARRAY_SUPPORT);function cce(e,t){if(e instanceof yc)return e;if(typeof e=="string")return yc.from(e,t);if(lce&&ArrayBuffer.isView(e)){if(e.byteLength===0)return yc.alloc(0);var r=yc.from(e.buffer,e.byteOffset,e.byteLength);if(r.byteLength===e.byteLength)return r}if(oce&&e instanceof Uint8Array||yc.isBuffer(e)&&e.constructor&&typeof e.constructor.isBuffer=="function"&&e.constructor.isBuffer(e))return yc.from(e);throw new TypeError('The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView.')}uo.prototype.update=function(e,t,r){var n=cce(e,t),i=this._update(n);return this.hashMode?this:(r&&(i=this._toString(i,r)),i)},uo.prototype.setAutoPadding=function(){},uo.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},uo.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},uo.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},uo.prototype._transform=function(e,t,r){var n;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(i){n=i}finally{r(n)}},uo.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(r){t=r}e(t)},uo.prototype._finalOrDigest=function(e){var t=this.__final()||yc.alloc(0);return e&&(t=this._toString(t,e,!0)),t},uo.prototype._toString=function(e,t,r){if(this._decoder||(this._decoder=new ace(t),this._encoding=t),this._encoding!==t)throw new Error("can\u2019t switch encodings");var n=this._decoder.write(e);return r&&(n+=this._decoder.end()),n};var _0=uo,uce=Zt,fce=a8,hce=o8,dce=l8,NR=_0;function Hw(e){NR.call(this,"digest"),this._hash=e}uce(Hw,NR),Hw.prototype._update=function(e){this._hash.update(e)},Hw.prototype._final=function(){return this._hash.digest()};var Zg=function(e){return e=e.toLowerCase(),e==="md5"?new fce:e==="rmd160"||e==="ripemd160"?new hce:new Hw(dce(e))},FR=Qt.Buffer,PR=BR.Transform,pce=Ig.StringDecoder,mce=Zt;function fo(e){PR.call(this),this.hashMode=typeof e=="string",this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}mce(fo,PR),fo.prototype.update=function(e,t,r){typeof e=="string"&&(e=FR.from(e,t));var n=this._update(e);return this.hashMode?this:(r&&(n=this._toString(n,r)),n)},fo.prototype.setAutoPadding=function(){},fo.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},fo.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},fo.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},fo.prototype._transform=function(e,t,r){var n;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(i){n=i}finally{r(n)}},fo.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(r){t=r}e(t)},fo.prototype._finalOrDigest=function(e){var t=this.__final()||FR.alloc(0);return e&&(t=this._toString(t,e,!0)),t},fo.prototype._toString=function(e,t,r){if(this._decoder||(this._decoder=new pce(t),this._encoding=t),this._encoding!==t)throw new Error("can't switch encodings");var n=this._decoder.write(e);return r&&(n+=this._decoder.end()),n};var zR=fo,gce=Zt,mh=Qt.Buffer,LR=zR,bce=mh.alloc(128),S0=64;function Ww(e,t){LR.call(this,"digest"),typeof t=="string"&&(t=mh.from(t)),this._alg=e,this._key=t,t.length>S0?t=e(t):t.length<S0&&(t=mh.concat([t,bce],S0));for(var r=this._ipad=mh.allocUnsafe(S0),n=this._opad=mh.allocUnsafe(S0),i=0;i<S0;i++)r[i]=t[i]^54,n[i]=t[i]^92;this._hash=[r]}gce(Ww,LR),Ww.prototype._update=function(e){this._hash.push(e)},Ww.prototype._final=function(){var e=this._alg(mh.concat(this._hash));return this._alg(mh.concat([this._opad,e]))};var yce=Ww,vce=a8,DR=function(e){return new vce().update(e).digest()},wce=Zt,xce=yce,UR=zR,$g=Qt.Buffer,_ce=DR,u8=o8,f8=l8,Sce=$g.alloc(128);function Hg(e,t){UR.call(this,"digest"),typeof t=="string"&&(t=$g.from(t));var r=e==="sha512"||e==="sha384"?128:64;if(this._alg=e,this._key=t,t.length>r){var n=e==="rmd160"?new u8:f8(e);t=n.update(t).digest()}else t.length<r&&(t=$g.concat([t,Sce],r));for(var i=this._ipad=$g.allocUnsafe(r),a=this._opad=$g.allocUnsafe(r),s=0;s<r;s++)i[s]=t[s]^54,a[s]=t[s]^92;this._hash=e==="rmd160"?new u8:f8(e),this._hash.update(i)}wce(Hg,UR),Hg.prototype._update=function(e){this._hash.update(e)},Hg.prototype._final=function(){var e=this._hash.digest(),t=this._alg==="rmd160"?new u8:f8(this._alg);return t.update(this._opad).update(e).digest()};var qR=function(e,t){return e=e.toLowerCase(),e==="rmd160"||e==="ripemd160"?new Hg("rmd160",t):e==="md5"?new xce(_ce,t):new Hg(e,t)};const kce={sign:"rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},Ece={sign:"rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},Mce={sign:"rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},Ace={sign:"rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},Cce={sign:"ecdsa",hash:"sha256",id:""},Tce={sign:"ecdsa",hash:"sha224",id:""},jce={sign:"ecdsa",hash:"sha384",id:""},Ice={sign:"ecdsa",hash:"sha512",id:""},Oce={sign:"dsa",hash:"sha1",id:""},Bce={sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"}
1981,Rce={sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"},VR={sha224WithRSAEncryption:kce,"RSA-SHA224":{sign:"ecdsa/rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},sha256WithRSAEncryption:Ece,"RSA-SHA256":{sign:"ecdsa/rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},sha384WithRSAEncryption:Mce,"RSA-SHA384":{sign:"ecdsa/rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},sha512WithRSAEncryption:Ace,"RSA-SHA512":{sign:"ecdsa/rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA1":{sign:"rsa",hash:"sha1",id:"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{sign:"ecdsa",hash:"sha1",id:""},sha256:Cce,sha224:Tce,sha384:jce,sha512:Ice,"DSA-SHA":{sign:"dsa",hash:"sha1",id:""},"DSA-SHA1":{sign:"dsa",hash:"sha1",id:""},DSA:Oce,"DSA-WITH-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-WITH-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-WITH-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-WITH-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-RIPEMD160":{sign:"dsa",hash:"rmd160",id:""},ripemd160WithRSA:Bce,"RSA-RIPEMD160":{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},md5WithRSAEncryption:Rce,"RSA-MD5":{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"}};var Nce=VR,Kw={},Fce=Math.pow(2,30)-1,ZR=function(e,t){if(typeof e!="number")throw new TypeError("Iterations not a number");if(e<0)throw new TypeError("Bad iterations");
1981if(typeof t!="number")throw new TypeError("Key length not a number");if(t<0||t>Fce||t!==t)throw new TypeError("Bad key length")},Gw;if(dt.process&&dt.process.browser)Gw="utf-8";else if(dt.process&&dt.process.version){var Pce=parseInt(ot.version.split(".")[0].slice(1),10);Gw=Pce>=6?"utf-8":"binary"}else Gw="utf-8";var $R=Gw,h8=Qt.Buffer,HR=function(e,t,r){if(h8.isBuffer(e))return e;if(typeof e=="string")return h8.from(e,t);if(ArrayBuffer.isView(e))return h8.from(e.buffer);throw new TypeError(r+" must be a string, a Buffer, a typed array or a DataView")},zce=DR,Lce=o8,Dce=l8,gh=Qt.Buffer,Uce=ZR,WR=$R,KR=HR,qce=gh.alloc(128),Yw={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function GR(e,t,r){var n=Vce(e),i=e==="sha512"||e==="sha384"?128:64;t.length>i?t=n(t):t.length<i&&(t=gh.concat([t,qce],i));for(var a=gh.allocUnsafe(i+Yw[e]),s=gh.allocUnsafe(i+Yw[e]),o=0;o<i;o++)a[o]=t[o]^54,s[o]=t[o]^92;var c=gh.allocUnsafe(i+r+4);a.copy(c,0,0,i),this.ipad1=c,this.ipad2=a,this.opad=s,this.alg=e,this.blocksize=i,this.hash=n,this.size=Yw[e]}GR.prototype.run=function(e,t){e.copy(t,this.blocksize);var r=this.hash(t);return r.copy(this.opad,this.blocksize),this.hash(this.opad)};function Vce(e){function t(n){return Dce(e).update(n).digest()}function r(n){return new Lce().update(n).digest()}return e==="rmd160"||e==="ripemd160"?r:e==="md5"?zce:t}function Zce(e,t,r,n,i){Uce(r,n),e=KR(e,WR,"Password"),t=KR(t,WR,"Salt"),i=i||"sha1";var a=new GR(i,e,t.length),s=gh.allocUnsafe(n),o=gh.allocUnsafe(t.length+4);t.copy(o,0,0,t.length);for(var c=0,l=Yw[i],u=Math.ceil(n/l),d=1;d<=u;d++){o.writeUInt32BE(d,t.length);for(var p=a.run(o,a.ipad1),w=p,O=1;O<r;O++){w=a.run(w,a.ipad2);for(var I=0;I<l;I++)p[I]^=w[I]}p.copy(s,c),c+=l}return s}var YR=Zce,XR=Qt.Buffer,$ce=ZR,JR=$R,QR=YR,eN=HR,Xw,Wg=dt.crypto&&dt.crypto.subtle,Hce={
1981sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},d8=[];function Wce(e){if(dt.process&&!dt.process.browser||!Wg||!Wg.importKey||!Wg.deriveBits)return Promise.resolve(!1);if(d8[e]!==void 0)return d8[e];Xw=Xw||XR.alloc(8);var t=tN(Xw,Xw,10,128,e).then(function(){return!0}).catch(function(){return!1});return d8[e]=t,t}var k0;function p8(){return k0||(dt.process&&dt.process.nextTick?k0=dt.process.nextTick:dt.queueMicrotask?k0=dt.queueMicrotask:dt.setImmediate?k0=dt.setImmediate:k0=dt.setTimeout,k0)}function tN(e,t,r,n,i){return Wg.importKey("raw",e,{name:"PBKDF2"},!1,["deriveBits"]).then(function(a){return Wg.deriveBits({name:"PBKDF2",salt:t,iterations:r,hash:{name:i}},a,n<<3)}).then(function(a){return XR.from(a)})}function Kce(e,t){e.then(function(r){p8()(function(){t(null,r)})},function(r){p8()(function(){t(r)})})}var Gce=function(e,t,r,n,i,a){typeof i=="function"&&(a=i,i=void 0),i=i||"sha1";var s=Hce[i.toLowerCase()];if(!s||typeof dt.Promise!="function"){p8()(function(){var o;try{o=QR(e,t,r,n,i)}catch(c){return a(c)}a(null,o)});return}if($ce(r,n),e=eN(e,JR,"Password"),t=eN(t,JR,"Salt"),typeof a!="function")throw new Error("No callback provided to pbkdf2");Kce(Wce(s).then(function(o){return o?tN(e,t,r,n,s):QR(e,t,r,n,i)}),a)};Kw.pbkdf2=Gce,Kw.pbkdf2Sync=YR;var ho={},E0={},ts={};ts.readUInt32BE=function(e,t){var r=e[0+t]<<24|e[1+t]<<16|e[2+t]<<8|e[3+t];return r>>>0},ts.writeUInt32BE=function(e,t,r){e[0+r]=t>>>24,e[1+r]=t>>>16&255,e[2+r]=t>>>8&255,e[3+r]=t&255},ts.ip=function(e,t,r,n){for(var i=0,a=0,s=6;s>=0;s-=2){for(var o=0;o<=24;o+=8)i<<=1,i|=t>>>o+s&1;for(var o=0;o<=24;o+=8)i<<=1,i|=e>>>o+s&1}for(var s=6;s>=0;s-=2){for(var o=1;o<=25;o+=8)a<<=1,a|=t>>>o+s&1;for(var o=1;o<=25;o+=8)a<<=1,a|=e>>>o+s&1}r[n+0]=i>>>0,r[n+1]=a>>>0},ts.rip=function(e,t,r,n){for(var i=0,a=0,s=0;s<4;s++)for(var o=24;o>=0;o-=8)i<<=1,i|=t>>>o+s&1,i<<=1,i|=e>>>o+s&1;for(var s=4;s<8;s++)for(var o=24;o>=0;o-=8)a<<=1,a|=t>>>o+s&1,a<<=1,a|=e>>>o+s&1;r[n+0]=i>>>0,r[n+1]=a>>>0},ts.pc1=function(e,t,r,n){for(var i=0,a=0,s=7;s>=5;s--){for(var o=0;o<=24;o+=8)i<<=1,i|=t>>o+s&1;for(var o=0;o<=24;o+=8)i<<=1,i|=e>>o+s&1}for(var o=0;o<=24;o+=8)i<<=1,i|=t>>o+s&1;for(var s=1;s<=3;s++){for(var o=0;o<=24;o+=8)a<<=1,a|=t>>o+s&1;for(var o=0;o<=24;o+=8)a<<=1,a|=e>>o+s&1}for(var o=0;o<=24;o+=8)a<<=1,a|=e>>o+s&1;r[n+0]=i>>>0,r[n+1]=a>>>0},ts.r28shl=function(e,t){return e<<t&268435455|e>>>28-t};var Jw=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];ts.pc2=function(e,t,r,n){for(var i=0,a=0,s=Jw.length>>>1,o=0;o<s;o++)i<<=1,i|=e>>>Jw[o]&1;for(var o=s;o<Jw.length;o++)a<<=1,a|=t>>>Jw[o]&1;r[n+0]=i>>>0,r[n+1]=a>>>0},ts.expand=function(e,t,r){var n=0,i=0;n=(e&1)<<5|e>>>27;for(var a=23;a>=15;a-=4)n<<=6,n|=e>>>a&63;for(var a=11;a>=3;a-=4)i|=e>>>a&63,i<<=6;i|=(e&31)<<1|e>>>31,t[r+0]=n>>>0,t[r+1]=i>>>0};var rN=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];ts.substitute=function(e,t){for(var r=0,n=0;n<4;n++){var i=e>>>18-n*6&63,a=rN[n*64+i];r<<=4,r|=a}for(var n=0;n<4;n++){var i=t>>>18-n*6&63,a=rN[4*64+n*64+i];r<<=4,r|=a}return r>>>0};var nN=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];ts.permute=function(e){for(var t=0,r=0;r<nN.length;r++)t<<=1,t|=e>>>nN[r]&1;return t>>>0},ts.padSplit=function(e,t,r){for(var n=e.toString(2);n.length<t;)n="0"+n;for(var i=[],a=0;a<t;a+=r)i.push(n.slice(a,a+r));return i.join(" ")};var Bs=iN;function iN(e,t){if(!e)throw new Error(t||"Assertion failed")}iN.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var Yce=Bs;function Rs(e){this.options=e,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0,this.padding=e.padding!==!1}var m8=Rs;Rs.prototype._init=function(){},Rs.prototype.update=function(e){return e.length===0?[]:this.type==="decrypt"?this._updateDecrypt(e):this._updateEncrypt(e)},Rs.prototype._buffer=function(e,t){for(var r=Math.min(this.buffer.length-this.bufferOff,e.length-t),n=0;n<r;n++)this.buffer[this.bufferOff+n]=e[t+n];return this.bufferOff+=r,r},Rs.prototype._flushBuffer=function(e,t){return this._update(this.buffer,0,e,t),this.bufferOff=0,this.blockSize},Rs.prototype._updateEncrypt=function(e){var t=0,r=0,n=(this.bufferOff+e.length)/this.blockSize|0,i=new Array(n*this.blockSize);this.bufferOff!==0&&(t+=this._buffer(e,t),this.bufferOff===this.buffer.length&&(r+=this._flushBuffer(i,r)));for(var a=e.length-(e.length-t)%this.blockSize;t<a;t+=this.blockSize)this._update(e,t,i,r),r+=this.blockSize;for(;t<e.length;t++,this.bufferOff++)this.buffer[this.bufferOff]=e[t];return i},Rs.prototype._updateDecrypt=function(e){for(var t=0,r=0,n=Math.ceil((this.bufferOff+e.length)/this.blockSize)-1,i=new Array(n*this.blockSize);n>0;n--)t+=this._buffer(e,t),r+=this._flushBuffer(i,r);return t+=this._buffer(e,t),i},Rs.prototype.final=function(e){var t;e&&(t=this.update(e));var r;return this.type==="encrypt"?r=this._finalEncrypt():r=this._finalDecrypt(),t?t.concat(r):r},Rs.prototype._pad=function(e,t){if(t===0)return!1;for(;t<e.length;)e[t++]=0;return!0},Rs.prototype._finalEncrypt=function(){if(!this._pad(this.buffer,this.bufferOff))return[];var e=new Array(this.blockSize);return this._update(this.buffer,0,e,0),e},Rs.prototype._unpad=function(e){return e},Rs.prototype._finalDecrypt=function(){Yce.equal(this.bufferOff,this.blockSize,"Not enough data to decrypt");var e=new Array(this.blockSize);return this._flushBuffer(e,0),this._unpad(e)};var aN=Bs,Xce=Zt,ai=ts,sN=m8;
1981function Jce(){this.tmp=new Array(2),this.keys=null}function sl(e){sN.call(this,e);var t=new Jce;this._desState=t,this.deriveKeys(t,e.key)}Xce(sl,sN);var oN=sl;sl.create=function(e){return new sl(e)};var Qce=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];sl.prototype.deriveKeys=function(e,t){e.keys=new Array(32),aN.equal(t.length,this.blockSize,"Invalid key length");var r=ai.readUInt32BE(t,0),n=ai.readUInt32BE(t,4);ai.pc1(r,n,e.tmp,0),r=e.tmp[0],n=e.tmp[1];for(var i=0;i<e.keys.length;i+=2){var a=Qce[i>>>1];r=ai.r28shl(r,a),n=ai.r28shl(n,a),ai.pc2(r,n,e.keys,i)}},sl.prototype._update=function(e,t,r,n){var i=this._desState,a=ai.readUInt32BE(e,t),s=ai.readUInt32BE(e,t+4);ai.ip(a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],this.type==="encrypt"?this._encrypt(i,a,s,i.tmp,0):this._decrypt(i,a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],ai.writeUInt32BE(r,a,n),ai.writeUInt32BE(r,s,n+4)},sl.prototype._pad=function(e,t){if(this.padding===!1)return!1;for(var r=e.length-t,n=t;n<e.length;n++)e[n]=r;return!0},sl.prototype._unpad=function(e){if(this.padding===!1)return e;for(var t=e[e.length-1],r=e.length-t;r<e.length;r++)aN.equal(e[r],t);return e.slice(0,e.length-t)},sl.prototype._encrypt=function(e,t,r,n,i){for(var a=t,s=r,o=0;o<e.keys.length;o+=2){var c=e.keys[o],l=e.keys[o+1];ai.expand(s,e.tmp,0),c^=e.tmp[0],l^=e.tmp[1];var u=ai.substitute(c,l),d=ai.permute(u),p=s;s=(a^d)>>>0,a=p}ai.rip(s,a,n,i)},sl.prototype._decrypt=function(e,t,r,n,i){for(var a=r,s=t,o=e.keys.length-2;o>=0;o-=2){var c=e.keys[o],l=e.keys[o+1];ai.expand(a,e.tmp,0),c^=e.tmp[0],l^=e.tmp[1];var u=ai.substitute(c,l),d=ai.permute(u),p=a;a=(s^d)>>>0,s=p}ai.rip(a,s,n,i)};var lN={},eue=Bs,tue=Zt,Qw={};function rue(e){eue.equal(e.length,8,"Invalid IV length"),this.iv=new Array(8);for(var t=0;t<this.iv.length;t++)this.iv[t]=e[t]}function nue(e){function t(a){e.call(this,a),this._cbcInit()}tue(t,e);for(var r=Object.keys(Qw),n=0;n<r.length;n++){var i=r[n];t.prototype[i]=Qw[i]}return t.create=function(a){return new t(a)},t}lN.instantiate=nue,Qw._cbcInit=function(){var e=new rue(this.options.iv);this._cbcState=e},Qw._update=function(e,t,r,n){var i=this._cbcState,a=this.constructor.super_.prototype,s=i.iv;if(this.type==="encrypt"){for(var o=0;o<this.blockSize;o++)s[o]^=e[t+o];a._update.call(this,s,0,r,n);for(var o=0;o<this.blockSize;o++)s[o]=r[n+o]}else{a._update.call(this,e,t,r,n);for(var o=0;o<this.blockSize;o++)r[n+o]^=s[o];for(var o=0;o<this.blockSize;o++)s[o]=e[t+o]}};var iue=Bs,aue=Zt,cN=m8,Ru=oN;function sue(e,t){iue.equal(t.length,24,"Invalid key length");var r=t.slice(0,8),n=t.slice(8,16),i=t.slice(16,24);e==="encrypt"?this.ciphers=[Ru.create({type:"encrypt",key:r}),Ru.create({type:"decrypt",key:n}),Ru.create({type:"encrypt",key:i})]:this.ciphers=[Ru.create({type:"decrypt",key:i}),Ru.create({type:"encrypt",key:n}),Ru.create({type:"decrypt",key:r})]}function bh(e){cN.call(this,e);var t=new sue(this.type,this.options.key);this._edeState=t}aue(bh,cN);var oue=bh;bh.create=function(e){return new bh(e)},bh.prototype._update=function(e,t,r,n){var i=this._edeState;i.ciphers[0]._update(e,t,r,n),i.ciphers[1]._update(r,n,r,n),i.ciphers[2]._update(r,n,r,n)},bh.prototype._pad=Ru.prototype._pad,bh.prototype._unpad=Ru.prototype._unpad,E0.utils=ts,E0.Cipher=m8,E0.DES=oN,E0.CBC=lN,E0.EDE=oue;var uN=_0,vc=E0,lue=Zt,yh=Qt.Buffer,Kg={"des-ede3-cbc":vc.CBC.instantiate(vc.EDE),"des-ede3":vc.EDE,"des-ede-cbc":vc.CBC.instantiate(vc.EDE),"des-ede":vc.EDE,"des-cbc":vc.CBC.instantiate(vc.DES),"des-ecb":vc.DES};Kg.des=Kg["des-cbc"],Kg.des3=Kg["des-ede3-cbc"];var cue=ex;lue(ex,uN);function ex(e){uN.call(this);var t=e.mode.toLowerCase(),r=Kg[t],n;e.decrypt?n="decrypt":n="encrypt";var i=e.key;yh.isBuffer(i)||(i=yh.from(i)),(t==="des-ede"||t==="des-ede-cbc")&&(i=yh.concat([i,i.slice(0,8)]));var a=e.iv;yh.isBuffer(a)||(a=yh.from(a)),this._des=r.create({key:i,iv:a,type:n})}ex.prototype._update=function(e){return yh.from(this._des.update(e))},ex.prototype._final=function(){return yh.from(this._des.final())};var rs={},g8={},b8={};b8.encrypt=function(e,t){return e._cipher.encryptBlock(t)},b8.decrypt=function(e,t){return e._cipher.decryptBlock(t)};var y8={},Gg=function(e,t){for(var r=Math.min(e.length,t.length),n=new je(r),i=0;i<r;++i)n[i]=e[i]^t[i];return n},fN=Gg;y8.encrypt=function(e,t){var r=fN(t,e._prev);return e._prev=e._cipher.encryptBlock(r),e._prev},y8.decrypt=function(e,t){var r=e._prev;e._prev=t;var n=e._cipher.decryptBlock(t);return fN(n,r)};var hN={},Yg=Qt.Buffer,uue=Gg;function dN(e,t,r){var n=t.length,i=uue(t,e._cache);return e._cache=e._cache.slice(n),e._prev=Yg.concat([e._prev,r?t:i]),i}hN.encrypt=function(e,t,r){for(var n=Yg.allocUnsafe(0),i;t.length;)if(e._cache.length===0&&(e._cache=e._cipher.encryptBlock(e._prev),e._prev=Yg.allocUnsafe(0)),e._cache.length<=t.length)i=e._cache.length,n=Yg.concat([n,dN(e,t.slice(0,i),r)]),t=t.slice(i);else{n=Yg.concat([n,dN(e,t,r)]);break}return n};var pN={},v8=Qt.Buffer;function fue(e,t,r){var n=e._cipher.encryptBlock(e._prev),i=n[0]^t;return e._prev=v8.concat([e._prev.slice(1),v8.from([r?t:i])]),i}pN.encrypt=function(e,t,r){for(var n=t.length,i=v8.allocUnsafe(n),a=-1;++a<n;)i[a]=fue(e,t[a],r);return i};var mN={},tx=Qt.Buffer;function hue(e,t,r){for(var n,i=-1,a=8,s=0,o,c;++i<a;)n=e._cipher.encryptBlock(e._prev),o=t&1<<7-i?128:0,c=n[0]^o,s+=(c&128)>>i%8,e._prev=due(e._prev,r?o:c);return s}function due(e,t){var r=e.length,n=-1,i=tx.allocUnsafe(e.length);for(e=tx.concat([e,tx.from([t])]);++n<r;)i[n]=e[n]<<1|e[n+1]>>7;return i}mN.encrypt=function(e,t,r){for(var n=t.length,i=tx.allocUnsafe(n),a=-1;++a<n;)i[a]=hue(e,t[a],r);return i};var gN={},pue=Gg;function mue(e){return e._prev=e._cipher.encryptBlock(e._prev),e._prev}gN.encrypt=function(e,t){for(;e._cache.length<t.length;)e._cache=je.concat([e._cache,mue(e)]);var r=e._cache.slice(0,t.length);return e._cache=e._cache.slice(t.length),pue(t,r)};var w8={};function gue(e){for(var t=e.length,r;t--;)if(r=e.readUInt8(t),r===255)e.writeUInt8(0,t);else{r++,e.writeUInt8(r,t);break}}var bN=gue,bue=Gg,yN=Qt.Buffer,yue=bN;function vue(e){var t=e._cipher.encryptBlockRaw(e._prev);return yue(e._prev),t}var x8=16;w8.encrypt=function(e,t){var r=Math.ceil(t.length/x8),n=e._cache.length;e._cache=yN.concat([e._cache,yN.allocUnsafe(r*x8)]);for(var i=0;i<r;i++){var a=vue(e),s=n+i*x8;e._cache.writeUInt32BE(a[0],s+0),e._cache.writeUInt32BE(a[1],s+4),e._cache.writeUInt32BE(a[2],s+8),e._cache.writeUInt32BE(a[3],s+12)}var o=e._cache.slice(0,t.length);return e._cache=e._cache.slice(t.length),bue(t,o)};const wue={cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},xue={cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},_ue={cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},vN={"aes-128-ecb":{cipher:"AES",key:128,iv:0,mode:"ECB",type:"block"},"aes-192-ecb":{cipher:"AES",key:192,iv:0,mode:"ECB",type:"block"},"aes-256-ecb":{cipher:"AES",key:256,iv:0,mode:"ECB",type:"block"},"aes-128-cbc":{cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},"aes-192-cbc":{cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},"aes-256-cbc":{cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},aes128:wue,aes192:xue,aes256:_ue,"aes-128-cfb":{cipher:"AES",key:128,iv:16,mode:"CFB",type:"stream"},"aes-192-cfb":{cipher:"AES",key:192,iv:16,mode:"CFB",type:"stream"},"aes-256-cfb":{cipher:"AES",key:256,iv:16,mode:"CFB",type:"stream"},"aes-128-cfb8":{cipher:"AES",key:128,iv:16,mode:"CFB8",type:"stream"},"aes-192-cfb8":{cipher:"AES",key:192,iv:16,mode:"CFB8",type:"stream"},"aes-256-cfb8":{cipher:"AES",key:256,iv:16,mode:"CFB8",type:"stream"},"aes-128-cfb1":{cipher:"AES",key:128,iv:16,mode:"CFB1",type:"stream"},"aes-192-cfb1":{cipher:"AES",key:192,iv:16,mode:"CFB1",type:"stream"},"aes-256-cfb1":{cipher:"AES",key:256,iv:16,mode:"CFB1",type:"stream"},"aes-128-ofb":{cipher:"AES",key:128,iv:16,mode:"OFB",type:"stream"},"aes-192-ofb":{cipher:"AES",key:192,iv:16,mode:"OFB",type:"stream"},"aes-256-ofb":{cipher:"AES",key:256,iv:16,mode:"OFB",type:"stream"},"aes-128-ctr":{cipher:"AES",key:128,iv:16,mode:"CTR",type:"stream"},"aes-192-ctr":{cipher:"AES",key:192,iv:16,mode:"CTR",type:"stream"},"aes-256-ctr":{cipher:"AES",key:256,iv:16,mode:"CTR",type:"stream"},"aes-128-gcm":{cipher:"AES",key:128,iv:12,mode:"GCM",type:"auth"},"aes-192-gcm":{cipher:"AES",key:192,iv:12,mode:"GCM",type:"auth"},"aes-256-gcm":{cipher:"AES",key:256,iv:12,mode:"GCM",type:"auth"}};
1981var Sue={ECB:b8,CBC:y8,CFB:hN,CFB8:pN,CFB1:mN,OFB:gN,CTR:w8,GCM:w8},rx=vN;for(var wN in rx)rx[wN].module=Sue[rx[wN].mode];var _8=rx,Xg={},nx=Qt.Buffer;function S8(e){nx.isBuffer(e)||(e=nx.from(e));for(var t=e.length/4|0,r=new Array(t),n=0;n<t;n++)r[n]=e.readUInt32BE(n*4);return r}function k8(e){for(var t=0;t<e.length;e++)e[t]=0}function xN(e,t,r,n,i){for(var a=r[0],s=r[1],o=r[2],c=r[3],l=e[0]^t[0],u=e[1]^t[1],d=e[2]^t[2],p=e[3]^t[3],w,O,I,R,C=4,j=1;j<i;j++)w=a[l>>>24]^s[u>>>16&255]^o[d>>>8&255]^c[p&255]^t[C++],O=a[u>>>24]^s[d>>>16&255]^o[p>>>8&255]^c[l&255]^t[C++],I=a[d>>>24]^s[p>>>16&255]^o[l>>>8&255]^c[u&255]^t[C++],R=a[p>>>24]^s[l>>>16&255]^o[u>>>8&255]^c[d&255]^t[C++],l=w,u=O,d=I,p=R;return w=(n[l>>>24]<<24|n[u>>>16&255]<<16|n[d>>>8&255]<<8|n[p&255])^t[C++],O=(n[u>>>24]<<24|n[d>>>16&255]<<16|n[p>>>8&255]<<8|n[l&255])^t[C++],I=(n[d>>>24]<<24|n[p>>>16&255]<<16|n[l>>>8&255]<<8|n[u&255])^t[C++],R=(n[p>>>24]<<24|n[l>>>16&255]<<16|n[u>>>8&255]<<8|n[d&255])^t[C++],w=w>>>0,O=O>>>0,I=I>>>0,R=R>>>0,[w,O,I,R]}var kue=[0,1,2,4,8,16,32,64,128,27,54],Zn=function(){for(var e=new Array(256),t=0;t<256;t++)t<128?e[t]=t<<1:e[t]=t<<1^283;for(var r=[],n=[],i=[[],[],[],[]],a=[[],[],[],[]],s=0,o=0,c=0;c<256;++c){var l=o^o<<1^o<<2^o<<3^o<<4;l=l>>>8^l&255^99,r[s]=l,n[l]=s;var u=e[s],d=e[u],p=e[d],w=e[l]*257^l*16843008;i[0][s]=w<<24|w>>>8,i[1][s]=w<<16|w>>>16,i[2][s]=w<<8|w>>>24,i[3][s]=w,w=p*16843009^d*65537^u*257^s*16843008,a[0][l]=w<<24|w>>>8,a[1][l]=w<<16|w>>>16,a[2][l]=w<<8|w>>>24,a[3][l]=w,s===0?s=o=1:(s=u^e[e[e[p^u]]],o^=e[e[o]])}return{SBOX:r,INV_SBOX:n,SUB_MIX:i,INV_SUB_MIX:a}}();function Ns(e){this._key=S8(e),this._reset()}Ns.blockSize=16,Ns.keySize=32,Ns.prototype.blockSize=Ns.blockSize,Ns.prototype.keySize=Ns.keySize,Ns.prototype._reset=function(){for(var e=this._key,t=e.length,r=t+6,n=(r+1)*4,i=[],a=0;a<t;a++)i[a]=e[a];for(a=t;a<n;a++){var s=i[a-1];a%t===0?(s=s<<8|s>>>24,s=Zn.SBOX[s>>>24]<<24|Zn.SBOX[s>>>16&255]<<16|Zn.SBOX[s>>>8&255]<<8|Zn.SBOX[s&255],s^=kue[a/t|0]<<24):t>6&&a%t===4&&(s=Zn.SBOX[s>>>24]<<24|Zn.SBOX[s>>>16&255]<<16|Zn.SBOX[s>>>8&255]<<8|Zn.SBOX[s&255]),i[a]=i[a-t]^s}for(var o=[],c=0;c<n;c++){var l=n-c,u=i[l-(c%4?0:4)];c<4||l<=4?o[c]=u:o[c]=Zn.INV_SUB_MIX[0][Zn.SBOX[u>>>24]]^Zn.INV_SUB_MIX[1][Zn.SBOX[u>>>16&255]]^Zn.INV_SUB_MIX[2][Zn.SBOX[u>>>8&255]]^Zn.INV_SUB_MIX[3][Zn.SBOX[u&255]]}this._nRounds=r,this._keySchedule=i,this._invKeySchedule=o},Ns.prototype.encryptBlockRaw=function(e){return e=S8(e),xN(e,this._keySchedule,Zn.SUB_MIX,Zn.SBOX,this._nRounds)},Ns.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),r=nx.allocUnsafe(16);return r.writeUInt32BE(t[0],0),r.writeUInt32BE(t[1],4),r.writeUInt32BE(t[2],8),r.writeUInt32BE(t[3],12),r},Ns.prototype.decryptBlock=function(e){e=S8(e);var t=e[1];e[1]=e[3],e[3]=t;var r=xN(e,this._invKeySchedule,Zn.INV_SUB_MIX,Zn.INV_SBOX,this._nRounds),n=nx.allocUnsafe(16);return n.writeUInt32BE(r[0],0),n.writeUInt32BE(r[3],4),n.writeUInt32BE(r[2],8),n.writeUInt32BE(r[1],12),n},Ns.prototype.scrub=function(){k8(this._keySchedule),k8(this._invKeySchedule),k8(this._key)},Xg.AES=Ns;var M0=Qt.Buffer,Eue=M0.alloc(16,0);function Mue(e){return[e.readUInt32BE(0),e.readUInt32BE(4),e.readUInt32BE(8),e.readUInt32BE(12)]}function _N(e){var t=M0.allocUnsafe(16);return t.writeUInt32BE(e[0]>>>0,0),t.writeUInt32BE(e[1]>>>0,4),t.writeUInt32BE(e[2]>>>0,8),t.writeUInt32BE(e[3]>>>0,12),t}function Jg(e){this.h=e,this.state=M0.alloc(16,0),this.cache=M0.allocUnsafe(0)}Jg.prototype.ghash=function(e){for(var t=-1;++t<e.length;)this.state[t]^=e[t];this._multiply()},Jg.prototype._multiply=function(){for(var e=Mue(this.h),t=[0,0,0,0],r,n,i,a=-1;++a<128;){for(n=(this.state[~~(a/8)]&1<<7-a%8)!==0,n&&(t[0]^=e[0],t[1]^=e[1],t[2]^=e[2],t[3]^=e[3]),i=(e[3]&1)!==0,r=3;r>0;r--)e[r]=e[r]>>>1|(e[r-1]&1)<<31;e[0]=e[0]>>>1,i&&(e[0]=e[0]^-520093696)}this.state=_N(t)},Jg.prototype.update=function(e){this.cache=M0.concat([this.cache,e]);for(var t;this.cache.length>=16;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)},Jg.prototype.final=function(e,t){return this.cache.length&&this.ghash(M0.concat([this.cache,Eue],16)),this.ghash(_N([0,e,0,t])),this.state};var Aue=Jg,Cue=Xg,Ta=Qt.Buffer,SN=_0,Tue=Zt,kN=Aue,jue=Gg,Iue=bN;function Oue(e,t){var r=0;e.length!==t.length&&r++;for(var n=Math.min(e.length,t.length),i=0;i<n;++i)r+=e[i]^t[i];return r}function Bue(e,t,r){if(t.length===12)return e._finID=Ta.concat([t,Ta.from([0,0,0,1])]),Ta.concat([t,Ta.from([0,0,0,2])]);var n=new kN(r),i=t.length,a=i%16;n.update(t),a&&(a=16-a,n.update(Ta.alloc(a,0))),n.update(Ta.alloc(8,0));var s=i*8,o=Ta.alloc(8);o.writeUIntBE(s,0,8),n.update(o),e._finID=n.state;var c=Ta.from(e._finID);return Iue(c),c}function vh(e,t,r,n){SN.call(this);var i=Ta.alloc(4,0);this._cipher=new Cue.AES(t);var a=this._cipher.encryptBlock(i);this._ghash=new kN(a),r=Bue(this,r,a),this._prev=Ta.from(r),this._cache=Ta.allocUnsafe(0),this._secCache=Ta.allocUnsafe(0),this._decrypt=n,this._alen=0,this._len=0,this._mode=e,this._authTag=null,this._called=!1}Tue(vh,SN),vh.prototype._update=function(e){if(!this._called&&this._alen){var t=16-this._alen%16;t<16&&(t=Ta.alloc(t,0),this._ghash.update(t))}this._called=!0;var r=this._mode.encrypt(this,e);return this._decrypt?this._ghash.update(e):this._ghash.update(r),this._len+=e.length,r},vh.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var e=jue(this._ghash.final(this._alen*8,this._len*8),this._cipher.encryptBlock(this._finID));if(this._decrypt&&Oue(e,this._authTag))throw new Error("Unsupported state or unable to authenticate data");this._authTag=e,this._cipher.scrub()},vh.prototype.getAuthTag=function(){if(this._decrypt||!Ta.isBuffer(this._authTag))throw new Error("Attempting to get auth tag in unsupported state");return this._authTag},vh.prototype.setAuthTag=function(e){if(!this._decrypt)throw new Error("Attempting to set auth tag in unsupported state");this._authTag=e},vh.prototype.setAAD=function(e){if(this._called)throw new Error("Attempting to set AAD in unsupported state");this._ghash.update(e),this._alen+=e.length};var EN=vh,Rue=Xg,E8=Qt.Buffer,MN=_0,Nue=Zt;function ix(e,t,r,n){MN.call(this),this._cipher=new Rue.AES(t),this._prev=E8.from(r),this._cache=E8.allocUnsafe(0),this._secCache=E8.allocUnsafe(0),this._decrypt=n,this._mode=e}Nue(ix,MN),ix.prototype._update=function(e){return this._mode.encrypt(this,e,this._decrypt)},ix.prototype._final=function(){this._cipher.scrub()};var AN=ix,wh=Qt.Buffer,Fue=a8;function Pue(e,t,r,n){if(wh.isBuffer(e)||(e=wh.from(e,"binary")),t&&(wh.isBuffer(t)||(t=wh.from(t,"binary")),t.length!==8))throw new RangeError("salt should be Buffer with 8 byte length");for(var i=r/8,a=wh.alloc(i),s=wh.alloc(n||0),o=wh.alloc(0);i>0||n>0;){var c=new Fue;c.update(o),c.update(e),t&&c.update(t),o=c.digest();var l=0;if(i>0){var u=a.length-i;l=Math.min(i,o.length),o.copy(a,u,0,l),i-=l}if(l<o.length&&n>0){var d=s.length-n,p=Math.min(n,o.length-l);o.copy(s,d,l,l+p),n-=p}}return o.fill(0),{key:a,iv:s}}var ax=Pue,CN=_8,zue=EN,wc=Qt.Buffer,Lue=AN,TN=_0,Due=Xg,Uue=ax,que=Zt;function Qg(e,t,r){TN.call(this),this._cache=new sx,this._cipher=new Due.AES(t),this._prev=wc.from(r),this._mode=e,this._autopadding=!0}que(Qg,TN),Qg.prototype._update=function(e){this._cache.add(e);for(var t,r,n=[];t=this._cache.get();)r=this._mode.encrypt(this,t),n.push(r);return wc.concat(n)};var Vue=wc.alloc(16,16);Qg.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return e=this._mode.encrypt(this,e),this._cipher.scrub(),e;if(!e.equals(Vue))throw this._cipher.scrub(),new Error("data not multiple of block length")},Qg.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this};function sx(){this.cache=wc.allocUnsafe(0)}sx.prototype.add=function(e){this.cache=wc.concat([this.cache,e])},sx.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},sx.prototype.flush=function(){for(var e=16-this.cache.length,t=wc.allocUnsafe(e),r=-1;++r<e;)t.writeUInt8(e,r);return wc.concat([this.cache,t])};function jN(e,t,r){var n=CN[e.toLowerCase()];if(!n)throw new TypeError("invalid suite type");if(typeof t=="string"&&(t=wc.from(t)),t.length!==n.key/8)throw new TypeError("invalid key length "+t.length);if(typeof r=="string"&&(r=wc.from(r)),n.mode!=="GCM"&&r.length!==n.iv)throw new TypeError("invalid iv length "+r.length);return n.type==="stream"?new Lue(n.module,t,r):n.type==="auth"?new zue(n.module,t,r):new Qg(n.module,t,r)}function Zue(e,t){var r=CN[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var n=Uue(t,!1,r.key,r.iv);return jN(e,n.key,n.iv)}g8.createCipheriv=jN,g8.createCipher=Zue;var M8={},$ue=EN,A0=Qt.Buffer,IN=_8,Hue=AN,ON=_0,Wue=Xg,Kue=ax,Gue=Zt;
1981function eb(e,t,r){ON.call(this),this._cache=new ox,this._last=void 0,this._cipher=new Wue.AES(t),this._prev=A0.from(r),this._mode=e,this._autopadding=!0}Gue(eb,ON),eb.prototype._update=function(e){this._cache.add(e);for(var t,r,n=[];t=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,t),n.push(r);return A0.concat(n)},eb.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return Yue(this._mode.decrypt(this,e));if(e)throw new Error("data not multiple of block length")},eb.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this};function ox(){this.cache=A0.allocUnsafe(0)}ox.prototype.add=function(e){this.cache=A0.concat([this.cache,e])},ox.prototype.get=function(e){var t;if(e){if(this.cache.length>16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(this.cache.length>=16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},ox.prototype.flush=function(){if(this.cache.length)return this.cache};function Yue(e){var t=e[15];if(t<1||t>16)throw new Error("unable to decrypt data");for(var r=-1;++r<t;)if(e[r+(16-t)]!==t)throw new Error("unable to decrypt data");if(t!==16)return e.slice(0,16-t)}function BN(e,t,r){var n=IN[e.toLowerCase()];if(!n)throw new TypeError("invalid suite type");if(typeof r=="string"&&(r=A0.from(r)),n.mode!=="GCM"&&r.length!==n.iv)throw new TypeError("invalid iv length "+r.length);if(typeof t=="string"&&(t=A0.from(t)),t.length!==n.key/8)throw new TypeError("invalid key length "+t.length);return n.type==="stream"?new Hue(n.module,t,r,!0):n.type==="auth"?new $ue(n.module,t,r,!0):new eb(n.module,t,r)}function Xue(e,t){var r=IN[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var n=Kue(t,!1,r.key,r.iv);return BN(e,n.key,n.iv)}M8.createDecipher=Xue,M8.createDecipheriv=BN;var RN=g8,NN=M8,Jue=vN;function Que(){return Object.keys(Jue)}rs.createCipher=rs.Cipher=RN.createCipher,rs.createCipheriv=rs.Cipheriv=RN.createCipheriv,rs.createDecipher=rs.Decipher=NN.createDecipher,rs.createDecipheriv=rs.Decipheriv=NN.createDecipheriv,rs.listCiphers=rs.getCiphers=Que;var FN={};(function(e){e["des-ecb"]={key:8,iv:0},e["des-cbc"]=e.des={key:8,iv:8},e["des-ede3-cbc"]=e.des3={key:24,iv:8},e["des-ede3"]={key:24,iv:0},e["des-ede-cbc"]={key:16,iv:8},e["des-ede"]={key:16,iv:0}})(FN);var PN=cue,A8=rs,Nu=_8,xc=FN,zN=ax;function efe(e,t){e=e.toLowerCase();var r,n;if(Nu[e])r=Nu[e].key,n=Nu[e].iv;else if(xc[e])r=xc[e].key*8,n=xc[e].iv;else throw new TypeError("invalid suite type");var i=zN(t,!1,r,n);return LN(e,i.key,i.iv)}function tfe(e,t){e=e.toLowerCase();var r,n;if(Nu[e])r=Nu[e].key,n=Nu[e].iv;else if(xc[e])r=xc[e].key*8,n=xc[e].iv;else throw new TypeError("invalid suite type");var i=zN(t,!1,r,n);return DN(e,i.key,i.iv)}function LN(e,t,r){if(e=e.toLowerCase(),Nu[e])return A8.createCipheriv(e,t,r);if(xc[e])return new PN({key:t,iv:r,mode:e});throw new TypeError("invalid suite type")}function DN(e,t,r){if(e=e.toLowerCase(),Nu[e])return A8.createDecipheriv(e,t,r);if(xc[e])return new PN({key:t,iv:r,mode:e,decrypt:!0});throw new TypeError("invalid suite type")}function rfe(){return Object.keys(xc).concat(A8.getCiphers())}ho.createCipher=ho.Cipher=efe,ho.createCipheriv=ho.Cipheriv=LN,ho.createDecipher=ho.Decipher=tfe,ho.createDecipheriv=ho.Decipheriv=DN,ho.listCiphers=ho.getCiphers=rfe;var xh={},C8={exports:{}};C8.exports,function(e){(function(t,r){function n(m,A){if(!m)throw new Error(A||"Assertion failed")}function i(m,A){m.super_=A;var f=function(){};f.prototype=A.prototype,m.prototype=new f,m.prototype.constructor=m}function a(m,A,f){if(a.isBN(m))return m;this.negative=0,this.words=null,this.length=0,this.red=null,m!==null&&((A==="le"||A==="be")&&(f=A,A=10),this._init(m||0,A||10,f||"be"))}typeof t=="object"?t.exports=a:r.BN=a,a.BN=a,a.wordSize=26;var s;try{typeof window<"u"&&typeof window.Buffer<"u"?s=window.Buffer:s=ji.Buffer}catch{}a.isBN=function(m){return m instanceof a?!0:m!==null&&typeof m=="object"&&m.constructor.wordSize===a.wordSize&&Array.isArray(m.words)},a.max=function(m,A){return m.cmp(A)>0?m:A},a.min=function(m,A){return m.cmp(A)<0?m:A},a.prototype._init=function(m,A,f){if(typeof m=="number")return this._initNumber(m,A,f);if(typeof m=="object")return this._initArray(m,A,f);A==="hex"&&(A=16),n(A===(A|0)&&A>=2&&A<=36),m=m.toString().replace(/\s+/g,"");var g=0;m[0]==="-"&&(g++,this.negative=1),g<m.length&&(A===16?this._parseHex(m,g,f):(this._parseBase(m,A,g),f==="le"&&this._initArray(this.toArray(),A,f)))},a.prototype._initNumber=function(m,A,f){m<0&&(this.negative=1,m=-m),m<67108864?(this.words=[m&67108863],this.length=1):m<4503599627370496?(this.words=[m&67108863,m/67108864&67108863],this.length=2):(n(m<9007199254740992),this.words=[m&67108863,m/67108864&67108863,1],this.length=3),f==="le"&&this._initArray(this.toArray(),A,f)},a.prototype._initArray=function(m,A,f){if(n(typeof m.length=="number"),m.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(m.length/3),this.words=new Array(this.length);for(var g=0;g<this.length;g++)this.words[g]=0;var _,B,T=0;if(f==="be")for(g=m.length-1,_=0;g>=0;g-=3)B=m[g]|m[g-1]<<8|m[g-2]<<16,this.words[_]|=B<<T&67108863,this.words[_+1]=B>>>26-T&67108863,T+=24,T>=26&&(T-=26,_++);else if(f==="le")for(g=0,_=0;g<m.length;g+=3)B=m[g]|m[g+1]<<8|m[g+2]<<16,this.words[_]|=B<<T&67108863,this.words[_+1]=B>>>26-T&67108863,T+=24,T>=26&&(T-=26,_++);return this.strip()};function o(m,A){var f=m.charCodeAt(A);return f>=65&&f<=70?f-55:f>=97&&f<=102?f-87:f-48&15}function c(m,A,f){var g=o(m,f);return f-1>=A&&(g|=o(m,f-1)<<4),g}a.prototype._parseHex=function(m,A,f){this.length=Math.ceil((m.length-A)/6),this.words=new Array(this.length);for(var g=0;g<this.length;g++)this.words[g]=0;var _=0,B=0,T;if(f==="be")for(g=m.length-1;g>=A;g-=2)T=c(m,A,g)<<_,this.words[B]|=T&67108863,_>=18?(_-=18,B+=1,this.words[B]|=T>>>26):_+=8;else{var S=m.length-A;for(g=S%2===0?A+1:A;g<m.length;g+=2)T=c(m,A,g)<<_,this.words[B]|=T&67108863,_>=18?(_-=18,B+=1,this.words[B]|=T>>>26):_+=8}this.strip()};function l(m,A,f,g){for(var _=0,B=Math.min(m.length,f),T=A;T<B;T++){var S=m.charCodeAt(T)-48;_*=g,S>=49?_+=S-49+10:S>=17?_+=S-17+10:_+=S}return _}a.prototype._parseBase=function(m,A,f){this.words=[0],this.length=1;for(var g=0,_=1;_<=67108863;_*=A)g++;g--,_=_/A|0;for(var B=m.length-f,T=B%g,S=Math.min(B,B-T)+f,h=0,x=f;x<S;x+=g)h=l(m,x,x+g,A),this.imuln(_),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h);if(T!==0){var v=1;for(h=l(m,x,m.length,A),x=0;x<T;x++)v*=A;this.imuln(v),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h)}this.strip()},a.prototype.copy=function(m){m.words=new Array(this.length);for(var A=0;A<this.length;A++)m.words[A]=this.words[A];m.length=this.length,m.negative=this.negative,m.red=this.red},a.prototype.clone=function(){var m=new a(null);return this.copy(m),m},a.prototype._expand=function(m){for(;this.length<m;)this.words[this.length++]=0;return this},a.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},a.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var u=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],d=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],p=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16
vendor: 5,869 bytes, line 1981
1981777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(m,A){m=m||10,A=A|0||1;var f;if(m===16||m==="hex"){f="";for(var g=0,_=0,B=0;B<this.length;B++){var T=this.words[B],S=((T<<g|_)&16777215).toString(16);_=T>>>24-g&16777215,_!==0||B!==this.length-1?f=u[6-S.length]+S+f:f=S+f,g+=2,g>=26&&(g-=26,B--)}for(_!==0&&(f=_.toString(16)+f);f.length%A!==0;)f="0"+f;return this.negative!==0&&(f="-"+f),f}if(m===(m|0)&&m>=2&&m<=36){var h=d[m],x=p[m];f="";var v=this.clone();for(v.negative=0;!v.isZero();){var F=v.modn(x).toString(m);v=v.idivn(x),v.isZero()?f=F+f:f=u[h-F.length]+F+f}for(this.isZero()&&(f="0"+f);f.length%A!==0;)f="0"+f;return this.negative!==0&&(f="-"+f),f}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var m=this.words[0];return this.length===2?m+=this.words[1]*67108864:this.length===3&&this.words[2]===1?m+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-m:m},a.prototype.toJSON=function(){return this.toString(16)},a.prototype.toBuffer=function(m,A){return n(typeof s<"u"),this.toArrayLike(s,m,A)},a.prototype.toArray=function(m,A){return this.toArrayLike(Array,m,A)},a.prototype.toArrayLike=function(m,A,f){var g=this.byteLength(),_=f||Math.max(1,g);n(g<=_,"byte array longer than desired length"),n(_>0,"Requested array length <= 0"),this.strip();var B=A==="le",T=new m(_),S,h,x=this.clone();if(B){for(h=0;!x.isZero();h++)S=x.andln(255),x.iushrn(8),T[h]=S;for(;h<_;h++)T[h]=0}else{for(h=0;h<_-g;h++)T[h]=0;for(h=0;!x.isZero();h++)S=x.andln(255),x.iushrn(8),T[_-h-1]=S}return T},Math.clz32?a.prototype._countBits=function(m){return 32-Math.clz32(m)}:a.prototype._countBits=function(m){var A=m,f=0;return A>=4096&&(f+=13,A>>>=13),A>=64&&(f+=7,A>>>=7),A>=8&&(f+=4,A>>>=4),A>=2&&(f+=2,A>>>=2),f+A},a.prototype._zeroBits=function(m){if(m===0)return 26;var A=m,f=0;return A&8191||(f+=13,A>>>=13),A&127||(f+=7,A>>>=7),A&15||(f+=4,A>>>=4),A&3||(f+=2,A>>>=2),A&1||f++,f},a.prototype.bitLength=function(){var m=this.words[this.length-1],A=this._countBits(m);return(this.length-1)*26+A};function w(m){for(var A=new Array(m.bitLength()),f=0;f<A.length;f++){var g=f/26|0,_=f%26;A[f]=(m.words[g]&1<<_)>>>_}return A}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var m=0,A=0;A<this.length;A++){var f=this._zeroBits(this.words[A]);if(m+=f,f!==26)break}return m},a.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},a.prototype.toTwos=function(m){return this.negative!==0?this.abs().inotn(m).iaddn(1):this.clone()},a.prototype.fromTwos=function(m){return this.testn(m-1)?this.notn(m).iaddn(1).ineg():this.clone()},a.prototype.isNeg=function(){return this.negative!==0},a.prototype.neg=function(){return this.clone().ineg()},a.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},a.prototype.iuor=function(m){for(;this.length<m.length;)this.words[this.length++]=0;for(var A=0;A<m.length;A++)this.words[A]=this.words[A]|m.words[A];return this.strip()},a.prototype.ior=function(m){return n((this.negative|m.negative)===0),this.iuor(m)},a.prototype.or=function(m){return this.length>m.length?this.clone().ior(m):m.clone().ior(this)},a.prototype.uor=function(m){return this.length>m.length?this.clone().iuor(m):m.clone().iuor(this)},a.prototype.iuand=function(m){var A;this.length>m.length?A=m:A=this;for(var f=0;f<A.length;f++)this.words[f]=this.words[f]&m.words[f];return this.length=A.length,this.strip()},a.prototype.iand=function(m){return n((this.negative|m.negative)===0),this.iuand(m)},a.prototype.and=function(m){return this.length>m.length?this.clone().iand(m):m.clone().iand(this)},a.prototype.uand=function(m){return this.length>m.length?this.clone().iuand(m):m.clone().iuand(this)},a.prototype.iuxor=function(m){var A,f;this.length>m.length?(A=this,f=m):(A=m,f=this);for(var g=0;g<f.length;g++)this.words[g]=A.words[g]^f.words[g];if(this!==A)for(;g<A.length;g++)this.words[g]=A.words[g];return this.length=A.length,this.strip()},a.prototype.ixor=function(m){return n((this.negative|m.negative)===0),this.iuxor(m)},a.prototype.xor=function(m){return this.length>m.length?this.clone().ixor(m):m.clone().ixor(this)},a.prototype.uxor=function(m){return this.length>m.length?this.clone().iuxor(m):m.clone().iuxor(this)},a.prototype.inotn=function(m){n(typeof m=="number"&&m>=0);var A=Math.ceil(m/26)|0,f=m%26;this._expand(A),f>0&&A--;for(var g=0;g<A;g++)this.words[g]=~this.words[g]&67108863;return f>0&&(this.words[g]=~this.words[g]&67108863>>26-f),this.strip()},a.prototype.notn=function(m){return this.clone().inotn(m)},a.prototype.setn=function(m,A){n(typeof m=="number"&&m>=0);var f=m/26|0,g=m%26;return this._expand(f+1),A?this.words[f]=this.words[f]|1<<g:this.words[f]=this.words[f]&~(1<<g),this.strip()},a.prototype.iadd=function(m){var A;if(this.negative!==0&&m.negative===0)return this.negative=0,A=this.isub(m),this.negative^=1,this._normSign();if(this.negative===0&&m.negative!==0)return m.negative=0,A=this.isub(m),m.negative=1,A._normSign();var f,g;this.length>m.length?(f=this,g=m):(f=m,g=this);for(var _=0,B=0;B<g.length;B++)A=(f.words[B]|0)+(g.words[B]|0)+_,this.words[B]=A&67108863,_=A>>>26;for(;_!==0&&B<f.length;B++)A=(f.words[B]|0)+_,this.words[B]=A&67108863,_=A>>>26;if(this.length=f.length,_!==0)this.words[this.length]=_,this.length++;else if(f!==this)for(;B<f.length;B++)this.words[B]=f.words[B];return this},a.prototype.add=function(m){var A;return m.negative!==0&&this.negative===0?(m.negative=0,A=this.sub(m),m.negative^=1,A):m.negative===0&&this.negative!==0?(this.negative=0,A=m.sub(this),this.negative=1,A):this.length>m.length?this.clone().iadd(m):m.clone().iadd(this)},a.prototype.isub=function(m){if(m.negative!==0){m.negative=0;
vendor: 8,256 bytes, line 1981
1981var A=this.iadd(m);return m.negative=1,A._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(m),this.negative=1,this._normSign();var f=this.cmp(m);if(f===0)return this.negative=0,this.length=1,this.words[0]=0,this;var g,_;f>0?(g=this,_=m):(g=m,_=this);for(var B=0,T=0;T<_.length;T++)A=(g.words[T]|0)-(_.words[T]|0)+B,B=A>>26,this.words[T]=A&67108863;for(;B!==0&&T<g.length;T++)A=(g.words[T]|0)+B,B=A>>26,this.words[T]=A&67108863;if(B===0&&T<g.length&&g!==this)for(;T<g.length;T++)this.words[T]=g.words[T];return this.length=Math.max(this.length,T),g!==this&&(this.negative=1),this.strip()},a.prototype.sub=function(m){return this.clone().isub(m)};function O(m,A,f){f.negative=A.negative^m.negative;var g=m.length+A.length|0;f.length=g,g=g-1|0;var _=m.words[0]|0,B=A.words[0]|0,T=_*B,S=T&67108863,h=T/67108864|0;f.words[0]=S;for(var x=1;x<g;x++){for(var v=h>>>26,F=h&67108863,Q=Math.min(x,A.length-1),G=Math.max(0,x-m.length+1);G<=Q;G++){var J=x-G|0;_=m.words[J]|0,B=A.words[G]|0,T=_*B+F,v+=T/67108864|0,F=T&67108863}f.words[x]=F|0,h=v|0}return h!==0?f.words[x]=h|0:f.length--,f.strip()}var I=function(m,A,f){var g=m.words,_=A.words,B=f.words,T=0,S,h,x,v=g[0]|0,F=v&8191,Q=v>>>13,G=g[1]|0,J=G&8191,Y=G>>>13,V=g[2]|0,W=V&8191,ce=V>>>13,pe=g[3]|0,ee=pe&8191,se=pe>>>13,ve=g[4]|0,_e=ve&8191,Ue=ve>>>13,xe=g[5]|0,Te=xe&8191,$e=xe>>>13,Ae=g[6]|0,De=Ae&8191,Ke=Ae>>>13,ut=g[7]|0,Fe=ut&8191,ge=ut>>>13,we=g[8]|0,ke=we&8191,Ne=we>>>13,z=g[9]|0,H=z&8191,k=z>>>13,L=_[0]|0,q=L&8191,ie=L>>>13,fe=_[1]|0,be=fe&8191,Ce=fe>>>13,ze=_[2]|0,Ie=ze&8191,qe=ze>>>13,it=_[3]|0,Ve=it&8191,zt=it>>>13,wt=_[4]|0,Xe=wt&8191,Tt=wt>>>13,jt=_[5]|0,Je=jt&8191,Et=jt>>>13,Bt=_[6]|0,Qe=Bt&8191,Lt=Bt>>>13,Dt=_[7]|0,et=Dt&8191,Rt=Dt>>>13,Mt=_[8]|0,Ye=Mt&8191,Nt=Mt>>>13,Ft=_[9]|0,tt=Ft&8191,At=Ft>>>13;f.negative=m.negative^A.negative,f.length=19,S=Math.imul(F,q),h=Math.imul(F,ie),h=h+Math.imul(Q,q)|0,x=Math.imul(Q,ie);var It=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(It>>>26)|0,It&=67108863,S=Math.imul(J,q),h=Math.imul(J,ie),h=h+Math.imul(Y,q)|0,x=Math.imul(Y,ie),S=S+Math.imul(F,be)|0,h=h+Math.imul(F,Ce)|0,h=h+Math.imul(Q,be)|0,x=x+Math.imul(Q,Ce)|0;var xt=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(xt>>>26)|0,xt&=67108863,S=Math.imul(W,q),h=Math.imul(W,ie),h=h+Math.imul(ce,q)|0,x=Math.imul(ce,ie),S=S+Math.imul(J,be)|0,h=h+Math.imul(J,Ce)|0,h=h+Math.imul(Y,be)|0,x=x+Math.imul(Y,Ce)|0,S=S+Math.imul(F,Ie)|0,h=h+Math.imul(F,qe)|0,h=h+Math.imul(Q,Ie)|0,x=x+Math.imul(Q,qe)|0;var oi=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(oi>>>26)|0,oi&=67108863,S=Math.imul(ee,q),h=Math.imul(ee,ie),h=h+Math.imul(se,q)|0,x=Math.imul(se,ie),S=S+Math.imul(W,be)|0,h=h+Math.imul(W,Ce)|0,h=h+Math.imul(ce,be)|0,x=x+Math.imul(ce,Ce)|0,S=S+Math.imul(J,Ie)|0,h=h+Math.imul(J,qe)|0,h=h+Math.imul(Y,Ie)|0,x=x+Math.imul(Y,qe)|0,S=S+Math.imul(F,Ve)|0,h=h+Math.imul(F,zt)|0,h=h+Math.imul(Q,Ve)|0,x=x+Math.imul(Q,zt)|0;var li=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(li>>>26)|0,li&=67108863,S=Math.imul(_e,q),h=Math.imul(_e,ie),h=h+Math.imul(Ue,q)|0,x=Math.imul(Ue,ie),S=S+Math.imul(ee,be)|0,h=h+Math.imul(ee,Ce)|0,h=h+Math.imul(se,be)|0,x=x+Math.imul(se,Ce)|0,S=S+Math.imul(W,Ie)|0,h=h+Math.imul(W,qe)|0,h=h+Math.imul(ce,Ie)|0,x=x+Math.imul(ce,qe)|0,S=S+Math.imul(J,Ve)|0,h=h+Math.imul(J,zt)|0,h=h+Math.imul(Y,Ve)|0,x=x+Math.imul(Y,zt)|0,S=S+Math.imul(F,Xe)|0,h=h+Math.imul(F,Tt)|0,h=h+Math.imul(Q,Xe)|0,x=x+Math.imul(Q,Tt)|0;var ci=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(ci>>>26)|0,ci&=67108863,S=Math.imul(Te,q),h=Math.imul(Te,ie),h=h+Math.imul($e,q)|0,x=Math.imul($e,ie),S=S+Math.imul(_e,be)|0,h=h+Math.imul(_e,Ce)|0,h=h+Math.imul(Ue,be)|0,x=x+Math.imul(Ue,Ce)|0,S=S+Math.imul(ee,Ie)|0,h=h+Math.imul(ee,qe)|0,h=h+Math.imul(se,Ie)|0,x=x+Math.imul(se,qe)|0,S=S+Math.imul(W,Ve)|0,h=h+Math.imul(W,zt)|0,h=h+Math.imul(ce,Ve)|0,x=x+Math.imul(ce,zt)|0,S=S+Math.imul(J,Xe)|0,h=h+Math.imul(J,Tt)|0,h=h+Math.imul(Y,Xe)|0,x=x+Math.imul(Y,Tt)|0,S=S+Math.imul(F,Je)|0,h=h+Math.imul(F,Et)|0,h=h+Math.imul(Q,Je)|0,x=x+Math.imul(Q,Et)|0;var Rn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Rn>>>26)|0,Rn&=67108863,S=Math.imul(De,q),h=Math.imul(De,ie),h=h+Math.imul(Ke,q)|0,x=Math.imul(Ke,ie),S=S+Math.imul(Te,be)|0,h=h+Math.imul(Te,Ce)|0,h=h+Math.imul($e,be)|0,x=x+Math.imul($e,Ce)|0,S=S+Math.imul(_e,Ie)|0,h=h+Math.imul(_e,qe)|0,h=h+Math.imul(Ue,Ie)|0,x=x+Math.imul(Ue,qe)|0,S=S+Math.imul(ee,Ve)|0,h=h+Math.imul(ee,zt)|0,h=h+Math.imul(se,Ve)|0,x=x+Math.imul(se,zt)|0,S=S+Math.imul(W,Xe)|0,h=h+Math.imul(W,Tt)|0,h=h+Math.imul(ce,Xe)|0,x=x+Math.imul(ce,Tt)|0,S=S+Math.imul(J,Je)|0,h=h+Math.imul(J,Et)|0,h=h+Math.imul(Y,Je)|0,x=x+Math.imul(Y,Et)|0,S=S+Math.imul(F,Qe)|0,h=h+Math.imul(F,Lt)|0,h=h+Math.imul(Q,Qe)|0,x=x+Math.imul(Q,Lt)|0;var Sn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Sn>>>26)|0,Sn&=67108863,S=Math.imul(Fe,q),h=Math.imul(Fe,ie),h=h+Math.imul(ge,q)|0,x=Math.imul(ge,ie),S=S+Math.imul(De,be)|0,h=h+Math.imul(De,Ce)|0,h=h+Math.imul(Ke,be)|0,x=x+Math.imul(Ke,Ce)|0,S=S+Math.imul(Te,Ie)|0,h=h+Math.imul(Te,qe)|0,h=h+Math.imul($e,Ie)|0,x=x+Math.imul($e,qe)|0,S=S+Math.imul(_e,Ve)|0,h=h+Math.imul(_e,zt)|0,h=h+Math.imul(Ue,Ve)|0,x=x+Math.imul(Ue,zt)|0,S=S+Math.imul(ee,Xe)|0,h=h+Math.imul(ee,Tt)|0,h=h+Math.imul(se,Xe)|0,x=x+Math.imul(se,Tt)|0,S=S+Math.imul(W,Je)|0,h=h+Math.imul(W,Et)|0,h=h+Math.imul(ce,Je)|0,x=x+Math.imul(ce,Et)|0,S=S+Math.imul(J,Qe)|0,h=h+Math.imul(J,Lt)|0,h=h+Math.imul(Y,Qe)|0,x=x+Math.imul(Y,Lt)|0,S=S+Math.imul(F,et)|0,h=h+Math.imul(F,Rt)|0,h=h+Math.imul(Q,et)|0,x=x+Math.imul(Q,Rt)|0;var zr=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(zr>>>26)|0,zr&=67108863,S=Math.imul(ke,q),h=Math.imul(ke,ie),h=h+Math.imul(Ne,q)|0,x=Math.imul(Ne,ie),S=S+Math.imul(Fe,be)|0,h=h+Math.imul(Fe,Ce)|0,h=h+Math.imul(ge,be)|0,x=x+Math.imul(ge,Ce)|0,S=S+Math.imul(De,Ie)|0,h=h+Math.imul(De,qe)|0,h=h+Math.imul(Ke,Ie)|0,x=x+Math.imul(Ke,qe)|0,S=S+Math.imul(Te,Ve)|0,h=h+Math.imul(Te,zt)|0,h=h+Math.imul($e,Ve)|0,x=x+Math.imul($e,zt)|0,S=S+Math.imul(_e,Xe)|0,h=h+Math.imul(_e,Tt)|0,h=h+Math.imul(Ue,Xe)|0,x=x+Math.imul(Ue,Tt)|0,S=S+Math.imul(ee,Je)|0,h=h+Math.imul(ee,Et)|0,h=h+Math.imul(se,Je)|0,x=x+Math.imul(se,Et)|0,S=S+Math.imul(W,Qe)|0,h=h+Math.imul(W,Lt)|0,h=h+Math.imul(ce,Qe)|0,x=x+Math.imul(ce,Lt)|0,S=S+Math.imul(J,et)|0,h=h+Math.imul(J,Rt)|0,h=h+Math.imul(Y,et)|0,x=x+Math.imul(Y,Rt)|0,S=S+Math.imul(F,Ye)|0,h=h+Math.imul(F,Nt)|0,h=h+Math.imul(Q,Ye)|0,x=x+Math.imul(Q,Nt)|0;var mn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(mn>>>26)|0,mn&=67108863,S=Math.imul(H,q),h=Math.imul(H,ie),h=h+Math.imul(k,q)|0,x=Math.imul(k,ie),S=S+Math.imul(ke,be)|0,h=h+Math.imul(ke,Ce)|0,h=h+Math.imul(Ne,be)|0,x=x+Math.imul(Ne,Ce)|0,S=S+Math.imul(Fe,Ie)|0,h=h+Math.imul(Fe,qe)|0,h=h+Math.imul(ge,Ie)|0,x=x+Math.imul(ge,qe)|0,S=S+Math.imul(De,Ve)|0,h=h+Math.imul(De,zt)|0,h=h+Math.imul(Ke,Ve)|0,x=x+Math.imul(Ke,zt)|0,S=S+Math.imul(Te,Xe)|0,h=h+Math.imul(Te,Tt)|0,h=h+Math.imul($e,Xe)|0,x=x+Math.imul($e,Tt)|0,S=S+Math.imul(_e,Je)|0,h=h+Math.imul(_e,Et)|0,h=h+Math.imul(Ue,Je)|0,x=x+Math.imul(Ue,Et)|0,S=S+Math.imul(ee,Qe)|0,h=h+Math.imul(ee,Lt)|0,h=h+Math.imul(se,Qe)|0,x=x+Math.imul(se,Lt)|0,S=S+Math.imul(W,et)|0,h=h+Math.imul(W,Rt)|0,h=h+Math.imul(ce,et)|0,x=x+Math.imul(ce,Rt)|0,S=S+Math.imul(J,Ye)|0,h=h+Math.imul(J,Nt)|0,h=h+Math.imul(Y,Ye)|0,x=x+Math.imul(Y,Nt)|0,S=S+Math.imul(F,tt)|0,h=h+Math.imul(F,At)|0,h=h+Math.imul(Q,tt)|0,x=x+Math.imul(Q,At)|0;var Nn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Nn>>>26)|0,Nn&=67108863,S=Math.imul(H,be),h=Math.imul(H,Ce),h=h+Math.imul(k,be)|0,x=Math.imul(k,Ce),S=S+Math.imul(ke,Ie)|0,h=h+Math.imul(ke,qe)|0,h=h+Math.imul(Ne,Ie)|0,x=x+Math.imul(Ne,qe)|0,S=S+Math.imul(Fe,Ve)|0,h=h+Math.imul(Fe,zt)|0,h=h+Math.imul(ge,Ve)|0,x=x+Math.imul(ge,zt)|0,S=S+Math.imul(De,Xe)|0,h=h+Math.imul(De,Tt)|0,h=h+Math.imul(Ke,Xe)|0,x=x+Math.imul(Ke,Tt)|0,S=S+Math.imul(Te,Je)|0,h=h+Math.imul(Te,Et)|0,h=h+Math.imul($e,Je)|0,x=x+Math.imul($e,Et)|0,S=S+Math.imul(_e,Qe)|0,h=h+Math.imul(_e,Lt)|0,h=h+Math.imul(Ue,Qe)|0,x=x+Math.imul(Ue,Lt)|0,S=S+Math.imul(ee,et)|0,h=h+Math.imul(ee,Rt)|0,h=h+Math.imul(se,et)|0,x=x+Math.imul(se,Rt)|0,S=S+Math.imul(W,Ye)|0,h=h+Math.imul(W,Nt)|0,h=h+Math.imul(ce,Ye)|0,x=x+Math.imul(ce,Nt)|0,S=S+Math.imul(J,tt)|0,h=h+Math.imul(J,At)|0,h=h+Math.imul(Y,tt)|0,x=x+Math.imul(Y,At)|0;var Kn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Kn>
vendor: 11,600 bytes, line 1981
1981>>26)|0,Kn&=67108863,S=Math.imul(H,Ie),h=Math.imul(H,qe),h=h+Math.imul(k,Ie)|0,x=Math.imul(k,qe),S=S+Math.imul(ke,Ve)|0,h=h+Math.imul(ke,zt)|0,h=h+Math.imul(Ne,Ve)|0,x=x+Math.imul(Ne,zt)|0,S=S+Math.imul(Fe,Xe)|0,h=h+Math.imul(Fe,Tt)|0,h=h+Math.imul(ge,Xe)|0,x=x+Math.imul(ge,Tt)|0,S=S+Math.imul(De,Je)|0,h=h+Math.imul(De,Et)|0,h=h+Math.imul(Ke,Je)|0,x=x+Math.imul(Ke,Et)|0,S=S+Math.imul(Te,Qe)|0,h=h+Math.imul(Te,Lt)|0,h=h+Math.imul($e,Qe)|0,x=x+Math.imul($e,Lt)|0,S=S+Math.imul(_e,et)|0,h=h+Math.imul(_e,Rt)|0,h=h+Math.imul(Ue,et)|0,x=x+Math.imul(Ue,Rt)|0,S=S+Math.imul(ee,Ye)|0,h=h+Math.imul(ee,Nt)|0,h=h+Math.imul(se,Ye)|0,x=x+Math.imul(se,Nt)|0,S=S+Math.imul(W,tt)|0,h=h+Math.imul(W,At)|0,h=h+Math.imul(ce,tt)|0,x=x+Math.imul(ce,At)|0;var sn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(sn>>>26)|0,sn&=67108863,S=Math.imul(H,Ve),h=Math.imul(H,zt),h=h+Math.imul(k,Ve)|0,x=Math.imul(k,zt),S=S+Math.imul(ke,Xe)|0,h=h+Math.imul(ke,Tt)|0,h=h+Math.imul(Ne,Xe)|0,x=x+Math.imul(Ne,Tt)|0,S=S+Math.imul(Fe,Je)|0,h=h+Math.imul(Fe,Et)|0,h=h+Math.imul(ge,Je)|0,x=x+Math.imul(ge,Et)|0,S=S+Math.imul(De,Qe)|0,h=h+Math.imul(De,Lt)|0,h=h+Math.imul(Ke,Qe)|0,x=x+Math.imul(Ke,Lt)|0,S=S+Math.imul(Te,et)|0,h=h+Math.imul(Te,Rt)|0,h=h+Math.imul($e,et)|0,x=x+Math.imul($e,Rt)|0,S=S+Math.imul(_e,Ye)|0,h=h+Math.imul(_e,Nt)|0,h=h+Math.imul(Ue,Ye)|0,x=x+Math.imul(Ue,Nt)|0,S=S+Math.imul(ee,tt)|0,h=h+Math.imul(ee,At)|0,h=h+Math.imul(se,tt)|0,x=x+Math.imul(se,At)|0;var Fn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Fn>>>26)|0,Fn&=67108863,S=Math.imul(H,Xe),h=Math.imul(H,Tt),h=h+Math.imul(k,Xe)|0,x=Math.imul(k,Tt),S=S+Math.imul(ke,Je)|0,h=h+Math.imul(ke,Et)|0,h=h+Math.imul(Ne,Je)|0,x=x+Math.imul(Ne,Et)|0,S=S+Math.imul(Fe,Qe)|0,h=h+Math.imul(Fe,Lt)|0,h=h+Math.imul(ge,Qe)|0,x=x+Math.imul(ge,Lt)|0,S=S+Math.imul(De,et)|0,h=h+Math.imul(De,Rt)|0,h=h+Math.imul(Ke,et)|0,x=x+Math.imul(Ke,Rt)|0,S=S+Math.imul(Te,Ye)|0,h=h+Math.imul(Te,Nt)|0,h=h+Math.imul($e,Ye)|0,x=x+Math.imul($e,Nt)|0,S=S+Math.imul(_e,tt)|0,h=h+Math.imul(_e,At)|0,h=h+Math.imul(Ue,tt)|0,x=x+Math.imul(Ue,At)|0;var Tn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Tn>>>26)|0,Tn&=67108863,S=Math.imul(H,Je),h=Math.imul(H,Et),h=h+Math.imul(k,Je)|0,x=Math.imul(k,Et),S=S+Math.imul(ke,Qe)|0,h=h+Math.imul(ke,Lt)|0,h=h+Math.imul(Ne,Qe)|0,x=x+Math.imul(Ne,Lt)|0,S=S+Math.imul(Fe,et)|0,h=h+Math.imul(Fe,Rt)|0,h=h+Math.imul(ge,et)|0,x=x+Math.imul(ge,Rt)|0,S=S+Math.imul(De,Ye)|0,h=h+Math.imul(De,Nt)|0,h=h+Math.imul(Ke,Ye)|0,x=x+Math.imul(Ke,Nt)|0,S=S+Math.imul(Te,tt)|0,h=h+Math.imul(Te,At)|0,h=h+Math.imul($e,tt)|0,x=x+Math.imul($e,At)|0;var Pn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Pn>>>26)|0,Pn&=67108863,S=Math.imul(H,Qe),h=Math.imul(H,Lt),h=h+Math.imul(k,Qe)|0,x=Math.imul(k,Lt),S=S+Math.imul(ke,et)|0,h=h+Math.imul(ke,Rt)|0,h=h+Math.imul(Ne,et)|0,x=x+Math.imul(Ne,Rt)|0,S=S+Math.imul(Fe,Ye)|0,h=h+Math.imul(Fe,Nt)|0,h=h+Math.imul(ge,Ye)|0,x=x+Math.imul(ge,Nt)|0,S=S+Math.imul(De,tt)|0,h=h+Math.imul(De,At)|0,h=h+Math.imul(Ke,tt)|0,x=x+Math.imul(Ke,At)|0;var Gn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Gn>>>26)|0,Gn&=67108863,S=Math.imul(H,et),h=Math.imul(H,Rt),h=h+Math.imul(k,et)|0,x=Math.imul(k,Rt),S=S+Math.imul(ke,Ye)|0,h=h+Math.imul(ke,Nt)|0,h=h+Math.imul(Ne,Ye)|0,x=x+Math.imul(Ne,Nt)|0,S=S+Math.imul(Fe,tt)|0,h=h+Math.imul(Fe,At)|0,h=h+Math.imul(ge,tt)|0,x=x+Math.imul(ge,At)|0;var Zr=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Zr>>>26)|0,Zr&=67108863,S=Math.imul(H,Ye),h=Math.imul(H,Nt),h=h+Math.imul(k,Ye)|0,x=Math.imul(k,Nt),S=S+Math.imul(ke,tt)|0,h=h+Math.imul(ke,At)|0,h=h+Math.imul(Ne,tt)|0,x=x+Math.imul(Ne,At)|0;var Yn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Yn>>>26)|0,Yn&=67108863,S=Math.imul(H,tt),h=Math.imul(H,At),h=h+Math.imul(k,tt)|0,x=Math.imul(k,At);var zn=(T+S|0)+((h&8191)<<13)|0;return T=(x+(h>>>13)|0)+(zn>>>26)|0,zn&=67108863,B[0]=It,B[1]=xt,B[2]=oi,B[3]=li,B[4]=ci,B[5]=Rn,B[6]=Sn,B[7]=zr,B[8]=mn,B[9]=Nn,B[10]=Kn,B[11]=sn,B[12]=Fn,B[13]=Tn,B[14]=Pn,B[15]=Gn,B[16]=Zr,B[17]=Yn,B[18]=zn,T!==0&&(B[19]=T,f.length++),f};Math.imul||(I=O);function R(m,A,f){f.negative=A.negative^m.negative,f.length=m.length+A.length;for(var g=0,_=0,B=0;B<f.length-1;B++){var T=_;_=0;for(var S=g&67108863,h=Math.min(B,A.length-1),x=Math.max(0,B-m.length+1);x<=h;x++){var v=B-x,F=m.words[v]|0,Q=A.words[x]|0,G=F*Q,J=G&67108863;T=T+(G/67108864|0)|0,J=J+S|0,S=J&67108863,T=T+(J>>>26)|0,_+=T>>>26,T&=67108863}f.words[B]=S,g=T,T=_}return g!==0?f.words[B]=g:f.length--,f.strip()}function C(m,A,f){var g=new j;return g.mulp(m,A,f)}a.prototype.mulTo=function(m,A){var f,g=this.length+m.length;return this.length===10&&m.length===10?f=I(this,m,A):g<63?f=O(this,m,A):g<1024?f=R(this,m,A):f=C(this,m,A),f};function j(m,A){this.x=m,this.y=A}j.prototype.makeRBT=function(m){for(var A=new Array(m),f=a.prototype._countBits(m)-1,g=0;g<m;g++)A[g]=this.revBin(g,f,m);return A},j.prototype.revBin=function(m,A,f){if(m===0||m===f-1)return m;for(var g=0,_=0;_<A;_++)g|=(m&1)<<A-_-1,m>>=1;return g},j.prototype.permute=function(m,A,f,g,_,B){for(var T=0;T<B;T++)g[T]=A[m[T]],_[T]=f[m[T]]},j.prototype.transform=function(m,A,f,g,_,B){this.permute(B,m,A,f,g,_);for(var T=1;T<_;T<<=1)for(var S=T<<1,h=Math.cos(2*Math.PI/S),x=Math.sin(2*Math.PI/S),v=0;v<_;v+=S)for(var F=h,Q=x,G=0;G<T;G++){var J=f[v+G],Y=g[v+G],V=f[v+G+T],W=g[v+G+T],ce=F*V-Q*W;W=F*W+Q*V,V=ce,f[v+G]=J+V,g[v+G]=Y+W,f[v+G+T]=J-V,g[v+G+T]=Y-W,G!==S&&(ce=h*F-x*Q,Q=h*Q+x*F,F=ce)}},j.prototype.guessLen13b=function(m,A){var f=Math.max(A,m)|1,g=f&1,_=0;for(f=f/2|0;f;f=f>>>1)_++;return 1<<_+1+g},j.prototype.conjugate=function(m,A,f){if(!(f<=1))for(var g=0;g<f/2;g++){var _=m[g];m[g]=m[f-g-1],m[f-g-1]=_,_=A[g],A[g]=-A[f-g-1],A[f-g-1]=-_}},j.prototype.normalize13b=function(m,A){for(var f=0,g=0;g<A/2;g++){var _=Math.round(m[2*g+1]/A)*8192+Math.round(m[2*g]/A)+f;m[g]=_&67108863,_<67108864?f=0:f=_/67108864|0}return m},j.prototype.convert13b=function(m,A,f,g){for(var _=0,B=0;B<A;B++)_=_+(m[B]|0),f[2*B]=_&8191,_=_>>>13,f[2*B+1]=_&8191,_=_>>>13;for(B=2*A;B<g;++B)f[B]=0;n(_===0),n((_&-8192)===0)},j.prototype.stub=function(m){for(var A=new Array(m),f=0;f<m;f++)A[f]=0;return A},j.prototype.mulp=function(m,A,f){var g=2*this.guessLen13b(m.length,A.length),_=this.makeRBT(g),B=this.stub(g),T=new Array(g),S=new Array(g),h=new Array(g),x=new Array(g),v=new Array(g),F=new Array(g),Q=f.words;Q.length=g,this.convert13b(m.words,m.length,T,g),this.convert13b(A.words,A.length,x,g),this.transform(T,B,S,h,g,_),this.transform(x,B,v,F,g,_);for(var G=0;G<g;G++){var J=S[G]*v[G]-h[G]*F[G];h[G]=S[G]*F[G]+h[G]*v[G],S[G]=J}return this.conjugate(S,h,g),this.transform(S,h,Q,B,g,_),this.conjugate(Q,B,g),this.normalize13b(Q,g),f.negative=m.negative^A.negative,f.length=m.length+A.length,f.strip()},a.prototype.mul=function(m){var A=new a(null);return A.words=new Array(this.length+m.length),this.mulTo(m,A)},a.prototype.mulf=function(m){var A=new a(null);return A.words=new Array(this.length+m.length),C(this,m,A)},a.prototype.imul=function(m){return this.clone().mulTo(m,this)},a.prototype.imuln=function(m){n(typeof m=="number"),n(m<67108864);for(var A=0,f=0;f<this.length;f++){var g=(this.words[f]|0)*m,_=(g&67108863)+(A&67108863);A>>=26,A+=g/67108864|0,A+=_>>>26,this.words[f]=_&67108863}return A!==0&&(this.words[f]=A,this.length++),this},a.prototype.muln=function(m){return this.clone().imuln(m)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(m){var A=w(m);if(A.length===0)return new a(1);for(var f=this,g=0;g<A.length&&A[g]===0;g++,f=f.sqr());if(++g<A.length)for(var _=f.sqr();g<A.length;g++,_=_.sqr())A[g]!==0&&(f=f.mul(_));return f},a.prototype.iushln=function(m){n(typeof m=="number"&&m>=0);var A=m%26,f=(m-A)/26,g=67108863>>>26-A<<26-A,_;if(A!==0){var B=0;for(_=0;_<this.length;_++){var T=this.words[_]&g,S=(this.words[_]|0)-T<<A;this.words[_]=S|B,B=T>>>26-A}B&&(this.words[_]=B,this.length++)}if(f!==0){for(_=this.length-1;_>=0;_--)this.words[_+f]=this.words[_];for(_=0;_<f;_++)this.words[_]=0;this.length+=f}return this.strip()},a.prototype.ishln=function(m){return n(this.negative===0),this.iushln(m)},a.prototype.iushrn=function(m,A,f){n(typeof m=="number"&&m>=0);var g;A?g=(A-A%26)/26:g=0;var _=m%26,B=Math.min((m-_)/26,this.length),T=67108863^67108863>>>_<<_,S=f;if(g-=B,g=Math.max(0,g),S){for(var h=0;h<B;h++)S.words[h]=this.words[h];S.length=B}if(B!==0)if(this.length>B)for(this.length-=B,h=0;h<this.length;h++)this.words[h]=this.words[h+B];else this.words[0]=0,this.length=1;var x=0;for(h=this.length-1;h>=0&&(x!==0||h>=g);h--){var v=this.words[h]|0;this.words[h]=x<<26-_|v>>>_,x=v&T}return S&&x!==0&&(S.words[S.length++]=x),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},a.prototype.ishrn=function(m,A,f){return n(this.negative===0),this.iushrn(m,A,f)},a.prototype.shln=function(m){return this.clone().ishln(m)},a.prototype.ushln=function(m){return this.clone().iushln(m)},a.prototype.shrn=function(m){return this.clone().ishrn(m)},a.prototype.ushrn=function(m){return this.clone().iushrn(m)},a.prototype.testn=function(m){n(typeof m=="number"&&m>=0);var A=m%26,f=(m-A)/26,g=1<<A;if(this.length<=f)return!1;var _=this.words[f];return!!(_&g)},a.prototype.imaskn=function(m){n(typeof m=="number"&&m>=0);var A=m%26,f=(m-A)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=f)return this;if(A!==0&&f++,this.length=Math.min(f,this.length),A!==0){var g=67108863^67108863>>>A<<A;this.words[this.length-1]&=g}return this.strip()},a.prototype.maskn=function(m){return this.clone().imaskn(m)},a.prototype.iaddn=function(m){return n(typeof m=="number"),n(m<67108864),m<0?this.isubn(-m):this.negative!==0?this.length===1&&(this.words[0]|0)<m?(this.words[0]=m-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(m),this.negative=1,this):this._iaddn(m)},a.prototype._iaddn=function(m){this.words[0]+=m;for(var A=0;A<this.length&&this.words[A]>=67108864;A++)this.words[A]-=67108864,A===this.length-1?this.words[A+1]=1:this.words[A+1]++;return this.length=Math.max(this.length,A+1),this},a.prototype.isubn=function(m){if(n(typeof m=="number"),n(m<67108864),m<0)return this.iaddn(-m);if(this.negative!==0)return this.negative=0,this.iaddn(m),this.negative=1,this;if(this.words[0]-=m,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var A=0;A<this.length&&this.words[A]<0;A++)this.words[A]+=67108864,this.words[A+1]-=1;return this.strip()},a.prototype.addn=function(m){return this.clone().iaddn(m)},a.prototype.subn=function(m){return this.clone().isubn(m)},a.prototype.iabs=function(){return this.negative=0,this},a.prototype.abs=function(){return this.clone().iabs()},a.prototype._ishlnsubmul=function(m,A,f){var g=m.length+f,_;this._expand(g);var B,T=0;for(_=0;_<m.length;_++){B=(this.words[_+f]|0)+T;var S=(m.words[_]|0)*A;B-=S&67108863,T=(B>>26)-(S/67108864|0),this.words[_+f]=B&67108863}for(;_<this.length-f;_++)B=(this.words[_+f]|0)+T,T=B>>26,this.words[_+f]=B&67108863;if(T===0)return this.strip();for(n(T===-1),T=0,_=0;_<this.length;_++)B=-(this.words[_]|0)+T,T=B>>26,this.words[_]=B&67108863;return this.negative=1,this.strip()},a.prototype._wordDiv=function(m,A){var f=this.length-m.length,g=this.clone(),_=m,B=_.words[_.length-1]|0,T=this._countBits(B);f=26-T,f!==0&&(_=_.ushln(f),g.iushln(f),B=_.words[_.length-1]|0);var S=g.length-_.length,h;if(A!=="mod"){h=new a(null),h.length=S+1,h.words=new Array(h.length);for(var x=0;x<h.length;x++)h.words[x]=0}var v=g.clone()._ishlnsubmul(_,1,S);v.negative===0&&(g=v,h&&(h.words[S]=1));for(var F=S-1;F>=0;F--){var Q=(g.words[_.length+F]|0)*67108864+(g.words[_.length+F-1]|0);
vendor: 12,827 bytes, line 1981
1981for(Q=Math.min(Q/B|0,67108863),g._ishlnsubmul(_,Q,F);g.negative!==0;)Q--,g.negative=0,g._ishlnsubmul(_,1,F),g.isZero()||(g.negative^=1);h&&(h.words[F]=Q)}return h&&h.strip(),g.strip(),A!=="div"&&f!==0&&g.iushrn(f),{div:h||null,mod:g}},a.prototype.divmod=function(m,A,f){if(n(!m.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var g,_,B;return this.negative!==0&&m.negative===0?(B=this.neg().divmod(m,A),A!=="mod"&&(g=B.div.neg()),A!=="div"&&(_=B.mod.neg(),f&&_.negative!==0&&_.iadd(m)),{div:g,mod:_}):this.negative===0&&m.negative!==0?(B=this.divmod(m.neg(),A),A!=="mod"&&(g=B.div.neg()),{div:g,mod:B.mod}):this.negative&m.negative?(B=this.neg().divmod(m.neg(),A),A!=="div"&&(_=B.mod.neg(),f&&_.negative!==0&&_.isub(m)),{div:B.div,mod:_}):m.length>this.length||this.cmp(m)<0?{div:new a(0),mod:this}:m.length===1?A==="div"?{div:this.divn(m.words[0]),mod:null}:A==="mod"?{div:null,mod:new a(this.modn(m.words[0]))}:{div:this.divn(m.words[0]),mod:new a(this.modn(m.words[0]))}:this._wordDiv(m,A)},a.prototype.div=function(m){return this.divmod(m,"div",!1).div},a.prototype.mod=function(m){return this.divmod(m,"mod",!1).mod},a.prototype.umod=function(m){return this.divmod(m,"mod",!0).mod},a.prototype.divRound=function(m){var A=this.divmod(m);if(A.mod.isZero())return A.div;var f=A.div.negative!==0?A.mod.isub(m):A.mod,g=m.ushrn(1),_=m.andln(1),B=f.cmp(g);return B<0||_===1&&B===0?A.div:A.div.negative!==0?A.div.isubn(1):A.div.iaddn(1)},a.prototype.modn=function(m){n(m<=67108863);for(var A=67108864%m,f=0,g=this.length-1;g>=0;g--)f=(A*f+(this.words[g]|0))%m;return f},a.prototype.idivn=function(m){n(m<=67108863);for(var A=0,f=this.length-1;f>=0;f--){var g=(this.words[f]|0)+A*67108864;this.words[f]=g/m|0,A=g%m}return this.strip()},a.prototype.divn=function(m){return this.clone().idivn(m)},a.prototype.egcd=function(m){n(m.negative===0),n(!m.isZero());var A=this,f=m.clone();A.negative!==0?A=A.umod(m):A=A.clone();for(var g=new a(1),_=new a(0),B=new a(0),T=new a(1),S=0;A.isEven()&&f.isEven();)A.iushrn(1),f.iushrn(1),++S;for(var h=f.clone(),x=A.clone();!A.isZero();){for(var v=0,F=1;!(A.words[0]&F)&&v<26;++v,F<<=1);if(v>0)for(A.iushrn(v);v-- >0;)(g.isOdd()||_.isOdd())&&(g.iadd(h),_.isub(x)),g.iushrn(1),_.iushrn(1);for(var Q=0,G=1;!(f.words[0]&G)&&Q<26;++Q,G<<=1);if(Q>0)for(f.iushrn(Q);Q-- >0;)(B.isOdd()||T.isOdd())&&(B.iadd(h),T.isub(x)),B.iushrn(1),T.iushrn(1);A.cmp(f)>=0?(A.isub(f),g.isub(B),_.isub(T)):(f.isub(A),B.isub(g),T.isub(_))}return{a:B,b:T,gcd:f.iushln(S)}},a.prototype._invmp=function(m){n(m.negative===0),n(!m.isZero());var A=this,f=m.clone();A.negative!==0?A=A.umod(m):A=A.clone();for(var g=new a(1),_=new a(0),B=f.clone();A.cmpn(1)>0&&f.cmpn(1)>0;){for(var T=0,S=1;!(A.words[0]&S)&&T<26;++T,S<<=1);if(T>0)for(A.iushrn(T);T-- >0;)g.isOdd()&&g.iadd(B),g.iushrn(1);for(var h=0,x=1;!(f.words[0]&x)&&h<26;++h,x<<=1);if(h>0)for(f.iushrn(h);h-- >0;)_.isOdd()&&_.iadd(B),_.iushrn(1);A.cmp(f)>=0?(A.isub(f),g.isub(_)):(f.isub(A),_.isub(g))}var v;return A.cmpn(1)===0?v=g:v=_,v.cmpn(0)<0&&v.iadd(m),v},a.prototype.gcd=function(m){if(this.isZero())return m.abs();if(m.isZero())return this.abs();var A=this.clone(),f=m.clone();A.negative=0,f.negative=0;for(var g=0;A.isEven()&&f.isEven();g++)A.iushrn(1),f.iushrn(1);do{for(;A.isEven();)A.iushrn(1);for(;f.isEven();)f.iushrn(1);var _=A.cmp(f);if(_<0){var B=A;A=f,f=B}else if(_===0||f.cmpn(1)===0)break;A.isub(f)}while(!0);return f.iushln(g)},a.prototype.invm=function(m){return this.egcd(m).a.umod(m)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(m){return this.words[0]&m},a.prototype.bincn=function(m){n(typeof m=="number");var A=m%26,f=(m-A)/26,g=1<<A;if(this.length<=f)return this._expand(f+1),this.words[f]|=g,this;for(var _=g,B=f;_!==0&&B<this.length;B++){var T=this.words[B]|0;T+=_,_=T>>>26,T&=67108863,this.words[B]=T}return _!==0&&(this.words[B]=_,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(m){var A=m<0;if(this.negative!==0&&!A)return-1;if(this.negative===0&&A)return 1;this.strip();var f;if(this.length>1)f=1;else{A&&(m=-m),n(m<=67108863,"Number is too big");var g=this.words[0]|0;f=g===m?0:g<m?-1:1}return this.negative!==0?-f|0:f},a.prototype.cmp=function(m){if(this.negative!==0&&m.negative===0)return-1;if(this.negative===0&&m.negative!==0)return 1;var A=this.ucmp(m);return this.negative!==0?-A|0:A},a.prototype.ucmp=function(m){if(this.length>m.length)return 1;if(this.length<m.length)return-1;for(var A=0,f=this.length-1;f>=0;f--){var g=this.words[f]|0,_=m.words[f]|0;if(g!==_){g<_?A=-1:g>_&&(A=1);break}}return A},a.prototype.gtn=function(m){return this.cmpn(m)===1},a.prototype.gt=function(m){return this.cmp(m)===1},a.prototype.gten=function(m){return this.cmpn(m)>=0},a.prototype.gte=function(m){return this.cmp(m)>=0},a.prototype.ltn=function(m){return this.cmpn(m)===-1},a.prototype.lt=function(m){return this.cmp(m)===-1},a.prototype.lten=function(m){return this.cmpn(m)<=0},a.prototype.lte=function(m){return this.cmp(m)<=0},a.prototype.eqn=function(m){return this.cmpn(m)===0},a.prototype.eq=function(m){return this.cmp(m)===0},a.red=function(m){return new ae(m)},a.prototype.toRed=function(m){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),m.convertTo(this)._forceRed(m)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(m){return this.red=m,this},a.prototype.forceRed=function(m){return n(!this.red,"Already a number in reduction context"),this._forceRed(m)},a.prototype.redAdd=function(m){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,m)},a.prototype.redIAdd=function(m){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,m)},a.prototype.redSub=function(m){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,m)},a.prototype.redISub=function(m){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,m)},a.prototype.redShl=function(m){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,m)},a.prototype.redMul=function(m){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,m),this.red.mul(this,m)},a.prototype.redIMul=function(m){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,m),this.red.imul(this,m)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(m){return n(this.red&&!m.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,m)};var N={k256:null,p224:null,p192:null,p25519:null};function P(m,A){this.name=m,this.p=new a(A,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}P.prototype._tmp=function(){var m=new a(null);return m.words=new Array(Math.ceil(this.n/13)),m},P.prototype.ireduce=function(m){var A=m,f;do this.split(A,this.tmp),A=this.imulK(A),A=A.iadd(this.tmp),f=A.bitLength();while(f>this.n);var g=f<this.n?-1:A.ucmp(this.p);return g===0?(A.words[0]=0,A.length=1):g>0?A.isub(this.p):A.strip!==void 0?A.strip():A._strip(),A},P.prototype.split=function(m,A){m.iushrn(this.n,0,A)},P.prototype.imulK=function(m){return m.imul(this.k)};function Z(){P.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(Z,P),Z.prototype.split=function(m,A){for(var f=4194303,g=Math.min(m.length,9),_=0;_<g;_++)A.words[_]=m.words[_];if(A.length=g,m.length<=9){m.words[0]=0,m.length=1;return}var B=m.words[9];for(A.words[A.length++]=B&f,_=10;_<m.length;_++){var T=m.words[_]|0;m.words[_-10]=(T&f)<<4|B>>>22,B=T}B>>>=22,m.words[_-10]=B,B===0&&m.length>10?m.length-=10:m.length-=9},Z.prototype.imulK=function(m){m.words[m.length]=0,m.words[m.length+1]=0,m.length+=2;for(var A=0,f=0;f<m.length;f++){var g=m.words[f]|0;A+=g*977,m.words[f]=A&67108863,A=g*64+(A/67108864|0)}return m.words[m.length-1]===0&&(m.length--,m.words[m.length-1]===0&&m.length--),m};function X(){P.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}i(X,P);function re(){P.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}i(re,P);function ne(){P.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}i(ne,P),ne.prototype.imulK=function(m){for(var A=0,f=0;f<m.length;f++){var g=(m.words[f]|0)*19+A,_=g&67108863;g>>>=26,m.words[f]=_,A=g}return A!==0&&(m.words[m.length++]=A),m},a._prime=function(m){if(N[m])return N[m];var A;if(m==="k256")A=new Z;else if(m==="p224")A=new X;else if(m==="p192")A=new re;else if(m==="p25519")A=new ne;else throw new Error("Unknown prime "+m);return N[m]=A,A};function ae(m){if(typeof m=="string"){var A=a._prime(m);this.m=A.p,this.prime=A}else n(m.gtn(1),"modulus must be greater than 1"),this.m=m,this.prime=null}ae.prototype._verify1=function(m){n(m.negative===0,"red works only with positives"),n(m.red,"red works only with red numbers")},ae.prototype._verify2=function(m,A){n((m.negative|A.negative)===0,"red works only with positives"),n(m.red&&m.red===A.red,"red works only with red numbers")},ae.prototype.imod=function(m){return this.prime?this.prime.ireduce(m)._forceRed(this):m.umod(this.m)._forceRed(this)},ae.prototype.neg=function(m){return m.isZero()?m.clone():this.m.sub(m)._forceRed(this)},ae.prototype.add=function(m,A){this._verify2(m,A);var f=m.add(A);return f.cmp(this.m)>=0&&f.isub(this.m),f._forceRed(this)},ae.prototype.iadd=function(m,A){this._verify2(m,A);var f=m.iadd(A);return f.cmp(this.m)>=0&&f.isub(this.m),f},ae.prototype.sub=function(m,A){this._verify2(m,A);var f=m.sub(A);return f.cmpn(0)<0&&f.iadd(this.m),f._forceRed(this)},ae.prototype.isub=function(m,A){this._verify2(m,A);var f=m.isub(A);return f.cmpn(0)<0&&f.iadd(this.m),f},ae.prototype.shl=function(m,A){return this._verify1(m),this.imod(m.ushln(A))},ae.prototype.imul=function(m,A){return this._verify2(m,A),this.imod(m.imul(A))},ae.prototype.mul=function(m,A){return this._verify2(m,A),this.imod(m.mul(A))},ae.prototype.isqr=function(m){return this.imul(m,m.clone())},ae.prototype.sqr=function(m){return this.mul(m,m)},ae.prototype.sqrt=function(m){if(m.isZero())return m.clone();var A=this.m.andln(3);if(n(A%2===1),A===3){var f=this.m.add(new a(1)).iushrn(2);return this.pow(m,f)}for(var g=this.m.subn(1),_=0;!g.isZero()&&g.andln(1)===0;)_++,g.iushrn(1);n(!g.isZero());var B=new a(1).toRed(this),T=B.redNeg(),S=this.m.subn(1).iushrn(1),h=this.m.bitLength();for(h=new a(2*h*h).toRed(this);this.pow(h,S).cmp(T)!==0;)h.redIAdd(T);for(var x=this.pow(h,g),v=this.pow(m,g.addn(1).iushrn(1)),F=this.pow(m,g),Q=_;F.cmp(B)!==0;){for(var G=F,J=0;G.cmp(B)!==0;J++)G=G.redSqr();n(J<Q);var Y=this.pow(x,new a(1).iushln(Q-J-1));v=v.redMul(Y),x=Y.redSqr(),F=F.redMul(x),Q=J}return v},ae.prototype.invm=function(m){var A=m._invmp(this.m);return A.negative!==0?(A.negative=0,this.imod(A).redNeg()):this.imod(A)},ae.prototype.pow=function(m,A){if(A.isZero())return new a(1).toRed(this);if(A.cmpn(1)===0)return m.clone();var f=4,g=new Array(1<<f);g[0]=new a(1).toRed(this),g[1]=m;for(var _=2;_<g.length;_++)g[_]=this.mul(g[_-1],m);var B=g[0],T=0,S=0,h=A.bitLength()%26;for(h===0&&(h=26),_=A.length-1;_>=0;_--){for(var x=A.words[_],v=h-1;v>=0;v--){var F=x>>v&1;if(B!==g[0]&&(B=this.sqr(B)),F===0&&T===0){S=0;continue}T<<=1,T|=F,S++,!(S!==f&&(_!==0||v!==0))&&(B=this.mul(B,g[T]),S=0,T=0)}h=26}return B},ae.prototype.convertTo=function(m){var A=m.umod(this.m);return A===m?A.clone():A},ae.prototype.convertFrom=function(m){var A=m.clone();return A.red=null,A},a.mont=function(m){return new ue(m)};function ue(m){ae.call(this,m),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(ue,ae),ue.prototype.convertTo=function(m){return this.imod(m.ushln(this.shift))},ue.prototype.convertFrom=function(m){var A=this.imod(m.mul(this.rinv));return A.red=null,A}
1981,ue.prototype.imul=function(m,A){if(m.isZero()||A.isZero())return m.words[0]=0,m.length=1,m;var f=m.imul(A),g=f.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),_=f.isub(g).iushrn(this.shift),B=_;return _.cmp(this.m)>=0?B=_.isub(this.m):_.cmpn(0)<0&&(B=_.iadd(this.m)),B._forceRed(this)},ue.prototype.mul=function(m,A){if(m.isZero()||A.isZero())return new a(0)._forceRed(this);var f=m.mul(A),g=f.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),_=f.isub(g).iushrn(this.shift),B=_;return _.cmp(this.m)>=0?B=_.isub(this.m):_.cmpn(0)<0&&(B=_.iadd(this.m)),B._forceRed(this)},ue.prototype.invm=function(m){var A=this.imod(m._invmp(this.m).mul(this.r2));return A._forceRed(this)}})(e,dt)}(C8);var Fu=C8.exports,lx={exports:{}},UN;function T8(){if(UN)return lx.exports;UN=1;var e;lx.exports=function(n){return e||(e=new t(null)),e.generate(n)};function t(n){this.rand=n}if(lx.exports.Rand=t,t.prototype.generate=function(n){return this._rand(n)},t.prototype._rand=function(n){if(this.rand.getBytes)return this.rand.getBytes(n);for(var i=new Uint8Array(n),a=0;a<i.length;a++)i[a]=this.rand.getByte();return i},typeof self=="object")self.crypto&&self.crypto.getRandomValues?t.prototype._rand=function(n){var i=new Uint8Array(n);return self.crypto.getRandomValues(i),i}:self.msCrypto&&self.msCrypto.getRandomValues?t.prototype._rand=function(n){var i=new Uint8Array(n);return self.msCrypto.getRandomValues(i),i}:typeof window=="object"&&(t.prototype._rand=function(){throw new Error("Not implemented yet")});else try{var r=XP();if(typeof r.randomBytes!="function")throw new Error("Not supported");t.prototype._rand=function(n){return r.randomBytes(n)}}catch{}return lx.exports}var j8,qN;function VN(){if(qN)return j8;qN=1;var e=Fu,t=T8();function r(n){this.rand=n||new t.Rand}return j8=r,r.create=function(n){return new r(n)},r.prototype._randbelow=function(n){var i=n.bitLength(),a=Math.ceil(i/8);do var s=new e(this.rand.generate(a));while(s.cmp(n)>=0);return s},r.prototype._randrange=function(n,i){var a=i.sub(n);return n.add(this._randbelow(a))},r.prototype.test=function(n,i,a){var s=n.bitLength(),o=e.mont(n),c=new e(1).toRed(o);i||(i=Math.max(1,s/48|0));for(var l=n.subn(1),u=0;!l.testn(u);u++);for(var d=n.shrn(u),p=l.toRed(o),w=!0;i>0;i--){var O=this._randrange(new e(2),l);a&&a(O);var I=O.toRed(o).redPow(d);if(!(I.cmp(c)===0||I.cmp(p)===0)){for(var R=1;R<u;R++){if(I=I.redSqr(),I.cmp(c)===0)return!1;if(I.cmp(p)===0)break}if(R===u)return!1}}return w},r.prototype.getDivisor=function(n,i){var a=n.bitLength(),s=e.mont(n),o=new e(1).toRed(s);i||(i=Math.max(1,a/48|0));for(var c=n.subn(1),l=0;!c.testn(l);l++);for(var u=n.shrn(l),d=c.toRed(s);i>0;i--){var p=this._randrange(new e(2),c),w=n.gcd(p);if(w.cmpn(1)!==0)return w;var O=p.toRed(s).redPow(u);if(!(O.cmp(o)===0||O.cmp(d)===0)){for(var I=1;I<l;I++){if(O=O.redSqr(),O.cmp(o)===0)return O.fromRed().subn(1).gcd(n);if(O.cmp(d)===0)break}if(I===l)return O=O.redSqr(),O.fromRed().subn(1).gcd(n)}}return!1},j8}var I8,ZN;function $N(){if(ZN)return I8;ZN=1;var e=v0;I8=R,R.simpleSieve=O,R.fermatTest=I;var t=Fu,r=new t(24),n=VN(),i=new n,a=new t(1),s=new t(2),o=new t(5);new t(16),new t(8);var c=new t(10),l=new t(3);new t(7);var u=new t(11),d=new t(4);new t(12);var p=null;function w(){if(p!==null)return p;var C=1048576,j=[];j[0]=2;for(var N=1,P=3;P<C;P+=2){for(var Z=Math.ceil(Math.sqrt(P)),X=0;X<N&&j[X]<=Z&&P%j[X]!==0;X++);N!==X&&j[X]<=Z||(j[N++]=P)}return p=j,j}function O(C){for(var j=w(),N=0;N<j.length;N++)if(C.modn(j[N])===0)return C.cmpn(j[N])===0;return!0}function I(C){var j=t.mont(C);return s.toRed(j).redPow(C.subn(1)).fromRed().cmpn(1)===0}function R(C,j){if(C<16)return j===2||j===5?new t([140,123]):new t([140,39]);j=new t(j);for(var N,P;;){for(N=new t(e(Math.ceil(C/8)));N.bitLength()>C;)N.ishrn(1);if(N.isEven()&&N.iadd(a),N.testn(1)||N.iadd(s),j.cmp(s)){if(!j.cmp(o))for(;N.mod(c).cmp(l);)N.iadd(d)}else for(;N.mod(r).cmp(u);)N.iadd(d);if(P=N.shrn(1),O(P)&&O(N)&&I(P)&&I(N)&&i.test(P)&&i.test(N))return N}}return I8}const nfe={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},ife={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},afe={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},sfe={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},ofe={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},lfe={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},cfe={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd4
198107b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},ufe={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"},ffe={modp1:nfe,modp2:ife,modp5:afe,modp14:sfe,modp15:ofe,modp16:lfe,modp17:cfe,modp18:ufe};var O8,HN;function hfe(){if(HN)return O8;HN=1;var e=Fu,t=VN(),r=new t,n=new e(24),i=new e(11),a=new e(10),s=new e(3),o=new e(7),c=$N(),l=v0;O8=O;function u(R,C){return C=C||"utf8",je.isBuffer(R)||(R=new je(R,C)),this._pub=new e(R),this}function d(R,C){return C=C||"utf8",je.isBuffer(R)||(R=new je(R,C)),this._priv=new e(R),this}var p={};function w(R,C){var j=C.toString("hex"),N=[j,R.toString(16)].join("_");if(N in p)return p[N];var P=0;if(R.isEven()||!c.simpleSieve||!c.fermatTest(R)||!r.test(R))return P+=1,j==="02"||j==="05"?P+=8:P+=4,p[N]=P,P;r.test(R.shrn(1))||(P+=2);var Z;switch(j){case"02":R.mod(n).cmp(i)&&(P+=8);break;case"05":Z=R.mod(a),Z.cmp(s)&&Z.cmp(o)&&(P+=8);break;default:P+=4}return p[N]=P,P}function O(R,C,j){this.setGenerator(C),this.__prime=new e(R),this._prime=e.mont(this.__prime),this._primeLen=R.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,j?(this.setPublicKey=u,this.setPrivateKey=d):this._primeCode=8}Object.defineProperty(O.prototype,"verifyError",{enumerable:!0,get:function(){return typeof this._primeCode!="number"&&(this._primeCode=w(this.__prime,this.__gen)),this._primeCode}}),O.prototype.generateKeys=function(){return this._priv||(this._priv=new e(l(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},O.prototype.computeSecret=function(R){R=new e(R),R=R.toRed(this._prime);var C=R.redPow(this._priv).fromRed(),j=new je(C.toArray()),N=this.getPrime();if(j.length<N.length){var P=new je(N.length-j.length);P.fill(0),j=je.concat([P,j])}return j},O.prototype.getPublicKey=function(R){return I(this._pub,R)},O.prototype.getPrivateKey=function(R){return I(this._priv,R)},O.prototype.getPrime=function(R){return I(this.__prime,R)},O.prototype.getGenerator=function(R){return I(this._gen,R)},O.prototype.setGenerator=function(R,C){return C=C||"utf8",je.isBuffer(R)||(R=new je(R,C)),this.__gen=R,this._gen=new e(R),this};function I(R,C){var j=new je(R.toArray());return C?j.toString(C):j}return O8}var WN;function dfe(){if(WN)return xh;WN=1;var e=$N(),t=ffe,r=hfe();function n(s){var o=new je(t[s].prime,"hex"),c=new je(t[s].gen,"hex");return new r(o,c)}var i={binary:!0,hex:!0,base64:!0};function a(s,o,c,l){return je.isBuffer(o)||i[o]===void 0?a(s,"binary",o,c):(o=o||"binary",l=l||"binary",c=c||new je([2]),je.isBuffer(c)||(c=new je(c,l)),typeof s=="number"?new r(e(s,c),c,!0):(je.isBuffer(s)||(s=new je(s,o)),new r(s,c,!0)))}return xh.DiffieHellmanGroup=xh.createDiffieHellmanGroup=xh.getDiffieHellman=n,xh.createDiffieHellman=xh.DiffieHellman=a,xh}var B8={exports:{}},R8={exports:{}};typeof ot>"u"||!ot.version||ot.version.indexOf("v0.")===0||ot.version.indexOf("v1.")===0&&ot.version.indexOf("v1.8.")!==0?R8.exports={nextTick:pfe}:R8.exports=ot;function pfe(e,t,r,n){if(typeof e!="function")throw new TypeError('"callback" argument must be a function');var i=arguments.length,a,s;switch(i){case 0:case 1:return ot.nextTick(e);case 2:return ot.nextTick(function(){e.call(null,t)});case 3:return ot.nextTick(function(){e.call(null,t,r)});case 4:return ot.nextTick(function(){e.call(null,t,r,n)});default:for(a=new Array(i-1),s=0;s<a.length;)a[s++]=arguments[s];return ot.nextTick(function(){e.apply(null,a)})}}var cx=R8.exports,mfe={}.toString,gfe=Array.isArray||function(e){return mfe.call(e)=="[object Array]"},KN=jg.EventEmitter,N8={exports:{}};(function(e,t){var r=ji,n=r.Buffer;function i(s,o){for(var c in s)o[c]=s[c]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=r:(i(r,t),t.Buffer=a);function a(s,o,c){return n(s,o,c)}i(n,a),a.from=function(s,o,c){if(typeof s=="number")throw new TypeError("Argument must not be a number");return n(s,o,c)},a.alloc=function(s,o,c){if(typeof s!="number")throw new TypeError("Argument must be a number");var l=n(s);
1981return o!==void 0?typeof c=="string"?l.fill(o,c):l.fill(o):l.fill(0),l},a.allocUnsafe=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return n(s)},a.allocUnsafeSlow=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(s)}})(N8,N8.exports);var F8=N8.exports,$n={};function bfe(e){return Array.isArray?Array.isArray(e):ux(e)==="[object Array]"}$n.isArray=bfe;function yfe(e){return typeof e=="boolean"}$n.isBoolean=yfe;function vfe(e){return e===null}$n.isNull=vfe;function wfe(e){return e==null}$n.isNullOrUndefined=wfe;function xfe(e){return typeof e=="number"}$n.isNumber=xfe;function _fe(e){return typeof e=="string"}$n.isString=_fe;function Sfe(e){return typeof e=="symbol"}$n.isSymbol=Sfe;function kfe(e){return e===void 0}$n.isUndefined=kfe;function Efe(e){return ux(e)==="[object RegExp]"}$n.isRegExp=Efe;function Mfe(e){return typeof e=="object"&&e!==null}$n.isObject=Mfe;function Afe(e){return ux(e)==="[object Date]"}$n.isDate=Afe;function Cfe(e){return ux(e)==="[object Error]"||e instanceof Error}$n.isError=Cfe;function Tfe(e){return typeof e=="function"}$n.isFunction=Tfe;function jfe(e){return e===null||typeof e=="boolean"||typeof e=="number"||typeof e=="string"||typeof e=="symbol"||typeof e>"u"}$n.isPrimitive=jfe,$n.isBuffer=ji.Buffer.isBuffer;function ux(e){return Object.prototype.toString.call(e)}var GN={exports:{}},YN;function Ife(){return YN||(YN=1,function(e){function t(a,s){if(!(a instanceof s))throw new TypeError("Cannot call a class as a function")}var r=F8.Buffer,n=ct;function i(a,s,o){a.copy(s,o)}e.exports=function(){function a(){t(this,a),this.head=null,this.tail=null,this.length=0}return a.prototype.push=function(s){var o={data:s,next:null};this.length>0?this.tail.next=o:this.head=o,this.tail=o,++this.length},a.prototype.unshift=function(s){var o={data:s,next:this.head};this.length===0&&(this.tail=o),this.head=o,++this.length},a.prototype.shift=function(){if(this.length!==0){var s=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,s}},a.prototype.clear=function(){this.head=this.tail=null,this.length=0},a.prototype.join=function(s){if(this.length===0)return"";for(var o=this.head,c=""+o.data;o=o.next;)c+=s+o.data;return c},a.prototype.concat=function(s){if(this.length===0)return r.alloc(0);for(var o=r.allocUnsafe(s>>>0),c=this.head,l=0;c;)i(c.data,o,l),l+=c.data.length,c=c.next;return o},a}(),n&&n.inspect&&n.inspect.custom&&(e.exports.prototype[n.inspect.custom]=function(){var a=n.inspect({length:this.length});return this.constructor.name+" "+a})}(GN)),GN.exports}var fx=cx;function Ofe(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,fx.nextTick(hx,this,e)):fx.nextTick(hx,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(a){!t&&a?r._writableState?r._writableState.errorEmitted||(r._writableState.errorEmitted=!0,fx.nextTick(hx,r,a)):fx.nextTick(hx,r,a):t&&t(a)}),this)}function Bfe(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function hx(e,t){e.emit("error",t)}var XN={destroy:Ofe,undestroy:Bfe},P8,JN;function QN(){if(JN)return P8;JN=1;var e=cx;P8=I;function t(T){var S=this;this.next=null,this.entry=null,this.finish=function(){B(S,T)}}var r=!ot.browser&&["v0.10","v0.9."].indexOf(ot.version.slice(0,5))>-1?setImmediate:e.nextTick,n;I.WritableState=w;var i=Object.create($n);i.inherits=Zt;var a={deprecate:KB},s=KN,o=F8.Buffer,c=(typeof dt<"u"?dt:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function l(T){return o.from(T)}function u(T){return o.isBuffer(T)||T instanceof c}var d=XN;i.inherits(I,s);function p(){}function w(T,S){n=n||C0(),T=T||{};var h=S instanceof n;this.objectMode=!!T.objectMode,h&&(this.objectMode=this.objectMode||!!T.writableObjectMode);var x=T.highWaterMark,v=T.writableHighWaterMark,F=this.objectMode?16:16*1024;x||x===0?this.highWaterMark=x:h&&(v||v===0)?this.highWaterMark=v:this.highWaterMark=F,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var Q=T.decodeStrings===!1;this.decodeStrings=!Q,this.defaultEncoding=T.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(G){re(S,G)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new t(this)}w.prototype.getBuffer=function(){for(var T=this.bufferedRequest,S=[];T;)S.push(T),T=T.next;return S},function(){try{Object.defineProperty(w.prototype,"buffer",{get:a.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var O;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(O=Function.prototype[Symbol.hasInstance],Object.defineProperty(I,Symbol.hasInstance,{value:function(T){return O.call(this,T)?!0:this!==I?!1:T&&T._writableState instanceof w}})):O=function(T){return T instanceof this};function I(T){if(n=n||C0(),!O.call(I,this)&&!(this instanceof n))return new I(T);this._writableState=new w(T,this),this.writable=!0,T&&(typeof T.write=="function"&&(this._write=T.write),typeof T.writev=="function"&&(this._writev=T.writev),typeof T.destroy=="function"&&(this._destroy=T.destroy),typeof T.final=="function"&&(this._final=T.final)),s.call(this)}
1981I.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))};function R(T,S){var h=new Error("write after end");T.emit("error",h),e.nextTick(S,h)}function C(T,S,h,x){var v=!0,F=!1;return h===null?F=new TypeError("May not write null values to stream"):typeof h!="string"&&h!==void 0&&!S.objectMode&&(F=new TypeError("Invalid non-string/buffer chunk")),F&&(T.emit("error",F),e.nextTick(x,F),v=!1),v}I.prototype.write=function(T,S,h){var x=this._writableState,v=!1,F=!x.objectMode&&u(T);return F&&!o.isBuffer(T)&&(T=l(T)),typeof S=="function"&&(h=S,S=null),F?S="buffer":S||(S=x.defaultEncoding),typeof h!="function"&&(h=p),x.ended?R(this,h):(F||C(this,x,T,h))&&(x.pendingcb++,v=N(this,x,F,T,S,h)),v},I.prototype.cork=function(){var T=this._writableState;T.corked++},I.prototype.uncork=function(){var T=this._writableState;T.corked&&(T.corked--,!T.writing&&!T.corked&&!T.bufferProcessing&&T.bufferedRequest&&ue(this,T))},I.prototype.setDefaultEncoding=function(T){if(typeof T=="string"&&(T=T.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((T+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+T);return this._writableState.defaultEncoding=T,this};function j(T,S,h){return!T.objectMode&&T.decodeStrings!==!1&&typeof S=="string"&&(S=o.from(S,h)),S}Object.defineProperty(I.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function N(T,S,h,x,v,F){if(!h){var Q=j(S,x,v);x!==Q&&(h=!0,v="buffer",x=Q)}var G=S.objectMode?1:x.length;S.length+=G;var J=S.length<S.highWaterMark;if(J||(S.needDrain=!0),S.writing||S.corked){var Y=S.lastBufferedRequest;S.lastBufferedRequest={chunk:x,encoding:v,isBuf:h,callback:F,next:null},Y?Y.next=S.lastBufferedRequest:S.bufferedRequest=S.lastBufferedRequest,S.bufferedRequestCount+=1}else P(T,S,!1,G,x,v,F);return J}function P(T,S,h,x,v,F,Q){S.writelen=x,S.writecb=Q,S.writing=!0,S.sync=!0,h?T._writev(v,S.onwrite):T._write(v,F,S.onwrite),S.sync=!1}function Z(T,S,h,x,v){--S.pendingcb,h?(e.nextTick(v,x),e.nextTick(g,T,S),T._writableState.errorEmitted=!0,T.emit("error",x)):(v(x),T._writableState.errorEmitted=!0,T.emit("error",x),g(T,S))}function X(T){T.writing=!1,T.writecb=null,T.length-=T.writelen,T.writelen=0}function re(T,S){var h=T._writableState,x=h.sync,v=h.writecb;if(X(h),S)Z(T,h,x,S,v);else{var F=m(h);!F&&!h.corked&&!h.bufferProcessing&&h.bufferedRequest&&ue(T,h),x?r(ne,T,h,F,v):ne(T,h,F,v)}}function ne(T,S,h,x){h||ae(T,S),S.pendingcb--,x(),g(T,S)}function ae(T,S){S.length===0&&S.needDrain&&(S.needDrain=!1,T.emit("drain"))}function ue(T,S){S.bufferProcessing=!0;var h=S.bufferedRequest;if(T._writev&&h&&h.next){var x=S.bufferedRequestCount,v=new Array(x),F=S.corkedRequestsFree;F.entry=h;for(var Q=0,G=!0;h;)v[Q]=h,h.isBuf||(G=!1),h=h.next,Q+=1;v.allBuffers=G,P(T,S,!0,S.length,v,"",F.finish),S.pendingcb++,S.lastBufferedRequest=null,F.next?(S.corkedRequestsFree=F.next,F.next=null):S.corkedRequestsFree=new t(S),S.bufferedRequestCount=0}else{for(;h;){var J=h.chunk,Y=h.encoding,V=h.callback,W=S.objectMode?1:J.length;if(P(T,S,!1,W,J,Y,V),h=h.next,S.bufferedRequestCount--,S.writing)break}h===null&&(S.lastBufferedRequest=null)}S.bufferedRequest=h,S.bufferProcessing=!1}I.prototype._write=function(T,S,h){h(new Error("_write() is not implemented"))},I.prototype._writev=null,I.prototype.end=function(T,S,h){var x=this._writableState;typeof T=="function"?(h=T,T=null,S=null):typeof S=="function"&&(h=S,S=null),T!=null&&this.write(T,S),x.corked&&(x.corked=1,this.uncork()),x.ending||_(this,x,h)};function m(T){return T.ending&&T.length===0&&T.bufferedRequest===null&&!T.finished&&!T.writing}function A(T,S){T._final(function(h){S.pendingcb--,h&&T.emit("error",h),S.prefinished=!0,T.emit("prefinish"),g(T,S)})}function f(T,S){!S.prefinished&&!S.finalCalled&&(typeof T._final=="function"?(S.pendingcb++,S.finalCalled=!0,e.nextTick(A,T,S)):(S.prefinished=!0,T.emit("prefinish")))}function g(T,S){var h=m(S);return h&&(f(T,S),S.pendingcb===0&&(S.finished=!0,T.emit("finish"))),h}
1981function _(T,S,h){S.ending=!0,g(T,S),h&&(S.finished?e.nextTick(h):T.once("finish",h)),S.ended=!0,T.writable=!1}function B(T,S,h){var x=T.entry;for(T.entry=null;x;){var v=x.callback;S.pendingcb--,v(h),x=x.next}S.corkedRequestsFree.next=T}return Object.defineProperty(I.prototype,"destroyed",{get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(T){this._writableState&&(this._writableState.destroyed=T)}}),I.prototype.destroy=d.destroy,I.prototype._undestroy=d.undestroy,I.prototype._destroy=function(T,S){this.end(),S(T)},P8}var z8,eF;function C0(){if(eF)return z8;eF=1;var e=cx,t=Object.keys||function(d){var p=[];for(var w in d)p.push(w);return p};z8=c;var r=Object.create($n);r.inherits=Zt;var n=aF(),i=QN();r.inherits(c,n);for(var a=t(i.prototype),s=0;s<a.length;s++){var o=a[s];c.prototype[o]||(c.prototype[o]=i.prototype[o])}function c(d){if(!(this instanceof c))return new c(d);n.call(this,d),i.call(this,d),d&&d.readable===!1&&(this.readable=!1),d&&d.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,d&&d.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",l)}Object.defineProperty(c.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function l(){this.allowHalfOpen||this._writableState.ended||e.nextTick(u,this)}function u(d){d.end()}return Object.defineProperty(c.prototype,"destroyed",{get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(d){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=d,this._writableState.destroyed=d)}}),c.prototype._destroy=function(d,p){this.push(null),this.end(),e.nextTick(p,d)},z8}var L8={},D8={exports:{}},tF;function Rfe(){return tF||(tF=1,function(e,t){var r=ji,n=r.Buffer;function i(s,o){for(var c in s)o[c]=s[c]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=r:(i(r,t),t.Buffer=a);function a(s,o,c){return n(s,o,c)}i(n,a),a.from=function(s,o,c){if(typeof s=="number")throw new TypeError("Argument must not be a number");return n(s,o,c)},a.alloc=function(s,o,c){if(typeof s!="number")throw new TypeError("Argument must be a number");var l=n(s);return o!==void 0?typeof c=="string"?l.fill(o,c):l.fill(o):l.fill(0),l},a.allocUnsafe=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return n(s)},a.allocUnsafeSlow=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(s)}}(D8,D8.exports)),D8.exports}var rF;function nF(){if(rF)return L8;rF=1;var e=Rfe().Buffer,t=e.isEncoding||function(C){switch(C=""+C,C&&C.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function r(C){if(!C)return"utf8";for(var j;;)switch(C){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return C;default:if(j)return;C=(""+C).toLowerCase(),j=!0}}function n(C){var j=r(C);if(typeof j!="string"&&(e.isEncoding===t||!t(C)))throw new Error("Unknown encoding: "+C);return j||C}L8.StringDecoder=i;function i(C){this.encoding=n(C);var j;switch(this.encoding){case"utf16le":this.text=d,this.end=p,j=4;break;case"utf8":this.fillLast=c,j=4;break;case"base64":this.text=w,this.end=O,j=3;break;default:this.write=I,this.end=R;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=e.allocUnsafe(j)}i.prototype.write=function(C){if(C.length===0)return"";var j,N;if(this.lastNeed){if(j=this.fillLast(C),j===void 0)return"";N=this.lastNeed,this.lastNeed=0}else N=0;return N<C.length?j?j+this.text(C,N):this.text(C,N):j||""},i.prototype.end=u,i.prototype.text=l,i.prototype.fillLast=function(C){if(this.lastNeed<=C.length)return C.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);C.copy(this.lastChar,this.lastTotal-this.lastNeed,0,C.length),this.lastNeed-=C.length};function a(C){return C<=127?0:C>>5===6?2:C>>4===14?3:C>>3===30?4:C>>6===2?-1:-2}function s(C,j,N){var P=j.length-1;if(P<N)return 0;var Z=a(j[P]);return Z>=0?(Z>0&&(C.lastNeed=Z-1),Z):--P<N||Z===-2?0:(Z=a(j[P]),Z>=0?(Z>0&&(C.lastNeed=Z-2),Z):--P<N||Z===-2?0:(Z=a(j[P]),Z>=0?(Z>0&&(Z===2?Z=0:C.lastNeed=Z-3),Z):0))}
1981function o(C,j,N){if((j[0]&192)!==128)return C.lastNeed=0,"\uFFFD";if(C.lastNeed>1&&j.length>1){if((j[1]&192)!==128)return C.lastNeed=1,"\uFFFD";if(C.lastNeed>2&&j.length>2&&(j[2]&192)!==128)return C.lastNeed=2,"\uFFFD"}}function c(C){var j=this.lastTotal-this.lastNeed,N=o(this,C);if(N!==void 0)return N;if(this.lastNeed<=C.length)return C.copy(this.lastChar,j,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);C.copy(this.lastChar,j,0,C.length),this.lastNeed-=C.length}function l(C,j){var N=s(this,C,j);if(!this.lastNeed)return C.toString("utf8",j);this.lastTotal=N;var P=C.length-(N-this.lastNeed);return C.copy(this.lastChar,0,P),C.toString("utf8",j,P)}function u(C){var j=C&&C.length?this.write(C):"";return this.lastNeed?j+"\uFFFD":j}function d(C,j){if((C.length-j)%2===0){var N=C.toString("utf16le",j);if(N){var P=N.charCodeAt(N.length-1);if(P>=55296&&P<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=C[C.length-2],this.lastChar[1]=C[C.length-1],N.slice(0,-1)}return N}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=C[C.length-1],C.toString("utf16le",j,C.length-1)}function p(C){var j=C&&C.length?this.write(C):"";if(this.lastNeed){var N=this.lastTotal-this.lastNeed;return j+this.lastChar.toString("utf16le",0,N)}return j}function w(C,j){var N=(C.length-j)%3;return N===0?C.toString("base64",j):(this.lastNeed=3-N,this.lastTotal=3,N===1?this.lastChar[0]=C[C.length-1]:(this.lastChar[0]=C[C.length-2],this.lastChar[1]=C[C.length-1]),C.toString("base64",j,C.length-N))}function O(C){var j=C&&C.length?this.write(C):"";return this.lastNeed?j+this.lastChar.toString("base64",0,3-this.lastNeed):j}function I(C){return C.toString(this.encoding)}function R(C){return C&&C.length?this.write(C):""}return L8}var U8,iF;function aF(){if(iF)return U8;iF=1;var e=cx;U8=j;var t=gfe,r;j.ReadableState=C,jg.EventEmitter;var n=function(V,W){return V.listeners(W).length},i=KN,a=F8.Buffer,s=(typeof dt<"u"?dt:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function o(V){return a.from(V)}function c(V){return a.isBuffer(V)||V instanceof s}var l=Object.create($n);l.inherits=Zt;var u=ct,d=void 0;u&&u.debuglog?d=u.debuglog("stream"):d=function(){};var p=Ife(),w=XN,O;l.inherits(j,i);var I=["error","close","destroy","pause","resume"];function R(V,W,ce){if(typeof V.prependListener=="function")return V.prependListener(W,ce);!V._events||!V._events[W]?V.on(W,ce):t(V._events[W])?V._events[W].unshift(ce):V._events[W]=[ce,V._events[W]]}function C(V,W){r=r||C0(),V=V||{};var ce=W instanceof r;this.objectMode=!!V.objectMode,ce&&(this.objectMode=this.objectMode||!!V.readableObjectMode);var pe=V.highWaterMark,ee=V.readableHighWaterMark,se=this.objectMode?16:16*1024;pe||pe===0?this.highWaterMark=pe:ce&&(ee||ee===0)?this.highWaterMark=ee:this.highWaterMark=se,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new p,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=V.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,V.encoding&&(O||(O=nF().StringDecoder),this.decoder=new O(V.encoding),this.encoding=V.encoding)}function j(V){if(r=r||C0(),!(this instanceof j))return new j(V);this._readableState=new C(V,this),this.readable=!0,V&&(typeof V.read=="function"&&(this._read=V.read),typeof V.destroy=="function"&&(this._destroy=V.destroy)),i.call(this)}Object.defineProperty(j.prototype,"destroyed",{get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(V){this._readableState&&(this._readableState.destroyed=V)}}),j.prototype.destroy=w.destroy,j.prototype._undestroy=w.undestroy,j.prototype._destroy=function(V,W){this.push(null),W(V)},j.prototype.push=function(V,W){var ce=this._readableState,pe;return ce.objectMode?pe=!0:typeof V=="string"&&(W=W||ce.defaultEncoding,W!==ce.encoding&&(V=a.from(V,W),W=""),pe=!0),N(this,V,W,!1,pe)},j.prototype.unshift=function(V){return N(this,V,null,!0,!1)};function N(V,W,ce,pe,ee){var se=V._readableState;if(W===null)se.reading=!1,ue(V,se);else{var ve;ee||(ve=Z(se,W)),ve?V.emit("error",ve):se.objectMode||W&&W.length>
19810?(typeof W!="string"&&!se.objectMode&&Object.getPrototypeOf(W)!==a.prototype&&(W=o(W)),pe?se.endEmitted?V.emit("error",new Error("stream.unshift() after end event")):P(V,se,W,!0):se.ended?V.emit("error",new Error("stream.push() after EOF")):(se.reading=!1,se.decoder&&!ce?(W=se.decoder.write(W),se.objectMode||W.length!==0?P(V,se,W,!1):f(V,se)):P(V,se,W,!1))):pe||(se.reading=!1)}return X(se)}function P(V,W,ce,pe){W.flowing&&W.length===0&&!W.sync?(V.emit("data",ce),V.read(0)):(W.length+=W.objectMode?1:ce.length,pe?W.buffer.unshift(ce):W.buffer.push(ce),W.needReadable&&m(V)),f(V,W)}function Z(V,W){var ce;return!c(W)&&typeof W!="string"&&W!==void 0&&!V.objectMode&&(ce=new TypeError("Invalid non-string/buffer chunk")),ce}function X(V){return!V.ended&&(V.needReadable||V.length<V.highWaterMark||V.length===0)}j.prototype.isPaused=function(){return this._readableState.flowing===!1},j.prototype.setEncoding=function(V){return O||(O=nF().StringDecoder),this._readableState.decoder=new O(V),this._readableState.encoding=V,this};var re=8388608;function ne(V){return V>=re?V=re:(V--,V|=V>>>1,V|=V>>>2,V|=V>>>4,V|=V>>>8,V|=V>>>16,V++),V}function ae(V,W){return V<=0||W.length===0&&W.ended?0:W.objectMode?1:V!==V?W.flowing&&W.length?W.buffer.head.data.length:W.length:(V>W.highWaterMark&&(W.highWaterMark=ne(V)),V<=W.length?V:W.ended?W.length:(W.needReadable=!0,0))}j.prototype.read=function(V){d("read",V),V=parseInt(V,10);var W=this._readableState,ce=V;if(V!==0&&(W.emittedReadable=!1),V===0&&W.needReadable&&(W.length>=W.highWaterMark||W.ended))return d("read: emitReadable",W.length,W.ended),W.length===0&&W.ended?G(this):m(this),null;if(V=ae(V,W),V===0&&W.ended)return W.length===0&&G(this),null;var pe=W.needReadable;d("need readable",pe),(W.length===0||W.length-V<W.highWaterMark)&&(pe=!0,d("length less than watermark",pe)),W.ended||W.reading?(pe=!1,d("reading or ended",pe)):pe&&(d("do read"),W.reading=!0,W.sync=!0,W.length===0&&(W.needReadable=!0),this._read(W.highWaterMark),W.sync=!1,W.reading||(V=ae(ce,W)));var ee;return V>0?ee=x(V,W):ee=null,ee===null?(W.needReadable=!0,V=0):W.length-=V,W.length===0&&(W.ended||(W.needReadable=!0),ce!==V&&W.ended&&G(this)),ee!==null&&this.emit("data",ee),ee};function ue(V,W){if(!W.ended){if(W.decoder){var ce=W.decoder.end();ce&&ce.length&&(W.buffer.push(ce),W.length+=W.objectMode?1:ce.length)}W.ended=!0,m(V)}}function m(V){var W=V._readableState;W.needReadable=!1,W.emittedReadable||(d("emitReadable",W.flowing),W.emittedReadable=!0,W.sync?e.nextTick(A,V):A(V))}function A(V){d("emit readable"),V.emit("readable"),h(V)}function f(V,W){W.readingMore||(W.readingMore=!0,e.nextTick(g,V,W))}function g(V,W){for(var ce=W.length;!W.reading&&!W.flowing&&!W.ended&&W.length<W.highWaterMark&&(d("maybeReadMore read 0"),V.read(0),ce!==W.length);)ce=W.length;W.readingMore=!1}j.prototype._read=function(V){this.emit("error",new Error("_read() is not implemented"))},j.prototype.pipe=function(V,W){var ce=this,pe=this._readableState;switch(pe.pipesCount){case 0:pe.pipes=V;break;case 1:pe.pipes=[pe.pipes,V];break;default:pe.pipes.push(V);break}pe.pipesCount+=1,d("pipe count=%d opts=%j",pe.pipesCount,W);var ee=(!W||W.end!==!1)&&V!==ot.stdout&&V!==ot.stderr,se=ee?_e:Fe;pe.endEmitted?e.nextTick(se):ce.once("end",se),V.on("unpipe",ve);function ve(ge,we){d("onunpipe"),ge===ce&&we&&we.hasUnpiped===!1&&(we.hasUnpiped=!0,Te())}function _e(){d("onend"),V.end()}var Ue=_(ce);V.on("drain",Ue);var xe=!1;function Te(){d("cleanup"),V.removeListener("close",Ke),V.removeListener("finish",ut),V.removeListener("drain",Ue),V.removeListener("error",De),V.removeListener("unpipe",ve),ce.removeListener("end",_e),ce.removeListener("end",Fe),ce.removeListener("data",Ae),xe=!0,pe.awaitDrain&&(!V._writableState||V._writableState.needDrain)&&Ue()}var $e=!1;ce.on("data",Ae);function Ae(ge){d("ondata"),$e=!1;var we=V.write(ge);we===!1&&!$e&&((pe.pipesCount===1&&pe.pipes===V||pe.pipesCount>1&&Y(pe.pipes,V)!==-1)&&!xe&&(d("false write response, pause",pe.awaitDrain),pe.awaitDrain++,$e=!0),ce.pause())}function De(ge){d("onerror",ge),Fe(),V.removeListener("error",De),n(V,"error")===0&&V.emit("error",ge)}R(V,"error",De);function Ke(){V.removeListener("finish",ut),Fe()}V.once("close",Ke);function ut(){d("onfinish"),V.removeListener("close",Ke),Fe()}V.once("finish",ut);function Fe(){d("unpipe"),ce.unpipe(V)}return V.emit("pipe",ce),pe.flowing||(d("pipe resume"),ce.resume()),V};function _(V){return function(){var W=V._readableState;d("pipeOnDrain",W.awaitDrain),W.awaitDrain&&W.awaitDrain--,W.awaitDrain===0&&n(V,"data")&&(W.flowing=!0,h(V))}}j.prototype.unpipe=function(V){var W=this._readableState,ce={hasUnpiped:!1};if(W.pipesCount===0)return this;if(W.pipesCount===1)return V&&V!==W.pipes?this:(V||(V=W.pipes),W.pipes=null,W.pipesCount=0,W.flowing=!1,V&&V.emit("unpipe",this,ce),this);if(!V){var pe=W.pipes,ee=W.pipesCount;W.pipes=null,W.pipesCount=0,W.flowing=!1;for(var se=0;se<ee;se++)pe[se].emit("unpipe",this,{hasUnpiped:!1});return this}var ve=Y(W.pipes,V);return ve===-1?this:(W.pipes.splice(ve,1),W.pipesCount-=1,W.pipesCount===1&&(W.pipes=W.pipes[0]),V.emit("unpipe",this,ce),this)},j.prototype.on=function(V,W){var ce=i.prototype.on.call(this,V,W);if(V==="data")this._readableState.flowing!==!1&&this.resume();else if(V==="readable"){var pe=this._readableState;!pe.endEmitted&&!pe.readableListening&&(pe.readableListening=pe.needReadable=!0,pe.emittedReadable=!1,pe.reading?pe.length&&m(this):e.nextTick(B,this))}return ce},j.prototype.addListener=j.prototype.on;function B(V){d("readable nexttick read 0"),V.read(0)}j.prototype.resume=function(){var V=this._readableState;return V.flowing||(d("resume"),V.flowing=!0,T(this,V)),this};function T(V,W){W.resumeScheduled||(W.resumeScheduled=!0,e.nextTick(S,V,W))}function S(V,W){W.reading||(d("resume read 0"),V.read(0)),W.resumeScheduled=!1,W.awaitDrain=0,V.emit("resume"),h(V),W.flowing&&!W.reading&&V.read(0)}j.prototype.pause=function(){return d("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(d("pause"),this._readableState.flowing=!1,this.emit
1981("pause")),this};function h(V){var W=V._readableState;for(d("flow",W.flowing);W.flowing&&V.read()!==null;);}j.prototype.wrap=function(V){var W=this,ce=this._readableState,pe=!1;V.on("end",function(){if(d("wrapped end"),ce.decoder&&!ce.ended){var ve=ce.decoder.end();ve&&ve.length&&W.push(ve)}W.push(null)}),V.on("data",function(ve){if(d("wrapped data"),ce.decoder&&(ve=ce.decoder.write(ve)),!(ce.objectMode&&ve==null)&&!(!ce.objectMode&&(!ve||!ve.length))){var _e=W.push(ve);_e||(pe=!0,V.pause())}});for(var ee in V)this[ee]===void 0&&typeof V[ee]=="function"&&(this[ee]=function(ve){return function(){return V[ve].apply(V,arguments)}}(ee));for(var se=0;se<I.length;se++)V.on(I[se],this.emit.bind(this,I[se]));return this._read=function(ve){d("wrapped _read",ve),pe&&(pe=!1,V.resume())},this},Object.defineProperty(j.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),j._fromList=x;function x(V,W){if(W.length===0)return null;var ce;return W.objectMode?ce=W.buffer.shift():!V||V>=W.length?(W.decoder?ce=W.buffer.join(""):W.buffer.length===1?ce=W.buffer.head.data:ce=W.buffer.concat(W.length),W.buffer.clear()):ce=v(V,W.buffer,W.decoder),ce}function v(V,W,ce){var pe;return V<W.head.data.length?(pe=W.head.data.slice(0,V),W.head.data=W.head.data.slice(V)):V===W.head.data.length?pe=W.shift():pe=ce?F(V,W):Q(V,W),pe}function F(V,W){var ce=W.head,pe=1,ee=ce.data;for(V-=ee.length;ce=ce.next;){var se=ce.data,ve=V>se.length?se.length:V;if(ve===se.length?ee+=se:ee+=se.slice(0,V),V-=ve,V===0){ve===se.length?(++pe,ce.next?W.head=ce.next:W.head=W.tail=null):(W.head=ce,ce.data=se.slice(ve));break}++pe}return W.length-=pe,ee}function Q(V,W){var ce=a.allocUnsafe(V),pe=W.head,ee=1;for(pe.data.copy(ce),V-=pe.data.length;pe=pe.next;){var se=pe.data,ve=V>se.length?se.length:V;if(se.copy(ce,ce.length-V,0,ve),V-=ve,V===0){ve===se.length?(++ee,pe.next?W.head=pe.next:W.head=W.tail=null):(W.head=pe,pe.data=se.slice(ve));break}++ee}return W.length-=ee,ce}function G(V){var W=V._readableState;if(W.length>0)throw new Error('"endReadable()" called on non-empty stream');W.endEmitted||(W.ended=!0,e.nextTick(J,W,V))}function J(V,W){!V.endEmitted&&V.length===0&&(V.endEmitted=!0,W.readable=!1,W.emit("end"))}function Y(V,W){for(var ce=0,pe=V.length;ce<pe;ce++)if(V[ce]===W)return ce;return-1}return U8}var sF=_c,dx=C0(),oF=Object.create($n);oF.inherits=Zt,oF.inherits(_c,dx);function Nfe(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,t!=null&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function _c(e){if(!(this instanceof _c))return new _c(e);dx.call(this,e),this._transformState={afterTransform:Nfe.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&(typeof e.transform=="function"&&(this._transform=e.transform),typeof e.flush=="function"&&(this._flush=e.flush)),this.on("prefinish",Ffe)}function Ffe(){var e=this;typeof this._flush=="function"?this._flush(function(t,r){lF(e,t,r)}):lF(this,null,null)}_c.prototype.push=function(e,t){return this._transformState.needTransform=!1,dx.prototype.push.call(this,e,t)},_c.prototype._transform=function(e,t,r){throw new Error("_transform() is not implemented")},_c.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},_c.prototype._read=function(e){var t=this._transformState;t.writechunk!==null&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},_c.prototype._destroy=function(e,t){var r=this;dx.prototype._destroy.call(this,e,function(n){t(n),r.emit("close")})};function lF(e,t,r){if(t)return e.emit("error",t);if(r!=null&&e.push(r),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}var Pfe=tb,cF=sF,uF=Object.create($n);uF.inherits=Zt,uF.inherits(tb,cF);function tb(e){if(!(this instanceof tb))return new tb(e);cF.call(this,e)}tb.prototype._transform=function(e,t,r){r(null,e)},function(e,t){t=e.exports=aF(),t.Stream=t,t.Readable=t,t.Writable=QN(),t.Duplex=C0(),t.Transform=sF,t.PassThrough=Pfe}(B8,B8.exports);
vendor: 44,689 bytes, line 1981
1981var zfe=B8.exports,rb={exports:{}},q8={exports:{}};q8.exports,function(e){(function(t,r){function n(f,g){if(!f)throw new Error(g||"Assertion failed")}function i(f,g){f.super_=g;var _=function(){};_.prototype=g.prototype,f.prototype=new _,f.prototype.constructor=f}function a(f,g,_){if(a.isBN(f))return f;this.negative=0,this.words=null,this.length=0,this.red=null,f!==null&&((g==="le"||g==="be")&&(_=g,g=10),this._init(f||0,g||10,_||"be"))}typeof t=="object"?t.exports=a:r.BN=a,a.BN=a,a.wordSize=26;var s;try{typeof window<"u"&&typeof window.Buffer<"u"?s=window.Buffer:s=ji.Buffer}catch{}a.isBN=function(f){return f instanceof a?!0:f!==null&&typeof f=="object"&&f.constructor.wordSize===a.wordSize&&Array.isArray(f.words)},a.max=function(f,g){return f.cmp(g)>0?f:g},a.min=function(f,g){return f.cmp(g)<0?f:g},a.prototype._init=function(f,g,_){if(typeof f=="number")return this._initNumber(f,g,_);if(typeof f=="object")return this._initArray(f,g,_);g==="hex"&&(g=16),n(g===(g|0)&&g>=2&&g<=36),f=f.toString().replace(/\s+/g,"");var B=0;f[0]==="-"&&(B++,this.negative=1),B<f.length&&(g===16?this._parseHex(f,B,_):(this._parseBase(f,g,B),_==="le"&&this._initArray(this.toArray(),g,_)))},a.prototype._initNumber=function(f,g,_){f<0&&(this.negative=1,f=-f),f<67108864?(this.words=[f&67108863],this.length=1):f<4503599627370496?(this.words=[f&67108863,f/67108864&67108863],this.length=2):(n(f<9007199254740992),this.words=[f&67108863,f/67108864&67108863,1],this.length=3),_==="le"&&this._initArray(this.toArray(),g,_)},a.prototype._initArray=function(f,g,_){if(n(typeof f.length=="number"),f.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(f.length/3),this.words=new Array(this.length);for(var B=0;B<this.length;B++)this.words[B]=0;var T,S,h=0;if(_==="be")for(B=f.length-1,T=0;B>=0;B-=3)S=f[B]|f[B-1]<<8|f[B-2]<<16,this.words[T]|=S<<h&67108863,this.words[T+1]=S>>>26-h&67108863,h+=24,h>=26&&(h-=26,T++);else if(_==="le")for(B=0,T=0;B<f.length;B+=3)S=f[B]|f[B+1]<<8|f[B+2]<<16,this.words[T]|=S<<h&67108863,this.words[T+1]=S>>>26-h&67108863,h+=24,h>=26&&(h-=26,T++);return this._strip()};function o(f,g){var _=f.charCodeAt(g);if(_>=48&&_<=57)return _-48;if(_>=65&&_<=70)return _-55;if(_>=97&&_<=102)return _-87;n(!1,"Invalid character in "+f)}function c(f,g,_){var B=o(f,_);return _-1>=g&&(B|=o(f,_-1)<<4),B}a.prototype._parseHex=function(f,g,_){this.length=Math.ceil((f.length-g)/6),this.words=new Array(this.length);for(var B=0;B<this.length;B++)this.words[B]=0;var T=0,S=0,h;if(_==="be")for(B=f.length-1;B>=g;B-=2)h=c(f,g,B)<<T,this.words[S]|=h&67108863,T>=18?(T-=18,S+=1,this.words[S]|=h>>>26):T+=8;else{var x=f.length-g;for(B=x%2===0?g+1:g;B<f.length;B+=2)h=c(f,g,B)<<T,this.words[S]|=h&67108863,T>=18?(T-=18,S+=1,this.words[S]|=h>>>26):T+=8}this._strip()};function l(f,g,_,B){for(var T=0,S=0,h=Math.min(f.length,_),x=g;x<h;x++){var v=f.charCodeAt(x)-48;T*=B,v>=49?S=v-49+10:v>=17?S=v-17+10:S=v,n(v>=0&&S<B,"Invalid character"),T+=S}return T}a.prototype._parseBase=function(f,g,_){this.words=[0],this.length=1;for(var B=0,T=1;T<=67108863;T*=g)B++;B--,T=T/g|0;for(var S=f.length-_,h=S%B,x=Math.min(S,S-h)+_,v=0,F=_;F<x;F+=B)v=l(f,F,F+B,g),this.imuln(T),this.words[0]+v<67108864?this.words[0]+=v:this._iaddn(v);if(h!==0){var Q=1;for(v=l(f,F,f.length,g),F=0;F<h;F++)Q*=g;this.imuln(Q),this.words[0]+v<67108864?this.words[0]+=v:this._iaddn(v)}this._strip()},a.prototype.copy=function(f){f.words=new Array(this.length);for(var g=0;g<this.length;g++)f.words[g]=this.words[g];f.length=this.length,f.negative=this.negative,f.red=this.red};function u(f,g){f.words=g.words,f.length=g.length,f.negative=g.negative,f.red=g.red}if(a.prototype._move=function(f){u(f,this)},a.prototype.clone=function(){var f=new a(null);return this.copy(f),f},a.prototype._expand=function(f){for(;this.length<f;)this.words[this.length++]=0;return this},a.prototype._strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol<"u"&&typeof Symbol.for=="function")try{a.prototype[Symbol.for("nodejs.util.inspect.custom")]=d}catch{a.prototype.inspect=d}else a.prototype.inspect=d;function d(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var p=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],w=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],O=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(f,g){f=f||10,g=g|0||1;var _;if(f===16||f==="hex"){_="";for(var B=0,T=0,S=0;S<this.length;S++){var h=this.words[S],x=((h<<B|T)&16777215).toString(16);T=h>>>24-B&16777215,B+=2,B>=26&&(B-=26,S--),T!==0||S!==this.length-1?_=p[6-x.length]+x+_:_=x+_}for(T!==0&&(_=T.toString(16)+_);_.length%g!==0;)_="0"+_;return this.negative!==0&&(_="-"+_),_}if(f===(f|0)&&f>=2&&f<=36){var v=w[f],F=O[f];_="";var Q=this.clone();for(Q.negative=0;!Q.isZero();){var G=Q.modrn(F).toString(f);Q=Q.idivn(F),Q.isZero()?_=G+_:_=p[v-G.length]+G+_}for(this.isZero()&&(_="0"+_);_.length%g!==0;)_="0"+_;return this.negative!==0&&(_="-"+_),_}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var f=this.words[0];return this.length===2?f+=this.words[1]*67108864:this.length===3&&this.words[2]===1?f+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-f:f},a.prototype.toJSON=function(){return this.toString(16,2)},s&&(a.prototype.toBuffer=function(f,g){return this.toArrayLike(s,f,g)}),a.prototype.toArray=function(f,g){return this.toArrayLike(Array,f,g)};var I=function(f,g){return f.allocUnsafe?f.allocUnsafe(g):new f(g)};a.prototype.toArrayLike=function(f,g,_){this._strip();var B=this.byteLength(),T=_||Math.max(1,B);n(B<=T,"byte array longer than desired length"),n(T>0,"Requested array length <= 0");var S=I(f,T),h=g==="le"?"LE":"BE";return this["_toArrayLike"+h](S,B),S},a.prototype._toArrayLikeLE=function(f,g){for(var _=0,B=0,T=0,S=0;T<this.length;T++){var h=this.words[T]<<S|B;f[_++]=h&255,_<f.length&&(f[_++]=h>>8&255),_<f.length&&(f[_++]=h>>16&255),S===6?(_<f.length&&(f[_++]=h>>24&255),B=0,S=0):(B=h>>>24,S+=2)}if(_<f.length)for(f[_++]=B;_<f.length;)f[_++]=0},a.prototype._toArrayLikeBE=function(f,g){for(var _=f.length-1,B=0,T=0,S=0;T<this.length;T++){var h=this.words[T]<<S|B;f[_--]=h&255,_>=0&&(f[_--]=h>>8&255),_>=0&&(f[_--]=h>>16&255),S===6?(_>=0&&(f[_--]=h>>24&255),B=0,S=0):(B=h>>>24,S+=2)}if(_>=0)for(f[_--]=B;_>=0;)f[_--]=0},Math.clz32?a.prototype._countBits=function(f){return 32-Math.clz32(f)}:a.prototype._countBits=function(f){var g=f,_=0;return g>=4096&&(_+=13,g>>>=13),g>=64&&(_+=7,g>>>=7),g>=8&&(_+=4,g>>>=4),g>=2&&(_+=2,g>>>=2),_+g},a.prototype._zeroBits=function(f){if(f===0)return 26;var g=f,_=0;return g&8191||(_+=13,g>>>=13),g&127||(_+=7,g>>>=7),g&15||(_+=4,g>>>=4),g&3||(_+=2,g>>>=2),g&1||_++,_},a.prototype.bitLength=function(){var f=this.words[this.length-1],g=this._countBits(f);return(this.length-1)*26+g};function R(f){for(var g=new Array(f.bitLength()),_=0;_<g.length;_++){var B=_/26|0,T=_%26;g[_]=f.words[B]>>>T&1}return g}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var f=0,g=0;g<this.length;g++){var _=this._zeroBits(this.words[g]);if(f+=_,_!==26)break}return f},a.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},a.prototype.toTwos=function(f){return this.negative!==0?this.abs().inotn(f).iaddn(1):this.clone()},a.prototype.fromTwos=function(f){return this.testn(f-1)?this.notn(f).iaddn(1).ineg():this.clone()},a.prototype.isNeg=function(){return this.negative!==0},a.prototype.neg=function(){return this.clone().ineg()},a.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},a.prototype.iuor=function(f){for(;this.length<f.length;)this.words[this.length++]=0;for(var g=0;g<f.length;g++)this.words[g]=this.words[g]|f.words[g];return this._strip()},a.prototype.ior=function(f){return n((this.negative|f.negative)===0),this.iuor(f)},a.prototype.or=function(f){return this.length>f.length?this.clone().ior(f):f.clone().ior(this)},a.prototype.uor=function(f){return this.length>f.length?this.clone().iuor(f):f.clone().iuor(this)},a.prototype.iuand=function(f){var g;this.length>f.length?g=f:g=this;for(var _=0;_<g.length;_++)this.words[_]=this.words[_]&f.words[_];return this.length=g.length,this._strip()},a.prototype.iand=function(f){return n((this.negative|f.negative)===0),this.iuand(f)},a.prototype.and=function(f){return this.length>f.length?this.clone().iand(f):f.clone().iand(this)},a.prototype.uand=function(f){return this.length>f.length?this.clone().iuand(f):f.clone().iuand(this)},a.prototype.iuxor=function(f){var g,_;this.length>f.length?(g=this,_=f):(g=f,_=this);for(var B=0;B<_.length;B++)this.words[B]=g.words[B]^_.words[B];if(this!==g)for(;B<g.length;B++)this.words[B]=g.words[B];return this.length=g.length,this._strip()},a.prototype.ixor=function(f){return n((this.negative|f.negative)===0),this.iuxor(f)},a.prototype.xor=function(f){return this.length>f.length?this.clone().ixor(f):f.clone().ixor(this)},a.prototype.uxor=function(f){return this.length>f.length?this.clone().iuxor(f):f.clone().iuxor(this)},a.prototype.inotn=function(f){n(typeof f=="number"&&f>=0);var g=Math.ceil(f/26)|0,_=f%26;this._expand(g),_>0&&g--;for(var B=0;B<g;B++)this.words[B]=~this.words[B]&67108863;return _>0&&(this.words[B]=~this.words[B]&67108863>>26-_),this._strip()},a.prototype.notn=function(f){return this.clone().inotn(f)},a.prototype.setn=function(f,g){n(typeof f=="number"&&f>=0);var _=f/26|0,B=f%26;return this._expand(_+1),g?this.words[_]=this.words[_]|1<<B:this.words[_]=this.words[_]&~(1<<B),this._strip()},a.prototype.iadd=function(f){var g;if(this.negative!==0&&f.negative===0)return this.negative=0,g=this.isub(f),this.negative^=1,this._normSign();if(this.negative===0&&f.negative!==0)return f.negative=0,g=this.isub(f),f.negative=1,g._normSign();var _,B;this.length>f.length?(_=this,B=f):(_=f,B=this);for(var T=0,S=0;S<B.length;S++)g=(_.words[S]|0)+(B.words[S]|0)+T,this.words[S]=g&67108863,T=g>>>26;for(;T!==0&&S<_.length;S++)g=(_.words[S]|0)+T,this.words[S]=g&67108863,T=g>>>26;if(this.length=_.length,T!==0)this.words[this.length]=T,this.length++;else if(_!==this)for(;S<_.length;S++)this.words[S]=_.words[S];return this},a.prototype.add=function(f){var g;return f.negative!==0&&this.negative===0?(f.negative=0,g=this.sub(f),f.negative^=1,g):f.negative===0&&this.negative!==0?(this.negative=0,g=f.sub(this),this.negative=1,g):this.length>f.length?this.clone().iadd(f):f.clone().iadd(this)},a.prototype.isub=function(f){if(f.negative!==0){f.negative=0;var g=this.iadd(f);return f.negative=1,g._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(f),this.negative=1,this._normSign();var _=this.cmp(f);if(_===0)return this.negative=0,this.length=1,this.words[0]=0,this;var B,T;_>0?(B=this,T=f):(B=f,T=this);for(var S=0,h=0;h<T.length;h++)g=(B.words[h]|0)-(T.words[h]|0)+S,S=g>>26,this.words[h]=g&67108863;for(;S!==0&&h<B.length;h++)g=(B.words[h]|0)+S,S=g>>26,this.words[h]=g&67108863;if(S===0&&h<B.length&&B!==this)for(;h<B.length;h++)this.words[h]=B.words[h];return this.length=Math.max(this.length,h),B!==this&&(this.negative=1),this._strip()},a.prototype.sub=function(f){return this.clone().isub(f)};function C(f,g,_){_.negative=g.negative^f.negative;var B=f.length+g.length|0;_.length=B,B=B-1|0;var T=f.words[0]|0,S=g.words[0]|0,h=T*S,x=h&67108863,v=h/67108864|0;_.words[0]=x;for(var F=1;F<B;F++){for(var Q=v>>>26,G=v&67108863,J=Math.min(F,g.length-1),Y=Math.max(0,F-f.length+1);Y<=J;Y++){var V=F-Y|0;T=f.words[V]|0,S=g.words[Y]|0,h=T*S+G,Q+=h/67108864|0,G=h&67108863}_.words[F]=G|0,v=Q|0}return v!==0?_.words[F]=v|0:_.length--,_._strip()}var j=function(f,g,_){var B=f.words,T=g.words,S=_.words,h=0,x,v,F,Q=B[0]|0,G=Q&8191,J=Q>>>13,Y=B[1]|0,V=Y&8191,W=Y>>>13,ce=B[2]|0,pe=ce&8191,ee=ce>>>13,se=B[3]|0,ve=se&8191,_e=se>>>13,Ue=B[4]|0,xe=Ue&8191,Te=Ue>>>13,$e=B[5]|0,Ae=$e&8191,De=$e>>>13,Ke=B[6]|0,ut=Ke&8191,Fe=Ke>>>13,ge=B[7]|0,we=ge&8191,ke=ge>>>13,Ne=B[8]|0,z=Ne&8191,H=Ne>>>13,k=B[9]|0,L=k&8191,q=k>>>13,ie=T[0]|0,fe=ie&8191,be=ie>>>13,Ce=T[1]|0,ze=Ce&8191,Ie=Ce>>>13,qe=T[2]|0,it=qe&8191,Ve=qe>>>13,zt=T[3]|0,wt=zt&8191,Xe=zt>>>13,Tt=T[4]|0,jt=Tt&8191,Je=Tt>>>13,Et=T[5]|0,Bt=Et&8191,Qe=Et>>>13,Lt=T[6]|0,Dt=Lt&8191,et=Lt>>>13,Rt=T[7]|0,Mt=Rt&8191,Ye=Rt>>>13,Nt=T[8]|0,Ft=Nt&8191,tt=Nt>>>13,At=T[9]|0,It=At&8191,xt=At>>>13;_.negative=f.negative^g.negative,_.length=19,x=Math.imul(G,fe),v=Math.imul(G,be),v=v+Math.imul(J,fe)|0,F=Math.imul(J,be);var oi=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(oi>>>26)|0,oi&=67108863,x=Math.imul(V,fe),v=Math.imul(V,be),v=v+Math.imul(W,fe)|0,F=Math.imul(W,be),x=x+Math.imul(G,ze)|0,v=v+Math.imul(G,Ie)|0,v=v+Math.imul(J,ze)|0,F=F+Math.imul(J,Ie)|0;var li=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(li>>>26)|0,li&=67108863,x=Math.imul(pe,fe),v=Math.imul(pe,be),v=v+Math.imul(ee,fe)|0,F=Math.imul(ee,be),x=x+Math.imul(V,ze)|0,v=v+Math.imul(V,Ie)|0,v=v+Math.imul(W,ze)|0,F=F+Math.imul(W,Ie)|0,x=x+Math.imul(G,it)|0,v=v+Math.imul(G,Ve)|0,v=v+Math.imul(J,it)|0,F=F+Math.imul(J,Ve)|0;var ci=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(ci>>>26)|0,ci&=67108863,x=Math.imul(ve,fe),v=Math.imul(ve,be),v=v+Math.imul(_e,fe)|0,F=Math.imul(_e,be),x=x+Math.imul(pe,ze)|0,v=v+Math.imul(pe,Ie)|0,v=v+Math.imul(ee,ze)|0,F=F+Math.imul(ee,Ie)|0,x=x+Math.imul(V,it)|0,v=v+Math.imul(V,Ve)|0,v=v+Math.imul(W,it)|0,F=F+Math.imul(W,Ve)|0,x=x+Math.imul(G,wt)|0,v=v+Math.imul(G,Xe)|0,v=v+Math.imul(J,wt)|0,F=F+Math.imul(J,Xe)|0;var Rn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Rn>>>26)|0,Rn&=67108863,x=Math.imul(xe,fe),v=Math.imul(xe,be),v=v+Math.imul(Te,fe)|0,F=Math.imul(Te,be),x=x+Math.imul(ve,ze)|0,v=v+Math.imul(ve,Ie)|0,v=v+Math.imul(_e,ze)|0,F=F+Math.imul(_e,Ie)|0,x=x+Math.imul(pe,it)|0,v=v+Math.imul(pe,Ve)|0,v=v+Math.imul(ee,it)|0,F=F+Math.imul(ee,Ve)|0,x=x+Math.imul(V,wt)|0,v=v+Math.imul(V,Xe)|0,v=v+Math.imul(W,wt)|0,F=F+Math.imul(W,Xe)|0,x=x+Math.imul(G,jt)|0,v=v+Math.imul(G,Je)|0,v=v+Math.imul(J,jt)|0,F=F+Math.imul(J,Je)|0;var Sn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Sn>>>26)|0,Sn&=67108863,x=Math.imul(Ae,fe),v=Math.imul(Ae,be),v=v+Math.imul(De,fe)|0,F=Math.imul(De,be),x=x+Math.imul(xe,ze)|0,v=v+Math.imul(xe,Ie)|0,v=v+Math.imul(Te,ze)|0,F=F+Math.imul(Te,Ie)|0,x=x+Math.imul(ve,it)|0,v=v+Math.imul(ve,Ve)|0,v=v+Math.imul(_e,it)|0,F=F+Math.imul(_e,Ve)|0,x=x+Math.imul(pe,wt)|0,v=v+Math.imul(pe,Xe)|0,v=v+Math.imul(ee,wt)|0,F=F+Math.imul(ee,Xe)|0,x=x+Math.imul(V,jt)|0,v=v+Math.imul(V,Je)|0,v=v+Math.imul(W,jt)|0,F=F+Math.imul(W,Je)|0,x=x+Math.imul(G,Bt)|0,v=v+Math.imul(G,Qe)|0,v=v+Math.imul(J,Bt)|0,F=F+Math.imul(J,Qe)|0;var zr=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(zr>>>26)|0,zr&=67108863,x=Math.imul(ut,fe),v=Math.imul(ut,be),v=v+Math.imul(Fe,fe)|0,F=Math.imul(Fe,be),x=x+Math.imul(Ae,ze)|0,v=v+Math.imul(Ae,Ie)|0,v=v+Math.imul(De,ze)|0,F=F+Math.imul(De,Ie)|0,x=x+Math.imul(xe,it)|0,v=v+Math.imul(xe,Ve)|0,v=v+Math.imul(Te,it)|0,F=F+Math.imul(Te,Ve)|0,x=x+Math.imul(ve,wt)|0,v=v+Math.imul(ve,Xe)|0,v=v+Math.imul(_e,wt)|0,F=F+Math.imul(_e,Xe)|0,x=x+Math.imul(pe,jt)|0,v=v+Math.imul(pe,Je)|0,v=v+Math.imul(ee,jt)|0,F=F+Math.imul(ee,Je)|0,x=x+Math.imul(V,Bt)|0,v=v+Math.imul(V,Qe)|0,v=v+Math.imul(W,Bt)|0,F=F+Math.imul(W,Qe)|0,x=x+Math.imul(G,Dt)|0,v=v+Math.imul(G,et)|0,v=v+Math.imul(J,Dt)|0,F=F+Math.imul(J,et)|0;var mn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(mn>>>26)|0,mn&=67108863,x=Math.imul(we,fe),v=Math.imul(we,be),v=v+Math.imul(ke,fe)|0,F=Math.imul(ke,be),x=x+Math.imul(ut,ze)|0,v=v+Math.imul(ut,Ie)|0,v=v+Math.imul(Fe,ze)|0,F=F+Math.imul(Fe,Ie)|0,x=x+Math.imul(Ae,it)|0,v=v+Math.imul(Ae,Ve)|0,v=v+Math.imul(De,it)|0,F=F+Math.imul(De,Ve)|0,x=x+Math.imul(xe,wt)|0,v=v+Math.imul(xe,Xe)|0,v=v+Math.imul(Te,wt)|0,F=F+Math.imul(Te,Xe)|0,x=x+Math.imul(ve,jt)|0,v=v+Math.imul(ve,Je)|0,v=v+Math.imul(_e,jt)|0,F=F+Math.imul(_e,Je)|0,x=x+Math.imul(pe,Bt)|0,v=v+Math.imul(pe,Qe)|0,v=v+Math.imul(ee,Bt)|0,F=F+Math.imul(ee,Qe)|0,x=x+Math.imul(V,Dt)|0,v=v+Math.imul(V,et)|0,v=v+Math.imul(W,Dt)|0,F=F+Math.imul(W,et)|0,x=x+Math.imul(G,Mt)|0,v=v+Math.imul(G,Ye)|0,v=v+Math.imul(J,Mt)|0,F=F+Math.imul(J,Ye)|0;var Nn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Nn>>>26)|0,Nn&=67108863,x=Math.imul(z,fe),v=Math.imul(z,be),v=v+Math.imul(H,fe)|0,F=Math.imul(H,be),x=x+Math.imul(we,ze)|0,v=v+Math.imul(we,Ie)|0,v=v+Math.imul(ke,ze)|0,F=F+Math.imul(ke,Ie)|0,x=x+Math.imul(ut,it)|0,v=v+Math.imul(ut,Ve)|0,v=v+Math.imul(Fe,it)|0,F=F+Math.imul(Fe,Ve)|0,x=x+Math.imul(Ae,wt)|0,v=v+Math.imul(Ae,Xe)|0,v=v+Math.imul(De,wt)|0,F=F+Math.imul(De,Xe)|0,x=x+Math.imul(xe,jt)|0,v=v+Math.imul(xe,Je)|0,v=v+Math.imul(Te,jt)|0,F=F+Math.imul(Te,Je)|0,x=x+Math.imul(ve,Bt)|0,v=v+Math.imul(ve,Qe)|0,v=v+Math.imul(_e,Bt)|0,F=F+Math.imul(_e,Qe)|0,x=x+Math.imul(pe,Dt)|0,v=v+Math.imul(pe,et)|0,v=v+Math.imul(ee,Dt)|0,F=F+Math.imul(ee,et)|0,x=x+Math.imul(V,Mt)|0,v=v+Math.imul(V,Ye)|0,v=v+Math.imul(W,Mt)|0,F=F+Math.imul(W,Ye)|0,x=x+Math.imul(G,Ft)|0,v=v+Math.imul(G,tt)|0,v=v+Math.imul(J,Ft)|0,F=F+Math.imul(J,tt)|0;var Kn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Kn>>>26)|0,Kn&=67108863,x=Math.imul(L,fe),v=Math.imul(L,be),v=v+Math.imul(q,fe)|0,F=Math.imul(q,be),x=x+Math.imul(z,ze)|0,v=v+Math.imul(z,Ie)|0,v=v+Math.imul(H,ze)|0,F=F+Math.imul(H,Ie)|0,x=x+Math.imul(we,it)|0,v=v+Math.imul(we,Ve)|0,v=v+Math.imul(ke,it)|0,F=F+Math.imul(ke,Ve)|0,x=x+Math.imul(ut,wt)|0,v=v+Math.imul(ut,Xe)|0,v=v+Math.imul(Fe,wt)|0,F=F+Math.imul(Fe,Xe)|0,x=x+Math.imul(Ae,jt)|0,v=v+Math.imul(Ae,Je)|0,v=v+Math.imul(De,jt)|0,F=F+Math.imul(De,Je)|0,x=x+Math.imul(xe,Bt)|0,v=v+Math.imul(xe,Qe)|0,v=v+Math.imul(Te,Bt)|0,F=F+Math.imul(Te,Qe)|0,x=x+Math.imul(ve,Dt)|0,v=v+Math.imul(ve,et)|0,v=v+Math.imul(_e,Dt)|0,F=F+Math.imul(_e,et)|0,x=x+Math.imul(pe,Mt)|0,v=v+Math.imul(pe,Ye)|0,v=v+Math.imul(ee,Mt)|0,F=F+Math.imul(ee,Ye)|0,x=x+Math.imul(V,Ft)|0,v=v+Math.imul(V,tt)|0,v=v+Math.imul(W,Ft)|0,F=F+Math.imul(W,tt)|0,x=x+Math.imul(G,It)|0,v=v+Math.imul(G,xt)|0,v=v+Math.imul(J,It)|0,F=F+Math.imul(J,xt)|0;var sn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(sn>>>26)|0,sn&=67108863,x=Math.imul(L,ze),v=Math.imul(L,Ie),v=v+Math.imul(q,ze)|0,F=Math.imul(q,Ie),x=x+Math.imul(z,it)|0,v=v+Math.imul(z,Ve)|0,v=v+Math.imul(H,it)|0,F=F+Math.imul(H,Ve)|0,x=x+Math.imul(we,wt)|0,v=v+Math.imul(we,Xe)|0,v=v+Math.imul(ke,wt)|0,F=F+Math.imul(ke,Xe)|0,x=x+Math.imul(ut,jt)|0,v=v+Math.imul(ut,Je)|0,v=v+Math.imul(Fe,jt)|0,F=F+Math.imul(Fe,Je)|0,x=x+Math.imul(Ae,Bt)|0,v=v+Math.imul(Ae,Qe)|0,v=v+Math.imul(De,Bt)|0,F=F+Math.imul(De,Qe)|0,x=x+Math.imul(xe,Dt)|0,v=v+Math.imul(xe,et)|0,v=v+Math.imul(Te,Dt)|0,F=F+Math.imul(Te,et)|0,x=x+Math.imul(ve,Mt)|0,v=v+Math.imul(ve,Ye)|0,v=v+Math.imul(_e,Mt)|0,F=F+Math.imul(_e,Ye)|0,x=x+Math.imul(pe,Ft)|0,v=v+Math.imul(pe,tt)|0,v=v+Math.imul(ee,Ft)|0,F=F+Math.imul(ee,tt)|0,x=x+Math.imul(V,It)|0,v=v+Math.imul(V,xt)|0,v=v+Math.imul(W,It)|0,F=F+Math.imul(W,xt)|0;var Fn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Fn>>>26)|0,Fn&=67108863,x=Math.imul(L,it),v=Math.imul(L,Ve),v=v+Math.imul(q,it)|0,F=Math.imul(q,Ve),x=x+Math.imul(z,wt)|0,v=v+Math.imul(z,Xe)|0,v=v+Math.imul(H,wt)|0,F=F+Math.imul(H,Xe)|0,x=x+Math.imul(we,jt)|0,v=v+Math.imul(we,Je)|0,v=v+Math.imul(ke,jt)|0,F=F+Math.imul(ke,Je)|0,x=x+Math.imul(ut,Bt)|0,v=v+Math.imul(ut,Qe)|0,v=v+Math.imul(Fe,Bt)|0,F=F+Math.imul(Fe,Qe)|0,x=x+Math.imul(Ae,Dt)|0,v=v+Math.imul(Ae,et)|0,v=v+Math.imul(De,Dt)|0,F=F+Math.imul(De,et)|0,x=x+Math.imul(xe,Mt)|0,v=v+Math.imul(xe,Ye)|0,v=v+Math.imul(Te,Mt)|0,F=F+Math.imul(Te,Ye)|0,x=x+Math.imul(ve,Ft)|0,v=v+Math.imul(ve,tt)|0,v=v+Math.imul(_e,Ft)|0,F=F+Math.imul(_e,tt)|0,x=x+Math.imul(pe,It)|0,v=v+Math.imul(pe,xt)|0,v=v+Math.imul(ee,It)|0,F=F+Math.imul(ee,xt)|0;var Tn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Tn>>>26)|0,Tn&=67108863,x=Math.imul(L,wt),v=Math.imul(L,Xe),v=v+Math.imul(q,wt)|0,F=Math.imul(q,Xe),x=x+Math.imul(z,jt)|0,v=v+Math.imul(z,Je)|0,v=v+Math.imul(H,jt)|0,F=F+Math.imul(H,Je)|0,x=x+Math.imul(we,Bt)|0,v=v+Math.imul(we,Qe)|0,v=v+Math.imul(ke,Bt)|0,F=F+Math.imul(ke,Qe)|0,x=x+Math.imul(ut,Dt)|0,v=v+Math.imul(ut,et)|0,v=v+Math.imul(Fe,Dt)|0,F=F+Math.imul(Fe,et)|0,x=x+Math.imul(Ae,Mt)|0,v=v+Math.imul(Ae,Ye)|0,v=v+Math.imul(De,Mt)|0,F=F+Math.imul(De,Ye)|0,x=x+Math.imul(xe,Ft)|0,v=v+Math.imul(xe,tt)|0,v=v+Math.imul(Te,Ft)|0,F=F+Math.imul(Te,tt)|0,x=x+Math.imul(ve,It)|0,v=v+Math.imul(ve,xt)|0,v=v+Math.imul(_e,It)|0,F=F+Math.imul(_e,xt)|0;var Pn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Pn>>>26)|0,Pn&=67108863,x=Math.imul(L,jt),v=Math.imul(L,Je),v=v+Math.imul(q,jt)|0,F=Math.imul(q,Je),x=x+Math.imul(z,Bt)|0,v=v+Math.imul(z,Qe)|0,v=v+Math.imul(H,Bt)|0,F=F+Math.imul(H,Qe)|0,x=x+Math.imul(we,Dt)|0,v=v+Math.imul(we,et)|0,v=v+Math.imul(ke,Dt)|0,F=F+Math.imul(ke,et)|0,x=x+Math.imul(ut,Mt)|0,v=v+Math.imul(ut,Ye)|0,v=v+Math.imul(Fe,Mt)|0,F=F+Math.imul(Fe,Ye)|0,x=x+Math.imul(Ae,Ft)|0,v=v+Math.imul(Ae,tt)|0,v=v+Math.imul(De,Ft)|0,F=F+Math.imul(De,tt)|0,x=x+Math.imul(xe,It)|0,v=v+Math.imul(xe,xt)|0,v=v+Math.imul(Te,It)|0,F=F+Math.imul(Te,xt)|0;var Gn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Gn>>>26)|0,Gn&=67108863,x=Math.imul(L,Bt),v=Math.imul(L,Qe),v=v+Math.imul(q,Bt)|0,F=Math.imul(q,Qe),x=x+Math.imul(z,Dt)|0,v=v+Math.imul(z,et)|0,v=v+Math.imul(H,Dt)|0,F=F+Math.imul(H,et)|0,x=x+Math.imul(we,Mt)|0,v=v+Math.imul(we,Ye)|0,v=v+Math.imul(ke,Mt)|0,F=F+Math.imul(ke,Ye)|0,x=x+Math.imul(ut,Ft)|0,v=v+Math.imul(ut,tt)|0,v=v+Math.imul(Fe,Ft)|0,F=F+Math.imul(Fe,tt)|0,x=x+Math.imul(Ae,It)|0,v=v+Math.imul(Ae,xt)|0,v=v+Math.imul(De,It)|0,F=F+Math.imul(De,xt)|0;var Zr=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Zr>>>26)|0,Zr&=67108863,x=Math.imul(L,Dt),v=Math.imul(L,et),v=v+Math.imul(q,Dt)|0,F=Math.imul(q,et),x=x+Math.imul(z,Mt)|0,v=v+Math.imul(z,Ye)|0,v=v+Math.imul(H,Mt)|0,F=F+Math.imul(H,Ye)|0,x=x+Math.imul(we,Ft)|0,v=v+Math.imul(we,tt)|0,v=v+Math.imul(ke,Ft)|0,F=F+Math.imul(ke,tt)|0,x=x+Math.imul(ut,It)|0,v=v+Math.imul(ut,xt)|0,v=v+Math.imul(Fe,It)|0,F=F+Math.imul(Fe,xt)|0;var Yn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Yn>>>26)|0,Yn&=67108863,x=Math.imul(L,Mt),v=Math.imul(L,Ye),v=v+Math.imul(q,Mt)|0,F=Math.imul(q,Ye),x=x+Math.imul(z,Ft)|0,v=v+Math.imul(z,tt)|0,v=v+Math.imul(H,Ft)|0,F=F+Math.imul(H,tt)|0,x=x+Math.imul(we,It)|0,v=v+Math.imul(we,xt)|0,v=v+Math.imul(ke,It)|0,F=F+Math.imul(ke,xt)|0;var zn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(zn>>>26)|0,zn&=67108863,x=Math.imul(L,Ft),v=Math.imul(L,tt),v=v+Math.imul(q,Ft)|0,F=Math.imul(q,tt),x=x+Math.imul(z,It)|0,v=v+Math.imul(z,xt)|0,v=v+Math.imul(H,It)|0,F=F+Math.imul(H,xt)|0;var Ua=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Ua>>>26)|0,Ua&=67108863,x=Math.imul(L,It),v=Math.imul(L,xt),v=v+Math.imul(q,It)|0,F=Math.imul(q,xt);var Do=(h+x|0)+((v&8191)<<13)|0;return h=(F+(v>>>13)|0)+(Do>>>26)|0,Do&=67108863,S[0]=oi,S[1]=li,S[2]=ci,S[3]=Rn,S[4]=Sn,S[5]=zr,S[6]=mn,S[7]=Nn,S[8]=Kn,S[9]=sn,S[10]=Fn,S[11]=Tn,S[12]=Pn,S[13]=Gn,S[14]=Zr,S[15]=Yn,S[16]=zn,S[17]=Ua,S[18]=Do,h!==0&&(S[19]=h,_.length++),_};Math.imul||(j=C);function N(f,g,_){_.negative=g.negative^f.negative,_.length=f.length+g.length;for(var B=0,T=0,S=0;S<_.length-1;S++){var h=T;T=0;for(var x=B&67108863,v=Math.min(S,g.length-1),F=Math.max(0,S-f.length+1);F<=v;F++){var Q=S-F,G=f.words[Q]|0,J=g.words[F]|0,Y=G*J,V=Y&67108863;h=h+(Y/67108864|0)|0,V=V+x|0,x=V&67108863,h=h+(V>>>26)|0,T+=h>>>26,h&=67108863}_.words[S]=x,B=h,h=T}return B!==0?_.words[S]=B:_.length--,_._strip()}function P(f,g,_){return N(f,g,_)}a.prototype.mulTo=function(f,g){var _,B=this.length+f.length;return this.length===10&&f.length===10?_=j(this,f,g):B<63?_=C(this,f,g):B<1024?_=N(this,f,g):_=P(this,f,g),_},a.prototype.mul=function(f){var g=new a(null);return g.words=new Array(this.length+f.length),this.mulTo(f,g)},a.prototype.mulf=function(f){var g=new a(null);return g.words=new Array(this.length+f.length),P(this,f,g)},a.prototype.imul=function(f){return this.clone().mulTo(f,this)},a.prototype.imuln=function(f){var g=f<0;g&&(f=-f),n(typeof f=="number"),n(f<67108864);for(var _=0,B=0;B<this.length;B++){var T=(this.words[B]|0)*f,S=(T&67108863)+(_&67108863);_>>=26,_+=T/67108864|0,_+=S>>>26,this.words[B]=S&67108863}return _!==0&&(this.words[B]=_,this.length++),g?this.ineg():this},a.prototype.muln=function(f){return this.clone().imuln(f)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(f){var g=R(f);if(g.length===0)return new a(1);for(var _=this,B=0;B<g.length&&g[B]===0;B++,_=_.sqr());if(++B<g.length)for(var T=_.sqr();B<g.length;B++,T=T.sqr())g[B]!==0&&(_=_.mul(T));return _},a.prototype.iushln=function(f){n(typeof f=="number"&&f>=0);var g=f%26,_=(f-g)/26,B=67108863>>>26-g<<26-g,T;if(g!==0){var S=0;for(T=0;T<this.length;T++){var h=this.words[T]&B,x=(this.words[T]|0)-h<<g;this.words[T]=x|S,S=h>>>26-g}S&&(this.words[T]=S,this.length++)}if(_!==0){for(T=this.length-1;T>=0;T--)this.words[T+_]=this.words[T];for(T=0;T<_;T++)this.words[T]=0;this.length+=_}return this._strip()},a.prototype.ishln=function(f){return n(this.negative===0),this.iushln(f)},a.prototype.iushrn=function(f,g,_){n(typeof f=="number"&&f>=0);var B;g?B=(g-g%26)/26:B=0;var T=f%26,S=Math.min((f-T)/26,this.length),h=67108863^67108863>>>T<<T,x=_;if(B-=S,B=Math.max(0,B),x){for(var v=0;v<S;v++)x.words[v]=this.words[v];x.length=S}if(S!==0)if(this.length>S)for(this.length-=S,v=0;v<this.length;v++)this.words[v]=this.words[v+S];else this.words[0]=0,this.length=1;var F=0;for(v=this.length-1;v>=0&&(F!==0||v>=B);v--){var Q=this.words[v]|0;this.words[v]=F<<26-T|Q>>>T,F=Q&h}return x&&F!==0&&(x.words[x.length++]=F),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},a.prototype.ishrn=function(f,g,_){return n(this.negative===0),this.iushrn(f,g,_)},a.prototype.shln=function(f){return this.clone().ishln(f)},a.prototype.ushln=function(f){return this.clone().iushln(f)},a.prototype.shrn=function(f){return this.clone().ishrn(f)},a.prototype.ushrn=function(f){return this.clone().iushrn(f)},a.prototype.testn=function(f){n(typeof f=="number"&&f>=0);var g=f%26,_=(f-g)/26,B=1<<g;if(this.length<=_)return!1;var T=this.words[_];return!!(T&B)},a.prototype.imaskn=function(f){n(typeof f=="number"&&f>=0);var g=f%26,_=(f-g)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=_)return this;if(g!==0&&_++,this.length=Math.min(_,this.length),g!==0){var B=67108863^67108863>>>g<<g;this.words[this.length-1]&=B}return this._strip()},a.prototype.maskn=function(f){return this.clone().imaskn(f)},a.prototype.iaddn=function(f){return n(typeof f=="number"),n(f<67108864),f<0?this.isubn(-f):this.negative!==0?this.length===1&&(this.words[0]|0)<=f?(this.words[0]=f-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(f),this.negative=1,this):this._iaddn(f)},a.prototype._iaddn=function(f){this.words[0]+=f;for(var g=0;g<this.length&&this.words[g]>=67108864;g++)this.words[g]-=67108864,g===this.length-1?this.words[g+1]=1:this.words[g+1]++;return this.length=Math.max(this.length,g+1),this},a.prototype.isubn=function(f){if(n(typeof f=="number"),n(f<67108864),f<0)return this.iaddn(-f);if(this.negative!==0)return this.negative=0,this.iaddn(f),this.negative=1,this;if(this.words[0]-=f,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var g=0;g<this.length&&this.words[g]<0;g++)this.words[g]+=67108864,this.words[g+1]-=1;return this._strip()},a.prototype.addn=function(f){return this.clone().iaddn(f)},a.prototype.subn=function(f){return this.clone().isubn(f)},a.prototype.iabs=function(){return this.negative=0,this},a.prototype.abs=function(){return this.clone().iabs()},a.prototype._ishlnsubmul=function(f,g,_){var B=f.length+_,T;this._expand(B);var S,h=0;for(T=0;T<f.length;T++){S=(this.words[T+_]|0)+h;var x=(f.words[T]|0)*g;S-=x&67108863,h=(S>>26)-(x/67108864|0),this.words[T+_]=S&67108863}for(;T<this.length-_;T++)S=(this.words[T+_]|0)+h,h=S>>26,this.words[T+_]=S&67108863;if(h===0)return this._strip();for(n(h===-1),h=0,T=0;T<this.length;T++)S=-(this.words[T]|0)+h,h=S>>26,this.words[T]=S&67108863;return this.negative=1,this._strip()},a.prototype._wordDiv=function(f,g){var _=this.length-f.length,B=this.clone(),T=f,S=T.words[T.length-1]|0,h=this._countBits(S);_=26-h,_!==0&&(T=T.ushln(_),B.iushln(_),S=T.words[T.length-1]|0);var x=B.length-T.length,v;if(g!=="mod"){v=new a(null),v.length=x+1,v.words=new Array(v.length);for(var F=0;F<v.length;F++)v.words[F]=0}var Q=B.clone()._ishlnsubmul(T,1,x);Q.negative===0&&(B=Q,v&&(v.words[x]=1));for(var G=x-1;G>=0;G--){var J=(B.words[T.length+G]|0)*67108864+(B.words[T.length+G-1]|0);for(J=Math.min(J/S|0,67108863),B._ishlnsubmul(T,J,G);B.negative!==0;)J--,B.negative=0,B._ishlnsubmul(T,1,G),B.isZero()||(B.negative^=1);v&&(v.words[G]=J)}return v&&v._strip(),B._strip(),g!=="div"&&_!==0&&B.iushrn(_),{div:v||null,mod:B}},a.prototype.divmod=function(f,g,_){if(n(!f.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var B,T,S;return this.negative!==0&&f.negative===0?(S=this.neg().divmod(f,g),g!=="mod"&&(B=S.div.neg()),g!=="div"&&(T=S.mod.neg(),_&&T.negative!==0&&T.iadd(f)),{div:B,mod:T}):this.negative===0&&f.negative!==0?(S=this.divmod(f.neg(),g),g!=="mod"&&(B=S.div.neg()),{div:B,mod:S.mod}):this.negative&f.negative?(S=this.neg().divmod(f.neg(),g),g!=="div"&&(T=S.mod.neg(),_&&T.negative!==0&&T.isub(f)),{div:S.div,mod:T}):f.length>this.length||this.cmp(f)<0?{div:new a(0),mod:this}:f.length===1?g==="div"?{div:this.divn(f.words[0]),mod:null}:g==="mod"?{div:null,mod:new a(this.modrn(f.words[0]))}:{div:this.divn(f.words[0]),mod:new a(this.modrn(f.words[0]))}:this._wordDiv(f,g)},a.prototype.div=function(f){return this.divmod(f,"div",!1).div},a.prototype.mod=function(f){return this.divmod(f,"mod",!1).mod},a.prototype.umod=function(f){return this.divmod(f,"mod",!0).mod},a.prototype.divRound=function(f){var g=this.divmod(f);if(g.mod.isZero())return g.div;var _=g.div.negative!==0?g.mod.isub(f):g.mod,B=f.ushrn(1),T=f.andln(1),S=_.cmp(B);return S<0||T===1&&S===0?g.div:g.div.negative!==0?g.div.isubn(1):g.div.iaddn(1)},a.prototype.modrn=function(f){var g=f<0;g&&(f=-f),n(f<=67108863);for(var _=67108864%f,B=0,T=this.length-1;T>=0;T--)B=(_*B+(this.words[T]|0))%f;return g?-B:B},a.prototype.modn=function(f){return this.modrn(f)},a.prototype.idivn=function(f){var g=f<0;g&&(f=-f),n(f<=67108863);for(var _=0,B=this.length-1;B>=0;B--){var T=(this.words[B]|0)+_*67108864;this.words[B]=T/f|0,_=T%f}return this._strip(),g?this.ineg():this},a.prototype.divn=function(f){return this.clone().idivn(f)},a.prototype.egcd=function(f){n(f.negative===0),n(!f.isZero());var g=this,_=f.clone();g.negative!==0?g=g.umod(f):g=g.clone();for(var B=new a(1),T=new a(0),S=new a(0),h=new a(1),x=0;g.isEven()&&_.isEven();)g.iushrn(1),_.iushrn(1),++x;for(var v=_.clone(),F=g.clone();!g.isZero();){for(var Q=0,G=1;!(g.words[0]&G)&&Q<26;++Q,G<<=1);if(Q>0)for(g.iushrn(Q);Q-- >0;)(B.isOdd()||T.isOdd())&&(B.iadd(v),T.isub(F)),B.iushrn(1),T.iushrn(1);for(var J=0,Y=1;!(_.words[0]&Y)&&J<26;++J,Y<<=1);if(J>0)for(_.iushrn(J);J-- >0;)(S.isOdd()||h.isOdd())&&(S.iadd(v),h.isub(F)),S.iushrn(1),h.iushrn(1);g.cmp(_)>=0?(g.isub(_),B.isub(S),T.isub(h)):(_.isub(g),S.isub(B),h.isub(T))}return{a:S,b:h,gcd:_.iushln(x)}},a.prototype._invmp=function(f){n(f.negative===0),n(!f.isZero());var g=this,_=f.clone();g.negative!==0?g=g.umod(f):g=g.clone();for(var B=new a(1),T=new a(0),S=_.clone();g.cmpn(1)>0&&_.cmpn(1)>0;){for(var h=0,x=1;!(g.words[0]&x)&&h<26;++h,x<<=1);if(h>0)for(g.iushrn(h);h-- >0;)B.isOdd()&&B.iadd(S),B.iushrn(1);for(var v=0,F=1;!(_.words[0]&F)&&v<26;++v,F<<=1);if(v>0)for(_.iushrn(v);v-- >0;)T.isOdd()&&T.iadd(S),T.iushrn(1);g.cmp(_)>=0?(g.isub(_),B.isub(T)):(_.isub(g),T.isub(B))}var Q;return g.cmpn(1)===0?Q=B:Q=T,Q.cmpn(0)<0&&Q.iadd(f),Q},a.prototype.gcd=function(f){if(this.isZero())return f.abs();if(f.isZero())return this.abs();var g=this.clone(),_=f.clone();g.negative=0,_.negative=0;for(var B=0;g.isEven()&&_.isEven();B++)g.iushrn(1),_.iushrn(1);do{for(;g.isEven();)g.iushrn(1);for(;_.isEven();)_.iushrn(1);var T=g.cmp(_);if(T<0){var S=g;g=_,_=S}else if(T===0||_.cmpn(1)===0)break;g.isub(_)}while(!0);return _.iushln(B)},a.prototype.invm=function(f){return this.egcd(f).a.umod(f)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(f){return this.words[0]&f},a.prototype.bincn=function(f){n(typeof f=="number");var g=f%26,_=(f-g)/26,B=1<<g;if(this.length<=_)return this._expand(_+1),this.words[_]|=B,this;for(var T=B,S=_;T!==0&&S<this.length;S++){var h=this.words[S]|0;h+=T,T=h>>>26,h&=67108863,this.words[S]=h}return T!==0&&(this.words[S]=T,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(f){var g=f<0;if(this.negative!==0&&!g)return-1;if(this.negative===0&&g)return 1;this._strip();var _;if(this.length>1)_=1;else{g&&(f=-f),n(f<=67108863,"Number is too big");var B=this.words[0]|0;_=B===f?0:B<f?-1:1}return this.negative!==0?-_|0:_},a.prototype.cmp=function(f){if(this.negative!==0&&f.negative===0)return-1;if(this.negative===0&&f.negative!==0)return 1;var g=this.ucmp(f);return this.negative!==0?-g|0:g},a.prototype.ucmp=function(f){if(this.length>f.length)return 1;if(this.length<f.length)return-1;for(var g=0,_=this.length-1;_>=0;_--){var B=this.words[_]|0,T=f.words[_]|0;if(B!==T){B<T?g=-1:B>T&&(g=1);break}}return g},a.prototype.gtn=function(f){return this.cmpn(f)===1},a.prototype.gt=function(f){return this.cmp(f)===1},a.prototype.gten=function(f){return this.cmpn(f)>=0},a.prototype.gte=function(f){return this.cmp(f)>=0},a.prototype.ltn=function(f){return this.cmpn(f)===-1},a.prototype.lt=function(f){return this.cmp(f)===-1},a.prototype.lten=function(f){return this.cmpn(f)<=0},a.prototype.lte=function(f){return this.cmp(f)<=0},a.prototype.eqn=function(f){return this.cmpn(f)===0},a.prototype.eq=function(f){return this.cmp(f)===0},a.red=function(f){return new m(f)},a.prototype.toRed=function(f){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),f.convertTo(this)._forceRed(f)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(f){return this.red=f,this},a.prototype.forceRed=function(f){return n(!this.red,"Already a number in reduction context"),this._forceRed(f)},a.prototype.redAdd=function(f){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,f)},a.prototype.redIAdd=function(f){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,f)},a.prototype.redSub=function(f){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,f)},a.prototype.redISub=function(f){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,f)},a.prototype.redShl=function(f){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,f)},a.prototype.redMul=function(f){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,f),this.red.mul(this,f)},a.prototype.redIMul=function(f){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,f),this.red.imul(this,f)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(f){return n(this.red&&!f.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,f)};var Z={k256:null,p224:null,p192:null,p25519:null};function X(f,g){this.name=f,this.p=new a(g,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}X.prototype._tmp=function(){var f=new a(null);return f.words=new Array(Math.ceil(this.n/13)),f},X.prototype.ireduce=function(f){var g=f,_;do this.split(g,this.tmp),g=this.imulK(g),g=g.iadd(this.tmp),_=g.bitLength();while(_>this.n);var B=_<this.n?-1:g.ucmp(this.p);return B===0?(g.words[0]=0,g.length=1):B>0?g.isub(this.p):g.strip!==void 0?g.strip():g._strip(),g},X.prototype.split=function(f,g){f.iushrn(this.n,0,g)},X.prototype.imulK=function(f){return f.imul(this.k)};function re(){X.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(re,X),re.prototype.split=function(f,g){for(var _=4194303,B=Math.min(f.length,9),T=0;T<B;T++)g.words[T]=f.words[T];if(g.length=B,f.length<=9){f.words[0]=0,f.length=1;return}var S=f.words[9];for(g.words[g.length++]=S&_,T=10;T<f.length;T++){var h=f.words[T]|0;f.words[T-10]=(h&_)<<4|S>>>22,S=h}S>>>=22,f.words[T-10]=S,S===0&&f.length>10?f.length-=10:f.length-=9},re.prototype.imulK=function(f){f.words[f.length]=0,f.words[f.length+1]=0,f.length+=2;for(var g=0,_=0;_<f.length;_++){var B=f.words[_]|0;g+=B*977,f.words[_]=g&67108863,g=B*64+(g/67108864|0)}return f.words[f.length-1]===0&&(f.length--,f.words[f.length-1]===0&&f.length--),f};function ne(){X.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}i(ne,X);function ae(){X.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}i(ae,X);function ue(){X.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}i(ue,X),ue.prototype.imulK=function(f){for(var g=0,_=0;_<f.length;_++){var B=(f.words[_]|0)*19+g,T=B&67108863;B>>>=26,f.words[_]=T,g=B}return g!==0&&(f.words[f.length++]=g),f},a._prime=function(f){if(Z[f])return Z[f];var g;if(f==="k256")g=new re;else if(f==="p224")g=new ne;else if(f==="p192")g=new ae;else if(f==="p25519")g=new ue;else throw new Error("Unknown prime "+f);return Z[f]=g,g};function m(f){if(typeof f=="string"){var g=a._prime(f);this.m=g.p,this.prime=g}else n(f.gtn(1),"modulus must be greater than 1"),this.m=f,this.prime=null}m.prototype._verify1=function(f){n(f.negative===0,"red works only with positives"),n(f.red,"red works only with red numbers")},m.prototype._verify2=function(f,g){n((f.negative|g.negative)===0,"red works only with positives"),n(f.red&&f.red===g.red,"red works only with red numbers")},m.prototype.imod=function(f){return this.prime?this.prime.ireduce(f)._forceRed(this):(u(f,f.umod(this.m)._forceRed(this)),f)},m.prototype.neg=function(f){return f.isZero()?f.clone():this.m.sub(f)._forceRed(this)},m.prototype.add=function(f,g){this._verify2(f,g);var _=f.add(g);return _.cmp(this.m)>=0&&_.isub(this.m),_._forceRed(this)},m.prototype.iadd=function(f,g){this._verify2(f,g);var _=f.iadd(g);return _.cmp(this.m)>=0&&_.isub(this.m),_},m.prototype.sub=function(f,g){this._verify2(f,g);var _=f.sub(g);return _.cmpn(0)<0&&_.iadd(this.m),_._forceRed(this)},m.prototype.isub=function(f,g){this._verify2(f,g);var _=f.isub(g);return _.cmpn(0)<0&&_.iadd(this.m),_},m.prototype.shl=function(f,g){return this._verify1(f),this.imod(f.ushln(g))},m.prototype.imul=function(f,g){return this._verify2(f,g),this.imod(f.imul(g))},m.prototype.mul=function(f,g){return this._verify2(f,g),this.imod(f.mul(g))},m.prototype.isqr=function(f){return this.imul(f,f.clone())},m.prototype.sqr=function(f){return this.mul(f,f)},m.prototype.sqrt=function(f){if(f.isZero())return f.clone();var g=this.m.andln(3);if(n(g%2===1),g===3){var _=this.m.add(new a(1)).iushrn(2);return this.pow(f,_)}for(var B=this.m.subn(1),T=0;!B.isZero()&&B.andln(1)===0;)T++,B.iushrn(1);n(!B.isZero());var S=new a(1).toRed(this),h=S.redNeg(),x=this.m.subn(1).iushrn(1),v=this.m.bitLength();for(v=new a(2*v*v).toRed(this);this.pow(v,x).cmp(h)!==0;)v.redIAdd(h);for(var F=this.pow(v,B),Q=this.pow(f,B.addn(1).iushrn(1)),G=this.pow(f,B),J=T;G.cmp(S)!==0;){for(var Y=G,V=0;Y.cmp(S)!==0;V++)Y=Y.redSqr();n(V<J);var W=this.pow(F,new a(1).iushln(J-V-1));Q=Q.redMul(W),F=W.redSqr(),G=G.redMul(F),J=V}return Q},m.prototype.invm=function(f){var g=f._invmp(this.m);return g.negative!==0?(g.negative=0,this.imod(g).redNeg()):this.imod(g)},m.prototype.pow=function(f,g){if(g.isZero())return new a(1).toRed(this);if(g.cmpn(1)===0)return f.clone();var _=4,B=new Array(1<<_);B[0]=new a(1).toRed(this),B[1]=f;for(var T=2;T<B.length;T++)B[T]=this.mul(B[T-1],f);var S=B[0],h=0,x=0,v=g.bitLength()%26;for(v===0&&(v=26),T=g.length-1;T>=0;T--){for(var F=g.words[T],Q=v-1;Q>=0;Q--){var G=F>>Q&1;if(S!==B[0]&&(S=this.sqr(S)),G===0&&h===0){x=0;continue}h<<=1,h|=G,x++,!(x!==_&&(T!==0||Q!==0))&&(S=this.mul(S,B[h]),x=0,h=0)}v=26}return S},m.prototype.convertTo=function(f){var g=f.umod(this.m);return g===f?g.clone():g},m.prototype.convertFrom=function(f){var g=f.clone();return g.red=null,g},a.mont=function(f){return new A(f)};function A(f){m.call(this,f),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(A,m),A.prototype.convertTo=function(f){return this.imod(f.ushln(this.shift))},A.prototype.convertFrom=function(f){var g=this.imod(f.mul(this.rinv));return g.red=null,g},A.prototype.imul=function(f,g){if(f.isZero()||g.isZero())return f.words[0]=0,f.length=1,f;var _=f.imul(g),B=_.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),T=_.isub(B).iushrn(this.shift),S=T;return T.cmp(this.m)>=0?S=T.isub(this.m):T.cmpn(0)<0&&(S=T.iadd(this.m)),S._forceRed(this)},A.prototype.mul=function(f,g){if(f.isZero()||g.isZero())return new a(0)._forceRed(this);var _=f.mul(g),B=_.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),T=_.isub(B).iushrn(this.shift),S=T;return T.cmp(this.m)>=0?S=T.isub(this.m):T.cmpn(0)<0&&(S=T.iadd(this.m)),S._forceRed(this)},A.prototype.invm=function(f){var g=this.imod(f._invmp(this.m).mul(this.r2));return g._forceRed(this)}})(e,dt)}(q8);var Lfe=q8.exports,T0=Lfe,Dfe=v0,Ufe=Qt.Buffer;function fF(e){var t=e.modulus.byteLength(),r;do r=new T0(Dfe(t));while(r.cmp(e.modulus)>=0||!r.umod(e.prime1)||!r.umod(e.prime2));return r}function qfe(e){var t=fF(e),r=t.toRed(T0.mont(e.modulus)).redPow(new T0(e.publicExponent)).fromRed();return{blinder:r,unblinder:t.invm(e.modulus)}}function hF(e,t){var r=qfe(t),n=t.modulus.byteLength(),i=new T0(e).mul(r.blinder).umod(t.modulus),a=i.toRed(T0.mont(t.prime1)),s=i.toRed(T0.mont(t.prime2)),o=t.coefficient,c=t.prime1,l=t.prime2,u=a.redPow(t.exponent1).fromRed(),d=s.redPow(t.exponent2).fromRed(),p=u.isub(d).imul(o).umod(c).imul(l);return d.iadd(p).imul(r.unblinder).umod(t.modulus).toArrayLike(Ufe,"be",n)}hF.getr=fF;var V8=hF,dF={};const Vfe="elliptic",Zfe="6.6.0",$fe="EC cryptography",Hfe="lib/elliptic.js",Wfe=["lib"],Kfe={lint:"eslint lib test","lint:fix":"npm run lint -- --fix",unit:"istanbul test _mocha --reporter=spec test/index.js",test:"npm run lint && npm run unit",version:"grunt dist && git add dist/"},Gfe={type:"git",url:"[email protected]:indutny/elliptic"},Yfe=["EC","Elliptic","curve","Cryptography"],Xfe="Fedor Indutny <[email protected]>",Jfe="MIT",Qfe={url:"https://github.com/indutny/elliptic/issues"},ehe="https://github.com/indutny/elliptic",the={brfs:"^2.0.2",coveralls:"^3.1.0",eslint:"^7.6.0",grunt:"^1.2.1","grunt-browserify":"^5.3.0","grunt-cli":"^1.3.2","grunt-contrib-connect":"^3.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^5.0.0","grunt-mocha-istanbul":"^5.0.2","grunt-saucelabs":"^9.0.1",istanbul:"^0.4.5",mocha:"^8.0.1"},rhe={"bn.js":"^4.11.9",brorand:"^1.1.0","hash.js":"^1.0.0","hmac-drbg":"^1.0.1",inherits:"^2.0.4","minimalistic-assert":"^1.0.1","minimalistic-crypto-utils":"^1.0.1"},nhe={name:Vfe,version:Zfe,description:$fe,main:Hfe,files:Wfe,scripts:Kfe,repository:Gfe,keywords:Yfe,author:Xfe,license:Jfe,bugs:Qfe,homepage:ehe,devDependencies:the,depen
vendor: 10,396 bytes, line 1981
1981dencies:rhe};var ns={},Z8={exports:{}};Z8.exports,function(e){(function(t,r){function n(m,A){if(!m)throw new Error(A||"Assertion failed")}function i(m,A){m.super_=A;var f=function(){};f.prototype=A.prototype,m.prototype=new f,m.prototype.constructor=m}function a(m,A,f){if(a.isBN(m))return m;this.negative=0,this.words=null,this.length=0,this.red=null,m!==null&&((A==="le"||A==="be")&&(f=A,A=10),this._init(m||0,A||10,f||"be"))}typeof t=="object"?t.exports=a:r.BN=a,a.BN=a,a.wordSize=26;var s;try{typeof window<"u"&&typeof window.Buffer<"u"?s=window.Buffer:s=ji.Buffer}catch{}a.isBN=function(m){return m instanceof a?!0:m!==null&&typeof m=="object"&&m.constructor.wordSize===a.wordSize&&Array.isArray(m.words)},a.max=function(m,A){return m.cmp(A)>0?m:A},a.min=function(m,A){return m.cmp(A)<0?m:A},a.prototype._init=function(m,A,f){if(typeof m=="number")return this._initNumber(m,A,f);if(typeof m=="object")return this._initArray(m,A,f);A==="hex"&&(A=16),n(A===(A|0)&&A>=2&&A<=36),m=m.toString().replace(/\s+/g,"");var g=0;m[0]==="-"&&(g++,this.negative=1),g<m.length&&(A===16?this._parseHex(m,g,f):(this._parseBase(m,A,g),f==="le"&&this._initArray(this.toArray(),A,f)))},a.prototype._initNumber=function(m,A,f){m<0&&(this.negative=1,m=-m),m<67108864?(this.words=[m&67108863],this.length=1):m<4503599627370496?(this.words=[m&67108863,m/67108864&67108863],this.length=2):(n(m<9007199254740992),this.words=[m&67108863,m/67108864&67108863,1],this.length=3),f==="le"&&this._initArray(this.toArray(),A,f)},a.prototype._initArray=function(m,A,f){if(n(typeof m.length=="number"),m.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(m.length/3),this.words=new Array(this.length);for(var g=0;g<this.length;g++)this.words[g]=0;var _,B,T=0;if(f==="be")for(g=m.length-1,_=0;g>=0;g-=3)B=m[g]|m[g-1]<<8|m[g-2]<<16,this.words[_]|=B<<T&67108863,this.words[_+1]=B>>>26-T&67108863,T+=24,T>=26&&(T-=26,_++);else if(f==="le")for(g=0,_=0;g<m.length;g+=3)B=m[g]|m[g+1]<<8|m[g+2]<<16,this.words[_]|=B<<T&67108863,this.words[_+1]=B>>>26-T&67108863,T+=24,T>=26&&(T-=26,_++);return this.strip()};function o(m,A){var f=m.charCodeAt(A);return f>=65&&f<=70?f-55:f>=97&&f<=102?f-87:f-48&15}function c(m,A,f){var g=o(m,f);return f-1>=A&&(g|=o(m,f-1)<<4),g}a.prototype._parseHex=function(m,A,f){this.length=Math.ceil((m.length-A)/6),this.words=new Array(this.length);for(var g=0;g<this.length;g++)this.words[g]=0;var _=0,B=0,T;if(f==="be")for(g=m.length-1;g>=A;g-=2)T=c(m,A,g)<<_,this.words[B]|=T&67108863,_>=18?(_-=18,B+=1,this.words[B]|=T>>>26):_+=8;else{var S=m.length-A;for(g=S%2===0?A+1:A;g<m.length;g+=2)T=c(m,A,g)<<_,this.words[B]|=T&67108863,_>=18?(_-=18,B+=1,this.words[B]|=T>>>26):_+=8}this.strip()};function l(m,A,f,g){for(var _=0,B=Math.min(m.length,f),T=A;T<B;T++){var S=m.charCodeAt(T)-48;_*=g,S>=49?_+=S-49+10:S>=17?_+=S-17+10:_+=S}return _}a.prototype._parseBase=function(m,A,f){this.words=[0],this.length=1;for(var g=0,_=1;_<=67108863;_*=A)g++;g--,_=_/A|0;for(var B=m.length-f,T=B%g,S=Math.min(B,B-T)+f,h=0,x=f;x<S;x+=g)h=l(m,x,x+g,A),this.imuln(_),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h);if(T!==0){var v=1;for(h=l(m,x,m.length,A),x=0;x<T;x++)v*=A;this.imuln(v),this.words[0]+h<67108864?this.words[0]+=h:this._iaddn(h)}this.strip()},a.prototype.copy=function(m){m.words=new Array(this.length);for(var A=0;A<this.length;A++)m.words[A]=this.words[A];m.length=this.length,m.negative=this.negative,m.red=this.red},a.prototype.clone=function(){var m=new a(null);return this.copy(m),m},a.prototype._expand=function(m){for(;this.length<m;)this.words[this.length++]=0;return this},a.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},a.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var u=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],d=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],p=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(m,A){m=m||10,A=A|0||1;var f;if(m===16||m==="hex"){f="";for(var g=0,_=0,B=0;B<this.length;B++){var T=this.words[B],S=((T<<g|_)&16777215).toString(16);_=T>>>24-g&16777215,g+=2,g>=26&&(g-=26,B--),_!==0||B!==this.length-1?f=u[6-S.length]+S+f:f=S+f}for(_!==0&&(f=_.toString(16)+f);f.length%A!==0;)f="0"+f;return this.negative!==0&&(f="-"+f),f}if(m===(m|0)&&m>=2&&m<=36){var h=d[m],x=p[m];f="";var v=this.clone();for(v.negative=0;!v.isZero();){var F=v.modn(x).toString(m);v=v.idivn(x),v.isZero()?f=F+f:f=u[h-F.length]+F+f}for(this.isZero()&&(f="0"+f);f.length%A!==0;)f="0"+f;return this.negative!==0&&(f="-"+f),f}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var m=this.words[0];return this.length===2?m+=this.words[1]*67108864:this.length===3&&this.words[2]===1?m+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-m:m},a.prototype.toJSON=function(){return this.toString(16)},a.prototype.toBuffer=function(m,A){return n(typeof s<"u"),this.toArrayLike(s,m,A)},a.prototype.toArray=function(m,A){return this.toArrayLike(Array,m,A)},a.prototype.toArrayLike=function(m,A,f){var g=this.byteLength(),_=f||Math.max(1,g);n(g<=_,"byte array longer than desired length"),n(_>0,"Requested array length <= 0"),this.strip();var B=A==="le",T=new m(_),S,h,x=this.clone();if(B){for(h=0;!x.isZero();h++)S=x.andln(255),x.iushrn(8),T[h]=S;for(;h<_;h++)T[h]=0}else{for(h=0;h<_-g;h++)T[h]=0;for(h=0;!x.isZero();h++)S=x.andln(255),x.iushrn(8),T[_-h-1]=S}return T},Math.clz32?a.prototype._countBits=function(m){return 32-Math.clz32(m)}:a.prototype._countBits=function(m){var A=m,f=0;return A>=4096&&(f+=13,A>>>=13),A>=64&&(f+=7,A>>>=7),A>=8&&(f+=4,A>>>=4),A>=2&&(f+=2,A>>>=2),f+A},a.prototype._zeroBits=function(m){if(m===0)return 26;var A=m,f=0;return A&8191||(f+=13,A>>>=13),A&127||(f+=7,A>>>=7),A&15||(f+=4,A>>>=4),A&3||(f+=2,A>>>=2),A&1||f++,f},a.prototype.bitLength=function(){var m=this.words[this.length-1],A=this._countBits(m);return(this.length-1)*26+A};function w(m){for(var A=new Array(m.bitLength()),f=0;f<A.length;f++){var g=f/26|0,_=f%26;A[f]=(m.words[g]&1<<_)>>>_}return A}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var m=0,A=0;A<this.length;A++){var f=this._zeroBits(this.words[A]);if(m+=f,f!==26)break}return m},a.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},a.prototype.toTwos=function(m){return this.negative!==0?this.abs().inotn(m).iaddn(1):this.clone()},a.prototype.fromTwos=function(m){return this.testn(m-1)?this.notn(m).iaddn(1).ineg():this.clone()},a.prototype.isNeg=function(){return this.negative!==0},a.prototype.neg=function(){return this.clone().ineg()},a.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},a.prototype.iuor=function(m){for(;this.length<m.length;)this.words[this.length++]=0;for(var A=0;A<m.length;A++)this.words[A]=this.words[A]|m.words[A];return this.strip()},a.prototype.ior=function(m){return n((this.negative|m.negative)===0),this.iuor(m)},a.prototype.or=function(m){return this.length>m.length?this.clone().ior(m):m.clone().ior(this)},a.prototype.uor=function(m){return this.length>m.length?this.clone().iuor(m):m.clone().iuor(this)},a.prototype.iuand=function(m){var A;this.length>m.length?A=m:A=this;for(var f=0;f<A.length;f++)this.words[f]=this.words[f]&m.words[f];return this.length=A.length,this.strip()},a.prototype.iand=function(m){return n((this.negative|m.negative)===0),this.iuand(m)},a.prototype.and=function(m){return this.length>m.length?this.clone().iand(m):m.clone().iand(this)},a.prototype.uand=function(m){return this.length>m.length?this.clone().iuand(m):m.clone().iuand(this)},a.prototype.iuxor=function(m){var A,f;this.length>m.length?(A=this,f=m):(A=m,f=this);for(var g=0;g<f.length;g++)this.words[g]=A.words[g]^f.words[g];if(this!==A)for(;g<A.length;g++)this.words[g]=A.words[g];return this.length=A.length,this.strip()},a.prototype.ixor=function(m){return n((this.negative|m.negative)===0),this.iuxor(m)},a.prototype.xor=function(m){return this.length>m.length?this.clone().ixor(m):m.clone().ixor(this)},a.prototype.uxor=function(m){return this.length>m.length?this.clone().iuxor(m):m.clone().iuxor(this)},a.prototype.inotn=function(m){n(typeof m=="number"&&m>=0);var A=Math.ceil(m/26)|0,f=m%26;this._expand(A),f>0&&A--;for(var g=0;g<A;g++)this.words[g]=~this.words[g]&67108863;return f>0&&(this.words[g]=~this.words[g]&67108863>>26-f),this.strip()},a.prototype.notn=function(m){return this.clone().inotn(m)},a.prototype.setn=function(m,A){n(typeof m=="number"&&m>=0);var f=m/26|0,g=m%26;return this._expand(f+1),A?this.words[f]=this.words[f]|1<<g:this.words[f]=this.words[f]&~(1<<g),this.strip()},a.prototype.iadd=function(m){var A;if(this.negative!==0&&m.negative===0)return this.negative=0,A=this.isub(m),this.negative^=1,this._normSign();if(this.negative===0&&m.negative!==0)return m.negative=0,A=this.isub(m),m.negative=1,A._normSign();var f,g;this.length>m.length?(f=this,g=m):(f=m,g=this);for(var _=0,B=0;B<g.length;B++)A=(f.words[B]|0)+(g.words[B]|0)+_,this.words[B]=A&67108863,_=A>>>26;for(;_!==0&&B<f.length;B++)A=(f.words[B]|0)+_,this.words[B]=A&67108863,_=A>>>26;if(this.length=f.length,_!==0)this.words[this.length]=_,this.length++;else if(f!==this)for(;B<f.length;B++)this.words[B]=f.words[B];return this},a.prototype.add=function(m){var A;return m.negative!==0&&this.negative===0?(m.negative=0,A=this.sub(m),m.negative^=1,A):m.negative===0&&this.negative!==0?(this.negative=0,A=m.sub(this),this.negative=1,A):this.length>m.length?this.clone().iadd(m):m.clone().iadd(this)},a.prototype.isub=function(m){if(m.negative!==0){m.negative=0;
vendor: 8,256 bytes, line 1981
1981var A=this.iadd(m);return m.negative=1,A._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(m),this.negative=1,this._normSign();var f=this.cmp(m);if(f===0)return this.negative=0,this.length=1,this.words[0]=0,this;var g,_;f>0?(g=this,_=m):(g=m,_=this);for(var B=0,T=0;T<_.length;T++)A=(g.words[T]|0)-(_.words[T]|0)+B,B=A>>26,this.words[T]=A&67108863;for(;B!==0&&T<g.length;T++)A=(g.words[T]|0)+B,B=A>>26,this.words[T]=A&67108863;if(B===0&&T<g.length&&g!==this)for(;T<g.length;T++)this.words[T]=g.words[T];return this.length=Math.max(this.length,T),g!==this&&(this.negative=1),this.strip()},a.prototype.sub=function(m){return this.clone().isub(m)};function O(m,A,f){f.negative=A.negative^m.negative;var g=m.length+A.length|0;f.length=g,g=g-1|0;var _=m.words[0]|0,B=A.words[0]|0,T=_*B,S=T&67108863,h=T/67108864|0;f.words[0]=S;for(var x=1;x<g;x++){for(var v=h>>>26,F=h&67108863,Q=Math.min(x,A.length-1),G=Math.max(0,x-m.length+1);G<=Q;G++){var J=x-G|0;_=m.words[J]|0,B=A.words[G]|0,T=_*B+F,v+=T/67108864|0,F=T&67108863}f.words[x]=F|0,h=v|0}return h!==0?f.words[x]=h|0:f.length--,f.strip()}var I=function(m,A,f){var g=m.words,_=A.words,B=f.words,T=0,S,h,x,v=g[0]|0,F=v&8191,Q=v>>>13,G=g[1]|0,J=G&8191,Y=G>>>13,V=g[2]|0,W=V&8191,ce=V>>>13,pe=g[3]|0,ee=pe&8191,se=pe>>>13,ve=g[4]|0,_e=ve&8191,Ue=ve>>>13,xe=g[5]|0,Te=xe&8191,$e=xe>>>13,Ae=g[6]|0,De=Ae&8191,Ke=Ae>>>13,ut=g[7]|0,Fe=ut&8191,ge=ut>>>13,we=g[8]|0,ke=we&8191,Ne=we>>>13,z=g[9]|0,H=z&8191,k=z>>>13,L=_[0]|0,q=L&8191,ie=L>>>13,fe=_[1]|0,be=fe&8191,Ce=fe>>>13,ze=_[2]|0,Ie=ze&8191,qe=ze>>>13,it=_[3]|0,Ve=it&8191,zt=it>>>13,wt=_[4]|0,Xe=wt&8191,Tt=wt>>>13,jt=_[5]|0,Je=jt&8191,Et=jt>>>13,Bt=_[6]|0,Qe=Bt&8191,Lt=Bt>>>13,Dt=_[7]|0,et=Dt&8191,Rt=Dt>>>13,Mt=_[8]|0,Ye=Mt&8191,Nt=Mt>>>13,Ft=_[9]|0,tt=Ft&8191,At=Ft>>>13;f.negative=m.negative^A.negative,f.length=19,S=Math.imul(F,q),h=Math.imul(F,ie),h=h+Math.imul(Q,q)|0,x=Math.imul(Q,ie);var It=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(It>>>26)|0,It&=67108863,S=Math.imul(J,q),h=Math.imul(J,ie),h=h+Math.imul(Y,q)|0,x=Math.imul(Y,ie),S=S+Math.imul(F,be)|0,h=h+Math.imul(F,Ce)|0,h=h+Math.imul(Q,be)|0,x=x+Math.imul(Q,Ce)|0;var xt=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(xt>>>26)|0,xt&=67108863,S=Math.imul(W,q),h=Math.imul(W,ie),h=h+Math.imul(ce,q)|0,x=Math.imul(ce,ie),S=S+Math.imul(J,be)|0,h=h+Math.imul(J,Ce)|0,h=h+Math.imul(Y,be)|0,x=x+Math.imul(Y,Ce)|0,S=S+Math.imul(F,Ie)|0,h=h+Math.imul(F,qe)|0,h=h+Math.imul(Q,Ie)|0,x=x+Math.imul(Q,qe)|0;var oi=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(oi>>>26)|0,oi&=67108863,S=Math.imul(ee,q),h=Math.imul(ee,ie),h=h+Math.imul(se,q)|0,x=Math.imul(se,ie),S=S+Math.imul(W,be)|0,h=h+Math.imul(W,Ce)|0,h=h+Math.imul(ce,be)|0,x=x+Math.imul(ce,Ce)|0,S=S+Math.imul(J,Ie)|0,h=h+Math.imul(J,qe)|0,h=h+Math.imul(Y,Ie)|0,x=x+Math.imul(Y,qe)|0,S=S+Math.imul(F,Ve)|0,h=h+Math.imul(F,zt)|0,h=h+Math.imul(Q,Ve)|0,x=x+Math.imul(Q,zt)|0;var li=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(li>>>26)|0,li&=67108863,S=Math.imul(_e,q),h=Math.imul(_e,ie),h=h+Math.imul(Ue,q)|0,x=Math.imul(Ue,ie),S=S+Math.imul(ee,be)|0,h=h+Math.imul(ee,Ce)|0,h=h+Math.imul(se,be)|0,x=x+Math.imul(se,Ce)|0,S=S+Math.imul(W,Ie)|0,h=h+Math.imul(W,qe)|0,h=h+Math.imul(ce,Ie)|0,x=x+Math.imul(ce,qe)|0,S=S+Math.imul(J,Ve)|0,h=h+Math.imul(J,zt)|0,h=h+Math.imul(Y,Ve)|0,x=x+Math.imul(Y,zt)|0,S=S+Math.imul(F,Xe)|0,h=h+Math.imul(F,Tt)|0,h=h+Math.imul(Q,Xe)|0,x=x+Math.imul(Q,Tt)|0;var ci=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(ci>>>26)|0,ci&=67108863,S=Math.imul(Te,q),h=Math.imul(Te,ie),h=h+Math.imul($e,q)|0,x=Math.imul($e,ie),S=S+Math.imul(_e,be)|0,h=h+Math.imul(_e,Ce)|0,h=h+Math.imul(Ue,be)|0,x=x+Math.imul(Ue,Ce)|0,S=S+Math.imul(ee,Ie)|0,h=h+Math.imul(ee,qe)|0,h=h+Math.imul(se,Ie)|0,x=x+Math.imul(se,qe)|0,S=S+Math.imul(W,Ve)|0,h=h+Math.imul(W,zt)|0,h=h+Math.imul(ce,Ve)|0,x=x+Math.imul(ce,zt)|0,S=S+Math.imul(J,Xe)|0,h=h+Math.imul(J,Tt)|0,h=h+Math.imul(Y,Xe)|0,x=x+Math.imul(Y,Tt)|0,S=S+Math.imul(F,Je)|0,h=h+Math.imul(F,Et)|0,h=h+Math.imul(Q,Je)|0,x=x+Math.imul(Q,Et)|0;var Rn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Rn>>>26)|0,Rn&=67108863,S=Math.imul(De,q),h=Math.imul(De,ie),h=h+Math.imul(Ke,q)|0,x=Math.imul(Ke,ie),S=S+Math.imul(Te,be)|0,h=h+Math.imul(Te,Ce)|0,h=h+Math.imul($e,be)|0,x=x+Math.imul($e,Ce)|0,S=S+Math.imul(_e,Ie)|0,h=h+Math.imul(_e,qe)|0,h=h+Math.imul(Ue,Ie)|0,x=x+Math.imul(Ue,qe)|0,S=S+Math.imul(ee,Ve)|0,h=h+Math.imul(ee,zt)|0,h=h+Math.imul(se,Ve)|0,x=x+Math.imul(se,zt)|0,S=S+Math.imul(W,Xe)|0,h=h+Math.imul(W,Tt)|0,h=h+Math.imul(ce,Xe)|0,x=x+Math.imul(ce,Tt)|0,S=S+Math.imul(J,Je)|0,h=h+Math.imul(J,Et)|0,h=h+Math.imul(Y,Je)|0,x=x+Math.imul(Y,Et)|0,S=S+Math.imul(F,Qe)|0,h=h+Math.imul(F,Lt)|0,h=h+Math.imul(Q,Qe)|0,x=x+Math.imul(Q,Lt)|0;var Sn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Sn>>>26)|0,Sn&=67108863,S=Math.imul(Fe,q),h=Math.imul(Fe,ie),h=h+Math.imul(ge,q)|0,x=Math.imul(ge,ie),S=S+Math.imul(De,be)|0,h=h+Math.imul(De,Ce)|0,h=h+Math.imul(Ke,be)|0,x=x+Math.imul(Ke,Ce)|0,S=S+Math.imul(Te,Ie)|0,h=h+Math.imul(Te,qe)|0,h=h+Math.imul($e,Ie)|0,x=x+Math.imul($e,qe)|0,S=S+Math.imul(_e,Ve)|0,h=h+Math.imul(_e,zt)|0,h=h+Math.imul(Ue,Ve)|0,x=x+Math.imul(Ue,zt)|0,S=S+Math.imul(ee,Xe)|0,h=h+Math.imul(ee,Tt)|0,h=h+Math.imul(se,Xe)|0,x=x+Math.imul(se,Tt)|0,S=S+Math.imul(W,Je)|0,h=h+Math.imul(W,Et)|0,h=h+Math.imul(ce,Je)|0,x=x+Math.imul(ce,Et)|0,S=S+Math.imul(J,Qe)|0,h=h+Math.imul(J,Lt)|0,h=h+Math.imul(Y,Qe)|0,x=x+Math.imul(Y,Lt)|0,S=S+Math.imul(F,et)|0,h=h+Math.imul(F,Rt)|0,h=h+Math.imul(Q,et)|0,x=x+Math.imul(Q,Rt)|0;var zr=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(zr>>>26)|0,zr&=67108863,S=Math.imul(ke,q),h=Math.imul(ke,ie),h=h+Math.imul(Ne,q)|0,x=Math.imul(Ne,ie),S=S+Math.imul(Fe,be)|0,h=h+Math.imul(Fe,Ce)|0,h=h+Math.imul(ge,be)|0,x=x+Math.imul(ge,Ce)|0,S=S+Math.imul(De,Ie)|0,h=h+Math.imul(De,qe)|0,h=h+Math.imul(Ke,Ie)|0,x=x+Math.imul(Ke,qe)|0,S=S+Math.imul(Te,Ve)|0,h=h+Math.imul(Te,zt)|0,h=h+Math.imul($e,Ve)|0,x=x+Math.imul($e,zt)|0,S=S+Math.imul(_e,Xe)|0,h=h+Math.imul(_e,Tt)|0,h=h+Math.imul(Ue,Xe)|0,x=x+Math.imul(Ue,Tt)|0,S=S+Math.imul(ee,Je)|0,h=h+Math.imul(ee,Et)|0,h=h+Math.imul(se,Je)|0,x=x+Math.imul(se,Et)|0,S=S+Math.imul(W,Qe)|0,h=h+Math.imul(W,Lt)|0,h=h+Math.imul(ce,Qe)|0,x=x+Math.imul(ce,Lt)|0,S=S+Math.imul(J,et)|0,h=h+Math.imul(J,Rt)|0,h=h+Math.imul(Y,et)|0,x=x+Math.imul(Y,Rt)|0,S=S+Math.imul(F,Ye)|0,h=h+Math.imul(F,Nt)|0,h=h+Math.imul(Q,Ye)|0,x=x+Math.imul(Q,Nt)|0;var mn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(mn>>>26)|0,mn&=67108863,S=Math.imul(H,q),h=Math.imul(H,ie),h=h+Math.imul(k,q)|0,x=Math.imul(k,ie),S=S+Math.imul(ke,be)|0,h=h+Math.imul(ke,Ce)|0,h=h+Math.imul(Ne,be)|0,x=x+Math.imul(Ne,Ce)|0,S=S+Math.imul(Fe,Ie)|0,h=h+Math.imul(Fe,qe)|0,h=h+Math.imul(ge,Ie)|0,x=x+Math.imul(ge,qe)|0,S=S+Math.imul(De,Ve)|0,h=h+Math.imul(De,zt)|0,h=h+Math.imul(Ke,Ve)|0,x=x+Math.imul(Ke,zt)|0,S=S+Math.imul(Te,Xe)|0,h=h+Math.imul(Te,Tt)|0,h=h+Math.imul($e,Xe)|0,x=x+Math.imul($e,Tt)|0,S=S+Math.imul(_e,Je)|0,h=h+Math.imul(_e,Et)|0,h=h+Math.imul(Ue,Je)|0,x=x+Math.imul(Ue,Et)|0,S=S+Math.imul(ee,Qe)|0,h=h+Math.imul(ee,Lt)|0,h=h+Math.imul(se,Qe)|0,x=x+Math.imul(se,Lt)|0,S=S+Math.imul(W,et)|0,h=h+Math.imul(W,Rt)|0,h=h+Math.imul(ce,et)|0,x=x+Math.imul(ce,Rt)|0,S=S+Math.imul(J,Ye)|0,h=h+Math.imul(J,Nt)|0,h=h+Math.imul(Y,Ye)|0,x=x+Math.imul(Y,Nt)|0,S=S+Math.imul(F,tt)|0,h=h+Math.imul(F,At)|0,h=h+Math.imul(Q,tt)|0,x=x+Math.imul(Q,At)|0;var Nn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Nn>>>26)|0,Nn&=67108863,S=Math.imul(H,be),h=Math.imul(H,Ce),h=h+Math.imul(k,be)|0,x=Math.imul(k,Ce),S=S+Math.imul(ke,Ie)|0,h=h+Math.imul(ke,qe)|0,h=h+Math.imul(Ne,Ie)|0,x=x+Math.imul(Ne,qe)|0,S=S+Math.imul(Fe,Ve)|0,h=h+Math.imul(Fe,zt)|0,h=h+Math.imul(ge,Ve)|0,x=x+Math.imul(ge,zt)|0,S=S+Math.imul(De,Xe)|0,h=h+Math.imul(De,Tt)|0,h=h+Math.imul(Ke,Xe)|0,x=x+Math.imul(Ke,Tt)|0,S=S+Math.imul(Te,Je)|0,h=h+Math.imul(Te,Et)|0,h=h+Math.imul($e,Je)|0,x=x+Math.imul($e,Et)|0,S=S+Math.imul(_e,Qe)|0,h=h+Math.imul(_e,Lt)|0,h=h+Math.imul(Ue,Qe)|0,x=x+Math.imul(Ue,Lt)|0,S=S+Math.imul(ee,et)|0,h=h+Math.imul(ee,Rt)|0,h=h+Math.imul(se,et)|0,x=x+Math.imul(se,Rt)|0,S=S+Math.imul(W,Ye)|0,h=h+Math.imul(W,Nt)|0,h=h+Math.imul(ce,Ye)|0,x=x+Math.imul(ce,Nt)|0,S=S+Math.imul(J,tt)|0,h=h+Math.imul(J,At)|0,h=h+Math.imul(Y,tt)|0,x=x+Math.imul(Y,At)|0;var Kn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Kn>
vendor: 11,600 bytes, line 1981
1981>>26)|0,Kn&=67108863,S=Math.imul(H,Ie),h=Math.imul(H,qe),h=h+Math.imul(k,Ie)|0,x=Math.imul(k,qe),S=S+Math.imul(ke,Ve)|0,h=h+Math.imul(ke,zt)|0,h=h+Math.imul(Ne,Ve)|0,x=x+Math.imul(Ne,zt)|0,S=S+Math.imul(Fe,Xe)|0,h=h+Math.imul(Fe,Tt)|0,h=h+Math.imul(ge,Xe)|0,x=x+Math.imul(ge,Tt)|0,S=S+Math.imul(De,Je)|0,h=h+Math.imul(De,Et)|0,h=h+Math.imul(Ke,Je)|0,x=x+Math.imul(Ke,Et)|0,S=S+Math.imul(Te,Qe)|0,h=h+Math.imul(Te,Lt)|0,h=h+Math.imul($e,Qe)|0,x=x+Math.imul($e,Lt)|0,S=S+Math.imul(_e,et)|0,h=h+Math.imul(_e,Rt)|0,h=h+Math.imul(Ue,et)|0,x=x+Math.imul(Ue,Rt)|0,S=S+Math.imul(ee,Ye)|0,h=h+Math.imul(ee,Nt)|0,h=h+Math.imul(se,Ye)|0,x=x+Math.imul(se,Nt)|0,S=S+Math.imul(W,tt)|0,h=h+Math.imul(W,At)|0,h=h+Math.imul(ce,tt)|0,x=x+Math.imul(ce,At)|0;var sn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(sn>>>26)|0,sn&=67108863,S=Math.imul(H,Ve),h=Math.imul(H,zt),h=h+Math.imul(k,Ve)|0,x=Math.imul(k,zt),S=S+Math.imul(ke,Xe)|0,h=h+Math.imul(ke,Tt)|0,h=h+Math.imul(Ne,Xe)|0,x=x+Math.imul(Ne,Tt)|0,S=S+Math.imul(Fe,Je)|0,h=h+Math.imul(Fe,Et)|0,h=h+Math.imul(ge,Je)|0,x=x+Math.imul(ge,Et)|0,S=S+Math.imul(De,Qe)|0,h=h+Math.imul(De,Lt)|0,h=h+Math.imul(Ke,Qe)|0,x=x+Math.imul(Ke,Lt)|0,S=S+Math.imul(Te,et)|0,h=h+Math.imul(Te,Rt)|0,h=h+Math.imul($e,et)|0,x=x+Math.imul($e,Rt)|0,S=S+Math.imul(_e,Ye)|0,h=h+Math.imul(_e,Nt)|0,h=h+Math.imul(Ue,Ye)|0,x=x+Math.imul(Ue,Nt)|0,S=S+Math.imul(ee,tt)|0,h=h+Math.imul(ee,At)|0,h=h+Math.imul(se,tt)|0,x=x+Math.imul(se,At)|0;var Fn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Fn>>>26)|0,Fn&=67108863,S=Math.imul(H,Xe),h=Math.imul(H,Tt),h=h+Math.imul(k,Xe)|0,x=Math.imul(k,Tt),S=S+Math.imul(ke,Je)|0,h=h+Math.imul(ke,Et)|0,h=h+Math.imul(Ne,Je)|0,x=x+Math.imul(Ne,Et)|0,S=S+Math.imul(Fe,Qe)|0,h=h+Math.imul(Fe,Lt)|0,h=h+Math.imul(ge,Qe)|0,x=x+Math.imul(ge,Lt)|0,S=S+Math.imul(De,et)|0,h=h+Math.imul(De,Rt)|0,h=h+Math.imul(Ke,et)|0,x=x+Math.imul(Ke,Rt)|0,S=S+Math.imul(Te,Ye)|0,h=h+Math.imul(Te,Nt)|0,h=h+Math.imul($e,Ye)|0,x=x+Math.imul($e,Nt)|0,S=S+Math.imul(_e,tt)|0,h=h+Math.imul(_e,At)|0,h=h+Math.imul(Ue,tt)|0,x=x+Math.imul(Ue,At)|0;var Tn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Tn>>>26)|0,Tn&=67108863,S=Math.imul(H,Je),h=Math.imul(H,Et),h=h+Math.imul(k,Je)|0,x=Math.imul(k,Et),S=S+Math.imul(ke,Qe)|0,h=h+Math.imul(ke,Lt)|0,h=h+Math.imul(Ne,Qe)|0,x=x+Math.imul(Ne,Lt)|0,S=S+Math.imul(Fe,et)|0,h=h+Math.imul(Fe,Rt)|0,h=h+Math.imul(ge,et)|0,x=x+Math.imul(ge,Rt)|0,S=S+Math.imul(De,Ye)|0,h=h+Math.imul(De,Nt)|0,h=h+Math.imul(Ke,Ye)|0,x=x+Math.imul(Ke,Nt)|0,S=S+Math.imul(Te,tt)|0,h=h+Math.imul(Te,At)|0,h=h+Math.imul($e,tt)|0,x=x+Math.imul($e,At)|0;var Pn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Pn>>>26)|0,Pn&=67108863,S=Math.imul(H,Qe),h=Math.imul(H,Lt),h=h+Math.imul(k,Qe)|0,x=Math.imul(k,Lt),S=S+Math.imul(ke,et)|0,h=h+Math.imul(ke,Rt)|0,h=h+Math.imul(Ne,et)|0,x=x+Math.imul(Ne,Rt)|0,S=S+Math.imul(Fe,Ye)|0,h=h+Math.imul(Fe,Nt)|0,h=h+Math.imul(ge,Ye)|0,x=x+Math.imul(ge,Nt)|0,S=S+Math.imul(De,tt)|0,h=h+Math.imul(De,At)|0,h=h+Math.imul(Ke,tt)|0,x=x+Math.imul(Ke,At)|0;var Gn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Gn>>>26)|0,Gn&=67108863,S=Math.imul(H,et),h=Math.imul(H,Rt),h=h+Math.imul(k,et)|0,x=Math.imul(k,Rt),S=S+Math.imul(ke,Ye)|0,h=h+Math.imul(ke,Nt)|0,h=h+Math.imul(Ne,Ye)|0,x=x+Math.imul(Ne,Nt)|0,S=S+Math.imul(Fe,tt)|0,h=h+Math.imul(Fe,At)|0,h=h+Math.imul(ge,tt)|0,x=x+Math.imul(ge,At)|0;var Zr=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Zr>>>26)|0,Zr&=67108863,S=Math.imul(H,Ye),h=Math.imul(H,Nt),h=h+Math.imul(k,Ye)|0,x=Math.imul(k,Nt),S=S+Math.imul(ke,tt)|0,h=h+Math.imul(ke,At)|0,h=h+Math.imul(Ne,tt)|0,x=x+Math.imul(Ne,At)|0;var Yn=(T+S|0)+((h&8191)<<13)|0;T=(x+(h>>>13)|0)+(Yn>>>26)|0,Yn&=67108863,S=Math.imul(H,tt),h=Math.imul(H,At),h=h+Math.imul(k,tt)|0,x=Math.imul(k,At);var zn=(T+S|0)+((h&8191)<<13)|0;return T=(x+(h>>>13)|0)+(zn>>>26)|0,zn&=67108863,B[0]=It,B[1]=xt,B[2]=oi,B[3]=li,B[4]=ci,B[5]=Rn,B[6]=Sn,B[7]=zr,B[8]=mn,B[9]=Nn,B[10]=Kn,B[11]=sn,B[12]=Fn,B[13]=Tn,B[14]=Pn,B[15]=Gn,B[16]=Zr,B[17]=Yn,B[18]=zn,T!==0&&(B[19]=T,f.length++),f};Math.imul||(I=O);function R(m,A,f){f.negative=A.negative^m.negative,f.length=m.length+A.length;for(var g=0,_=0,B=0;B<f.length-1;B++){var T=_;_=0;for(var S=g&67108863,h=Math.min(B,A.length-1),x=Math.max(0,B-m.length+1);x<=h;x++){var v=B-x,F=m.words[v]|0,Q=A.words[x]|0,G=F*Q,J=G&67108863;T=T+(G/67108864|0)|0,J=J+S|0,S=J&67108863,T=T+(J>>>26)|0,_+=T>>>26,T&=67108863}f.words[B]=S,g=T,T=_}return g!==0?f.words[B]=g:f.length--,f.strip()}function C(m,A,f){var g=new j;return g.mulp(m,A,f)}a.prototype.mulTo=function(m,A){var f,g=this.length+m.length;return this.length===10&&m.length===10?f=I(this,m,A):g<63?f=O(this,m,A):g<1024?f=R(this,m,A):f=C(this,m,A),f};function j(m,A){this.x=m,this.y=A}j.prototype.makeRBT=function(m){for(var A=new Array(m),f=a.prototype._countBits(m)-1,g=0;g<m;g++)A[g]=this.revBin(g,f,m);return A},j.prototype.revBin=function(m,A,f){if(m===0||m===f-1)return m;for(var g=0,_=0;_<A;_++)g|=(m&1)<<A-_-1,m>>=1;return g},j.prototype.permute=function(m,A,f,g,_,B){for(var T=0;T<B;T++)g[T]=A[m[T]],_[T]=f[m[T]]},j.prototype.transform=function(m,A,f,g,_,B){this.permute(B,m,A,f,g,_);for(var T=1;T<_;T<<=1)for(var S=T<<1,h=Math.cos(2*Math.PI/S),x=Math.sin(2*Math.PI/S),v=0;v<_;v+=S)for(var F=h,Q=x,G=0;G<T;G++){var J=f[v+G],Y=g[v+G],V=f[v+G+T],W=g[v+G+T],ce=F*V-Q*W;W=F*W+Q*V,V=ce,f[v+G]=J+V,g[v+G]=Y+W,f[v+G+T]=J-V,g[v+G+T]=Y-W,G!==S&&(ce=h*F-x*Q,Q=h*Q+x*F,F=ce)}},j.prototype.guessLen13b=function(m,A){var f=Math.max(A,m)|1,g=f&1,_=0;for(f=f/2|0;f;f=f>>>1)_++;return 1<<_+1+g},j.prototype.conjugate=function(m,A,f){if(!(f<=1))for(var g=0;g<f/2;g++){var _=m[g];m[g]=m[f-g-1],m[f-g-1]=_,_=A[g],A[g]=-A[f-g-1],A[f-g-1]=-_}},j.prototype.normalize13b=function(m,A){for(var f=0,g=0;g<A/2;g++){var _=Math.round(m[2*g+1]/A)*8192+Math.round(m[2*g]/A)+f;m[g]=_&67108863,_<67108864?f=0:f=_/67108864|0}return m},j.prototype.convert13b=function(m,A,f,g){for(var _=0,B=0;B<A;B++)_=_+(m[B]|0),f[2*B]=_&8191,_=_>>>13,f[2*B+1]=_&8191,_=_>>>13;for(B=2*A;B<g;++B)f[B]=0;n(_===0),n((_&-8192)===0)},j.prototype.stub=function(m){for(var A=new Array(m),f=0;f<m;f++)A[f]=0;return A},j.prototype.mulp=function(m,A,f){var g=2*this.guessLen13b(m.length,A.length),_=this.makeRBT(g),B=this.stub(g),T=new Array(g),S=new Array(g),h=new Array(g),x=new Array(g),v=new Array(g),F=new Array(g),Q=f.words;Q.length=g,this.convert13b(m.words,m.length,T,g),this.convert13b(A.words,A.length,x,g),this.transform(T,B,S,h,g,_),this.transform(x,B,v,F,g,_);for(var G=0;G<g;G++){var J=S[G]*v[G]-h[G]*F[G];h[G]=S[G]*F[G]+h[G]*v[G],S[G]=J}return this.conjugate(S,h,g),this.transform(S,h,Q,B,g,_),this.conjugate(Q,B,g),this.normalize13b(Q,g),f.negative=m.negative^A.negative,f.length=m.length+A.length,f.strip()},a.prototype.mul=function(m){var A=new a(null);return A.words=new Array(this.length+m.length),this.mulTo(m,A)},a.prototype.mulf=function(m){var A=new a(null);return A.words=new Array(this.length+m.length),C(this,m,A)},a.prototype.imul=function(m){return this.clone().mulTo(m,this)},a.prototype.imuln=function(m){n(typeof m=="number"),n(m<67108864);for(var A=0,f=0;f<this.length;f++){var g=(this.words[f]|0)*m,_=(g&67108863)+(A&67108863);A>>=26,A+=g/67108864|0,A+=_>>>26,this.words[f]=_&67108863}return A!==0&&(this.words[f]=A,this.length++),this},a.prototype.muln=function(m){return this.clone().imuln(m)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(m){var A=w(m);if(A.length===0)return new a(1);for(var f=this,g=0;g<A.length&&A[g]===0;g++,f=f.sqr());if(++g<A.length)for(var _=f.sqr();g<A.length;g++,_=_.sqr())A[g]!==0&&(f=f.mul(_));return f},a.prototype.iushln=function(m){n(typeof m=="number"&&m>=0);var A=m%26,f=(m-A)/26,g=67108863>>>26-A<<26-A,_;if(A!==0){var B=0;for(_=0;_<this.length;_++){var T=this.words[_]&g,S=(this.words[_]|0)-T<<A;this.words[_]=S|B,B=T>>>26-A}B&&(this.words[_]=B,this.length++)}if(f!==0){for(_=this.length-1;_>=0;_--)this.words[_+f]=this.words[_];for(_=0;_<f;_++)this.words[_]=0;this.length+=f}return this.strip()},a.prototype.ishln=function(m){return n(this.negative===0),this.iushln(m)},a.prototype.iushrn=function(m,A,f){n(typeof m=="number"&&m>=0);var g;A?g=(A-A%26)/26:g=0;var _=m%26,B=Math.min((m-_)/26,this.length),T=67108863^67108863>>>_<<_,S=f;if(g-=B,g=Math.max(0,g),S){for(var h=0;h<B;h++)S.words[h]=this.words[h];S.length=B}if(B!==0)if(this.length>B)for(this.length-=B,h=0;h<this.length;h++)this.words[h]=this.words[h+B];else this.words[0]=0,this.length=1;var x=0;for(h=this.length-1;h>=0&&(x!==0||h>=g);h--){var v=this.words[h]|0;this.words[h]=x<<26-_|v>>>_,x=v&T}return S&&x!==0&&(S.words[S.length++]=x),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},a.prototype.ishrn=function(m,A,f){return n(this.negative===0),this.iushrn(m,A,f)},a.prototype.shln=function(m){return this.clone().ishln(m)},a.prototype.ushln=function(m){return this.clone().iushln(m)},a.prototype.shrn=function(m){return this.clone().ishrn(m)},a.prototype.ushrn=function(m){return this.clone().iushrn(m)},a.prototype.testn=function(m){n(typeof m=="number"&&m>=0);var A=m%26,f=(m-A)/26,g=1<<A;if(this.length<=f)return!1;var _=this.words[f];return!!(_&g)},a.prototype.imaskn=function(m){n(typeof m=="number"&&m>=0);var A=m%26,f=(m-A)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=f)return this;if(A!==0&&f++,this.length=Math.min(f,this.length),A!==0){var g=67108863^67108863>>>A<<A;this.words[this.length-1]&=g}return this.strip()},a.prototype.maskn=function(m){return this.clone().imaskn(m)},a.prototype.iaddn=function(m){return n(typeof m=="number"),n(m<67108864),m<0?this.isubn(-m):this.negative!==0?this.length===1&&(this.words[0]|0)<m?(this.words[0]=m-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(m),this.negative=1,this):this._iaddn(m)},a.prototype._iaddn=function(m){this.words[0]+=m;for(var A=0;A<this.length&&this.words[A]>=67108864;A++)this.words[A]-=67108864,A===this.length-1?this.words[A+1]=1:this.words[A+1]++;return this.length=Math.max(this.length,A+1),this},a.prototype.isubn=function(m){if(n(typeof m=="number"),n(m<67108864),m<0)return this.iaddn(-m);if(this.negative!==0)return this.negative=0,this.iaddn(m),this.negative=1,this;if(this.words[0]-=m,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var A=0;A<this.length&&this.words[A]<0;A++)this.words[A]+=67108864,this.words[A+1]-=1;return this.strip()},a.prototype.addn=function(m){return this.clone().iaddn(m)},a.prototype.subn=function(m){return this.clone().isubn(m)},a.prototype.iabs=function(){return this.negative=0,this},a.prototype.abs=function(){return this.clone().iabs()},a.prototype._ishlnsubmul=function(m,A,f){var g=m.length+f,_;this._expand(g);var B,T=0;for(_=0;_<m.length;_++){B=(this.words[_+f]|0)+T;var S=(m.words[_]|0)*A;B-=S&67108863,T=(B>>26)-(S/67108864|0),this.words[_+f]=B&67108863}for(;_<this.length-f;_++)B=(this.words[_+f]|0)+T,T=B>>26,this.words[_+f]=B&67108863;if(T===0)return this.strip();for(n(T===-1),T=0,_=0;_<this.length;_++)B=-(this.words[_]|0)+T,T=B>>26,this.words[_]=B&67108863;return this.negative=1,this.strip()},a.prototype._wordDiv=function(m,A){var f=this.length-m.length,g=this.clone(),_=m,B=_.words[_.length-1]|0,T=this._countBits(B);f=26-T,f!==0&&(_=_.ushln(f),g.iushln(f),B=_.words[_.length-1]|0);var S=g.length-_.length,h;if(A!=="mod"){h=new a(null),h.length=S+1,h.words=new Array(h.length);for(var x=0;x<h.length;x++)h.words[x]=0}var v=g.clone()._ishlnsubmul(_,1,S);v.negative===0&&(g=v,h&&(h.words[S]=1));for(var F=S-1;F>=0;F--){var Q=(g.words[_.length+F]|0)*67108864+(g.words[_.length+F-1]|0);
vendor: 12,827 bytes, line 1981
1981for(Q=Math.min(Q/B|0,67108863),g._ishlnsubmul(_,Q,F);g.negative!==0;)Q--,g.negative=0,g._ishlnsubmul(_,1,F),g.isZero()||(g.negative^=1);h&&(h.words[F]=Q)}return h&&h.strip(),g.strip(),A!=="div"&&f!==0&&g.iushrn(f),{div:h||null,mod:g}},a.prototype.divmod=function(m,A,f){if(n(!m.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var g,_,B;return this.negative!==0&&m.negative===0?(B=this.neg().divmod(m,A),A!=="mod"&&(g=B.div.neg()),A!=="div"&&(_=B.mod.neg(),f&&_.negative!==0&&_.iadd(m)),{div:g,mod:_}):this.negative===0&&m.negative!==0?(B=this.divmod(m.neg(),A),A!=="mod"&&(g=B.div.neg()),{div:g,mod:B.mod}):this.negative&m.negative?(B=this.neg().divmod(m.neg(),A),A!=="div"&&(_=B.mod.neg(),f&&_.negative!==0&&_.isub(m)),{div:B.div,mod:_}):m.length>this.length||this.cmp(m)<0?{div:new a(0),mod:this}:m.length===1?A==="div"?{div:this.divn(m.words[0]),mod:null}:A==="mod"?{div:null,mod:new a(this.modn(m.words[0]))}:{div:this.divn(m.words[0]),mod:new a(this.modn(m.words[0]))}:this._wordDiv(m,A)},a.prototype.div=function(m){return this.divmod(m,"div",!1).div},a.prototype.mod=function(m){return this.divmod(m,"mod",!1).mod},a.prototype.umod=function(m){return this.divmod(m,"mod",!0).mod},a.prototype.divRound=function(m){var A=this.divmod(m);if(A.mod.isZero())return A.div;var f=A.div.negative!==0?A.mod.isub(m):A.mod,g=m.ushrn(1),_=m.andln(1),B=f.cmp(g);return B<0||_===1&&B===0?A.div:A.div.negative!==0?A.div.isubn(1):A.div.iaddn(1)},a.prototype.modn=function(m){n(m<=67108863);for(var A=67108864%m,f=0,g=this.length-1;g>=0;g--)f=(A*f+(this.words[g]|0))%m;return f},a.prototype.idivn=function(m){n(m<=67108863);for(var A=0,f=this.length-1;f>=0;f--){var g=(this.words[f]|0)+A*67108864;this.words[f]=g/m|0,A=g%m}return this.strip()},a.prototype.divn=function(m){return this.clone().idivn(m)},a.prototype.egcd=function(m){n(m.negative===0),n(!m.isZero());var A=this,f=m.clone();A.negative!==0?A=A.umod(m):A=A.clone();for(var g=new a(1),_=new a(0),B=new a(0),T=new a(1),S=0;A.isEven()&&f.isEven();)A.iushrn(1),f.iushrn(1),++S;for(var h=f.clone(),x=A.clone();!A.isZero();){for(var v=0,F=1;!(A.words[0]&F)&&v<26;++v,F<<=1);if(v>0)for(A.iushrn(v);v-- >0;)(g.isOdd()||_.isOdd())&&(g.iadd(h),_.isub(x)),g.iushrn(1),_.iushrn(1);for(var Q=0,G=1;!(f.words[0]&G)&&Q<26;++Q,G<<=1);if(Q>0)for(f.iushrn(Q);Q-- >0;)(B.isOdd()||T.isOdd())&&(B.iadd(h),T.isub(x)),B.iushrn(1),T.iushrn(1);A.cmp(f)>=0?(A.isub(f),g.isub(B),_.isub(T)):(f.isub(A),B.isub(g),T.isub(_))}return{a:B,b:T,gcd:f.iushln(S)}},a.prototype._invmp=function(m){n(m.negative===0),n(!m.isZero());var A=this,f=m.clone();A.negative!==0?A=A.umod(m):A=A.clone();for(var g=new a(1),_=new a(0),B=f.clone();A.cmpn(1)>0&&f.cmpn(1)>0;){for(var T=0,S=1;!(A.words[0]&S)&&T<26;++T,S<<=1);if(T>0)for(A.iushrn(T);T-- >0;)g.isOdd()&&g.iadd(B),g.iushrn(1);for(var h=0,x=1;!(f.words[0]&x)&&h<26;++h,x<<=1);if(h>0)for(f.iushrn(h);h-- >0;)_.isOdd()&&_.iadd(B),_.iushrn(1);A.cmp(f)>=0?(A.isub(f),g.isub(_)):(f.isub(A),_.isub(g))}var v;return A.cmpn(1)===0?v=g:v=_,v.cmpn(0)<0&&v.iadd(m),v},a.prototype.gcd=function(m){if(this.isZero())return m.abs();if(m.isZero())return this.abs();var A=this.clone(),f=m.clone();A.negative=0,f.negative=0;for(var g=0;A.isEven()&&f.isEven();g++)A.iushrn(1),f.iushrn(1);do{for(;A.isEven();)A.iushrn(1);for(;f.isEven();)f.iushrn(1);var _=A.cmp(f);if(_<0){var B=A;A=f,f=B}else if(_===0||f.cmpn(1)===0)break;A.isub(f)}while(!0);return f.iushln(g)},a.prototype.invm=function(m){return this.egcd(m).a.umod(m)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(m){return this.words[0]&m},a.prototype.bincn=function(m){n(typeof m=="number");var A=m%26,f=(m-A)/26,g=1<<A;if(this.length<=f)return this._expand(f+1),this.words[f]|=g,this;for(var _=g,B=f;_!==0&&B<this.length;B++){var T=this.words[B]|0;T+=_,_=T>>>26,T&=67108863,this.words[B]=T}return _!==0&&(this.words[B]=_,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(m){var A=m<0;if(this.negative!==0&&!A)return-1;if(this.negative===0&&A)return 1;this.strip();var f;if(this.length>1)f=1;else{A&&(m=-m),n(m<=67108863,"Number is too big");var g=this.words[0]|0;f=g===m?0:g<m?-1:1}return this.negative!==0?-f|0:f},a.prototype.cmp=function(m){if(this.negative!==0&&m.negative===0)return-1;if(this.negative===0&&m.negative!==0)return 1;var A=this.ucmp(m);return this.negative!==0?-A|0:A},a.prototype.ucmp=function(m){if(this.length>m.length)return 1;if(this.length<m.length)return-1;for(var A=0,f=this.length-1;f>=0;f--){var g=this.words[f]|0,_=m.words[f]|0;if(g!==_){g<_?A=-1:g>_&&(A=1);break}}return A},a.prototype.gtn=function(m){return this.cmpn(m)===1},a.prototype.gt=function(m){return this.cmp(m)===1},a.prototype.gten=function(m){return this.cmpn(m)>=0},a.prototype.gte=function(m){return this.cmp(m)>=0},a.prototype.ltn=function(m){return this.cmpn(m)===-1},a.prototype.lt=function(m){return this.cmp(m)===-1},a.prototype.lten=function(m){return this.cmpn(m)<=0},a.prototype.lte=function(m){return this.cmp(m)<=0},a.prototype.eqn=function(m){return this.cmpn(m)===0},a.prototype.eq=function(m){return this.cmp(m)===0},a.red=function(m){return new ae(m)},a.prototype.toRed=function(m){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),m.convertTo(this)._forceRed(m)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(m){return this.red=m,this},a.prototype.forceRed=function(m){return n(!this.red,"Already a number in reduction context"),this._forceRed(m)},a.prototype.redAdd=function(m){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,m)},a.prototype.redIAdd=function(m){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,m)},a.prototype.redSub=function(m){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,m)},a.prototype.redISub=function(m){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,m)},a.prototype.redShl=function(m){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,m)},a.prototype.redMul=function(m){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,m),this.red.mul(this,m)},a.prototype.redIMul=function(m){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,m),this.red.imul(this,m)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(m){return n(this.red&&!m.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,m)};var N={k256:null,p224:null,p192:null,p25519:null};function P(m,A){this.name=m,this.p=new a(A,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}P.prototype._tmp=function(){var m=new a(null);return m.words=new Array(Math.ceil(this.n/13)),m},P.prototype.ireduce=function(m){var A=m,f;do this.split(A,this.tmp),A=this.imulK(A),A=A.iadd(this.tmp),f=A.bitLength();while(f>this.n);var g=f<this.n?-1:A.ucmp(this.p);return g===0?(A.words[0]=0,A.length=1):g>0?A.isub(this.p):A.strip!==void 0?A.strip():A._strip(),A},P.prototype.split=function(m,A){m.iushrn(this.n,0,A)},P.prototype.imulK=function(m){return m.imul(this.k)};function Z(){P.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(Z,P),Z.prototype.split=function(m,A){for(var f=4194303,g=Math.min(m.length,9),_=0;_<g;_++)A.words[_]=m.words[_];if(A.length=g,m.length<=9){m.words[0]=0,m.length=1;return}var B=m.words[9];for(A.words[A.length++]=B&f,_=10;_<m.length;_++){var T=m.words[_]|0;m.words[_-10]=(T&f)<<4|B>>>22,B=T}B>>>=22,m.words[_-10]=B,B===0&&m.length>10?m.length-=10:m.length-=9},Z.prototype.imulK=function(m){m.words[m.length]=0,m.words[m.length+1]=0,m.length+=2;for(var A=0,f=0;f<m.length;f++){var g=m.words[f]|0;A+=g*977,m.words[f]=A&67108863,A=g*64+(A/67108864|0)}return m.words[m.length-1]===0&&(m.length--,m.words[m.length-1]===0&&m.length--),m};function X(){P.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}i(X,P);function re(){P.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}i(re,P);function ne(){P.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}i(ne,P),ne.prototype.imulK=function(m){for(var A=0,f=0;f<m.length;f++){var g=(m.words[f]|0)*19+A,_=g&67108863;g>>>=26,m.words[f]=_,A=g}return A!==0&&(m.words[m.length++]=A),m},a._prime=function(m){if(N[m])return N[m];var A;if(m==="k256")A=new Z;else if(m==="p224")A=new X;else if(m==="p192")A=new re;else if(m==="p25519")A=new ne;else throw new Error("Unknown prime "+m);return N[m]=A,A};function ae(m){if(typeof m=="string"){var A=a._prime(m);this.m=A.p,this.prime=A}else n(m.gtn(1),"modulus must be greater than 1"),this.m=m,this.prime=null}ae.prototype._verify1=function(m){n(m.negative===0,"red works only with positives"),n(m.red,"red works only with red numbers")},ae.prototype._verify2=function(m,A){n((m.negative|A.negative)===0,"red works only with positives"),n(m.red&&m.red===A.red,"red works only with red numbers")},ae.prototype.imod=function(m){return this.prime?this.prime.ireduce(m)._forceRed(this):m.umod(this.m)._forceRed(this)},ae.prototype.neg=function(m){return m.isZero()?m.clone():this.m.sub(m)._forceRed(this)},ae.prototype.add=function(m,A){this._verify2(m,A);var f=m.add(A);return f.cmp(this.m)>=0&&f.isub(this.m),f._forceRed(this)},ae.prototype.iadd=function(m,A){this._verify2(m,A);var f=m.iadd(A);return f.cmp(this.m)>=0&&f.isub(this.m),f},ae.prototype.sub=function(m,A){this._verify2(m,A);var f=m.sub(A);return f.cmpn(0)<0&&f.iadd(this.m),f._forceRed(this)},ae.prototype.isub=function(m,A){this._verify2(m,A);var f=m.isub(A);return f.cmpn(0)<0&&f.iadd(this.m),f},ae.prototype.shl=function(m,A){return this._verify1(m),this.imod(m.ushln(A))},ae.prototype.imul=function(m,A){return this._verify2(m,A),this.imod(m.imul(A))},ae.prototype.mul=function(m,A){return this._verify2(m,A),this.imod(m.mul(A))},ae.prototype.isqr=function(m){return this.imul(m,m.clone())},ae.prototype.sqr=function(m){return this.mul(m,m)},ae.prototype.sqrt=function(m){if(m.isZero())return m.clone();var A=this.m.andln(3);if(n(A%2===1),A===3){var f=this.m.add(new a(1)).iushrn(2);return this.pow(m,f)}for(var g=this.m.subn(1),_=0;!g.isZero()&&g.andln(1)===0;)_++,g.iushrn(1);n(!g.isZero());var B=new a(1).toRed(this),T=B.redNeg(),S=this.m.subn(1).iushrn(1),h=this.m.bitLength();for(h=new a(2*h*h).toRed(this);this.pow(h,S).cmp(T)!==0;)h.redIAdd(T);for(var x=this.pow(h,g),v=this.pow(m,g.addn(1).iushrn(1)),F=this.pow(m,g),Q=_;F.cmp(B)!==0;){for(var G=F,J=0;G.cmp(B)!==0;J++)G=G.redSqr();n(J<Q);var Y=this.pow(x,new a(1).iushln(Q-J-1));v=v.redMul(Y),x=Y.redSqr(),F=F.redMul(x),Q=J}return v},ae.prototype.invm=function(m){var A=m._invmp(this.m);return A.negative!==0?(A.negative=0,this.imod(A).redNeg()):this.imod(A)},ae.prototype.pow=function(m,A){if(A.isZero())return new a(1).toRed(this);if(A.cmpn(1)===0)return m.clone();var f=4,g=new Array(1<<f);g[0]=new a(1).toRed(this),g[1]=m;for(var _=2;_<g.length;_++)g[_]=this.mul(g[_-1],m);var B=g[0],T=0,S=0,h=A.bitLength()%26;for(h===0&&(h=26),_=A.length-1;_>=0;_--){for(var x=A.words[_],v=h-1;v>=0;v--){var F=x>>v&1;if(B!==g[0]&&(B=this.sqr(B)),F===0&&T===0){S=0;continue}T<<=1,T|=F,S++,!(S!==f&&(_!==0||v!==0))&&(B=this.mul(B,g[T]),S=0,T=0)}h=26}return B},ae.prototype.convertTo=function(m){var A=m.umod(this.m);return A===m?A.clone():A},ae.prototype.convertFrom=function(m){var A=m.clone();return A.red=null,A},a.mont=function(m){return new ue(m)};function ue(m){ae.call(this,m),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(ue,ae),ue.prototype.convertTo=function(m){return this.imod(m.ushln(this.shift))},ue.prototype.convertFrom=function(m){var A=this.imod(m.mul(this.rinv));return A.red=null,A}
1981,ue.prototype.imul=function(m,A){if(m.isZero()||A.isZero())return m.words[0]=0,m.length=1,m;var f=m.imul(A),g=f.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),_=f.isub(g).iushrn(this.shift),B=_;return _.cmp(this.m)>=0?B=_.isub(this.m):_.cmpn(0)<0&&(B=_.iadd(this.m)),B._forceRed(this)},ue.prototype.mul=function(m,A){if(m.isZero()||A.isZero())return new a(0)._forceRed(this);var f=m.mul(A),g=f.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),_=f.isub(g).iushrn(this.shift),B=_;return _.cmp(this.m)>=0?B=_.isub(this.m):_.cmpn(0)<0&&(B=_.iadd(this.m)),B._forceRed(this)},ue.prototype.invm=function(m){var A=this.imod(m._invmp(this.m).mul(this.r2));return A._forceRed(this)}})(e,dt)}(Z8);var Sc=Z8.exports,$8={};(function(e){var t=e;function r(a,s){if(Array.isArray(a))return a.slice();if(!a)return[];var o=[];if(typeof a!="string"){for(var c=0;c<a.length;c++)o[c]=a[c]|0;return o}if(s==="hex"){a=a.replace(/[^a-z0-9]+/ig,""),a.length%2!==0&&(a="0"+a);for(var c=0;c<a.length;c+=2)o.push(parseInt(a[c]+a[c+1],16))}else for(var c=0;c<a.length;c++){var l=a.charCodeAt(c),u=l>>8,d=l&255;u?o.push(u,d):o.push(d)}return o}t.toArray=r;function n(a){return a.length===1?"0"+a:a}t.zero2=n;function i(a){for(var s="",o=0;o<a.length;o++)s+=n(a[o].toString(16));return s}t.toHex=i,t.encode=function(a,s){return s==="hex"?i(a):a}})($8),function(e){var t=e,r=Sc,n=Bs,i=$8;t.assert=n,t.toArray=i.toArray,t.zero2=i.zero2,t.toHex=i.toHex,t.encode=i.encode;
1981function a(u,d,p){var w=new Array(Math.max(u.bitLength(),p)+1),O;for(O=0;O<w.length;O+=1)w[O]=0;var I=1<<d+1,R=u.clone();for(O=0;O<w.length;O++){var C,j=R.andln(I-1);R.isOdd()?(j>(I>>1)-1?C=(I>>1)-j:C=j,R.isubn(C)):C=0,w[O]=C,R.iushrn(1)}return w}t.getNAF=a;function s(u,d){var p=[[],[]];u=u.clone(),d=d.clone();for(var w=0,O=0,I;u.cmpn(-w)>0||d.cmpn(-O)>0;){var R=u.andln(3)+w&3,C=d.andln(3)+O&3;R===3&&(R=-1),C===3&&(C=-1);var j;R&1?(I=u.andln(7)+w&7,(I===3||I===5)&&C===2?j=-R:j=R):j=0,p[0].push(j);var N;C&1?(I=d.andln(7)+O&7,(I===3||I===5)&&R===2?N=-C:N=C):N=0,p[1].push(N),2*w===j+1&&(w=1-w),2*O===N+1&&(O=1-O),u.iushrn(1),d.iushrn(1)}return p}t.getJSF=s;function o(u,d,p){var w="_"+d;u.prototype[d]=function(){return this[w]!==void 0?this[w]:this[w]=p.call(this)}}t.cachedProperty=o;function c(u){return typeof u=="string"?t.toArray(u,"hex"):u}t.parseBytes=c;function l(u){return new r(u,"hex","le")}t.intFromLE=l}(ns);var H8={},_h=Sc,nb=ns,px=nb.getNAF,ihe=nb.getJSF,mx=nb.assert;function Pu(e,t){this.type=e,this.p=new _h(t.p,16),this.red=t.prime?_h.red(t.prime):_h.mont(this.p),this.zero=new _h(0).toRed(this.red),this.one=new _h(1).toRed(this.red),this.two=new _h(2).toRed(this.red),this.n=t.n&&new _h(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var gx=Pu;Pu.prototype.point=function(){throw new Error("Not implemented")},Pu.prototype.validate=function(){throw new Error("Not implemented")},Pu.prototype._fixedNafMul=function(e,t){mx(e.precomputed);var r=e._getDoubles(),n=px(t,1,this._bitLength),i=(1<<r.step+1)-(r.step%2===0?2:1);i/=3;var a=[],s,o;for(s=0;s<n.length;s+=r.step){o=0;for(var c=s+r.step-1;c>=s;c--)o=(o<<1)+n[c];a.push(o)}for(var l=this.jpoint(null,null,null),u=this.jpoint(null,null,null),d=i;d>0;d--){for(s=0;s<a.length;s++)o=a[s],o===d?u=u.mixedAdd(r.points[s]):o===-d&&(u=u.mixedAdd(r.points[s].neg()));l=l.add(u)}return l.toP()},Pu.prototype._wnafMul=function(e,t){var r=4,n=e._getNAFPoints(r);r=n.wnd;for(var i=n.points,a=px(t,r,this._bitLength),s=this.jpoint(null,null,null),o=a.length-1;o>=0;o--){for(var c=0;o>=0&&a[o]===0;o--)c++;if(o>=0&&c++,s=s.dblp(c),o<0)break;var l=a[o];mx(l!==0),e.type==="affine"?l>0?s=s.mixedAdd(i[l-1>>1]):s=s.mixedAdd(i[-l-1>>1].neg()):l>0?s=s.add(i[l-1>>1]):s=s.add(i[-l-1>>1].neg())}return e.type==="affine"?s.toP():s},Pu.prototype._wnafMulAdd=function(e,t,r,n,i){var a=this._wnafT1,s=this._wnafT2,o=this._wnafT3,c=0,l,u,d;for(l=0;l<n;l++){d=t[l];var p=d._getNAFPoints(e);a[l]=p.wnd,s[l]=p.points}for(l=n-1;l>=1;l-=2){var w=l-1,O=l;if(a[w]!==1||a[O]!==1){o[w]=px(r[w],a[w],this._bitLength),o[O]=px(r[O],a[O],this._bitLength),c=Math.max(o[w].length,c),c=Math.max(o[O].length,c);continue}var I=[t[w],null,null,t[O]];t[w].y.cmp(t[O].y)===0?(I[1]=t[w].add(t[O]),I[2]=t[w].toJ().mixedAdd(t[O].neg())):t[w].y.cmp(t[O].y.redNeg())===0?(I[1]=t[w].toJ().mixedAdd(t[O]),I[2]=t[w].add(t[O].neg())):(I[1]=t[w].toJ().mixedAdd(t[O]),I[2]=t[w].toJ().mixedAdd(t[O].neg()));var R=[-3,-1,-5,-7,0,7,5,1,3],C=ihe(r[w],r[O]);for(c=Math.max(C[0].length,c),o[w]=new Array(c),o[O]=new Array(c),u=0;u<c;u++){var j=C[0][u]|0,N=C[1][u]|0;o[w][u]=R[(j+1)*3+(N+1)],o[O][u]=0,s[w]=I}}var P=this.jpoint(null,null,null),Z=this._wnafT4;for(l=c;l>=0;l--){for(var X=0;l>=0;){var re=!0;for(u=0;u<n;u++)Z[u]=o[u][l]|0,Z[u]!==0&&(re=!1);if(!re)break;X++,l--}if(l>=0&&X++,P=P.dblp(X),l<0)break;for(u=0;u<n;u++){var ne=Z[u];ne!==0&&(ne>0?d=s[u][ne-1>>1]:ne<0&&(d=s[u][-ne-1>>1].neg()),d.type==="affine"?P=P.mixedAdd(d):P=P.add(d))}}for(l=0;l<n;l++)s[l]=null;return i?P:P.toP()};function Fs(e,t){this.curve=e,this.type=t,this.precomputed=null}Pu.BasePoint=Fs,Fs.prototype.eq=function(){throw new Error("Not implemented")},Fs.prototype.validate=function(){return this.curve.validate(this)},Pu.prototype.decodePoint=function(e,t){e=nb.toArray(e,t);var r=this.p.byteLength();if((e[0]===4||e[0]===6||e[0]===7)&&e.length-1===2*r){e[0]===6?mx(e[e.length-1]%2===0):e[0]===7&&mx(e[e.length-1]%2===1);var n=this.point(e.slice(1,1+r),e.slice(1+r,1+2*r));return n}else if((e[0]===2||e[0]===3)&&e.length-1===r)return this.pointFromX(e.slice(1,1+r),e[0]===3);throw new Error("Unknown point format")},Fs.prototype.encodeCompressed=function(e){return this.encode(e,!0)},Fs.prototype._encode=function(e){var t=this.curve.p.byteLength(),r=this.getX().toArray("be",t);return e?[this.getY().isEven()?2:3].concat(r):[4].concat(r,this.getY().toArray("be",t))},Fs.prototype.encode=function(e,t){return nb.encode(this._encode(t),e)}
1981,Fs.prototype.precompute=function(e){if(this.precomputed)return this;var t={doubles:null,naf:null,beta:null};return t.naf=this._getNAFPoints(8),t.doubles=this._getDoubles(4,e),t.beta=this._getBeta(),this.precomputed=t,this},Fs.prototype._hasDoubles=function(e){if(!this.precomputed)return!1;var t=this.precomputed.doubles;return t?t.points.length>=Math.ceil((e.bitLength()+1)/t.step):!1},Fs.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i<t;i+=e){for(var a=0;a<e;a++)n=n.dbl();r.push(n)}return{step:e,points:r}},Fs.prototype._getNAFPoints=function(e){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var t=[this],r=(1<<e)-1,n=r===1?null:this.dbl(),i=1;i<r;i++)t[i]=t[i-1].add(n);return{wnd:e,points:t}},Fs.prototype._getBeta=function(){return null},Fs.prototype.dblp=function(e){for(var t=this,r=0;r<e;r++)t=t.dbl();return t};var ahe=ns,Mn=Sc,W8=Zt,j0=gx,she=ahe.assert;function Ps(e){j0.call(this,"short",e),this.a=new Mn(e.a,16).toRed(this.red),this.b=new Mn(e.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=this.a.fromRed().cmpn(0)===0,this.threeA=this.a.fromRed().sub(this.p).cmpn(-3)===0,this.endo=this._getEndomorphism(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}W8(Ps,j0);var ohe=Ps;Ps.prototype._getEndomorphism=function(e){if(!(!this.zeroA||!this.g||!this.n||this.p.modn(3)!==1)){var t,r;if(e.beta)t=new Mn(e.beta,16).toRed(this.red);else{var n=this._getEndoRoots(this.p);t=n[0].cmp(n[1])<0?n[0]:n[1],t=t.toRed(this.red)}if(e.lambda)r=new Mn(e.lambda,16);else{var i=this._getEndoRoots(this.n);this.g.mul(i[0]).x.cmp(this.g.x.redMul(t))===0?r=i[0]:(r=i[1],she(this.g.mul(r).x.cmp(this.g.x.redMul(t))===0))}var a;return e.basis?a=e.basis.map(function(s){return{a:new Mn(s.a,16),b:new Mn(s.b,16)}}):a=this._getEndoBasis(r),{beta:t,lambda:r,basis:a}}},Ps.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:Mn.mont(e),r=new Mn(2).toRed(t).redInvm(),n=r.redNeg(),i=new Mn(3).toRed(t).redNeg().redSqrt().redMul(r),a=n.redAdd(i).fromRed(),s=n.redSub(i).fromRed();return[a,s]},Ps.prototype._getEndoBasis=function(e){for(var t=this.n.ushrn(Math.floor(this.n.bitLength()/2)),r=e,n=this.n.clone(),i=new Mn(1),a=new Mn(0),s=new Mn(0),o=new Mn(1),c,l,u,d,p,w,O,I=0,R,C;r.cmpn(0)!==0;){var j=n.div(r);R=n.sub(j.mul(r)),C=s.sub(j.mul(i));var N=o.sub(j.mul(a));if(!u&&R.cmp(t)<0)c=O.neg(),l=i,u=R.neg(),d=C;else if(u&&++I===2)break;O=R,n=r,r=R,s=i,i=C,o=a,a=N}p=R.neg(),w=C;var P=u.sqr().add(d.sqr()),Z=p.sqr().add(w.sqr());return Z.cmp(P)>=0&&(p=c,w=l),u.negative&&(u=u.neg(),d=d.neg()),p.negative&&(p=p.neg(),w=w.neg()),[{a:u,b:d},{a:p,b:w}]},Ps.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),a=r.b.neg().mul(e).divRound(this.n),s=i.mul(r.a),o=a.mul(n.a),c=i.mul(r.b),l=a.mul(n.b),u=e.sub(s).sub(o),d=c.add(l).neg();return{k1:u,k2:d}},Ps.prototype.pointFromX=function(e,t){e=new Mn(e,16),e.red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(n.redSqr().redSub(r).cmp(this.zero)!==0)throw new Error("invalid point");var i=n.fromRed().isOdd();return(t&&!i||!t&&i)&&(n=n.redNeg()),this.point(e,n)},Ps.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return r.redSqr().redISub(i).cmpn(0)===0},Ps.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,a=0;a<e.length;a++){var s=this._endoSplit(t[a]),o=e[a],c=o._getBeta();s.k1.negative&&(s.k1.ineg(),o=o.neg(!0)),s.k2.negative&&(s.k2.ineg(),c=c.neg(!0)),n[a*2]=o,n[a*2+1]=c,i[a*2]=s.k1,i[a*2+1]=s.k2}for(var l=this._wnafMulAdd(1,n,i,a*2,r),u=0;u<a*2;u++)n[u]=null,i[u]=null;return l};function yi(e,t,r,n){j0.BasePoint.call(this,e,"affine"),t===null&&r===null?(this.x=null,this.y=null,this.inf=!0):(this.x=new Mn(t,16),this.y=new Mn(r,16),n&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}W8(yi,j0.BasePoint),Ps.prototype.point=function(e,t,r){return new yi(this,e,t,r)},Ps.prototype.pointFromJSON=function(e,t){return yi.fromJSON(this,e,t)},yi.prototype._getBeta=function(){if(this.curve.endo){var e=this.prec
vendor: 8,544 bytes, line 1981
1981omputed;if(e&&e.beta)return e.beta;var t=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(e){var r=this.curve,n=function(i){return r.point(i.x.redMul(r.endo.beta),i.y)};e.beta=t,t.precomputed={beta:null,naf:e.naf&&{wnd:e.naf.wnd,points:e.naf.points.map(n)},doubles:e.doubles&&{step:e.doubles.step,points:e.doubles.points.map(n)}}}return t}},yi.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},yi.fromJSON=function(e,t,r){typeof t=="string"&&(t=JSON.parse(t));var n=e.point(t[0],t[1],r);if(!t[2])return n;function i(s){return e.point(s[0],s[1],r)}var a=t[2];return n.precomputed={beta:null,doubles:a.doubles&&{step:a.doubles.step,points:[n].concat(a.doubles.points.map(i))},naf:a.naf&&{wnd:a.naf.wnd,points:[n].concat(a.naf.points.map(i))}},n},yi.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},yi.prototype.isInfinity=function(){return this.inf},yi.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(this.x.cmp(e.x)===0)return this.curve.point(null,null);var t=this.y.redSub(e.y);t.cmpn(0)!==0&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},yi.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(e.cmpn(0)===0)return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),a=i.redSqr().redISub(this.x.redAdd(this.x)),s=i.redMul(this.x.redSub(a)).redISub(this.y);return this.curve.point(a,s)},yi.prototype.getX=function(){return this.x.fromRed()},yi.prototype.getY=function(){return this.y.fromRed()},yi.prototype.mul=function(e){return e=new Mn(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},yi.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},yi.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},yi.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||this.x.cmp(e.x)===0&&this.y.cmp(e.y)===0)},yi.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(i){return i.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},yi.prototype.toJ=function(){if(this.inf)return this.curve.jpoint(null,null,null);var e=this.curve.jpoint(this.x,this.y,this.curve.one);return e};function Ii(e,t,r,n){j0.BasePoint.call(this,e,"jacobian"),t===null&&r===null&&n===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new Mn(0)):(this.x=new Mn(t,16),this.y=new Mn(r,16),this.z=new Mn(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}W8(Ii,j0.BasePoint),Ps.prototype.jpoint=function(e,t,r){return new Ii(this,e,t,r)},Ii.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},Ii.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},Ii.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),a=this.y.redMul(t.redMul(e.z)),s=e.y.redMul(r.redMul(this.z)),o=n.redSub(i),c=a.redSub(s);if(o.cmpn(0)===0)return c.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var l=o.redSqr(),u=l.redMul(o),d=n.redMul(l),p=c.redSqr().redIAdd(u).redISub(d).redISub(d),w=c.redMul(d.redISub(p)).redISub(a.redMul(u)),O=this.z.redMul(e.z).redMul(o);return this.curve.jpoint(p,w,O)},Ii.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,a=e.y.redMul(t).redMul(this.z),s=r.redSub(n),o=i.redSub(a);if(s.cmpn(0)===0)return o.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var c=s.redSqr(),l=c.redMul(s),u=r.redMul(c),d=o.redSqr().redIAdd(l).redISub(u).redISub(u),p=o.redMul(u.redISub(d)).redISub(i.redMul(l)),w=this.z.redMul(s);return this.curve.jpoint(d,p,w)},Ii.prototype.dblp=function(e){if(e===0)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t<e;t++)r=r.dbl();return r}var n=this.curve.a,i=this.curve.tinv,a=this.x,s=this.y,o=this.z,c=o.redSqr().redSqr(),l=s.redAdd(s);for(t=0;t<e;t++){var u=a.redSqr(),d=l.redSqr(),p=d.redSqr(),w=u.redAdd(u).redIAdd(u).redIAdd(n.redMul(c)),O=a.redMul(d),I=w.redSqr().redISub(O.redAdd(O)),R=O.redISub(I),C=w.redMul(R);C=C.redIAdd(C).redISub(p);var j=l.redMul(o);t+1<e&&(c=c.redMul(p)),a=I,o=j,l=C}return this.curve.jpoint(a,l.redMul(i),o)},Ii.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},Ii.prototype._zeroDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),i=this.y.redSqr(),a=i.redSqr(),s=this.x.redAdd(i).redSqr().redISub(n).redISub(a);s=s.redIAdd(s);var o=n.redAdd(n).redIAdd(n),c=o.redSqr().redISub(s).redISub(s),l=a.redIAdd(a);l=l.redIAdd(l),l=l.redIAdd(l),e=c,t=o.redMul(s.redISub(c)).redISub(l),r=this.y.redAdd(this.y)}else{var u=this.x.redSqr(),d=this.y.redSqr(),p=d.redSqr(),w=this.x.redAdd(d).redSqr().redISub(u).redISub(p);w=w.redIAdd(w);var O=u.redAdd(u).redIAdd(u),I=O.redSqr(),R=p.redIAdd(p);R=R.redIAdd(R),R=R.redIAdd(R),e=I.redISub(w).redISub(w),t=O.redMul(w.redISub(e)).redISub(R),r=this.y.redMul(this.z),r=r.redIAdd(r)}return this.curve.jpoint(e,t,r)},Ii.prototype._threeDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),i=this.y.redSqr(),a=i.redSqr(),s=this.x.redAdd(i).redSqr().redISub(n).redISub(a);s=s.redIAdd(s);var o=n.redAdd(n).redIAdd(n).redIAdd(this.curve.a),c=o.redSqr().redISub(s).redISub(s);e=c;var l=a.redIAdd(a);l=l.redIAdd(l),l=l.redIAdd(l),t=o.redMul(s.redISub(c)).redISub(l),r=this.y.redAdd(this.y)}else{var u=this.z.redSqr(),d=this.y.redSqr(),p=this.x.redMul(d),w=this.x.redSub(u).redMul(this.x.redAdd(u));w=w.redAdd(w).redIAdd(w);var O=p.redIAdd(p);O=O.redIAdd(O);var I=O.redAdd(O);e=w.redSqr().redISub(I),r=this.y.redAdd(this.z).redSqr().redISub(d).redISub(u);var R=d.redSqr();R=R.redIAdd(R),R=R.redIAdd(R),R=R.redIAdd(R),t=w.redMul(O.redISub(e)).redISub(R)}return this.curve.jpoint(e,t,r)},Ii.prototype._dbl=function(){var e=this.curve.a,t=this.x,r=this.y,n=this.z,i=n.redSqr().redSqr(),a=t.redSqr(),s=r.redSqr(),o=a.redAdd(a).redIAdd(a).redIAdd(e.redMul(i)),c=t.redAdd(t);c=c.redIAdd(c);var l=c.redMul(s),u=o.redSqr().redISub(l.redAdd(l)),d=l.redISub(u),p=s.redSqr();p=p.redIAdd(p),p=p.redIAdd(p),p=p.redIAdd(p);var w=o.redMul(d).redISub(p),O=r.redAdd(r).redMul(n);return this.curve.jpoint(u,w,O)},Ii.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr(),n=t.redSqr(),i=e.redAdd(e).redIAdd(e),a=i.redSqr(),s=this.x.redAdd(t).redSqr().redISub(e).redISub(n);s=s.redIAdd(s),s=s.redAdd(s).redIAdd(s),s=s.redISub(a);var o=s.redSqr(),c=n.redIAdd(n);c=c.redIAdd(c),c=c.redIAdd(c),c=c.redIAdd(c);var l=i.redIAdd(s).redSqr().redISub(a).redISub(o).redISub(c),u=t.redMul(l);u=u.redIAdd(u),u=u.redIAdd(u);var d=this.x.redMul(o).redISub(u);d=d.redIAdd(d),d=d.redIAdd(d);var p=this.y.redMul(l.redMul(c.redISub(l)).redISub(s.redMul(o)));p=p.redIAdd(p),p=p.redIAdd(p),p=p.redIAdd(p);var w=this.z.redAdd(s).redSqr().redISub(r).redISub(o);return this.curve.jpoint(d,p,w)},Ii.prototype.mul=function(e,t){return e=new Mn(e,t),this.curve._wnafMul(this,e)},Ii.prototype.eq=function(e){if(e.type==="affine")return this.eq(e.toJ());if(this===e)return!0;
1981var t=this.z.redSqr(),r=e.z.redSqr();if(this.x.redMul(r).redISub(e.x.redMul(t)).cmpn(0)!==0)return!1;var n=t.redMul(this.z),i=r.redMul(e.z);return this.y.redMul(i).redISub(e.y.redMul(n)).cmpn(0)===0},Ii.prototype.eqXToP=function(e){var t=this.z.redSqr(),r=e.toRed(this.curve.red).redMul(t);if(this.x.cmp(r)===0)return!0;for(var n=e.clone(),i=this.curve.redN.redMul(t);;){if(n.iadd(this.curve.n),n.cmp(this.curve.p)>=0)return!1;if(r.redIAdd(i),this.x.cmp(r)===0)return!0}},Ii.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},Ii.prototype.isInfinity=function(){return this.z.cmpn(0)===0};var I0=Sc,pF=Zt,bx=gx,lhe=ns;function O0(e){bx.call(this,"mont",e),this.a=new I0(e.a,16).toRed(this.red),this.b=new I0(e.b,16).toRed(this.red),this.i4=new I0(4).toRed(this.red).redInvm(),this.two=new I0(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}pF(O0,bx);var che=O0;O0.prototype.validate=function(e){var t=e.normalize().x,r=t.redSqr(),n=r.redMul(t).redAdd(r.redMul(this.a)).redAdd(t),i=n.redSqrt();return i.redSqr().cmp(n)===0};function vi(e,t,r){bx.BasePoint.call(this,e,"projective"),t===null&&r===null?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new I0(t,16),this.z=new I0(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}pF(vi,bx.BasePoint),O0.prototype.decodePoint=function(e,t){return this.point(lhe.toArray(e,t),1)},O0.prototype.point=function(e,t){return new vi(this,e,t)},O0.prototype.pointFromJSON=function(e){return vi.fromJSON(this,e)},vi.prototype.precompute=function(){},vi.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},vi.fromJSON=function(e,t){return new vi(e,t[0],t[1]||e.one)},vi.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},vi.prototype.isInfinity=function(){return this.z.cmpn(0)===0},vi.prototype.dbl=function(){var e=this.x.redAdd(this.z),t=e.redSqr(),r=this.x.redSub(this.z),n=r.redSqr(),i=t.redSub(n),a=t.redMul(n),s=i.redMul(n.redAdd(this.curve.a24.redMul(i)));return this.curve.point(a,s)},vi.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},vi.prototype.diffAdd=function(e,t){var r=this.x.redAdd(this.z),n=this.x.redSub(this.z),i=e.x.redAdd(e.z),a=e.x.redSub(e.z),s=a.redMul(r),o=i.redMul(n),c=t.z.redMul(s.redAdd(o).redSqr()),l=t.x.redMul(s.redISub(o).redSqr());return this.curve.point(c,l)},vi.prototype.mul=function(e){for(var t=e.clone(),r=this,n=this.curve.point(null,null),i=this,a=[];t.cmpn(0)!==0;t.iushrn(1))a.push(t.andln(1));for(var s=a.length-1;s>=0;s--)a[s]===0?(r=r.diffAdd(n,i),n=n.dbl()):(n=r.diffAdd(n,i),r=r.dbl());return n},vi.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},vi.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},vi.prototype.eq=function(e){return this.getX().cmp(e.getX())===0},vi.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},vi.prototype.getX=function(){return this.normalize(),this.x.fromRed()};var uhe=ns,kc=Sc,mF=Zt,yx=gx,fhe=uhe.assert;function ol(e){this.twisted=(e.a|0)!==1,this.mOneA=this.twisted&&(e.a|0)===-1,this.extended=this.mOneA,yx.call(this,"edwards",e),this.a=new kc(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new kc(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new kc(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),fhe(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(e.c|0)===1}mF(ol,yx);var hhe=ol;ol.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},ol.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},ol.prototype.jpoint=function(e,t,r,n){return this.point(e,t,r,n)},ol.prototype.pointFromX=function(e,t){e=new kc(e,16),e.red||(e=e.toRed(this.red));var r=e.redSqr(),n=this.c2.redSub(this.a.redMul(r)),i=this.one.redSub(this.c2.redMul(this.d).redMul(r)),a=n.redMul(i.redInvm()),s=a.redSqrt();if(s.redSqr().redSub(a).cmp(this.zero)!==0)throw new Error("invalid point");var o=s.fromRed().isOdd();return(t&&!o||!t&&o)&&(s=s.redNeg()),this.point(e,s)},ol.prototype.pointFromY=function(e,t){e=new kc(e,16),e.red||(e=e.toRed(this.red));var r=e.redSqr(),n=r.redSub(this.c2),i=r.redMul(this.d).redMul(this.c2).redSub(this.a),a=n.redMul(i.redInvm());if(a.cmp(this.zero)===0){if(t)throw new Error("invalid point");return this.point(this.zero,e)}var s=a.redSqrt();if(s.redSqr().redSub(a).cmp(this.zero)!==0)throw new Error("invalid point");return s.fromRed().isOdd()!==t&&(s=s.redNeg()),this.point(s,e)},ol.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();
1981var t=e.x.redSqr(),r=e.y.redSqr(),n=t.redMul(this.a).redAdd(r),i=this.c2.redMul(this.one.redAdd(this.d.redMul(t).redMul(r)));return n.cmp(i)===0};function Kr(e,t,r,n,i){yx.BasePoint.call(this,e,"projective"),t===null&&r===null&&n===null?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new kc(t,16),this.y=new kc(r,16),this.z=n?new kc(n,16):this.curve.one,this.t=i&&new kc(i,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}mF(Kr,yx.BasePoint),ol.prototype.pointFromJSON=function(e){return Kr.fromJSON(this,e)},ol.prototype.point=function(e,t,r,n){return new Kr(this,e,t,r,n)},Kr.fromJSON=function(e,t){return new Kr(e,t[0],t[1],t[2])},Kr.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},Kr.prototype.isInfinity=function(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)},Kr.prototype._extDbl=function(){var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var n=this.curve._mulA(e),i=this.x.redAdd(this.y).redSqr().redISub(e).redISub(t),a=n.redAdd(t),s=a.redSub(r),o=n.redSub(t),c=i.redMul(s),l=a.redMul(o),u=i.redMul(o),d=s.redMul(a);return this.curve.point(c,l,d,u)},Kr.prototype._projDbl=function(){var e=this.x.redAdd(this.y).redSqr(),t=this.x.redSqr(),r=this.y.redSqr(),n,i,a,s,o,c;if(this.curve.twisted){s=this.curve._mulA(t);var l=s.redAdd(r);this.zOne?(n=e.redSub(t).redSub(r).redMul(l.redSub(this.curve.two)),i=l.redMul(s.redSub(r)),a=l.redSqr().redSub(l).redSub(l)):(o=this.z.redSqr(),c=l.redSub(o).redISub(o),n=e.redSub(t).redISub(r).redMul(c),i=l.redMul(s.redSub(r)),a=l.redMul(c))}else s=t.redAdd(r),o=this.curve._mulC(this.z).redSqr(),c=s.redSub(o).redSub(o),n=this.curve._mulC(e.redISub(s)).redMul(c),i=this.curve._mulC(s).redMul(t.redISub(r)),a=s.redMul(c);return this.curve.point(n,i,a)},Kr.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},Kr.prototype._extAdd=function(e){var t=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),r=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),n=this.t.redMul(this.curve.dd).redMul(e.t),i=this.z.redMul(e.z.redAdd(e.z)),a=r.redSub(t),s=i.redSub(n),o=i.redAdd(n),c=r.redAdd(t),l=a.redMul(s),u=o.redMul(c),d=a.redMul(c),p=s.redMul(o);return this.curve.point(l,u,p,d)},Kr.prototype._projAdd=function(e){var t=this.z.redMul(e.z),r=t.redSqr(),n=this.x.redMul(e.x),i=this.y.redMul(e.y),a=this.curve.d.redMul(n).redMul(i),s=r.redSub(a),o=r.redAdd(a),c=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(n).redISub(i),l=t.redMul(s).redMul(c),u,d;return this.curve.twisted?(u=t.redMul(o).redMul(i.redSub(this.curve._mulA(n))),d=s.redMul(o)):(u=t.redMul(o).redMul(i.redSub(n)),d=this.curve._mulC(s).redMul(o)),this.curve.point(l,u,d)},Kr.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},Kr.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},Kr.prototype.mulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!1)},Kr.prototype.jmulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!0)},Kr.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},Kr.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},Kr.prototype.getX=function(){return this.normalize(),this.x.fromRed()},Kr.prototype.getY=function(){return this.normalize(),this.y.fromRed()},Kr.prototype.eq=function(e){return this===e||this.getX().cmp(e.getX())===0&&this.getY().cmp(e.getY())===0},Kr.prototype.eqXToP=function(e){var t=e.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(t)===0)return!0;for(var r=e.clone(),n=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(t.redIAdd(n),this.x.cmp(t)===0)return!0}},Kr.prototype.toP=Kr.prototype.normalize,Kr.prototype.mixedAdd=Kr.prototype.add,function(e){var t=e;
1981t.base=gx,t.short=ohe,t.mont=che,t.edwards=hhe}(H8);var vx={},ib={},gr={},dhe=Bs,phe=Zt;gr.inherits=phe;function mhe(e,t){return(e.charCodeAt(t)&64512)!==55296||t<0||t+1>=e.length?!1:(e.charCodeAt(t+1)&64512)===56320}function ghe(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if(typeof e=="string")if(t){if(t==="hex")for(e=e.replace(/[^a-z0-9]+/ig,""),e.length%2!==0&&(e="0"+e),i=0;i<e.length;i+=2)r.push(parseInt(e[i]+e[i+1],16))}else for(var n=0,i=0;i<e.length;i++){var a=e.charCodeAt(i);a<128?r[n++]=a:a<2048?(r[n++]=a>>6|192,r[n++]=a&63|128):mhe(e,i)?(a=65536+((a&1023)<<10)+(e.charCodeAt(++i)&1023),r[n++]=a>>18|240,r[n++]=a>>12&63|128,r[n++]=a>>6&63|128,r[n++]=a&63|128):(r[n++]=a>>12|224,r[n++]=a>>6&63|128,r[n++]=a&63|128)}else for(i=0;i<e.length;i++)r[i]=e[i]|0;return r}gr.toArray=ghe;function bhe(e){for(var t="",r=0;r<e.length;r++)t+=bF(e[r].toString(16));return t}gr.toHex=bhe;function gF(e){var t=e>>>24|e>>>8&65280|e<<8&16711680|(e&255)<<24;return t>>>0}gr.htonl=gF;function yhe(e,t){for(var r="",n=0;n<e.length;n++){var i=e[n];t==="little"&&(i=gF(i)),r+=yF(i.toString(16))}return r}gr.toHex32=yhe;function bF(e){return e.length===1?"0"+e:e}gr.zero2=bF;function yF(e){return e.length===7?"0"+e:e.length===6?"00"+e:e.length===5?"000"+e:e.length===4?"0000"+e:e.length===3?"00000"+e:e.length===2?"000000"+e:e.length===1?"0000000"+e:e}gr.zero8=yF;function vhe(e,t,r,n){var i=r-t;dhe(i%4===0);for(var a=new Array(i/4),s=0,o=t;s<a.length;s++,o+=4){var c;n==="big"?c=e[o]<<24|e[o+1]<<16|e[o+2]<<8|e[o+3]:c=e[o+3]<<24|e[o+2]<<16|e[o+1]<<8|e[o],a[s]=c>>>0}return a}gr.join32=vhe;function whe(e,t){for(var r=new Array(e.length*4),n=0,i=0;n<e.length;n++,i+=4){var a=e[n];t==="big"?(r[i]=a>>>24,r[i+1]=a>>>16&255,r[i+2]=a>>>8&255,r[i+3]=a&255):(r[i+3]=a>>>24,r[i+2]=a>>>16&255,r[i+1]=a>>>8&255,r[i]=a&255)}return r}gr.split32=whe;function xhe(e,t){return e>>>t|e<<32-t}gr.rotr32=xhe;function _he(e,t){return e<<t|e>>>32-t}gr.rotl32=_he;function She(e,t){return e+t>>>0}gr.sum32=She;function khe(e,t,r){return e+t+r>>>0}gr.sum32_3=khe;function Ehe(e,t,r,n){return e+t+r+n>>>0}gr.sum32_4=Ehe;function Mhe(e,t,r,n,i){return e+t+r+n+i>>>0}gr.sum32_5=Mhe;function Ahe(e,t,r,n){var i=e[t],a=e[t+1],s=n+a>>>0,o=(s<n?1:0)+r+i;e[t]=o>>>0,e[t+1]=s}gr.sum64=Ahe;function Che(e,t,r,n){var i=t+n>>>0,a=(i<t?1:0)+e+r;return a>>>0}gr.sum64_hi=Che;function The(e,t,r,n){var i=t+n;return i>>>0}gr.sum64_lo=The;function jhe(e,t,r,n,i,a,s,o){var c=0,l=t;l=l+n>>>0,c+=l<t?1:0,l=l+a>>>0,c+=l<a?1:0,l=l+o>>>0,c+=l<o?1:0;var u=e+r+i+s+c;return u>>>0}gr.sum64_4_hi=jhe;function Ihe(e,t,r,n,i,a,s,o){var c=t+n+a+o;return c>>>0}gr.sum64_4_lo=Ihe;function Ohe(e,t,r,n,i,a,s,o,c,l){var u=0,d=t;d=d+n>>>0,u+=d<t?1:0,d=d+a>>>0,u+=d<a?1:0,d=d+o>>>0,u+=d<o?1:0,d=d+l>>>0,u+=d<l?1:0;var p=e+r+i+s+c+u;return p>>>0}gr.sum64_5_hi=Ohe;function Bhe(e,t,r,n,i,a,s,o,c,l){var u=t+n+a+o+l;return u>>>0}gr.sum64_5_lo=Bhe;function Rhe(e,t,r){var n=t<<32-r|e>>>r;return n>>>0}gr.rotr64_hi=Rhe;function Nhe(e,t,r){var n=e<<32-r|t>>>r;return n>>>0}gr.rotr64_lo=Nhe;function Fhe(e,t,r){return e>>>r}gr.shr64_hi=Fhe;function Phe(e,t,r){var n=e<<32-r|t>>>r;return n>>>0}gr.shr64_lo=Phe;var B0={},vF=gr,zhe=Bs;function wx(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}B0.BlockHash=wx,wx.prototype.update=function(e,t){if(e=vF.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){e=this.pending;var r=e.length%this._delta8;this.pending=e.slice(e.length-r,e.length),this.pending.length===0&&(this.pending=null),e=vF.join32(e,0,e.length-r,this.endian);for(var n=0;n<e.length;n+=this._delta32)this._update(e,n,n+this._delta32)}return this},wx.prototype.digest=function(e){return this.update(this._pad()),zhe(this.pending===null),this._digest(e)},wx.prototype._pad=function(){var e=this.pendingTotal,t=this._delta8,r=t-(e+this.padLength)%t,n=new Array(r+this.padLength);n[0]=128;for(var i=1;i<r;i++)n[i]=0;if(e<<=3,this.endian==="big"){for(var a=8;a<this.padLength;a++)n[i++]=0;n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=e>>>24&255,n[i++]=e>>>16&255,n[i++]=e>>>8&255,n[i++]=e&255}else for(n[i++]=e&255,n[i++]=e>>>8&255,n[i++]=e>>>16&255,n[i++]=e>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,a=8;a<this.padLength;a++)n[i++]=0;return n};var R0={},ll={},Lhe=gr,cl=Lhe.rotr32;function Dhe(e,t,r,n){if(e===0)return wF(t,r,n);if(e===1||e===3)return _F(t,r,n);if(e===2)return xF(t,r,n)}ll.ft_1=Dhe;function wF(e,t,r){return e&t^~e&r}ll.ch32=wF;function xF(e,t,r){return e&t^e&r^t&r}ll.maj32=xF;function _F(e,t,r){return e^t^r}ll.p32=_F;function Uhe(e){return cl(e,2)^cl(e,13)^cl(e,22)}ll.s0_256=Uhe;function qhe(e){return cl(e,6)^cl(e,11)^cl(e,25)}ll.s1_256=qhe;function Vhe(e){return cl(e,7)^cl(e,18)^e>>>3}ll.g0_256=Vhe;function Zhe(e){return cl(e,17)^cl(e,19)^e>>>10}ll.g1_256=Zhe;var N0=gr,$he=B0,Hhe=ll,K8=N0.rotl32,ab=N0.sum32,Whe=N0.sum32_5,Khe=Hhe.ft_1,SF=$he.BlockHash,Ghe=[1518500249,1859775393,2400959708,3395469782];function ul(){if(!(this instanceof ul))return new ul;SF.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}N0.inherits(ul,SF);var Yhe=ul;ul.blockSize=512,ul.outSize=160,ul.hmacStrength=80,ul.padLength=64,ul.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=K8(r[n-3]^r[n-8]^r[n-14]^r[n-16],1);var i=this.h[0],a=this.h[1],s=this.h[2],o=this.h[3],c=this.h[4];for(n=0;n<r.length;n++){var l=~~(n/20),u=Whe(K8(i,5),Khe(l,a,s,o),c,r[n],Ghe[l]);c=o,o=s,s=K8(a,30),a=i,i=u}this.h[0]=ab(this.h[0],i),this.h[1]=ab(this.h[1],a),this.h[2]=ab(this.h[2],s),this.h[3]=ab(this.h[3],o),this.h[4]=ab(this.h[4],c)},ul.prototype._digest=function(e){return e==="hex"?N0.toHex32(this.h,"big"):N0.split32(this.h,"big")};var F0=gr,Xhe=B0,P0=ll,Jhe=Bs,po=F0.sum32,Qhe=F0.sum32_4,ede=F0.sum32_5,tde=P0.ch32,rde=P
vendor: 8,378 bytes, line 1981
19810.maj32,nde=P0.s0_256,ide=P0.s1_256,ade=P0.g0_256,sde=P0.g1_256,kF=Xhe.BlockHash,ode=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function fl(){if(!(this instanceof fl))return new fl;kF.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=ode,this.W=new Array(64)}F0.inherits(fl,kF);var EF=fl;fl.blockSize=512,fl.outSize=256,fl.hmacStrength=192,fl.padLength=64,fl.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=Qhe(sde(r[n-2]),r[n-7],ade(r[n-15]),r[n-16]);var i=this.h[0],a=this.h[1],s=this.h[2],o=this.h[3],c=this.h[4],l=this.h[5],u=this.h[6],d=this.h[7];for(Jhe(this.k.length===r.length),n=0;n<r.length;n++){var p=ede(d,ide(c),tde(c,l,u),this.k[n],r[n]),w=po(nde(i),rde(i,a,s));d=u,u=l,l=c,c=po(o,p),o=s,s=a,a=i,i=po(p,w)}this.h[0]=po(this.h[0],i),this.h[1]=po(this.h[1],a),this.h[2]=po(this.h[2],s),this.h[3]=po(this.h[3],o),this.h[4]=po(this.h[4],c),this.h[5]=po(this.h[5],l),this.h[6]=po(this.h[6],u),this.h[7]=po(this.h[7],d)},fl.prototype._digest=function(e){return e==="hex"?F0.toHex32(this.h,"big"):F0.split32(this.h,"big")};var G8=gr,MF=EF;function Ec(){if(!(this instanceof Ec))return new Ec;MF.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}G8.inherits(Ec,MF);var lde=Ec;Ec.blockSize=512,Ec.outSize=224,Ec.hmacStrength=192,Ec.padLength=64,Ec.prototype._digest=function(e){return e==="hex"?G8.toHex32(this.h.slice(0,7),"big"):G8.split32(this.h.slice(0,7),"big")};var ja=gr,cde=B0,ude=Bs,hl=ja.rotr64_hi,dl=ja.rotr64_lo,AF=ja.shr64_hi,CF=ja.shr64_lo,zu=ja.sum64,Y8=ja.sum64_hi,X8=ja.sum64_lo,fde=ja.sum64_4_hi,hde=ja.sum64_4_lo,dde=ja.sum64_5_hi,pde=ja.sum64_5_lo,TF=cde.BlockHash,mde=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function mo(){if(!(this instanceof mo))return new mo;TF.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=mde,this.W=new Array(160)}ja.inherits(mo,TF);var jF=mo;mo.blockSize=1024,mo.outSize=512,mo.hmacStrength=192,mo.padLength=128,mo.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n<r.length;n+=2){var i=Mde(r[n-4],r[n-3]),a=Ade(r[n-4],r[n-3]),s=r[n-14],o=r[n-13],c=kde(r[n-30],r[n-29]),l=Ede(r[n-30],r[n-29]),u=r[n-32],d=r[n-31];r[n]=fde(i,a,s,o,c,l,u,d),r[n+1]=hde(i,a,s,o,c,l,u,d)}},mo.prototype._update=function(e,t){this._prepareBlock(e,t);var r=this.W,n=this.h[0],i=this.h[1],a=this.h[2],s=this.h[3],o=this.h[4],c=this.h[5],l=this.h[6],u=this.h[7],d=this.h[8],p=this.h[9],w=this.h[10],O=this.h[11],I=this.h[12],R=this.h[13],C=this.h[14],j=this.h[15];ude(this.k.length===r.length);for(var N=0;N<r.length;N+=2){var P=C,Z=j,X=_de(d,p),re=Sde(d,p),ne=gde(d,p,w,O,I),ae=bde(d,p,w,O,I,R),ue=this.k[N],m=this.k[N+1],A=r[N],f=r[N+1],g=dde(P,Z,X,re,ne,ae,ue,m,A,f),_=pde(P,Z,X,re,ne,ae,ue,m,A,f);P=wde(n,i),Z=xde(n,i),X=yde(n,i,a,s,o),re=vde(n,i,a,s,o,c);var B=Y8(P,Z,X,re),T=X8(P,Z,X,re);C=I,j=R,I=w,R=O,w=d,O=p,d=Y8(l,u,g,_),p=X8(u,u,g,_),l=o,u=c,o=a,c=s,a=n,s=i,n=Y8(g,_,B,T),i=X8(g,_,B,T)}zu(this.h,0,n,i),zu(this.h,2,a,s),zu(this.h,4,o,c),zu(this.h,6,l,u),zu(this.h,8,d,p),zu(this.h,10,w,O),zu(this.h,12,I,R),zu(this.h,14,C,j)},mo.prototype._digest=function(e){return e==="hex"?ja.toHex32(this.h,"big"):ja.split32(this.h,"big")};function gde(e,t,r,n,i){var a=e&r^~e&i;return a<0&&(a+=4294967296),a}function bde(e,t,r,n,i,a){var s=t&n^~t&a;return s<0&&(s+=4294967296),s}function yde(e,t,r,n,i){var a=e&r^e&i^r&i;return a<0&&(a+=4294967296),a}function vde(e,t,r,n,i,a){var s=t&n^t&a^n&a;return s<0&&(s+=4294967296),s}function wde(e,t){var r=hl(e,t,28),n=hl(t,e,2),i=hl(t,e,7),a=r^n^i;return a<0&&(a+=4294967296),a}function xde(e,t){var r=dl(e,t,28),n=dl(t,e,2),i=dl(t,e,7),a=r^n^i;return a<0&&(a+=4294967296),a}function _de(e,t){var r=hl(e,t,14),n=hl(e,t,18),i=hl(t,e,9),a=r^n^i;return a<0&&(a+=4294967296),a}function Sde(e,t){var r=dl(e,t,14),n=dl(e,t,18),i=dl(t,e,9),a=r^n^i;return a<0&&(a+=4294967296),a}function kde(e,t){var r=hl(e,t,1),n=hl(e,t,8),i=AF(e,t,7),a=r^n^i;return a<0&&(a+=4294967296),a}function Ede(e,t){var r=dl(e,t,1),n=dl(e,t,8),i=CF(e,t,7),a=r^n^i;return a<0&&(a+=4294967296),a}function Mde(e,t){var r=hl(e,t,19),n=hl(t,e,29),i=AF(e,t,6),a=r^n^i;return a<0&&(a+=4294967296),a}function Ade(e,t){var r=dl(e,t,19),n=dl(t,e,29),i=CF(e,t,6),a=r^n^i;return a<0&&(a+=4294967296),a}var J8=gr,IF=jF;function Mc(){if(!(this instanceof Mc))return new Mc;IF.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}J8.inherits(Mc,IF);var Cde=Mc;Mc.blockSize=1024,Mc.outSize=384,Mc.hmacStrength=192,Mc.padLength=128,Mc.prototype._digest=function(e){return e==="hex"?J8.toHex32(this.h.slice(0,12),"big"):J8.split32(this.h.slice(0,12),"big")},R0.sha1=Yhe,R0.sha224=lde,R0.sha256=EF,R0.sha384=Cde,R0.sha512=jF;var OF={},Sh=gr,Tde=B0,xx=Sh.rotl32,BF=Sh.sum32,sb=Sh.sum32_3,RF=Sh.sum32_4,NF=Tde.BlockHash;function pl(){if(!(this instanceof pl))return new pl;NF.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}Sh.inherits(pl,NF),OF.ripemd160=pl,pl.blockSize=512,pl.outSize=160,pl.hmacStrength=192,pl.padLength=64,pl.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],i=this.h[2],a=this.h[3],s=this.h[4],o=r,c=n,l=i,u=a,d=s,p=0;p<80;p++){var w=BF(xx(RF(r,FF(p,n,i,a),e[Ode[p]+t],jde(p)),Rde[p]),s);r=s,s=a,a=xx(i,10),i=n,n=w,w=BF(xx(RF(o,FF(79-p,c,l,u),e[Bde[p]+t],Ide(p)),Nde[p]),d),o=d,d=u,u=xx(l,10),l=c,c=w}w=sb(this.h[1],i,u),this.h[1]=sb(this.h[2],a,d),this.h[2]=sb(this.h[3],s,o),this.h[3]=sb(this.h[4],r,c),this.h[4]=sb(this.h[0],n,l),this.h[0]=w},pl.prototype._digest=function(e){return e==="hex"?Sh.toHex32(this.h,"little"):Sh.split32(this.h,"little")};function FF(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}
1981function jde(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function Ide(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}var Ode=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],Bde=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],Rde=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],Nde=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],Fde=gr,Pde=Bs;function z0(e,t,r){if(!(this instanceof z0))return new z0(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(Fde.toArray(t,r))}var zde=z0;z0.prototype._init=function(e){e.length>this.blockSize&&(e=new this.Hash().update(e).digest()),Pde(e.length<=this.blockSize);for(var t=e.length;t<this.blockSize;t++)e.push(0);for(t=0;t<e.length;t++)e[t]^=54;for(this.inner=new this.Hash().update(e),t=0;t<e.length;t++)e[t]^=106;this.outer=new this.Hash().update(e)},z0.prototype.update=function(e,t){return this.inner.update(e,t),this},z0.prototype.digest=function(e){return this.outer.update(this.inner.digest()),this.outer.digest(e)},function(e){var t=e;t.utils=gr,t.common=B0,t.sha=R0,t.ripemd=OF,t.hmac=zde,t.sha1=t.sha.sha1,t.sha256=t.sha.sha256,t.sha224=t.sha.sha224,t.sha384=t.sha.sha384,t.sha512=t.sha.sha512,t.ripemd160=t.ripemd.ripemd160}(ib);const PF=Nr(ib);var zF,LF;function Lde(){return LF||(LF=1,zF
vendor: 26,127 bytes, line 1981
1981={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}
1981),zF}(function(e){var t=e,r=ib,n=H8,i=ns,a=i.assert;function s(l){l.type==="short"?this.curve=new n.short(l):l.type==="edwards"?this.curve=new n.edwards(l):this.curve=new n.mont(l),this.g=this.curve.g,this.n=this.curve.n,this.hash=l.hash,a(this.g.validate(),"Invalid curve"),a(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}t.PresetCurve=s;function o(l,u){Object.defineProperty(t,l,{configurable:!0,enumerable:!0,get:function(){var d=new s(u);return Object.defineProperty(t,l,{configurable:!0,enumerable:!0,value:d}),d}})}o("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:r.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),o("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:r.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),o("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:r.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),o("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:r.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),o("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:r.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),o("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:r.sha256,gRed:!1,g:["9"]}),o("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:r.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});var c;try{c=Lde()}catch{c=void 0}o("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:r.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"}
1981,{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",c]})})(vx);var Dde=ib,kh=$8,DF=Bs;function Lu(e){if(!(this instanceof Lu))return new Lu(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=kh.toArray(e.entropy,e.entropyEnc||"hex"),r=kh.toArray(e.nonce,e.nonceEnc||"hex"),n=kh.toArray(e.pers,e.persEnc||"hex");DF(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var Ude=Lu;Lu.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i<this.V.length;i++)this.K[i]=0,this.V[i]=1;this._update(n),this._reseed=1,this.reseedInterval=281474976710656},Lu.prototype._hmac=function(){return new Dde.hmac(this.hash,this.K)},Lu.prototype._update=function(e){var t=this._hmac().update(this.V).update([0]);e&&(t=t.update(e)),this.K=t.digest(),this.V=this._hmac().update(this.V).digest(),e&&(this.K=this._hmac().update(this.V).update([1]).update(e).digest(),this.V=this._hmac().update(this.V).digest())},Lu.prototype.reseed=function(e,t,r,n){typeof t!="string"&&(n=r,r=t,t=null),e=kh.toArray(e,t),r=kh.toArray(r,n),DF(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},Lu.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof t!="string"&&(n=r,r=t,t=null),r&&(r=kh.toArray(r,n||"hex"),this._update(r));for(var i=[];i.length<e;)this.V=this._hmac().update(this.V).digest(),i=i.concat(this.V);var a=i.slice(0,e);return this._update(r),this._reseed++,kh.encode(a,t)};var qde=Sc,Vde=ns,Q8=Vde.assert;function Ji(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}var Zde=Ji;Ji.fromPublic=function(e,t,r){return t instanceof Ji?t:new Ji(e,{pub:t,pubEnc:r})},Ji.fromPrivate=function(e,t,r){return t instanceof Ji?t:new Ji(e,{priv:t,privEnc:r})},Ji.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},Ji.prototype.getPublic=function(e,t){return typeof e=="string"&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},Ji.prototype.getPrivate=function(e){return e==="hex"?this.priv.toString(16,2):this.priv},Ji.prototype._importPrivate=function(e,t){this.priv=new qde(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},Ji.prototype._importPublic=function(e,t){if(e.x||e.y){this.ec.curve.type==="mont"?Q8(e.x,"Need x coordinate"):(this.ec.curve.type==="short"||this.ec.curve.type==="edwards")&&Q8(e.x&&e.y,"Need both x and y coordinate"),this.pub=this.ec.curve.point(e.x,e.y);return}this.pub=this.ec.curve.decodePoint(e,t)},Ji.prototype.derive=function(e){return e.validate()||Q8(e.validate(),"public point not validated"),e.mul(this.priv).getX()},Ji.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},Ji.prototype.verify=function(e,t,r){return this.ec.verify(e,t,this,void 0,r)},Ji.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"};var _x=Sc,eS=ns,$de=eS.assert;function Sx(e,t){if(e instanceof Sx)return e;this._importDER(e,t)||($de(e.r&&e.s,"Signature without r or s"),this.r=new _x(e.r,16),this.s=new _x(e.s,16),e.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var Hde=Sx;function Wde(){this.place=0}function tS(e,t){var r=e[t.place++];if(!(r&128))return r;var n=r&15;if(n===0||n>4||e[t.place]===0)return!1;for(var i=0,a=0,s=t.place;a<n;a++,s++)i<<=8,i|=e[s],i>>>=0;return i<=127?!1:(t.place=s,i)}function UF(e){for(var t=0,r=e.length-1;!e[t]&&!(e[t+1]&128)&&t<r;)t++;return t===0?e:e.slice(t)}Sx.prototype._importDER=function(e,t){e=eS.toArray(e,t);var r=new Wde;if(e[r.place++]!==48)return!1;var n=tS(e,r);if(n===!1||n+r.place!==e.length||e[r.place++]!==2)return!1;var i=tS(e,r);if(i===!1||e[r.place]&128)return!1;var a=e.slice(r.place,i+r.place);if(r.place+=i,e[r.place++]!==2)return!1;var s=tS(e,r);if(s===!1||e.length!==s+r.place||e[r.place]&128)return!1;var o=e.slice(r.place,s+r.place);if(a[0]===0)if(a[1]&128)a=a.slice(1);else return!1;if(o[0]===0)if(o[1]&128)o=o.slice(1);else return!1;return this.r=new _x(a),this.s=new _x(o),this.recoveryParam=null,!0};function rS(e,t){if(t<128){e.push(t);return}var r=1+(Math.log(t)/Math.LN2>>>3);for(e.push(r|128);--r;)e.push(t>>>(r<<3)&255);e.push(t)}Sx.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(t[0]&128&&(t=[0].concat(t)),r[0]&128&&(r=[0].concat(r)),t=UF(t),r=UF(r);!r[0]&&!(r[1]&128);)r=r.slice(1);var n=[2];rS(n,t.length),n=n.concat(t),n.push(2),rS(n,r.length);var i=n.concat(r),a=[48];return rS(a,i.length),a=a.concat(i),eS.encode(a,e)};var nS,qF;function Kde(){if(qF)return nS;qF=1;var e=Sc,t=Ude,r=ns,n=vx,i=T8(),a=r.assert,s=Zde,o=Hde;function c(l){if(!(this instanceof c))return new c(l);typeof l=="string"&&(a(Object.prototype.hasOwnProperty.call(n,l),"Unknown curve "+l),l=n[l]),l instanceof n.PresetCurve&&(l={curve:l}),this.curve=l.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=l.curve.g,this.g.precompute(l.curve.n.bitLength()+1),this.hash=l.hash||l.curve.hash}return nS=c,c.prototype.keyPair=function(l){return new s(this,l)},c.prototype.keyFromPrivate=function(l,u){return s.fromPrivate(this,l,u)},c.prototype.keyFromPublic=function(l,u){return s.fromPublic(this,l,u)},c.prototype.genKeyPair=function(l){l||(l={});for(var u=new t({hash:this.hash,pers:l.pers,persEnc:l.persEnc||"utf8",entro
1981py:l.entropy||i(this.hash.hmacStrength),entropyEnc:l.entropy&&l.entropyEnc||"utf8",nonce:this.n.toArray()}),d=this.n.byteLength(),p=this.n.sub(new e(2));;){var w=new e(u.generate(d));if(!(w.cmp(p)>0))return w.iaddn(1),this.keyFromPrivate(w)}},c.prototype._truncateToN=function(l,u,d){var p;if(e.isBN(l)||typeof l=="number")l=new e(l,16),p=l.byteLength();else if(typeof l=="object")p=l.length,l=new e(l,16);else{var w=l.toString();p=w.length+1>>>1,l=new e(w,16)}typeof d!="number"&&(d=p*8);var O=d-this.n.bitLength();return O>0&&(l=l.ushrn(O)),!u&&l.cmp(this.n)>=0?l.sub(this.n):l},c.prototype.sign=function(l,u,d,p){typeof d=="object"&&(p=d,d=null),p||(p={}),u=this.keyFromPrivate(u,d),l=this._truncateToN(l,!1,p.msgBitLength);for(var w=this.n.byteLength(),O=u.getPrivate().toArray("be",w),I=l.toArray("be",w),R=new t({hash:this.hash,entropy:O,nonce:I,pers:p.pers,persEnc:p.persEnc||"utf8"}),C=this.n.sub(new e(1)),j=0;;j++){var N=p.k?p.k(j):new e(R.generate(this.n.byteLength()));if(N=this._truncateToN(N,!0),!(N.cmpn(1)<=0||N.cmp(C)>=0)){var P=this.g.mul(N);if(!P.isInfinity()){var Z=P.getX(),X=Z.umod(this.n);if(X.cmpn(0)!==0){var re=N.invm(this.n).mul(X.mul(u.getPrivate()).iadd(l));if(re=re.umod(this.n),re.cmpn(0)!==0){var ne=(P.getY().isOdd()?1:0)|(Z.cmp(X)!==0?2:0);return p.canonical&&re.cmp(this.nh)>0&&(re=this.n.sub(re),ne^=1),new o({r:X,s:re,recoveryParam:ne})}}}}}},c.prototype.verify=function(l,u,d,p,w){w||(w={}),l=this._truncateToN(l,!1,w.msgBitLength),d=this.keyFromPublic(d,p),u=new o(u,"hex");var O=u.r,I=u.s;if(O.cmpn(1)<0||O.cmp(this.n)>=0||I.cmpn(1)<0||I.cmp(this.n)>=0)return!1;var R=I.invm(this.n),C=R.mul(l).umod(this.n),j=R.mul(O).umod(this.n),N;return this.curve._maxwellTrick?(N=this.g.jmulAdd(C,d.getPublic(),j),N.isInfinity()?!1:N.eqXToP(O)):(N=this.g.mulAdd(C,d.getPublic(),j),N.isInfinity()?!1:N.getX().umod(this.n).cmp(O)===0)},c.prototype.recoverPubKey=function(l,u,d,p){a((3&d)===d,"The recovery param is more than two bits"),u=new o(u,p);var w=this.n,O=new e(l),I=u.r,R=u.s,C=d&1,j=d>>1;if(I.cmp(this.curve.p.umod(this.curve.n))>=0&&j)throw new Error("Unable to find sencond key candinate");j?I=this.curve.pointFromX(I.add(this.curve.n),C):I=this.curve.pointFromX(I,C);var N=u.r.invm(w),P=w.sub(O).mul(N).umod(w),Z=R.mul(N).umod(w);return this.g.mulAdd(P,I,Z)},c.prototype.getKeyRecoveryParam=function(l,u,d,p){if(u=new o(u,p),u.recoveryParam!==null)return u.recoveryParam;for(var w=0;w<4;w++){var O;try{O=this.recoverPubKey(l,u,w)}catch{continue}if(O.eq(d))return w}throw new Error("Unable to find valid recovery factor")},nS}var ob=ns,VF=ob.assert,ZF=ob.parseBytes,L0=ob.cachedProperty;function wi(e,t){this.eddsa=e,this._secret=ZF(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=ZF(t.pub)}wi.fromPublic=function(e,t){return t instanceof wi?t:new wi(e,{pub:t})},wi.fromSecret=function(e,t){return t instanceof wi?t:new wi(e,{secret:t})},wi.prototype.secret=function(){return this._secret},L0(wi,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())}),L0(wi,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())}),L0(wi,"privBytes",function(){var e=this.eddsa,t=this.hash(),r=e.encodingLength-1,n=t.slice(0,e.encodingLength);return n[0]&=248,n[r]&=127,n[r]|=64,n}),L0(wi,"priv",function(){return this.eddsa.decodeInt(this.privBytes())}),L0(wi,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()}),L0(wi,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)}),wi.prototype.sign=function(e){return VF(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},wi.prototype.verify=function(e,t){return this.eddsa.verify(e,t,this)},wi.prototype.getSecret=function(e){return VF(this._secret,"KeyPair is public only"),ob.encode(this.secret(),e)},wi.prototype.getPublic=function(e){return ob.encode(this.pubBytes(),e)};var Gde=wi,Yde=Sc,kx=ns,$F=kx.assert,Ex=kx.cachedProperty,Xde=kx.parseBytes;function Eh(e,t){this.eddsa=e,typeof t!="object"&&(t=Xde(t)),Array.isArray(t)&&($F(t.length===e.encodingLength*2,"Signature has invalid size"),t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),$F(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof Yde&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}Ex(Eh,"S",function(){return this.eddsa.decodeInt(this.Sencoded())}),Ex(Eh,"R",function(){return this.eddsa.decodePoint(this.Rencoded())}),Ex(Eh,"Rencoded",function(){return this.eddsa.encodePoint(this.R())}),Ex(Eh,"Sencoded",function(){return this.eddsa.encodeInt(this.S())}),Eh.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},Eh.prototype.toHex=function(){return kx.encode(this.toBytes(),"hex").toUpperCase()};var Jde=Eh,Qde=ib,e0e=vx,D0=ns,t0e=D0.assert,HF=D0.parseBytes,WF=Gde,KF=Jde;function Ia(e){if(t0e(e==="ed25519","only tested with ed25519 so far"),!(this instanceof Ia))return new Ia(e);e=e0e[e].curve,this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=Qde.sha512}var r0e=Ia;Ia.prototype.sign=function(e,t){e=HF(e);var r=this.keyFromSecret(t),n=this.hashInt(r.messagePrefix(),e),i=this.g.mul(n),a=this.encodePoint(i),s=this.hashInt(a,r.pubBytes(),e).mul(r.priv()),o=n.add(s).umod(this.curve.n);return this.makeSignature({R:i,S:o,Rencoded:a})},Ia.prototype.verify=function(e,t,r){if(e=HF(e),t=this.makeSignature(t),t.S().gte(t.eddsa.curve.n)||t.S().isNeg())return!1;var n=this.keyFromPublic(r),i=this.hashInt(t.Rencoded(),n.pubBytes(),e),a=this.g.mul(t.S()),s=t.R().add(n.pub().mul(i));return s.eq(a)},Ia.prototype.hashInt=function(){for(var e=this.hash(),t=0;t<arguments.length;t++)e.update(arguments[t]);return D0.intFromLE(e.digest()).umod(this.curve.n)},Ia.prototype.keyFromPublic=function(e){return WF.fromPublic(this,e)},Ia.prototype.keyFromSecret=function(e){return WF.fromSecret(this,e)},Ia.prototype.makeSignature=function(e){return e instanceof KF?e:new KF(this,e)},Ia.prototype.encodePoint=function(e){var t=e.getY().toArray("le",this.encodingLength);return t[this.encodingLength-1]|=e.getX().isOdd()?128:0,t},Ia.prototype.decodePoint=function(e){e=D0.parseBytes(e);var t=e.length-1,r=e.slice(0,t).concat(e[t]&-129),n=(e[t]&128)!==0,i=D0.intFromLE(r);return this.curve.pointFromY(i,n)},Ia.prototype.encodeInt=function(e){return e.toArray("le",this.encodingLength)},Ia.prototype.decodeInt=function(e){return D0.intFromLE(e)},Ia.prototype.isPoint=function(e){return e instanceof this.pointClass};var GF;function iS(){return GF||(GF=1,function(e){var t=e;t.version=nhe.version,t.utils=ns,t.rand=T8(),t.curve=H8,t.curves=vx,t.ec=Kde(),t.eddsa=r0e}(dF)),dF}var aS={exports:{}};aS.exports,function(e){(function(t,r){function n(f,g){if(!f)throw new Error(g||"Assertion failed")}function i(f,g){f.super_=g;var _=function(){};_.prototype=g.prototype,f.prototype=new _,f.prototype.constructor=f}function a(f,g,_){if(a.isBN(f))return f;this.negative=0,this.words=null,this.length=0,this.red=null,f!==null&&((g==="le"||g==="be")&&(_=g,g=10),this._init(f||0,g||10,_||"be"))}
vendor: 44,393 bytes, lines 1981-1983
1981typeof t=="object"?t.exports=a:r.BN=a,a.BN=a,a.wordSize=26;var s;try{typeof window<"u"&&typeof window.Buffer<"u"?s=window.Buffer:s=ji.Buffer}catch{}a.isBN=function(f){return f instanceof a?!0:f!==null&&typeof f=="object"&&f.constructor.wordSize===a.wordSize&&Array.isArray(f.words)},a.max=function(f,g){return f.cmp(g)>0?f:g},a.min=function(f,g){return f.cmp(g)<0?f:g},a.prototype._init=function(f,g,_){if(typeof f=="number")return this._initNumber(f,g,_);if(typeof f=="object")return this._initArray(f,g,_);g==="hex"&&(g=16),n(g===(g|0)&&g>=2&&g<=36),f=f.toString().replace(/\s+/g,"");var B=0;f[0]==="-"&&(B++,this.negative=1),B<f.length&&(g===16?this._parseHex(f,B,_):(this._parseBase(f,g,B),_==="le"&&this._initArray(this.toArray(),g,_)))},a.prototype._initNumber=function(f,g,_){f<0&&(this.negative=1,f=-f),f<67108864?(this.words=[f&67108863],this.length=1):f<4503599627370496?(this.words=[f&67108863,f/67108864&67108863],this.length=2):(n(f<9007199254740992),this.words=[f&67108863,f/67108864&67108863,1],this.length=3),_==="le"&&this._initArray(this.toArray(),g,_)},a.prototype._initArray=function(f,g,_){if(n(typeof f.length=="number"),f.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(f.length/3),this.words=new Array(this.length);for(var B=0;B<this.length;B++)this.words[B]=0;var T,S,h=0;if(_==="be")for(B=f.length-1,T=0;B>=0;B-=3)S=f[B]|f[B-1]<<8|f[B-2]<<16,this.words[T]|=S<<h&67108863,this.words[T+1]=S>>>26-h&67108863,h+=24,h>=26&&(h-=26,T++);else if(_==="le")for(B=0,T=0;B<f.length;B+=3)S=f[B]|f[B+1]<<8|f[B+2]<<16,this.words[T]|=S<<h&67108863,this.words[T+1]=S>>>26-h&67108863,h+=24,h>=26&&(h-=26,T++);return this._strip()};function o(f,g){var _=f.charCodeAt(g);if(_>=48&&_<=57)return _-48;if(_>=65&&_<=70)return _-55;if(_>=97&&_<=102)return _-87;n(!1,"Invalid character in "+f)}function c(f,g,_){var B=o(f,_);return _-1>=g&&(B|=o(f,_-1)<<4),B}a.prototype._parseHex=function(f,g,_){this.length=Math.ceil((f.length-g)/6),this.words=new Array(this.length);for(var B=0;B<this.length;B++)this.words[B]=0;var T=0,S=0,h;if(_==="be")for(B=f.length-1;B>=g;B-=2)h=c(f,g,B)<<T,this.words[S]|=h&67108863,T>=18?(T-=18,S+=1,this.words[S]|=h>>>26):T+=8;else{var x=f.length-g;for(B=x%2===0?g+1:g;B<f.length;B+=2)h=c(f,g,B)<<T,this.words[S]|=h&67108863,T>=18?(T-=18,S+=1,this.words[S]|=h>>>26):T+=8}this._strip()};function l(f,g,_,B){for(var T=0,S=0,h=Math.min(f.length,_),x=g;x<h;x++){var v=f.charCodeAt(x)-48;T*=B,v>=49?S=v-49+10:v>=17?S=v-17+10:S=v,n(v>=0&&S<B,"Invalid character"),T+=S}return T}a.prototype._parseBase=function(f,g,_){this.words=[0],this.length=1;for(var B=0,T=1;T<=67108863;T*=g)B++;B--,T=T/g|0;for(var S=f.length-_,h=S%B,x=Math.min(S,S-h)+_,v=0,F=_;F<x;F+=B)v=l(f,F,F+B,g),this.imuln(T),this.words[0]+v<67108864?this.words[0]+=v:this._iaddn(v);if(h!==0){var Q=1;for(v=l(f,F,f.length,g),F=0;F<h;F++)Q*=g;this.imuln(Q),this.words[0]+v<67108864?this.words[0]+=v:this._iaddn(v)}this._strip()},a.prototype.copy=function(f){f.words=new Array(this.length);for(var g=0;g<this.length;g++)f.words[g]=this.words[g];f.length=this.length,f.negative=this.negative,f.red=this.red};function u(f,g){f.words=g.words,f.length=g.length,f.negative=g.negative,f.red=g.red}if(a.prototype._move=function(f){u(f,this)},a.prototype.clone=function(){var f=new a(null);return this.copy(f),f},a.prototype._expand=function(f){for(;this.length<f;)this.words[this.length++]=0;return this},a.prototype._strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol<"u"&&typeof Symbol.for=="function")try{a.prototype[Symbol.for("nodejs.util.inspect.custom")]=d}catch{a.prototype.inspect=d}else a.prototype.inspect=d;function d(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var p=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],w=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],O=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(f,g){f=f||10,g=g|0||1;var _;if(f===16||f==="hex"){_="";for(var B=0,T=0,S=0;S<this.length;S++){var h=this.words[S],x=((h<<B|T)&16777215).toString(16);T=h>>>24-B&16777215,B+=2,B>=26&&(B-=26,S--),T!==0||S!==this.length-1?_=p[6-x.length]+x+_:_=x+_}for(T!==0&&(_=T.toString(16)+_);_.length%g!==0;)_="0"+_;return this.negative!==0&&(_="-"+_),_}if(f===(f|0)&&f>=2&&f<=36){var v=w[f],F=O[f];_="";var Q=this.clone();for(Q.negative=0;!Q.isZero();){var G=Q.modrn(F).toString(f);Q=Q.idivn(F),Q.isZero()?_=G+_:_=p[v-G.length]+G+_}for(this.isZero()&&(_="0"+_);_.length%g!==0;)_="0"+_;return this.negative!==0&&(_="-"+_),_}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var f=this.words[0];return this.length===2?f+=this.words[1]*67108864:this.length===3&&this.words[2]===1?f+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-f:f},a.prototype.toJSON=function(){return this.toString(16,2)},s&&(a.prototype.toBuffer=function(f,g){return this.toArrayLike(s,f,g)}),a.prototype.toArray=function(f,g){return this.toArrayLike(Array,f,g)};var I=function(f,g){return f.allocUnsafe?f.allocUnsafe(g):new f(g)};a.prototype.toArrayLike=function(f,g,_){this._strip();var B=this.byteLength(),T=_||Math.max(1,B);n(B<=T,"byte array longer than desired length"),n(T>0,"Requested array length <= 0");var S=I(f,T),h=g==="le"?"LE":"BE";return this["_toArrayLike"+h](S,B),S},a.prototype._toArrayLikeLE=function(f,g){for(var _=0,B=0,T=0,S=0;T<this.length;T++){var h=this.words[T]<<S|B;f[_++]=h&255,_<f.length&&(f[_++]=h>>8&255),_<f.length&&(f[_++]=h>>16&255),S===6?(_<f.length&&(f[_++]=h>>24&255),B=0,S=0):(B=h>>>24,S+=2)}if(_<f.length)for(f[_++]=B;_<f.length;)f[_++]=0},a.prototype._toArrayLikeBE=function(f,g){for(var _=f.length-1,B=0,T=0,S=0;T<this.length;T++){var h=this.words[T]<<S|B;f[_--]=h&255,_>=0&&(f[_--]=h>>8&255),_>=0&&(f[_--]=h>>16&255),S===6?(_>=0&&(f[_--]=h>>24&255),B=0,S=0):(B=h>>>24,S+=2)}if(_>=0)for(f[_--]=B;_>=0;)f[_--]=0},Math.clz32?a.prototype._countBits=function(f){return 32-Math.clz32(f)}:a.prototype._countBits=function(f){var g=f,_=0;return g>=4096&&(_+=13,g>>>=13),g>=64&&(_+=7,g>>>=7),g>=8&&(_+=4,g>>>=4),g>=2&&(_+=2,g>>>=2),_+g},a.prototype._zeroBits=function(f){if(f===0)return 26;var g=f,_=0;return g&8191||(_+=13,g>>>=13),g&127||(_+=7,g>>>=7),g&15||(_+=4,g>>>=4),g&3||(_+=2,g>>>=2),g&1||_++,_},a.prototype.bitLength=function(){var f=this.words[this.length-1],g=this._countBits(f);return(this.length-1)*26+g};function R(f){for(var g=new Array(f.bitLength()),_=0;_<g.length;_++){var B=_/26|0,T=_%26;g[_]=f.words[B]>>>T&1}return g}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var f=0,g=0;g<this.length;g++){var _=this._zeroBits(this.words[g]);if(f+=_,_!==26)break}return f},a.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},a.prototype.toTwos=function(f){return this.negative!==0?this.abs().inotn(f).iaddn(1):this.clone()},a.prototype.fromTwos=function(f){return this.testn(f-1)?this.notn(f).iaddn(1).ineg():this.clone()},a.prototype.isNeg=function(){return this.negative!==0},a.prototype.neg=function(){return this.clone().ineg()},a.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},a.prototype.iuor=function(f){for(;this.length<f.length;)this.words[this.length++]=0;for(var g=0;g<f.length;g++)this.words[g]=this.words[g]|f.words[g];return this._strip()},a.prototype.ior=function(f){return n((this.negative|f.negative)===0),this.iuor(f)},a.prototype.or=function(f){return this.length>f.length?this.clone().ior(f):f.clone().ior(this)},a.prototype.uor=function(f){return this.length>f.length?this.clone().iuor(f):f.clone().iuor(this)},a.prototype.iuand=function(f){var g;this.length>f.length?g=f:g=this;for(var _=0;_<g.length;_++)this.words[_]=this.words[_]&f.words[_];return this.length=g.length,this._strip()},a.prototype.iand=function(f){return n((this.negative|f.negative)===0),this.iuand(f)},a.prototype.and=function(f){return this.length>f.length?this.clone().iand(f):f.clone().iand(this)},a.prototype.uand=function(f){return this.length>f.length?this.clone().iuand(f):f.clone().iuand(this)},a.prototype.iuxor=function(f){var g,_;this.length>f.length?(g=this,_=f):(g=f,_=this);for(var B=0;B<_.length;B++)this.words[B]=g.words[B]^_.words[B];if(this!==g)for(;B<g.length;B++)this.words[B]=g.words[B];return this.length=g.length,this._strip()},a.prototype.ixor=function(f){return n((this.negative|f.negative)===0),this.iuxor(f)},a.prototype.xor=function(f){return this.length>f.length?this.clone().ixor(f):f.clone().ixor(this)},a.prototype.uxor=function(f){return this.length>f.length?this.clone().iuxor(f):f.clone().iuxor(this)},a.prototype.inotn=function(f){n(typeof f=="number"&&f>=0);var g=Math.ceil(f/26)|0,_=f%26;this._expand(g),_>0&&g--;for(var B=0;B<g;B++)this.words[B]=~this.words[B]&67108863;return _>0&&(this.words[B]=~this.words[B]&67108863>>26-_),this._strip()},a.prototype.notn=function(f){return this.clone().inotn(f)},a.prototype.setn=function(f,g){n(typeof f=="number"&&f>=0);var _=f/26|0,B=f%26;return this._expand(_+1),g?this.words[_]=this.words[_]|1<<B:this.words[_]=this.words[_]&~(1<<B),this._strip()},a.prototype.iadd=function(f){var g;if(this.negative!==0&&f.negative===0)return this.negative=0,g=this.isub(f),this.negative^=1,this._normSign();if(this.negative===0&&f.negative!==0)return f.negative=0,g=this.isub(f),f.negative=1,g._normSign();var _,B;this.length>f.length?(_=this,B=f):(_=f,B=this);for(var T=0,S=0;S<B.length;S++)g=(_.words[S]|0)+(B.words[S]|0)+T,this.words[S]=g&67108863,T=g>>>26;for(;T!==0&&S<_.length;S++)g=(_.words[S]|0)+T,this.words[S]=g&67108863,T=g>>>26;if(this.length=_.length,T!==0)this.words[this.length]=T,this.length++;else if(_!==this)for(;S<_.length;S++)this.words[S]=_.words[S];return this},a.prototype.add=function(f){var g;return f.negative!==0&&this.negative===0?(f.negative=0,g=this.sub(f),f.negative^=1,g):f.negative===0&&this.negative!==0?(this.negative=0,g=f.sub(this),this.negative=1,g):this.length>f.length?this.clone().iadd(f):f.clone().iadd(this)},a.prototype.isub=function(f){if(f.negative!==0){f.negative=0;var g=this.iadd(f);return f.negative=1,g._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(f),this.negative=1,this._normSign();var _=this.cmp(f);if(_===0)return this.negative=0,this.length=1,this.words[0]=0,this;var B,T;_>0?(B=this,T=f):(B=f,T=this);for(var S=0,h=0;h<T.length;h++)g=(B.words[h]|0)-(T.words[h]|0)+S,S=g>>26,this.words[h]=g&67108863;for(;S!==0&&h<B.length;h++)g=(B.words[h]|0)+S,S=g>>26,this.words[h]=g&67108863;if(S===0&&h<B.length&&B!==this)for(;h<B.length;h++)this.words[h]=B.words[h];return this.length=Math.max(this.length,h),B!==this&&(this.negative=1),this._strip()},a.prototype.sub=function(f){return this.clone().isub(f)};function C(f,g,_){_.negative=g.negative^f.negative;var B=f.length+g.length|0;_.length=B,B=B-1|0;var T=f.words[0]|0,S=g.words[0]|0,h=T*S,x=h&67108863,v=h/67108864|0;_.words[0]=x;for(var F=1;F<B;F++){for(var Q=v>>>26,G=v&67108863,J=Math.min(F,g.length-1),Y=Math.max(0,F-f.length+1);Y<=J;Y++){var V=F-Y|0;T=f.words[V]|0,S=g.words[Y]|0,h=T*S+G,Q+=h/67108864|0,G=h&67108863}_.words[F]=G|0,v=Q|0}return v!==0?_.words[F]=v|0:_.length--,_._strip()}var j=function(f,g,_){var B=f.words,T=g.words,S=_.words,h=0,x,v,F,Q=B[0]|0,G=Q&8191,J=Q>>>13,Y=B[1]|0,V=Y&8191,W=Y>>>13,ce=B[2]|0,pe=ce&8191,ee=ce>>>13,se=B[3]|0,ve=se&8191,_e=se>>>13,Ue=B[4]|0,xe=Ue&8191,Te=Ue>>>13,$e=B[5]|0,Ae=$e&8191,De=$e>>>13,Ke=B[6]|0,ut=Ke&8191,Fe=Ke>>>13,ge=B[7]|0,we=ge&8191,ke=ge>>>13,Ne=B[8]|0,z=Ne&8191,H=Ne>>>13,k=B[9]|0,L=k&8191,q=k>>>13,ie=T[0]|0,fe=ie&8191,be=ie>>>13,Ce=T[1]|0,ze=Ce&8191,Ie=Ce>>>13,qe=T[2]|0,it=qe&8191,Ve=qe>>>13,zt=T[3]|0,wt=zt&8191,Xe=zt>>>13,Tt=T[4]|0,jt=Tt&8191,Je=Tt>>>13,Et=T[5]|0,Bt=Et&8191,Qe=Et>>>13,Lt=T[6]|0,Dt=Lt&8191,et=Lt>>>13,Rt=T[7]|0,Mt=Rt&8191,Ye=Rt>>>13,Nt=T[8]|0,Ft=Nt&8191,tt=Nt>>>13,At=T[9]|0,It=At&8191,xt=At>>>13;_.negative=f.negative^g.negative,_.length=19,x=Math.imul(G,fe),v=Math.imul(G,be),v=v+Math.imul(J,fe)|0,F=Math.imul(J,be);var oi=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(oi>>>26)|0,oi&=67108863,x=Math.imul(V,fe),v=Math.imul(V,be),v=v+Math.imul(W,fe)|0,F=Math.imul(W,be),x=x+Math.imul(G,ze)|0,v=v+Math.imul(G,Ie)|0,v=v+Math.imul(J,ze)|0,F=F+Math.imul(J,Ie)|0;var li=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(li>>>26)|0,li&=67108863,x=Math.imul(pe,fe),v=Math.imul(pe,be),v=v+Math.imul(ee,fe)|0,F=Math.imul(ee,be),x=x+Math.imul(V,ze)|0,v=v+Math.imul(V,Ie)|0,v=v+Math.imul(W,ze)|0,F=F+Math.imul(W,Ie)|0,x=x+Math.imul(G,it)|0,v=v+Math.imul(G,Ve)|0,v=v+Math.imul(J,it)|0,F=F+Math.imul(J,Ve)|0;var ci=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(ci>>>26)|0,ci&=67108863,x=Math.imul(ve,fe),v=Math.imul(ve,be),v=v+Math.imul(_e,fe)|0,F=Math.imul(_e,be),x=x+Math.imul(pe,ze)|0,v=v+Math.imul(pe,Ie)|0,v=v+Math.imul(ee,ze)|0,F=F+Math.imul(ee,Ie)|0,x=x+Math.imul(V,it)|0,v=v+Math.imul(V,Ve)|0,v=v+Math.imul(W,it)|0,F=F+Math.imul(W,Ve)|0,x=x+Math.imul(G,wt)|0,v=v+Math.imul(G,Xe)|0,v=v+Math.imul(J,wt)|0,F=F+Math.imul(J,Xe)|0;var Rn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Rn>>>26)|0,Rn&=67108863,x=Math.imul(xe,fe),v=Math.imul(xe,be),v=v+Math.imul(Te,fe)|0,F=Math.imul(Te,be),x=x+Math.imul(ve,ze)|0,v=v+Math.imul(ve,Ie)|0,v=v+Math.imul(_e,ze)|0,F=F+Math.imul(_e,Ie)|0,x=x+Math.imul(pe,it)|0,v=v+Math.imul(pe,Ve)|0,v=v+Math.imul(ee,it)|0,F=F+Math.imul(ee,Ve)|0,x=x+Math.imul(V,wt)|0,v=v+Math.imul(V,Xe)|0,v=v+Math.imul(W,wt)|0,F=F+Math.imul(W,Xe)|0,x=x+Math.imul(G,jt)|0,v=v+Math.imul(G,Je)|0,v=v+Math.imul(J,jt)|0,F=F+Math.imul(J,Je)|0;var Sn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Sn>>>26)|0,Sn&=67108863,x=Math.imul(Ae,fe),v=Math.imul(Ae,be),v=v+Math.imul(De,fe)|0,F=Math.imul(De,be),x=x+Math.imul(xe,ze)|0,v=v+Math.imul(xe,Ie)|0,v=v+Math.imul(Te,ze)|0,F=F+Math.imul(Te,Ie)|0,x=x+Math.imul(ve,it)|0,v=v+Math.imul(ve,Ve)|0,v=v+Math.imul(_e,it)|0,F=F+Math.imul(_e,Ve)|0,x=x+Math.imul(pe,wt)|0,v=v+Math.imul(pe,Xe)|0,v=v+Math.imul(ee,wt)|0,F=F+Math.imul(ee,Xe)|0,x=x+Math.imul(V,jt)|0,v=v+Math.imul(V,Je)|0,v=v+Math.imul(W,jt)|0,F=F+Math.imul(W,Je)|0,x=x+Math.imul(G,Bt)|0,v=v+Math.imul(G,Qe)|0,v=v+Math.imul(J,Bt)|0,F=F+Math.imul(J,Qe)|0;var zr=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(zr>>>26)|0,zr&=67108863,x=Math.imul(ut,fe),v=Math.imul(ut,be),v=v+Math.imul(Fe,fe)|0,F=Math.imul(Fe,be),x=x+Math.imul(Ae,ze)|0,v=v+Math.imul(Ae,Ie)|0,v=v+Math.imul(De,ze)|0,F=F+Math.imul(De,Ie)|0,x=x+Math.imul(xe,it)|0,v=v+Math.imul(xe,Ve)|0,v=v+Math.imul(Te,it)|0,F=F+Math.imul(Te,Ve)|0,x=x+Math.imul(ve,wt)|0,v=v+Math.imul(ve,Xe)|0,v=v+Math.imul(_e,wt)|0,F=F+Math.imul(_e,Xe)|0,x=x+Math.imul(pe,jt)|0,v=v+Math.imul(pe,Je)|0,v=v+Math.imul(ee,jt)|0,F=F+Math.imul(ee,Je)|0,x=x+Math.imul(V,Bt)|0,v=v+Math.imul(V,Qe)|0,v=v+Math.imul(W,Bt)|0,F=F+Math.imul(W,Qe)|0,x=x+Math.imul(G,Dt)|0,v=v+Math.imul(G,et)|0,v=v+Math.imul(J,Dt)|0,F=F+Math.imul(J,et)|0;var mn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(mn>>>26)|0,mn&=67108863,x=Math.imul(we,fe),v=Math.imul(we,be),v=v+Math.imul(ke,fe)|0,F=Math.imul(ke,be),x=x+Math.imul(ut,ze)|0,v=v+Math.imul(ut,Ie)|0,v=v+Math.imul(Fe,ze)|0,F=F+Math.imul(Fe,Ie)|0,x=x+Math.imul(Ae,it)|0,v=v+Math.imul(Ae,Ve)|0,v=v+Math.imul(De,it)|0,F=F+Math.imul(De,Ve)|0,x=x+Math.imul(xe,wt)|0,v=v+Math.imul(xe,Xe)|0,v=v+Math.imul(Te,wt)|0,F=F+Math.imul(Te,Xe)|0,x=x+Math.imul(ve,jt)|0,v=v+Math.imul(ve,Je)|0,v=v+Math.imul(_e,jt)|0,F=F+Math.imul(_e,Je)|0,x=x+Math.imul(pe,Bt)|0,v=v+Math.imul(pe,Qe)|0,v=v+Math.imul(ee,Bt)|0,F=F+Math.imul(ee,Qe)|0,x=x+Math.imul(V,Dt)|0,v=v+Math.imul(V,et)|0,v=v+Math.imul(W,Dt)|0,F=F+Math.imul(W,et)|0,x=x+Math.imul(G,Mt)|0,v=v+Math.imul(G,Ye)|0,v=v+Math.imul(J,Mt)|0,F=F+Math.imul(J,Ye)|0;var Nn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Nn>>>26)|0,Nn&=67108863,x=Math.imul(z,fe),v=Math.imul(z,be),v=v+Math.imul(H,fe)|0,F=Math.imul(H,be),x=x+Math.imul(we,ze)|0,v=v+Math.imul(we,Ie)|0,v=v+Math.imul(ke,ze)|0,F=F+Math.imul(ke,Ie)|0,x=x+Math.imul(ut,it)|0,v=v+Math.imul(ut,Ve)|0,v=v+Math.imul(Fe,it)|0,F=F+Math.imul(Fe,Ve)|0,x=x+Math.imul(Ae,wt)|0,v=v+Math.imul(Ae,Xe)|0,v=v+Math.imul(De,wt)|0,F=F+Math.imul(De,Xe)|0,x=x+Math.imul(xe,jt)|0,v=v+Math.imul(xe,Je)|0,v=v+Math.imul(Te,jt)|0,F=F+Math.imul(Te,Je)|0,x=x+Math.imul(ve,Bt)|0,v=v+Math.imul(ve,Qe)|0,v=v+Math.imul(_e,Bt)|0,F=F+Math.imul(_e,Qe)|0,x=x+Math.imul(pe,Dt)|0,v=v+Math.imul(pe,et)|0,v=v+Math.imul(ee,Dt)|0,F=F+Math.imul(ee,et)|0,x=x+Math.imul(V,Mt)|0,v=v+Math.imul(V,Ye)|0,v=v+Math.imul(W,Mt)|0,F=F+Math.imul(W,Ye)|0,x=x+Math.imul(G,Ft)|0,v=v+Math.imul(G,tt)|0,v=v+Math.imul(J,Ft)|0,F=F+Math.imul(J,tt)|0;var Kn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Kn>>>26)|0,Kn&=67108863,x=Math.imul(L,fe),v=Math.imul(L,be),v=v+Math.imul(q,fe)|0,F=Math.imul(q,be),x=x+Math.imul(z,ze)|0,v=v+Math.imul(z,Ie)|0,v=v+Math.imul(H,ze)|0,F=F+Math.imul(H,Ie)|0,x=x+Math.imul(we,it)|0,v=v+Math.imul(we,Ve)|0,v=v+Math.imul(ke,it)|0,F=F+Math.imul(ke,Ve)|0,x=x+Math.imul(ut,wt)|0,v=v+Math.imul(ut,Xe)|0,v=v+Math.imul(Fe,wt)|0,F=F+Math.imul(Fe,Xe)|0,x=x+Math.imul(Ae,jt)|0,v=v+Math.imul(Ae,Je)|0,v=v+Math.imul(De,jt)|0,F=F+Math.imul(De,Je)|0,x=x+Math.imul(xe,Bt)|0,v=v+Math.imul(xe,Qe)|0,v=v+Math.imul(Te,Bt)|0,F=F+Math.imul(Te,Qe)|0,x=x+Math.imul(ve,Dt)|0,v=v+Math.imul(ve,et)|0,v=v+Math.imul(_e,Dt)|0,F=F+Math.imul(_e,et)|0,x=x+Math.imul(pe,Mt)|0,v=v+Math.imul(pe,Ye)|0,v=v+Math.imul(ee,Mt)|0,F=F+Math.imul(ee,Ye)|0,x=x+Math.imul(V,Ft)|0,v=v+Math.imul(V,tt)|0,v=v+Math.imul(W,Ft)|0,F=F+Math.imul(W,tt)|0,x=x+Math.imul(G,It)|0,v=v+Math.imul(G,xt)|0,v=v+Math.imul(J,It)|0,F=F+Math.imul(J,xt)|0;var sn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(sn>>>26)|0,sn&=67108863,x=Math.imul(L,ze),v=Math.imul(L,Ie),v=v+Math.imul(q,ze)|0,F=Math.imul(q,Ie),x=x+Math.imul(z,it)|0,v=v+Math.imul(z,Ve)|0,v=v+Math.imul(H,it)|0,F=F+Math.imul(H,Ve)|0,x=x+Math.imul(we,wt)|0,v=v+Math.imul(we,Xe)|0,v=v+Math.imul(ke,wt)|0,F=F+Math.imul(ke,Xe)|0,x=x+Math.imul(ut,jt)|0,v=v+Math.imul(ut,Je)|0,v=v+Math.imul(Fe,jt)|0,F=F+Math.imul(Fe,Je)|0,x=x+Math.imul(Ae,Bt)|0,v=v+Math.imul(Ae,Qe)|0,v=v+Math.imul(De,Bt)|0,F=F+Math.imul(De,Qe)|0,x=x+Math.imul(xe,Dt)|0,v=v+Math.imul(xe,et)|0,v=v+Math.imul(Te,Dt)|0,F=F+Math.imul(Te,et)|0,x=x+Math.imul(ve,Mt)|0,v=v+Math.imul(ve,Ye)|0,v=v+Math.imul(_e,Mt)|0,F=F+Math.imul(_e,Ye)|0,x=x+Math.imul(pe,Ft)|0,v=v+Math.imul(pe,tt)|0,v=v+Math.imul(ee,Ft)|0,F=F+Math.imul(ee,tt)|0,x=x+Math.imul(V,It)|0,v=v+Math.imul(V,xt)|0,v=v+Math.imul(W,It)|0,F=F+Math.imul(W,xt)|0;var Fn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Fn>>>26)|0,Fn&=67108863,x=Math.imul(L,it),v=Math.imul(L,Ve),v=v+Math.imul(q,it)|0,F=Math.imul(q,Ve),x=x+Math.imul(z,wt)|0,v=v+Math.imul(z,Xe)|0,v=v+Math.imul(H,wt)|0,F=F+Math.imul(H,Xe)|0,x=x+Math.imul(we,jt)|0,v=v+Math.imul(we,Je)|0,v=v+Math.imul(ke,jt)|0,F=F+Math.imul(ke,Je)|0,x=x+Math.imul(ut,Bt)|0,v=v+Math.imul(ut,Qe)|0,v=v+Math.imul(Fe,Bt)|0,F=F+Math.imul(Fe,Qe)|0,x=x+Math.imul(Ae,Dt)|0,v=v+Math.imul(Ae,et)|0,v=v+Math.imul(De,Dt)|0,F=F+Math.imul(De,et)|0,x=x+Math.imul(xe,Mt)|0,v=v+Math.imul(xe,Ye)|0,v=v+Math.imul(Te,Mt)|0,F=F+Math.imul(Te,Ye)|0,x=x+Math.imul(ve,Ft)|0,v=v+Math.imul(ve,tt)|0,v=v+Math.imul(_e,Ft)|0,F=F+Math.imul(_e,tt)|0,x=x+Math.imul(pe,It)|0,v=v+Math.imul(pe,xt)|0,v=v+Math.imul(ee,It)|0,F=F+Math.imul(ee,xt)|0;var Tn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Tn>>>26)|0,Tn&=67108863,x=Math.imul(L,wt),v=Math.imul(L,Xe),v=v+Math.imul(q,wt)|0,F=Math.imul(q,Xe),x=x+Math.imul(z,jt)|0,v=v+Math.imul(z,Je)|0,v=v+Math.imul(H,jt)|0,F=F+Math.imul(H,Je)|0,x=x+Math.imul(we,Bt)|0,v=v+Math.imul(we,Qe)|0,v=v+Math.imul(ke,Bt)|0,F=F+Math.imul(ke,Qe)|0,x=x+Math.imul(ut,Dt)|0,v=v+Math.imul(ut,et)|0,v=v+Math.imul(Fe,Dt)|0,F=F+Math.imul(Fe,et)|0,x=x+Math.imul(Ae,Mt)|0,v=v+Math.imul(Ae,Ye)|0,v=v+Math.imul(De,Mt)|0,F=F+Math.imul(De,Ye)|0,x=x+Math.imul(xe,Ft)|0,v=v+Math.imul(xe,tt)|0,v=v+Math.imul(Te,Ft)|0,F=F+Math.imul(Te,tt)|0,x=x+Math.imul(ve,It)|0,v=v+Math.imul(ve,xt)|0,v=v+Math.imul(_e,It)|0,F=F+Math.imul(_e,xt)|0;var Pn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Pn>>>26)|0,Pn&=67108863,x=Math.imul(L,jt),v=Math.imul(L,Je),v=v+Math.imul(q,jt)|0,F=Math.imul(q,Je),x=x+Math.imul(z,Bt)|0,v=v+Math.imul(z,Qe)|0,v=v+Math.imul(H,Bt)|0,F=F+Math.imul(H,Qe)|0,x=x+Math.imul(we,Dt)|0,v=v+Math.imul(we,et)|0,v=v+Math.imul(ke,Dt)|0,F=F+Math.imul(ke,et)|0,x=x+Math.imul(ut,Mt)|0,v=v+Math.imul(ut,Ye)|0,v=v+Math.imul(Fe,Mt)|0,F=F+Math.imul(Fe,Ye)|0,x=x+Math.imul(Ae,Ft)|0,v=v+Math.imul(Ae,tt)|0,v=v+Math.imul(De,Ft)|0,F=F+Math.imul(De,tt)|0,x=x+Math.imul(xe,It)|0,v=v+Math.imul(xe,xt)|0,v=v+Math.imul(Te,It)|0,F=F+Math.imul(Te,xt)|0;var Gn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Gn>>>26)|0,Gn&=67108863,x=Math.imul(L,Bt),v=Math.imul(L,Qe),v=v+Math.imul(q,Bt)|0,F=Math.imul(q,Qe),x=x+Math.imul(z,Dt)|0,v=v+Math.imul(z,et)|0,v=v+Math.imul(H,Dt)|0,F=F+Math.imul(H,et)|0,x=x+Math.imul(we,Mt)|0,v=v+Math.imul(we,Ye)|0,v=v+Math.imul(ke,Mt)|0,F=F+Math.imul(ke,Ye)|0,x=x+Math.imul(ut,Ft)|0,v=v+Math.imul(ut,tt)|0,v=v+Math.imul(Fe,Ft)|0,F=F+Math.imul(Fe,tt)|0,x=x+Math.imul(Ae,It)|0,v=v+Math.imul(Ae,xt)|0,v=v+Math.imul(De,It)|0,F=F+Math.imul(De,xt)|0;var Zr=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Zr>>>26)|0,Zr&=67108863,x=Math.imul(L,Dt),v=Math.imul(L,et),v=v+Math.imul(q,Dt)|0,F=Math.imul(q,et),x=x+Math.imul(z,Mt)|0,v=v+Math.imul(z,Ye)|0,v=v+Math.imul(H,Mt)|0,F=F+Math.imul(H,Ye)|0,x=x+Math.imul(we,Ft)|0,v=v+Math.imul(we,tt)|0,v=v+Math.imul(ke,Ft)|0,F=F+Math.imul(ke,tt)|0,x=x+Math.imul(ut,It)|0,v=v+Math.imul(ut,xt)|0,v=v+Math.imul(Fe,It)|0,F=F+Math.imul(Fe,xt)|0;var Yn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Yn>>>26)|0,Yn&=67108863,x=Math.imul(L,Mt),v=Math.imul(L,Ye),v=v+Math.imul(q,Mt)|0,F=Math.imul(q,Ye),x=x+Math.imul(z,Ft)|0,v=v+Math.imul(z,tt)|0,v=v+Math.imul(H,Ft)|0,F=F+Math.imul(H,tt)|0,x=x+Math.imul(we,It)|0,v=v+Math.imul(we,xt)|0,v=v+Math.imul(ke,It)|0,F=F+Math.imul(ke,xt)|0;var zn=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(zn>>>26)|0,zn&=67108863,x=Math.imul(L,Ft),v=Math.imul(L,tt),v=v+Math.imul(q,Ft)|0,F=Math.imul(q,tt),x=x+Math.imul(z,It)|0,v=v+Math.imul(z,xt)|0,v=v+Math.imul(H,It)|0,F=F+Math.imul(H,xt)|0;var Ua=(h+x|0)+((v&8191)<<13)|0;h=(F+(v>>>13)|0)+(Ua>>>26)|0,Ua&=67108863,x=Math.imul(L,It),v=Math.imul(L,xt),v=v+Math.imul(q,It)|0,F=Math.imul(q,xt);var Do=(h+x|0)+((v&8191)<<13)|0;return h=(F+(v>>>13)|0)+(Do>>>26)|0,Do&=67108863,S[0]=oi,S[1]=li,S[2]=ci,S[3]=Rn,S[4]=Sn,S[5]=zr,S[6]=mn,S[7]=Nn,S[8]=Kn,S[9]=sn,S[10]=Fn,S[11]=Tn,S[12]=Pn,S[13]=Gn,S[14]=Zr,S[15]=Yn,S[16]=zn,S[17]=Ua,S[18]=Do,h!==0&&(S[19]=h,_.length++),_};Math.imul||(j=C);function N(f,g,_){_.negative=g.negative^f.negative,_.length=f.length+g.length;for(var B=0,T=0,S=0;S<_.length-1;S++){var h=T;T=0;for(var x=B&67108863,v=Math.min(S,g.length-1),F=Math.max(0,S-f.length+1);F<=v;F++){var Q=S-F,G=f.words[Q]|0,J=g.words[F]|0,Y=G*J,V=Y&67108863;h=h+(Y/67108864|0)|0,V=V+x|0,x=V&67108863,h=h+(V>>>26)|0,T+=h>>>26,h&=67108863}_.words[S]=x,B=h,h=T}return B!==0?_.words[S]=B:_.length--,_._strip()}function P(f,g,_){return N(f,g,_)}a.prototype.mulTo=function(f,g){var _,B=this.length+f.length;return this.length===10&&f.length===10?_=j(this,f,g):B<63?_=C(this,f,g):B<1024?_=N(this,f,g):_=P(this,f,g),_},a.prototype.mul=function(f){var g=new a(null);return g.words=new Array(this.length+f.length),this.mulTo(f,g)},a.prototype.mulf=function(f){var g=new a(null);return g.words=new Array(this.length+f.length),P(this,f,g)},a.prototype.imul=function(f){return this.clone().mulTo(f,this)},a.prototype.imuln=function(f){var g=f<0;g&&(f=-f),n(typeof f=="number"),n(f<67108864);for(var _=0,B=0;B<this.length;B++){var T=(this.words[B]|0)*f,S=(T&67108863)+(_&67108863);_>>=26,_+=T/67108864|0,_+=S>>>26,this.words[B]=S&67108863}return _!==0&&(this.words[B]=_,this.length++),g?this.ineg():this},a.prototype.muln=function(f){return this.clone().imuln(f)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(f){var g=R(f);if(g.length===0)return new a(1);for(var _=this,B=0;B<g.length&&g[B]===0;B++,_=_.sqr());if(++B<g.length)for(var T=_.sqr();B<g.length;B++,T=T.sqr())g[B]!==0&&(_=_.mul(T));return _},a.prototype.iushln=function(f){n(typeof f=="number"&&f>=0);var g=f%26,_=(f-g)/26,B=67108863>>>26-g<<26-g,T;if(g!==0){var S=0;for(T=0;T<this.length;T++){var h=this.words[T]&B,x=(this.words[T]|0)-h<<g;this.words[T]=x|S,S=h>>>26-g}S&&(this.words[T]=S,this.length++)}if(_!==0){for(T=this.length-1;T>=0;T--)this.words[T+_]=this.words[T];for(T=0;T<_;T++)this.words[T]=0;this.length+=_}return this._strip()},a.prototype.ishln=function(f){return n(this.negative===0),this.iushln(f)},a.prototype.iushrn=function(f,g,_){n(typeof f=="number"&&f>=0);var B;g?B=(g-g%26)/26:B=0;var T=f%26,S=Math.min((f-T)/26,this.length),h=67108863^67108863>>>T<<T,x=_;if(B-=S,B=Math.max(0,B),x){for(var v=0;v<S;v++)x.words[v]=this.words[v];x.length=S}if(S!==0)if(this.length>S)for(this.length-=S,v=0;v<this.length;v++)this.words[v]=this.words[v+S];else this.words[0]=0,this.length=1;var F=0;for(v=this.length-1;v>=0&&(F!==0||v>=B);v--){var Q=this.words[v]|0;this.words[v]=F<<26-T|Q>>>T,F=Q&h}return x&&F!==0&&(x.words[x.length++]=F),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},a.prototype.ishrn=function(f,g,_){return n(this.negative===0),this.iushrn(f,g,_)},a.prototype.shln=function(f){return this.clone().ishln(f)},a.prototype.ushln=function(f){return this.clone().iushln(f)},a.prototype.shrn=function(f){return this.clone().ishrn(f)},a.prototype.ushrn=function(f){return this.clone().iushrn(f)},a.prototype.testn=function(f){n(typeof f=="number"&&f>=0);var g=f%26,_=(f-g)/26,B=1<<g;if(this.length<=_)return!1;var T=this.words[_];return!!(T&B)},a.prototype.imaskn=function(f){n(typeof f=="number"&&f>=0);var g=f%26,_=(f-g)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=_)return this;if(g!==0&&_++,this.length=Math.min(_,this.length),g!==0){var B=67108863^67108863>>>g<<g;this.words[this.length-1]&=B}return this._strip()},a.prototype.maskn=function(f){return this.clone().imaskn(f)},a.prototype.iaddn=function(f){return n(typeof f=="number"),n(f<67108864),f<0?this.isubn(-f):this.negative!==0?this.length===1&&(this.words[0]|0)<=f?(this.words[0]=f-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(f),this.negative=1,this):this._iaddn(f)},a.prototype._iaddn=function(f){this.words[0]+=f;for(var g=0;g<this.length&&this.words[g]>=67108864;g++)this.words[g]-=67108864,g===this.length-1?this.words[g+1]=1:this.words[g+1]++;return this.length=Math.max(this.length,g+1),this},a.prototype.isubn=function(f){if(n(typeof f=="number"),n(f<67108864),f<0)return this.iaddn(-f);if(this.negative!==0)return this.negative=0,this.iaddn(f),this.negative=1,this;if(this.words[0]-=f,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var g=0;g<this.length&&this.words[g]<0;g++)this.words[g]+=67108864,this.words[g+1]-=1;return this._strip()},a.prototype.addn=function(f){return this.clone().iaddn(f)},a.prototype.subn=function(f){return this.clone().isubn(f)},a.prototype.iabs=function(){return this.negative=0,this},a.prototype.abs=function(){return this.clone().iabs()},a.prototype._ishlnsubmul=function(f,g,_){var B=f.length+_,T;this._expand(B);var S,h=0;for(T=0;T<f.length;T++){S=(this.words[T+_]|0)+h;var x=(f.words[T]|0)*g;S-=x&67108863,h=(S>>26)-(x/67108864|0),this.words[T+_]=S&67108863}for(;T<this.length-_;T++)S=(this.words[T+_]|0)+h,h=S>>26,this.words[T+_]=S&67108863;if(h===0)return this._strip();for(n(h===-1),h=0,T=0;T<this.length;T++)S=-(this.words[T]|0)+h,h=S>>26,this.words[T]=S&67108863;return this.negative=1,this._strip()},a.prototype._wordDiv=function(f,g){var _=this.length-f.length,B=this.clone(),T=f,S=T.words[T.length-1]|0,h=this._countBits(S);_=26-h,_!==0&&(T=T.ushln(_),B.iushln(_),S=T.words[T.length-1]|0);var x=B.length-T.length,v;if(g!=="mod"){v=new a(null),v.length=x+1,v.words=new Array(v.length);for(var F=0;F<v.length;F++)v.words[F]=0}var Q=B.clone()._ishlnsubmul(T,1,x);Q.negative===0&&(B=Q,v&&(v.words[x]=1));for(var G=x-1;G>=0;G--){var J=(B.words[T.length+G]|0)*67108864+(B.words[T.length+G-1]|0);for(J=Math.min(J/S|0,67108863),B._ishlnsubmul(T,J,G);B.negative!==0;)J--,B.negative=0,B._ishlnsubmul(T,1,G),B.isZero()||(B.negative^=1);v&&(v.words[G]=J)}return v&&v._strip(),B._strip(),g!=="div"&&_!==0&&B.iushrn(_),{div:v||null,mod:B}},a.prototype.divmod=function(f,g,_){if(n(!f.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var B,T,S;return this.negative!==0&&f.negative===0?(S=this.neg().divmod(f,g),g!=="mod"&&(B=S.div.neg()),g!=="div"&&(T=S.mod.neg(),_&&T.negative!==0&&T.iadd(f)),{div:B,mod:T}):this.negative===0&&f.negative!==0?(S=this.divmod(f.neg(),g),g!=="mod"&&(B=S.div.neg()),{div:B,mod:S.mod}):this.negative&f.negative?(S=this.neg().divmod(f.neg(),g),g!=="div"&&(T=S.mod.neg(),_&&T.negative!==0&&T.isub(f)),{div:S.div,mod:T}):f.length>this.length||this.cmp(f)<0?{div:new a(0),mod:this}:f.length===1?g==="div"?{div:this.divn(f.words[0]),mod:null}:g==="mod"?{div:null,mod:new a(this.modrn(f.words[0]))}:{div:this.divn(f.words[0]),mod:new a(this.modrn(f.words[0]))}:this._wordDiv(f,g)},a.prototype.div=function(f){return this.divmod(f,"div",!1).div},a.prototype.mod=function(f){return this.divmod(f,"mod",!1).mod},a.prototype.umod=function(f){return this.divmod(f,"mod",!0).mod},a.prototype.divRound=function(f){var g=this.divmod(f);if(g.mod.isZero())return g.div;var _=g.div.negative!==0?g.mod.isub(f):g.mod,B=f.ushrn(1),T=f.andln(1),S=_.cmp(B);return S<0||T===1&&S===0?g.div:g.div.negative!==0?g.div.isubn(1):g.div.iaddn(1)},a.prototype.modrn=function(f){var g=f<0;g&&(f=-f),n(f<=67108863);for(var _=67108864%f,B=0,T=this.length-1;T>=0;T--)B=(_*B+(this.words[T]|0))%f;return g?-B:B},a.prototype.modn=function(f){return this.modrn(f)},a.prototype.idivn=function(f){var g=f<0;g&&(f=-f),n(f<=67108863);for(var _=0,B=this.length-1;B>=0;B--){var T=(this.words[B]|0)+_*67108864;this.words[B]=T/f|0,_=T%f}return this._strip(),g?this.ineg():this},a.prototype.divn=function(f){return this.clone().idivn(f)},a.prototype.egcd=function(f){n(f.negative===0),n(!f.isZero());var g=this,_=f.clone();g.negative!==0?g=g.umod(f):g=g.clone();for(var B=new a(1),T=new a(0),S=new a(0),h=new a(1),x=0;g.isEven()&&_.isEven();)g.iushrn(1),_.iushrn(1),++x;for(var v=_.clone(),F=g.clone();!g.isZero();){for(var Q=0,G=1;!(g.words[0]&G)&&Q<26;++Q,G<<=1);if(Q>0)for(g.iushrn(Q);Q-- >0;)(B.isOdd()||T.isOdd())&&(B.iadd(v),T.isub(F)),B.iushrn(1),T.iushrn(1);for(var J=0,Y=1;!(_.words[0]&Y)&&J<26;++J,Y<<=1);if(J>0)for(_.iushrn(J);J-- >0;)(S.isOdd()||h.isOdd())&&(S.iadd(v),h.isub(F)),S.iushrn(1),h.iushrn(1);g.cmp(_)>=0?(g.isub(_),B.isub(S),T.isub(h)):(_.isub(g),S.isub(B),h.isub(T))}return{a:S,b:h,gcd:_.iushln(x)}},a.prototype._invmp=function(f){n(f.negative===0),n(!f.isZero());var g=this,_=f.clone();g.negative!==0?g=g.umod(f):g=g.clone();for(var B=new a(1),T=new a(0),S=_.clone();g.cmpn(1)>0&&_.cmpn(1)>0;){for(var h=0,x=1;!(g.words[0]&x)&&h<26;++h,x<<=1);if(h>0)for(g.iushrn(h);h-- >0;)B.isOdd()&&B.iadd(S),B.iushrn(1);for(var v=0,F=1;!(_.words[0]&F)&&v<26;++v,F<<=1);if(v>0)for(_.iushrn(v);v-- >0;)T.isOdd()&&T.iadd(S),T.iushrn(1);g.cmp(_)>=0?(g.isub(_),B.isub(T)):(_.isub(g),T.isub(B))}var Q;return g.cmpn(1)===0?Q=B:Q=T,Q.cmpn(0)<0&&Q.iadd(f),Q},a.prototype.gcd=function(f){if(this.isZero())return f.abs();if(f.isZero())return this.abs();var g=this.clone(),_=f.clone();g.negative=0,_.negative=0;for(var B=0;g.isEven()&&_.isEven();B++)g.iushrn(1),_.iushrn(1);do{for(;g.isEven();)g.iushrn(1);for(;_.isEven();)_.iushrn(1);var T=g.cmp(_);if(T<0){var S=g;g=_,_=S}else if(T===0||_.cmpn(1)===0)break;g.isub(_)}while(!0);return _.iushln(B)},a.prototype.invm=function(f){return this.egcd(f).a.umod(f)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(f){return this.words[0]&f},a.prototype.bincn=function(f){n(typeof f=="number");var g=f%26,_=(f-g)/26,B=1<<g;if(this.length<=_)return this._expand(_+1),this.words[_]|=B,this;for(var T=B,S=_;T!==0&&S<this.length;S++){var h=this.words[S]|0;h+=T,T=h>>>26,h&=67108863,this.words[S]=h}return T!==0&&(this.words[S]=T,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(f){var g=f<0;if(this.negative!==0&&!g)return-1;if(this.negative===0&&g)return 1;this._strip();var _;if(this.length>1)_=1;else{g&&(f=-f),n(f<=67108863,"Number is too big");var B=this.words[0]|0;_=B===f?0:B<f?-1:1}return this.negative!==0?-_|0:_},a.prototype.cmp=function(f){if(this.negative!==0&&f.negative===0)return-1;if(this.negative===0&&f.negative!==0)return 1;var g=this.ucmp(f);return this.negative!==0?-g|0:g},a.prototype.ucmp=function(f){if(this.length>f.length)return 1;if(this.length<f.length)return-1;for(var g=0,_=this.length-1;_>=0;_--){var B=this.words[_]|0,T=f.words[_]|0;if(B!==T){B<T?g=-1:B>T&&(g=1);break}}return g},a.prototype.gtn=function(f){return this.cmpn(f)===1},a.prototype.gt=function(f){return this.cmp(f)===1},a.prototype.gten=function(f){return this.cmpn(f)>=0},a.prototype.gte=function(f){return this.cmp(f)>=0},a.prototype.ltn=function(f){return this.cmpn(f)===-1},a.prototype.lt=function(f){return this.cmp(f)===-1},a.prototype.lten=function(f){return this.cmpn(f)<=0},a.prototype.lte=function(f){return this.cmp(f)<=0},a.prototype.eqn=function(f){return this.cmpn(f)===0},a.prototype.eq=function(f){return this.cmp(f)===0},a.red=function(f){return new m(f)},a.prototype.toRed=function(f){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),f.convertTo(this)._forceRed(f)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(f){return this.red=f,this},a.prototype.forceRed=function(f){return n(!this.red,"Already a number in reduction context"),this._forceRed(f)},a.prototype.redAdd=function(f){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,f)},a.prototype.redIAdd=function(f){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,f)},a.prototype.redSub=function(f){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,f)},a.prototype.redISub=function(f){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,f)},a.prototype.redShl=function(f){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,f)},a.prototype.redMul=function(f){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,f),this.red.mul(this,f)},a.prototype.redIMul=function(f){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,f),this.red.imul(this,f)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(f){return n(this.red&&!f.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,f)};var Z={k256:null,p224:null,p192:null,p25519:null};function X(f,g){this.name=f,this.p=new a(g,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}X.prototype._tmp=function(){var f=new a(null);return f.words=new Array(Math.ceil(this.n/13)),f},X.prototype.ireduce=function(f){var g=f,_;do this.split(g,this.tmp),g=this.imulK(g),g=g.iadd(this.tmp),_=g.bitLength();while(_>this.n);var B=_<this.n?-1:g.ucmp(this.p);return B===0?(g.words[0]=0,g.length=1):B>0?g.isub(this.p):g.strip!==void 0?g.strip():g._strip(),g},X.prototype.split=function(f,g){f.iushrn(this.n,0,g)},X.prototype.imulK=function(f){return f.imul(this.k)};function re(){X.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(re,X),re.prototype.split=function(f,g){for(var _=4194303,B=Math.min(f.length,9),T=0;T<B;T++)g.words[T]=f.words[T];if(g.length=B,f.length<=9){f.words[0]=0,f.length=1;return}var S=f.words[9];for(g.words[g.length++]=S&_,T=10;T<f.length;T++){var h=f.words[T]|0;f.words[T-10]=(h&_)<<4|S>>>22,S=h}S>>>=22,f.words[T-10]=S,S===0&&f.length>10?f.length-=10:f.length-=9},re.prototype.imulK=function(f){f.words[f.length]=0,f.words[f.length+1]=0,f.length+=2;for(var g=0,_=0;_<f.length;_++){var B=f.words[_]|0;g+=B*977,f.words[_]=g&67108863,g=B*64+(g/67108864|0)}return f.words[f.length-1]===0&&(f.length--,f.words[f.length-1]===0&&f.length--),f};function ne(){X.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}i(ne,X);function ae(){X.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}i(ae,X);function ue(){X.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}i(ue,X),ue.prototype.imulK=function(f){for(var g=0,_=0;_<f.length;_++){var B=(f.words[_]|0)*19+g,T=B&67108863;B>>>=26,f.words[_]=T,g=B}return g!==0&&(f.words[f.length++]=g),f},a._prime=function(f){if(Z[f])return Z[f];var g;if(f==="k256")g=new re;else if(f==="p224")g=new ne;else if(f==="p192")g=new ae;else if(f==="p25519")g=new ue;else throw new Error("Unknown prime "+f);return Z[f]=g,g};function m(f){if(typeof f=="string"){var g=a._prime(f);this.m=g.p,this.prime=g}else n(f.gtn(1),"modulus must be greater than 1"),this.m=f,this.prime=null}m.prototype._verify1=function(f){n(f.negative===0,"red works only with positives"),n(f.red,"red works only with red numbers")},m.prototype._verify2=function(f,g){n((f.negative|g.negative)===0,"red works only with positives"),n(f.red&&f.red===g.red,"red works only with red numbers")},m.prototype.imod=function(f){return this.prime?this.prime.ireduce(f)._forceRed(this):(u(f,f.umod(this.m)._forceRed(this)),f)},m.prototype.neg=function(f){return f.isZero()?f.clone():this.m.sub(f)._forceRed(this)},m.prototype.add=function(f,g){this._verify2(f,g);var _=f.add(g);return _.cmp(this.m)>=0&&_.isub(this.m),_._forceRed(this)},m.prototype.iadd=function(f,g){this._verify2(f,g);var _=f.iadd(g);return _.cmp(this.m)>=0&&_.isub(this.m),_},m.prototype.sub=function(f,g){this._verify2(f,g);var _=f.sub(g);return _.cmpn(0)<0&&_.iadd(this.m),_._forceRed(this)},m.prototype.isub=function(f,g){this._verify2(f,g);var _=f.isub(g);return _.cmpn(0)<0&&_.iadd(this.m),_},m.prototype.shl=function(f,g){return this._verify1(f),this.imod(f.ushln(g))},m.prototype.imul=function(f,g){return this._verify2(f,g),this.imod(f.imul(g))},m.prototype.mul=function(f,g){return this._verify2(f,g),this.imod(f.mul(g))},m.prototype.isqr=function(f){return this.imul(f,f.clone())},m.prototype.sqr=function(f){return this.mul(f,f)},m.prototype.sqrt=function(f){if(f.isZero())return f.clone();var g=this.m.andln(3);if(n(g%2===1),g===3){var _=this.m.add(new a(1)).iushrn(2);return this.pow(f,_)}for(var B=this.m.subn(1),T=0;!B.isZero()&&B.andln(1)===0;)T++,B.iushrn(1);n(!B.isZero());var S=new a(1).toRed(this),h=S.redNeg(),x=this.m.subn(1).iushrn(1),v=this.m.bitLength();for(v=new a(2*v*v).toRed(this);this.pow(v,x).cmp(h)!==0;)v.redIAdd(h);for(var F=this.pow(v,B),Q=this.pow(f,B.addn(1).iushrn(1)),G=this.pow(f,B),J=T;G.cmp(S)!==0;){for(var Y=G,V=0;Y.cmp(S)!==0;V++)Y=Y.redSqr();n(V<J);var W=this.pow(F,new a(1).iushln(J-V-1));Q=Q.redMul(W),F=W.redSqr(),G=G.redMul(F),J=V}return Q},m.prototype.invm=function(f){var g=f._invmp(this.m);return g.negative!==0?(g.negative=0,this.imod(g).redNeg()):this.imod(g)},m.prototype.pow=function(f,g){if(g.isZero())return new a(1).toRed(this);if(g.cmpn(1)===0)return f.clone();var _=4,B=new Array(1<<_);B[0]=new a(1).toRed(this),B[1]=f;for(var T=2;T<B.length;T++)B[T]=this.mul(B[T-1],f);var S=B[0],h=0,x=0,v=g.bitLength()%26;for(v===0&&(v=26),T=g.length-1;T>=0;T--){for(var F=g.words[T],Q=v-1;Q>=0;Q--){var G=F>>Q&1;if(S!==B[0]&&(S=this.sqr(S)),G===0&&h===0){x=0;continue}h<<=1,h|=G,x++,!(x!==_&&(T!==0||Q!==0))&&(S=this.mul(S,B[h]),x=0,h=0)}v=26}return S},m.prototype.convertTo=function(f){var g=f.umod(this.m);return g===f?g.clone():g},m.prototype.convertFrom=function(f){var g=f.clone();return g.red=null,g},a.mont=function(f){return new A(f)};function A(f){m.call(this,f),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(A,m),A.prototype.convertTo=function(f){return this.imod(f.ushln(this.shift))},A.prototype.convertFrom=function(f){var g=this.imod(f.mul(this.rinv));return g.red=null,g},A.prototype.imul=function(f,g){if(f.isZero()||g.isZero())return f.words[0]=0,f.length=1,f;var _=f.imul(g),B=_.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),T=_.isub(B).iushrn(this.shift),S=T;return T.cmp(this.m)>=0?S=T.isub(this.m):T.cmpn(0)<0&&(S=T.iadd(this.m)),S._forceRed(this)},A.prototype.mul=function(f,g){if(f.isZero()||g.isZero())return new a(0)._forceRed(this);var _=f.mul(g),B=_.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),T=_.isub(B).iushrn(this.shift),S=T;return T.cmp(this.m)>=0?S=T.isub(this.m):T.cmpn(0)<0&&(S=T.iadd(this.m)),S._forceRed(this)},A.prototype.invm=function(f){var g=this.imod(f._invmp(this.m).mul(this.r2));return g._forceRed(this)}})(e,dt)}(aS);var YF=aS.exports,go={},XF={},JF={};const n0e={},i0e=Object.freeze(Object.defineProperty({__proto__:null,default:n0e},Symbol.toStringTag,{value:"Module"})),a0e=Cf(i0e);var QF;function s0e(){return QF||(QF=1,function(e){var t=cb(),r=Zt,n=e;n.define=function(a,s){return new i(a,s)};function i(a,s){this.name=a,this.body=s,this.decoders={},this.encoders={}}i.prototype._createNamed=function(a){var s;try{s=a0e.runInThisContext("(function "+this.name+`(entity) {
1982  this._initNamed(entity);
1983})`)}catch{s=function(o){this._initNamed(o)}}return r(s,a),s.prototype._initNamed=function(o){a.call(this,o)},new s(this)},i.prototype._getDecoder=function(a){return a=a||"der",this.decoders.hasOwnProperty(a)||(this.decoders[a]=this._createNamed(t.decoders[a])),this.decoders[a]},i.prototype.decode=function(a,s,o){return this._getDecoder(s).decode(a,o)},i.prototype._getEncoder=function(a){return a=a||"der",this.encoders.hasOwnProperty(a)||(this.encoders[a]=this._createNamed(t.encoders[a])),this.encoders[a]},i.prototype.encode=function(a,s,o){return this._getEncoder(s).encode(a,o)}}(JF)),JF}var eP={},tP={},o0e=Zt;function zs(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}tP.Reporter=zs,zs.prototype.isError=function(e){return e instanceof U0},zs.prototype.save=function(){var e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},zs.prototype.restore=function(e){var t=this._reporterState;t.obj=e.obj,t.path=t.path.slice(0,e.pathLen)},zs.prototype.enterKey=function(e){return this._reporterState.path.push(e)},zs.prototype.exitKey=function(e){var t=this._reporterState;t.path=t.path.slice(0,e-1)},zs.prototype.leaveKey=function(e,t,r){var n=this._reporterState;this.exitKey(e),n.obj!==null&&(n.obj[t]=r)},zs.prototype.path=function(){return this._reporterState.path.join("/")},zs.prototype.enterObject=function(){var e=this._reporterState,t=e.obj;return e.obj={},t},zs.prototype.leaveObject=function(e){var t=this._reporterState,r=t.obj;return t.obj=e,r},zs.prototype.error=function(e){var t,r=this._reporterState,n=e instanceof U0;
1983if(n?t=e:t=new U0(r.path.map(function(i){return"["+JSON.stringify(i)+"]"}).join(""),e.message||e,e.stack),!r.options.partial)throw t;return n||r.errors.push(t),t},zs.prototype.wrapResult=function(e){var t=this._reporterState;return t.options.partial?{result:this.isError(e)?null:e,errors:t.errors}:e};function U0(e,t){this.path=e,this.rethrow(t)}o0e(U0,Error),U0.prototype.rethrow=function(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,U0),!this.stack)try{throw new Error(this.message)}catch(t){this.stack=t.stack}return this};var Mx={},rP;function nP(){if(rP)return Mx;rP=1;var e=Zt,t=lb().Reporter,r=ji.Buffer;function n(a,s){if(t.call(this,s),!r.isBuffer(a)){this.error("Input not Buffer");return}this.base=a,this.offset=0,this.length=a.length}e(n,t),Mx.DecoderBuffer=n,n.prototype.save=function(){return{offset:this.offset,reporter:t.prototype.save.call(this)}},n.prototype.restore=function(a){var s=new n(this.base);return s.offset=a.offset,s.length=this.offset,this.offset=a.offset,t.prototype.restore.call(this,a.reporter),s},n.prototype.isEmpty=function(){return this.offset===this.length},n.prototype.readUInt8=function(a){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(a||"DecoderBuffer overrun")},n.prototype.skip=function(a,s){if(!(this.offset+a<=this.length))return this.error(s||"DecoderBuffer overrun");var o=new n(this.base);return o._reporterState=this._reporterState,o.offset=this.offset,o.length=this.offset+a,this.offset+=a,o},n.prototype.raw=function(a){return this.base.slice(a?a.offset:this.offset,this.length)};function i(a,s){if(Array.isArray(a))this.length=0,this.value=a.map(function(o){return o instanceof i||(o=new i(o,s)),this.length+=o.length,o},this);else if(typeof a=="number"){if(!(0<=a&&a<=255))return s.error("non-byte EncoderBuffer value");this.value=a,this.length=1}else if(typeof a=="string")this.value=a,this.length=r.byteLength(a);else if(r.isBuffer(a))this.value=a,this.length=a.length;else return s.error("Unsupported type: "+typeof a)}return Mx.EncoderBuffer=i,i.prototype.join=function(a,s){return a||(a=new r(this.length)),s||(s=0),this.length===0||(Array.isArray(this.value)?this.value.forEach(function(o){o.join(a,s),s+=o.length}):(typeof this.value=="number"?a[s]=this.value:typeof this.value=="string"?a.write(this.value,s):r.isBuffer(this.value)&&this.value.copy(a,s),s+=this.length)),a},Mx}var sS,iP;function l0e(){if(iP)return sS;iP=1;var e=lb().Reporter,t=lb().EncoderBuffer,r=lb().DecoderBuffer,n=Bs,i=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],a=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(i),s=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function o(l,u){var d={};this._baseState=d,d.enc=l,d.parent=u||null,d.children=null,d.tag=null,d.args=null,d.reverseArgs=null,d.choice=null,d.optional=!1,d.any=!1,d.obj=!1,d.use=null,d.useDecoder=null,d.key=null,d.default=null,d.explicit=null,d.implicit=null,d.contains=null,d.parent||(d.children=[],this._wrap())}sS=o;var c=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];return o.prototype.clone=function(){var l=this._baseState,u={};
1983c.forEach(function(p){u[p]=l[p]});var d=new this.constructor(u.parent);return d._baseState=u,d},o.prototype._wrap=function(){var l=this._baseState;a.forEach(function(u){this[u]=function(){var d=new this.constructor(this);return l.children.push(d),d[u].apply(d,arguments)}},this)},o.prototype._init=function(l){var u=this._baseState;n(u.parent===null),l.call(this),u.children=u.children.filter(function(d){return d._baseState.parent===this},this),n.equal(u.children.length,1,"Root node can have only one child")},o.prototype._useArgs=function(l){var u=this._baseState,d=l.filter(function(p){return p instanceof this.constructor},this);l=l.filter(function(p){return!(p instanceof this.constructor)},this),d.length!==0&&(n(u.children===null),u.children=d,d.forEach(function(p){p._baseState.parent=this},this)),l.length!==0&&(n(u.args===null),u.args=l,u.reverseArgs=l.map(function(p){if(typeof p!="object"||p.constructor!==Object)return p;var w={};return Object.keys(p).forEach(function(O){O==(O|0)&&(O|=0);var I=p[O];w[I]=O}),w}))}
1983,s.forEach(function(l){o.prototype[l]=function(){var u=this._baseState;throw new Error(l+" not implemented for encoding: "+u.enc)}}),i.forEach(function(l){o.prototype[l]=function(){var u=this._baseState,d=Array.prototype.slice.call(arguments);return n(u.tag===null),u.tag=l,this._useArgs(d),this}}),o.prototype.use=function(l){n(l);var u=this._baseState;return n(u.use===null),u.use=l,this},o.prototype.optional=function(){var l=this._baseState;return l.optional=!0,this},o.prototype.def=function(l){var u=this._baseState;return n(u.default===null),u.default=l,u.optional=!0,this},o.prototype.explicit=function(l){var u=this._baseState;return n(u.explicit===null&&u.implicit===null),u.explicit=l,this},o.prototype.implicit=function(l){var u=this._baseState;return n(u.explicit===null&&u.implicit===null),u.implicit=l,this},o.prototype.obj=function(){var l=this._baseState,u=Array.prototype.slice.call(arguments);return l.obj=!0,u.length!==0&&this._useArgs(u),this},o.prototype.key=function(l){var u=this._baseState;return n(u.key===null),u.key=l,this},o.prototype.any=function(){var l=this._baseState;return l.any=!0,this},o.prototype.choice=function(l){var u=this._baseState;return n(u.choice===null),u.choice=l,this._useArgs(Object.keys(l).map(function(d){return l[d]})),this},o.prototype.contains=function(l){var u=this._baseState;return n(u.use===null),u.contains=l,this},o.prototype._decode=function(l,u){var d=this._baseState;if(d.parent===null)return l.wrapResult(d.children[0]._decode(l,u));var p=d.default,w=!0,O=null;if(d.key!==null&&(O=l.enterKey(d.key)),d.optional){var I=null;if(d.explicit!==null?I=d.explicit:d.implicit!==null?I=d.implicit:d.tag!==null&&(I=d.tag),I===null&&!d.any){var R=l.save();try{d.choice===null?this._decodeGeneric(d.tag,l,u):this._decodeChoice(l,u),w=!0}catch{w=!1}l.restore(R)}else if(w=this._peekTag(l,I,d.any),l.isError(w))return w}var C;if(d.obj&&w&&(C=l.enterObject()),w){if(d.explicit!==null){var j=this._decodeTag(l,d.explicit);if(l.isError(j))return j;l=j}var N=l.offset;if(d.use===null&&d.choice===null){if(d.any)var R=l.save();var P=this._decodeTag(l,d.implicit!==null?d.implicit:d.tag,d.any);if(l.isError(P))return P;d.any?p=l.raw(R):l=P}if(u&&u.track&&d.tag!==null&&u.track(l.path(),N,l.length,"tagged"),u&&u.track&&d.tag!==null&&u.track(l.path(),l.offset,l.length,"content"),d.any?p=p:d.choice===null?p=this._decodeGeneric(d.tag,l,u):p=this._decodeChoice(l,u),l.isError(p))return p;if(!d.any&&d.choice===null&&d.children!==null&&d.children.forEach(function(X){X._decode(l,u)}),d.contains&&(d.tag==="octstr"||d.tag==="bitstr")){var Z=new r(p);p=this._getUse(d.contains,l._reporterState.obj)._decode(Z,u)}}return d.obj&&w&&(p=l.leaveObject(C)),d.key!==null&&(p!==null||w===!0)?l.leaveKey(O,d.key,p):O!==null&&l.exitKey(O),p},o.prototype._decodeGeneric=function(l,u,d){var p=this._baseState;return l==="seq"||l==="set"?null:l==="seqof"||l==="setof"?this._decodeList(u,l,p.args[0],d):/str$/.test(l)?this._decodeStr(u,l,d):l==="objid"&&p.args?this._decodeObjid(u,p.args[0],p.args[1],d):l==="objid"?this._decodeObjid(u,null,null,d):l==="gentime"||l==="utctime"?this._decodeTime(u,l,d):l==="null_"?this._decodeNull(u,d):l==="bool"?this._decodeBool(u,d):l==="objDesc"?this._decodeStr(u,l,d):l==="int"||l==="enum"?this._decodeInt(u,p.args&&p.args[0],d):p.use!==null?this._getUse(p.use,u._reporterState.obj)._decode(u,d):u.error("unknown tag: "+l)},o.prototype._getUse=function(l,u){var d=this._baseState;return d.useDecoder=this._use(l,u),n(d.useDecoder._baseState.parent===null),d.useDecoder=d.useDecoder._baseState.children[0],d.implicit!==d.useDecoder._baseState.implicit&&(d.useDecoder=d.useDecoder.clone(),d.useDecoder._baseState.implicit=d.implicit),d.useDecoder},o.prototype._decodeChoice=function(l,u){var d=this._baseState,p=null,w=!1;return Object.keys(d.choice).some(function(O){var I=l.save(),R=d.choice[O];try{var C=R._decode(l,u);if(l.isError(C))return!1;p={type:O,value:C},w=!0}catch{return l.restore(I),!1}return!0},this),w?p:l.error("Choice not matched")},o.prototype._createEncoderBuffer=function(l){return new t(l,this.reporter)},o.prototype._encode=function(l,u,d){var p=this._baseState;if(!(p.default!==null&&p.default===l)){var w=this._encodeValue(l,u,d);if(w!==void 0&&!this._skipDefault(w,u,d))return w}},o.prototype._encodeValue=function(l,u,d){var p=this._baseState;if(p.parent===null)return p.children[0]._encode(l,u||new e);var R=null;if(this.reporter=u,p.optional&&l===void 0)if(p.default!==null)l=p.default;else return;var w=null,O=!1;
1983if(p.any)R=this._createEncoderBuffer(l);else if(p.choice)R=this._encodeChoice(l,u);else if(p.contains)w=this._getUse(p.contains,d)._encode(l,u),O=!0;else if(p.children)w=p.children.map(function(N){if(N._baseState.tag==="null_")return N._encode(null,u,l);if(N._baseState.key===null)return u.error("Child should have a key");var P=u.enterKey(N._baseState.key);if(typeof l!="object")return u.error("Child expected, but input is not object");var Z=N._encode(l[N._baseState.key],u,l);return u.leaveKey(P),Z},this).filter(function(N){return N}),w=this._createEncoderBuffer(w);else if(p.tag==="seqof"||p.tag==="setof"){if(!(p.args&&p.args.length===1))return u.error("Too many args for : "+p.tag);if(!Array.isArray(l))return u.error("seqof/setof, but data is not Array");var I=this.clone();I._baseState.implicit=null,w=this._createEncoderBuffer(l.map(function(N){var P=this._baseState;return this._getUse(P.args[0],l)._encode(N,u)},I))}else p.use!==null?R=this._getUse(p.use,d)._encode(l,u):(w=this._encodePrimitive(p.tag,l),O=!0);var R;if(!p.any&&p.choice===null){var C=p.implicit!==null?p.implicit:p.tag,j=p.implicit===null?"universal":"context";C===null?p.use===null&&u.error("Tag could be omitted only for .use()"):p.use===null&&(R=this._encodeComposite(C,O,j,w))}return p.explicit!==null&&(R=this._encodeComposite(p.explicit,!1,"context",R)),R},o.prototype._encodeChoice=function(l,u){var d=this._baseState,p=d.choice[l.type];return p||n(!1,l.type+" not found in "+JSON.stringify(Object.keys(d.choice))),p._encode(l.value,u)},o.prototype._encodePrimitive=function(l,u){var d=this._baseState;if(/str$/.test(l))return this._encodeStr(u,l);if(l==="objid"&&d.args)return this._encodeObjid(u,d.reverseArgs[0],d.args[
19831]);if(l==="objid")return this._encodeObjid(u,null,null);if(l==="gentime"||l==="utctime")return this._encodeTime(u,l);if(l==="null_")return this._encodeNull();if(l==="int"||l==="enum")return this._encodeInt(u,d.args&&d.reverseArgs[0]);if(l==="bool")return this._encodeBool(u);if(l==="objDesc")return this._encodeStr(u,l);throw new Error("Unsupported tag: "+l)},o.prototype._isNumstr=function(l){return/^[0-9 ]*$/.test(l)},o.prototype._isPrintstr=function(l){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(l)},sS}var aP;function lb(){return aP||(aP=1,function(e){var t=e;t.Reporter=tP.Reporter,t.DecoderBuffer=nP().DecoderBuffer,t.EncoderBuffer=nP().EncoderBuffer,t.Node=l0e()}(eP)),eP}var sP={},oP={},lP;function c0e(){return lP||(lP=1,function(e){var t=uP();e.tagClass={0:"universal",1:"application",2:"context",3:"private"},e.tagClassByName=t._reverse(e.tagClass),e.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},e.tagByName=t._reverse(e.tag)}(oP)),oP}var cP;function uP(){return cP||(cP=1,function(e){var t=e;t._reverse=function(r){var n={};return Object.keys(r).forEach(function(i){(i|0)==i&&(i=i|0);var a=r[i];n[a]=i}),n},t.der=c0e()}(sP)),sP}var fP={},oS,hP;function dP(){if(hP)return oS;hP=1;var e=Zt,t=cb(),r=t.base,n=t.bignum,i=t.constants.der;function a(l){this.enc="der",this.name=l.name,this.entity=l,this.tree=new s,this.tree._init(l.body)}oS=a,a.prototype.decode=function(l,u){return l instanceof r.DecoderBuffer||(l=new r.DecoderBuffer(l,u)),this.tree._decode(l,u)};function s(l){r.Node.call(this,"der",l)}e(s,r.Node),s.prototype._peekTag=function(l,u,d){if(l.isEmpty())return!1;var p=l.save(),w=o(l,'Failed to peek tag: "'+u+'"');return l.isError(w)?w:(l.restore(p),w.tag===u||w.tagStr===u||w.tagStr+"of"===u||d)},s.prototype._decodeTag=function(l,u,d){var p=o(l,'Failed to decode tag of "'+u+'"');if(l.isError(p))return p;var w=c(l,p.primitive,'Failed to get length of "'+u+'"');if(l.isError(w))return w;if(!d&&p.tag!==u&&p.tagStr!==u&&p.tagStr+"of"!==u)return l.error('Failed to match tag: "'+u+'"');if(p.primitive||w!==null)return l.skip(w,'Failed to match body of: "'+u+'"');var O=l.save(),I=this._skipUntilEnd(l,'Failed to skip indefinite length body: "'+this.tag+'"');return l.isError(I)?I:(w=l.offset-O.offset,l.restore(O),l.skip(w,'Failed to match body of: "'+u+'"'))},s.prototype._skipUntilEnd=function(l,u){for(;;){var d=o(l,u);if(l.isError(d))return d;var p=c(l,d.primitive,u);if(l.isError(p))return p;var w;if(d.primitive||p!==null?w=l.skip(p):w=this._skipUntilEnd(l,u),l.isError(w))return w;if(d.tagStr==="end")break}},s.prototype._decodeList=function(l,u,d,p){for(var w=[];!l.isEmpty();){var O=this._peekTag(l,"end");if(l.isError(O))return O;var I=d.decode(l,"der",p);if(l.isError(I)&&O)break;w.push(I)}return w},s.prototype._decodeStr=function(l,u){if(u==="bitstr"){var d=l.readUInt8();return l.isError(d)?d:{unused:d,data:l.raw()}}else if(u==="bmpstr"){var p=l.raw();if(p.length%2===1)return l.error("Decoding of string type: bmpstr length mismatch");for(var w="",O=0;O<p.length/2;O++)w+=String.fromCharCode(p.readUInt16BE(O*2));return w}else if(u==="numstr"){var I=l.raw().toString("ascii");return this._isNumstr(I)?I:l.error("Decoding of string type: numstr unsupported characters")}else{if(u==="octstr"||u==="objDesc")return l.raw();if(u==="printstr"){var R=l.raw().toString("ascii");return this._isPrintstr(R)?R:l.error("Decoding of string type: printstr unsupported characters")}else return/str$/.test(u)?l.raw().toString():l.error("Decoding of string type: "+u+" unsupported")}},s.prototype._decodeObjid=function(l,u,d){for(var p,w=[],O=0;!l.isEmpty();){var I=l.readUInt8();O<<=7,O|=I&127,I&128||(w.push(O),O=0)}I&128&&w.push(O);var R=w[0]/40|0,C=w[0]%40;if(d?p=w:p=[R,C].concat(w.slice(1)),u){var j=u[p.join(" ")];j===void 0&&(j=u[p.join(".")]),j!==void 0&&(p=j)}return p},s.prototype._decodeTime=function(l,u){var d=l.raw().toString();if(u==="gentime")var p=d.slice(0,4)|0,w=d.slice(4,6)|0,O=d.slice(6,8)|0,I=d.slice(8,10)|0,R=d.slice(10,12)|0,C=d.slice(12,14)|0;else if(u==="utctime"){var p=d.slice(0,2)|0,w=d.slice(2,4)|0,O=d.slice(4,6)|0,I=d.slice(6,8)|0,R=d.slice(8,10)|0,C=d.slice(10,12)|0;p<70?p=2e3+p:p=1900+p}else return l.error("Decoding "+u+" time is not supported yet");return Date.UTC(p,w-1,O,I,R,C,0)},s.prototype._decodeNull=function(l){return null},s.prototype._decodeBool=function(l){var u=l.readUInt8();return l.isError(u)?u:u!==0},s.prototype._decodeInt=function(l,u){var d=l.raw(),p=new n(d);return u&&(p=u[p.toString(10)]||p),p},s.prototype._use=function(l,u){return typeof l=="function"&&(l=l(u)),l._getDecoder("der").tree};function o(l,u){var d=l.readUInt8(u);if(l.isError(d))return d;var p=i.tagClass[d>>6],w=(d&32)===0;
1983if((d&31)===31){var O=d;for(d=0;(O&128)===128;){if(O=l.readUInt8(u),l.isError(O))return O;d<<=7,d|=O&127}}else d&=31;var I=i.tag[d];return{cls:p,primitive:w,tag:d,tagStr:I}}function c(l,u,d){var p=l.readUInt8(d);if(l.isError(p))return p;if(!u&&p===128)return null;if(!(p&128))return p;var w=p&127;if(w>4)return l.error("length octect is too long");p=0;for(var O=0;O<w;O++){p<<=8;var I=l.readUInt8(d);if(l.isError(I))return I;p|=I}return p}return oS}var lS,pP;function u0e(){if(pP)return lS;pP=1;var e=Zt,t=ji.Buffer,r=dP();function n(i){r.call(this,i),this.enc="pem"}return e(n,r),lS=n,n.prototype.decode=function(i,a){for(var s=i.toString().split(/[\r\n]+/g),o=a.label.toUpperCase(),c=/^-----(BEGIN|END) ([^-]+)-----$/,l=-1,u=-1,d=0;d<s.length;d++){var p=s[d].match(c);if(p!==null&&p[2]===o)if(l===-1){if(p[1]!=="BEGIN")break;l=d}else{if(p[1]!=="END")break;u=d;break}}if(l===-1||u===-1)throw new Error("PEM section not found for: "+o);var w=s.slice(l+1,u).join("");w.replace(/[^a-z0-9\+\/=]+/gi,"");var O=new t(w,"base64");return r.prototype.decode.call(this,O,a)},lS}var mP;function f0e(){return mP||(mP=1,function(e){var t=e;t.der=dP(),t.pem=u0e()}(fP)),fP}var gP={},cS,bP;function yP(){if(bP)return cS;bP=1;var e=Zt,t=ji.Buffer,r=cb(),n=r.base,i=r.constants.der;function a(l){this.enc="der",this.name=l.name,this.entity=l,this.tree=new s,this.tree._init(l.body)}cS=a,a.prototype.encode=function(l,u){return this.tree._encode(l,u).join()};function s(l){n.Node.call(this,"der",l)}e(s,n.Node),s.prototype._encodeComposite=function(l,u,d,p){var w=c(l,u,d,this.reporter);if(p.length<128){var R=new t(2);return R[0]=w,R[1]=p.length,this._createEncoderBuffer([R,p])}for(var O=1,I=p.length;I>=256;I>>=8)O++;var R=new t(2+O);R[0]=w,R[1]=128|O;for(var I=1+O,C=p.length;C>0;I--,C>>=8)R[I]=C&255;return this._createEncoderBuffer([R,p])},s.prototype._encodeStr=function(l,u){if(u==="bitstr")return this._createEncoderBuffer([l.unused|0,l.data]);if(u==="bmpstr"){for(var d=new t(l.length*2),p=0;p<l.length;p++)d.writeUInt16BE(l.charCodeAt(p),p*2);return this._createEncoderBuffer(d)}else return u==="numstr"?this._isNumstr(l)?this._createEncoderBuffer(l):this.reporter.error("Encoding of string type: numstr supports only digits and space"):u==="printstr"?this._isPrintstr(l)?this._createEncoderBuffer(l):this.reporter.error("Encoding of string type: printstr supports only latin upper and lower case letters, digits, space, apostrophe, left and rigth parenthesis, plus sign, comma, hyphen, dot, slash, colon, equal sign, question mark"):/str$/.test(u)?this._createEncoderBuffer(l):u==="objDesc"?this._createEncoderBuffer(l):this.reporter.error("Encoding of string type: "+u+" unsupported")},s.prototype._encodeObjid=function(l,u,d){if(typeof l=="string"){if(!u)return this.reporter.error("string objid given, but no values map found");if(!u.hasOwnProperty(l))return this.reporter.error("objid not found in values map");l=u[l].split(/[\s\.]+/g);for(var p=0;p<l.length;p++)l[p]|=0}else if(Array.isArray(l)){l=l.slice();for(var p=0;p<l.length;p++)l[p]|=0}if(!Array.isArray(l))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(l));if(!d){if(l[1]>=40)return this.reporter.error("Second objid identifier OOB");l.splice(0,2,l[0]*40+l[1])}for(var w=0,p=0;p<l.length;p++){var O=l[p];for(w++;O>=128;O>>=7)w++}for(var I=new t(w),R=I.length-1,p=l.length-1;p>=0;p--){var O=l[p];for(I[R--]=O&127;(O>>=7)>0;)I[R--]=128|O&127}return this._createEncoderBuffer(I)};function o(l){return l<10?"0"+l:l}s.prototype._encodeTime=function(l,u){var d,p=new Date(l);return u==="gentime"?d=[o(p.getFullYear()),o(p.getUTCMonth()+1),o(p.getUTCDate()),o(p.getUTCHours()),o(p.getUTCMinutes()),o(p.getUTCSeconds()),"Z"].join(""):u==="utctime"?d=[o(p.getFullYear()%100),o(p.getUTCMonth()+1),o(p.getUTCDate()),o(p.getUTCHours()),o(p.getUTCMinutes()),o(p.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+u+" time is not supported yet"),this._encodeStr(d,"octstr")},s.prototype._encodeNull=function(){return this._createEncoderBuffer("")},s.prototype._encodeInt=function(l,u){if(typeof l=="string"){if(!u)return this.reporter.error("String int or enum given, but no values map");if(!u.hasOwnProperty(l))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(l));l=u[l]}if(typeof l!="number"&&!t.isBuffer(l)){var d=l.toArray();!l.sign&&d[0]&128&&d.unshift(0),l=new t(d)}if(t.isBuffer(l)){var p=l.length;l.length===0&&p++;var w=new t(p);return l.copy(w),l.length===0&&(w[0]=0),this._createEncoderBuffer(w)}if(l<128)return this._createEncoderBuffer(l);if(l<256)return this._createEncoderBuffer([0,l]);for(var p=1,O=l;O>=256;O>>=8)p++;for(var w=new Array(p),O=w.length-1;O>=0;O--)w[O]=l&255,l>>=8;return w[0]&128&&w.unshift(0),this._createEncoderBuffer(new t(w))},s.prototype._encodeBool=function(l){return this._createEncoderBuffer(l?255:0)},s.prototype._use=function(l,u){return typeof l=="function"&&(l=l(u)),l._getEncoder("der").tree},s.prototype._skipDefault=function(l,u,d){var p=this._baseState,w;if(p.default===null)return!1;var O=l.join();if(p.defaultBuffer===void 0&&(p.defaultBuffer=this._encodeValue(p.default,u,d).join()),O.length!==p.defaultBuffer.length)return!1;for(w=0;w<O.length;w++)if(O[w]!==p.defaultBuffer[w])return!1;return!0};function c(l,u,d,p){var w;if(l==="seqof"?l="seq":l==="setof"&&(l="set"),i.tagByName.hasOwnProperty(l))w=i.tagByName[l];else if(typeof l=="number"&&(l|0)===l)w=l;else return p.error("Unknown tag: "+l);return w>=31?p.error("Multi-octet tag encoding unsupported"):(u||(w|=32),w|=i.tagClassByName[d||"universal"]<<6,w)}return cS}var uS,vP;function h0e(){if(vP)return uS;vP=1;var e=Zt,t=yP();function r(n){t.call(this,n),this.enc="pem"}return e(r,t),uS=r,r.prototype.encode=function(n,i){for(var a=t.prototype.encode.call(this,n),s=a.toString("base64"),o=["-----BEGIN "+i.label+"-----"],c=0;c<s.length;c+=64)o.push(s.slice(c,c+64));return o.push("-----END "+i.label+"-----"),o.join(`
1984`)},uS}var wP;function d0e(){return wP||(wP=1,function(e){var t=e;t.der=yP(),t.pem=h0e()}(gP)),gP}var xP;function cb(){return xP||(xP=1,function(e){var t=e;t.bignum=Fu,t.define=s0e().define,t.base=lb(),t.constants=uP(),t.decoders=f0e(),t.encoders=d0e()}(XF)),XF}var bo=cb(),_P=bo.define("Time",function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})}),p0e=bo.define("AttributeTypeValue",function(){this.seq().obj(this.key("type").objid(),this.key("value").any())}),fS=bo.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())}),m0e=bo.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(fS),this.key("subjectPublicKey").bitstr())}),g0e=bo.define("RelativeDistinguishedName",function(){this.setof(p0e)}),b0e=bo.define("RDNSequence",function(){this.seqof(g0e)}),SP=bo.define("Name",function(){this.choice({rdnSequence:this.use(b0e)})}),y0e=bo.define("Validity",function(){this.seq().obj(this.key("notBefore").use(_P),this.key("notAfter").use(_P))}),v0e=bo.define("Extension",function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())}),w0e=bo.define("TBSCertificate",function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(fS),this.key("issuer").use(SP),this.key("validity").use(y0e),this.key("subject").use(SP),this.key("subjectPublicKeyInfo").use(m0e),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(v0e).optional())}
1984),x0e=bo.define("X509Certificate",function(){this.seq().obj(this.key("tbsCertificate").use(w0e),this.key("signatureAlgorithm").use(fS),this.key("signatureValue").bitstr())}),_0e=x0e,yo=cb();go.certificate=_0e;var S0e=yo.define("RSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())});go.RSAPrivateKey=S0e;var k0e=yo.define("RSAPublicKey",function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())});go.RSAPublicKey=k0e;var kP=yo.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())}),E0e=yo.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(kP),this.key("subjectPublicKey").bitstr())});go.PublicKey=E0e;var M0e=yo.define("PrivateKeyInfo",function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(kP),this.key("subjectPrivateKey").octstr())});go.PrivateKey=M0e;var A0e=yo.define("EncryptedPrivateKeyInfo",function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())});go.EncryptedPrivateKey=A0e;var C0e=yo.define("DSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())});go.DSAPrivateKey=C0e,go.DSAparam=yo.define("DSAparam",function(){this.int()});var T0e=yo.define("ECParameters",function(){this.choice({namedCurve:this.objid()})}),j0e=yo.define("ECPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(T0e),this.key("publicKey").optional().explicit(1).bitstr())});go.ECPrivateKey=j0e,go.signature=yo.define("signature",function(){this.seq().obj(this.key("r").int(),this.key("s").int())});const I0e={"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"};var O0e=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,B0e=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,R0e=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,N0e=ax,F0e=rs,Ax=Qt.Buffer,P0e=function(e,t){var r=e.toString(),n=r.match(O0e),i;if(n){var a="aes"+n[1],s=Ax.from(n[2],"hex"),o=Ax.from(n[3].replace(/[\r\n]/g,""),"base64"),c=N0e(t,s.slice(0,8),parseInt(n[1],10)).key,l=[],u=F0e.createDecipheriv(a,c,s);l.push(u.update(o)),l.push(u.final()),i=Ax.concat(l)}else{var d=r.match(R0e);i=Ax.from(d[2].replace(/[\r\n]/g,""),"base64")}var p=r.match(B0e)[1];return{tag:p,data:i}},Oa=go,z0e=I0e,L0e=P0e,D0e=rs,U0e=Kw,hS=Qt.Buffer;function q0e(e,t){var r=e.algorithm.decrypt.kde.kdeparams.salt,n=parseInt(e.algorithm.decrypt.kde.kdeparams.iters.toString(),10),i=z0e[e.algorithm.decrypt.cipher.algo.join(".")],a=e.algorithm.decrypt.cipher.iv,s=e.subjectPrivateKey,o=parseInt(i.split("-")[1],10)/8,c=U0e.pbkdf2Sync(t,r,n,o,"sha1"),l=D0e.createDecipheriv(i,c,a),u=[];return u.push(l.update(s)),u.push(l.final()),hS.concat(u)}function EP(e){var t;typeof e=="object"&&!hS.isBuffer(e)&&(t=e.passphrase,e=e.key),typeof e=="string"&&(e=hS.from(e));var r=L0e(e,t),n=r.tag,i=r.data,a,s;switch(n){case"CERTIFICATE":s=Oa.certificate.decode(i,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(s||(s=Oa.PublicKey.decode(i,"der")),a=s.algorithm.algorithm.join("."),a){case"1.2.840.113549.1.1.1":return Oa.RSAPublicKey.decode(s.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return s.subjectPrivateKey=s.subjectPublicKey,{type:"ec",data:s};case"1.2.840.10040.4.1":return s.algorithm.params.pub_key=Oa.DSAparam.decode(s.subjectPublicKey.data,"der"),{type:"dsa",data:s.algorithm.params};default:throw new Error("unknown key id "+a)}case"ENCRYPTED PRIVATE KEY":i=Oa.EncryptedPrivateKey.decode(i,"der"),i=q0e(i,t);case"PRIVATE KEY":switch(s=Oa.PrivateKey.decode(i,"der"),a=s.algorithm.algorithm.join("."),a){case"1.2.840.113549.1.1.1":return Oa.RSAPrivateKey.decode(s.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:s.algorithm.curve,privateKey:Oa.ECPrivateKey.decode(s.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return s.algorithm.params.priv_key=Oa.DSAparam.decode(s.subjectPrivateKey,"der"),{type:"dsa",params:s.algorithm.params};default:throw new Error("unknown key id "+a)}case"RSA PUBLIC KEY":return Oa.RSAPublicKey.decode(i,"der");case"RSA PRIVATE KEY":return Oa.RSAPrivateKey.decode(i,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:Oa.DSAPrivateKey.decode(i,"der")};case"EC PRIVATE KEY":return i=Oa.ECPrivateKey.decode(i,"der"),{curve:i.parameters.value,privateKey:i.privateKey};default:throw new Error("unknown key type "+n)}}EP.signature=Oa.signature;var Cx=EP;const MP={"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"};var AP;function V0e(){if(AP)return rb.exports;AP=1;var e=Qt.Buffer,t=qR,r=V8,n=iS().ec,i=YF,a=Cx,s=MP,o=1;function c(C,j,N,P,Z){var X=a(j);if(X.curve){if(P!=="ecdsa"&&P!=="ecdsa/rsa")throw new Error("wrong private key type");return l(C,X)}else if(X.type==="dsa"){if(P!=="dsa")throw new Error("wrong private key type");return u(C,X,N)}if(P!=="rsa"&&P!=="ecdsa/rsa")throw new Error("wrong private key type");if(j.padding!==void 0&&j.padding!==o)throw new Error("illegal or unsupported padding mode");C=e.concat([Z,C]);for(var re=X.modulus.byteLength(),ne=[0,1];C.length+ne.length+1<re;)ne.push(255);ne.push(0);for(var ae=-1;++ae<C.length;)ne.push(C[ae]);var ue=r(ne,X);return ue}function l(C,j){var N=s[j.curve.join(".")];if(!N)throw new Error("unknown curve "+j.curve.join("."));var P=new n(N),Z=P.keyFromPrivate(j.privateKey),X=Z.sign(C);return e.from(X.toDER())}function u(C,j,N){for(var P=j.params.priv_key,Z=j.params.p,X=j.params.q,re=j.params.g,ne=new i(0),ae,ue=w(C,X).mod(X),m=!1,A=p(P,X,C,N);m===!1;)ae=I(X,A,N),ne=R(re,ae,Z,X),m=ae.invm(X).imul(ue.add(P.mul(ne))).mod(X),m.cmpn(0)===0&&(m=!1,ne=new i(0));return d(ne,m)}function d(C,j){C=C.toArray(),j=j.toArray(),C[0]&128&&(C=[0].concat(C)),j[0]&128&&(j=[0].concat(j));var N=C.length+j.length+4,P=[48,N,2,C.length];return P=P.concat(C,[2,j.length],j),e.from(P)}function p(C,j,N,P){if(C=e.from(C.toArray()),C.length<j.byteLength()){var Z=e.alloc(j.byteLength()-C.length);C=e.concat([Z,C])}var X=N.length,re=O(N,j),ne=e.alloc(X);ne.fill(1);var ae=e.alloc(X);return ae=t(P,ae).update(ne).update(e.from([0])).update(C).update(re).digest(),ne=t(P,ae).update(ne).digest(),ae=t(P,ae).update(ne).update(e.from([1])).update(C).update(re).digest(),ne=t(P,ae).update(ne).digest(),{k:ae,v:ne}}function w(C,j){var N=new i(C),P=(C.length<<3)-j.bitLength();return P>0&&N.ishrn(P),N}function O(C,j){C=w(C,j),C=C.mod(j);var N=e.from(C.toArray());if(N.length<j.byteLength()){var P=e.alloc(j.byteLength()-N.length);N=e.concat([P,N])}return N}function I(C,j,N){var P,Z;do{for(P=e.alloc(0);P.length*8<C.bitLength();)j.v=t(N,j.k).update(j.v).digest(),P=e.concat([P,j.v]);Z=w(P,C),j.k=t(N,j.k).update(j.v).update(e.from([0])).digest(),j.v=t(N,j.k).update(j.v).digest()}while(Z.cmp(C)!==-1);return Z}function R(C,j,N,P){return C.toRed(i.mont(N)).redPow(j).fromRed().mod(P)}return rb.exports=c,rb.exports.getKey=p,rb.exports.makeKey=I,rb.exports}var dS,CP;function Z0e(){if(CP)return dS;CP=1;var e=Qt.Buffer,t=YF,r=iS().ec,n=Cx,i=MP;function a(l,u,d,p,w){var O=n(d);if(O.type==="ec"){if(p!=="ecdsa"&&p!=="ecdsa/rsa")throw new Error("wrong public key type");return s(l,u,O)}else if(O.type==="dsa"){if(p!=="dsa")throw new Error("wrong public key type");return o(l,u,O)}if(p!=="rsa"&&p!=="ecdsa/rsa")throw new Error("wrong public key type");u=e.concat([w,u]);for(var I=O.modulus.byteLength(),R=[1],C=0;u.length+R.length+2<I;)R.push(255),C+=1;R.push(0);for(var j=-1;++j<u.length;)R.push(u[j]);R=e.from(R);var N=t.mont(O.modulus);l=new t(l).toRed(N),l=l.redPow(new t(O.publicExponent)),l=e.from(l.fromRed().toArray());var P=C<8?1:0;for(I=Math.min(l.length,R.length),l.length!==R.length&&(P=1),j=-1;++j<I;)P|=l[j]^R[j];return P===0}function s(l,u,d){var p=i[d.data.algorithm.curve.join(".")];if(!p)throw new Error("unknown curve "+d.data.algorithm.curve.join("."));var w=new r(p),O=d.data.subjectPrivateKey.data;return w.verify(u,l,O)}function o(l,u,d){var p=d.data.p,w=d.data.q,O=d.data.g,I=d.data.pub_key,R=n.signature.decode(l,"der"),C=R.s,j=R.r;c(C,w),c(j,w);var N=t.mont(p),P=C.invm(w),Z=O.toRed(N).redPow(new t(u).mul(P).mod(w)).fromRed().mul(I.toRed(N).redPow(j.mul(P).mod(w)).fromRed()).mod(p).mod(w);return Z.cmp(j)===0}function c(l,u){if(l.cmpn(0)<=0)throw new Error("invalid sig");if(l.cmp(u)>=0)throw new Error("invalid sig")}return dS=a,dS}var pS,TP;
1984function $0e(){if(TP)return pS;TP=1;var e=Qt.Buffer,t=Zg,r=zfe,n=Zt,i=V0e(),a=Z0e(),s=VR;Object.keys(s).forEach(function(d){s[d].id=e.from(s[d].id,"hex"),s[d.toLowerCase()]=s[d]});function o(d){r.Writable.call(this);var p=s[d];if(!p)throw new Error("Unknown message digest");this._hashType=p.hash,this._hash=t(p.hash),this._tag=p.id,this._signType=p.sign}n(o,r.Writable),o.prototype._write=function(d,p,w){this._hash.update(d),w()},o.prototype.update=function(d,p){return this._hash.update(typeof d=="string"?e.from(d,p):d),this},o.prototype.sign=function(d,p){this.end();var w=this._hash.digest(),O=i(w,d,this._hashType,this._signType,this._tag);return p?O.toString(p):O};function c(d){r.Writable.call(this);var p=s[d];if(!p)throw new Error("Unknown message digest");this._hash=t(p.hash),this._tag=p.id,this._signType=p.sign}n(c,r.Writable),c.prototype._write=function(d,p,w){this._hash.update(d),w()},c.prototype.update=function(d,p){return this._hash.update(typeof d=="string"?e.from(d,p):d),this},c.prototype.verify=function(d,p,w){var O=typeof p=="string"?e.from(p,w):p;this.end();var I=this._hash.digest();return a(O,I,d,this._signType,this._tag)};function l(d){return new o(d)}function u(d){return new c(d)}
1984return pS={Sign:l,Verify:u,createSign:l,createVerify:u},pS}var mS,jP;function H0e(){if(jP)return mS;jP=1;var e=iS(),t=Fu;mS=function(a){return new n(a)};var r={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};r.p224=r.secp224r1,r.p256=r.secp256r1=r.prime256v1,r.p192=r.secp192r1=r.prime192v1,r.p384=r.secp384r1,r.p521=r.secp521r1;function n(a){this.curveType=r[a],this.curveType||(this.curveType={name:a}),this.curve=new e.ec(this.curveType.name),this.keys=void 0}n.prototype.generateKeys=function(a,s){return this.keys=this.curve.genKeyPair(),this.getPublicKey(a,s)},n.prototype.computeSecret=function(a,s,o){s=s||"utf8",je.isBuffer(a)||(a=new je(a,s));var c=this.curve.keyFromPublic(a).getPublic(),l=c.mul(this.keys.getPrivate()).getX();return i(l,o,this.curveType.byteLength)},n.prototype.getPublicKey=function(a,s){var o=this.keys.getPublic(s==="compressed",!0);return s==="hybrid"&&(o[o.length-1]%2?o[0]=7:o[0]=6),i(o,a)},n.prototype.getPrivateKey=function(a){return i(this.keys.getPrivate(),a)},n.prototype.setPublicKey=function(a,s){return s=s||"utf8",je.isBuffer(a)||(a=new je(a,s)),this.keys._importPublic(a),this},n.prototype.setPrivateKey=function(a,s){s=s||"utf8",je.isBuffer(a)||(a=new je(a,s));var o=new t(a);return o=o.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(o),this};function i(a,s,o){Array.isArray(a)||(a=a.toArray());var c=new je(a);if(o&&c.length<o){var l=new je(o-c.length);l.fill(0),c=je.concat([l,c])}return s?c.toString(s):c}return mS}var IP={},W0e=Zg,gS=Qt.Buffer,OP=function(e,t){for(var r=gS.alloc(0),n=0,i;r.length<t;)i=K0e(n++),r=gS.concat([r,W0e("sha1").update(e).update(i).digest()]);return r.slice(0,t)};function K0e(e){var t=gS.allocUnsafe(4);return t.writeUInt32BE(e,0),t}var BP=function(e,t){for(var r=e.length,n=-1;++n<r;)e[n]^=t[n];return e},RP=Fu,G0e=Qt.Buffer;function Y0e(e,t){return G0e.from(e.toRed(RP.mont(t.modulus)).redPow(new RP(t.publicExponent)).fromRed().toArray())}var NP=Y0e,X0e=Cx,bS=v0,J0e=Zg,FP=OP,PP=BP,yS=Fu,Q0e=NP,epe=V8,vo=Qt.Buffer,tpe=function(e,t,r){var n;e.padding?n=e.padding:r?n=1:n=4;var i=X0e(e),a;if(n===4)a=rpe(i,t);else if(n===1)a=npe(i,t,r);else if(n===3){if(a=new yS(t),a.cmp(i.modulus)>=0)throw new Error("data too long for modulus")}else throw new Error("unknown padding");return r?epe(a,i):Q0e(a,i)};function rpe(e,t){var r=e.modulus.byteLength(),n=t.length,i=J0e("sha1").update(vo.alloc(0)).digest(),a=i.length,s=2*a;if(n>r-s-2)throw new Error("message too long");var o=vo.alloc(r-n-s-2),c=r-a-1,l=bS(a),u=PP(vo.concat([i,o,vo.alloc(1,1),t],c),FP(l,c)),d=PP(l,FP(u,a));return new yS(vo.concat([vo.alloc(1),d,u],r))}function npe(e,t,r){var n=t.length,i=e.modulus.byteLength();if(n>i-11)throw new Error("message too long");var a;return r?a=vo.alloc(i-n-3,255):a=ipe(i-n-3),new yS(vo.concat([vo.from([0,r?1:2]),a,vo.alloc(1),t],i))}function ipe(e){for(var t=vo.allocUnsafe(e),r=0,n=bS(e*2),i=0,a;r<e;)i===n.length&&(n=bS(e*2),i=0),a=n[i++],a&&(t[r++]=a);return t}var ape=Cx,zP=OP,LP=BP,DP=Fu,spe=V8,ope=Zg,lpe=NP,ub=Qt.Buffer,cpe=function(e,t,r){var n;e.padding?n=e.padding:r?n=1:n=4;var i=ape(e),a=i.modulus.byteLength();if(t.length>a||new DP(t).cmp(i.modulus)>=0)throw new Error("decryption error");var s;r?s=lpe(new DP(t),i):s=spe(t,i);var o=ub.alloc(a-s.length);if(s=ub.concat([o,s],a),n===4)return upe(i,s);if(n===1)return fpe(i,s,r);if(n===3)return s;throw new Error("unknown padding")};function upe(e,t){var r=e.modulus.byteLength(),n=ope("sha1").update(ub.alloc(0)).digest(),i=n.length;if(t[0]!==0)throw new Error("decryption error");var a=t.slice(1,i+1),s=t.slice(i+1),o=LP(a,zP(s,i)),c=LP(s,zP(o,r-i-1));if(hpe(n,c.slice(0,i)))throw new Error("decryption error");for(var l=i;c[l]===0;)l++;if(c[l++]!==1)throw new Error("decryption error");return c.slice(l)}function fpe(e,t,r){for(var n=t.slice(0,2),i=2,a=0;t[i++]!==0;)if(i>=t.length){a++;break}var s=t.slice(2,i-1);if((n.toString("hex")!=="0002"&&!r||n.toString("hex")!=="0001"&&r)&&a++,s.length<8&&a++,a)throw new Error("decryption error");return t.slice(i)}function hpe(e,t){e=ub.from(e),t=ub.from(t);var r=0,n=e.length;e.length!==t.length&&(r++,n=Math.min(e.length,t.length));for(var i=-1;++i<n;)r+=e[i]^t[i];return r}(function(e){e.publicEncrypt=tpe,e.privateDecrypt=cpe,e.privateEncrypt=function(t,r){return e.publicEncrypt(t,r,!0)},e.publicDecrypt=function(t,r){return e.privateDecrypt(t,r,!0)}})(IP);var fb={};function UP(){throw new Error(`secure random number generation not supported by this browser
1985use chrome, FireFox or Internet Explorer 11`)}var qP=Qt,VP=v0,ZP=qP.Buffer,$P=qP.kMaxLength,vS=dt.crypto||dt.msCrypto,HP=Math.pow(2,32)-1;function WP(e,t){if(typeof e!="number"||e!==e)throw new TypeError("offset must be a number");if(e>HP||e<0)throw new TypeError("offset must be a uint32");if(e>$P||e>t)throw new RangeError("offset out of range")}function KP(e,t,r){if(typeof e!="number"||e!==e)throw new TypeError("size must be a number");if(e>HP||e<0)throw new TypeError("size must be a uint32");if(e+t>r||e>$P)throw new RangeError("buffer too small")}vS&&vS.getRandomValues||!ot.browser?(fb.randomFill=dpe,fb.randomFillSync=ppe):(fb.randomFill=UP,fb.randomFillSync=UP);
1985function dpe(e,t,r,n){if(!ZP.isBuffer(e)&&!(e instanceof dt.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if(typeof t=="function")n=t,t=0,r=e.length;else if(typeof r=="function")n=r,r=e.length-t;else if(typeof n!="function")throw new TypeError('"cb" argument must be a function');return WP(t,e.length),KP(r,t,e.length),GP(e,t,r,n)}function GP(e,t,r,n){if(ot.browser){var i=e.buffer,a=new Uint8Array(i,t,r);if(vS.getRandomValues(a),n){ot.nextTick(function(){n(null,e)});return}return e}if(n){VP(r,function(o,c){if(o)return n(o);c.copy(e,t),n(null,e)});return}var s=VP(r);return s.copy(e,t),e}function ppe(e,t,r){if(typeof t>"u"&&(t=0),!ZP.isBuffer(e)&&!(e instanceof dt.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');return WP(t,e.length),r===void 0&&(r=e.length-t),KP(r,t,e.length),GP(e,t,r)}var YP;function XP(){if(YP)return tr;YP=1,tr.randomBytes=tr.rng=tr.pseudoRandomBytes=tr.prng=v0,tr.createHash=tr.Hash=Zg,tr.createHmac=tr.Hmac=qR;var e=Nce,t=Object.keys(e),r=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(t);tr.getHashes=function(){return r};var n=Kw;
1985tr.pbkdf2=n.pbkdf2,tr.pbkdf2Sync=n.pbkdf2Sync;var i=ho;tr.Cipher=i.Cipher,tr.createCipher=i.createCipher,tr.Cipheriv=i.Cipheriv,tr.createCipheriv=i.createCipheriv,tr.Decipher=i.Decipher,tr.createDecipher=i.createDecipher,tr.Decipheriv=i.Decipheriv,tr.createDecipheriv=i.createDecipheriv,tr.getCiphers=i.getCiphers,tr.listCiphers=i.listCiphers;var a=dfe();tr.DiffieHellmanGroup=a.DiffieHellmanGroup,tr.createDiffieHellmanGroup=a.createDiffieHellmanGroup,tr.getDiffieHellman=a.getDiffieHellman,tr.createDiffieHellman=a.createDiffieHellman,tr.DiffieHellman=a.DiffieHellman;var s=$0e();tr.createSign=s.createSign,tr.Sign=s.Sign,tr.createVerify=s.createVerify,tr.Verify=s.Verify,tr.createECDH=H0e();var o=IP;tr.publicEncrypt=o.publicEncrypt,tr.privateEncrypt=o.privateEncrypt,tr.publicDecrypt=o.publicDecrypt,tr.privateDecrypt=o.privateDecrypt;var c=fb;return tr.randomFill=c.randomFill,tr.randomFillSync=c.randomFillSync,tr.createCredentials=function(){throw new Error(`sorry, createCredentials is not implemented yet
1986we accept pull requests
1987https://github.com/browserify/crypto-browserify`)},tr.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6},tr}var mpe=XP();const gpe=Nr(mpe),wS=Object.prototype.toString.call(typeof ot<"u"?ot:0)==="[object process]";var hb={},xS=hb.isatty=function(){return!1};function bpe(){throw new Error("tty.ReadStream is not implemented")}var ype=hb.ReadStream=bpe;function vpe(){throw new Error("tty.WriteStream is not implemented")}var wpe=hb.WriteStream=vpe;const xpe=Rr({__proto__:null,ReadStream:ype,WriteStream:wpe,default:hb,isatty:xS},[hb]),{env:Du={},argv:JP=[],platform:_pe=""}=typeof ot>"u"?{}:ot,Spe="NO_COLOR"in Du||JP.includes("--no-color"),kpe="FORCE_COLOR"in Du||JP.includes("--color"),Epe=_pe==="win32",QP=Du.TERM==="dumb",Mpe=xpe&&xS&&xS(1)&&Du.TERM&&!QP,Ape="CI"in Du&&("GITHUB_ACTIONS"in Du||"GITLAB_CI"in Du||"CIRCLECI"in Du),ez=!Spe&&(kpe||Epe&&!QP||Mpe||Ape),tz=(e,t,r,n,i=t.substring(0,e)+n,a=t.substring(e+r.length),s=a.indexOf(r))=>i+(s<0?a:tz(s,a,r,n)),Cpe=(e,t,r,n,i)=>e<0?r+t+n:r+tz(e,t,n,i)+n,Tpe=(e,t,r=e,n=e.length+1)=>i=>i||!(i===""||i===void 0)?Cpe((""+i).indexOf(t,n),i,e,t,r):"",rr=(e,t,r)=>Tpe(`\x1B[${e}m`,`\x1B[${t}m`,r),rz={reset:rr(0,0),bold:rr(1,22,"\x1B[22m\x1B[1m"),dim:rr(2,22,"\x1B[22m\x1B[2m"),italic:rr(3,23),underline:rr(4,24),inverse:rr(7,27),hidden:rr(8,28),strikethrough:rr(9,29),black:rr(30,39),red:rr(31,39),green:rr(32,39),yellow:rr(33,39),blue:rr(34,39),magenta:rr(35,39),cyan:rr(36,39),white:rr(37,39),gray:rr(90,39),bgBlack:rr(40,49),bgRed:rr(41,49),bgGreen:rr(42,49),bgYellow:rr(43,49),bgBlue:rr(44,49),bgMagenta:rr(45,49),bgCyan:rr(46,49),bgWhite:rr(47,49),blackBright:rr(90,39),redBright:rr(91,39),greenBright:rr(92,39),yellowBright:rr(93,39),blueBright:rr(94,39),magentaBright:rr(95,39),cyanBright:rr(96,39),whiteBright:rr(97,39),bgBlackBright:rr(100,49),bgRedBright:rr(101,49),bgGreenBright:rr(102,49),bgYellowBright:rr(103,49),bgBlueBright:rr(104,49),bgMagentaBright:rr(105,49),bgCyanBright:rr(106,49),bgWhiteBright:rr(107,49)},nz=({useColor:e=ez}={})=>e?rz:Object.keys(rz).reduce((t,r)=>({...t,[r]:String}),{});nz();var _S={exports:{}};function jpe(e){try{return JSON.stringify(e)}catch{return'"[Circular]"'}}var Ipe=Ope;function Ope(e,t,r){var n=r&&r.stringify||jpe,i=1;if(typeof e=="object"&&e!==null){var a=t.length+i;if(a===1)return e;var s=new Array(a);s[0]=n(e);for(var o=1;o<a;o++)s[o]=n(t[o]);return s.join(" ")}if(typeof e!="string")return e;var c=t.length;if(c===0)return e;for(var l="",u=1-i,d=-1,p=e&&e.length||0,w=0;w<p;){if(e.charCodeAt(w)===37&&w+1<p){switch(d=d>-1?d:0,e.charCodeAt(w+1)){case 100:case 102:if(u>=c||t[u]==null)break;d<w&&(l+=e.slice(d,w)),l+=Number(t[u]),d=w+2,w++;break;case 105:if(u>=c||t[u]==null)break;d<w&&(l+=e.slice(d,w)),l+=Math.floor(Number(t[u])),d=w+2,w++;break;case 79:case 111:case 106:if(u>=c||t[u]===void 0)break;d<w&&(l+=e.slice(d,w));var O=typeof t[u];if(O==="string"){l+="'"+t[u]+"'",d=w+2,w++;break}if(O==="function"){l+=t[u].name||"<anonymous>",d=w+2,w++;break}l+=n(t[u]),d=w+2,w++;break;case 115:if(u>=c)break;d<w&&(l+=e.slice(d,w)),l+=String(t[u]),d=w+2,w++;break;case 37:d<w&&(l+=e.slice(d,w)),l+="%",d=w+2,w++,u--;break}++u}++w}return d===-1?e:(d<p&&(l+=e.slice(d)),l)}const iz=Ipe;_S.exports=Ac;const db=Wpe().console||{},Bpe={mapHttpRequest:Tx,mapHttpResponse:Tx,wrapRequestSerializer:AS,wrapResponseSerializer:AS,wrapErrorSerializer:AS,req:Tx,res:Tx,err:sz,errWithCause:sz};
vendor: 5,211 bytes, line 1987
1987function Uu(e,t){return e==="silent"?1/0:t.levels.values[e]}const SS=Symbol("pino.logFuncs"),kS=Symbol("pino.hierarchy"),Rpe={error:"log",fatal:"error",warn:"error",info:"log",debug:"log",trace:"log"};function az(e,t){const r={logger:t,parent:e[kS]};t[kS]=r}function Npe(e,t,r){const n={};t.forEach(i=>{n[i]=r[i]?r[i]:db[i]||db[Rpe[i]||"log"]||q0}),e[SS]=n}function Fpe(e,t){return Array.isArray(e)?e.filter(function(r){return r!=="!stdSerializers.err"}):e===!0?Object.keys(t):!1}function Ac(e){e=e||{},e.browser=e.browser||{};const t=e.browser.transmit;if(t&&typeof t.send!="function")throw Error("pino: transmit option must have a send function");const r=e.browser.write||db;e.browser.write&&(e.browser.asObject=!0);const n=e.serializers||{},i=Fpe(e.browser.serialize,n);let a=e.browser.serialize;Array.isArray(e.browser.serialize)&&e.browser.serialize.indexOf("!stdSerializers.err")>-1&&(a=!1);const s=Object.keys(e.customLevels||{}),o=["error","fatal","warn","info","debug","trace"].concat(s);typeof r=="function"&&o.forEach(function(I){r[I]=r}),(e.enabled===!1||e.browser.disabled)&&(e.level="silent");const c=e.level||"info",l=Object.create(r);l.log||(l.log=q0),Npe(l,o,r),az({},l),Object.defineProperty(l,"levelVal",{get:d}),Object.defineProperty(l,"level",{get:p,set:w});const u={transmit:t,serialize:i,asObject:e.browser.asObject,formatters:e.browser.formatters,levels:o,timestamp:Zpe(e),messageKey:e.messageKey||"msg",onChild:e.onChild||q0};l.levels=Ppe(e),l.level=c,l.setMaxListeners=l.getMaxListeners=l.emit=l.addListener=l.on=l.prependListener=l.once=l.prependOnceListener=l.removeListener=l.removeAllListeners=l.listeners=l.listenerCount=l.eventNames=l.write=l.flush=q0,l.serializers=n,l._serialize=i,l._stdErrSerialize=a,l.child=function(...I){return O.call(this,u,...I)},t&&(l._logEvent=MS());function d(){return Uu(this.level,this)}function p(){return this._level}function w(I){if(I!=="silent"&&!this.levels.values[I])throw Error("unknown level "+I);this._level=I,Mh(this,u,l,"error"),Mh(this,u,l,"fatal"),Mh(this,u,l,"warn"),Mh(this,u,l,"info"),Mh(this,u,l,"debug"),Mh(this,u,l,"trace"),s.forEach(R=>{Mh(this,u,l,R)})}function O(I,R,C){if(!R)throw new Error("missing bindings for child Pino");C=C||{},i&&R.serializers&&(C.serializers=R.serializers);const j=C.serializers;if(i&&j){var N=Object.assign({},n,j),P=e.browser.serialize===!0?Object.keys(N):i;delete R.serializers,ES([R],P,N,this._stdErrSerialize)}function Z(re){this._childLevel=(re._childLevel|0)+1,this.bindings=R,N&&(this.serializers=N,this._serialize=P),t&&(this._logEvent=MS([].concat(re._logEvent.bindings,R)))}Z.prototype=this;const X=new Z(this);return az(this,X),X.child=function(...re){return O.call(this,I,...re)},X.level=C.level||this.level,I.onChild(X),X}return l}function Ppe(e){const t=e.customLevels||{},r=Object.assign({},Ac.levels.values,t),n=Object.assign({},Ac.levels.labels,zpe(t));return{values:r,labels:n}}function zpe(e){const t={};return Object.keys(e).forEach(function(r){t[e[r]]=r}),t}Ac.levels={values:{fatal:60,error:50,warn:40,info:30,debug:20,trace:10},labels:{10:"trace",20:"debug",30:"info",40:"warn",50:"error",60:"fatal"}},Ac.stdSerializers=Bpe,Ac.stdTimeFunctions=Object.assign({},{nullTime:oz,epochTime:lz,unixTime:$pe,isoTime:Hpe});function Lpe(e){const t=[];e.bindings&&t.push(e.bindings);let r=e[kS];for(;r.parent;)r=r.parent,r.logger.bindings&&t.push(r.logger.bindings);return t.reverse()}function Mh(e,t,r,n){if(Object.defineProperty(e,n,{value:Uu(e.level,r)>Uu(n,r)?q0:r[SS][n],writable:!0,enumerable:!0,configurable:!0}),e[n]===q0){if(!t.transmit)return;const a=t.transmit.level||e.level,s=Uu(a,r);if(Uu(n,r)<s)return}e[n]=Upe(e,t,r,n);const i=Lpe(e);i.length!==0&&(e[n]=Dpe(i,e[n]))}function Dpe(e,t){return function(){return t.apply(this,[...e,...arguments])}}function Upe(e,t,r,n){return function(i){return function(){const a=t.timestamp(),s=new Array(arguments.length),o=Object.getPrototypeOf&&Object.getPrototypeOf(this)===db?db:this;for(var c=0;c<s.length;c++)s[c]=arguments[c];var l=!1;if(t.serialize&&(ES(s,this._serialize,this.serializers,this._stdErrSerialize),l=!0),t.asObject||t.formatters?i.call(o,qpe(this,n,s,a,t)):i.apply(o,s),t.transmit){const u=t.transmit.level||e._level,d=Uu(u,r),p=Uu(n,r);if(p<d)return;Vpe(this,{ts:a,methodLevel:n,methodValue:p,transmitLevel:u,transmitValue:r.levels.values[t.transmit.level||e._level],send:t.transmit.send,val:Uu(e._level,r)},s,l)}}}(e[SS][n])}function qpe(e,t,r,n,i){const{level:a,log:s=d=>d}=i.formatters||{},o=r.slice();let c=o[0];const l={};if(n&&(l.time=n),a){const d=a(t,e.levels.values[t]);Object.assign(l,d)}else l.level=e.levels.values[t];let u=(e._childLevel|0)+1;if(u<1&&(u=1),c!==null&&typeof c=="object"){for(;u--&&typeof o[0]=="object";)Object.assign(l,o.shift());c=o.length?iz(o.shift(),o):void 0}else typeof c=="string"&&(c=iz(o.shift(),o));return c!==void 0&&(l[i.messageKey]=c),s(l)}function ES(e,t,r,n){for(const i in e)if(n&&e[i]instanceof Error)e[i]=Ac.stdSerializers.err(e[i]);else if(typeof e[i]=="object"&&!Array.isArray(e[i])&&t)for(const a in e[i])t.indexOf(a)>-1&&a in r&&(e[i][a]=r[a](e[i][a]))}function Vpe(e,t,r,n=!1){const i=t.send,a=t.ts,s=t.methodLevel,o=t.methodValue,c=t.val,l=e._logEvent.bindings;
1987n||ES(r,e._serialize||Object.keys(e.serializers),e.serializers,e._stdErrSerialize===void 0?!0:e._stdErrSerialize),e._logEvent.ts=a,e._logEvent.messages=r.filter(function(u){return l.indexOf(u)===-1}),e._logEvent.level.label=s,e._logEvent.level.value=o,i(s,e._logEvent,c),e._logEvent=MS(l)}function MS(e){return{ts:0,messages:[],bindings:e||[],level:{label:"",value:0}}}function sz(e){const t={type:e.constructor.name,msg:e.message,stack:e.stack};for(const r in e)t[r]===void 0&&(t[r]=e[r]);return t}function Zpe(e){return typeof e.timestamp=="function"?e.timestamp:e.timestamp===!1?oz:lz}function Tx(){return{}}function AS(e){return e}function q0(){}function oz(){return!1}function lz(){return Date.now()}function $pe(){return Math.round(Date.now()/1e3)}function Hpe(){return new Date(Date.now()).toISOString()}function Wpe(){function e(t){return typeof t<"u"&&t}try{return typeof globalThis<"u"||Object.defineProperty(Object.prototype,"globalThis",{get:function(){return delete Object.prototype.globalThis,this.globalThis=this},configurable:!0}),globalThis}catch{return e(self)||e(window)||e(this)||{}}}_S.exports.default=Ac;var Ah=_S.exports.pino=Ac;function Kpe(e,t,r,n="Array size exceeds target length"){if(e.length>r)throw new Error(n);return[...e,...Array(r-e.length).fill(t)]}async function cz(e,t){return await Promise.all(Array(e).fill(0).map((r,n)=>t(n)))}function Ls(e){return e.filter(t=>t&&("isZero"in t?!t.isZero():!t.isEmpty())).map(t=>t.toBuffer().length).reduce((t,r)=>t+r,0)}function Gpe(e){return e.filter(t=>t!==void 0)}function CS(e){return{parseEnv:t=>Xpe(t,e),defaultValue:e}}function Ype(e=!1){const t=r=>typeof r=="boolean"?r:pb(r);return{parseEnv:t,parseVal:t,defaultValue:e,isBoolean:!0}}function pb(e){return e!==void 0&&["1","true","TRUE"].includes(e)}function Xpe(e,t){const r=parseInt(e,10);return Number.isSafeInteger(r)?r:t}const Jpe="logging.googleapis.com/trace",Qpe="logging.googleapis.com/spanId",eme="logging.googleapis.com/trace_sampled",tme={messageKey:"message",timestamp(){return`,"timestamp":"${new Date(Date.now()).toISOString()}"`},formatters:{log(e){const{trace_id:t,span_id:r,trace_flags:n,...i}=e;return t&&r?{[Jpe]:t,[Qpe]:r,[eme]:n?n==="01":void 0,trace_flags:n,...i}:e},level(e,t){let r;switch(e){case"trace":case"debug":r="DEBUG";break;case"verbose":case"info":r="INFO";break;case"warn":r="WARNING";break;case"error":r="ERROR";break;case"fatal":r="CRITICAL";break;default:r="DEFAULT";break}return{severity:r,level:t}}}},rme=["silent","fatal","error","warn","info","verbose","debug","trace"];function nme(e,t){for(const[r,n]of e)try{if(new RegExp(r).test(t))return n}catch{if(t.startsWith(r))return n}}function uz(e){if(!rme.includes(e))throw new Error(`Invalid log level: ${e}`)}function ime(e,t){if(!e)return[t,[]];const[r]=e.split(";",1);return uz(r),[r,ame(e.slice(r.length+1))]}function ame(e){if(!e)return[];const t=e.split(";"),r=[];for(const n of t){const[i]=n.split(":",1),a=n.slice(i.length+1);if(!a||!i)throw new Error(`Invalid log filter statement: ${n}`);const s=i.trim().toLowerCase();uz(s);for(const o of a.split(","))r.push([o.trim().toLowerCase().replace(/^aztec:/,""),s])}return r.reverse()}var Ch={};function V0(e){e=lme.reduce((n,i)=>i(n),e.replace(/^aztec:/,""));const t=vz.child({module:e},{level:nme(hz,e)}),r=(n,i,a)=>fz(t,n)&&t[n](ome(a??{}),i);return{silent:()=>{},fatal:(n,i,a)=>r("fatal",wz(n,i),a),error:(n,i,a)=>r("error",wz(n,i),a),warn:(n,i)=>r("warn",n,i),info:(n,i)=>r("info",n,i),verbose:(n,i)=>r("verbose",n,i),debug:(n,i)=>r("debug",n,i),trace:(n,i)=>r("trace",n,i),level:t.level,isLevelEnabled:n=>fz(t,n),module:e}}const sme=[];function ome(e){return sme.reduce((t,r)=>r(t),e)}const lme=[];function fz(e,t){return typeof e.isLevelEnabled=="function"?e.isLevelEnabled(t):e.levels.values[t]>=e.levels.values[e.level]}const cme="info",[TS,hz]=ime(Ch.LOG_LEVEL,cme),jS={verbose:25},dz=pb(Ch.USE_GCLOUD_LOGGING),mb=["validatorPrivateKey","publisherPrivateKey","peerIdPrivateKey","l1PrivateKey","senderPrivateKey","l1ConsensusHostApiKey","privateKey","mnemonic","l1Mnemonic","l1PrivateKey"],IS={customLevels:jS,messageKey:"msg",useOnlyCustomLevels:!1,level:TS,redact:{paths:[...mb,...mb.map(e=>`config.${e}`),...mb.map(e=>`cfg.${e}`),...mb.map(e=>`options.${e}`),...mb.map(e=>`opts.${e}`)]},...dz?tme:{}},pz={labels:{...Ah.levels.labels,...Object.fromEntries(Object.entries(jS).map(e=>e.reverse()))},values:{...Ah.levels.values,...jS}},mz=Ch.FORCE_COLOR,gz=mz===void 0?ez:pb(mz),{bold:ume,reset:fme}=nz({useColor:gz}),hme={destination:2,sync:!0,colorize:gz,ignore:"module,pid,hostname,trace_id,span_id,trace_flags,severity",messageFormat:`${ume("{module}")} ${fme("{msg}")}
1987`,customLevels:"fatal:60,error:50,warn:40,info:30,verbose:25,debug:20,trace:10",customColors:"fatal:bgRed,error:red,warn:yellow,info:green,verbose:magenta,debug:blue,trace:gray",minimumLevel:"trace",singleLine:!pb(Ch.LOG_MULTILINE)},dme={target:"pino-pretty",options:hme,level:"trace"},pme={target:"pino/file",options:{destination:2},level:"trace"},bz=Ch.OTEL_EXPORTER_OTLP_LOGS_ENDPOINT,yz=!!bz&&!dz,mme={levels:pz},gme={target:"@aztec/telemetry-client/otel-pino-stream",options:mme,level:"trace"};function bme(){if(wS){if(Ch.JEST_WORKER_ID)return Ah(IS,Ah.destination(2));{const e=Gpe([pb(Ch.LOG_JSON)?pme:dme,yz?gme:void 0]);return Ah(IS,Ah.transport({targets:e,levels:pz.values}))}}else return Ah({...IS,browser:{asObject:!1}})}const vz=bme();vz.verbose({module:"logger",...hz.reduce((e,[t,r])=>({...e,[`log.${t}`]:r}),{})},wS?`Logger initialized with level ${TS}`+(yz?` with OTLP exporter to ${bz}`:""):`Browser console logger initialized with level ${TS}`);function wz(e,t){return t?`${e}: ${ct.inspect(t)}`:e}var xz={};const id=class id{constructor(t,r=V0("foundation:randomness_singleton")){te(this,"seed");te(this,"log");te(this,"counter");this.seed=t,this.log=r,this.counter=0,t!==void 0?(this.log.debug(`Using pseudo-randomness with seed: ${t}`),this.counter=t):this.log.debug("Using true randomness")}static getInstance(){if(!id.instance){const t=xz.SEED?Number(xz.SEED):void 0;id.instance=new id(t)}return id.instance}isDeterministic(){return this.seed!==void 0}getBytes(t){if(this.seed===void 0)throw new Error("RandomnessSingleton is not implemented for non-deterministic mode");const r=je.alloc(t);for(let n=0;n<t;n++)r[n]=this.counter>>n*8&255;return this.counter++,r}};te(id,"instance");let OS=id;const BS=65536,yme=()=>{if(typeof window<"u"&&window.crypto)return window.crypto;if(typeof self<"u"&&self.crypto)return self.crypto},wo=e=>{const t=OS.getInstance();if(t.isDeterministic())return t.getBytes(e);if(wS)return gpe.randomBytes(e);const r=yme();if(!r)throw new Error("randomBytes UnsupportedEnvironment");const n=je.allocUnsafe(e);if(e>BS)for(let i=0;i<e;i+=BS)r.getRandomValues(n.slice(i,i+BS));else r.getRandomValues(n);return n},RS=e=>{const t=wo(6);return parseInt(t.toString("hex"),16)%e},vme=()=>wo(1)[0]%2===0;var Sr;(function(e){e.assertEqual=i=>i;function t(i){}e.assertIs=t;function r(i){throw new Error}e.assertNever=r,e.arrayToEnum=i=>{const a={};for(const s of i)a[s]=s;return a},e.getValidEnumValues=i=>{const a=e.objectKeys(i).filter(o=>typeof i[i[o]]!="number"),s={};for(const o of a)s[o]=i[o];return e.objectValues(s)},e.objectValues=i=>e.objectKeys(i).map(function(a){return i[a]}),e.objectKeys=typeof Object.keys=="function"?i=>Object.keys(i):i=>{const a=[];for(const s in i)Object.prototype.hasOwnProperty.call(i,s)&&a.push(s);return a},e.find=(i,a)=>{for(const s of i)if(a(s))return s},e.isInteger=typeof Number.isInteger=="function"?i=>Number.isInteger(i):i=>typeof i=="number"&&isFinite(i)&&Math.floor(i)===i;function n(i,a=" | "){return i.map(s=>typeof s=="string"?`'${s}'`:s).join(a)}e.joinValues=n,e.jsonStringifyReplacer=(i,a)=>typeof a=="bigint"?a.toString():a})(Sr||(Sr={}));var NS;(function(e){e.mergeShapes=(t,r)=>({...t,...r})})(NS||(NS={}));const ft=Sr.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),Cc=e=>{switch(typeof e){case"undefined":return ft.undefined;case"string":return ft.string;case"number":return isNaN(e)?ft.nan:ft.number;case"boolean":return ft.boolean;case"function":return ft.function;case"bigint":return ft.bigint;case"symbol":return ft.symbol;case"object":return Array.isArray(e)?ft.array:e===null?ft.null:e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?ft.promise:typeof Map<"u"&&e instanceof Map?ft.map:typeof Set<"u"&&e instanceof Set?ft.set:typeof Date<"u"&&e instanceof Date?ft.date:ft.object;default:return ft.unknown}}
vendor: 4,303 bytes, line 1987
1987,We=Sr.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),wme=e=>JSON.stringify(e,null,2).replace(/"([^"]+)":/g,"$1:");class is extends Error{get errors(){return this.issues}constructor(t){super(),this.issues=[],this.addIssue=n=>{this.issues=[...this.issues,n]},this.addIssues=(n=[])=>{this.issues=[...this.issues,...n]};const r=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,r):this.__proto__=r,this.name="ZodError",this.issues=t}format(t){const r=t||function(a){return a.message},n={_errors:[]},i=a=>{for(const s of a.issues)if(s.code==="invalid_union")s.unionErrors.map(i);else if(s.code==="invalid_return_type")i(s.returnTypeError);else if(s.code==="invalid_arguments")i(s.argumentsError);else if(s.path.length===0)n._errors.push(r(s));else{let o=n,c=0;for(;c<s.path.length;){const l=s.path[c];c===s.path.length-1?(o[l]=o[l]||{_errors:[]},o[l]._errors.push(r(s))):o[l]=o[l]||{_errors:[]},o=o[l],c++}}};return i(this),n}static assert(t){if(!(t instanceof is))throw new Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,Sr.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=r=>r.message){const r={},n=[];for(const i of this.issues)i.path.length>0?(r[i.path[0]]=r[i.path[0]]||[],r[i.path[0]].push(t(i))):n.push(t(i));return{formErrors:n,fieldErrors:r}}get formErrors(){return this.flatten()}}is.create=e=>new is(e);const Z0=(e,t)=>{let r;switch(e.code){case We.invalid_type:e.received===ft.undefined?r="Required":r=`Expected ${e.expected}, received ${e.received}`;break;case We.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(e.expected,Sr.jsonStringifyReplacer)}`;break;case We.unrecognized_keys:r=`Unrecognized key(s) in object: ${Sr.joinValues(e.keys,", ")}`;break;case We.invalid_union:r="Invalid input";break;case We.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${Sr.joinValues(e.options)}`;break;case We.invalid_enum_value:r=`Invalid enum value. Expected ${Sr.joinValues(e.options)}, received '${e.received}'`;break;case We.invalid_arguments:r="Invalid function arguments";break;case We.invalid_return_type:r="Invalid function return type";break;case We.invalid_date:r="Invalid date";break;case We.invalid_string:typeof e.validation=="object"?"includes"in e.validation?(r=`Invalid input: must include "${e.validation.includes}"`,typeof e.validation.position=="number"&&(r=`${r} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?r=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?r=`Invalid input: must end with "${e.validation.endsWith}"`:Sr.assertNever(e.validation):e.validation!=="regex"?r=`Invalid ${e.validation}`:r="Invalid";break;case We.too_small:e.type==="array"?r=`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:e.type==="string"?r=`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:e.type==="number"?r=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="date"?r=`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:r="Invalid input";break;case We.too_big:e.type==="array"?r=`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:e.type==="string"?r=`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:e.type==="number"?r=`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="bigint"?r=`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="date"?r=`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:r="Invalid input";break;case We.custom:r="Invalid input";break;
vendor: 4,100 bytes, line 1987
1987case We.invalid_intersection_types:r="Intersection results could not be merged";break;case We.not_multiple_of:r=`Number must be a multiple of ${e.multipleOf}`;break;case We.not_finite:r="Number must be finite";break;default:r=t.defaultError,Sr.assertNever(e)}return{message:r}};let _z=Z0;function xme(e){_z=e}function jx(){return _z}const Ix=e=>{const{data:t,path:r,errorMaps:n,issueData:i}=e,a=[...r,...i.path||[]],s={...i,path:a};if(i.message!==void 0)return{...i,path:a,message:i.message};let o="";const c=n.filter(l=>!!l).slice().reverse();for(const l of c)o=l(s,{data:t,defaultError:o}).message;return{...i,path:a,message:o}},_me=[];function lt(e,t){const r=jx(),n=Ix({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,r,r===Z0?void 0:Z0].filter(i=>!!i)});e.common.issues.push(n)}class Qi{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(t,r){const n=[];for(const i of r){if(i.status==="aborted")return $t;i.status==="dirty"&&t.dirty(),n.push(i.value)}return{status:t.value,value:n}}static async mergeObjectAsync(t,r){const n=[];for(const i of r){const a=await i.key,s=await i.value;n.push({key:a,value:s})}return Qi.mergeObjectSync(t,n)}static mergeObjectSync(t,r){const n={};for(const i of r){const{key:a,value:s}=i;if(a.status==="aborted"||s.status==="aborted")return $t;a.status==="dirty"&&t.dirty(),s.status==="dirty"&&t.dirty(),a.value!=="__proto__"&&(typeof s.value<"u"||i.alwaysSet)&&(n[a.value]=s.value)}return{status:t.value,value:n}}}const $t=Object.freeze({status:"aborted"}),Ox=e=>({status:"dirty",value:e}),ea=e=>({status:"valid",value:e}),FS=e=>e.status==="aborted",PS=e=>e.status==="dirty",Th=e=>e.status==="valid",gb=e=>typeof Promise<"u"&&e instanceof Promise;function Bx(e,t,r,n){if(typeof t=="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t.get(e)}function Sz(e,t,r,n,i){if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return t.set(e,r),r}var _t;(function(e){e.errToObj=t=>typeof t=="string"?{message:t}:t||{},e.toString=t=>typeof t=="string"?t:t==null?void 0:t.message})(_t||(_t={}));var bb,yb;class ml{constructor(t,r,n,i){this._cachedPath=[],this.parent=t,this.data=r,this._path=n,this._key=i}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const kz=(e,t)=>{if(Th(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const r=new is(e.common.issues);return this._error=r,this._error}}};function er(e){if(!e)return{};const{errorMap:t,invalid_type_error:r,required_error:n,description:i}=e;if(t&&(r||n))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return t?{errorMap:t,description:i}:{errorMap:(a,s)=>{var o,c;const{message:l}=e;return a.code==="invalid_enum_value"?{message:l??s.defaultError}:typeof s.data>"u"?{message:(o=l??n)!==null&&o!==void 0?o:s.defaultError}:a.code!=="invalid_type"?{message:s.defaultError}:{message:(c=l??r)!==null&&c!==void 0?c:s.defaultError}},description:i}}class nr{get description(){return this._def.description}_getType(t){return Cc(t.data)}_getOrReturnCtx(t,r){return r||{common:t.parent.common,data:t.data,parsedType:Cc(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new Qi,ctx:{common:t.parent.common,data:t.data,parsedType:Cc(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){const r=this._parse(t);if(gb(r))throw new Error("Synchronous parse encountered promise.");return r}_parseAsync(t){const r=this._parse(t);return Promise.resolve(r)}parse(t,r){const n=this.safeParse(t,r);
vendor: 44,724 bytes, line 1987
1987if(n.success)return n.data;throw n.error}safeParse(t,r){var n;const i={common:{issues:[],async:(n=r==null?void 0:r.async)!==null&&n!==void 0?n:!1,contextualErrorMap:r==null?void 0:r.errorMap},path:(r==null?void 0:r.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Cc(t)},a=this._parseSync({data:t,path:i.path,parent:i});return kz(i,a)}"~validate"(t){var r,n;const i={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Cc(t)};if(!this["~standard"].async)try{const a=this._parseSync({data:t,path:[],parent:i});return Th(a)?{value:a.value}:{issues:i.common.issues}}catch(a){!((n=(r=a==null?void 0:a.message)===null||r===void 0?void 0:r.toLowerCase())===null||n===void 0)&&n.includes("encountered")&&(this["~standard"].async=!0),i.common={issues:[],async:!0}}return this._parseAsync({data:t,path:[],parent:i}).then(a=>Th(a)?{value:a.value}:{issues:i.common.issues})}async parseAsync(t,r){const n=await this.safeParseAsync(t,r);if(n.success)return n.data;throw n.error}async safeParseAsync(t,r){const n={common:{issues:[],contextualErrorMap:r==null?void 0:r.errorMap,async:!0},path:(r==null?void 0:r.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Cc(t)},i=this._parse({data:t,path:n.path,parent:n}),a=await(gb(i)?i:Promise.resolve(i));return kz(n,a)}refine(t,r){const n=i=>typeof r=="string"||typeof r>"u"?{message:r}:typeof r=="function"?r(i):r;return this._refinement((i,a)=>{const s=t(i),o=()=>a.addIssue({code:We.custom,...n(i)});return typeof Promise<"u"&&s instanceof Promise?s.then(c=>c?!0:(o(),!1)):s?!0:(o(),!1)})}refinement(t,r){return this._refinement((n,i)=>t(n)?!0:(i.addIssue(typeof r=="function"?r(n,i):r),!1))}_refinement(t){return new So({schema:this,typeName:Ut.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}constructor(t){this.spa=this.safeParseAsync,this._def=t,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:r=>this["~validate"](r)}}optional(){return ko.create(this,this._def)}nullable(){return Hu.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return _o.create(this)}promise(){return K0.create(this,this._def)}or(t){return _b.create([this,t],this._def)}and(t){return Sb.create(this,t,this._def)}transform(t){return new So({...er(this._def),schema:this,typeName:Ut.ZodEffects,effect:{type:"transform",transform:t}})}default(t){const r=typeof t=="function"?t:()=>t;return new Cb({...er(this._def),innerType:this,defaultValue:r,typeName:Ut.ZodDefault})}brand(){return new DS({typeName:Ut.ZodBranded,type:this,...er(this._def)})}catch(t){const r=typeof t=="function"?t:()=>t;return new Tb({...er(this._def),innerType:this,catchValue:r,typeName:Ut.ZodCatch})}describe(t){const r=this.constructor;return new r({...this._def,description:t})}pipe(t){return jb.create(this,t)}readonly(){return Ib.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const Sme=/^c[^\s-]{8,}$/i,kme=/^[0-9a-z]+$/,Eme=/^[0-9A-HJKMNP-TV-Z]{26}$/i,Mme=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,Ame=/^[a-z0-9_-]{21}$/i,Cme=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,Tme=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,jme=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,Ime="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let zS;const Ome=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,Bme=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,Rme=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,Nme=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Fme=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,Pme=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Ez="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",zme=new RegExp(`^${Ez}$`);function Mz(e){let t="([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";return e.precision?t=`${t}\\.\\d{${e.precision}}`:e.precision==null&&(t=`${t}(\\.\\d+)?`),t}function Lme(e){return new RegExp(`^${Mz(e)}$`)}function Az(e){let t=`${Ez}T${Mz(e)}`;const r=[];return r.push(e.local?"Z?":"Z"),e.offset&&r.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${r.join("|")})`,new RegExp(`^${t}$`)}function Dme(e,t){return!!((t==="v4"||!t)&&Ome.test(e)||(t==="v6"||!t)&&Rme.test(e))}function Ume(e,t){if(!Cme.test(e))return!1;try{const[r]=e.split("."),n=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),i=JSON.parse(atob(n));return!(typeof i!="object"||i===null||!i.typ||!i.alg||t&&i.alg!==t)}catch{return!1}}function qme(e,t){return!!((t==="v4"||!t)&&Bme.test(e)||(t==="v6"||!t)&&Nme.test(e))}class xo extends nr{_parse(t){if(this._def.coerce&&(t.data=String(t.data)),this._getType(t)!==ft.string){const i=this._getOrReturnCtx(t);return lt(i,{code:We.invalid_type,expected:ft.string,received:i.parsedType}),$t}const r=new Qi;let n;for(const i of this._def.checks)if(i.kind==="min")t.data.length<i.value&&(n=this._getOrReturnCtx(t,n),lt(n,{code:We.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),r.dirty());else if(i.kind==="max")t.data.length>i.value&&(n=this._getOrReturnCtx(t,n),lt(n,{code:We.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),r.dirty());else if(i.kind==="length"){const a=t.data.length>i.value,s=t.data.length<i.value;(a||s)&&(n=this._getOrReturnCtx(t,n),a?lt(n,{code:We.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}):s&&lt(n,{code:We.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}),r.dirty())}else if(i.kind==="email")jme.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"email",code:We.invalid_string,message:i.message}),r.dirty());else if(i.kind==="emoji")zS||(zS=new RegExp(Ime,"u")),zS.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"emoji",code:We.invalid_string,message:i.message}),r.dirty());else if(i.kind==="uuid")Mme.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"uuid",code:We.invalid_string,message:i.message}),r.dirty());else if(i.kind==="nanoid")Ame.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"nanoid",code:We.invalid_string,message:i.message}),r.dirty());else if(i.kind==="cuid")Sme.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"cuid",code:We.invalid_string,message:i.message}),r.dirty());else if(i.kind==="cuid2")kme.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"cuid2",code:We.invalid_string,message:i.message}),r.dirty());else if(i.kind==="ulid")Eme.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"ulid",code:We.invalid_string,message:i.message}),r.dirty());else if(i.kind==="url")try{new URL(t.data)}catch{n=this._getOrReturnCtx(t,n),lt(n,{validation:"url",code:We.invalid_string,message:i.message}),r.dirty()}else i.kind==="regex"?(i.regex.lastIndex=0,i.regex.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"regex",code:We.invalid_string,message:i.message}),r.dirty())):i.kind==="trim"?t.data=t.data.trim():i.kind==="includes"?t.data.includes(i.value,i.position)||(n=this._getOrReturnCtx(t,n),lt(n,{code:We.invalid_string,validation:{includes:i.value,position:i.position},message:i.message}),r.dirty()):i.kind==="toLowerCase"?t.data=t.data.toLowerCase():i.kind==="toUpperCase"?t.data=t.data.toUpperCase():i.kind==="startsWith"?t.data.startsWith(i.value)||(n=this._getOrReturnCtx(t,n),lt(n,{code:We.invalid_string,validation:{startsWith:i.value},message:i.message}),r.dirty()):i.kind==="endsWith"?t.data.endsWith(i.value)||(n=this._getOrReturnCtx(t,n),lt(n,{code:We.invalid_string,validation:{endsWith:i.value},message:i.message}),r.dirty()):i.kind==="datetime"?Az(i).test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{code:We.invalid_string,validation:"datetime",message:i.message}),r.dirty()):i.kind==="date"?zme.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{code:We.invalid_string,validation:"date",message:i.message}),r.dirty()):i.kind==="time"?Lme(i).test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{code:We.invalid_string,validation:"time",message:i.message}),r.dirty()):i.kind==="duration"?Tme.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"duration",code:We.invalid_string,message:i.message}),r.dirty()):i.kind==="ip"?Dme(t.data,i.version)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"ip",code:We.invalid_string,message:i.message}),r.dirty()):i.kind==="jwt"?Ume(t.data,i.alg)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"jwt",code:We.invalid_string,message:i.message}),r.dirty()):i.kind==="cidr"?qme(t.data,i.version)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"cidr",code:We.invalid_string,message:i.message}),r.dirty()):i.kind==="base64"?Fme.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"base64",code:We.invalid_string,message:i.message}),r.dirty()):i.kind==="base64url"?Pme.test(t.data)||(n=this._getOrReturnCtx(t,n),lt(n,{validation:"base64url",code:We.invalid_string,message:i.message}),r.dirty()):Sr.assertNever(i);return{status:r.value,value:t.data}}_regex(t,r,n){return this.refinement(i=>t.test(i),{validation:r,code:We.invalid_string,..._t.errToObj(n)})}_addCheck(t){return new xo({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",..._t.errToObj(t)})}url(t){return this._addCheck({kind:"url",..._t.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",..._t.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",..._t.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",..._t.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",..._t.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",..._t.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",..._t.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",..._t.errToObj(t)})}base64url(t){return this._addCheck({kind:"base64url",..._t.errToObj(t)})}jwt(t){return this._addCheck({kind:"jwt",..._t.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",..._t.errToObj(t)})}cidr(t){return this._addCheck({kind:"cidr",..._t.errToObj(t)})}datetime(t){var r,n;return typeof t=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:t}):this._addCheck({kind:"datetime",precision:typeof(t==null?void 0:t.precision)>"u"?null:t==null?void 0:t.precision,offset:(r=t==null?void 0:t.offset)!==null&&r!==void 0?r:!1,local:(n=t==null?void 0:t.local)!==null&&n!==void 0?n:!1,..._t.errToObj(t==null?void 0:t.message)})}date(t){return this._addCheck({kind:"date",message:t})}time(t){return typeof t=="string"?this._addCheck({kind:"time",precision:null,message:t}):this._addCheck({kind:"time",precision:typeof(t==null?void 0:t.precision)>"u"?null:t==null?void 0:t.precision,..._t.errToObj(t==null?void 0:t.message)})}duration(t){return this._addCheck({kind:"duration",..._t.errToObj(t)})}regex(t,r){return this._addCheck({kind:"regex",regex:t,..._t.errToObj(r)})}includes(t,r){return this._addCheck({kind:"includes",value:t,position:r==null?void 0:r.position,..._t.errToObj(r==null?void 0:r.message)})}startsWith(t,r){return this._addCheck({kind:"startsWith",value:t,..._t.errToObj(r)})}endsWith(t,r){return this._addCheck({kind:"endsWith",value:t,..._t.errToObj(r)})}min(t,r){return this._addCheck({kind:"min",value:t,..._t.errToObj(r)})}max(t,r){return this._addCheck({kind:"max",value:t,..._t.errToObj(r)})}length(t,r){return this._addCheck({kind:"length",value:t,..._t.errToObj(r)})}nonempty(t){return this.min(1,_t.errToObj(t))}trim(){return new xo({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new xo({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new xo({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(t=>t.kind==="datetime")}get isDate(){return!!this._def.checks.find(t=>t.kind==="date")}get isTime(){return!!this._def.checks.find(t=>t.kind==="time")}get isDuration(){return!!this._def.checks.find(t=>t.kind==="duration")}get isEmail(){return!!this._def.checks.find(t=>t.kind==="email")}get isURL(){return!!this._def.checks.find(t=>t.kind==="url")}get isEmoji(){return!!this._def.checks.find(t=>t.kind==="emoji")}get isUUID(){return!!this._def.checks.find(t=>t.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(t=>t.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(t=>t.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(t=>t.kind==="cuid2")}get isULID(){return!!this._def.checks.find(t=>t.kind==="ulid")}get isIP(){return!!this._def.checks.find(t=>t.kind==="ip")}get isCIDR(){return!!this._def.checks.find(t=>t.kind==="cidr")}get isBase64(){return!!this._def.checks.find(t=>t.kind==="base64")}get isBase64url(){return!!this._def.checks.find(t=>t.kind==="base64url")}get minLength(){let t=null;for(const r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t}get maxLength(){let t=null;for(const r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t}}xo.create=e=>{var t;return new xo({checks:[],typeName:Ut.ZodString,coerce:(t=e==null?void 0:e.coerce)!==null&&t!==void 0?t:!1,...er(e)})};function Vme(e,t){const r=(e.toString().split(".")[1]||"").length,n=(t.toString().split(".")[1]||"").length,i=r>n?r:n,a=parseInt(e.toFixed(i).replace(".","")),s=parseInt(t.toFixed(i).replace(".",""));return a%s/Math.pow(10,i)}class qu extends nr{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce&&(t.data=Number(t.data)),this._getType(t)!==ft.number){const i=this._getOrReturnCtx(t);return lt(i,{code:We.invalid_type,expected:ft.number,received:i.parsedType}),$t}let r;const n=new Qi;for(const i of this._def.checks)i.kind==="int"?Sr.isInteger(t.data)||(r=this._getOrReturnCtx(t,r),lt(r,{code:We.invalid_type,expected:"integer",received:"float",message:i.message}),n.dirty()):i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(r=this._getOrReturnCtx(t,r),lt(r,{code:We.too_small,minimum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),n.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(r=this._getOrReturnCtx(t,r),lt(r,{code:We.too_big,maximum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),n.dirty()):i.kind==="multipleOf"?Vme(t.data,i.value)!==0&&(r=this._getOrReturnCtx(t,r),lt(r,{code:We.not_multiple_of,multipleOf:i.value,message:i.message}),n.dirty()):i.kind==="finite"?Number.isFinite(t.data)||(r=this._getOrReturnCtx(t,r),lt(r,{code:We.not_finite,message:i.message}),n.dirty()):Sr.assertNever(i);return{status:n.value,value:t.data}}gte(t,r){return this.setLimit("min",t,!0,_t.toString(r))}gt(t,r){return this.setLimit("min",t,!1,_t.toString(r))}lte(t,r){return this.setLimit("max",t,!0,_t.toString(r))}lt(t,r){return this.setLimit("max",t,!1,_t.toString(r))}setLimit(t,r,n,i){return new qu({...this._def,checks:[...this._def.checks,{kind:t,value:r,inclusive:n,message:_t.toString(i)}]})}_addCheck(t){return new qu({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:_t.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:_t.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:_t.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:_t.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:_t.toString(t)})}multipleOf(t,r){return this._addCheck({kind:"multipleOf",value:t,message:_t.toString(r)})}finite(t){return this._addCheck({kind:"finite",message:_t.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:_t.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:_t.toString(t)})}get minValue(){let t=null;for(const r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t}get maxValue(){let t=null;for(const r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t}get isInt(){return!!this._def.checks.find(t=>t.kind==="int"||t.kind==="multipleOf"&&Sr.isInteger(t.value))}get isFinite(){let t=null,r=null;for(const n of this._def.checks){if(n.kind==="finite"||n.kind==="int"||n.kind==="multipleOf")return!0;n.kind==="min"?(r===null||n.value>r)&&(r=n.value):n.kind==="max"&&(t===null||n.value<t)&&(t=n.value)}return Number.isFinite(r)&&Number.isFinite(t)}}qu.create=e=>new qu({checks:[],typeName:Ut.ZodNumber,coerce:(e==null?void 0:e.coerce)||!1,...er(e)});class Vu extends nr{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce)try{t.data=BigInt(t.data)}catch{return this._getInvalidInput(t)}if(this._getType(t)!==ft.bigint)return this._getInvalidInput(t);let r;const n=new Qi;for(const i of this._def.checks)i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(r=this._getOrReturnCtx(t,r),lt(r,{code:We.too_small,type:"bigint",minimum:i.value,inclusive:i.inclusive,message:i.message}),n.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(r=this._getOrReturnCtx(t,r),lt(r,{code:We.too_big,type:"bigint",maximum:i.value,inclusive:i.inclusive,message:i.message}),n.dirty()):i.kind==="multipleOf"?t.data%i.value!==BigInt(0)&&(r=this._getOrReturnCtx(t,r),lt(r,{code:We.not_multiple_of,multipleOf:i.value,message:i.message}),n.dirty()):Sr.assertNever(i);return{status:n.value,value:t.data}}_getInvalidInput(t){const r=this._getOrReturnCtx(t);return lt(r,{code:We.invalid_type,expected:ft.bigint,received:r.parsedType}),$t}gte(t,r){return this.setLimit("min",t,!0,_t.toString(r))}gt(t,r){return this.setLimit("min",t,!1,_t.toString(r))}lte(t,r){return this.setLimit("max",t,!0,_t.toString(r))}lt(t,r){return this.setLimit("max",t,!1,_t.toString(r))}setLimit(t,r,n,i){return new Vu({...this._def,checks:[...this._def.checks,{kind:t,value:r,inclusive:n,message:_t.toString(i)}]})}_addCheck(t){return new Vu({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:_t.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:_t.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:_t.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:_t.toString(t)})}multipleOf(t,r){return this._addCheck({kind:"multipleOf",value:t,message:_t.toString(r)})}get minValue(){let t=null;for(const r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t}get maxValue(){let t=null;for(const r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t}}Vu.create=e=>{var t;return new Vu({checks:[],typeName:Ut.ZodBigInt,coerce:(t=e==null?void 0:e.coerce)!==null&&t!==void 0?t:!1,...er(e)})};class vb extends nr{_parse(t){if(this._def.coerce&&(t.data=!!t.data),this._getType(t)!==ft.boolean){const r=this._getOrReturnCtx(t);return lt(r,{code:We.invalid_type,expected:ft.boolean,received:r.parsedType}),$t}return ea(t.data)}}vb.create=e=>new vb({typeName:Ut.ZodBoolean,coerce:(e==null?void 0:e.coerce)||!1,...er(e)});class jh extends nr{_parse(t){if(this._def.coerce&&(t.data=new Date(t.data)),this._getType(t)!==ft.date){const i=this._getOrReturnCtx(t);return lt(i,{code:We.invalid_type,expected:ft.date,received:i.parsedType}),$t}if(isNaN(t.data.getTime())){const i=this._getOrReturnCtx(t);return lt(i,{code:We.invalid_date}),$t}const r=new Qi;let n;for(const i of this._def.checks)i.kind==="min"?t.data.getTime()<i.value&&(n=this._getOrReturnCtx(t,n),lt(n,{code:We.too_small,message:i.message,inclusive:!0,exact:!1,minimum:i.value,type:"date"}),r.dirty()):i.kind==="max"?t.data.getTime()>i.value&&(n=this._getOrReturnCtx(t,n),lt(n,{code:We.too_big,message:i.message,inclusive:!0,exact:!1,maximum:i.value,type:"date"}),r.dirty()):Sr.assertNever(i);return{status:r.value,value:new Date(t.data.getTime())}}_addCheck(t){return new jh({...this._def,checks:[...this._def.checks,t]})}min(t,r){return this._addCheck({kind:"min",value:t.getTime(),message:_t.toString(r)})}max(t,r){return this._addCheck({kind:"max",value:t.getTime(),message:_t.toString(r)})}get minDate(){let t=null;for(const r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t!=null?new Date(t):null}get maxDate(){let t=null;for(const r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t!=null?new Date(t):null}}jh.create=e=>new jh({checks:[],coerce:(e==null?void 0:e.coerce)||!1,typeName:Ut.ZodDate,...er(e)});class Rx extends nr{_parse(t){if(this._getType(t)!==ft.symbol){const r=this._getOrReturnCtx(t);return lt(r,{code:We.invalid_type,expected:ft.symbol,received:r.parsedType}),$t}return ea(t.data)}}Rx.create=e=>new Rx({typeName:Ut.ZodSymbol,...er(e)});class wb extends nr{_parse(t){if(this._getType(t)!==ft.undefined){const r=this._getOrReturnCtx(t);return lt(r,{code:We.invalid_type,expected:ft.undefined,received:r.parsedType}),$t}return ea(t.data)}}wb.create=e=>new wb({typeName:Ut.ZodUndefined,...er(e)});class xb extends nr{_parse(t){if(this._getType(t)!==ft.null){const r=this._getOrReturnCtx(t);return lt(r,{code:We.invalid_type,expected:ft.null,received:r.parsedType}),$t}return ea(t.data)}}xb.create=e=>new xb({typeName:Ut.ZodNull,...er(e)});class $0 extends nr{constructor(){super(...arguments),this._any=!0}_parse(t){return ea(t.data)}}$0.create=e=>new $0({typeName:Ut.ZodAny,...er(e)});class Ih extends nr{constructor(){super(...arguments),this._unknown=!0}_parse(t){return ea(t.data)}}Ih.create=e=>new Ih({typeName:Ut.ZodUnknown,...er(e)});class Tc extends nr{_parse(t){const r=this._getOrReturnCtx(t);return lt(r,{code:We.invalid_type,expected:ft.never,received:r.parsedType}),$t}}Tc.create=e=>new Tc({typeName:Ut.ZodNever,...er(e)});class Nx extends nr{_parse(t){if(this._getType(t)!==ft.undefined){const r=this._getOrReturnCtx(t);return lt(r,{code:We.invalid_type,expected:ft.void,received:r.parsedType}),$t}return ea(t.data)}}Nx.create=e=>new Nx({typeName:Ut.ZodVoid,...er(e)});class _o extends nr{_parse(t){const{ctx:r,status:n}=this._processInputParams(t),i=this._def;if(r.parsedType!==ft.array)return lt(r,{code:We.invalid_type,expected:ft.array,received:r.parsedType}),$t;if(i.exactLength!==null){const s=r.data.length>i.exactLength.value,o=r.data.length<i.exactLength.value;(s||o)&&(lt(r,{code:s?We.too_big:We.too_small,minimum:o?i.exactLength.value:void 0,maximum:s?i.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:i.exactLength.message}),n.dirty())}if(i.minLength!==null&&r.data.length<i.minLength.value&&(lt(r,{code:We.too_small,minimum:i.minLength.value,type:"array",inclusive:!0,exact:!1,message:i.minLength.message}),n.dirty()),i.maxLength!==null&&r.data.length>i.maxLength.value&&(lt(r,{code:We.too_big,maximum:i.maxLength.value,type:"array",inclusive:!0,exact:!1,message:i.maxLength.message}),n.dirty()),r.common.async)return Promise.all([...r.data].map((s,o)=>i.type._parseAsync(new ml(r,s,r.path,o)))).then(s=>Qi.mergeArray(n,s));const a=[...r.data].map((s,o)=>i.type._parseSync(new ml(r,s,r.path,o)));return Qi.mergeArray(n,a)}get element(){return this._def.type}min(t,r){return new _o({...this._def,minLength:{value:t,message:_t.toString(r)}})}max(t,r){return new _o({...this._def,maxLength:{value:t,message:_t.toString(r)}})}length(t,r){return new _o({...this._def,exactLength:{value:t,message:_t.toString(r)}})}nonempty(t){return this.min(1,t)}}_o.create=(e,t)=>new _o({type:e,minLength:null,maxLength:null,exactLength:null,typeName:Ut.ZodArray,...er(t)});function H0(e){if(e instanceof xn){const t={};for(const r in e.shape){const n=e.shape[r];t[r]=ko.create(H0(n))}return new xn({...e._def,shape:()=>t})}else return e instanceof _o?new _o({...e._def,type:H0(e.element)}):e instanceof ko?ko.create(H0(e.unwrap())):e instanceof Hu?Hu.create(H0(e.unwrap())):e instanceof gl?gl.create(e.items.map(t=>H0(t))):e}class xn extends nr{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const t=this._def.shape(),r=Sr.objectKeys(t);return this._cached={shape:t,keys:r}}_parse(t){if(this._getType(t)!==ft.object){const c=this._getOrReturnCtx(t);return lt(c,{code:We.invalid_type,expected:ft.object,received:c.parsedType}),$t}const{status:r,ctx:n}=this._processInputParams(t),{shape:i,keys:a}=this._getCached(),s=[];if(!(this._def.catchall instanceof Tc&&this._def.unknownKeys==="strip"))for(const c in n.data)a.includes(c)||s.push(c);const o=[];for(const c of a){const l=i[c],u=n.data[c];o.push({key:{status:"valid",value:c},value:l._parse(new ml(n,u,n.path,c)),alwaysSet:c in n.data})}if(this._def.catchall instanceof Tc){const c=this._def.unknownKeys;if(c==="passthrough")for(const l of s)o.push({key:{status:"valid",value:l},value:{status:"valid",value:n.data[l]}});else if(c==="strict")s.length>0&&(lt(n,{code:We.unrecognized_keys,keys:s}),r.dirty());else if(c!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const c=this._def.catchall;for(const l of s){const u=n.data[l];o.push({key:{status:"valid",value:l},value:c._parse(new ml(n,u,n.path,l)),alwaysSet:l in n.data})}}return n.common.async?Promise.resolve().then(async()=>{const c=[];for(const l of o){const u=await l.key,d=await l.value;c.push({key:u,value:d,alwaysSet:l.alwaysSet})}return c}).then(c=>Qi.mergeObjectSync(r,c)):Qi.mergeObjectSync(r,o)}get shape(){return this._def.shape()}strict(t){return _t.errToObj,new xn({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(r,n)=>{var i,a,s,o;const c=(s=(a=(i=this._def).errorMap)===null||a===void 0?void 0:a.call(i,r,n).message)!==null&&s!==void 0?s:n.defaultError;return r.code==="unrecognized_keys"?{message:(o=_t.errToObj(t).message)!==null&&o!==void 0?o:c}:{message:c}}}:{}})}strip(){return new xn({...this._def,unknownKeys:"strip"})}passthrough(){return new xn({...this._def,unknownKeys:"passthrough"})}extend(t){return new xn({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new xn({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:Ut.ZodObject})}setKey(t,r){return this.augment({[t]:r})}catchall(t){return new xn({...this._def,catchall:t})}pick(t){const r={};return Sr.objectKeys(t).forEach(n=>{t[n]&&this.shape[n]&&(r[n]=this.shape[n])}),new xn({...this._def,shape:()=>r})}omit(t){const r={};return Sr.objectKeys(this.shape).forEach(n=>{t[n]||(r[n]=this.shape[n])}),new xn({...this._def,shape:()=>r})}deepPartial(){return H0(this)}partial(t){const r={};return Sr.objectKeys(this.shape).forEach(n=>{const i=this.shape[n];t&&!t[n]?r[n]=i:r[n]=i.optional()}),new xn({...this._def,shape:()=>r})}required(t){const r={};return Sr.objectKeys(this.shape).forEach(n=>{if(t&&!t[n])r[n]=this.shape[n];else{let i=this.shape[n];for(;i instanceof ko;)i=i._def.innerType;r[n]=i}}),new xn({...this._def,shape:()=>r})}keyof(){return Cz(Sr.objectKeys(this.shape))}}xn.create=(e,t)=>new xn({shape:()=>e,unknownKeys:"strip",catchall:Tc.create(),typeName:Ut.ZodObject,...er(t)}),xn.strictCreate=(e,t)=>new xn({shape:()=>e,unknownKeys:"strict",catchall:Tc.create(),typeName:Ut.ZodObject,...er(t)}),xn.lazycreate=(e,t)=>new xn({shape:e,unknownKeys:"strip",catchall:Tc.create(),typeName:Ut.ZodObject,...er(t)});class _b extends nr{_parse(t){const{ctx:r}=this._processInputParams(t),n=this._def.options;function i(a){for(const o of a)if(o.result.status==="valid")return o.result;for(const o of a)if(o.result.status==="dirty")return r.common.issues.push(...o.ctx.common.issues),o.result;const s=a.map(o=>new is(o.ctx.common.issues));return lt(r,{code:We.invalid_union,unionErrors:s}),$t}if(r.common.async)return Promise.all(n.map(async a=>{const s={...r,common:{...r.common,issues:[]},parent:null};return{result:await a._parseAsync({data:r.data,path:r.path,parent:s}),ctx:s}})).then(i);{let a;const s=[];for(const c of n){const l={...r,common:{...r.common,issues:[]},parent:null},u=c._parseSync({data:r.data,path:r.path,parent:l});if(u.status==="valid")return u;u.status==="dirty"&&!a&&(a={result:u,ctx:l}),l.common.issues.length&&s.push(l.common.issues)}if(a)return r.common.issues.push(...a.ctx.common.issues),a.result;const o=s.map(c=>new is(c));return lt(r,{code:We.invalid_union,unionErrors:o}),$t}}get options(){return this._def.options}}_b.create=(e,t)=>new _b({options:e,typeName:Ut.ZodUnion,...er(t)});const Zu=e=>e instanceof Eb?Zu(e.schema):e instanceof So?Zu(e.innerType()):e instanceof Mb?[e.value]:e instanceof $u?e.options:e instanceof Ab?Sr.objectValues(e.enum):e instanceof Cb?Zu(e._def.innerType):e instanceof wb?[void 0]:e instanceof xb?[null]:e instanceof ko?[void 0,...Zu(e.unwrap())]:e instanceof Hu?[null,...Zu(e.unwrap())]:e instanceof DS||e instanceof Ib?Zu(e.unwrap()):e instanceof Tb?Zu(e._def.innerType):[];class Fx extends nr{_parse(t){const{ctx:r}=this._processInputParams(t);if(r.parsedType!==ft.object)return lt(r,{code:We.invalid_type,expected:ft.object,received:r.parsedType}),$t;const n=this.discriminator,i=r.data[n],a=this.optionsMap.get(i);return a?r.common.async?a._parseAsync({data:r.data,path:r.path,parent:r}):a._parseSync({data:r.data,path:r.path,parent:r}):(lt(r,{code:We.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[n]}),$t)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,r,n){const i=new Map;for(const a of r){const s=Zu(a.shape[t]);if(!s.length)throw new Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(const o of s){if(i.has(o))throw new Error(`Discriminator property ${String(t)} has duplicate value ${String(o)}`);i.set(o,a)}}return new Fx({typeName:Ut.ZodDiscriminatedUnion,discriminator:t,options:r,optionsMap:i,...er(n)})}}function LS(e,t){const r=Cc(e),n=Cc(t);if(e===t)return{valid:!0,data:e};if(r===ft.object&&n===ft.object){const i=Sr.objectKeys(t),a=Sr.objectKeys(e).filter(o=>i.indexOf(o)!==-1),s={...e,...t};for(const o of a){const c=LS(e[o],t[o]);if(!c.valid)return{valid:!1};s[o]=c.data}return{valid:!0,data:s}}else if(r===ft.array&&n===ft.array){if(e.length!==t.length)return{valid:!1};const i=[];for(let a=0;a<e.length;a++){const s=e[a],o=t[a],c=LS(s,o);if(!c.valid)return{valid:!1};i.push(c.data)}return{valid:!0,data:i}}else return r===ft.date&&n===ft.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}class Sb extends nr{_parse(t){const{status:r,ctx:n}=this._processInputParams(t),i=(a,s)=>{if(FS(a)||FS(s))return $t;const o=LS(a.value,s.value);return o.valid?((PS(a)||PS(s))&&r.dirty(),{status:r.value,value:o.data}):(lt(n,{code:We.invalid_intersection_types}),$t)};return n.common.async?Promise.all([this._def.left._parseAsync({data:n.data,path:n.path,parent:n}),this._def.right._parseAsync({data:n.data,path:n.path,parent:n})]).then(([a,s])=>i(a,s)):i(this._def.left._parseSync({data:n.data,path:n.path,parent:n}),this._def.right._parseSync({data:n.data,path:n.path,parent:n}))}}Sb.create=(e,t,r)=>new Sb({left:e,right:t,typeName:Ut.ZodIntersection,...er(r)});class gl extends nr{_parse(t){const{status:r,ctx:n}=this._processInputParams(t);if(n.parsedType!==ft.array)return lt(n,{code:We.invalid_type,expected:ft.array,received:n.parsedType}),$t;if(n.data.length<this._def.items.length)return lt(n,{code:We.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),$t;!this._def.rest&&n.data.length>this._def.items.length&&(lt(n,{code:We.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),r.dirty());const i=[...n.data].map((a,s)=>{const o=this._def.items[s]||this._def.rest;return o?o._parse(new ml(n,a,n.path,s)):null}).filter(a=>!!a);return n.common.async?Promise.all(i).then(a=>Qi.mergeArray(r,a)):Qi.mergeArray(r,i)}get items(){return this._def.items}rest(t){return new gl({...this._def,rest:t})}}gl.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new gl({items:e,typeName:Ut.ZodTuple,rest:null,...er(t)})};class kb extends nr{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){const{status:r,ctx:n}=this._processInputParams(t);if(n.parsedType!==ft.object)return lt(n,{code:We.invalid_type,expected:ft.object,received:n.parsedType}),$t;const i=[],a=this._def.keyType,s=this._def.valueType;for(const o in n.data)i.push({key:a._parse(new ml(n,o,n.path,o)),value:s._parse(new ml(n,n.data[o],n.path,o)),alwaysSet:o in n.data});return n.common.async?Qi.mergeObjectAsync(r,i):Qi.mergeObjectSync(r,i)}get element(){return this._def.valueType}static create(t,r,n){return r instanceof nr?new kb({keyType:t,valueType:r,typeName:Ut.ZodRecord,...er(n)}):new kb({keyType:xo.create(),valueType:t,typeName:Ut.ZodRecord,...er(r)})}}class Px extends nr{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){const{status:r,ctx:n}=this._processInputParams(t);if(n.parsedType!==ft.map)return lt(n,{code:We.invalid_type,expected:ft.map,received:n.parsedType}),$t;const i=this._def.keyType,a=this._def.valueType,s=[...n.data.entries()].map(([o,c],l)=>({key:i._parse(new ml(n,o,n.path,[l,"key"])),value:a._parse(new ml(n,c,n.path,[l,"value"]))}));if(n.common.async){const o=new Map;return Promise.resolve().then(async()=>{for(const c of s){const l=await c.key,u=await c.value;if(l.status==="aborted"||u.status==="aborted")return $t;(l.status==="dirty"||u.status==="dirty")&&r.dirty(),o.set(l.value,u.value)}return{status:r.value,value:o}})}else{const o=new Map;for(const c of s){const l=c.key,u=c.value;if(l.status==="aborted"||u.status==="aborted")return $t;(l.status==="dirty"||u.status==="dirty")&&r.dirty(),o.set(l.value,u.value)}return{status:r.value,value:o}}}}Px.create=(e,t,r)=>new Px({valueType:t,keyType:e,typeName:Ut.ZodMap,...er(r)});class Oh extends nr{_parse(t){const{status:r,ctx:n}=this._processInputParams(t);if(n.parsedType!==ft.set)return lt(n,{code:We.invalid_type,expected:ft.set,received:n.parsedType}),$t;const i=this._def;i.minSize!==null&&n.data.size<i.minSize.value&&(lt(n,{code:We.too_small,minimum:i.minSize.value,type:"set",inclusive:!0,exact:!1,message:i.minSize.message}),r.dirty()),i.maxSize!==null&&n.data.size>i.maxSize.value&&(lt(n,{code:We.too_big,maximum:i.maxSize.value,type:"set",inclusive:!0,exact:!1,message:i.maxSize.message}),r.dirty());const a=this._def.valueType;function s(c){const l=new Set;for(const u of c){if(u.status==="aborted")return $t;u.status==="dirty"&&r.dirty(),l.add(u.value)}return{status:r.value,value:l}}const o=[...n.data.values()].map((c,l)=>a._parse(new ml(n,c,n.path,l)));return n.common.async?Promise.all(o).then(c=>s(c)):s(o)}min(t,r){return new Oh({...this._def,minSize:{value:t,message:_t.toString(r)}})}max(t,r){return new Oh({...this._def,maxSize:{value:t,message:_t.toString(r)}})}size(t,r){return this.min(t,r).max(t,r)}nonempty(t){return this.min(1,t)}}Oh.create=(e,t)=>new Oh({valueType:e,minSize:null,maxSize:null,typeName:Ut.ZodSet,...er(t)});class W0 extends nr{constructor(){super(...arguments),this.validate=this.implement}_parse(t){const{ctx:r}=this._processInputParams(t);if(r.parsedType!==ft.function)return lt(r,{code:We.invalid_type,expected:ft.function,received:r.parsedType}),$t;function n(o,c){return Ix({data:o,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,jx(),Z0].filter(l=>!!l),issueData:{code:We.invalid_arguments,argumentsError:c}})}function i(o,c){return Ix({data:o,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,jx(),Z0].filter(l=>!!l),issueData:{code:We.invalid_return_type,returnTypeError:c}})}const a={errorMap:r.common.contextualErrorMap},s=r.data;if(this._def.returns instanceof K0){const o=this;return ea(async function(...c){const l=new is([]),u=await o._def.args.parseAsync(c,a).catch(p=>{throw l.addIssue(n(c,p)),l}),d=await Reflect.apply(s,this,u);return await o._def.returns._def.type.parseAsync(d,a).catch(p=>{throw l.addIssue(i(d,p)),l})})}else{const o=this;return ea(function(...c){const l=o._def.args.safeParse(c,a);if(!l.success)throw new is([n(c,l.error)]);const u=Reflect.apply(s,this,l.data),d=o._def.returns.safeParse(u,a);if(!d.success)throw new is([i(u,d.error)]);return d.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...t){return new W0({...this._def,args:gl.create(t).rest(Ih.create())})}returns(t){return new W0({...this._def,returns:t})}implement(t){return this.parse(t)}strictImplement(t){return this.parse(t)}static create(t,r,n){return new W0({args:t||gl.create([]).rest(Ih.create()),returns:r||Ih.create(),typeName:Ut.ZodFunction,...er(n)})}}class Eb extends nr{get schema(){return this._def.getter()}_parse(t){const{ctx:r}=this._processInputParams(t);return this._def.getter()._parse({data:r.data,path:r.path,parent:r})}}Eb.create=(e,t)=>new Eb({getter:e,typeName:Ut.ZodLazy,...er(t)});class Mb extends nr{_parse(t){if(t.data!==this._def.value){const r=this._getOrReturnCtx(t);return lt(r,{received:r.data,code:We.invalid_literal,expected:this._def.value}),$t}return{status:"valid",value:t.data}}get value(){return this._def.value}}Mb.create=(e,t)=>new Mb({value:e,typeName:Ut.ZodLiteral,...er(t)});function Cz(e,t){return new $u({values:e,typeName:Ut.ZodEnum,...er(t)})}class $u extends nr{constructor(){super(...arguments),bb.set(this,void 0)}_parse(t){if(typeof t.data!="string"){const r=this._getOrReturnCtx(t),n=this._def.values;return lt(r,{expected:Sr.joinValues(n),received:r.parsedType,code:We.invalid_type}),$t}if(Bx(this,bb)||Sz(this,bb,new Set(this._def.values)),!Bx(this,bb).has(t.data)){const r=this._getOrReturnCtx(t),n=this._def.values;return lt(r,{received:r.data,code:We.invalid_enum_value,options:n}),$t}return ea(t.data)}get options(){return this._def.values}get enum(){const t={};for(const r of this._def.values)t[r]=r;return t}get Values(){const t={};for(const r of this._def.values)t[r]=r;return t}get Enum(){const t={};for(const r of this._def.values)t[r]=r;return t}extract(t,r=this._def){return $u.create(t,{...this._def,...r})}exclude(t,r=this._def){return $u.create(this.options.filter(n=>!t.includes(n)),{...this._def,...r})}}bb=new WeakMap,$u.create=Cz;class Ab extends nr{constructor(){super(...arguments),yb.set(this,void 0)}_parse(t){const r=Sr.getValidEnumValues(this._def.values),n=this._getOrReturnCtx(t);if(n.parsedType!==ft.string&&n.parsedType!==ft.number){const i=Sr.objectValues(r);return lt(n,{expected:Sr.joinValues(i),received:n.parsedType,code:We.invalid_type}),$t}if(Bx(this,yb)||Sz(this,yb,new Set(Sr.getValidEnumValues(this._def.values))),!Bx(this,yb).has(t.data)){const i=Sr.objectValues(r);return lt(n,{received:n.data,code:We.invalid_enum_value,options:i}),$t}return ea(t.data)}get enum(){return this._def.values}}yb=new WeakMap,Ab.create=(e,t)=>new Ab({values:e,typeName:Ut.ZodNativeEnum,...er(t)});class K0 extends nr{unwrap(){return this._def.type}_parse(t){const{ctx:r}=this._processInputParams(t);if(r.parsedType!==ft.promise&&r.common.async===!1)return lt(r,{code:We.invalid_type,expected:ft.promise,received:r.parsedType}),$t;const n=r.parsedType===ft.promise?r.data:Promise.resolve(r.data);return ea(n.then(i=>this._def.type.parseAsync(i,{path:r.path,errorMap:r.common.contextualErrorMap})))}}K0.create=(e,t)=>new K0({type:e,typeName:Ut.ZodPromise,...er(t)});class So extends nr{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===Ut.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){const{status:r,ctx:n}=this._processInputParams(t),i=this._def.effect||null,a={addIssue:s=>{lt(n,s),s.fatal?r.abort():r.dirty()},get path(){return n.path}};if(a.addIssue=a.addIssue.bind(a),i.type==="preprocess"){const s=i.transform(n.data,a);if(n.common.async)return Promise.resolve(s).then(async o=>{if(r.value==="aborted")return $t;const c=await this._def.schema._parseAsync({data:o,path:n.path,parent:n});return c.status==="aborted"?$t:c.status==="dirty"||r.value==="dirty"?Ox(c.value):c});{if(r.value==="aborted")return $t;const o=this._def.schema._parseSync({data:s,path:n.path,parent:n});return o.status==="aborted"?$t:o.status==="dirty"||r.value==="dirty"?Ox(o.value):o}}if(i.type==="refinement"){const s=o=>{const c=i.refinement(o,a);if(n.common.async)return Promise.resolve(c);if(c instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return o};if(n.common.async===!1){const o=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});return o.status==="aborted"?$t:(o.status==="dirty"&&r.dirty(),s(o.value),{status:r.value,value:o.value})}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(o=>o.status==="aborted"?$t:(o.status==="dirty"&&r.dirty(),s(o.value).then(()=>({status:r.value,value:o.value}))))}if(i.type==="transform")if(n.common.async===!1){const s=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});if(!Th(s))return s;const o=i.transform(s.value,a);if(o instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:r.value,value:o}}else return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then(s=>Th(s)?Promise.resolve(i.transform(s.value,a)).then(o=>({status:r.value,value:o})):s);Sr.assertNever(i)}}So.create=(e,t,r)=>new So({schema:e,typeName:Ut.ZodEffects,effect:t,...er(r)}),So.createWithPreprocess=(e,t,r)=>new So({schema:t,effect:{type:"preprocess",transform:e},typeName:Ut.ZodEffects,...er(r)});class ko extends nr{_parse(t){return this._getType(t)===ft.undefined?ea(void 0):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}ko.create=(e,t)=>
vendor: 6,160 bytes, line 1987
1987new ko({innerType:e,typeName:Ut.ZodOptional,...er(t)});class Hu extends nr{_parse(t){return this._getType(t)===ft.null?ea(null):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}Hu.create=(e,t)=>new Hu({innerType:e,typeName:Ut.ZodNullable,...er(t)});class Cb extends nr{_parse(t){const{ctx:r}=this._processInputParams(t);let n=r.data;return r.parsedType===ft.undefined&&(n=this._def.defaultValue()),this._def.innerType._parse({data:n,path:r.path,parent:r})}removeDefault(){return this._def.innerType}}Cb.create=(e,t)=>new Cb({innerType:e,typeName:Ut.ZodDefault,defaultValue:typeof t.default=="function"?t.default:()=>t.default,...er(t)});class Tb extends nr{_parse(t){const{ctx:r}=this._processInputParams(t),n={...r,common:{...r.common,issues:[]}},i=this._def.innerType._parse({data:n.data,path:n.path,parent:{...n}});return gb(i)?i.then(a=>({status:"valid",value:a.status==="valid"?a.value:this._def.catchValue({get error(){return new is(n.common.issues)},input:n.data})})):{status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new is(n.common.issues)},input:n.data})}}removeCatch(){return this._def.innerType}}Tb.create=(e,t)=>new Tb({innerType:e,typeName:Ut.ZodCatch,catchValue:typeof t.catch=="function"?t.catch:()=>t.catch,...er(t)});class zx extends nr{_parse(t){if(this._getType(t)!==ft.nan){const r=this._getOrReturnCtx(t);return lt(r,{code:We.invalid_type,expected:ft.nan,received:r.parsedType}),$t}return{status:"valid",value:t.data}}}zx.create=e=>new zx({typeName:Ut.ZodNaN,...er(e)});const Zme=Symbol("zod_brand");class DS extends nr{_parse(t){const{ctx:r}=this._processInputParams(t),n=r.data;return this._def.type._parse({data:n,path:r.path,parent:r})}unwrap(){return this._def.type}}class jb extends nr{_parse(t){const{status:r,ctx:n}=this._processInputParams(t);if(n.common.async)return(async()=>{const i=await this._def.in._parseAsync({data:n.data,path:n.path,parent:n});return i.status==="aborted"?$t:i.status==="dirty"?(r.dirty(),Ox(i.value)):this._def.out._parseAsync({data:i.value,path:n.path,parent:n})})();{const i=this._def.in._parseSync({data:n.data,path:n.path,parent:n});return i.status==="aborted"?$t:i.status==="dirty"?(r.dirty(),{status:"dirty",value:i.value}):this._def.out._parseSync({data:i.value,path:n.path,parent:n})}}static create(t,r){return new jb({in:t,out:r,typeName:Ut.ZodPipeline})}}class Ib extends nr{_parse(t){const r=this._def.innerType._parse(t),n=i=>(Th(i)&&(i.value=Object.freeze(i.value)),i);return gb(r)?r.then(i=>n(i)):n(r)}unwrap(){return this._def.innerType}}Ib.create=(e,t)=>new Ib({innerType:e,typeName:Ut.ZodReadonly,...er(t)});function Tz(e,t){const r=typeof e=="function"?e(t):typeof e=="string"?{message:e}:e;return typeof r=="string"?{message:r}:r}function jz(e,t={},r){return e?$0.create().superRefine((n,i)=>{var a,s;const o=e(n);if(o instanceof Promise)return o.then(c=>{var l,u;if(!c){const d=Tz(t,n),p=(u=(l=d.fatal)!==null&&l!==void 0?l:r)!==null&&u!==void 0?u:!0;i.addIssue({code:"custom",...d,fatal:p})}});if(!o){const c=Tz(t,n),l=(s=(a=c.fatal)!==null&&a!==void 0?a:r)!==null&&s!==void 0?s:!0;i.addIssue({code:"custom",...c,fatal:l})}}):$0.create()}const $me={object:xn.lazycreate};var Ut;(function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"})(Ut||(Ut={}));const Hme=(e,t={message:`Input not instance of ${e.name}`})=>jz(r=>r instanceof e,t),Iz=xo.create,Oz=qu.create,Wme=zx.create,Kme=Vu.create,Bz=vb.create,Gme=jh.create,Yme=Rx.create,Xme=wb.create,Jme=xb.create,Qme=$0.create,ege=Ih.create,tge=Tc.create,rge=Nx.create,nge=_o.create,ige=xn.create,age=xn.strictCreate,sge=_b.create,oge=Fx.create,lge=Sb.create,cge=gl.create,uge=kb.create,fge=Px.create,hge=Oh.create,dge=W0.create,pge=Eb.create,mge=Mb.create,gge=$u.create,bge=Ab.create,yge=K0.create,Rz=So.create,vge=ko.create,wge=Hu.create,xge=So.createWithPreprocess,_ge=jb.create;var K=Object.freeze({__proto__:null,defaultErrorMap:Z0,setErrorMap:xme,getErrorMap:jx,makeIssue:Ix,EMPTY_PATH:_me,addIssueToContext:lt,ParseStatus:Qi,INVALID:$t,DIRTY:Ox,OK:ea,isAborted:FS,isDirty:PS,isValid:Th,isAsync:gb,get util(){return Sr},get objectUtil(){return NS},ZodParsedType:ft,getParsedType:Cc,ZodType:nr,datetimeRegex:Az,ZodString:xo,ZodNumber:qu,ZodBigInt:Vu,ZodBoolean:vb,ZodDate:jh,ZodSymbol:Rx,ZodUndefined:wb,ZodNull:xb,ZodAny:$0,ZodUnknown:Ih,ZodNever:Tc,ZodVoid:Nx,ZodArray:_o,ZodObject:xn,ZodUnion:_b,ZodDiscriminatedUnion:Fx,ZodIntersection:Sb,ZodTuple:gl,ZodRecord:kb,ZodMap:Px,ZodSet:Oh,ZodFunction:W0,ZodLazy:Eb,ZodLiteral:Mb,ZodEnum:$u,ZodNativeEnum:Ab,ZodPromise:K0,ZodEffects:So,ZodTransformer:So,ZodOptional:ko,ZodNullable:Hu,ZodDefault:Cb,ZodCatch:Tb,ZodNaN:zx,BRAND:Zme,ZodBranded:DS,ZodPipeline:jb,ZodReadonly:Ib,custom:jz,Schema:nr,ZodSchema:nr,late:$me,get ZodFirstPartyTypeKind(){return Ut},coerce:{string:e=>xo.create({...e,coerce:!0}),number:e=>qu.create({...e,coerce:!0}),boolean:e=>vb.create({...e,coerce:!0}),bigint:e=>Vu.create({...e,coerce:!0}),date:e=>jh.create({...e,coerce:!0})},any:Qme,array:nge,bigint:Kme,boolean:Bz,date:Gme,discriminatedUnion:oge,effect:Rz,enum:gge,function:dge,instanceof:Hme,intersection:lge,lazy:pge,literal:mge,map:fge,nan:Wme,nativeEnum:bge,never:tge,null:Jme,nullable:wge,number:Oz,object:ige,oboolean:()=>Bz().optional(),onumber:()=>Oz().optional(),optional:vge,ostring:()=>
1987Iz().optional(),pipeline:_ge,preprocess:xge,promise:yge,record:uge,set:hge,strictObject:age,string:Iz,symbol:Yme,transformer:Rz,tuple:cge,undefined:Xme,union:sge,unknown:ege,void:rge,NEVER:$t,ZodIssueCode:We,quotelessJson:wme,ZodError:is});function Nz(e){return e.startsWith("0x")}function Ob(e){return Nz(e)?e.slice(2):e}function Lx(e){return/^(0x)?[0-9a-fA-F]*$/.test(e)}function fn(e){return je.from(Ob(e),"hex")}function Ur(e){return`0x${e.toString("hex")}`}const Sge=K.string().refine(Lx,"Not a valid hex string").transform(Ob),kge=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,US=K.string().refine(e=>e.length>1024||kge.test(e),"Not a valid base64 string").transform(e=>je.from(e,"base64"));class qS extends ko{constructor(){super(...arguments);te(this,"_isNullableOptional",!0)}_parse(r){const n=this._getType(r);return n===ft.undefined||n===ft.null?ea(void 0):this._def.innerType._parse(r)}static create(r){return new qS({innerType:r,typeName:Ut.ZodOptional})}}function ua(e){return qS.create(e)}function Ds(e,t){const r=(t?K.string().refine(t,"Not a valid instance"):K.string()).refine(Lx,"Not a valid hex string");return"fromString"in e?r.transform(e.fromString.bind(e)):r.transform(n=>je.from(Ob(n),"hex")).transform(e.fromBuffer.bind(e))}function Bb(e){return US.transform(e.fromBuffer.bind(e))}function Dx(e,t){return K.array(K.tuple([e,t])).transform(r=>new Map(r))}const w2=class w2{constructor(t,r=0){qt(this,fs);te(this,"buffer");te(this,"index");this.buffer=t,this.index=r}static asReader(t){if(t instanceof w2)return t;const r=je.isBuffer(t)?t:je.from(t.buffer,t.byteOffset,t.byteLength);return new w2(r)}isEmpty(){return this.index===this.buffer.length}readNumber(){return Vt(this,fs,Ho).call(this,4),this.index+=4,this.buffer.readUint32BE(this.index-4)}readNumbers(t){return Array.from({length:t},()=>this.readNumber())}readUInt256(){Vt(this,fs,Ho).call(this,32);let t=BigInt(0);for(let r=0;r<32;r++)t=t<<BigInt(8)|BigInt(this.buffer[this.index+r]);return this.index+=32,t}readUInt16(){return Vt(this,fs,Ho).call(this,2),this.index+=2,this.buffer.readUInt16BE(this.index-2)}readUInt8(){return Vt(this,fs,Ho).call(this,1),this.index+=1,this.buffer.readUInt8(this.index-1)}readBoolean(){return Vt(this,fs,Ho).call(this,1),this.index+=1,!!this.buffer.at(this.index-1)}readBytes(t){return Vt(this,fs,Ho).call(this,t),this.index+=t,je.from(this.buffer.subarray(this.index-t,this.index))}readToEnd(){const t=this.buffer.subarray(this.index);return this.index=this.buffer.length,t}readNumberVector(){return this.readVector({fromBuffer:t=>t.readNumber()})}readVector(t){const r=this.readNumber(),n=new Array(r);for(let i=0;i<r;i++)n[i]=t.fromBuffer(this);return n}readVectorUint8Prefix(t){const r=this.readUInt8(),n=new Array(r);for(let i=0;i<r;i++)n[i]=t.fromBuffer(this);return n}readArray(t,r){return Array.from({length:t},()=>r.fromBuffer(this))}readBufferArray(t=-1){const r=[],n=t>=0?this.index+t:this.buffer.length;for(Vt(this,fs,Ho).call(this,n-this.index);this.index<n;){const i=this.readBuffer();r.push(i)}if(this.index!==n)throw new Error(`Reader buffer was not fully consumed. Consumed up to ${this.index} bytes. End of data: ${n} bytes.`);return r}readObject(t){return t.fromBuffer(this)}peekBytes(t){return Vt(this,fs,Ho).call(this,t||0),this.buffer.subarray(this.index,t?this.index+t:void 0)}readString(){return this.readBuffer().toString()}readBuffer(){const t=this.readNumber();return Vt(this,fs,Ho).call(this,t),this.readBytes(t)}readUint8Array(){const t=this.readNumber();return Vt(this,fs,Ho).call(this,t),this.readBytes(t)}readMap(t){const r=this.readNumber(),n={};for(let i=0;i<r;i++){const a=this.readString(),s=this.readObject(t);n[a]=s}return n}getLength(){return this.buffer.length}remainingBytes(){return this.buffer.length-this.index}};fs=new WeakSet,Ho=function(t){if(this.index+t>this.buffer.length)throw new Error(`Attempted to read beyond buffer length. Start index: ${this.index}, Num bytes to read: ${t}, Buffer length: ${this.buffer.length}`)};let rt=w2;class Bh{static register(t,r){this.registry.set(t,r)}static getConstructor(t){return this.registry.get(t)}}te(Bh,"registry",new Map);var Ege={};const Mge=je.alloc(32),qc=class qc{constructor(t){te(this,"asBuffer");te(this,"asBigInt");if(je.isBuffer(t)){if(t.length>qc.SIZE_IN_BYTES)throw new Error(`Value length ${t.length} exceeds ${qc.SIZE_IN_BYTES}`);this.asBuffer=t.length===qc.SIZE_IN_BYTES?t:je.concat([je.alloc(qc.SIZE_IN_BYTES-t.length),t])}else if(typeof t=="bigint"||typeof t=="number"||typeof t=="boolean"){if(this.asBigInt=BigInt(t),this.asBigInt>=this.modulus())throw new Error(`Value 0x${this.asBigInt.toString(16)} is greater or equal to field modulus.`)}else if(t instanceof qc)this.asBuffer=t.asBuffer,this.asBigInt=t.asBigInt;else throw new Error(`Type '${typeof t}' with value '${t}' passed to BaseField ctor.`)}get value(){return this.toBigInt()}get size(){return qc.SIZE_IN_BYTES}toBuffer(){return this.asBuffer||(this.asBuffer=Ca(this.asBigInt,32)),je.from(this.asBuffer)}toString(){return`0x${this.toBuffer().toString("hex")}`}toBigInt(){if(this.asBigInt===void 0&&(this.asBigInt=co(this.asBuffer),this.asBigInt>=this.modulus()))throw new Error(`Value 0x${this.asBigInt.toString(16)} is greater or equal to field modulus.`);return this.asBigInt}toBool(){return!!this.toBigInt()}toNumber(){const t=this.toBigInt();if(t>Number.MAX_SAFE_INTEGER)throw new Error(`Value ${t.toString(16)} greater than than max safe integer`);return Number(t)}toNumberUnsafe(){const t=this.toBigInt();return Number(t)}toShortString(){const t=this.toString();return`${t.slice(0,10)}...${t.slice(-4)}`}equals(t){return this.toBuffer().equals(t.toBuffer())}lt(t){return this.toBigInt()<t.toBigInt()}cmp(t){const r=this.toBigInt(),n=t.toBigInt();return r===n?0:r<n?-1:1}isZero(){return this.toBuffer().equals(Mge)}isEmpty(){return this.isZero()}toFriendlyJSON(){return this.toString()}toField(){return this}};te(qc,"SIZE_IN_BYTES",32);let G0=qc;function VS(e,t){const r=rt.asReader(e);return new t(r.readBytes(G0.SIZE_IN_BYTES))}function ZS(e,t){return new t(co(e)%t.MODULUS)}function Fz(e){return ZS(wo(64),e)}function Ux(e,t){var i;const r=(i=e.replace(/^0x/i,"").match(/^[0-9A-F]+$/i))==null?void 0:i[0];if(r===void 0)throw new Error(`Invalid hex-encoded string: "${e}"`);const n=je.from(r.length%2===1?"0"+r:r,"hex");return new t(n)}const Mr=class Mr extends G0{constructor(t){super(t)}[ct.inspect.custom](){return`Fr<${this.toString()}>`}modulus(){return Mr.MODULUS}static random(){return Fz(Mr)}static zero(){return Mr.ZERO}static isZero(t){return t.isZero()}static fromBuffer(t){return VS(t,Mr)}static fromBufferReduce(t){return ZS(t,Mr)}static fromString(t){if(t.match(/^\d+$/)!==null)return new Mr(Ca(BigInt(t),32));if(t.match(/^0x/i)!==null)return Ux(t,Mr);
1987throw new Error(`Tried to create a Fr from an invalid string: ${t}`)}static fromHexString(t){return Ux(t,Mr)}add(t){return new Mr((this.toBigInt()+t.toBigInt())%Mr.MODULUS)}square(){return new Mr(this.toBigInt()*this.toBigInt()%Mr.MODULUS)}negate(){return new Mr(Mr.MODULUS-this.toBigInt())}sub(t){const r=this.toBigInt()-t.toBigInt();return new Mr(r<0?r+Mr.MODULUS:r)}mul(t){return new Mr(this.toBigInt()*t.toBigInt()%Mr.MODULUS)}div(t){if(t.isZero())throw new Error("Division by zero");const r=Age(t.toBigInt());return this.mul(r)}ediv(t){if(t.isZero())throw new Error("Division by zero");return new Mr(this.toBigInt()/t.toBigInt())}async sqrt(){const t=(await js.initSingleton(Ege.BB_WASM_PATH)).getWasm(),[r]=t.callWasmExport("bn254_fr_sqrt",[this.toBuffer()],[Mr.SIZE_IN_BYTES+1]);return r[0]===1?new Mr(je.from(r.slice(1))):null}toJSON(){return this.toString()}static get schema(){return Ds(Mr)}};te(Mr,"ZERO",new Mr(0n)),te(Mr,"ONE",new Mr(1n)),te(Mr,"MODULUS",0x30644e72e131a029b85045b68181585d2833e84879b9709143e1f593f0000001n),te(Mr,"MAX_FIELD_VALUE",new Mr(Mr.MODULUS-1n));let le=Mr;Bh.register("Fr",le);const _n=class _n extends G0{[ct.inspect.custom](){return`Fq<${this.toString()}>`}get lo(){return new le(this.toBigInt()&_n.LOW_MASK)}get hi(){return new le(this.toBigInt()>>_n.HIGH_SHIFT)}constructor(t){super(t)}modulus(){return _n.MODULUS}static random(){return Fz(_n)}static zero(){return _n.ZERO}static fromBuffer(t){return VS(t,_n)}static fromBufferReduce(t){return ZS(t,_n)}static fromString(t){if(t.match(/^\d+$/)!==null)return new _n(Ca(BigInt(t),32));if(t.match(/^0x/i)!==null)return Ux(t,_n);throw new Error(`Tried to create a Fq from an invalid string: ${t}`)}static fromHexString(t){return Ux(t,_n)}static fromHighLow(t,r){return new _n((t.toBigInt()<<_n.HIGH_SHIFT)+r.toBigInt())}add(t){return new _n((this.toBigInt()+t.toBigInt())%_n.MODULUS)}toJSON(){return this.toString()}toFields(){return[this.lo,this.hi]}static get schema(){return Ds(_n)}};te(_n,"ZERO",new _n(0n)),te(_n,"MODULUS",0x30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47n),te(_n,"HIGH_SHIFT",BigInt(G0.SIZE_IN_BYTES/2*8)),te(_n,"LOW_MASK",(1n<<_n.HIGH_SHIFT)-1n);let Rh=_n;Bh.register("Fq",Rh);function Age(e){const[t,r,n]=Pz(e,le.MODULUS);if(t!=1n)throw Error("Inverse does not exist");return new le(r>0?r:r+le.MODULUS)}function Pz(e,t){if(e==0n)return[t,0n,1n];{const[r,n,i]=Pz(t%e,e);return[r,i-t/e*n,n]}}const zz=Rh;function qx(e,t=4){const r=je.alloc(t);return r.writeUInt32BE(e,t-4),r}function Cge(e){if(e.length!==32)throw new Error("Buffer to truncate must be 32 bytes");return je.concat([je.alloc(1),e.subarray(0,31)])}function bl(e,t=4){const r=$S(e);let n;if(t===1)n=je.alloc(1),n.writeUInt8(r.length,0);else if(t===4)n=je.alloc(4),n.writeUInt32BE(r.length,0);else throw new Error(`Unsupported prefix length. Got ${t}, expected 1 or 4`);return je.concat([n,...r])}function Tge(e,t,r=0){let n=r;const i=t.readUInt32BE(n);n+=4;const a=new Array(i);for(let s=0;s<i;++s){const{elem:o,adv:c}=e(t,n);n+=c,a[s]=o}return{elem:a,adv:n-r}}function Lz(e,t=1){const r=je.alloc(t);return r.writeUInt8(e?1:0,t-1),r}function $S(...e){var r;const t=[];for(const n of e)if(Array.isArray(n))t.push(...$S(...n));else if(je.isBuffer(n))t.push(n);else if(typeof n=="boolean")t.push(Lz(n));else if(typeof n=="bigint"){if(n>BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"))throw new Error(`BigInt ${n} does not fit into 32 bytes`);t.push(Vx(n))}else if(typeof n=="number")t.push(qx(n));else if(typeof n=="string")t.push(qx(n.length)),t.push(je.from(n));else if("toBuffer"in n)t.push(n.toBuffer());else throw new Error(`Cannot serialize input to buffer: ${typeof n} ${(r=n.constructor)==null?void 0:r.name}`);return t}function Gr(...e){var r;const t=[];for(const n of e)if(Array.isArray(n))t.push(...Gr(...n));else if(n instanceof le)t.push(n);else if(typeof n=="boolean"||typeof n=="number"||typeof n=="bigint")t.push(new le(n));else if("toFields"in n)t.push(...n.toFields());else if("toFr"in n)t.push(n.toFr());else if("toField"in n)t.push(n.toField());else if(je.isBuffer(n))t.push(le.fromBuffer(n));else throw new Error(`Cannot serialize input to field: ${typeof n} ${(r=n.constructor)==null?void 0:r.name}`);return t}function ht(...e){return je.concat($S(...e))}function Vx(e,t=32){return Ca(e,t)}function jge(e,t=0,r=32){return{elem:co(e.subarray(t,t+r)),adv:r}}var HS={};async function WS(e){const t=Gr(e),r=(await js.initSingleton(HS.BB_WASM_PATH)).poseidon2Hash(t.map(n=>new h4(n.toBuffer())));return le.fromBuffer(je.from(r.toBuffer()))}async function yl(e,t){const r=Gr(e);r.unshift(new le(t));const n=(await js.initSingleton(HS.BB_WASM_PATH)).poseidon2Hash(r.map(i=>new h4(i.toBuffer())));return le.fromBuffer(je.from(n.toBuffer()))}async function Dz(e){const t=[];for(let n=0;n<e.length;n+=31){const i=je.alloc(32,0);e.slice(n,n+31).copy(i),i.reverse(),t.push(le.fromBuffer(i))}const r=(await js.initSingleton(HS.BB_WASM_PATH)).poseidon2Hash(t.map(n=>new h4(n.toBuffer())));return le.fromBuffer(je.from(r.toBuffer()))}class Pt{constructor(t,r=0){te(this,"fields");te(this,"index");te(this,"length");if(this.fields=t,this.index=r,this.length=t.length,r>=this.length)throw new Error("Offset out of bounds.")}static asReader(t){return t instanceof Pt?t:new Pt(t)}
1987get cursor(){return this.index}skip(t){if(this.index+t>this.length)throw new Error("Not enough fields to be consumed.");this.index+=t}readField(){if(this.index===this.length)throw new Error("Not enough fields to be consumed.");return this.fields[this.index++]}peekField(){if(this.index===this.length)throw new Error("Not enough fields to be consumed.");return this.fields[this.index]}readFq(){return Rh.fromHighLow(this.readField(),this.readField())}readBoolean(){const t=this.readField().toBigInt();if(t>1n)throw new Error("Field is not a boolean.");return t==1n}readU32(){const t=this.readField().toBigInt();if(t>=1n<<32n)throw new Error("Field is not a u32.");return Number(t)}readFieldArray(t){const r=[];for(let n=0;n<t;++n)r.push(this.readField());return r}readArray(t,r){return Array.from({length:t},()=>r.fromFields(this))}readObject(t){return t.fromFields(this)}isFinished(){return this.index>=this.length}}function Ige(e,t){if(e.length!==t)throw new Error(`Wrong 'fixed array' size. Expected ${t}, got ${e.length}.`);return e}function Oge(e,t){return e.map(t)}const Hs=class Hs{constructor(t,r,n){te(this,"x");te(this,"y");te(this,"isInfinite");te(this,"kind");this.x=t,this.y=r,this.isInfinite=n,this.kind="point"}toJSON(){return this.toString()}static get schema(){return Ds(Hs)}static async random(){for(;;)try{return await Hs.fromXAndSign(le.random(),vme())}catch(t){if(!(t instanceof Uz))throw t;continue}}static fromBuffer(t){const r=rt.asReader(t);return new this(le.fromBuffer(r),le.fromBuffer(r),!1)}static fromCompressedBuffer(t){const r=rt.asReader(t),n=co(r.readBytes(Hs.COMPRESSED_SIZE_IN_BYTES)),i=new le(n&(1n<<255n)-1n),a=(n&1n<<255n)!==0n;return this.fromXAndSign(i,a)}static fromString(t){return this.fromBuffer(fn(t))}toFields(){return[this.x,this.y,new le(this.isInfinite)]}static fromFields(t){const r=Pt.asReader(t);return new this(r.readField(),r.readField(),r.readBoolean())}static async fromXAndSign(t,r){const n=await Hs.YFromX(t);if(n==null)throw new Uz(t);const i=n.toBigInt()<=(le.MODULUS-1n)/2n?n.toBigInt():le.MODULUS-n.toBigInt(),a=le.MODULUS-i,s=r?new le(i):new le(a);return new this(t,s,!1)}static YFromX(t){return t.square().mul(t).sub(new le(17)).sqrt()}toXAndSign(){return[this.x,this.y.toBigInt()<=(le.MODULUS-1n)/2n]}toBigInts(){return{x:this.x.toBigInt(),y:this.y.toBigInt(),isInfinite:this.isInfinite?1n:0n}}toBuffer(){if(this.isInfinite)throw new Error("Cannot serialize infinite point without isInfinite flag");const t=ht([this.x,this.y]);if(t.length!==Hs.SIZE_IN_BYTES)throw new Error(`Invalid buffer length for Point: ${t.length}`);return t}toCompressedBuffer(){const[t,r]=this.toXAndSign(),n=t.toBigInt()+(r?2n**255n:0n),i=ht(n);if(i.length!==Hs.COMPRESSED_SIZE_IN_BYTES)throw new Error(`Invalid buffer length for compressed Point: ${i.length}`);return i}toString(){return Ur(this.toBuffer())}toShortString(){const t=this.toString();return`${t.slice(0,10)}...${t.slice(-4)}`}toNoirStruct(){return{x:this.x,y:this.y,is_infinite:this.isInfinite}}toWrappedNoirStruct(){return{inner:this.toNoirStruct()}}equals(t){return this.x.equals(t.x)&&this.y.equals(t.y)}isZero(){return this.x.isZero()&&this.y.isZero()}hash(){return WS(this.toFields())}get inf(){return this.isInfinite}isOnGrumpkin(){if(this.inf)return!0;const t=this.y.square(),r=this.x.mul(this.x).mul(this.x).sub(new le(17));return t.equals(r)}};te(Hs,"ZERO",new Hs(le.ZERO,le.ZERO,!1)),te(Hs,"SIZE_IN_BYTES",le.SIZE_IN_BYTES*2),te(Hs,"COMPRESSED_SIZE_IN_BYTES",le.SIZE_IN_BYTES);let Ir=Hs;class Uz extends Error{constructor(t){super("The given x-coordinate is not on the Grumpkin curve: "+t.toString()),this.name="NotOnCurveError"}}const jp=class jp{constructor(t){te(this,"fields");this.fields=t}toFields(){return this.fields}static random(){return this.fromField(le.random())}toFieldsBuffer(){return je.concat([this.fields[0].toBuffer(),this.fields[1].toBuffer()])}toBuffer(){const t=this.fields[0].toBuffer(),r=this.fields[1].toBuffer();return t[0]=r[31],t}equals(t){return this.toBigInt()===t.toBigInt()}toBigInt(){return co(this.toBuffer())}static fromBuffer(t){if(t.length!=32)throw new Error("Invalid size of coordinate buffer");const r=je.alloc(32);t.copy(r,0,0,32);const n=je.alloc(32);return n[31]=r[0],r[0]=0,new jp([le.fromBuffer(r),le.fromBuffer(n)])}static fromField(t){const r=t.toBuffer(),n=je.alloc(32);return n[31]=r[0],r[0]=0,new jp([le.fromBuffer(r),le.fromBuffer(n)])}};
1987te(jp,"ZERO",new jp([le.ZERO,le.ZERO]));let qz=jp;function KS(e){return je.from(PF.sha256().update(e).digest())}function Vz(e){return Cge(KS(e))}function Bge(e){const t=ht(e);return le.fromBuffer(Vz(t))}var Zz={},$z={},Hz={},Wz={},Rge=function(e,t){return function(r,n){var i=n*2,a=t*2;r[i]=e[a],r[i+1]=e[a+1]}},GS=Rge;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=r(GS);function r(a){return a&&a.__esModule?a:{default:a}}var n=function(a){for(var s=a.A,o=a.C,c=0;c<25;c+=5){for(var l=0;l<5;l++)(0,t.default)(s,c+l)(o,l);for(var u=0;u<5;u++){var d=(c+u)*2,p=(u+1)%5*2,w=(u+2)%5*2;s[d]^=~o[p]&o[w],s[d+1]^=~o[p+1]&o[w+1]}}},i=n;e.default=i})(Wz);var Kz={},Gz={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=new Uint32Array([0,1,0,32898,2147483648,32906,2147483648,2147516416,0,32907,0,2147483649,2147483648,2147516545,2147483648,32777,0,138,0,136,0,2147516425,0,2147483658,0,2147516555,2147483648,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,0,32778,2147483648,2147483658,2147483648,2147516545,2147483648,32896,0,2147483649,2147483648,2147516424]),r=t;e.default=r})(Gz),function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=r(Gz);function r(a){return a&&a.__esModule?a:{default:a}}var n=function(a){var s=a.A,o=a.roundIndex,c=o*2;s[0]^=t.default[c],s[1]^=t.default[c+1]},i=n;e.default=i}(Kz);var Yz={},Xz={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=[10,7,11,17,18,3,5,16,8,21,24,4,15,23,19,13,12,2,20,14,22,9,6,1],r=t;e.default=r})(Xz);var Jz={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=[1,3,6,10,15,21,28,36,45,55,2,14,27,41,56,8,25,43,62,18,39,61,20,44],r=t;e.default=r})(Jz),function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=i(Xz),r=i(Jz),n=i(GS);function i(o){return o&&o.__esModule?o:{default:o}}var a=function(o){var c=o.A,l=o.C,u=o.W;(0,n.default)(c,1)(u,0);for(var d=0,p=0,w=0,O=32,I=0;I<24;I++){var R=t.default[I],C=r.default[I];(0,n.default)(c,R)(l,0),d=u[0],p=u[1],O=32-C,w=C<32?0:1,u[w]=d<<C|p>>>O,u[(w+1)%2]=p<<C|d>>>O,(0,n.default)(u,0)(c,R),(0,n.default)(l,0)(u,0)}},s=a;e.default=s}(Yz);var Qz={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=r(GS);function r(a){return a&&a.__esModule?a:{default:a}}var n=function(a){for(var s=a.A,o=a.C,c=a.D,l=a.W,u=0,d=0,p=0;p<5;p++){var w=p*2,O=(p+5)*2,I=(p+10)*2,R=(p+15)*2,C=(p+20)*2;o[w]=s[w]^s[O]^s[I]^s[R]^s[C],o[w+1]=s[w+1]^s[O+1]^s[I+1]^s[R+1]^s[C+1]}for(var j=0;j<5;j++){(0,t.default)(o,(j+1)%5)(l,0),u=l[0],d=l[1],l[0]=u<<1|d>>>31,l[1]=d<<1|u>>>31,c[j*2]=o[(j+4)%5*2]^l[0],c[j*2+1]=o[(j+4)%5*2+1]^l[1];for(var N=0;N<25;N+=5)s[(N+j)*2]^=c[j*2],s[(N+j)*2+1]^=c[j*2+1]}},i=n;e.default=i})(Qz),function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=a(Wz),r=a(Kz),n=a(Yz),i=a(Qz);function a(c){return c&&c.__esModule?c:{default:c}}var s=function(){var c=new Uint32Array(10),l=new Uint32Array(10),u=new Uint32Array(2);return function(d){for(var p=0;p<24;p++)(0,i.default)({A:d,C:c,D:l,W:u}),(0,n.default)({A:d,C:c,W:u}),(0,t.default)({A:d,C:c}),(0,r.default)({A:d,roundIndex:p});c.fill(0),l.fill(0),u.fill(0)}},o=s;e.default=o}(Hz),function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=ji,r=n(Hz);function n(c){return c&&c.__esModule?c:{default:c}}var i=function(c,l){for(var u=0;u<c.length;u+=8){var d=u/4;l[d]^=c[u+7]<<24|c[u+6]<<16|c[u+5]<<8|c[u+4],l[d+1]^=c[u+3]<<24|c[u+2]<<16|c[u+1]<<8|c[u]}return l},a=function(c,l){for(var u=0;u<l.length;u+=8){var d=u/4;l[u]=c[d+1],l[u+1]=c[d+1]>>>8,l[u+2]=c[d+1]>>>16,l[u+3]=c[d+1]>>>24,l[u+4]=c[d],l[u+5]=c[d]>>>8,l[u+6]=c[d]>>>16,l[u+7]=c[d]>>>24}return l},s=function(c){var l=this,u=c.capacity,d=c.padding,p=(0,r.default)(),w=200,O=u/8,I=w-u/4,R=0,C=new Uint32Array(w/4),j=t.Buffer.allocUnsafe(I);return this.absorb=function(N){for(var P=0;P<N.length;P++)j[R]=N[P],R+=1,R>=I&&(i(j,C),p(C),R=0);return l},this.squeeze=function(){var N=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},P={buffer:N.buffer||t.Buffer.allocUnsafe(O),padding:N.padding||d,queue:t.Buffer.allocUnsafe(j.length),state:new Uint32Array(C.length)};j.copy(P.queue);for(var Z=0;Z<C.length;Z++)P.state[Z]=C[Z];P.queue.fill(0,R),P.queue[R]|=P.padding,P.queue[I-1]|=128,i(P.queue,P.state);for(var X=0;X<P.buffer.length;X+=I)p(P.state),a(P.state,P.buffer.slice(X,X+I));return P.buffer},this.reset=function(){return j.fill(0),C.fill(0),R=0,l},this},o=s;e.default=o}
1987($z),function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.SHAKE=e.SHA3Hash=e.SHA3=e.Keccak=void 0;var t=ji,r=n($z);function n(u){return u&&u.__esModule?u:{default:u}}var i=function(u){var d=u.allowedSizes,p=u.defaultSize,w=u.padding;return function O(){var I=this,R=arguments.length>0&&arguments[0]!==void 0?arguments[0]:p;if(!this||this.constructor!==O)return new O(R);if(d&&!d.includes(R))throw new Error("Unsupported hash length");var C=new r.default({capacity:R});return this.update=function(j){var N=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"utf8";if(t.Buffer.isBuffer(j))return C.absorb(j),I;if(typeof j=="string")return I.update(t.Buffer.from(j,N));throw new TypeError("Not a string or buffer")},this.digest=function(){var j=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"binary",N=typeof j=="string"?{format:j}:j,P=C.squeeze({buffer:N.buffer,padding:N.padding||w});return N.format&&N.format!=="binary"?P.toString(N.format):P},this.reset=function(){return C.reset(),I},this}},a=i({allowedSizes:[224,256,384,512],defaultSize:512,padding:1});e.Keccak=a;var s=i({allowedSizes:[224,256,384,512],defaultSize:512,padding:6});e.SHA3=s;var o=i({allowedSizes:[128,256],defaultSize:256,padding:31});e.SHAKE=o;var c=a;e.SHA3Hash=c,s.SHA3Hash=c;var l=s;e.default=l}(Zz);const Wn=class Wn{constructor(t){te(this,"buffer");if(this.buffer=t,t.length!==Wn.SIZE)throw new Error(`Expected buffer to have length ${Wn.SIZE} but was ${t.length}`)}toBuffer(){return this.buffer}static fromBuffer(t){const r=rt.asReader(t);return new Wn(r.readBytes(Wn.SIZE))}equals(t){return this.buffer.equals(t.buffer)}isZero(){return this.buffer.equals(je.alloc(32,0))}toString(){return Ur(this.buffer)}toJSON(){return this.toString()}toBigInt(){return jge(this.buffer,0,Wn.SIZE).elem}static fromBigInt(t){return new Wn(Vx(t,Wn.SIZE))}static fromField(t){return new Wn(Vx(t.toBigInt()))}static fromBuffer28(t){if(t.length!=28)throw new Error("Expected Buffer32 input buffer to be 28 bytes");const r=je.concat([je.alloc(this.SIZE-28),t]);return new Wn(r)}static fromString(t){if(t.startsWith("0x")&&(t=t.slice(2)),t.length!==64)throw new Error(`Expected string to be 64 characters long, but was ${t.length}`);return new Wn(je.from(t,"hex"))}static fromNumber(t){return new Wn(Vx(BigInt(t),Wn.SIZE))}static random(){return new Wn(je.from(wo(Wn.SIZE)))}};te(Wn,"SIZE",32),te(Wn,"ZERO",new Wn(je.alloc(Wn.SIZE)));let ta=Wn;function eL(e){const t=new Zz.Keccak(256);return t.reset(),t.update(e),t.digest("hex")}const Nge=e=>je.from(PF.sha512().update(e).digest()),Zx=e=>{const t=ht(e);return zz.fromBufferReduce(Nge(t))},dn=class dn{constructor(t){te(this,"buffer");if(this.buffer=t,t.length!==dn.SIZE_IN_BYTES)throw new Error(`Expect buffer size to be ${dn.SIZE_IN_BYTES}. Got ${t.length}.`)}static fromString(t){if(!dn.isAddress(t))throw new Error(`Invalid address string: ${t}`);return new dn(je.from(t.replace(/^0x/i,""),"hex"))}static random(){return new dn(wo(20))}static isAddress(t){return/^(0x)?[0-9a-f]{40}$/i.test(t)?/^(0x|0X)?[0-9a-f]{40}$/.test(t)||/^(0x|0X)?[0-9A-F]{40}$/.test(t)?!0:dn.checkAddressChecksum(t):!1}isZero(){return this.equals(dn.ZERO)}static checkAddressChecksum(t){t=t.replace(/^0x/i,"");const r=eL(t.toLowerCase());for(let n=0;n<40;n++)if(parseInt(r[n],16)>7&&t[n].toUpperCase()!==t[n]||parseInt(r[n],16)<=7&&t[n].toLowerCase()!==t[n])return!1;return!0}static toChecksumAddress(t){if(!dn.isAddress(t))throw new Error("Invalid address string.");t=t.toLowerCase().replace(/^0x/i,"");const r=eL(t);let n="0x";for(let i=0;i<t.length;i++)parseInt(r[i],16)>7?n+=t[i].toUpperCase():n+=t[i];return n}equals(t){return this.buffer.equals(t.buffer)}toString(){return Ur(this.buffer)}[ct.inspect.custom](){return`EthAddress<${this.toString()}>`}toChecksumString(){return dn.toChecksumAddress(this.buffer.toString("hex"))}toBuffer(){return this.buffer}toBuffer32(){const t=je.alloc(32);return this.buffer.copy(t,12),t}toField(){return le.fromBuffer(this.toBuffer32())}static fromField(t){return new dn(t.toBuffer().slice(-dn.SIZE_IN_BYTES))}static fromFields(t){const r=Pt.asReader(t);return dn.fromField(r.readField())}static fromBuffer(t){const r=rt.asReader(t);
1987return new dn(r.readBytes(dn.SIZE_IN_BYTES))}static fromNumber(t){const r=je.alloc(dn.SIZE_IN_BYTES);return r.writeBigUInt64BE(BigInt(t),0),new dn(r)}toJSON(){return this.toString()}static get schema(){return Ds(dn,dn.isAddress)}};te(dn,"SIZE_IN_BYTES",20),te(dn,"ZERO",new dn(je.alloc(dn.SIZE_IN_BYTES)));let Eo=dn;Bh.register("EthAddress",Eo);class jc{constructor(t,r,n,i=!1){te(this,"r");te(this,"s");te(this,"v");te(this,"isEmpty");te(this,"size");this.r=t,this.s=r,this.v=n,this.isEmpty=i}static fromBuffer(t){const r=rt.asReader(t),n=r.readObject(ta),i=r.readObject(ta),a=r.readNumber(),s=n.isZero()&&i.isZero();return new jc(n,i,a,s)}static isValidString(t){return/^0x[0-9a-f]{129,}$/i.test(t)}static fromString(t){const r=fn(t),n=rt.asReader(r),i=n.readObject(ta),a=n.readObject(ta),s=parseInt(t.slice(2+64*2),16),o=i.isZero()&&a.isZero();return new jc(i,a,s,o)}static fromViemSignature(t){return new jc(ta.fromBuffer(fn(t.r)),ta.fromBuffer(fn(t.s)),t.v,t.isEmpty)}static random(){return new jc(ta.random(),ta.random(),Math.floor(Math.random()*2),!1)}static empty(){return new jc(ta.ZERO,ta.ZERO,0,!0)}equals(t){return this.r.equals(t.r)&&this.s.equals(t.s)&&this.v===t.v&&this.isEmpty===t.isEmpty}toBuffer(){const t=ht([this.r,this.s,this.v]);return this.size=t.length,t}getSize(){return this.size?this.size:(this.size=this.toBuffer().length,this.size)}toString(){return`0x${this.r.buffer.toString("hex")}${this.s.buffer.toString("hex")}${this.v.toString(16)}`}toViemSignature(){return{r:this.r.toString(),s:this.s.toString(),v:this.v,isEmpty:this.isEmpty}}toJSON(){return this.toString()}static get schema(){return K.string().refine(Nz,"No hex prefix").refine(jc.isValidString,"Not a valid Ethereum signature").transform(jc.fromString)}}var Rb={};const x2=class x2{generator(){return x2.generator}async mul(t,r){const n=await js.initSingleton(Rb.BB_WASM_PATH),[i]=n.getWasm().callWasmExport("ecc_grumpkin__mul",[t.toBuffer(),r.toBuffer()],[64]);return Ir.fromBuffer(je.from(i))}async add(t,r){const n=await js.initSingleton(Rb.BB_WASM_PATH),[i]=n.getWasm().callWasmExport("ecc_grumpkin__add",[t.toBuffer(),r.toBuffer()],[64]);return Ir.fromBuffer(je.from(i))}async batchMul(t,r){const n=je.concat(t.map(c=>c.toBuffer())),i=t.length*Ir.SIZE_IN_BYTES,a=await js.initSingleton(Rb.BB_WASM_PATH),[s]=a.getWasm().callWasmExport("ecc_grumpkin__batch_mul",[n,r.toBuffer(),t.length],[i]),o=[];for(let c=0;c<i;c+=64)o.push(Ir.fromBuffer(je.from(s.subarray(c,c+64))));return o}async getRandomFr(){const t=await js.initSingleton(Rb.BB_WASM_PATH),[r]=t.getWasm().callWasmExport("ecc_grumpkin__get_random_scalar_mod_circuit_modulus",[],[32]);return le.fromBuffer(je.from(r))}async reduce512BufferToFr(t){const r=await js.initSingleton(Rb.BB_WASM_PATH),[n]=r.getWasm().callWasmExport("ecc_grumpkin__reduce512_buffer_mod_circuit_modulus",[t],[32]);return le.fromBuffer(je.from(n))}};te(x2,"generator",Ir.fromBuffer(je.from([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,2,207,19,94,117,6,164,93,99,45,39,13,69,241,24,18,148,131,63,196,141,130,63,39,44])));let $x=x2;var YS={};const _2=class _2{generator(){return _2.generator}async mul(t,r){const n=await js.initSingleton(YS.BB_WASM_PATH),[i]=n.getWasm().callWasmExport("ecc_secp256k1__mul",[t,r],[64]);return je.from(i)}async getRandomFr(){const t=await js.initSingleton(YS.BB_WASM_PATH),[r]=t.getWasm().callWasmExport("ecc_secp256k1__get_random_scalar_mod_circuit_modulus",[],[32]);return je.from(r)}async reduce512BufferToFr(t){const r=await js.initSingleton(YS.BB_WASM_PATH),[n]=r.getWasm().callWasmExport("ecc_secp256k1__reduce512_buffer_mod_circuit_modulus",[t],[32]);return je.from(n)}};te(_2,"generator",je.from([121,190,102,126,249,220,187,172,85,160,98,149,206,135,11,7,2,155,252,219,45,206,40,217,89,242,129,91,22,248,23,152,72,58,218,119,38,163,196,101,93,164,251,252,14,17,8,168,253,23,180,72,166,133,84,25,156,71,208,143,251,16,212,184]));let tL=_2;const Lo=class Lo{constructor(t){te(this,"buffer");if(this.buffer=t,t.length!==Lo.SIZE)throw new Error(`Invalid signature buffer of length ${t.length}.`)}static isSignature(t){return/^(0x)?[0-9a-f]{128}$/i.test(t)}static fromString(t){if(!Lo.isSignature(t))throw new Error(`Invalid signature string: ${t}`);return new Lo(je.from(t.replace(/^0x/i,""),"hex"))}static random(){return new Lo(wo(64))}get s(){return this.buffer.subarray(0,32)}get e(){return this.buffer.subarray(32)}toBuffer(){return this.buffer}static fromBuffer(t){const r=rt.asReader(t);return new Lo(r.readBytes(Lo.SIZE))}toString(){return`0x${this.buffer.toString("hex")}`}toFields(){const t=this.toBuffer(),r=je.alloc(32),n=je.alloc(32),i=je.alloc(32);return t.copy(r,1,0,31),t.copy(n,1,31,62),t.copy(i,1,62,64),Oge([r,n,i],le.fromBuffer)}};te(Lo,"SIZE",64),te(Lo,"EMPTY",new Lo(je.alloc(64)));let rL=Lo;function Ar(e,t,r=0){return Array.from({length:e},(n,i)=>t(i+r))}async function nL(e,t,r=0){return await Promise.all(Array(e).fill(0).map(async(n,i)=>await t(i+r)))}function Fge(e,t){return typeof t=="string"&&Object.hasOwn(e,t)&&typeof e[t].parameters=="function"&&typeof e[t].returnType=="function"}const He={EthAddress:Eo.schema,Fr:le.schema,Fq:Rh.schema,Point:Ir.schema,BigInt:K.union([K.bigint(),K.number(),K.string()]).pipe(K.coerce.bigint()),Integer:K.union([K.bigint(),K.number(),K.string()]).pipe(K.coerce.number().int()),UInt32:K.union([K.bigint(),K.number(),K.string()]).pipe(K.coerce.number().int().min(0).max(2**32-1)),Buffer32:K.string().refine(Lx,"Not a valid hex string").transform(ta.fromString),Buffer:K.union([US,K.object({type:K.literal("Buffer"),data:K.array(K.number().int().min(0).max(255))}).transform(({data:e})=>je.from(e))]),BufferHex:K.string().refine(Lx,"Not a valid hex string").transform(Ob).transform(e=>je.from(e,"hex")),HexString:Sge};
1987class An{constructor(t,r){te(this,"pathSize");te(this,"data");this.pathSize=t,this.data=Ige(r,t)}static get schema(){return He.Buffer.transform(t=>An.fromBuffer(t))}static schemaFor(t){return He.Buffer.transform(r=>An.fromBuffer(r)).refine(r=>r.pathSize===t,r=>({message:`Expected sibling path size ${t} but got ${r.pathSize}`}))}toJSON(){return this.toBuffer()}static ZERO(t,r,n){const i=[];let a=r;for(let s=0;s<t;++s)i.push(a),a=n.hash(a,a);return new An(t,i)}static random(t){const r=Array.from({length:t},()=>le.random().toBuffer());return new An(t,r)}toBuffer(){return bl(this.data)}toBufferArray(){return this.data}toFields(){return this.data.map(t=>le.fromBuffer(t))}toTuple(){const t=this.toFields();return Ar(t.length,r=>t[r],0)}static fromBuffer(t,r=0){const{elem:n}=An.deserialize(t,r);return n}static deserialize(t,r=0){const n=(o,c)=>({elem:o.slice(c,c+32),adv:32}),{elem:i,adv:a}=Tge(n,t,r),s=i.length;return{elem:new An(s,i),adv:a}}toString(){return Ur(this.toBuffer())}static fromString(t){return An.fromBuffer(fn(t))}getSubtreeSiblingPath(t){const r=this.data.slice(t),n=this.pathSize-t;return new An(n,r)}}const XS=16,JS=16,QS=5,ek=16,tk=2,rk=16,nk=16,ik=16,ak=16,sk=1,Pge=29,zge=40,Hx=40,ok=40,iL=39,Lge=0,Dge=1,Uge=2,qge=3,Vge=4,Wu=64,Ku=64,lk=32,ck=64,Gu=8,Yu=32,Y0=1,Zge=1,aL=4096,sL=3,Wx=13,oL=14,Nh=18,$ge=0x1498945581e0eb9f8427ad6021184c700ef091d570892c437d12c7d90364bbdn,Hge=0x170ae506787c5c43d6ca9255d571c10fa9ffa9d141666e290c347c5c9ab7e344n,Wge=0xc044b05b6ca83b9c2dbae79cc1135155956a64e136819136e9947fe5e5866cn,Kge=0x1c1f0ca244c7cd46b682552bff8ae77dea40b966a71de076ec3b7678f2bdb151n,Gge=0x1b00316144359e9a3ec8e49c1cdb7eeb0cedd190dfd9dc90eea5115aa779e287n,Yge=0x80ffc74d7a8b0bccb88ac11f45874172f3847eb8b92654aaa58a3d2b8dc7833n,Xge=0x19c111f36ad3fc1d9b7a7a14344314d2864b94f030594cd67f753ef774a1efbn,Jge=0x2039907fe37f08d10739255141bb066c506a12f7d1e8dfec21abc58494705b6fn,lL=8,cL=4,uL=4,fL=2,hL=9,dL=3,pL=4,mL=2,gL=4,bL=5,yL=6,vL=20,Fh=3019,wL=3020,xL=4,_L=5,SL=2,kL=8,EL=8,ML=10,AL=14,CL=25,TL=724,jL=740,IL=37,OL=868,BL=1782,RL=782,NL=1e9,FL=6e6,uk=1,Qge=2,PL=3,zL=4,LL=5,DL=6,UL=7,qL=8,VL=9;var Ba=function(e){return e[e.NOTE_HASH=1]="NOTE_HASH",e[e.NOTE_HASH_NONCE=2]="NOTE_HASH_NONCE",e[e.UNIQUE_NOTE_HASH=3]="UNIQUE_NOTE_HASH",e[e.SILOED_NOTE_HASH=4]="SILOED_NOTE_HASH",e[e.MESSAGE_NULLIFIER=5]="MESSAGE_NULLIFIER",e[e.INITIALIZATION_NULLIFIER=6]="INITIALIZATION_NULLIFIER",e[e.OUTER_NULLIFIER=7]="OUTER_NULLIFIER",e[e.PUBLIC_DATA_READ=8]="PUBLIC_DATA_READ",e[e.PUBLIC_DATA_UPDATE_REQUEST=9]="PUBLIC_DATA_UPDATE_REQUEST",e[e.FUNCTION_DATA=10]="FUNCTION_DATA",e[e.FUNCTION_LEAF=11]="FUNCTION_LEAF",e[e.CONTRACT_DEPLOYMENT_DATA=12]="CONTRACT_DEPLOYMENT_DATA",e[e.CONSTRUCTOR=13]="CONSTRUCTOR",e[e.CONSTRUCTOR_ARGS=14]="CONSTRUCTOR_ARGS",e[e.CONTRACT_ADDRESS_V1=15]="CONTRACT_ADDRESS_V1",e[e.CONTRACT_LEAF=16]="CONTRACT_LEAF",e[e.CALL_CONTEXT=17]="CALL_CONTEXT",e[e.CALL_STACK_ITEM=18]="CALL_STACK_ITEM",e[e.CALL_STACK_ITEM_2=19]="CALL_STACK_ITEM_2",e[e.SECRET_HASH=20]="SECRET_HASH",e[e.L2_TO_L1_MSG=21]="L2_TO_L1_MSG",e[e.TX_CONTEXT=22]="TX_CONTEXT",e[e.PUBLIC_LEAF_INDEX=23]="PUBLIC_LEAF_INDEX",e[e.PUBLIC_DATA_LEAF=24]="PUBLIC_DATA_LEAF",e[e.SIGNED_TX_REQUEST=25]="SIGNED_TX_REQUEST",e[e.GLOBAL_VARIABLES=26]="GLOBAL_VARIABLES",e[e.PARTIAL_ADDRESS=27]="PARTIAL_ADDRESS",e[e.BLOCK_HASH=28]="BLOCK_HASH",e[e.SIDE_EFFECT=29]="SIDE_EFFECT",e[e.FEE_PAYLOAD=30]="FEE_PAYLOAD",e[e.COMBINED_PAYLOAD=31]="COMBINED_PAYLOAD",e[e.TX_NULLIFIER=32]="TX_NULLIFIER",e[e.TX_REQUEST=33]="TX_REQUEST",e[e.SIGNATURE_PAYLOAD=34]="SIGNATURE_PAYLOAD",e[e.VK=41]="VK",e[e.PUBLIC_CALLDATA=43]="PUBLIC_CALLDATA",e[e.FUNCTION_ARGS=44]="FUNCTION_ARGS",e[e.AUTHWIT_INNER=45]="AUTHWIT_INNER",e[e.AUTHWIT_OUTER=46]="AUTHWIT_OUTER",e[e.AUTHWIT_NULLIFIER=47]="AUTHWIT_NULLIFIER",e[e.NSK_M=48]="NSK_M",e[e.IVSK_M=49]="IVSK_M",e[e.OVSK_M=50]="OVSK_M",e[e.TSK_M=51]="TSK_M",e[e.PUBLIC_KEYS_HASH=52]="PUBLIC_KEYS_HASH",e[e.NOTE_NULLIFIER=53]="NOTE_NULLIFIER",e[e.SYMMETRIC_KEY=54]="SYMMETRIC_KEY",e[e.SYMMETRIC_KEY_2=55]="SYMMETRIC_KEY_2",e[e.PUBLIC_TX_HASH=56]="PUBLIC_TX_HASH",e[e.PRIVATE_TX_HASH=57]="PRIVATE_TX_HASH",e}({});BigInt(1e21),BigInt(0);class vl{constructor(t,r,n){te(this,"nullifier");te(this,"nextNullifier");te(this,"nextIndex");this.nullifier=t,this.nextNullifier=r,this.nextIndex=n}static get schema(){return K.object({nullifier:He.Fr,nextNullifier:He.Fr,nextIndex:He.BigInt}).transform(({nullifier:t,nextNullifier:r,nextIndex:n})=>new vl(t,r,n))}
1987getKey(){return this.nullifier.toBigInt()}getNextKey(){return this.nextNullifier.toBigInt()}getNextIndex(){return this.nextIndex}asLeaf(){return new Nb(this.nullifier)}toBuffer(){return je.concat(this.toHashInputs())}toHashInputs(){return[je.from(this.nullifier.toBuffer()),je.from(this.nextNullifier.toBuffer()),je.from(Ca(this.nextIndex,32))]}toFields(){return this.toHashInputs().map(t=>le.fromBuffer(t))}clone(){return new vl(this.nullifier,this.nextNullifier,this.nextIndex)}static random(){return new vl(le.random(),le.random(),BigInt(Math.floor(Math.random()*1e3)))}static empty(){return new vl(le.ZERO,le.ZERO,0n)}static fromBuffer(t){const r=rt.asReader(t);return new vl(r.readObject(le),r.readObject(le),co(r.readBytes(32)))}static fromLeaf(t,r,n){return new vl(t.value,new le(r),n)}static clone(t){return new vl(t.nullifier,t.nextNullifier,t.nextIndex)}}class Nb{constructor(t){te(this,"value");this.value=t}getKey(){return this.value.toBigInt()}toBuffer(){return this.value.toBuffer()}isEmpty(){return this.value.isZero()}updateTo(t){throw new Error("Nullifiers are create only")}static buildDummy(t){return new Nb(new le(t))}static fromBuffer(t){return new Nb(le.fromBuffer(t))}static get schema(){return K.object({value:He.Fr}).transform(({value:t})=>new Nb(t))}}class Mo{constructor(t,r,n,i){te(this,"slot");te(this,"value");te(this,"nextSlot");te(this,"nextIndex");this.slot=t,this.value=r,this.nextSlot=n,this.nextIndex=i}static get schema(){return K.object({slot:He.Fr,value:He.Fr,nextSlot:He.Fr,nextIndex:He.BigInt}).transform(({slot:t,value:r,nextSlot:n,nextIndex:i})=>new Mo(t,r,n,i))}getKey(){return this.slot.toBigInt()}getNextKey(){return this.nextSlot.toBigInt()}getNextIndex(){return this.nextIndex}asLeaf(){return new Ph(this.slot,this.value)}toBuffer(){return je.concat(this.toHashInputs())}toHashInputs(){return[je.from(this.slot.toBuffer()),je.from(this.value.toBuffer()),je.from(Ca(this.nextIndex,32)),je.from(this.nextSlot.toBuffer())]}clone(){return new Mo(this.slot,this.value,this.nextSlot,this.nextIndex)}static random(){return new Mo(le.random(),le.random(),le.random(),BigInt(Math.floor(Math.random()*1e3)))}static empty(){return new Mo(le.ZERO,le.ZERO,le.ZERO,0n)}static fromBuffer(t){const r=rt.asReader(t),n=le.fromBuffer(r),i=le.fromBuffer(r),a=co(r.readBytes(32)),s=le.fromBuffer(r);return new Mo(n,i,s,a)}static fromLeaf(t,r,n){return new Mo(t.slot,t.value,new le(r),n)}static clone(t){return new Mo(t.slot,t.value,t.nextSlot,t.nextIndex)}}class Ph{constructor(t,r){te(this,"slot");te(this,"value");this.slot=t,this.value=r}getKey(){return this.slot.toBigInt()}toBuffer(){return ht([this.slot,this.value])}static fromBuffer(t){const r=rt.asReader(t);return new Ph(le.fromBuffer(r),le.fromBuffer(r))}equals(t){return this.slot.equals(t.slot)&&this.value.equals(t.value)}toString(){return`PublicDataTreeLeaf(${this.slot.toString()}, ${this.value.toString()})`}isEmpty(){return this.slot.isZero()&&this.value.isZero()}updateTo(t){if(!this.slot.equals(t.slot))throw new Error("Invalid update: slots do not match");return new Ph(this.slot,t.value)}static buildDummy(t){return new Ph(new le(t),new le(0))}static empty(){return new Ph(le.ZERO,le.ZERO)}static get schema(){return K.object({slot:He.Fr,value:He.Fr}).transform(({slot:t,value:r})=>new Ph(t,r))}}class Ct{constructor(t,r){te(this,"root");te(this,"nextAvailableLeafIndex");this.root=t,this.nextAvailableLeafIndex=r}static get schema(){return K.object({root:He.Fr,nextAvailableLeafIndex:He.UInt32}).transform(({root:t,nextAvailableLeafIndex:r})=>new Ct(t,r))}getSize(){return this.root.size+4}toBuffer(){return ht(this.root,this.nextAvailableLeafIndex)}toFields(){return[this.root,new le(this.nextAvailableLeafIndex)]}toString(){return Ur(this.toBuffer())}static fromBuffer(t){const r=rt.asReader(t);return new Ct(le.fromBuffer(r),r.readNumber())}static fromString(t){return Ct.fromBuffer(fn(t))}static fromFields(t){const r=Pt.asReader(t);return new Ct(r.readField(),Number(r.readField().toBigInt()))}static zero(){return new Ct(le.ZERO,0)}isZero(){return this.root.isZero()&&this.nextAvailableLeafIndex===0}
1987[ct.inspect.custom](){return`AppendOnlyTreeSnapshot { root: ${this.root.toString()}, nextAvailableLeafIndex: ${this.nextAvailableLeafIndex} }`}equals(t){return this.root.equals(t.root)&&this.nextAvailableLeafIndex===t.nextAvailableLeafIndex}static random(){return new Ct(le.random(),Math.floor(Math.random()*1e3))}}var Ao=function(e){return e[e.NULLIFIER_TREE=Lge]="NULLIFIER_TREE",e[e.NOTE_HASH_TREE=Dge]="NOTE_HASH_TREE",e[e.PUBLIC_DATA_TREE=Uge]="PUBLIC_DATA_TREE",e[e.L1_TO_L2_MESSAGE_TREE=qge]="L1_TO_L2_MESSAGE_TREE",e[e.ARCHIVE=Vge]="ARCHIVE",e}({});Ao.NOTE_HASH_TREE+"",Ao.ARCHIVE+"",Ao.L1_TO_L2_MESSAGE_TREE+"",Ao.NULLIFIER_TREE+"",Ao.PUBLIC_DATA_TREE+"",Ao.NULLIFIER_TREE+"",Ao.NOTE_HASH_TREE+"",Ao.PUBLIC_DATA_TREE+"",Ao.L1_TO_L2_MESSAGE_TREE+"",Ao.ARCHIVE+"";const Ip=class Ip{constructor(t){te(this,"value");if(this.value=t,t>2**(Ip.SIZE*8)-1)throw new Error(`Selector must fit in ${Ip.SIZE} bytes (got value ${t}).`)}isEmpty(){return this.value===0}toBuffer(t=Ip.SIZE){return Ca(BigInt(this.value),t)}toString(){return Ur(this.toBuffer())}[ct.inspect.custom](){return`Selector<${this.toString()}>`}equals(t){return this.value===t.value}toField(){return new le(BigInt(this.value))}};te(Ip,"SIZE",4);let ra=Ip;class Ic extends ra{static fromBuffer(t){const r=rt.asReader(t),n=Number(co(r.readBytes(ra.SIZE)));return new Ic(n)}static fromField(t){return new Ic(Number(t.toBigInt()))}static async fromSignature(t){if(/\s/.test(t))throw new Error("Signature cannot contain whitespace");const r=(await Dz(je.from(t))).toBuffer().slice(-ra.SIZE);return Ic.fromBuffer(r)}static fromString(t){const r=jB(t);if(r.length!==ra.SIZE)throw new Error(`Invalid EventSelector length ${r.length} (expected ${ra.SIZE}).`);return Ic.fromBuffer(r)}static empty(){return new Ic(0)}static random(){return Ic.fromBuffer(wo(ra.SIZE))}toJSON(){return this.toString()}static get schema(){return Ds(Ic)}}const ga=class ga{constructor(t){te(this,"xCoord");if("length"in t&&t.length!==32)throw new Error(`Invalid AztecAddress length ${t.length}.`);this.xCoord=new le(t)}[ct.inspect.custom](){return`AztecAddress<${this.toString()}>`}static isAddress(t){return/^(0x)?[a-fA-F0-9]{64}$/.test(t)}static zero(){return ga.ZERO}static fromField(t){return new ga(t)}static fromBuffer(t){return new ga(VS(t,le))}static fromFields(t){const r=Pt.asReader(t);return new ga(r.readField())}static fromBigInt(t){return new ga(new le(t))}static fromNumber(t){return new ga(new le(t))}static fromString(t){return new ga(fn(t))}static async random(){for(;;){const t=new ga(le.random());if(await t.isValid())return t}}get size(){return this.xCoord.size}equals(t){return this.xCoord.equals(t.xCoord)}isZero(){return this.xCoord.isZero()}async isValid(){return await Ir.YFromX(this.xCoord)!==null}toAddressPoint(){return Ir.fromXAndSign(this.xCoord,!0)}toBuffer(){return this.xCoord.toBuffer()}toBigInt(){return this.xCoord.toBigInt()}toField(){return this.xCoord}toString(){return this.xCoord.toString()}toJSON(){return this.toString()}static get schema(){return Ds(ga,ga.isAddress)}};te(ga,"SIZE_IN_BYTES",le.SIZE_IN_BYTES),te(ga,"ZERO",new ga(je.alloc(32,0)));let nt=ga;Bh.register("AztecAddress",nt);class ebe{constructor(t,r,n=!1){te(this,"name");te(this,"parameters");te(this,"includeNames");te(this,"separator");this.name=t,this.parameters=r,this.includeNames=n,this.separator=n?", ":","}getParameterType(t){switch(t.kind){case"field":return"Field";case"integer":if(t.sign==="signed")throw new Error("Unsupported type: signed integer");return`u${t.width}`;case"boolean":return"bool";case"array":return`[${this.getParameterType(t.type)};${t.length}]`;case"string":return`str<${t.length}>`;case"struct":return`(${t.fields.map(r=>`${this.decodeParameter(r)}`).join(this.separator)})`;default:throw new Error(`Unsupported type: ${t}`)}}decodeParameter(t){const r=this.getParameterType(t.type);return this.includeNames?`${t.name}: ${r}`:r}decode(){return`${this.name}(${this.parameters.map(t=>this.decodeParameter(t)).join(this.separator)})`}}function tbe(e,t){return new ebe(e,t).decode()}class Yr extends ra{static fromBuffer(t){const r=rt.asReader(t),n=Number(co(r.readBytes(ra.SIZE)));return new Yr(n)}static fromField(t){return new Yr(Number(t.toBigInt()))}static fromFields(t){const r=Pt.asReader(t);return Yr.fromField(r.readField())}static async fromSignature(t){if(/\s/.test(t))throw new Error("Signature cannot contain whitespace");const r=(await Dz(je.from(t))).toBuffer().slice(-ra.SIZE);return Yr.fromBuffer(r)}static fromString(t){const r=jB(t);if(r.length!==ra.SIZE)throw new Error(`Invalid FunctionSelector length ${r.length} (expected ${ra.SIZE}).`);return Yr.fromBuffer(r)}static empty(){return new Yr(0)}static async fromNameAndParameters(t,r){const{name:n,parameters:i}=typeof t=="string"?{name:t,parameters:r}:t,a=tbe(n,i);return await this.fromSignature(a)}static random(){return Yr.fromBuffer(wo(ra.SIZE))}toJSON(){return this.toString()}static get schema(){return Ds(Yr)}}Bh.register("FunctionSelector",Yr);class Co extends ra{static fromBuffer(t){const r=rt.asReader(t),n=Number(co(r.readBytes(ra.SIZE)));if(n>=128)throw new Error(`Invalid note selector: ${n}`);return new Co(n)}static fromString(t){const r=t.replace(/^0x/i,"").slice(-8),n=je.from(r,"hex");return Co.fromBuffer(n)}static fromField(t){return new Co(Number(t.toBigInt()))}static empty(){return new Co(0)}static random(){const t=RS(128);return Co.fromField(new le(t))}toJSON(){return this.toString()}static get schema(){return Ds(Co)}}Bh.register("NoteSelector",Co);const Be={EthAddress:He.EthAddress,Fr:He.Fr,Fq:He.Fq,Point:He.Point,BigInt:He.BigInt,Integer:He.Integer,UInt32:He.UInt32,Buffer32:He.Buffer32,Buffer:He.Buffer,BufferHex:He.BufferHex,HexString:He.HexString,AztecAddress:nt.schema,NoteSelector:Co.schema,FunctionSelector:Yr.schema,EventSelector:Ic.schema},Fb=K.union([Be.BigInt,K.boolean(),Be.AztecAddress,K.array(K.lazy(()=>Fb)),K.record(K.lazy(()=>Fb))]);class Pb{constructor(t,r,n){te(this,"index");te(this,"leafPreimage");te(this,"siblingPath");this.index=t,this.leafPreimage=r,this.siblingPath=n}static get schema(){return K.object({index:Be.BigInt,leafPreimage:vl.schema,siblingPath:An.schemaFor(ok)}).transform(({index:t,leafPreimage:r,siblingPath:n})=>new Pb(t,r,n))}static random(){return new Pb(BigInt(Math.floor(Math.random()*1e3)),vl.random(),An.random(ok))}toFields(){return[new le(this.index),...this.leafPreimage.toFields(),...this.siblingPath.toFields()]}toNoirRepresentation(){return[new le(this.index).toString(),...this.leafPreimage.toFields().map(t=>t.toString()),this.siblingPath.toFields().map(t=>t.toString())]}}class X0{constructor(t,r,n){te(this,"index");te(this,"leafPreimage");te(this,"siblingPath");this.index=t,this.leafPreimage=r,this.siblingPath=n}static get schema(){return K.object({index:Be.BigInt,leafPreimage:Mo.schema,siblingPath:An.schemaFor(Hx)}).transform(({index:t,leafPreimage:r,siblingPath:n})=>new X0(t,r,n))}toFields(){return[new le(this.index),new le(this.leafPreimage.slot),new le(this.leafPreimage.value),new le(this.leafPreimage.nextIndex),new le(this.leafPreimage.nextSlot),...this.siblingPath.toFields()]}toNoirRepresentation(){return[new le(this.index).toString(),new le(this.leafPreimage.slot).toString(),new le(this.leafPreimage.value).toString(),new le(this.leafPreimage.nextSlot).toString(),new le(this.leafPreimage.nextIndex).toString(),this.siblingPath.toFields().map(t=>t.toString())]}toBuffer(){return ht([this.index,this.leafPreimage,this.siblingPath])}toString(){return Ur(this.toBuffer())}static random(){return new X0(BigInt(Math.floor(Math.random()*1e3)),Mo.random(),An.random(Hx))}static fromBuffer(t){const r=rt.asReader(t);return new X0(co(r.readBytes(32)),r.readObject(Mo),An.fromBuffer(r.readBytes(4+32*Hx)))}static fromString(t){return X0.fromBuffer(fn(t))}}var ZL={exports:{}},fk,$L;function rbe(){if($L)return fk;$L=1;var e=1e3,t=e*60,r=t*60,n=r*24,i=n*7,a=n*365.25;fk=function(u,d){d=d||{};var p=typeof u;
vendor: 4,295 bytes, line 1987
1987if(p==="string"&&u.length>0)return s(u);if(p==="number"&&isFinite(u))return d.long?c(u):o(u);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(u))};function s(u){if(u=String(u),!(u.length>100)){var d=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(u);if(d){var p=parseFloat(d[1]),w=(d[2]||"ms").toLowerCase();switch(w){case"years":case"year":case"yrs":case"yr":case"y":return p*a;case"weeks":case"week":case"w":return p*i;case"days":case"day":case"d":return p*n;case"hours":case"hour":case"hrs":case"hr":case"h":return p*r;case"minutes":case"minute":case"mins":case"min":case"m":return p*t;case"seconds":case"second":case"secs":case"sec":case"s":return p*e;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return p;default:return}}}}function o(u){var d=Math.abs(u);return d>=n?Math.round(u/n)+"d":d>=r?Math.round(u/r)+"h":d>=t?Math.round(u/t)+"m":d>=e?Math.round(u/e)+"s":u+"ms"}function c(u){var d=Math.abs(u);return d>=n?l(u,d,n,"day"):d>=r?l(u,d,r,"hour"):d>=t?l(u,d,t,"minute"):d>=e?l(u,d,e,"second"):u+" ms"}function l(u,d,p,w){var O=d>=p*1.5;return Math.round(u/p)+" "+w+(O?"s":"")}return fk}function nbe(e){r.debug=r,r.default=r,r.coerce=c,r.disable=s,r.enable=i,r.enabled=o,r.humanize=rbe(),r.destroy=l,Object.keys(e).forEach(u=>{r[u]=e[u]}),r.names=[],r.skips=[],r.formatters={};function t(u){let d=0;for(let p=0;p<u.length;p++)d=(d<<5)-d+u.charCodeAt(p),d|=0;return r.colors[Math.abs(d)%r.colors.length]}r.selectColor=t;function r(u){let d,p=null,w,O;function I(...R){if(!I.enabled)return;const C=I,j=Number(new Date),N=j-(d||j);C.diff=N,C.prev=d,C.curr=j,d=j,R[0]=r.coerce(R[0]),typeof R[0]!="string"&&R.unshift("%O");let P=0;R[0]=R[0].replace(/%([a-zA-Z%])/g,(Z,X)=>{if(Z==="%%")return"%";P++;const re=r.formatters[X];if(typeof re=="function"){const ne=R[P];Z=re.call(C,ne),R.splice(P,1),P--}return Z}),r.formatArgs.call(C,R),(C.log||r.log).apply(C,R)}return I.namespace=u,I.useColors=r.useColors(),I.color=r.selectColor(u),I.extend=n,I.destroy=r.destroy,Object.defineProperty(I,"enabled",{enumerable:!0,configurable:!1,get:()=>p!==null?p:(w!==r.namespaces&&(w=r.namespaces,O=r.enabled(u)),O),set:R=>{p=R}}),typeof r.init=="function"&&r.init(I),I}function n(u,d){const p=r(this.namespace+(typeof d>"u"?":":d)+u);return p.log=this.log,p}function i(u){r.save(u),r.namespaces=u,r.names=[],r.skips=[];const d=(typeof u=="string"?u:"").trim().replace(" ",",").split(",").filter(Boolean);for(const p of d)p[0]==="-"?r.skips.push(p.slice(1)):r.names.push(p)}function a(u,d){let p=0,w=0,O=-1,I=0;for(;p<u.length;)if(w<d.length&&(d[w]===u[p]||d[w]==="*"))d[w]==="*"?(O=w,I=p,w++):(p++,w++);else if(O!==-1)w=O+1,I++,p=I;else return!1;for(;w<d.length&&d[w]==="*";)w++;return w===d.length}function s(){const u=[...r.names,...r.skips.map(d=>"-"+d)].join(",");return r.enable(""),u}function o(u){for(const d of r.skips)if(a(u,d))return!1;for(const d of r.names)if(a(u,d))return!0;return!1}function c(u){return u instanceof Error?u.stack||u.message:u}function l(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return r.enable(r.load()),r}var ibe=nbe;(function(e,t){var r={};t.formatArgs=i,t.save=a,t.load=s,t.useColors=n,t.storage=o(),t.destroy=(()=>{let l=!1;return()=>{l||(l=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#F
1987F6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function n(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let l;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&(l=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(l[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function i(l){if(l[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+l[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const u="color: "+this.color;l.splice(1,0,u,"color: inherit");let d=0,p=0;l[0].replace(/%[a-zA-Z%]/g,w=>{w!=="%%"&&(d++,w==="%c"&&(p=d))}),l.splice(p,0,u)}t.log=console.debug||console.log||(()=>{});function a(l){try{l?t.storage.setItem("debug",l):t.storage.removeItem("debug")}catch{}}function s(){let l;try{l=t.storage.getItem("debug")}catch{}return!l&&typeof ot<"u"&&"env"in ot&&(l=r.DEBUG),l}function o(){try{return localStorage}catch{}}e.exports=ibe(t);const{formatters:c}=e.exports;c.j=function(l){try{return JSON.stringify(l)}catch(u){return"[UnexpectedJSONParseError]: "+u.message}}})(ZL,ZL.exports);class To{constructor(t,r,n,i){te(this,"masterNullifierPublicKey");te(this,"masterIncomingViewingPublicKey");te(this,"masterOutgoingViewingPublicKey");te(this,"masterTaggingPublicKey");this.masterNullifierPublicKey=t,this.masterIncomingViewingPublicKey=r,this.masterOutgoingViewingPublicKey=n,this.masterTaggingPublicKey=i}static get schema(){return K.object({masterNullifierPublicKey:He.Point,masterIncomingViewingPublicKey:He.Point,masterOutgoingViewingPublicKey:He.Point,masterTaggingPublicKey:He.Point}).transform(To.from)}static from(t){return new To(t.masterNullifierPublicKey,t.masterIncomingViewingPublicKey,t.masterOutgoingViewingPublicKey,t.masterTaggingPublicKey)}hash(){return this.isEmpty()?le.ZERO:yl([this.masterNullifierPublicKey,this.masterIncomingViewingPublicKey,this.masterOutgoingViewingPublicKey,this.masterTaggingPublicKey],Ba.PUBLIC_KEYS_HASH)}isEmpty(){return this.masterNullifierPublicKey.isZero()&&this.masterIncomingViewingPublicKey.isZero()&&this.masterOutgoingViewingPublicKey.isZero()&&this.masterTaggingPublicKey.isZero()}static default(){return new To(new Ir(new le($ge),new le(Hge),!1),new Ir(new le(Wge),new le(Kge),!1),new Ir(new le(Gge),new le(Yge),!1),new Ir(new le(Xge),new le(Jge),!1))}static async random(){return new To(await Ir.random(),await Ir.random(),await Ir.random(),await Ir.random())}equals(t){return this.masterNullifierPublicKey.equals(t.masterNullifierPublicKey)&&this.masterIncomingViewingPublicKey.equals(t.masterIncomingViewingPublicKey)&&this.masterOutgoingViewingPublicKey.equals(t.masterOutgoingViewingPublicKey)&&this.masterTaggingPublicKey.equals(t.masterTaggingPublicKey)}toBuffer(){return ht([this.masterNullifierPublicKey,this.masterIncomingViewingPublicKey,this.masterOutgoingViewingPublicKey,this.masterTaggingPublicKey])}static fromBuffer(t){const r=rt.asReader(t),n=r.readObject(Ir),i=r.readObject(Ir),a=r.readObject(Ir),s=r.readObject(Ir);return new To(n,i,a,s)}toNoirStruct(){return{npk_m:this.masterNullifierPublicKey.toWrappedNoirStruct(),ivpk_m:this.masterIncomingViewingPublicKey.toWrappedNoirStruct(),ovpk_m:this.masterOutgoingViewingPublicKey.toWrappedNoirStruct(),tpk_m:this.masterTaggingPublicKey.toWrappedNoirStruct()}}toFields(){return[...this.masterNullifierPublicKey.toFields(),...this.masterIncomingViewingPublicKey.toFields(),...this.masterOutgoingViewingPublicKey.toFields(),...this.masterTaggingPublicKey.toFields()]}encodeToNoir(){return this.toFields()}static fromFields(t){const r=Pt.asReader(t);return new To(r.readObject(Ir),r.readObject(Ir),r.readObject(Ir),r.readObject(Ir))}toString(){return Ur(this.toBuffer())}static fromString(t){return To.fromBuffer(je.from(Ob(t),"hex"))}}function abe(e){return Zx([e,Ba.NSK_M])}function sbe(e){return Zx([e,Ba.IVSK_M])}function obe(e){return Zx([e,Ba.OVSK_M])}function HL(e,t){return yl([e,t],Ba.CONTRACT_ADDRESS_V1)}async function WL(e,t){const r=await HL(await e.hash(),t),n=await new $x().add(await zb(new Rh(r.toBigInt())),e.masterIncomingViewingPublicKey);return new nt(n.x)}function zb(e){const t=new $x;return t.mul(t.generator(),e)}async function lbe(e){const t=abe(e),r=sbe(e),n=obe(e),i=Zx([e,Ba.TSK_M]),a=await zb(t),s=await zb(r),o=await zb(n),c=await zb(i),l=new To(a,s,o,c);return{masterNullifierSecretKey:t,masterIncomingViewingSecretKey:r,masterOutgoingViewingSecretKey:n,masterTaggingSecretKey:i,publicKeys:l}}function cbe(e){return e.length===0?Promise.resolve(le.ZERO):yl(e,Ba.FUNCTION_ARGS)}function KL(e){return e.length===0?Promise.resolve(le.ZERO):yl(e,Ba.PUBLIC_CALLDATA)}class Xu{constructor(t){te(this,"items");this.items=t}toBuffer(){return ht(this.items.length,this.items)}toFriendlyJSON(){return this.items}}
1987class Oc{constructor(t,r){te(this,"requestHash");te(this,"witness");this.requestHash=t,this.witness=r.map(n=>new le(n))}static get schema(){return Ds(Oc)}toJSON(){return this.toString()}toBuffer(){return ht(this.requestHash,new Xu(this.witness))}static fromBuffer(t){const r=rt.asReader(t);return new Oc(le.fromBuffer(r),r.readVector(le))}toString(){return Ur(this.toBuffer())}static fromString(t){return Oc.fromBuffer(fn(t))}static random(){return new Oc(le.random(),[le.random(),le.random(),le.random()])}}K.object({l1StartBlock:Be.BigInt,l1GenesisTime:Be.BigInt,slotDuration:K.number(),epochDuration:K.number(),ethereumSlotDuration:K.number()});const xi=32;class jo{constructor(t,r,n,i){te(this,"numTxs");te(this,"blobsHash");te(this,"inHash");te(this,"outHash");if(this.numTxs=t,this.blobsHash=r,this.inHash=n,this.outHash=i,r.length!==xi)throw new Error(`blobsHash buffer must be ${xi} bytes`);if(r[0]!==0)throw new Error("blobsHash buffer should be truncated and left padded");if(n.length!==xi)throw new Error(`inHash buffer must be ${xi} bytes`);if(n[0]!==0)throw new Error("inHash buffer should be truncated and left padded");if(i.length!==xi)throw new Error(`outHash buffer must be ${xi} bytes`);if(i[0]!==0)throw new Error("outHash buffer should be truncated and left padded")}static get schema(){return K.object({numTxs:He.Fr,blobsHash:He.Buffer,inHash:He.Buffer,outHash:He.Buffer}).transform(({numTxs:t,blobsHash:r,inHash:n,outHash:i})=>new jo(t,r,n,i))}getSize(){return this.toBuffer().length}toBuffer(){return ht(this.numTxs,this.blobsHash,this.inHash,this.outHash)}toInspect(){return{numTxs:this.numTxs.toNumber(),blobsHash:Ur(this.blobsHash),inHash:Ur(this.inHash),outHash:Ur(this.outHash)}}toFields(){const t=[this.numTxs,le.fromBuffer(this.blobsHash),le.fromBuffer(this.inHash),le.fromBuffer(this.outHash)];if(t.length!==uL)throw new Error(`Expected content commitment to have ${uL} fields, but it has ${t.length} fields`);return t}static fromBuffer(t){const r=rt.asReader(t);return new jo(r.readObject(le),r.readBytes(xi),r.readBytes(xi),r.readBytes(xi))}static fromFields(t){const r=Pt.asReader(t);return new jo(r.readField(),r.readField().toBuffer(),r.readField().toBuffer(),r.readField().toBuffer())}static empty(){return new jo(le.zero(),je.alloc(xi),je.alloc(xi),je.alloc(xi))}isEmpty(){return this.numTxs.isZero()&&this.blobsHash.equals(je.alloc(xi))&&this.inHash.equals(je.alloc(xi))&&this.outHash.equals(je.alloc(xi))}toString(){return Ur(this.toBuffer())}static fromString(t){const r=je.from(t.replace(/^0x/i,""),"hex");return jo.fromBuffer(r)}equals(t){return this.inHash.equals(t.inHash)&&this.outHash.equals(t.outHash)&&this.numTxs.equals(t.numTxs)&&this.blobsHash.equals(t.blobsHash)}}function hk(e,t){return JSON.stringify(e,(r,n)=>typeof n=="bigint"?n.toString():typeof n=="object"&&n&&n.type==="Buffer"&&Array.isArray(n.data)?I6.from(n.data).toString("base64"):typeof n=="object"&&n&&I6.isBuffer(n)?n.toString("base64"):typeof n=="object"&&n instanceof Map?Array.from(n.entries()):typeof n=="object"&&n instanceof Set?Array.from(n.values()):n,0)}class qr{constructor(t,r){te(this,"feePerDaGas");te(this,"feePerL2Gas");this.feePerDaGas=new le(t),this.feePerL2Gas=new le(r)}static get schema(){return K.object({feePerDaGas:He.Fr,feePerL2Gas:He.Fr}).transform(qr.from)}clone(){return new qr(this.feePerDaGas,this.feePerL2Gas)}equals(t){return this.feePerDaGas.equals(t.feePerDaGas)&&this.feePerL2Gas.equals(t.feePerL2Gas)}get(t){switch(t){case"da":return this.feePerDaGas;case"l2":return this.feePerL2Gas}}mul(t){return t===1||t===1n?this.clone():typeof t=="bigint"?new qr(new le(this.feePerDaGas.toBigInt()*t),new le(this.feePerL2Gas.toBigInt()*t)):new qr(new le(this.feePerDaGas.toNumberUnsafe()*t),new le(this.feePerL2Gas.toNumberUnsafe()*t))}static from(t){return new qr(t.feePerDaGas,t.feePerL2Gas)}static random(){return new qr(le.random(),le.random())}static empty(){return new qr(le.ZERO,le.ZERO)}isEmpty(){return this.feePerDaGas.isZero()&&this.feePerL2Gas.isZero()}static fromBuffer(t){const r=rt.asReader(t);return new qr(r.readObject(le),r.readObject(le))}toBuffer(){return ht(this.feePerDaGas,this.feePerL2Gas)}static fromFields(t){const r=Pt.asReader(t);return new qr(r.readField(),r.readField())}toFields(){return Gr(this.feePerDaGas,this.feePerL2Gas)}toInspect(){return{feePerDaGas:this.feePerDaGas.toNumberUnsafe(),feePerL2Gas:this.feePerL2Gas.toNumberUnsafe()}}[ct.inspect.custom](){return`GasFees { feePerDaGas=${this.feePerDaGas.toBigInt()} feePerL2Gas=${this.feePerL2Gas.toBigInt()} }`}}class si{constructor(t,r,n,i,a,s,o,c){te(this,"chainId");te(this,"version");te(this,"blockNumber");te(this,"slotNumber");te(this,"timestamp");te(this,"coinbase");te(this,"feeRecipient");te(this,"gasFees");this.chainId=t,this.version=r,this.blockNumber=n,this.slotNumber=i,this.timestamp=a,this.coinbase=s,this.feeRecipient=o,this.gasFees=c}static get schema(){return K.object({chainId:Be.Fr,version:Be.Fr,blockNumber:Be.Fr,slotNumber:Be.Fr,timestamp:Be.Fr,coinbase:Be.EthAddress,feeRecipient:Be.AztecAddress,gasFees:qr.schema}).transform(si.from)}getSize(){return this.toBuffer().length}static from(t){return new si(...si.getFields(t))}static empty(t={}){return si.from({blockNumber:le.ZERO,slotNumber:le.ZERO,timestamp:le.ZERO,chainId:le.ZERO,version:le.ZERO,coinbase:Eo.ZERO,feeRecipient:nt.ZERO,gasFees:qr.empty(),...t})}static fromBuffer(t){const r=rt.asReader(t);return new si(le.fromBuffer(r),le.fromBuffer(r),le.fromBuffer(r),le.fromBuffer(r),le.fromBuffer(r),r.readObject(Eo),r.readObject(nt),r.readObject(qr))}static fromFields(t){const r=Pt.asReader(t);return new si(r.readField(),r.readField(),r.readField(),r.readField(),r.readField(),Eo.fromField(r.readField()),nt.fromField(r.readField()),qr.fromFields(r))}static getFields(t){return[t.chainId,t.version,t.blockNumber,t.slotNumber,t.timestamp,t.coinbase,t.feeRecipient,t.gasFees]}toBuffer(){return ht(...si.getFields(this))}toFields(){const t=Gr(...si.getFields(this));if(t.length!==hL)throw new Error(`Invalid number of fields for GlobalVariables. Expected ${hL}, got ${t.length}`);return t}toFriendlyJSON(){return{blockNumber:this.blockNumber.toNumber(),slotNumber:this.slotNumber.toNumber(),timestamp:this.timestamp.toString(),coinbase:this.coinbase.toString(),gasFees:hk(this.gasFees)}}clone(){return si.fromBuffer(this.toBuffer())}isEmpty(){return this.chainId.isZero()&&this.version.isZero()&&this.blockNumber.isZero()&&this.slotNumber.isZero()&&this.timestamp.isZero()&&this.coinbase.isZero()&&this.feeRecipient.isZero()&&this.gasFees.isEmpty()}toInspect(){return{chainId:this.chainId.toNumber(),version:this.version.toNumber(),blockNumber:this.blockNumber.toNumber(),slotNumber:this.slotNumber.toNumber(),timestamp:this.timestamp.toNumber(),coinbase:this.coinbase.toString(),feeRecipient:this.feeRecipient.toString(),feePerDaGas:this.gasFees.feePerDaGas.toNumber(),feePerL2Gas:this.gasFees.feePerL2Gas.toNumber()}}[ct.inspect.custom](){return`GlobalVariables ${ct.inspect(this.toInspect())}`}equals(t){return this.chainId.equals(t.chainId)&&this.version.equals(t.version)&&this.blockNumber.equals(t.blockNumber)&&this.slotNumber.equals(t.slotNumber)&&this.timestamp.equals(t.timestamp)&&this.coinbase.equals(t.coinbase)&&this.feeRecipient.equals(t.feeRecipient)&&this.gasFees.equals(t.gasFees)}}class wl{constructor(t,r,n){te(this,"noteHashTree");te(this,"nullifierTree");te(this,"publicDataTree");this.noteHashTree=t,this.nullifierTree=r,this.publicDataTree=n}static get schema(){return K.object({noteHashTree:Ct.schema,nullifierTree:Ct.schema,publicDataTree:Ct.schema}).transform(({noteHashTree:t,nullifierTree:r,publicDataTree:n})=>new wl(t,r,n))}getSize(){return this.noteHashTree.getSize()+this.nullifierTree.getSize()+this.publicDataTree.getSize()}static fromBuffer(t){const r=rt.asReader(t);return new wl(r.readObject(Ct),r.readObject(Ct),r.readObject(Ct))}static fromFields(t){const r=Pt.asReader(t),n=Ct.fromFields(r),i=Ct.fromFields(r),a=Ct.fromFields(r);return new wl(n,i,a)}static empty(){return new wl(Ct.zero(),Ct.zero(),Ct.zero())}toBuffer(){return ht(this.noteHashTree,this.nullifierTree,this.publicDataTree)}toFields(){const t=[...this.noteHashTree.toFields(),...this.nullifierTree.toFields(),...this.publicDataTree.toFields()];if(t.length!==yL)throw new Error(`Invalid number of fields for PartialStateReference. Expected ${yL}, got ${t.length}`);return t}isEmpty(){return this.noteHashTree.isZero()&&this.nullifierTree.isZero()&&this.publicDataTree.isZero()}equals(t){return this.noteHashTree.equals(t.noteHashTree)&&this.nullifierTree.equals(t.nullifierTree)&&this.publicDataTree.equals(t.publicDataTree)}}
1987class xl{constructor(t,r){te(this,"l1ToL2MessageTree");te(this,"partial");this.l1ToL2MessageTree=t,this.partial=r}static get schema(){return K.object({l1ToL2MessageTree:Ct.schema,partial:wl.schema}).transform(({l1ToL2MessageTree:t,partial:r})=>new xl(t,r))}getSize(){return this.l1ToL2MessageTree.getSize()+this.partial.getSize()}toBuffer(){return ht(this.l1ToL2MessageTree,this.partial)}toFields(){const t=[...this.l1ToL2MessageTree.toFields(),...this.partial.toFields()];if(t.length!==kL)throw new Error(`Invalid number of fields for StateReference. Expected ${kL}, got ${t.length}`);return t}static fromBuffer(t){const r=rt.asReader(t);return new xl(r.readObject(Ct),r.readObject(wl))}static fromFields(t){const r=Pt.asReader(t),n=Ct.fromFields(r),i=wl.fromFields(r);return new xl(n,i)}static empty(){return new xl(Ct.zero(),wl.empty())}isEmpty(){return this.l1ToL2MessageTree.isZero()&&this.partial.isEmpty()}toInspect(){return{l1ToL2MessageTree:this.l1ToL2MessageTree.root.toString(),noteHashTree:this.partial.noteHashTree.root.toString(),nullifierTree:this.partial.nullifierTree.root.toString(),publicDataTree:this.partial.publicDataTree.root.toString()}}[ct.inspect.custom](){return`StateReference {
1988  l1ToL2MessageTree: ${ct.inspect(this.l1ToL2MessageTree)},
1989  noteHashTree: ${ct.inspect(this.partial.noteHashTree)},
1990  nullifierTree: ${ct.inspect(this.partial.nullifierTree)},
1991  publicDataTree: ${ct.inspect(this.partial.publicDataTree)},
1992}`}equals(t){return this.l1ToL2MessageTree.root.equals(t.l1ToL2MessageTree.root)&&this.partial.equals(t.partial)}}class Xr{constructor(t,r,n,i,a,s){te(this,"lastArchive");te(this,"contentCommitment");te(this,"state");te(this,"globalVariables");te(this,"totalFees");te(this,"totalManaUsed");this.lastArchive=t,this.contentCommitment=r,this.state=n,this.globalVariables=i,this.totalFees=a,this.totalManaUsed=s}static get schema(){return K.object({lastArchive:Ct.schema,contentCommitment:jo.schema,state:xl.schema,globalVariables:si.schema,totalFees:He.Fr,totalManaUsed:He.Fr}).transform(Xr.from)}static getFields(t){return[t.lastArchive,t.contentCommitment,t.state,t.globalVariables,t.totalFees,t.totalManaUsed]}static from(t){return new Xr(...Xr.getFields(t))}getSlot(){return this.globalVariables.slotNumber.toBigInt()}getSize(){return this.lastArchive.getSize()+this.contentCommitment.getSize()+this.state.getSize()+this.globalVariables.getSize()+this.totalFees.size+this.totalManaUsed.size}toBuffer(){return ht(...Xr.getFields(this))}toFields(){const t=Gr(...Xr.getFields(this));if(t.length!==CL)throw new Error(`Invalid number of fields for Header. Expected ${CL}, got ${t.length}`);return t}clone(){return Xr.fromBuffer(this.toBuffer())}static fromBuffer(t){const r=rt.asReader(t);return new Xr(r.readObject(Ct),r.readObject(jo),r.readObject(xl),r.readObject(si),r.readObject(le),r.readObject(le))}static fromFields(t){const r=Pt.asReader(t);return new Xr(Ct.fromFields(r),jo.fromFields(r),xl.fromFields(r),si.fromFields(r),r.readField(),r.readField())}static empty(t={}){return Xr.from({lastArchive:Ct.zero(),contentCommitment:jo.empty(),state:xl.empty(),globalVariables:si.empty(),totalFees:le.ZERO,totalManaUsed:le.ZERO,...t})}isEmpty(){return this.lastArchive.isZero()&&this.contentCommitment.isEmpty()&&this.state.isEmpty()&&this.globalVariables.isEmpty()&&this.totalFees.isZero()&&this.totalManaUsed.isZero()}toString(){return Ur(this.toBuffer())}static fromString(t){return Xr.fromBuffer(fn(t))}hash(){return yl(this.toFields(),Ba.BLOCK_HASH)}toInspect(){return{lastArchive:this.lastArchive.root.toString(),contentCommitment:this.contentCommitment.toInspect(),state:this.state.toInspect(),globalVariables:this.globalVariables.toInspect(),totalFees:this.totalFees.toBigInt(),totalManaUsed:this.totalManaUsed.toBigInt()}}[ct.inspect.custom](){return`Header {
1993  lastArchive: ${ct.inspect(this.lastArchive)},
1994  contentCommitment.numTxs: ${this.contentCommitment.numTxs.toNumber()},
1995  contentCommitment.blobsHash: ${this.contentCommitment.blobsHash.toString("hex")},
1996  contentCommitment.inHash: ${this.contentCommitment.inHash.toString("hex")},
1997  contentCommitment.outHash: ${this.contentCommitment.outHash.toString("hex")},
1998  state.l1ToL2MessageTree: ${ct.inspect(this.state.l1ToL2MessageTree)},
1999  state.noteHashTree: ${ct.inspect(this.state.partial.noteHashTree)},
2000  state.nullifierTree: ${ct.inspect(this.state.partial.nullifierTree)},
2001  state.publicDataTree: ${ct.inspect(this.state.partial.publicDataTree)},
2002  globalVariables: ${ct.inspect(this.globalVariables)},
2003  totalFees: ${this.totalFees},
2004  totalManaUsed: ${this.totalManaUsed},
2005}`}equals(t){return this.contentCommitment.equals(t.contentCommitment)&&this.state.equals(t.state)&&this.globalVariables.equals(t.globalVariables)&&this.totalFees.equals(t.totalFees)&&this.totalManaUsed.equals(t.totalManaUsed)&&this.lastArchive.equals(t.lastArchive)}}const ube=4,GL=0,YL=1,fbe=2;function J0(e){let t=e.length;for(;--t>=0;)e[t]=0}const hbe=0,XL=1,dbe=2,pbe=3,mbe=258,dk=29,Lb=256,Db=Lb+1+dk,Q0=30,pk=19,JL=2*Db+1,zh=15,mk=16,gbe=7,gk=256,QL=16,eD=17,tD=18,bk=new Uint8Array([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]),Kx=new Uint8Array([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]),bbe=ne
vendor: 45,929 bytes, line 2005
2005w Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),rD=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),ybe=512,Bc=new Array((Db+2)*2);J0(Bc);const Ub=new Array(Q0*2);J0(Ub);const qb=new Array(ybe);J0(qb);const Vb=new Array(mbe-pbe+1);J0(Vb);const yk=new Array(dk);J0(yk);const Gx=new Array(Q0);J0(Gx);function vk(e,t,r,n,i){this.static_tree=e,this.extra_bits=t,this.extra_base=r,this.elems=n,this.max_length=i,this.has_stree=e&&e.length}let nD,iD,aD;function wk(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}const sD=e=>e<256?qb[e]:qb[256+(e>>>7)],Zb=(e,t)=>{e.pending_buf[e.pending++]=t&255,e.pending_buf[e.pending++]=t>>>8&255},Ra=(e,t,r)=>{e.bi_valid>mk-r?(e.bi_buf|=t<<e.bi_valid&65535,Zb(e,e.bi_buf),e.bi_buf=t>>mk-e.bi_valid,e.bi_valid+=r-mk):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=r)},_l=(e,t,r)=>{Ra(e,r[t*2],r[t*2+1])},oD=(e,t)=>{let r=0;do r|=e&1,e>>>=1,r<<=1;while(--t>0);return r>>>1},vbe=e=>{e.bi_valid===16?(Zb(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=e.bi_buf&255,e.bi_buf>>=8,e.bi_valid-=8)},wbe=(e,t)=>{const r=t.dyn_tree,n=t.max_code,i=t.stat_desc.static_tree,a=t.stat_desc.has_stree,s=t.stat_desc.extra_bits,o=t.stat_desc.extra_base,c=t.stat_desc.max_length;let l,u,d,p,w,O,I=0;for(p=0;p<=zh;p++)e.bl_count[p]=0;for(r[e.heap[e.heap_max]*2+1]=0,l=e.heap_max+1;l<JL;l++)u=e.heap[l],p=r[r[u*2+1]*2+1]+1,p>c&&(p=c,I++),r[u*2+1]=p,!(u>n)&&(e.bl_count[p]++,w=0,u>=o&&(w=s[u-o]),O=r[u*2],e.opt_len+=O*(p+w),a&&(e.static_len+=O*(i[u*2+1]+w)));if(I!==0){do{for(p=c-1;e.bl_count[p]===0;)p--;e.bl_count[p]--,e.bl_count[p+1]+=2,e.bl_count[c]--,I-=2}while(I>0);for(p=c;p!==0;p--)for(u=e.bl_count[p];u!==0;)d=e.heap[--l],!(d>n)&&(r[d*2+1]!==p&&(e.opt_len+=(p-r[d*2+1])*r[d*2],r[d*2+1]=p),u--)}},lD=(e,t,r)=>{const n=new Array(zh+1);let i=0,a,s;for(a=1;a<=zh;a++)i=i+r[a-1]<<1,n[a]=i;for(s=0;s<=t;s++){let o=e[s*2+1];o!==0&&(e[s*2]=oD(n[o]++,o))}},xbe=()=>{let e,t,r,n,i;const a=new Array(zh+1);for(r=0,n=0;n<dk-1;n++)for(yk[n]=r,e=0;e<1<<bk[n];e++)Vb[r++]=n;for(Vb[r-1]=n,i=0,n=0;n<16;n++)for(Gx[n]=i,e=0;e<1<<Kx[n];e++)qb[i++]=n;for(i>>=7;n<Q0;n++)for(Gx[n]=i<<7,e=0;e<1<<Kx[n]-7;e++)qb[256+i++]=n;for(t=0;t<=zh;t++)a[t]=0;for(e=0;e<=143;)Bc[e*2+1]=8,e++,a[8]++;for(;e<=255;)Bc[e*2+1]=9,e++,a[9]++;for(;e<=279;)Bc[e*2+1]=7,e++,a[7]++;for(;e<=287;)Bc[e*2+1]=8,e++,a[8]++;for(lD(Bc,Db+1,a),e=0;e<Q0;e++)Ub[e*2+1]=5,Ub[e*2]=oD(e,5);nD=new vk(Bc,bk,Lb+1,Db,zh),iD=new vk(Ub,Kx,0,Q0,zh),aD=new vk(new Array(0),bbe,0,pk,gbe)},cD=e=>{let t;for(t=0;t<Db;t++)e.dyn_ltree[t*2]=0;for(t=0;t<Q0;t++)e.dyn_dtree[t*2]=0;for(t=0;t<pk;t++)e.bl_tree[t*2]=0;e.dyn_ltree[gk*2]=1,e.opt_len=e.static_len=0,e.sym_next=e.matches=0},uD=e=>{e.bi_valid>8?Zb(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0},fD=(e,t,r,n)=>{const i=t*2,a=r*2;return e[i]<e[a]||e[i]===e[a]&&n[t]<=n[r]},xk=(e,t,r)=>{const n=e.heap[r];let i=r<<1;for(;i<=e.heap_len&&(i<e.heap_len&&fD(t,e.heap[i+1],e.heap[i],e.depth)&&i++,!fD(t,n,e.heap[i],e.depth));)e.heap[r]=e.heap[i],r=i,i<<=1;e.heap[r]=n},hD=(e,t,r)=>{let n,i,a=0,s,o;if(e.sym_next!==0)do n=e.pending_buf[e.sym_buf+a++]&255,n+=(e.pending_buf[e.sym_buf+a++]&255)<<8,i=e.pending_buf[e.sym_buf+a++],n===0?_l(e,i,t):(s=Vb[i],_l(e,s+Lb+1,t),o=bk[s],o!==0&&(i-=yk[s],Ra(e,i,o)),n--,s=sD(n),_l(e,s,r),o=Kx[s],o!==0&&(n-=Gx[s],Ra(e,n,o)));while(a<e.sym_next);_l(e,gk,t)},_k=(e,t)=>{const r=t.dyn_tree,n=t.stat_desc.static_tree,i=t.stat_desc.has_stree,a=t.stat_desc.elems;let s,o,c=-1,l;for(e.heap_len=0,e.heap_max=JL,s=0;s<a;s++)r[s*2]!==0?(e.heap[++e.heap_len]=c=s,e.depth[s]=0):r[s*2+1]=0;for(;e.heap_len<2;)l=e.heap[++e.heap_len]=c<2?++c:0,r[l*2]=1,e.depth[l]=0,e.opt_len--,i&&(e.static_len-=n[l*2+1]);for(t.max_code=c,s=e.heap_len>>1;s>=1;s--)xk(e,r,s);l=a;do s=e.heap[1],e.heap[1]=e.heap[e.heap_len--],xk(e,r,1),o=e.heap[1],e.heap[--e.heap_max]=s,e.heap[--e.heap_max]=o,r[l*2]=r[s*2]+r[o*2],e.depth[l]=(e.depth[s]>=e.depth[o]?e.depth[s]:e.depth[o])+1,r[s*2+1]=r[o*2+1]=l,e.heap[1]=l++,xk(e,r,1);while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],wbe(e,t),lD(r,c,e.bl_count)},dD=(e,t,r)=>{let n,i=-1,a,s=t[0*2+1],o=0,c=7,l=4;for(s===0&&(c=138,l=3),t[(r+1)*2+1]=65535,n=0;n<=r;n++)a=s,s=t[(n+1)*2+1],!(++o<c&&a===s)&&(o<l?e.bl_tree[a*2]+=o:a!==0?(a!==i&&e.bl_tree[a*2]++,e.bl_tree[QL*2]++):o<=10?e.bl_tree[eD*2]++:e.bl_tree[tD*2]++,o=0,i=a,s===0?(c=138,l=3):a===s?(c=6,l=3):(c=7,l=4))},pD=(e,t,r)=>{let n,i=-1,a,s=t[0*2+1],o=0,c=7,l=4;for(s===0&&(c=138,l=3),n=0;n<=r;n++)if(a=s,s=t[(n+1)*2+1],!(++o<c&&a===s)){if(o<l)do _l(e,a,e.bl_tree);while(--o!==0);else a!==0?(a!==i&&(_l(e,a,e.bl_tree),o--),_l(e,QL,e.bl_tree),Ra(e,o-3,2)):o<=10?(_l(e,eD,e.bl_tree),Ra(e,o-3,3)):(_l(e,tD,e.bl_tree),Ra(e,o-11,7));o=0,i=a,s===0?(c=138,l=3):a===s?(c=6,l=3):(c=7,l=4)}},_be=e=>{let t;for(dD(e,e.dyn_ltree,e.l_desc.max_code),dD(e,e.dyn_dtree,e.d_desc.max_code),_k(e,e.bl_desc),t=pk-1;t>=3&&e.bl_tree[rD[t]*2+1]===0;t--);return e.opt_len+=3*(t+1)+5+5+4,t},Sbe=(e,t,r,n)=>{let i;for(Ra(e,t-257,5),Ra(e,r-1,5),Ra(e,n-4,4),i=0;i<n;i++)Ra(e,e.bl_tree[rD[i]*2+1],3);pD(e,e.dyn_ltree,t-1),pD(e,e.dyn_dtree,r-1)},kbe=e=>{let t=4093624447,r;for(r=0;r<=31;r++,t>>>=1)if(t&1&&e.dyn_ltree[r*2]!==0)return GL;if(e.dyn_ltree[9*2]!==0||e.dyn_ltree[10*2]!==0||e.dyn_ltree[13*2]!==0)return YL;for(r=32;r<Lb;r++)if(e.dyn_ltree[r*2]!==0)return YL;return GL};let mD=!1;const Ebe=e=>{mD||(xbe(),mD=!0),e.l_desc=new wk(e.dyn_ltree,nD),e.d_desc=new wk(e.dyn_dtree,iD),e.bl_desc=new wk(e.bl_tree,aD),e.bi_buf=0,e.bi_valid=0,cD(e)},gD=(e,t,r,n)=>{Ra(e,(hbe<<1)+(n?1:0),3),uD(e),Zb(e,r),Zb(e,~r),r&&e.pending_buf.set(e.window.subarray(t,t+r),e.pending),e.pending+=r},Mbe=e=>{Ra(e,XL<<1,3),_l(e,gk,Bc),vbe(e)},Abe=(e,t,r,n)=>{let i,a,s=0;e.level>0?(e.strm.data_type===fbe&&(e.strm.data_type=kbe(e)),_k(e,e.l_desc),_k(e,e.d_desc),s=_be(e),i=e.opt_len+3+7>>>3,a=e.static_len+3+7>>>3,a<=i&&(i=a)):i=a=r+5,r+4<=i&&t!==-1?gD(e,t,r,n):e.strategy===ube||a===i?(Ra(e,(XL<<1)+(n?1:0),3),hD(e,Bc,Ub)):(Ra(e,(dbe<<1)+(n?1:0),3),Sbe(e,e.l_desc.max_code+1,e.d_desc.max_code+1,s+1),hD(e,e.dyn_ltree,e.dyn_dtree)),cD(e),n&&uD(e)},Cbe=(e,t,r)=>(e.pending_buf[e.sym_buf+e.sym_next++]=t,e.pending_buf[e.sym_buf+e.sym_next++]=t>>8,e.pending_buf[e.sym_buf+e.sym_next++]=r,t===0?e.dyn_ltree[r*2]++:(e.matches++,t--,e.dyn_ltree[(Vb[r]+Lb+1)*2]++,e.dyn_dtree[sD(t)*2]++),e.sym_next===e.sym_end);var Tbe=Ebe,jbe=gD,Ibe=Abe,Obe=Cbe,Bbe=Mbe,Rbe={_tr_init:Tbe,_tr_stored_block:jbe,_tr_flush_block:Ibe,_tr_tally:Obe,_tr_align:Bbe},$b=(e,t,r,n)=>{let i=e&65535|0,a=e>>>16&65535|0,s=0;for(;r!==0;){s=r>2e3?2e3:r,r-=s;do i=i+t[n++]|0,a=a+i|0;while(--s);i%=65521,a%=65521}return i|a<<16|0};const Nbe=()=>{let e,t=[];for(var r=0;r<256;r++){e=r;for(var n=0;n<8;n++)e=e&1?3988292384^e>>>1:e>>>1;t[r]=e}return t},Fbe=new Uint32Array(Nbe());var _i=(e,t,r,n)=>{const i=Fbe,a=n+r;e^=-1;for(let s=n;s<a;s++)e=e>>>8^i[(e^t[s])&255];return e^-1},Hb={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},Yx={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8};const{_tr_init:Pbe,_tr_stored_block:Sk,_tr_flush_block:zbe,_tr_tally:Ju,_tr_align:Lbe}=Rbe,{Z_NO_FLUSH:Qu,Z_PARTIAL_FLUSH:Dbe,Z_FULL_FLUSH:Ube,Z_FINISH:Us,Z_BLOCK:bD,Z_OK:Oi,Z_STREAM_END:yD,Z_STREAM_ERROR:Sl,Z_DATA_ERROR:qbe,Z_BUF_ERROR:kk,Z_DEFAULT_COMPRESSION:Vbe,Z_FILTERED:Zbe,Z_HUFFMAN_ONLY:Xx,Z_RLE:$be,Z_FIXED:Hbe,Z_DEFAULT_STRATEGY:Wbe,Z_UNKNOWN:Kbe,Z_DEFLATED:Jx}=Yx,Gbe=9,Ybe=15,Xbe=8,Jbe=29,Qbe=256,Ek=Qbe+1+Jbe,e1e=30,t1e=19,r1e=2*Ek+1,n1e=15,wr=3,ef=258,kl=ef+wr+1,i1e=32,ep=42,Mk=57,Ak=69,Ck=73,Tk=91,jk=103,Lh=113,Wb=666,fa=1,tp=2,Dh=3,rp=4,a1e=3,Uh=(e,t)=>(e.msg=Hb[t],t),vD=e=>e*2-(e>4?9:0),tf=e=>{let t=e.length;for(;--t>=0;)e[t]=0},s1e=e=>{let t,r,n,i=e.w_size;t=e.hash_size,n=t;do r=e.head[--n],e.head[n]=r>=i?r-i:0;while(--t);t=i,n=t;do r=e.prev[--n],e.prev[n]=r>=i?r-i:0;while(--t)};let o1e=(e,t,r)=>(t<<e.hash_shift^r)&e.hash_mask,rf=o1e;const as=e=>{const t=e.state;let r=t.pending;r>e.avail_out&&(r=e.avail_out),r!==0&&(e.output.set(t.pending_buf.subarray(t.pending_out,t.pending_out+r),e.next_out),e.next_out+=r,t.pending_out+=r,e.total_out+=r,e.avail_out-=r,t.pending-=r,t.pending===0&&(t.pending_out=0))},ss=(e,t)=>{zbe(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,as(e.strm)},Cr=(e,t)=>{e.pending_buf[e.pending++]=t},Kb=(e,t)=>{e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=t&255},Ik=(e,t,r,n)=>{let i=e.avail_in;return i>n&&(i=n),i===0?0:(e.avail_in-=i,t.set(e.input.subarray(e.next_in,e.next_in+i),r),e.state.wrap===1?e.adler=$b(e.adler,t,i,r):e.state.wrap===2&&(e.adler=_i(e.adler,t,i,r)),e.next_in+=i,e.total_in+=i,i)},wD=(e,t)=>{let r=e.max_chain_length,n=e.strstart,i,a,s=e.prev_length,o=e.nice_match;const c=e.strstart>e.w_size-kl?e.strstart-(e.w_size-kl):0,l=e.window,u=e.w_mask,d=e.prev,p=e.strstart+ef;let w=l[n+s-1],O=l[n+s];e.prev_length>=e.good_match&&(r>>=2),o>e.lookahead&&(o=e.lookahead);do if(i=t,!(l[i+s]!==O||l[i+s-1]!==w||l[i]!==l[n]||l[++i]!==l[n+1])){n+=2,i++;do;while(l[++n]===l[++i]&&l[++n]===l[++i]&&l[++n]===l[++i]&&l[++n]===l[++i]&&l[++n]===l[++i]&&l[++n]===l[++i]&&l[++n]===l[++i]&&l[++n]===l[++i]&&n<p);if(a=ef-(p-n),n=p-ef,a>s){if(e.match_start=t,s=a,a>=o)break;w=l[n+s-1],O=l[n+s]}}while((t=d[t&u])>c&&--r!==0);return s<=e.lookahead?s:e.lookahead},np=e=>{const t=e.w_size;let r,n,i;do{if(n=e.window_size-e.lookahead-e.strstart,e.strstart>=t+(t-kl)&&(e.window.set(e.window.subarray(t,t+t-n),0),e.match_start-=t,e.strstart-=t,e.block_start-=t,e.insert>e.strstart&&(e.insert=e.strstart),s1e(e),n+=t),e.strm.avail_in===0)break;if(r=Ik(e.strm,e.window,e.strstart+e.lookahead,n),e.lookahead+=r,e.lookahead+e.insert>=wr)for(i=e.strstart-e.insert,e.ins_h=e.window[i],e.ins_h=rf(e,e.ins_h,e.window[i+1]);e.insert&&(e.ins_h=rf(e,e.ins_h,e.window[i+wr-1]),e.prev[i&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=i,i++,e.insert--,!(e.lookahead+e.insert<wr)););}while(e.lookahead<kl&&e.strm.avail_in!==0)},xD=(e,t)=>{let r=e.pending_buf_size-5>e.w_size?e.w_size:e.pending_buf_size-5,n,i,a,s=0,o=e.strm.avail_in;do{if(n=65535,a=e.bi_valid+42>>3,e.strm.avail_out<a||(a=e.strm.avail_out-a,i=e.strstart-e.block_start,n>i+e.strm.avail_in&&(n=i+e.strm.avail_in),n>a&&(n=a),n<r&&(n===0&&t!==Us||t===Qu||n!==i+e.strm.avail_in)))break;s=t===Us&&n===i+e.strm.avail_in?1:0,Sk(e,0,0,s),e.pending_buf[e.pending-4]=n,e.pending_buf[e.pending-3]=n>>8,e.pending_buf[e.pending-2]=~n,e.pending_buf[e.pending-1]=~n>>8,as(e.strm),i&&(i>n&&(i=n),e.strm.output.set(e.window.subarray(e.block_start,e.block_start+i),e.strm.next_out),e.strm.next_out+=i,e.strm.avail_out-=i,e.strm.total_out+=i,e.block_start+=i,n-=i),n&&(Ik(e.strm,e.strm.output,e.strm.next_out,n),e.strm.next_out+=n,e.strm.avail_out-=n,e.strm.total_out+=n)}while(s===0);return o-=e.strm.avail_in,o&&(o>=e.w_size?(e.matches=2,e.window.set(e.strm.input.subarray(e.strm.next_in-e.w_size,e.strm.next_in),0),e.strstart=e.w_size,e.insert=e.strstart):(e.window_size-e.strstart<=o&&(e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,e.insert>e.strstart&&(e.insert=e.strstart)),e.window.set(e.strm.input.subarray(e.strm.next_in-o,e.strm.next_in),e.strstart),e.strstart+=o,e.insert+=o>e.w_size-e.insert?e.w_size-e.insert:o),e.block_start=e.strstart),e.high_water<e.strstart&&(e.high_water=e.strstart),s?rp:t!==Qu&&t!==Us&&e.strm.avail_in===0&&e.strstart===e.block_start?tp:(a=e.window_size-e.strstart,e.strm.avail_in>a&&e.block_start>=e.w_size&&(e.block_start-=e.w_size,e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,a+=e.w_size,e.insert>e.strstart&&(e.insert=e.strstart)),a>e.strm.avail_in&&(a=e.strm.avail_in),a&&(Ik(e.strm,e.window,e.strstart,a),e.strstart+=a,e.insert+=a>e.w_size-e.insert?e.w_size-e.insert:a),e.high_water<e.strstart&&(e.high_water=e.strstart),a=e.bi_valid+42>>3,a=e.pending_buf_size-a>65535?65535:e.pending_buf_size-a,r=a>e.w_size?e.w_size:a,i=e.strstart-e.block_start,(i>=r||(i||t===Us)&&t!==Qu&&e.strm.avail_in===0&&i<=a)&&(n=i>a?a:i,s=t===Us&&e.strm.avail_in===0&&n===i?1:0,Sk(e,e.block_start,n,s),e.block_start+=n,as(e.strm)),s?Dh:fa)},Ok=(e,t)=>{let r,n;for(;;){if(e.lookahead<kl){if(np(e),e.lookahead<kl&&t===Qu)return fa;if(e.lookahead===0)break}if(r=0,e.lookahead>=wr&&(e.ins_h=rf(e,e.ins_h,e.window[e.strstart+wr-1]),r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),r!==0&&e.strstart-r<=e.w_size-kl&&(e.match_length=wD(e,r)),e.match_length>=wr)if(n=Ju(e,e.strstart-e.match_start,e.match_length-wr),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=wr){e.match_length--;do e.strstart++,e.ins_h=rf(e,e.ins_h,e.window[e.strstart+wr-1]),r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart;while(--e.match_length!==0);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=rf(e,e.ins_h,e.window[e.strstart+1]);else n=Ju(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(n&&(ss(e,!1),e.strm.avail_out===0))return fa}return e.insert=e.strstart<wr-1?e.strstart:wr-1,t===Us?(ss(e,!0),e.strm.avail_out===0?Dh:rp):e.sym_next&&(ss(e,!1),e.strm.avail_out===0)?fa:tp},ip=(e,t)=>{let r,n,i;for(;;){if(e.lookahead<kl){if(np(e),e.lookahead<kl&&t===Qu)return fa;if(e.lookahead===0)break}if(r=0,e.lookahead>=wr&&(e.ins_h=rf(e,e.ins_h,e.window[e.strstart+wr-1]),r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=wr-1,r!==0&&e.prev_length<e.max_lazy_match&&e.strstart-r<=e.w_size-kl&&(e.match_length=wD(e,r),e.match_length<=5&&(e.strategy===Zbe||e.match_length===wr&&e.strstart-e.match_start>4096)&&(e.match_length=wr-1)),e.prev_length>=wr&&e.match_length<=e.prev_length){i=e.strstart+e.lookahead-wr,n=Ju(e,e.strstart-1-e.prev_match,e.prev_length-wr),e.lookahead-=e.prev_length-1,e.prev_length-=2;do++e.strstart<=i&&(e.ins_h=rf(e,e.ins_h,e.window[e.strstart+wr-1]),r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart);while(--e.prev_length!==0);if(e.match_available=0,e.match_length=wr-1,e.strstart++,n&&(ss(e,!1),e.strm.avail_out===0))return fa}else if(e.match_available){if(n=Ju(e,0,e.window[e.strstart-1]),n&&ss(e,!1),e.strstart++,e.lookahead--,e.strm.avail_out===0)return fa}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(n=Ju(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<wr-1?e.strstart:wr-1,t===Us?(ss(e,!0),e.strm.avail_out===0?Dh:rp):e.sym_next&&(ss(e,!1),e.strm.avail_out===0)?fa:tp},l1e=(e,t)=>{let r,n,i,a;const s=e.window;for(;;){if(e.lookahead<=ef){if(np(e),e.lookahead<=ef&&t===Qu)return fa;if(e.lookahead===0)break}if(e.match_length=0,e.lookahead>=wr&&e.strstart>0&&(i=e.strstart-1,n=s[i],n===s[++i]&&n===s[++i]&&n===s[++i])){a=e.strstart+ef;do;while(n===s[++i]&&n===s[++i]&&n===s[++i]&&n===s[++i]&&n===s[++i]&&n===s[++i]&&n===s[++i]&&n===s[++i]&&i<a);e.match_length=ef-(a-i),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=wr?(r=Ju(e,1,e.match_length-wr),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(r=Ju(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),r&&(ss(e,!1),e.strm.avail_out===0))return fa}return e.insert=0,t===Us?(ss(e,!0),e.strm.avail_out===0?Dh:rp):e.sym_next&&(ss(e,!1),e.strm.avail_out===0)?fa:tp},c1e=(e,t)=>{let r;for(;;){if(e.lookahead===0&&(np(e),e.lookahead===0)){if(t===Qu)return fa;break}if(e.match_length=0,r=Ju(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,r&&(ss(e,!1),e.strm.avail_out===0))return fa}return e.insert=0,t===Us?(ss(e,!0),e.strm.avail_out===0?Dh:rp):e.sym_next&&(ss(e,!1),e.strm.avail_out===0)?fa:tp};function El(e,t,r,n,i){this.good_length=e,this.max_lazy=t,this.nice_length=r,this.max_chain=n,this.func=i}const Gb=[new El(0,0,0,0,xD),new El(4,4,8,4,Ok),new El(4,5,16,8,Ok),new El(4,6,32,32,Ok),new El(4,4,16,16,ip),new El(8,16,32,32,ip),new El(8,16,128,128,ip),new El(8,32,128,256,ip),new El(32,128,258,1024,ip),new El(32,258,258,4096,ip)],u1e=e=>{e.window_size=2*e.w_size,tf(e.head),e.max_lazy_match=Gb[e.level].max_lazy,e.good_match=Gb[e.level].good_length,e.nice_match=Gb[e.level].nice_length,e.max_chain_length=Gb[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=wr-1,e.match_available=0,e.ins_h=0};function f1e(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Jx,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new Uint16Array(r1e*2),this.dyn_dtree=new Uint16Array((2*e1e+1)*2),this.bl_tree=new Uint16Array((2*t1e+1)*2),tf(this.dyn_ltree),tf(this.dyn_dtree),tf(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(n1e+1),this.heap=new Uint16Array(2*Ek+1),tf(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(2*Ek+1),tf(this.depth),this.sym_buf=0,this.lit_bufsize=0,this.sym_next=0,this.sym_end=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}const Yb=e=>{if(!e)return 1;const t=e.state;return!t||t.strm!==e||t.status!==ep&&t.status!==Mk&&t.status!==Ak&&t.status!==Ck&&t.status!==Tk&&t.status!==jk&&t.status!==Lh&&t.status!==Wb?1:0},_D=e=>{if(Yb(e))return Uh(e,Sl);e.total_in=e.total_out=0,e.data_type=Kbe;const t=e.state;return t.pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap===2?Mk:t.wrap?ep:Lh,e.adler=t.wrap===2?0:1,t.last_flush=-2,Pbe(t),Oi},SD=e=>{const t=_D(e);return t===Oi&&u1e(e.state),t},h1e=(e,t)=>Yb(e)||e.state.wrap!==2?Sl:(e.state.gzhead=t,Oi),kD=(e,t,r,n,i,a)=>{if(!e)return Sl;let s=1;if(t===Vbe&&(t=6),n<0?(s=0,n=-n):n>15&&(s=2,n-=16),i<1||i>Gbe||r!==Jx||n<8||n>15||t<0||t>9||a<0||a>Hbe||n===8&&s!==1)return Uh(e,Sl);n===8&&(n=9);const o=new f1e;return e.state=o,o.strm=e,o.status=ep,o.wrap=s,o.gzhead=null,o.w_bits=n,o.w_size=1<<o.w_bits,o.w_mask=o.w_size-1,o.hash_bits=i+7,o.hash_size=1<<o.hash_bits,o.hash_mask=o.hash_size-1,o.hash_shift=~~((o.hash_bits+wr-1)/wr),o.window=new Uint8Array(o.w_size*2),o.head=new Uint16Array(o.hash_size),o.prev=new Uint16Array(o.w_size),o.lit_bufsize=1<<i+6,o.pending_buf_size=o.lit_bufsize*4,o.pending_buf=new Uint8Array(o.pending_buf_size),o.sym_buf=o.lit_bufsize,o.sym_end=(o.lit_bufsize-1)*3,o.level=t,o.strategy=a,o.method=r,SD(e)},d1e=(e,t)=>kD(e,t,Jx,Ybe,Xbe,Wbe),p1e=(e,t)=>{if(Yb(e)||t>bD||t<0)return e?Uh(e,Sl):Sl;const r=e.state;if(!e.output||e.avail_in!==0&&!e.input||r.status===Wb&&t!==Us)return Uh(e,e.avail_out===0?kk:Sl);const n=r.last_flush;if(r.last_flush=t,r.pending!==0){if(as(e),e.avail_out===0)return r.last_flush=-1,Oi}else if(e.avail_in===0&&vD(t)<=vD(n)&&t!==Us)return Uh(e,kk);if(r.status===Wb&&e.avail_in!==0)return Uh(e,kk);if(r.status===ep&&r.wrap===0&&(r.status=Lh),r.status===ep){let i=Jx+(r.w_bits-8<<4)<<8,a=-1;if(r.strategy>=Xx||r.level<2?a=0:r.level<6?a=1:r.level===6?a=2:a=3,i|=a<<6,r.strstart!==0&&(i|=i1e),i+=31-i%31,Kb(r,i),r.strstart!==0&&(Kb(r,e.adler>>>16),Kb(r,e.adler&65535)),e.adler=1,r.status=Lh,as(e),r.pending!==0)return r.last_flush=-1,Oi}if(r.status===Mk){if(e.adler=0,Cr(r,31),Cr(r,139),Cr(r,8),r.gzhead)Cr(r,(r.gzhead.text?1:0)+(r.gzhead.hcrc?2:0)+(r.gzhead.extra?4:0)+(r.gzhead.name?8:0)+(r.gzhead.comment?16:0)),Cr(r,r.gzhead.time&255),Cr(r,r.gzhead.time>>8&255),Cr(r,r.gzhead.time>>16&255),Cr(r,r.gzhead.time>>24&255),Cr(r,r.level===9?2:r.strategy>=Xx||r.level<2?4:0),Cr(r,r.gzhead.os&255),r.gzhead.extra&&r.gzhead.extra.length&&(Cr(r,r.gzhead.extra.length&255),Cr(r,r.gzhead.extra.length>>8&255)),r.gzhead.hcrc&&(e.adler=_i(e.adler,r.pending_buf,r.pending,0)),r.gzindex=0,r.status=Ak;else if(Cr(r,0),Cr(r,0),Cr(r,0),Cr(r,0),Cr(r,0),Cr(r,r.level===9?2:r.strategy>=Xx||r.level<2?4:0),Cr(r,a1e),r.status=Lh,as(e),r.pending!==0)return r.last_flush=-1,Oi}if(r.status===Ak){if(r.gzhead.extra){let i=r.pending,a=(r.gzhead.extra.length&65535)-r.gzindex;for(;r.pending+a>r.pending_buf_size;){let o=r.pending_buf_size-r.pending;if(r.pending_buf.set(r.gzhead.extra.subarray(r.gzindex,r.gzindex+o),r.pending),r.pending=r.pending_buf_size,r.gzhead.hcrc&&r.pending>i&&(e.adler=_i(e.adler,r.pending_buf,r.pending-i,i)),r.gzindex+=o,as(e),r.pending!==0)return r.last_flush=-1,Oi;i=0,a-=o}let s=new Uint8Array(r.gzhead.extra);r.pending_buf.set(s.subarray(r.gzindex,r.gzindex+a),r.pending),r.pending+=a,r.gzhead.hcrc&&r.pending>i&&(e.adler=_i(e.adler,r.pending_buf,r.pending-i,i)),r.gzindex=0}r.status=Ck}if(r.status===Ck){if(r.gzhead.name){let i=r.pending,a;do{if(r.pending===r.pending_buf_size){if(r.gzhead.hcrc&&r.pending>i&&(e.adler=_i(e.adler,r.pending_buf,r.pending-i,i)),as(e),r.pending!==0)return r.last_flush=-1,Oi;i=0}r.gzindex<r.gzhead.name.length?a=r.gzhead.name.charCodeAt(r.gzindex++)&255:a=0,Cr(r,a)}while(a!==0);r.gzhead.hcrc&&r.pending>i&&(e.adler=_i(e.adler,r.pending_buf,r.pending-i,i)),r.gzindex=0}r.status=Tk}if(r.status===Tk){if(r.gzhead.comment){let i=r.pending,a;do{if(r.pending===r.pending_buf_size){if(r.gzhead.hcrc&&r.pending>i&&(e.adler=_i(e.adler,r.pending_buf,r.pending-i,i)),as(e),r.pending!==0)return r.last_flush=-1,Oi;i=0}r.gzindex<r.gzhead.comment.length?a=r.gzhead.comment.charCodeAt(r.gzindex++)&255:a=0,Cr(r,a)}while(a!==0);r.gzhead.hcrc&&r.pending>i&&(e.adler=_i(e.adler,r.pending_buf,r.pending-i,i))}r.status=jk}if(r.status===jk){if(r.gzhead.hcrc){if(r.pending+2>r.pending_buf_size&&(as(e),r.pending!==0))return r.last_flush=-1,Oi;Cr(r,e.adler&255),Cr(r,e.adler>>8&255),e.adler=0}if(r.status=Lh,as(e),r.pending!==0)return r.last_flush=-1,Oi}if(e.avail_in!==0||r.lookahead!==0||t!==Qu&&r.status!==Wb){let i=r.level===0?xD(r,t):r.strategy===Xx?c1e(r,t):r.strategy===$be?l1e(r,t):Gb[r.level].func(r,t);if((i===Dh||i===rp)&&(r.status=Wb),i===fa||i===Dh)return e.avail_out===0&&(r.last_flush=-1),Oi;if(i===tp&&(t===Dbe?Lbe(r):t!==bD&&(Sk(r,0,0,!1),t===Ube&&(tf(r.head),r.lookahead===0&&(r.strstart=0,r.block_start=0,r.insert=0))),as(e),e.avail_out===0))return r.last_flush=-1,Oi}return t!==Us?Oi:r.wrap<=0?yD:(r.wrap===2?(Cr(r,e.adler&255),Cr(r,e.adler>>8&255),Cr(r,e.adler>>16&255),Cr(r,e.adler>>24&255),Cr(r,e.total_in&255),Cr(r,e.total_in>>8&255),Cr(r,e.total_in>>16&255),Cr(r,e.total_in>>24&255)):(Kb(r,e.adler>>>16),Kb(r,e.adler&65535)),as(e),r.wrap>0&&(r.wrap=-r.wrap),r.pending!==0?Oi:yD)},m1e=e=>{if(Yb(e))return Sl;const t=e.state.status;return e.state=null,t===Lh?Uh(e,qbe):Oi},g1e=(e,t)=>{let r=t.length;if(Yb(e))return Sl;const n=e.state,i=n.wrap;if(i===2||i===1&&n.status!==ep||n.lookahead)return Sl;if(i===1&&(e.adler=$b(e.adler,t,r,0)),n.wrap=0,r>=n.w_size){i===0&&(tf(n.head),n.strstart=0,n.block_start=0,n.insert=0);let c=new Uint8Array(n.w_size);c.set(t.subarray(r-n.w_size,r),0),t=c,r=n.w_size}const a=e.avail_in,s=e.next_in,o=e.input;for(e.avail_in=r,e.next_in=0,e.input=t,np(n);n.lookahead>=wr;){let c=n.strstart,l=n.lookahead-(wr-1);do n.ins_h=rf(n,n.ins_h,n.window[c+wr-1]),n.prev[c&n.w_mask]=n.head[n.ins_h],n.head[n.ins_h]=c,c++;while(--l);n.strstart=c,n.lookahead=wr-1,np(n)}return n.strstart+=n.lookahead,n.block_start=n.strstart,n.insert=n.lookahead,n.lookahead=0,n.match_length=n.prev_length=wr-1,n.match_available=0,e.next_in=s,e.input=o,e.avail_in=a,n.wrap=i,Oi};var b1e=d1e,y1e=kD,v1e=SD,w1e=_D,x1e=h1e,_1e=p1e,S1e=m1e,k1e=g1e,E1e="pako deflate (from Nodeca project)",Xb={deflateInit:b1e,deflateInit2:y1e,deflateReset:v1e,deflateResetKeep:w1e,deflateSetHeader:x1e,deflate:_1e,deflateEnd:S1e,deflateSetDictionary:k1e,deflateInfo:E1e};const M1e=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var A1e=function(e){const t=Array.prototype.slice.call(arguments,1);for(;t.length;){const r=t.shift();if(r){if(typeof r!="object")throw new TypeError(r+"must be non-object");for(const n in r)M1e(r,n)&&(e[n]=r[n])}}return e},C1e=e=>{let t=0;for(let n=0,i=e.length;n<i;n++)t+=e[n].length;const r=new Uint8Array(t);for(let n=0,i=0,a=e.length;n<a;n++){let s=e[n];r.set(s,i),i+=s.length}return r},Qx={assign:A1e,flattenChunks:C1e};let ED=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{ED=!1}const Jb=new Uint8Array(256);for(let e=0;e<256;e++)Jb[e]=e>=252?6:e>=248?5:e>=240?4:e>=224?3:e>=192?2:1;Jb[254]=Jb[254]=1;var T1e=e=>{if(typeof TextEncoder=="function"&&TextEncoder.prototype.encode)return new TextEncoder().encode(e);let t,r,n,i,a,s=e.length,o=0;for(i=0;i<s;i++)r=e.charCodeAt(i),(r&64512)===55296&&i+1<s&&(n=e.charCodeAt(i+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),i++)),o+=r<128?1:r<2048?2:r<65536?3:4;for(t=new Uint8Array(o),a=0,i=0;a<o;i++)r=e.charCodeAt(i),(r&64512)===55296&&i+1<s&&(n=e.charCodeAt(i+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),i++)),r<128?t[a++]=r:r<2048?(t[a++]=192|r>>>6,t[a++]=128|r&63):r<65536?(t[a++]=224|r>>>12,t[a++]=128|r>>>6&63,t[a++]=128|r&63):(t[a++]=240|r>>>18,t[a++]=128|r>>>12&63,t[a++]=128|r>>>6&63,t[a++]=128|r&63);return t};const j1e=(e,t)=>{if(t<65534&&e.subarray&&ED)return String.fromCharCode.apply(null,e.length===t?e:e.subarray(0,t));let r="";for(let n=0;n<t;n++)r+=String.fromCharCode(e[n]);return r};var I1e=(e,t)=>{const r=t||e.length;if(typeof TextDecoder=="function"&&TextDecoder.prototype.decode)return new TextDecoder().decode(e.subarray(0,t));let n,i;const a=new Array(r*2);for(i=0,n=0;n<r;){let s=e[n++];if(s<128){a[i++]=s;continue}let o=Jb[s];if(o>4){a[i++]=65533,n+=o-1;continue}for(s&=o===2?31:o===3?15:7;o>1&&n<r;)s=s<<6|e[n++]&63,o--;if(o>1){a[i++]=65533;continue}s<65536?a[i++]=s:(s-=65536,a[i++]=55296|s>>10&1023,a[i++]=56320|s&1023)}return j1e(a,i)},O1e=(e,t)=>{t=t||e.length,t>e.length&&(t=e.length);let r=t-1;for(;r>=0&&(e[r]&192)===128;)r--;return r<0||r===0?t:r+Jb[e[r]]>t?r:t},Qb={string2buf:T1e,buf2string:I1e,utf8border:O1e};function B1e(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}var MD=B1e;const AD=Object.prototype.toString,{Z_NO_FLUSH:R1e,Z_SYNC_FLUSH:N1e,Z_FULL_FLUSH:F1e,Z_FINISH:P1e,Z_OK:e2,Z_STREAM_END:z1e,Z_DEFAULT_COMPRESSION:L1e,Z_DEFAULT_STRATEGY:D1e,Z_DEFLATED:U1e}=Yx;function Bk(e){this.options=Qx.assign({level:L1e,method:U1e,chunkSize:16384,windowBits:15,memLevel:8,strategy:D1e},e||{});let t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new MD,this.strm.avail_out=0;let r=Xb.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(r!==e2)throw new Error(Hb[r]);if(t.header&&Xb.deflateSetHeader(this.strm,t.header),t.dictionary){let n;if(typeof t.dictionary=="string"?n=Qb.string2buf(t.dictionary):AD.call(t.dictionary)==="[object ArrayBuffer]"?n=new Uint8Array(t.dictionary):n=t.dictionary,r=Xb.deflateSetDictionary(this.strm,n),r!==e2)throw new Error(Hb[r]);this._dict_set=!0}}Bk.prototype.push=function(e,t){const r=this.strm,n=this.options.chunkSize;let i,a;if(this.ended)return!1;for(t===~~t?a=t:a=t===!0?P1e:R1e,typeof e=="string"?r.input=Qb.string2buf(e):AD.call(e)==="[object ArrayBuffer]"?r.input=new Uint8Array(e):r.input=e,r.next_in=0,r.avail_in=r.input.length;;){if(r.avail_out===0&&(r.output=new Uint8Array(n),r.next_out=0,r.avail_out=n),(a===N1e||a===F1e)&&r.avail_out<=6){this.onData(r.output.subarray(0,r.next_out)),r.avail_out=0;continue}if(i=Xb.deflate(r,a),i===z1e)return r.next_out>0&&this.onData(r.output.subarray(0,r.next_out)),i=Xb.deflateEnd(this.strm),this.onEnd(i),this.ended=!0,i===e2;if(r.avail_out===0){this.onData(r.output);continue}if(a>0&&r.next_out>0){this.onData(r.output.subarray(0,r.next_out)),r.avail_out=0;continue}if(r.avail_in===0)break}return!0},Bk.prototype.onData=function(e){this.chunks.push(e)},Bk.prototype.onEnd=function(e){e===e2&&(this.result=Qx.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};const t2=16209,q1e=16191;var V1e=function(e,t){let r,n,i,a,s,o,c,l,u,d,p,w,O,I,R,C,j,N,P,Z,X,re,ne,ae;const ue=e.state;r=e.next_in,ne=e.input,n=r+(e.avail_in-5),i=e.next_out,ae=e.output,a=i-(t-e.avail_out),s=i+(e.avail_out-257),o=ue.dmax,c=ue.wsize,l=ue.whave,u=ue.wnext,d=ue.window,p=ue.hold,w=ue.bits,O=ue.lencode,I=ue.distcode,R=(1<<ue.lenbits)-1,C=(1<<ue.distbits)-1;e:do{w<15&&(p+=ne[r++]<<w,w+=8,p+=ne[r++]<<w,w+=8),j=O[p&R];t:for(;;){if(N=j>>>24,p>>>=N,w-=N,N=j>>>16&255,N===0)ae[i++]=j&65535;else if(N&16){P=j&65535,N&=15,N&&(w<N&&(p+=ne[r++]<<w,w+=8),P+=p&(1<<N)-1,p>>>=N,w-=N),w<15&&(p+=ne[r++]<<w,w+=8,p+=ne[r++]<<w,w+=8),j=I[p&C];r:for(;;){if(N=j>>>24,p>>>=N,w-=N,N=j>>>16&255,N&16){if(Z=j&65535,N&=15,w<N&&(p+=ne[r++]<<w,w+=8,w<N&&(p+=ne[r++]<<w,w+=8)),Z+=p&(1<<N)-1,Z>o){e.msg="invalid distance too far back",ue.mode=t2;break e}if(p>>>=N,w-=N,N=i-a,Z>N){if(N=Z-N,N>l&&ue.sane){e.msg="invalid distance too far back",ue.mode=t2;break e}if(X=0,re=d,u===0){if(X+=c-N,N<P){P-=N;do ae[i++]=d[X++];while(--N);X=i-Z,re=ae}}else if(u<N){if(X+=c+u-N,N-=u,N<P){P-=N;do ae[i++]=d[X++];while(--N);if(X=0,u<P){N=u,P-=N;do ae[i++]=d[X++];while(--N);X=i-Z,re=ae}}}else if(X+=u-N,N<P){P-=N;do ae[i++]=d[X++];while(--N);X=i-Z,re=ae}for(;P>2;)ae[i++]=re[X++],ae[i++]=re[X++],ae[i++]=re[X++],P-=3;P&&(ae[i++]=re[X++],P>1&&(ae[i++]=re[X++]))}else{X=i-Z;do ae[i++]=ae[X++],ae[i++]=ae[X++],ae[i++]=ae[X++],P-=3;while(P>2);P&&(ae[i++]=ae[X++],P>1&&(ae[i++]=ae[X++]))}}else if(N&64){e.msg="invalid distance code",ue.mode=t2;break e}else{j=I[(j&65535)+(p&(1<<N)-1)];continue r}break}}else if(N&64)if(N&32){ue.mode=q1e;break e}else{e.msg="invalid literal/length code",ue.mode=t2;break e}else{j=O[(j&65535)+(p&(1<<N)-1)];continue t}break}}while(r<n&&i<s);P=w>>3,r-=P,w-=P<<3,p&=(1<<w)-1,e.next_in=r,e.next_out=i,e.avail_in=r<n?5+(n-r):5-(r-n),e.avail_out=i<s?257+(s-i):257-(i-s),ue.hold=p,ue.bits=w};const ap=15,CD=852,TD=592,jD=0,Rk=1,ID=2,Z1e=new Uint16Array([3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0]),$1e=new Uint8Array([16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78]),H1e=new Uint16Array([1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0]),W1e=new Uint8Array([16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]);var e1=(e,t,r,n,i,a,s,o)=>{const c=o.bits;let l=0,u=0,d=0,p=0,w=0,O=0,I=0,R=0,C=0,j=0,N,P,Z,X,re,ne=null,ae;const ue=new Uint16Array(ap+1),m=new Uint16Array(ap+1);let A=null,f,g,_;for(l=0;l<=ap;l++)ue[l]=0;for(u=0;u<n;u++)ue[t[r+u]]++;for(w=c,p=ap;p>=1&&ue[p]===0;p--);if(w>p&&(w=p),p===0)return i[a++]=1<<24|64<<16|0,i[a++]=1<<24|64<<16|0,o.bits=1,0;for(d=1;d<p&&ue[d]===0;d++);for(w<d&&(w=d),R=1,l=1;l<=ap;l++)if(R<<=1,R-=ue[l],R<0)return-1;if(R>0&&(e===jD||p!==1))return-1;for(m[1]=0,l=1;l<ap;l++)m[l+1]=m[l]+ue[l];for(u=0;u<n;u++)t[r+u]!==0&&(s[m[t[r+u]]++]=u);if(e===jD?(ne=A=s,ae=20):e===Rk?(ne=Z1e,A=$1e,ae=257):(ne=H1e,A=W1e,ae=0),j=0,u=0,l=d,re=a,O=w,I=0,Z=-1,C=1<<w,X=C-1,e===Rk&&C>CD||e===ID&&C>TD)return 1;for(;;){f=l-I,s[u]+1<ae?(g=0,_=s[u]):s[u]>=ae?(g=A[s[u]-ae],_=ne[s[u]-ae]):(g=96,_=0),N=1<<l-I,P=1<<O,d=P;do P-=N,i[re+(j>>I)+P]=f<<24|g<<16|_|0;while(P!==0);for(N=1<<l-1;j&N;)N>>=1;if(N!==0?(j&=N-1,j+=N):j=0,u++,--ue[l]===0){if(l===p)break;l=t[r+s[u]]}if(l>w&&(j&X)!==Z){for(I===0&&(I=w),re+=d,O=l-I,R=1<<O;O+I<p&&(R-=ue[O+I],!(R<=0));)O++,R<<=1;if(C+=1<<O,e===Rk&&C>CD||e===ID&&C>TD)return 1;Z=j&X,i[Z]=w<<24|O<<16|re-a|0}}return j!==0&&(i[re+j]=l-I<<24|64<<16|0),o.bits=w,0};const K1e=0,OD=1,BD=2,{Z_FINISH:RD,Z_BLOCK:G1e,Z_TREES:r2,Z_OK:qh,Z_STREAM_END:Y1e,Z_NEED_DICT:X1e,Z_STREAM_ERROR:Io,Z_DATA_ERROR:ND,Z_MEM_ERROR:FD,Z_BUF_ERROR:J1e,Z_DEFLATED:PD}=Yx,n2=16180,zD=16181,LD=16182,DD=16183,UD=16184,qD=16185,VD=16186,ZD=16187,$D=16188,HD=16189,i2=16190,Rc=16191,Nk=16192,WD=16193,Fk=16194,KD=16195,GD=16196,YD=16197,XD=16198,a2=16199,s2=16200,JD=16201,QD=16202,eU=16203,tU=16204,rU=16205,Pk=16206,nU=16207,iU=16208,hn=16209,aU=16210,sU=16211,Q1e=852,eye=592,tye=15,rye=tye,oU=e=>(e>>>24&255)+(e>>>8&65280)+((e&65280)<<8)+((e&255)<<24);function nye(){this.strm=null,this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}const Vh=e=>{if(!e)return 1;const t=e.state;return!t||t.strm!==e||t.mode<n2||t.mode>sU?1:0},lU=e=>{if(Vh(e))return Io;const t=e.state;return e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=t.wrap&1),t.mode=n2,t.last=0,t.havedict=0,t.flags=-1,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Int32Array(Q1e),t.distcode=t.distdyn=new Int32Array(eye),t.sane=1,t.back=-1,qh},cU=e=>{if(Vh(e))return Io;const t=e.state;return t.wsize=0,t.whave=0,t.wnext=0,lU(e)},uU=(e,t)=>{let r;if(Vh(e))return Io;const n=e.state;return t<0?(r=0,t=-t):(r=(t>>4)+5,t<48&&(t&=15)),t&&(t<8||t>15)?Io:(n.window!==null&&n.wbits!==t&&(n.window=null),n.wrap=r,n.wbits=t,cU(e))},fU=(e,t)=>{if(!e)return Io;const r=new nye;e.state=r,r.strm=e,r.window=null,r.mode=n2;const n=uU(e,t);return n!==qh&&(e.state=null),n},iye=e=>fU(e,rye);let hU=!0,zk,Lk;const aye=e=>{if(hU){zk=new Int32Array(512),Lk=new Int32Array(32);let t=0;for(;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(e1(OD,e.lens,0,288,zk,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;e1(BD,e.lens,0,32,Lk,0,e.work,{bits:5}),hU=!1}e.lencode=zk,e.lenbits=9,e.distcode=Lk,e.distbits=5},dU=(e,t,r,n)=>{let i;const a=e.state;return a.window===null&&(a.wsize=1<<a.wbits,a.wnext=0,a.whave=0,a.window=new Uint8Array(a.wsize)),n>=a.wsize?(a.window.set(t.subarray(r-a.wsize,r),0),a.wnext=0,a.whave=a.wsize):(i=a.wsize-a.wnext,i>n&&(i=n),a.window.set(t.subarray(r-n,r-n+i),a.wnext),n-=i,n?(a.window.set(t.subarray(r-n,r),0),a.wnext=n,a.whave=a.wsize):(a.wnext+=i,a.wnext===a.wsize&&(a.wnext=0),a.whave<a.wsize&&(a.whave+=i))),0},sye=(e,t)=>{let r,n,i,a,s,o,c,l,u,d,p,w,O,I,R=0,C,j,N,P,Z,X,re,ne;const ae=new Uint8Array(4);let ue,m;const A=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(Vh(e)||!e.output||!e.input&&e.avail_in!==0)return Io;r=e.state,r.mode===Rc&&(r.mode=Nk),s=e.next_out,i=e.output,c=e.avail_out,a=e.next_in,n=e.input,o=e.avail_in,l=r.hold,u=r.bits,d=o,p=c,ne=qh;e:for(;;)switch(r.mode){case n2:if(r.wrap===0){r.mode=Nk;break}for(;u<16;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}if(r.wrap&2&&l===35615){r.wbits===0&&(r.wbits=15),r.check=0,ae[0]=l&255,ae[1]=l>>>8&255,r.check=_i(r.check,ae,2,0),l=0,u=0,r.mode=zD;break}if(r.head&&(r.head.done=!1),!(r.wrap&1)||(((l&255)<<8)+(l>>8))%31){e.msg="incorrect header check",r.mode=hn;break}if((l&15)!==PD){e.msg="unknown compression method",r.mode=hn;break}if(l>>>=4,u-=4,re=(l&15)+8,r.wbits===0&&(r.wbits=re),re>15||re>r.wbits){e.msg="invalid window size",r.mode=hn;break}r.dmax=1<<r.wbits,r.flags=0,e.adler=r.check=1,r.mode=l&512?HD:Rc,l=0,u=0;break;case zD:for(;u<16;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}if(r.flags=l,(r.flags&255)!==PD){e.msg="unknown compression method",r.mode=hn;break}if(r.flags&57344){e.msg="unknown header flags set",r.mode=hn;break}r.head&&(r.head.text=l>>8&1),r.flags&512&&r.wrap&4&&(ae[0]=l&255,ae[1]=l>>>8&255,r.check=_i(r.check,ae,2,0)),l=0,u=0,r.mode=LD;case LD:for(;u<32;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}r.head&&(r.head.time=l),r.flags&512&&r.wrap&4&&(ae[0]=l&255,ae[1]=l>>>8&255,ae[2]=l>>>16&255,ae[3]=l>>>24&255,r.check=_i(r.check,ae,4,0)),l=0,u=0,r.mode=DD;case DD:for(;u<16;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}r.head&&(r.head.xflags=l&255,r.head.os=l>>8),r.flags&512&&r.wrap&4&&(ae[0]=l&255,ae[1]=l>>>8&255,r.check=_i(r.check,ae,2,0)),l=0,u=0,r.mode=UD;case UD:if(r.flags&1024){for(;u<16;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}r.length=l,r.head&&(r.head.extra_len=l),r.flags&512&&r.wrap&4&&(ae[0]=l&255,ae[1]=l>>>8&255,r.check=_i(r.check,ae,2,0)),l=0,u=0}else r.head&&(r.head.extra=null);r.mode=qD;case qD:if(r.flags&1024&&(w=r.length,w>o&&(w=o),w&&(r.head&&(re=r.head.extra_len-r.length,r.head.extra||(r.head.extra=new Uint8Array(r.head.extra_len)),r.head.extra.set(n.subarray(a,a+w),re)),r.flags&512&&r.wrap&4&&(r.check=_i(r.check,n,w,a)),o-=w,a+=w,r.length-=w),r.length))break e;r.length=0,r.mode=VD;case VD:if(r.flags&2048){if(o===0)break e;w=0;do re=n[a+w++],r.head&&re&&r.length<65536&&(r.head.name+=String.fromCharCode(re));while(re&&w<o);if(r.flags&512&&r.wrap&4&&(r.check=_i(r.check,n,w,a)),o-=w,a+=w,re)break e}else r.head&&(r.head.name=null);r.length=0,r.mode=ZD;case ZD:if(r.flags&4096){if(o===0)break e;w=0;do re=n[a+w++],r.head&&re&&r.length<65536&&(r.head.comment+=String.fromCharCode(re));while(re&&w<o);if(r.flags&512&&r.wrap&4&&(r.check=_i(r.check,n,w,a)),o-=w,a+=w,re)break e}else r.head&&(r.head.comment=null);r.mode=$D;case $D:if(r.flags&512){for(;u<16;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}if(r.wrap&4&&l!==(r.check&65535)){e.msg="header crc mismatch",r.mode=hn;break}l=0,u=0}r.head&&(r.head.hcrc=r.flags>>9&1,r.head.done=!0),e.adler=r.check=0,r.mode=Rc;break;case HD:for(;u<32;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}e.adler=r.check=oU(l),l=0,u=0,r.mode=i2;case i2:if(r.havedict===0)return e.next_out=s,e.avail_out=c,e.next_in=a,e.avail_in=o,r.hold=l,r.bits=u,X1e;e.adler=r.check=1,r.mode=Rc;case Rc:if(t===G1e||t===r2)break e;case Nk:if(r.last){l>>>=u&7,u-=u&7,r.mode=Pk;break}for(;u<3;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}switch(r.last=l&1,l>>>=1,u-=1,l&3){case 0:r.mode=WD;break;case 1:if(aye(r),r.mode=a2,t===r2){l>>>=2,u-=2;break e}break;case 2:r.mode=GD;break;case 3:e.msg="invalid block type",r.mode=hn}l>>>=2,u-=2;break;case WD:for(l>>>=u&7,u-=u&7;u<32;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}if((l&65535)!==(l>>>16^65535)){e.msg="invalid stored block lengths",r.mode=hn;break}if(r.length=l&65535,l=0,u=0,r.mode=Fk,t===r2)break e;case Fk:r.mode=KD;case KD:if(w=r.length,w){if(w>o&&(w=o),w>c&&(w=c),w===0)break e;i.set(n.subarray(a,a+w),s),o-=w,a+=w,c-=w,s+=w,r.length-=w;break}r.mode=Rc;break;case GD:for(;u<14;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}if(r.nlen=(l&31)+257,l>>>=5,u-=5,r.ndist=(l&31)+1,l>>>=5,u-=5,r.ncode=(l&15)+4,l>>>=4,u-=4,r.nlen>286||r.ndist>30){e.msg="too many length or distance symbols",r.mode=hn;break}r.have=0,r.mode=YD;case YD:for(;r.have<r.ncode;){for(;u<3;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}r.lens[A[r.have++]]=l&7,l>>>=3,u-=3}for(;r.have<19;)r.lens[A[r.have++]]=0;if(r.lencode=r.lendyn,r.lenbits=7,ue={bits:r.lenbits},ne=e1(K1e,r.lens,0,19,r.lencode,0,r.work,ue),r.lenbits=ue.bits,ne){e.msg="invalid code lengths set",r.mode=hn;break}r.have=0,r.mode=XD;case XD:for(;r.have<r.nlen+r.ndist;){for(;R=r.lencode[l&(1<<r.lenbits)-1],C=R>>>24,j=R>>>16&255,N=R&65535,!(C<=u);){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}if(N<16)l>>>=C,u-=C,r.lens[r.have++]=N;else{if(N===16){for(m=C+2;u<m;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}if(l>>>=C,u-=C,r.have===0){e.msg="invalid bit length repeat",r.mode=hn;break}re=r.lens[r.have-1],w=3+(l&3),l>>>=2,u-=2}else if(N===17){for(m=C+3;u<m;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}l>>>=C,u-=C,re=0,w=3+(l&7),l>>>=3,u-=3}else{for(m=C+7;u<m;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}l>>>=C,u-=C,re=0,w=11+(l&127),l>>>=7,u-=7}if(r.have+w>r.nlen+r.ndist){e.msg="invalid bit length repeat",r.mode=hn;break}for(;w--;)r.lens[r.have++]=re}}if(r.mode===hn)break;if(r.lens[256]===0){e.msg="invalid code -- missing end-of-block",r.mode=hn;break}if(r.lenbits=9,ue={bits:r.lenbits},ne=e1(OD,r.lens,0,r.nlen,r.lencode,0,r.work,ue),r.lenbits=ue.bits,ne){e.msg="invalid literal/lengths set",r.mode=hn;break}if(r.distbits=6,r.distcode=r.distdyn,ue={bits:r.distbits},ne=e1(BD,r.lens,r.nlen,r.ndist,r.distcode,0,r.work,ue),r.distbits=ue.bits,ne){e.msg="invalid distances set",r.mode=hn;break}if(r.mode=a2,t===r2)break e;case a2:r.mode=s2;case s2:if(o>=6&&c>=258){e.next_out=s,e.avail_out=c,e.next_in=a,e.avail_in=o,r.hold=l,r.bits=u,V1e(e,p),s=e.next_out,i=e.output,c=e.avail_out,a=e.next_in,n=e.input,o=e.avail_in,l=r.hold,u=r.bits,r.mode===Rc&&(r.back=-1);break}for(r.back=0;R=r.lencode[l&(1<<r.lenbits)-1],C=R>>>24,j=R>>>16&255,N=R&65535,!(C<=u);){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}if(j&&!(j&240)){for(P=C,Z=j,X=N;R=r.lencode[X+((l&(1<<P+Z)-1)>>P)],C=R>>>24,j=R>>>16&255,N=R&65535,!(P+C<=u);){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}l>>>=P,u-=P,r.back+=P}if(l>>>=C,u-=C,r.back+=C,r.length=N,j===0){r.mode=rU;break}if(j&32){r.back=-1,r.mode=Rc;break}if(j&64){e.msg="invalid literal/length code",r.mode=hn;break}r.extra=j&15,r.mode=JD;case JD:if(r.extra){for(m=r.extra;u<m;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}r.length+=l&(1<<r.extra)-1,l>>>=r.extra,u-=r.extra,r.back+=r.extra}r.was=r.length,r.mode=QD;case QD:for(;R=r.distcode[l&(1<<r.distbits)-1],C=R>>>24,j=R>>>16&255,N=R&65535,!(C<=u);){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}if(!(j&240)){for(P=C,Z=j,X=N;R=r.distcode[X+((l&(1<<P+Z)-1)>>P)],C=R>>>24,j=R>>>16&255,N=R&65535,!(P+C<=u);){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}l>>>=P,u-=P,r.back+=P}if(l>>>=C,u-=C,r.back+=C,j&64){e.msg="invalid distance code",r.mode=hn;break}r.offset=N,r.extra=j&15,r.mode=eU;case eU:if(r.extra){for(m=r.extra;u<m;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}r.offset+=l&(1<<r.extra)-1,l>>>=r.extra,u-=r.extra,r.back+=r.extra}if(r.offset>r.dmax){e.msg="invalid distance too far back",r.mode=hn;break}r.mode=tU;case tU:if(c===0)break e;if(w=p-c,r.offset>w){if(w=r.offset-w,w>r.whave&&r.sane){e.msg="invalid distance too far back",r.mode=hn;break}w>r.wnext?(w-=r.wnext,O=r.wsize-w):O=r.wnext-w,w>r.length&&(w=r.length),I=r.window}else I=i,O=s-r.offset,w=r.length;w>c&&(w=c),c-=w,r.length-=w;do i[s++]=I[O++];while(--w);r.length===0&&(r.mode=s2);break;case rU:if(c===0)break e;i[s++]=r.length,c--,r.mode=s2;break;case Pk:if(r.wrap){for(;u<32;){if(o===0)break e;o--,l|=n[a++]<<u,u+=8}if(p-=c,e.total_out+=p,r.total+=p,r.wrap&4&&p&&(e.adler=r.check=r.flags?_i(r.check,i,p,s-p):$b(r.check,i,p,s-p)),p=c,r.wrap&4&&(r.flags?l:oU(l))!==r.check){e.msg="incorrect data check",r.mode=hn;break}l=0,u=0}r.mode=nU;case nU:if(r.wrap&&r.flags){for(;u<32;){if(o===0)break e;o--,l+=n[a++]<<u,u+=8}if(r.wrap&4&&l!==(r.total&4294967295)){e.msg="incorrect length check",r.mode=hn;break}l=0,u=0}r.mode=iU;case iU:ne=Y1e;break e;case hn:ne=ND;break e;case aU:return FD;case sU:default:return Io}return e.next_out=s,e.avail_out=c,e.next_in=a,e.avail_in=o,r.hold=l,r.bits=u,(r.wsize||p!==e.avail_out&&r.mode<hn&&(r.mode<Pk||t!==RD))&&dU(e,e.output,e.next_out,p-e.avail_out),d-=e.avail_in,p-=e.avail_out,e.total_in+=d,e.total_out+=p,r.total+=p,r.wrap&4&&p&&(e.adler=r.check=r.flags?_i(r.check,i,p,e.next_out-p):$b(r.check,i,p,e.next_out-p)),e.data_type=r.bits+(r.last?64:0)+(r.mode===Rc?128:0)+(r.mode===a2||r.mode===Fk?256:0),(d===0&&p===0||t===RD)&&ne===qh&&(ne=J1e),ne},oye=e=>{if(Vh(e))return Io;let t=e.state;return t.window&&(t.window=null),e.state=null,qh},lye=(e,t)=>{if(Vh(e))return Io;const r=e.state;return r.wrap&2?(r.head=t,t.done=!1,qh):Io},cye=(e,t)=>{const r=t.length;let n,i,a;return Vh(e)||(n=e.state,n.wrap!==0&&n.mode!==i2)?Io:n.mode===i2&&(i=1,i=$b(i,t,r,0),i!==n.check)?ND:(a=dU(e,t,r,r),a?(n.mode=aU,FD):(n.havedict=1,qh))};var uye=cU,fye=uU,hye=lU,dye=iye,pye=fU,mye=sye,gye=oye,bye=lye,yye=cye,vye="pako inflate (from Nodeca project)",Nc={inflateReset:uye,inflateReset2:fye,inflateResetKeep:hye,inflateInit:dye,inflateInit2:pye,inflate:mye,inflateEnd:gye,inflateGetHeader:bye,inflateSetDictionary:yye,inflateInfo:vye};function wye(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}var xye=wye;const pU=Object.prototype.toString,{Z_NO_FLUSH:_ye,Z_FINISH:Sye,Z_OK:t1,Z_STREAM_END:Dk,Z_NEED_DICT:Uk,Z_STREAM_ERROR:kye,Z_DATA_ERROR:mU,Z_MEM_ERROR:Eye}=Yx;function qk(e){this.options=Qx.assign({chunkSize:65536,windowBits:15,to:""},e||{});const t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,t.windowBits===0&&(t.windowBits=-15)),t.windowBits>=0&&t.windowBits<16&&!(e&&e.windowBits)&&(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&(t.windowBits&15||(t.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new MD,this.strm.avail_out=0;let r=Nc.inflateInit2(this.strm,t.windowBits);if(r!==t1)throw new Error(Hb[r]);if(this.header=new xye,Nc.inflateGetHeader(this.strm,this.header),t.dictionary&&(typeof t.dictionary=="string"?t.dictionary=Qb.string2buf(t.dictionary):pU.call(t.dictionary)==="[object ArrayBuffer]"&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(r=Nc.inflateSetDictionary(this.strm,t.dictionary),r!==t1)))throw new Error(Hb[r])}qk.prototype.push=function(e,t){const r=this.strm,n=this.options.chunkSize,i=this.options.dictionary;let a,s,o;if(this.ended)return!1;for(t===~~t?s=t:s=t===!0?Sye:_ye,pU.call(e)==="[object ArrayBuffer]"?r.input
2005=new Uint8Array(e):r.input=e,r.next_in=0,r.avail_in=r.input.length;;){for(r.avail_out===0&&(r.output=new Uint8Array(n),r.next_out=0,r.avail_out=n),a=Nc.inflate(r,s),a===Uk&&i&&(a=Nc.inflateSetDictionary(r,i),a===t1?a=Nc.inflate(r,s):a===mU&&(a=Uk));r.avail_in>0&&a===Dk&&r.state.wrap>0&&e[r.next_in]!==0;)Nc.inflateReset(r),a=Nc.inflate(r,s);switch(a){case kye:case mU:case Uk:case Eye:return this.onEnd(a),this.ended=!0,!1}if(o=r.avail_out,r.next_out&&(r.avail_out===0||a===Dk))if(this.options.to==="string"){let c=Qb.utf8border(r.output,r.next_out),l=r.next_out-c,u=Qb.buf2string(r.output,c);r.next_out=l,r.avail_out=n-l,l&&r.output.set(r.output.subarray(c,c+l),0),this.onData(u)}else this.onData(r.output.length===r.next_out?r.output:r.output.subarray(0,r.next_out));if(!(a===t1&&o===0)){if(a===Dk)return a=Nc.inflateEnd(this.strm),this.onEnd(a),this.ended=!0,!0;if(r.avail_in===0)break}}return!0},qk.prototype.onData=function(e){this.chunks.push(e)},qk.prototype.onEnd=function(e){e===t1&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=Qx.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},V0("aztec:foundation:abi");const o2=K.discriminatedUnion("kind",[K.object({kind:K.literal("boolean"),value:K.boolean()}),K.object({kind:K.literal("string"),value:K.string()}),K.object({kind:K.literal("array"),value:K.array(K.lazy(()=>o2))}),K.object({kind:K.literal("tuple"),fields:K.array(K.lazy(()=>o2))}),K.object({kind:K.literal("integer"),value:K.string(),sign:K.boolean()}),K.object({kind:K.literal("struct"),fields:K.array(K.object({name:K.string(),value:K.lazy(()=>o2)}))})]),gU=["public","private","databus"],Mye=["unsigned","signed"],Fc=K.discriminatedUnion("kind",[K.object({kind:K.literal("field")}),K.object({kind:K.literal("boolean")}),K.object({kind:K.literal("integer"),sign:K.enum(Mye),width:K.number()}),K.object({kind:K.literal("array"),length:K.number(),type:K.lazy(()=>Fc)}),K.object({kind:K.literal("string"),length:K.number()}),K.object({kind:K.literal("struct"),fields:K.array(K.lazy(()=>
2005bU)),path:K.string()}),K.object({kind:K.literal("tuple"),fields:K.array(K.lazy(()=>Fc))})]),bU=K.object({name:K.string(),type:Fc});bU.and(K.object({visibility:K.enum(gU)}));const Aye=K.union([K.object({error_kind:K.literal("string"),string:K.string()}),K.object({error_kind:K.literal("fmtstring"),length:K.number(),item_types:K.array(Fc)}),K.object({error_kind:K.literal("custom")}).and(Fc)]);var yU=function(e){return e.PRIVATE="private",e.PUBLIC="public",e.UNCONSTRAINED="unconstrained",e}({});const vU=K.object({name:K.string(),functionType:K.nativeEnum(yU),isInternal:K.boolean(),isStatic:K.boolean(),isInitializer:K.boolean(),parameters:K.array(K.object({name:K.string(),type:Fc,visibility:K.enum(gU)})),returnTypes:K.array(Fc),errorTypes:K.record(Aye)}),Cye=K.object({debugSymbols:K.object({locations:K.record(K.array(K.object({span:K.object({start:K.number(),end:K.number()}),file:K.number()}))),brillig_locations:K.record(K.record(K.array(K.object({span:K.object({start:K.number(),end:K.number()}),file:K.number()}))))}),files:K.record(K.object({source:K.string(),path:K.string()}))}),Tye=vU.and(K.object({bytecode:He.Buffer,verificationKey:K.string().optional(),debugSymbols:K.string(),debug:Cye.optional()})),jye=K.object({name:K.string(),index:K.number(),nullable:K.boolean()}),Iye=K.object({id:Co.schema,typ:K.string(),fields:K.array(jye)}),l2=K.object({name:K.string(),functions:K.array(Tye),nonDispatchPublicFunctions:K.array(vU),outputs:K.object({structs:K.record(K.array(Fc)).transform(e=>{for(const[t,r]of Object.entries(e))(t==="events"||t==="functions")&&(e[t]=r.sort((n,i)=>n.path>i.path?-1:1));return e}),globals:K.record(K.array(o2))}),storageLayout:K.record(K.object({slot:He.Fr})),notes:K.record(Iye),fileMap:K.record(K.coerce.number(),K.object({source:K.string(),path:K.string()}))});
2005class na{constructor(t,r,n,i){te(this,"msgSender");te(this,"contractAddress");te(this,"functionSelector");te(this,"isStaticCall");this.msgSender=t,this.contractAddress=r,this.functionSelector=n,this.isStaticCall=i}static empty(){return new na(nt.ZERO,nt.ZERO,Yr.empty(),!1)}static async random(){return new na(await nt.random(),await nt.random(),Yr.random(),Math.random()>.5)}static get schema(){return K.object({msgSender:Be.AztecAddress,contractAddress:Be.AztecAddress,functionSelector:Be.FunctionSelector,isStaticCall:K.boolean()}).transform(na.from)}isEmpty(){return this.msgSender.isZero()&&this.contractAddress.isZero()&&this.functionSelector.isEmpty()&&!this.isStaticCall}static from(t){return new na(...na.getFields(t))}static getFields(t){return[t.msgSender,t.contractAddress,t.functionSelector,t.isStaticCall]}toBuffer(){return ht(...na.getFields(this))}toFields(){const t=Gr(...na.getFields(this));if(t.length!==cL)throw new Error(`Invalid number of fields for CallContext. Expected ${cL}, got ${t.length}`);return t}static fromBuffer(t){const r=rt.asReader(t);return new na(r.readObject(nt),r.readObject(nt),r.readObject(Yr),r.readBoolean())}static fromFields(t){const r=Pt.asReader(t);return new na(r.readObject(nt),r.readObject(nt),r.readObject(Yr),r.readBoolean())}equals(t){return t.msgSender.equals(this.msgSender)&&t.contractAddress.equals(this.contractAddress)&&t.functionSelector.equals(this.functionSelector)&&t.isStaticCall===this.isStaticCall}[ct.inspect.custom](){return`CallContext {
2006      msgSender: ${this.msgSender}
2007      contractAddress: ${this.contractAddress}
2008      functionSelector: ${this.functionSelector}
2009      isStaticCall: ${this.isStaticCall}
2010    }`}}class Na{constructor(t,r){te(this,"isSome");te(this,"value");this.isSome=t,this.value=r}toBuffer(){return ht(...Na.getFields(this))}toFields(){const t=Gr(...Na.getFields(this));if(t.length!==mL)throw new Error(`Invalid number of fields for MaxBlockNumber. Expected ${mL}, got ${t.length}`);return t}static fromBuffer(t){const r=rt.asReader(t);return new Na(r.readBoolean(),le.fromBuffer(r))}static fromFields(t){const r=Pt.asReader(t);return new Na(r.readBoolean(),r.readField())}static empty(){return new Na(!1,le.ZERO)}isEmpty(){return!this.isSome&&this.value.isZero()}static from(t){return new Na(...Na.getFields(t))}static getFields(t){return[t.isSome,t.value]}}class Pc{constructor(t,r){te(this,"selector");te(this,"isPrivate");this.selector=t,this.isPrivate=r}static async fromAbi(t){return new Pc(await Yr.fromNameAndParameters(t.name,t.parameters),t.functionType===yU.PRIVATE)}static get schema(){return K.object({selector:Yr.schema,isPrivate:K.boolean()}).transform(({selector:t,isPrivate:r})=>new Pc(t,r))}toBuffer(){return ht(this.selector,this.isPrivate)}toFields(){const t=[this.selector.toField(),new le(this.isPrivate)];if(t.length!==fL)throw new Error(`Invalid number of fields for FunctionData. Expected ${fL}, got ${t.length}`);return t}isEmpty(){return this.selector.isEmpty()}equals(t){return this.selector.equals(t.selector)&&this.isPrivate===t.isPrivate}static empty(t){return new Pc(Yr.empty(),(t==null?void 0:t.isPrivate)??!1)}static fromBuffer(t){const r=rt.asReader(t);return new Pc(r.readObject(Yr),r.readBoolean())}static fromFields(t){const r=Pt.asReader(t),n=Yr.fromFields(r),i=r.readBoolean();return new Pc(n,i)}}class r1{constructor(t,r,n,i){te(this,"l1ToL2MessageTree");te(this,"noteHashTree");te(this,"nullifierTree");te(this,"publicDataTree");this.l1ToL2MessageTree=t,this.noteHashTree=r,this.nullifierTree=n,this.publicDataTree=i}static get schema(){return K.object({l1ToL2MessageTree:Ct.schema,noteHashTree:Ct.schema,nullifierTree:Ct.schema,publicDataTree:Ct.schema}).transform(({l1ToL2MessageTree:t,noteHashTree:r,nullifierTree:n,publicDataTree:i})=>new r1(t,r,n,i))}getSize(){return this.l1ToL2MessageTree.getSize()+this.noteHashTree.getSize()+this.nullifierTree.getSize()+this.publicDataTree.getSize()}static fromBuffer(t){const r=rt.asReader(t);return new r1(r.readObject(Ct),r.readObject(Ct),r.readObject(Ct),r.readObject(Ct))}toBuffer(){return ht(this.l1ToL2MessageTree,this.noteHashTree,this.nullifierTree,this.publicDataTree)}static fromFields(t){const r=Pt.asReader(t),n=Ct.fromFields(r),i=Ct.fromFields(r),a=Ct.fromFields(r),s=Ct.fromFields(r);return new r1(n,i,a,s)}toFields(){const t=[...this.l1ToL2MessageTree.toFields(),...this.noteHashTree.toFields(),...this.nullifierTree.toFields(),...this.publicDataTree.toFields()];if(t.length!==EL)throw new Error(`Invalid number of fields for TreeSnapshots. Expected ${EL}, got ${t.length}`);return t}static empty(){return new r1(Ct.zero(),Ct.zero(),Ct.zero(),Ct.zero())}isEmpty(){return this.l1ToL2MessageTree.isZero()&&this.noteHashTree.isZero()&&this.nullifierTree.isZero()&&this.publicDataTree.isZero()}[ct.inspect.custom](){return`TreeSnapshots {
2011  l1ToL2MessageTree: ${ct.inspect(this.l1ToL2MessageTree)},
2012  noteHashTree: ${ct.inspect(this.noteHashTree)},
2013  nullifierTree: ${ct.inspect(this.nullifierTree)},
2014  publicDataTree: ${ct.inspect(this.publicDataTree)},
2015}`}}const wU=["da","l2"];
2015class cr{constructor(t,r){te(this,"daGas");te(this,"l2Gas");this.daGas=t,this.l2Gas=r}static get schema(){return K.object({daGas:He.UInt32,l2Gas:He.UInt32}).transform(cr.from)}clone(){return new cr(this.daGas,this.l2Gas)}get(t){return this[`${t}Gas`]}equals(t){return this.daGas===t.daGas&&this.l2Gas===t.l2Gas}static from(t){return new cr(t.daGas??0,t.l2Gas??0)}static empty(){return new cr(0,0)}static random(){return new cr(Math.floor(Math.random()*1e9),Math.floor(Math.random()*1e9))}isEmpty(){return this.daGas===0&&this.l2Gas===0}static fromBuffer(t){const r=rt.asReader(t);return new cr(r.readNumber(),r.readNumber())}toBuffer(){return ht(this.daGas,this.l2Gas)}[ct.inspect.custom](){return`Gas { daGas=${this.daGas} l2Gas=${this.l2Gas} }`}add(t){return new cr(this.daGas+t.daGas,this.l2Gas+t.l2Gas)}sub(t){return new cr(this.daGas-t.daGas,this.l2Gas-t.l2Gas)}mul(t){return new cr(Math.ceil(this.daGas*t),Math.ceil(this.l2Gas*t))}gtAny(t){return this.daGas>t.daGas||this.l2Gas>t.l2Gas}computeFee(t){return wU.reduce((r,n)=>r.add(t.get(n).mul(new le(this.get(n)))),le.ZERO)}toFields(){return Gr(this.daGas,this.l2Gas)}static fromFields(t){const r=Pt.asReader(t);return new cr(r.readU32(),r.readU32())}}class Fa{constructor(t,r,n,i){te(this,"gasLimits");te(this,"teardownGasLimits");te(this,"maxFeesPerGas");te(this,"maxPriorityFeesPerGas");this.gasLimits=t,this.teardownGasLimits=r,this.maxFeesPerGas=n,this.maxPriorityFeesPerGas=i}static get schema(){return K.object({gasLimits:cr.schema,teardownGasLimits:cr.schema,maxFeesPerGas:qr.schema,maxPriorityFeesPerGas:qr.schema}).transform(Fa.from)}getSize(){return this.toBuffer().length}static from(t){return new Fa(cr.from(t.gasLimits),cr.from(t.teardownGasLimits),qr.from(t.maxFeesPerGas),qr.from(t.maxPriorityFeesPerGas))}clone(){return new Fa(this.gasLimits.clone(),this.teardownGasLimits.clone(),this.maxFeesPerGas.clone(),this.maxPriorityFeesPerGas.clone())}getFeeLimit(){return wU.reduce((t,r)=>this.maxFeesPerGas.get(r).mul(new le(this.gasLimits.get(r))).add(t),le.ZERO)}static empty(){return new Fa(cr.empty(),cr.empty(),qr.empty(),qr.empty())}static default(t){return Fa.from({gasLimits:t.gasLimits??{l2Gas:NL,daGas:NL},teardownGasLimits:t.teardownGasLimits??{l2Gas:FL,daGas:FL},maxFeesPerGas:t.maxFeesPerGas,maxPriorityFeesPerGas:t.maxPriorityFeesPerGas??qr.empty()})}isEmpty(){return this.gasLimits.isEmpty()&&this.teardownGasLimits.isEmpty()&&this.maxFeesPerGas.isEmpty()&&this.maxPriorityFeesPerGas.isEmpty()}equals(t){return this.gasLimits.equals(t.gasLimits)&&this.teardownGasLimits.equals(t.teardownGasLimits)&&this.maxFeesPerGas.equals(t.maxFeesPerGas)&&this.maxPriorityFeesPerGas.equals(t.maxPriorityFeesPerGas)}static fromBuffer(t){const r=rt.asReader(t);return new Fa(r.readObject(cr),r.readObject(cr),r.readObject(qr),r.readObject(qr))}toBuffer(){return ht(...Fa.getFields(this))}static fromFields(t){const r=Pt.asReader(t);return new Fa(r.readObject(cr),r.readObject(cr),r.readObject(qr),r.readObject(qr))}toFields(){const t=Gr(...Fa.getFields(this));if(t.length!==lL)throw new Error(`Invalid number of fields for GasSettings. Expected ${lL} but got ${t.length}`);return t}static getFields(t){return[t.gasLimits,t.teardownGasLimits,t.maxFeesPerGas,t.maxPriorityFeesPerGas]}}class an{constructor(t,r,n){te(this,"gasSettings");te(this,"chainId");te(this,"version");this.gasSettings=n,this.chainId=new le(t),this.version=new le(r)}static get schema(){return K.object({chainId:He.Fr,version:He.Fr,gasSettings:Fa.schema}).transform(an.from)}getSize(){return this.chainId.size+this.version.size+this.gasSettings.getSize()}clone(){return new an(this.chainId,this.version,this.gasSettings.clone())}toBuffer(){return ht(...an.getFields(this))}static fromFields(t){const r=Pt.asReader(t);return new an(r.readField(),r.readField(),r.readObject(Fa))}toFields(){const t=Gr(...an.getFields(this));if(t.length!==ML)throw new Error(`Invalid number of fields for TxContext. Expected ${ML}, got ${t.length}`);return t}static fromBuffer(t){const r=rt.asReader(t);return new an(le.fromBuffer(r),le.fromBuffer(r),r.readObject(Fa))}static empty(t=0,r=0){return new an(new le(t),new le(r),Fa.empty())}isEmpty(){return this.chainId.isZero()&&this.version.isZero()&&this.gasSettings.isEmpty()}static from(t){return new an(...an.getFields(t))}static getFields(t){return[t.chainId,t.version,t.gasSettings]}}class Bi{constructor(t,r,n,i){te(this,"historicalHeader");te(this,"txContext");te(this,"vkTreeRoot");te(this,"protocolContractTreeRoot");this.historicalHeader=t,this.txContext=r,this.vkTreeRoot=n,this.protocolContractTreeRoot=i}static from(t){return new Bi(...Bi.getFields(t))}static getFields(t){return[t.historicalHeader,t.txContext,t.vkTreeRoot,t.protocolContractTreeRoot]}static fromFields(t){const r=Pt.asReader(t);return new Bi(r.readObject(Xr),r.readObject(an),r.readField(),r.readField())}toFields(){const t=Gr(...Bi.getFields(this));if(t.length!==IL)throw new Error(`Invalid number of fields for TxConstantData. Expected ${IL}, got ${t.length}`);return t}static fromBuffer(t){const r=rt.asReader(t);return new Bi(r.readObject(Xr),r.readObject(an),le.fromBuffer(r),le.fromBuffer(r))}toBuffer(){return ht(...Bi.getFields(this))}static empty(){return new Bi(Xr.empty(),an.empty(),le.ZERO,le.ZERO)}getSize(){return this.historicalHeader.getSize()+this.txContext.getSize()+this.vkTreeRoot.size+this.protocolContractTreeRoot.size}clone(){return Bi.fromBuffer(this.toBuffer())}}class nf{constructor(t,r,n,i){te(this,"origin");te(this,"functionData");te(this,"argsHash");te(this,"txContext");this.origin=t,this.functionData=r,this.argsHash=n,this.txContext=i}static getFields(t){return[t.origin,t.functionData,t.argsHash,t.txContext]}static from(t){return new nf(...nf.getFields(t))}toBuffer(){return ht([...nf.getFields(this)])}toFields(){const t=Gr(...nf.getFields(this));if(t.length!==AL)throw new Error(`Invalid number of fields for TxRequest. Expected ${AL}, got ${t.length}`);return t}static fromBuffer(t){const r=rt.asReader(t);return new nf(r.readObject(nt),r.readObject(Pc),le.fromBuffer(r),r.readObject(an))}hash(){return yl(this.toFields(),Ba.TX_REQUEST)}static empty(){return new nf(nt.ZERO,Pc.empty(),le.zero(),an.empty())}isEmpty(){return this.origin.isZero()&&this.functionData.isEmpty()&&this.argsHash.isZero()&&this.txContext.isEmpty()}}
2015class af{constructor(t,r){te(this,"pkM");te(this,"skApp");this.pkM=t,this.skApp=r instanceof le?r:new le(r.toBigInt())}toBuffer(){return ht(this.pkM,this.skApp)}get skAppAsGrumpkinScalar(){return new zz(this.skApp.toBigInt())}static fromBuffer(t){const r=rt.asReader(t);return new af(Ir.fromBuffer(r),le.fromBuffer(r))}toFields(){const t=[this.pkM.toFields(),this.skApp].flat();if(t.length!==gL)throw new Error(`Invalid number of fields for KeyValidationRequest. Expected ${gL}, got ${t.length}`);return t}static fromFields(t){const r=Pt.asReader(t);return new af(Ir.fromFields(r),r.readField())}isEmpty(){return this.pkM.isZero()&&this.skApp.isZero()}static empty(){return new af(Ir.ZERO,le.ZERO)}static async random(){return new af(await Ir.random(),le.random())}}class Zh{constructor(t,r){te(this,"request");te(this,"skAppGenerator");this.request=t,this.skAppGenerator=r}toBuffer(){return ht(this.request,this.skAppGenerator)}static fromBuffer(t){const r=rt.asReader(t);return new Zh(r.readObject(af),le.fromBuffer(r))}toFields(){const t=[...this.request.toFields(),this.skAppGenerator];if(t.length!==bL)throw new Error(`Invalid number of fields for KeyValidationRequestAndGenerator. Expected ${bL}, got ${t.length}`);return t}static fromFields(t){const r=Pt.asReader(t);return new Zh(af.fromFields(r),r.readField())}isEmpty(){return this.request.isEmpty()&&this.skAppGenerator.isZero()}static empty(){return new Zh(af.empty(),le.ZERO)}}class Ml{constructor(t,r,n){te(this,"value");te(this,"counter");te(this,"length");this.value=t,this.counter=r,this.length=n}toFields(){return[this.value,new le(this.counter),new le(this.length)]}static fromFields(t){const r=Pt.asReader(t);return new Ml(r.readField(),r.readU32(),r.readU32())}isEmpty(){return this.value.isZero()&&!this.length&&!this.counter}static empty(){return new Ml(le.zero(),0,0)}toBuffer(){return ht(this.value,this.counter,this.length)}static fromBuffer(t){const r=rt.asReader(t);return new Ml(le.fromBuffer(r),r.readNumber(),r.readNumber())}toString(){return`value=${this.value} counter=${this.counter} length=${this.length}`}scope(t){return new Al(this,t)}[ct.inspect.custom](){return`LogHash { ${this.toString()} }`}}class Al{constructor(t,r){te(this,"logHash");te(this,"contractAddress");this.logHash=t,this.contractAddress=r}get counter(){return this.logHash.counter}get value(){return this.logHash.value}toFields(){return[...this.logHash.toFields(),this.contractAddress.toField()]}static fromFields(t){const r=Pt.asReader(t);return new Al(r.readObject(Ml),nt.fromField(r.readField()))}isEmpty(){return this.logHash.isEmpty()&&this.contractAddress.isZero()}static empty(){return new Al(Ml.empty(),nt.ZERO)}toBuffer(){return ht(this.logHash,this.contractAddress)}static fromBuffer(t){const r=rt.asReader(t);return new Al(Ml.fromBuffer(r),nt.fromBuffer(r))}toString(){return`logHash=${this.logHash} contractAddress=${this.contractAddress}`}}class $h{constructor(t,r,n,i,a){te(this,"callContext");te(this,"argsHash");te(this,"returnsHash");te(this,"startSideEffectCounter");te(this,"endSideEffectCounter");this.callContext=t,this.argsHash=r,this.returnsHash=n,this.startSideEffectCounter=i,this.endSideEffectCounter=a}toFields(){return Gr([this.callContext,this.argsHash,this.returnsHash,this.startSideEffectCounter,this.endSideEffectCounter])}static fromFields(t){const r=Pt.asReader(t);return new $h(r.readObject(na),r.readField(),r.readField(),r.readU32(),r.readU32())}toBuffer(){return ht(this.callContext,this.argsHash,this.returnsHash,this.startSideEffectCounter,this.endSideEffectCounter)}static fromBuffer(t){const r=rt.asReader(t);return new $h(r.readObject(na),le.fromBuffer(r),le.fromBuffer(r),r.readNumber(),r.readNumber())}isEmpty(){return this.callContext.isEmpty()&&this.argsHash.isZero()&&this.returnsHash.isZero()&&this.startSideEffectCounter===0&&this.endSideEffectCounter===0}static empty(){return new $h(na.empty(),le.ZERO,le.ZERO,0,0)}equals(t){return t.callContext.equals(this.callContext)&&t.argsHash.equals(this.argsHash)&&t.returnsHash.equals(this.returnsHash)&&t.startSideEffectCounter===this.startSideEffectCounter&&t.endSideEffectCounter===this.endSideEffectCounter}toString(){return`PrivateCallRequest(callContext: ${this.callContext}, argsHash: ${this.argsHash}, returnsHash: ${this.returnsHash}, startSideEffectCounter: ${this.startSideEffectCounter}, endSideEffectCounter: ${this.endSideEffectCounter})`}}const yf=class yf{constructor(t){te(this,"fields");this.fields=t}toFields(){return this.fields}static fromFields(t){const r=Pt.asReader(t);
2015return new yf(r.readFieldArray(Nh))}isEmpty(){return this.fields.every(t=>t.isZero())}static empty(){return new yf(Ar(Nh,le.zero))}toBuffer(){return ht(this.fields)}static fromBuffer(t){const r=rt.asReader(t);return new yf(r.readArray(Nh,le))}static random(t=le.random()){return yf.fromFields([t,...Array.from({length:Nh-1},()=>le.random())])}getEmittedLength(){return this.getEmittedFields().length}getEmittedFields(){const t=this.fields.findLastIndex(r=>!r.isZero());return this.fields.slice(0,t+1)}static get schema(){return K.object({fields:K.array(He.Fr)}).transform(({fields:t})=>yf.fromFields(t))}equals(t){return this.fields.every((r,n)=>r.equals(t.fields[n]))}[ct.inspect.custom](){return`PrivateLog {
2016      fields: [${this.fields.map(t=>ct.inspect(t)).join(", ")}],
2017    }`}};te(yf,"SIZE_IN_BYTES",le.SIZE_IN_BYTES*Nh);let Hn=yf;class Pa{constructor(t,r,n){te(this,"log");te(this,"noteHashCounter");te(this,"counter");this.log=t,this.noteHashCounter=r,this.counter=n}static from(t){return new Pa(...Pa.getFields(t))}static getFields(t){return[t.log,t.noteHashCounter,t.counter]}static fromFields(t){const r=Pt.asReader(t);return new Pa(r.readObject(Hn),r.readU32(),r.readU32())}toFields(){const t=Gr(...Pa.getFields(this));if(t.length!==vL)throw new Error(`Invalid number of fields for PrivateLogData. Expected ${vL}, got ${t.length}`);return t}static fromBuffer(t){const r=rt.asReader(t);return new Pa(r.readObject(Hn),r.readNumber(),r.readNumber())}toBuffer(){return ht(...Pa.getFields(this))}static empty(){return new Pa(Hn.empty(),0,0)}isEmpty(){return this.log.isEmpty()&&!this.noteHashCounter&&!this.counter}[ct.inspect.custom](){return`PrivateLogData {
2018      log: ${this.log}
2019      noteHashCounter: ${this.noteHashCounter}
2020      counter: ${this.counter}
2021    }`}}class sf{constructor(t,r){te(this,"inner");te(this,"contractAddress");this.inner=t,this.contractAddress=r}static from(t){return new sf(...sf.getFields(t))}static getFields(t){return[t.inner,t.contractAddress]}toFields(){return Gr(...sf.getFields(this))}static fromFields(t){const r=Pt.asReader(t);return new sf(r.readObject(Pa),nt.fromField(r.readField()))}isEmpty(){return this.inner.isEmpty()&&this.contractAddress.isZero()}static empty(){return new sf(Pa.empty(),nt.ZERO)}toBuffer(){return ht(...sf.getFields(this))}static fromBuffer(t){const r=rt.asReader(t);return new sf(Pa.fromBuffer(r),nt.fromBuffer(r))}[ct.inspect.custom](){return`ScopedPrivateLogData {
2022      inner: ${this.inner}
2023      contractAddress: ${this.contractAddress}
2024    }`}}class qs{constructor(t,r,n){te(this,"recipient");te(this,"content");te(this,"counter");this.recipient=t,this.content=r,this.counter=n}static get schema(){return K.object({recipient:He.EthAddress,content:He.Fr,counter:K.number().int().nonnegative()}).transform(({recipient:t,content:r,counter:n})=>new qs(t,r,n))}static empty(){return new qs(Eo.ZERO,le.zero(),0)}equals(t){return this.recipient.equals(t.recipient)&&this.content.equals(t.content)&&this.counter===t.counter}toBuffer(){return ht(this.recipient,this.content,this.counter)}toFields(){const t=[this.recipient.toField(),this.content,new le(this.counter)];if(t.length!==dL)throw new Error(`Invalid number of fields for L2ToL1Message. Expected ${dL}, got ${t.length}`);return t}static fromFields(t){const r=Pt.asReader(t);return new qs(r.readObject(Eo),r.readField(),r.readU32())}static fromBuffer(t){const r=rt.asReader(t);return new qs(r.readObject(Eo),r.readObject(le),r.readNumber())}isEmpty(){return this.recipient.isZero()&&this.content.isZero()&&!this.counter}scope(t){return new Vs(this,t)}}class Vs{constructor(t,r){te(this,"message");te(this,"contractAddress");this.message=t,this.contractAddress=r}static get schema(){return K.object({message:qs.schema,contractAddress:nt.schema}).transform(({message:t,contractAddress:r})=>new Vs(t,r))}static getFields(t){return[t.message,t.contractAddress]}static empty(){return new Vs(qs.empty(),nt.ZERO)}equals(t){return this.message.equals(t.message)&&this.contractAddress.equals(t.contractAddress)}toBuffer(){return ht(this.message,this.contractAddress)}static fromBuffer(t){const r=rt.asReader(t);return new Vs(r.readObject(qs),r.readObject(nt))}static fromFields(t){const r=Pt.asReader(t);return new Vs(r.readObject(qs),r.readObject(nt))}toFields(){const t=Gr(...Vs.getFields(this));if(t.length!==pL)throw new Error(`Invalid number of fields for ScopedL2ToL1Message. Expected ${pL}, got ${t.length}`);return t}isEmpty(){return this.message.isEmpty()&&this.contractAddress.isZero()}}
2024class os{constructor(t,r){te(this,"value");te(this,"counter");this.value=t,this.counter=r}toBuffer(){return ht(this.value,this.counter)}static fromBuffer(t){const r=rt.asReader(t);return new os(le.fromBuffer(r),r.readNumber())}toFields(){return[this.value,new le(this.counter)]}static fromFields(t){const r=Pt.asReader(t);return new os(r.readField(),r.readU32())}isEmpty(){return this.value.isZero()&&!this.counter}static empty(){return new os(le.zero(),0)}scope(t){return new n1(this,t)}}class n1{constructor(t,r){te(this,"readRequest");te(this,"contractAddress");this.readRequest=t,this.contractAddress=r}get value(){return this.readRequest.value}get counter(){return this.readRequest.counter}toBuffer(){return ht(this.readRequest,this.contractAddress)}static fromBuffer(t){const r=rt.asReader(t);return new n1(os.fromBuffer(r),nt.fromBuffer(r))}toFields(){return[...this.readRequest.toFields(),this.contractAddress.toField()]}static fromFields(t){const r=Pt.asReader(t);return new n1(r.readObject(os),nt.fromField(r.readField()))}isEmpty(){return this.readRequest.isEmpty()&&this.contractAddress.isZero()}static empty(){return new n1(os.empty(),nt.ZERO)}}class Cl{constructor(t,r){te(this,"value");te(this,"counter");this.value=t,this.counter=r}toFields(){return[this.value,new le(this.counter)]}static fromFields(t){const r=Pt.asReader(t);return new Cl(r.readField(),r.readU32())}isEmpty(){return this.value.isZero()&&!this.counter}static empty(){return new Cl(le.zero(),0)}toBuffer(){return ht(this.value,this.counter)}static fromBuffer(t){const r=rt.asReader(t);return new Cl(le.fromBuffer(r),r.readNumber())}toString(){return`value=${this.value} counter=${this.counter}`}scope(t){return new i1(this,t)}}class i1{constructor(t,r){te(this,"noteHash");te(this,"contractAddress");this.noteHash=t,this.contractAddress=r}get counter(){return this.noteHash.counter}get value(){return this.noteHash.value}toFields(){return[...this.noteHash.toFields(),this.contractAddress.toField()]}static fromFields(t){const r=Pt.asReader(t);return new i1(r.readObject(Cl),nt.fromField(r.readField()))}isEmpty(){return this.noteHash.isEmpty()&&this.contractAddress.isZero()}static empty(){return new i1(Cl.empty(),nt.ZERO)}toBuffer(){return ht(this.noteHash,this.contractAddress)}static fromBuffer(t){const r=rt.asReader(t);return new i1(Cl.fromBuffer(r),nt.fromBuffer(r))}toString(){return`noteHash=${this.noteHash} contractAddress=${this.contractAddress}`}}class Tl{constructor(t,r,n){te(this,"value");te(this,"counter");te(this,"noteHash");this.value=t,this.counter=r,this.noteHash=n}toFields(){return[this.value,new le(this.counter),this.noteHash]}static fromFields(t){const r=Pt.asReader(t);return new Tl(r.readField(),r.readU32(),r.readField())}isEmpty(){return this.value.isZero()&&!this.counter&&this.noteHash.isZero()}static empty(){return new Tl(le.zero(),0,le.zero())}toBuffer(){return ht(this.value,this.counter,this.noteHash)}static fromBuffer(t){const r=rt.asReader(t);return new Tl(le.fromBuffer(r),r.readNumber(),le.fromBuffer(r))}toString(){return`value=${this.value} counter=${this.counter} noteHash=${this.noteHash}`}scope(t){return new a1(this,t)}}class a1{constructor(t,r){te(this,"nullifier");te(this,"contractAddress");this.nullifier=t,this.contractAddress=r}get counter(){return this.nullifier.counter}get value(){return this.nullifier.value}get nullifiedNoteHash(){return this.nullifier.noteHash}toFields(){return[...this.nullifier.toFields(),this.contractAddress.toField()]}static fromFields(t){const r=Pt.asReader(t);return new a1(r.readObject(Tl),nt.fromField(r.readField()))}isEmpty(){return this.nullifier.isEmpty()&&this.contractAddress.isZero()}static empty(){return new a1(Tl.empty(),nt.ZERO)}toBuffer(){return ht(this.nullifier,this.contractAddress)}static fromBuffer(t){const r=rt.asReader(t);return new a1(Tl.fromBuffer(r),nt.fromBuffer(r))}toString(){return`nullifier=${this.nullifier} contractAddress=${this.contractAddress}`}}class Jr{constructor(t,r,n,i){te(this,"msgSender");te(this,"contractAddress");te(this,"isStaticCall");te(this,"calldataHash");this.msgSender=t,this.contractAddress=r,this.isStaticCall=n,this.calldataHash=i}static get schema(){return K.object({msgSender:nt.schema,contractAddress:nt.schema,isStaticCall:K.boolean(),calldataHash:He.Fr}).transform(({msgSender:t,contractAddress:r,isStaticCall:n,calldataHash:i})=>new Jr(t,r,n,i))}getSize(){return this.isEmpty()?0:this.toBuffer().length}static from(t){return new Jr(...Jr.getFields(t))}static getFields(t){return[t.msgSender,t.contractAddress,t.isStaticCall,t.calldataHash]}static fromFields(t){const r=Pt.asReader(t);return new Jr(r.readObject(nt),r.readObject(nt),r.readBoolean(),r.readField())}toFields(){const t=Gr(...Jr.getFields(this));if(t.length!==xL)throw new Error(`Invalid number of fields for PublicCallRequest. Expected ${xL}, got ${t.length}`);return t}static fromBuffer(t){const r=rt.asReader(t);return new Jr(r.readObject(nt),r.readObject(nt),r.readBoolean(),r.readObject(le))}toBuffer(){return ht(...Jr.getFields(this))}static empty(){return new Jr(nt.ZERO,nt.ZERO,!1,le.ZERO)}isEmpty(){return this.msgSender.isZero()&&this.contractAddress.isZero()&&!this.isStaticCall&&this.calldataHash.isEmpty()}[ct.inspect.custom](){return`PublicCallRequest {
2025      msgSender: ${this.msgSender}
2026      contractAddress: ${this.contractAddress}
2027      isStaticCall: ${this.isStaticCall}
2028      calldataHash: ${this.calldataHash}
2029    }`}static async fromCalldata(t,r,n,i){const a=await KL(i);return new Jr(t,r,n,a)}}
2029class zc{constructor(t,r){te(this,"inner");te(this,"counter");this.inner=t,this.counter=r}getSize(){return this.isEmpty()?0:this.toBuffer().length}static getFields(t){return[t.inner,t.counter]}static fromFields(t){const r=Pt.asReader(t);return new zc(r.readObject(Jr),r.readU32())}toFields(){const t=Gr(...zc.getFields(this));if(t.length!==_L)throw new Error(`Invalid number of fields for CountedPublicCallRequest. Expected ${_L}, got ${t.length}`);return t}static fromBuffer(t){const r=rt.asReader(t);return new zc(r.readObject(Jr),r.readNumber())}toBuffer(){return ht(...zc.getFields(this))}static empty(){return new zc(Jr.empty(),0)}isEmpty(){return this.inner.isEmpty()&&this.counter==0}}function c2(e){return e.reduce((t,r,n)=>{if(!r.isEmpty()){if(t!==n)throw new Error("Non-empty items must be placed continuously from index 0.");return t+1}return t},0)}function u2(e,t,r=e.length){const n=c2(e),i=c2(t);if(n+i>r)throw new Error("Combined non-empty items exceeded the maximum allowed.");const a=[...e];return t.slice(0,i).forEach((s,o)=>a[o+n]=s),a}function Oye(e,t,r=!0){return[...e].sort((n,i)=>n.isEmpty()?1:i.isEmpty()?-1:r?t(n,i):t(i,n))}function Bye(e,t){return e.counter-t.counter}function Rye(e,t=!0){return Oye(e,Bye,t)}function jl(e){return e.every(t=>t.isEmpty())}class Oo{constructor(t,r,n,i,a,s,o,c,l,u,d,p,w,O,I,R,C,j,N,P,Z){te(this,"callContext");te(this,"argsHash");te(this,"returnsHash");te(this,"minRevertibleSideEffectCounter");te(this,"isFeePayer");te(this,"maxBlockNumber");te(this,"noteHashReadRequests");te(this,"nullifierReadRequests");te(this,"keyValidationRequestsAndGenerators");te(this,"noteHashes");te(this,"nullifiers");te(this,"privateCallRequests");te(this,"publicCallRequests");te(this,"publicTeardownCallRequest");te(this,"l2ToL1Msgs");te(this,"privateLogs");te(this,"contractClassLogsHashes");te(this,"startSideEffectCounter");te(this,"endSideEffectCounter");te(this,"historicalHeader");te(this,"txContext");this.callContext=t,this.argsHash=r,this.returnsHash=n,this.minRevertibleSideEffectCounter=i,this.isFeePayer=a,this.maxBlockNumber=s,this.noteHashReadRequests=o,this.nullifierReadRequests=c,this.keyValidationRequestsAndGenerators=l,this.noteHashes=u,this.nullifiers=d,this.privateCallRequests=p,this.publicCallRequests=w,this.publicTeardownCallRequest=O,this.l2ToL1Msgs=I,this.privateLogs=R,this.contractClassLogsHashes=C,this.startSideEffectCounter=j,this.endSideEffectCounter=N,this.historicalHeader=P,this.txContext=Z}static from(t){return new Oo(...Oo.getFields(t))}static fromBuffer(t){const r=rt.asReader(t);return new Oo(r.readObject(na),r.readObject(le),r.readObject(le),r.readObject(le),r.readBoolean(),r.readObject(Na),r.readArray(rk,os),r.readArray(nk,os),r.readArray(ik,Zh),r.readArray(XS,Cl),r.readArray(JS,Tl),r.readArray(QS,$h),r.readArray(ek,zc),r.readObject(Jr),r.readArray(tk,qs),r.readArray(ak,Pa),r.readArray(sk,Ml),r.readObject(le),r.readObject(le),r.readObject(Xr),r.readObject(an))}static fromFields(t){const r=Pt.asReader(t);return new Oo(r.readObject(na),r.readField(),r.readField(),r.readField(),r.readBoolean(),r.readObject(Na),r.readArray(rk,os),r.readArray(nk,os),r.readArray(ik,Zh),r.readArray(XS,Cl),r.readArray(JS,Tl),r.readArray(QS,$h),r.readArray(ek,zc),r.readObject(Jr),r.readArray(tk,qs),r.readArray(ak,Pa),r.readArray(sk,Ml),r.readField(),r.readField(),r.readObject(Xr),r.readObject(an))}static empty(){return new Oo(na.empty(),le.ZERO,le.ZERO,le.ZERO,!1,Na.empty(),Ar(rk,os.empty),Ar(nk,os.empty),Ar(ik,Zh.empty),Ar(XS,Cl.empty),Ar(JS,Tl.empty),Ar(QS,$h.empty),Ar(ek,zc.empty),Jr.empty(),Ar(tk,qs.empty),Ar(ak,Pa.empty),Ar(sk,Ml.empty),le.ZERO,le.ZERO,Xr.empty(),an.empty())}isEmpty(){return this.callContext.isEmpty()&&this.argsHash.isZero()&&this.returnsHash.isZero()&&this.minRevertibleSideEffectCounter.isZero()&&!this.isFeePayer&&this.maxBlockNumber.isEmpty()&&jl(this.noteHashReadRequests)&&jl(this.nullifierReadRequests)&&jl(this.keyValidationRequestsAndGenerators)&&jl(this.noteHashes)&&jl(this.nullifiers)&&jl(this.privateCallRequests)&&jl(this.publicCallRequests)&&this.publicTeardownCallRequest.isEmpty()&&jl(this.l2ToL1Msgs)&&jl(this.privateLogs)&&jl(this.contractClassLogsHashes)&&this.startSideEffectCounter.isZero()&&this.endSideEffectCounter.isZero()&&this.historicalHeader.isEmpty()&&this.txContext.isEmpty()}static getFields(t){return[t.callContext,t.argsHash,t.returnsHash,t.minRevertibleSideEffectCounter,t.isFeePayer,t.maxBlockNumber,t.noteHashReadRequests,t.nullifierReadRequests,t.keyValidationRequestsAndGenerators,t.noteHashes,t.nullifiers,t.privateCallRequests,t.publicCallRequests,t.publicTeardownCallRequest,t.l2ToL1Msgs,t.privateLogs,t.contractClassLogsHashes,t.startSideEffectCounter,t.endSideEffectCounter,t.historicalHeader,t.txContext]}toBuffer(){return ht(...Oo.getFields(this))}toFields(){const t=Gr(...Oo.getFields(this));if(t.length!==TL)throw new Error(`Invalid number of fields for PrivateCircuitPublicInputs. Expected ${TL}, got ${t.length}`);return t}toJSON(){return this.toBuffer()}static get schema(){return Bb(Oo)}}
2029const Pl=class Pl{constructor(t,r){te(this,"contractAddress");te(this,"fields");te(this,"unsiloedFirstField");if(this.contractAddress=t,this.fields=r,r.length!==Fh)throw new Error(`Invalid number of fields for ContractClassLog. Expected ${Fh}, got ${r.length}`)}toFields(){return[this.contractAddress.toField(),...this.fields]}equals(t){return this.contractAddress.equals(t.contractAddress)&&this.fields.length===t.fields.length&&this.fields.every((r,n)=>r.equals(t.fields[n]))}static fromFields(t){const r=Pt.asReader(t);return new Pl(r.readObject(nt),Array.from({length:Fh},()=>r.readField()))}isEmpty(){return this.fields.every(t=>t.isZero())}static empty(){return new Pl(nt.ZERO,new Array(Fh).fill(le.ZERO))}toBuffer(){return ht([this.contractAddress,this.fields])}static fromBuffer(t){const r=rt.asReader(t),n=r.readObject(nt),i=Array.from({length:Fh},()=>r.remainingBytes()==0?le.ZERO:le.fromBuffer(r));return new Pl(n,i)}clone(){return Pl.fromBuffer(this.toBuffer())}static async random(){const t=Array.from({length:Math.ceil(Fh/2)},()=>le.random());return new Pl(await nt.random(),t.concat(Array.from({length:Math.floor(Fh/2)},()=>le.ZERO)))}getEmittedLength(){return this.getEmittedFields().length}getEmittedFields(){const t=this.fields.findLastIndex(r=>!r.isZero());return this.fields.slice(0,t+1)}setUnsiloedFirstField(t){this.unsiloedFirstField=t}toUnsiloed(){return this.unsiloedFirstField?new Pl(this.contractAddress,[this.unsiloedFirstField].concat(this.fields.slice(1))):this}async silo(){const t=this.clone();return t.contractAddress.isZero()||(t.setUnsiloedFirstField(t.fields[0]),t.fields[0]=await W
2029S([t.contractAddress,t.fields[0]])),t}async hash(){return await WS(this.fields)}static get schema(){return K.object({contractAddress:nt.schema,fields:K.array(He.Fr)}).transform(({contractAddress:t,fields:r})=>Pl.fromFields([t.toField(),...r]))}[ct.inspect.custom](){return`ContractClassLog {
2030      fields: [${this.fields.map(t=>ct.inspect(t)).join(", ")}],
2031    }`}};te(Pl,"SIZE_IN_BYTES",le.SIZE_IN_BYTES*wL);let ha=Pl;class sp extends Xu{toJSON(){return this.toBuffer()}static get schema(){return Be.Buffer.transform(sp.fromBuffer)}static fromBuffer(t){const r=rt.asReader(t);return new sp(r.readVector(le))}static random(){const t=RS(10)+1,r=Array.from({length:t},()=>le.random());return new sp(r)}toString(){return Ur(this.toBuffer())}static fromString(t){return sp.fromBuffer(fn(t))}get length(){return this.items.length}equals(t){return this.items.every((r,n)=>r.equals(t.items[n]))}}class Bo extends sp{static get schema(){return He.Buffer.transform(Bo.fromBuffer)}static fromBuffer(t){const r=rt.asReader(t);return new Bo(r.readVector(le))}}class Si{constructor(t,r){te(this,"values");te(this,"hash");this.values=t,this.hash=r}getSize(){return this.values.length+1}static get schema(){return K.object({values:K.array(Be.Fr),hash:Be.Fr}).transform(Si.from)}static from(t){return new Si(...Si.getFields(t))}static getFields(t){return[t.values,t.hash]}static random(){return new Si([le.random(),le.random()],le.random())}toBuffer(){return ht(new Xu(this.values),this.hash)}static fromBuffer(t){const r=rt.asReader(t);return new Si(r.readVector(le),le.fromBuffer(r))}static async fromArgs(t){return new Si(t,await cbe(t))}static async fromCalldata(t){return new Si(t,await KL(t))}}class op{constructor(t,r,n){te(this,"note");te(this,"storageSlot");te(this,"noteTypeId");this.note=t,this.storageSlot=r,this.noteTypeId=n}static get schema(){return K.object({note:Bo.schema,storageSlot:Be.Fr,noteTypeId:Be.NoteSelector}).transform(op.from)}static from(t){return new op(t.note,t.storageSlot,t.noteTypeId)}static random(){return new op(Bo.random(),le.random(),Co.random())}}class s1{constructor(t,r){te(this,"log");te(this,"counter");this.log=t,this.counter=r}static get schema(){return K.object({log:ha.schema,counter:Be.Integer}).transform(s1.from)}static from(t){return new s1(t.log,t.counter)}isEmpty(){return this.log.isEmpty()&&!this.counter}}class Lc{constructor(t,r,n){te(this,"entrypoint");te(this,"firstNullifier");te(this,"publicFunctionCalldata");this.entrypoint=t,this.firstNullifier=r,this.publicFunctionCalldata=n}static get schema(){return K.object({entrypoint:of.schema,firstNullifier:Be.Fr,publicFunctionCalldata:K.array(Si.schema)}).transform(Lc.from)}static from(t){return new Lc(t.entrypoint,t.firstNullifier,t.publicFunctionCalldata)}static async random(t=1){return new Lc(await of.random(t),le.random(),[Si.random(),Si.random()])}getSimulationBlockNumber(){return this.entrypoint.publicInputs.historicalHeader.globalVariables.blockNumber.toNumber()}}class of{constructor(t,r,n,i,a,s,o,c,l,u){te(this,"acir");te(this,"vk");te(this,"partialWitness");te(this,"publicInputs");te(this,"noteHashLeafIndexMap");te(this,"newNotes");te(this,"noteHashNullifierCounterMap");te(this,"returnValues");te(this,"nestedExecutions");te(this,"contractClassLogs");this.acir=t,this.vk=r,this.partialWitness=n,this.publicInputs=i,this.noteHashLeafIndexMap=a,this.newNotes=s,this.noteHashNullifierCounterMap=o,this.returnValues=c,this.nestedExecutions=l,this.contractClassLogs=u}static get schema(){return K.object({acir:Be.Buffer,vk:Be.Buffer,partialWitness:Dx(K.coerce.number(),K.string()),publicInputs:Oo.schema,noteHashLeafIndexMap:Dx(Be.BigInt,Be.BigInt),newNotes:K.array(op.schema),noteHashNullifierCounterMap:Dx(K.coerce.number(),K.number()),returnValues:K.array(Be.Fr),nestedExecutions:K.array(K.lazy(()=>of.schema)),contractClassLogs:K.array(s1.schema)}).transform(of.from)}static from(t){return new of(t.acir,t.vk,t.partialWitness,t.publicInputs,t.noteHashLeafIndexMap,t.newNotes,t.noteHashNullifierCounterMap,t.returnValues,t.nestedExecutions,t.contractClassLogs)}static async random(t=1){return new of(wo(4),wo(4),new Map([[1,"one"]]),Oo.empty(),new Map([[1n,1n]]),[op.random()],new Map([[0,0]]),[le.random()],await cz(t,()=>of.random(0)),[new s1(await ha.random(),RS(10))])}}function xU(e){return[e.contractClassLogs,...e.nestedExecutions.flatMap(xU)].flat()}function _U(e){const t=xU(e.entrypoint);return Rye(t).map(r=>r.log)}
2031class lp{constructor(t,r){te(this,"request");te(this,"calldata");this.request=t,this.calldata=r}get functionSelector(){return Yr.fromField(this.calldata[0])}get args(){return this.calldata.slice(1)}static get schema(){return K.object({request:Jr.schema,calldata:K.array(Be.Fr)}).transform(lp.from)}static from(t){return new lp(t.request,t.calldata)}toBuffer(){return ht(this.request,new Xu(this.calldata))}static fromBuffer(t){const r=rt.asReader(t);return new lp(Jr.fromBuffer(r),r.readVector(le))}static empty(){return new lp(Jr.empty(),[])}isEmpty(){return this.request.isEmpty()&&this.calldata.length===0}[ct.inspect.custom](){return`PublicCallRequestWithCalldata {
2032      request: ${ct.inspect(this.request)}
2033      calldata: ${this.calldata}
2034    }`}}class Er{constructor(t){te(this,"hash");this.hash=t}static random(){return new Er(le.random())}static fromBuffer(t){const r=rt.asReader(t);return new this(r.readObject(le))}static fromString(t){return new Er(le.fromString(t))}static fromBigInt(t){return new Er(new le(t))}toBuffer(){return this.hash.toBuffer()}toString(){return this.hash.toString()}toBigInt(){return this.hash.toBigInt()}toJSON(){return this.toString()}equals(t){return this.hash.equals(t.hash)}static get schema(){return Be.BufferHex.transform(t=>new Er(le.fromBuffer(t)))}static zero(){return new Er(le.ZERO)}static get SIZE(){return le.SIZE_IN_BYTES}}var Nye=function(e){return e[e.OK=0]="OK",e[e.APP_LOGIC_REVERTED=1]="APP_LOGIC_REVERTED",e[e.TEARDOWN_REVERTED=2]="TEARDOWN_REVERTED",e[e.BOTH_REVERTED=3]="BOTH_REVERTED",e}({});function SU(e){return e===0||e===1||e===2||e===3}const pn=class pn{constructor(t){te(this,"code");this.code=t.valueOf()}getCode(){return this.code}equals(t){return this.code===t.code}isOK(){return this.equals(pn.OK)}getDescription(){switch(this.code){case 0:return"OK";case 1:return"Application logic reverted";case 2:return"Teardown reverted";case 3:return"Both reverted";default:return`Unknown RevertCode: ${this.code}`}}toJSON(){return this.code}static get schema(){return K.nativeEnum(Nye).transform(t=>new pn(t))}toHashPreimage(){const t=je.alloc(pn.PREIMAGE_SIZE_IN_BYTES-pn.PACKED_SIZE_IN_BYTES);return je.concat([t,this.toBuffer()])}toBuffer(){const t=je.alloc(pn.PACKED_SIZE_IN_BYTES);return t.writeUInt8(this.code,0),t}toField(){return new le(this.toBuffer())}getSerializedLength(){return this.toBuffer().length}static fromField(t){if(!SU(t.toNumber()))throw new Error(`Invalid RevertCode: ${t.toNumber()}`);return new pn(t.toNumber())}static fromFields(t){const r=Pt.asReader(t);return pn.fromField(r.readField())}static fromBuffer(t){const r=rt.asReader(t).readBytes(pn.PACKED_SIZE_IN_BYTES).readUInt8(0);if(!SU(r))throw new Error(`Invalid RevertCode: ${r}`);return new pn(r)}static random(){return new pn(Math.floor(Math.random()*pn.NUM_OPTIONS))}[ct.inspect.custom](){return`RevertCode<${this.code.toString()}>`}};te(pn,"OK",new pn(0)),te(pn,"APP_LOGIC_REVERTED",new pn(1)),te(pn,"TEARDOWN_REVERTED",new pn(2)),te(pn,"BOTH_REVERTED",new pn(3)),te(pn,"PREIMAGE_SIZE_IN_BYTES",32),te(pn,"PACKED_SIZE_IN_BYTES",1),te(pn,"NUM_OPTIONS",4);let Ro=pn;class cp extends ta{constructor(t){super(t)}static random(){return new cp(le.random().toBuffer())}static get schema(){return Be.BufferHex.transform(t=>new cp(t))}static zero(){return new cp(ta.ZERO.toBuffer())}static fromField(t){return new cp(t.toBuffer())}}var Fye=function(e){return e.DROPPED="dropped",e.PENDING="pending",e.SUCCESS="success",e.APP_LOGIC_REVERTED="app_logic_reverted",e.TEARDOWN_REVERTED="teardown_reverted",e.BOTH_REVERTED="both_reverted",e}({});class up{constructor(t,r,n,i,a,s){te(this,"txHash");te(this,"status");te(this,"error");te(this,"transactionFee");te(this,"blockHash");te(this,"blockNumber");this.txHash=t,this.status=r,this.error=n,this.transactionFee=i,this.blockHash=a,this.blockNumber=s}static empty(){return new up(Er.zero(),"dropped","")}static get schema(){return K.object({txHash:Er.schema,status:K.nativeEnum(Fye),error:K.string(),blockHash:cp.schema.optional(),blockNumber:K.number().int().nonnegative().optional(),transactionFee:Be.BigInt.optional()}).transform(up.from)}static from(t){return new up(t.txHash,t.status,t.error,t.transactionFee,t.blockHash,t.blockNumber)}static statusFromRevertCode(t){if(t.equals(Ro.OK))return"success";if(t.equals(Ro.APP_LOGIC_REVERTED))return"app_logic_reverted";if(t.equals(Ro.TEARDOWN_REVERTED))return"teardown_reverted";if(t.equals(Ro.BOTH_REVERTED))return"both_reverted";throw new Error(`Unknown revert code: ${t}`)}}class ls{constructor(t){te(this,"maxBlockNumber");this.maxBlockNumber=t}getSize(){return this.toBuffer().length}toBuffer(){return ht(this.maxBlockNumber)}toString(){return Ur(this.toBuffer())}static getFields(t){return[t.maxBlockNumber]}static fromFields(t){const r=Pt.asReader(t);return new ls(Na.fromFields(r))}toFields(){const t=Gr(...ls.getFields(this));if(t.length!==SL)throw new Error(`Invalid number of fields for RollupValidationRequests. Expected ${SL}, got ${t.length}`);return t}static fromBuffer(t){const r=rt.asReader(t);return new ls(r.readObject(Na))}static fromString(t){return ls.fromBuffer(fn(t))}static empty(){return new ls(Na.empty())}}class da{constructor(t,r,n,i,a,s){te(this,"noteHashes");te(this,"nullifiers");te(this,"l2ToL1Msgs");te(this,"privateLogs");te(this,"contractClassLogsHashes");te(this,"publicCallRequests");this.noteHashes=t,this.nullifiers=r,this.l2ToL1Msgs=n,this.privateLogs=i,this.contractClassLogsHashes=a,this.publicCallRequests=s}
2034getSize(){return Ls(this.noteHashes)+Ls(this.nullifiers)+Ls(this.l2ToL1Msgs)+Ls(this.privateLogs)+Ls(this.contractClassLogsHashes)+Ls(this.publicCallRequests)}static getFields(t){return[t.noteHashes,t.nullifiers,t.l2ToL1Msgs,t.privateLogs,t.contractClassLogsHashes,t.publicCallRequests]}static fromFields(t){const r=Pt.asReader(t);return new this(r.readFieldArray(Wu),r.readFieldArray(Ku),r.readArray(Gu,Vs),r.readArray(Yu,Hn),r.readArray(Y0,Al),r.readArray(lk,Jr))}static from(t){return new da(...da.getFields(t))}static fromBuffer(t){const r=rt.asReader(t);return new da(r.readArray(Wu,le),r.readArray(Ku,le),r.readArray(Gu,Vs),r.readArray(Yu,Hn),r.readArray(Y0,Al),r.readArray(lk,Jr))}toBuffer(){return ht(...da.getFields(this))}toFields(){const t=Gr(...da.getFields(this));if(t.length!==OL)throw new Error(`Invalid number of fields for PrivateToPublicAccumulatedData. Expected ${OL}, got ${t.length}`);return t}static empty(){return new da(Ar(Wu,le.zero),Ar(Ku,le.zero),Ar(Gu,Vs.empty),Ar(Yu,Hn.empty),Ar(Y0,Al.empty),Ar(lk,Jr.empty))}[ct.inspect.custom](){return`PrivateToPublicAccumulatedData {
2035      noteHashes: [${this.noteHashes.filter(t=>!t.isZero()).map(t=>ct.inspect(t)).join(", ")}],
2036      nullifiers: [${this.nullifiers.filter(t=>!t.isZero()).map(t=>ct.inspect(t)).join(", ")}],
2037      l2ToL1Msgs: [${this.l2ToL1Msgs.filter(t=>!t.isEmpty()).map(t=>ct.inspect(t)).join(", ")}],
2038      privateLogs: [${this.privateLogs.filter(t=>!t.isEmpty()).map(t=>ct.inspect(t)).join(", ")}],
2039      contractClassLogsHashes: [${this.contractClassLogsHashes.filter(t=>!t.isEmpty()).map(t=>ct.inspect(t)).join(", ")}],
2040      publicCallRequests: [${this.publicCallRequests.filter(t=>!t.isEmpty()).map(t=>ct.inspect(t)).join(", ")}],
2041    }`}}class fp{constructor(t,r,n,i,a,s,o){te(this,"constants");te(this,"rollupValidationRequests");te(this,"nonRevertibleAccumulatedData");te(this,"revertibleAccumulatedData");te(this,"publicTeardownCallRequest");te(this,"gasUsed");te(this,"feePayer");this.constants=t,this.rollupValidationRequests=r,this.nonRevertibleAccumulatedData=n,this.revertibleAccumulatedData=i,this.publicTeardownCallRequest=a,this.gasUsed=s,this.feePayer=o}toBuffer(){return ht(this.constants,this.rollupValidationRequests,this.nonRevertibleAccumulatedData,this.revertibleAccumulatedData,this.publicTeardownCallRequest,this.gasUsed,this.feePayer)}static getFields(t){return[t.constants,t.rollupValidationRequests,t.nonRevertibleAccumulatedData,t.revertibleAccumulatedData,t.publicTeardownCallRequest,t.gasUsed,t.feePayer]}static fromBuffer(t){const r=rt.asReader(t);return new fp(r.readObject(Bi),r.readObject(ls),r.readObject(da),r.readObject(da),r.readObject(Jr),r.readObject(cr),r.readObject(nt))}static empty(){return new fp(Bi.empty(),ls.empty(),da.empty(),da.empty(),Jr.empty(),cr.empty(),nt.ZERO)}static fromString(t){return fp.fromBuffer(fn(t))}toString(){return Ur(this.toBuffer())}toFields(){const t=Gr(...fp.getFields(this));if(t.length!==BL)throw new Error(`Invalid number of fields for PrivateToPublicKernelCircuitPublicInputs. Expected ${BL}, got ${t.length}`);return t}hash(){return yl(this.toFields(),Ba.PUBLIC_TX_HASH)}}class za{constructor(t,r,n,i,a){te(this,"noteHashes");te(this,"nullifiers");te(this,"l2ToL1Msgs");te(this,"privateLogs");te(this,"contractClassLogsHashes");this.noteHashes=t,this.nullifiers=r,this.l2ToL1Msgs=n,this.privateLogs=i,this.contractClassLogsHashes=a}getSize(){return Ls(this.noteHashes)+Ls(this.nullifiers)+Ls(this.l2ToL1Msgs)+Ls(this.privateLogs)+Ls(this.contractClassLogsHashes)}static getFields(t){return[t.noteHashes,t.nullifiers,t.l2ToL1Msgs,t.privateLogs,t.contractClassLogsHashes]}static from(t){return new za(...za.getFields(t))}static get schema(){return Bb(za)}toJSON(){return this.toBuffer()}toBuffer(){return ht(...za.getFields(this))}toString(){return Ur(this.toBuffer())}static fromBuffer(t){const r=rt.asReader(t);return new za(r.readArray(Wu,le),r.readArray(Ku,le),r.readArray(Gu,Vs),r.readArray(Yu,Hn),r.readArray(Y0,Al))}static fromString(t){return za.fromBuffer(fn(t))}static empty(){return new za(Ar(Wu,le.zero),Ar(Ku,le.zero),Ar(Gu,Vs.empty),Ar(Yu,Hn.empty),Ar(Y0,Al.empty))}toFields(){const t=Gr(...za.getFields(this));if(t.length!==jL)throw new Error(`Invalid number of fields for PrivateToRollupAccumulatedData. Expected ${jL}, got ${t.length}`);return t}[ct.inspect.custom](){return`PrivateToRollupAccumulatedData {
2042      noteHashes: [${this.noteHashes.filter(t=>!t.isZero()).map(t=>ct.inspect(t)).join(", ")}],
2043      nullifiers: [${this.nullifiers.filter(t=>!t.isZero()).map(t=>ct.inspect(t)).join(", ")}],
2044      l2ToL1Msgs: [${this.l2ToL1Msgs.filter(t=>!t.isEmpty()).map(t=>ct.inspect(t)).join(", ")}],
2045      privateLogs:  [${this.privateLogs.filter(t=>!t.isEmpty()).map(t=>ct.inspect(t)).join(", ")}]
2046      contractClassLogsHashes: : [${this.contractClassLogsHashes.filter(t=>!t.isEmpty()).map(t=>ct.inspect(t)).join(", ")}],
2047    }`}}class Hh{constructor(t,r,n,i,a){te(this,"constants");te(this,"rollupValidationRequests");te(this,"end");te(this,"gasUsed");te(this,"feePayer");this.constants=t,this.rollupValidationRequests=r,this.end=n,this.gasUsed=i,this.feePayer=a}getNonEmptyNullifiers(){return this.end.nullifiers.filter(t=>!t.isZero())}toBuffer(){return ht(this.constants,this.rollupValidationRequests,this.end,this.gasUsed,this.feePayer)}static fromBuffer(t){const r=rt.asReader(t);return new Hh(r.readObject(Bi),r.readObject(ls),r.readObject(za),r.readObject(cr),r.readObject(nt))}static empty(){return new Hh(Bi.empty(),ls.empty(),za.empty(),cr.empty(),nt.ZERO)}toString(){return Ur(this.toBuffer())}static fromString(t){return Hh.fromBuffer(fn(t))}toJSON(){return this.toBuffer()}static getFields(t){return[t.constants,t.rollupValidationRequests,t.end,t.gasUsed,t.feePayer]}static get schema(){return Bb(Hh)}toFields(){const t=Gr(...Hh.getFields(this));if(t.length!==RL)throw new Error(`Invalid number of fields for PrivateToRollupKernelCircuitPublicInputs. Expected ${RL}, got ${t.length}`);return t}hash(){return yl(this.toFields(),Ba.PRIVATE_TX_HASH)}}class f2{constructor(t,r,n){te(this,"nonRevertibleAccumulatedData");te(this,"revertibleAccumulatedData");te(this,"publicTeardownCallRequest");this.nonRevertibleAccumulatedData=t,this.revertibleAccumulatedData=r,this.publicTeardownCallRequest=n}getSize(){return this.nonRevertibleAccumulatedData.getSize()+this.revertibleAccumulatedData.getSize()+this.publicTeardownCallRequest.getSize()}get needsSetup(){return!this.nonRevertibleAccumulatedData.publicCallRequests[0].isEmpty()}get needsAppLogic(){return!this.revertibleAccumulatedData.publicCallRequests[0].isEmpty()}get needsTeardown(){return!this.publicTeardownCallRequest.isEmpty()}static fromBuffer(t){const r=rt.asReader(t);return new f2(r.readObject(da),r.readObject(da),r.readObject(Jr))}toBuffer(){return ht(this.nonRevertibleAccumulatedData,this.revertibleAccumulatedData,this.publicTeardownCallRequest)}static empty(){return new f2(da.empty(),da.empty(),Jr.empty())}}class hp{constructor(t){te(this,"end");this.end=t}static fromBuffer(t){const r=rt.asReader(t);return new hp(r.readObject(za))}getSize(){return this.end.getSize()}toBuffer(){return ht(this.end)}static empty(){return new hp(za.empty())}}class cs{constructor(t,r,n,i,a,s){te(this,"constants");te(this,"rollupValidationRequests");te(this,"gasUsed");te(this,"feePayer");te(this,"forPublic");te(this,"forRollup");if(this.constants=t,this.rollupValidationRequests=r,this.gasUsed=n,this.feePayer=i,this.forPublic=a,this.forRollup=s,!a&&!s)throw new Error("Missing partial public inputs for private tail circuit.");
2047if(a&&s)throw new Error("Cannot create PrivateKernelTailCircuitPublicInputs that is for both public kernel circuit and rollup circuit.")}static get schema(){return Bb(cs)}toJSON(){return this.toBuffer()}getSize(){var t,r;return(((t=this.forPublic)==null?void 0:t.getSize())??0)+(((r=this.forRollup)==null?void 0:r.getSize())??0)+this.constants.getSize()+this.rollupValidationRequests.getSize()+this.feePayer.size}toPrivateToPublicKernelCircuitPublicInputs(){if(!this.forPublic)throw new Error("Private tail public inputs is not for public circuit.");return new fp(this.constants,this.rollupValidationRequests,this.forPublic.nonRevertibleAccumulatedData,this.forPublic.revertibleAccumulatedData,this.forPublic.publicTeardownCallRequest,this.gasUsed,this.feePayer)}toPrivateToRollupKernelCircuitPublicInputs(){if(!this.forRollup)throw new Error("Private tail public inputs is not for rollup circuit.");const t=new Bi(this.constants.historicalHeader,this.constants.txContext,this.constants.vkTreeRoot,this.constants.protocolContractTreeRoot);return new Hh(t,this.rollupValidationRequests,this.forRollup.end,this.gasUsed,this.feePayer)}numberOfPublicCallRequests(){return this.numberOfNonRevertiblePublicCallRequests()+this.numberOfRevertiblePublicCallRequests()+(this.hasTeardownPublicCallRequest()?1:0)}numberOfNonRevertiblePublicCallRequests(){return this.forPublic?c2(this.forPublic.nonRevertibleAccumulatedData.publicCallRequests):0}numberOfRevertiblePublicCallRequests(){return this.forPublic?c2(this.forPublic.revertibleAccumulatedData.publicCallRequests):0}hasTeardownPublicCallRequest(){return this.forPublic?!this.forPublic.publicTeardownCallRequest.isEmpty():!1}getNonRevertiblePublicCallRequests(){return this.forPublic?this.forPublic.nonRevertibleAccumulatedData.publicCallRequests.filter(t=>!t.isEmpty()):[]}getRevertiblePublicCallRequests(){return this.forPublic?this.forPublic.revertibleAccumulatedData.publicCallRequests.filter(t=>!t.isEmpty()):[]}getTeardownPublicCallRequest(){var r;const t=(r=this.forPublic)==null?void 0:r.publicTeardownCallRequest;return t!=null&&t.isEmpty()?void 0:t}getNonEmptyNoteHashes(){return(this.forPublic?u2(this.forPublic.nonRevertibleAccumulatedData.noteHashes,this.forPublic.revertibleAccumulatedData.noteHashes):this.forRollup.end.noteHashes).filter(t=>!t.isZero())}getNonEmptyNullifiers(){return(this.forPublic?u2(this.forPublic.nonRevertibleAccumulatedData.nullifiers,this.forPublic.revertibleAccumulatedData.nullifiers):this.forRollup.end.nullifiers).filter(t=>!t.isZero())}getNonEmptyPrivateLogs(){return(this.forPublic?u2(this.forPublic.nonRevertibleAccumulatedData.privateLogs,this.forPublic.revertibleAccumulatedData.privateLogs):this.forRollup.end.privateLogs).filter(t=>!t.isEmpty())}getNonEmptyContractClassLogsHashes(){return(this.forPublic?u2(this.forPublic.nonRevertibleAccumulatedData.contractClassLogsHashes,this.forPublic.revertibleAccumulatedData.contractClassLogsHashes):this.forRollup.end.contractClassLogsHashes).filter(t=>!t.isEmpty())}getEmittedContractClassLogsLength(){return this.getNonEmptyContractClassLogsHashes().reduce((t,r)=>t+r.logHash.length,0)}getEmittedPrivateLogsLength(){return this.getNonEmptyPrivateLogs().reduce((t,r)=>t+r.getEmittedLength(),0)}static fromBuffer(t){const r=rt.asReader(t),n=r.readBoolean();return new cs(r.readObject(Bi),r.readObject(ls),r.readObject(cr),r.readObject(nt),n?r.readObject(f2):void 0,n?void 0:r.readObject(hp))}toBuffer(){const t=!!this.forPublic;return ht(t,this.constants,this.rollupValidationRequests,this.gasUsed,this.feePayer,t?this.forPublic.toBuffer():this.forRollup.toBuffer())}static empty(){return new cs(Bi.empty(),ls.empty(),cr.empty(),nt.ZERO,void 0,hp.empty())}static emptyWithNullifier(){const t=za.empty();return t.nullifiers[0]=le.random(),new cs(Bi.empty(),ls.empty(),cr.empty(),nt.ZERO,void 0,new hp(t))}}class kU{}te(kU,"p2pTopic");function Pye(e){return"/aztec/"+e+"/0.1.0"}var zye=function(e){return e.tx="tx",e.block_proposal="block_proposal",e.block_attestation="block_attestation",e}({});const Lye=172052;class La{constructor(t){te(this,"clientIvcProofBuffer");this.clientIvcProofBuffer=t}isEmpty(){return this.clientIvcProofBuffer.length===0}
2047static empty(){return new La(je.from(""))}static fake(t=Math.floor(Math.random()*255)){return new La(je.alloc(1,t))}static random(){return new La(je.from(wo(Lye)))}static get schema(){return Bb(La)}toJSON(){return this.toBuffer()}static fromBuffer(t){const r=rt.asReader(t);return new La(r.readBuffer())}toBuffer(){return ht(this.clientIvcProofBuffer.length,this.clientIvcProofBuffer)}}const zl=class zl extends kU{constructor(r,n,i,a){super();qt(this,ad);te(this,"data");te(this,"clientIvcProof");te(this,"contractClassLogs");te(this,"publicFunctionCalldata");te(this,"txHash");te(this,"calldataMap");this.data=r,this.clientIvcProof=n,this.contractClassLogs=i,this.publicFunctionCalldata=a}async p2pMessageIdentifier(){return new ta((await this.getTxHash()).toBuffer())}hasPublicCalls(){return this.numberOfPublicCalls()>0}numberOfPublicCalls(){return this.data.numberOfPublicCallRequests()}getNonRevertiblePublicCallRequestsWithCalldata(){return this.data.getNonRevertiblePublicCallRequests().map(r=>Vt(this,ad,q1).call(this,r))}getRevertiblePublicCallRequestsWithCalldata(){return this.data.getRevertiblePublicCallRequests().map(r=>Vt(this,ad,q1).call(this,r))}getTeardownPublicCallRequestWithCalldata(){const r=this.data.getTeardownPublicCallRequest();return r?Vt(this,ad,q1).call(this,r):void 0}getPublicCallRequestsWithCalldata(){const r=this.data.getTeardownPublicCallRequest();return[...this.data.getNonRevertiblePublicCallRequests(),...this.data.getRevertiblePublicCallRequests(),...r?[r]:[]].map(n=>Vt(this,ad,q1).call(this,n))}getTotalPublicCalldataCount(){return this.publicFunctionCalldata.reduce((r,n)=>r+n.values.length,0)}getGasSettings(){return this.data.constants.txContext.gasSettings}static fromBuffer(r){const n=rt.asReader(r);return new zl(n.readObject(cs),n.readObject(La),n.readVectorUint8Prefix(ha),n.readVectorUint8Prefix(Si))}toBuffer(){return ht([this.data,this.clientIvcProof,bl(this.contractClassLogs,1),bl(this.publicFunctionCalldata,1)])}static get schema(){return K.object({data:cs.schema,clientIvcProof:La.schema,contractClassLogs:K.array(ha.schema),publicFunctionCalldata:K.array(Si.schema)}).transform(zl.from)}static from(r){return new zl(r.data,r.clientIvcProof,r.contractClassLogs,r.publicFunctionCalldata)}async getPublicLogs(r){return r.getPublicLogs({txHash:await this.getTxHash()})}async getSplitContractClassLogs(r,n=!1){if(!this.data.forPublic)return[];const i=r?this.data.forPublic.revertibleAccumulatedData.contractClassLogsHashes.filter(a=>!a.isEmpty()):this.data.forPublic.nonRevertibleAccumulatedData.contractClassLogsHashes.filter(a=>!a.isEmpty());return await this.filterContractClassLogs(i,n)}async filterContractClassLogs(r,n=!1){const i=[];for(const a of this.contractClassLogs){const s=await a.hash();r.find(o=>o.value.equals(s)&&o.contractAddress.equals(a.contractAddress))&&i.push(n?await a.silo():a)}return i}async getTxHash(r=!1){if(!this.txHash||r){const n=this.data.forPublic?await this.data.toPrivateToPublicKernelCircuitPublicInputs().hash():await this.data.toPrivateToRollupKernelCircuitPublicInputs().hash();this.txHash=new Er(n)}return this.txHash}setTxHash(r){this.txHash=r}getCalldataMap(){if(!this.calldataMap){const r=new Map;this.publicFunctionCalldata.forEach(n=>r.set(n.hash.toString(),n.values)),this.calldataMap=r}return this.calldataMap}async getStats(){var r;return{txHash:(await this.getTxHash()).toString(),noteHashCount:this.data.getNonEmptyNoteHashes().length,nullifierCount:this.data.getNonEmptyNullifiers().length,privateLogCount:this.data.getNonEmptyPrivateLogs().length,classRegisteredCount:this.data.getNonEmptyContractClassLogsHashes().length,contractClassLogSize:this.data.getEmittedContractClassLogsLength(),proofSize:this.clientIvcProof.clientIvcProofBuffer.length,size:this.toBuffer().length,feePaymentMethod:(r=this.data.forPublic)!=null&&r.needsSetup?"fpc":"fee_juice"}}getSize(){return this.data.getSize()+this.clientIvcProof.clientIvcProofBuffer.length+Ls(this.contractClassLogs)+this.publicFunctionCalldata.reduce((r,n)=>r+n.getSize(),0)}getEstimatedPrivateTxEffectsSize(){return this.data.getNonEmptyNoteHashes().length*le.SIZE_IN_BYTES+this.data.getNonEmptyNullifiers().length*le.SIZE_IN_BYTES+this.data.getEmittedPrivateLogsLength()*le.SIZE_IN_BYTES+this.data.getEmittedContractClassLogsLength()*le.SIZE_IN_BYTES}static async getHash(r){return Dye(r)?r.hash:await r.getTxHash()}static async getHashes(r){return await Promise.all(r.map(zl.getHash))}static clone(r){const n=cs.fromBuffer(r.data.toBuffer()),i=La.fromBuffer(r.clientIvcProof.toBuffer()),a=r.contractClassLogs.map(c=>ha.fromBuffer(c.toBuffer())),s=r.publicFunctionCalldata.map(c=>Si.fromBuffer(c.toBuffer())),o=new zl(n,i,a,s);
2047return r.txHash&&o.setTxHash(Er.fromBuffer(r.txHash.toBuffer())),o}static async random(r=!1){return new zl(cs.emptyWithNullifier(),r?La.random():La.empty(),[await ha.random()],[Si.random()])}async filterRevertedLogs(){this.contractClassLogs=await this.getSplitContractClassLogs(!1)}};ad=new WeakSet,q1=function(r){const n=this.getCalldataMap().get(r.calldataHash.toString())??[];return new lp(r,n)},te(zl,"p2pTopic"),zl.p2pTopic=Pye(zye.tx);let No=zl;function Dye(e){return e.hash!==void 0}class Fo{constructor(t,r,n,i,a){te(this,"historicalHeader");te(this,"txContext");te(this,"vkTreeRoot");te(this,"protocolContractTreeRoot");te(this,"globalVariables");this.historicalHeader=t,this.txContext=r,this.vkTreeRoot=n,this.protocolContractTreeRoot=i,this.globalVariables=a}static combine(t,r){return new Fo(t.historicalHeader,t.txContext,t.vkTreeRoot,t.protocolContractTreeRoot,r)}static get schema(){return K.object({historicalHeader:Xr.schema,txContext:an.schema,vkTreeRoot:He.Fr,protocolContractTreeRoot:He.Fr,globalVariables:si.schema}).transform(Fo.from).or(Ds(Fo))}toBuffer(){return ht(this.historicalHeader,this.txContext,this.vkTreeRoot,this.protocolContractTreeRoot,this.globalVariables)}clone(){return Fo.fromBuffer(this.toBuffer())}getSize(){return this.historicalHeader.getSize()+this.txContext.getSize()+this.vkTreeRoot.size+this.protocolContractTreeRoot.size+this.globalVariables.getSize()}static from({historicalHeader:t,txContext:r,vkTreeRoot:n,protocolContractTreeRoot:i,globalVariables:a}){return new Fo(t,r,n,i,a)}static fromBuffer(t){const r=rt.asReader(t);return new Fo(r.readObject(Xr),r.readObject(an),le.fromBuffer(r),le.fromBuffer(r),r.readObject(si))}static fromFields(t){const r=Pt.asReader(t);return new Fo(r.readObject(Xr),r.readObject(an),r.readField(),r.readField(),r.readObject(si))}static empty(){return new Fo(Xr.empty(),an.empty(),le.ZERO,le.ZERO,si.empty())}}const Ws=class Ws{constructor(t,r){te(this,"leafSlot");te(this,"value");this.leafSlot=t,this.value=r}static get schema(){return K.object({leafSlot:He.Fr,value:He.Fr}).transform(Ws.from)}static from(t){return new Ws(...Ws.getFields(t))}static getFields(t){return[t.leafSlot,t.value]}static fromFields(t){const r=Pt.asReader(t);return new Ws(r.readField(),r.readField())}static fromBuffer(t){const r=rt.asReader(t);return new Ws(le.fromBuffer(r),le.fromBuffer(r))}toBuffer(){return ht(...Ws.getFields(this))}static fromString(t){return Ws.fromBuffer(fn(t))}toString(){return Ur(this.toBuffer())}static empty(){return new Ws(le.ZERO,le.ZERO)}static random(){return new Ws(le.random(),le.random())}static isEmpty(t){return t.isEmpty()}isEmpty(){return this.leafSlot.isZero()&&this.value.isZero()}equals(t){return this.leafSlot.equals(t.leafSlot)&&this.value.equals(t.value)}};te(Ws,"SIZE_IN_BYTES",le.SIZE_IN_BYTES*2);let dp=Ws;const Ll=class Ll{constructor(t,r){te(this,"contractAddress");te(this,"log");this.contractAddress=t,this.log=r}toFields(){return Gr(...Ll.getFields(this))}static getFields(t){return[t.contractAddress,t.log]}static fromFields(t){const r=Pt.asReader(t);return new Ll(r.readObject(nt),r.readFieldArray(Wx))}isEmpty(){return this.contractAddress.isZero()&&this.log.every(t=>t.isZero())}static empty(){return new Ll(nt.ZERO,Ar(Wx,le.zero))}toBuffer(){return ht(...Ll.getFields(this))}static fromBuffer(t){const r=rt.asReader(t);return new Ll(r.readObject(nt),r.readArray(Wx,le))}static async random(){return new Ll(await nt.random(),Ar(Wx,le.random))}getEmittedLength(){return this.getEmittedFields().length}getEmittedFields(){const t=this.toFields(),r=t.findLastIndex(n=>!n.isZero());return t.slice(0,r+1)}equals(t){return this.contractAddress.equals(t.contractAddress)&&this.log.reduce((r,n,i)=>r&&n.equals(t.log[i]),!0)}toHumanReadable(){return`PublicLog: (contractAddress: ${this.contractAddress} log: ${this.log})`}static get schema(){return K.object({contractAddress:nt.schema,log:K.array(He.Fr)}).transform(({contractAddress:t,log:r})=>Ll.fromFields([t.toField(),...r]))}[ct.inspect.custom](){return`PublicLog {
2048      contractAddress: ${ct.inspect(this.contractAddress)},
2049      log: [${this.log.map(t=>ct.inspect(t)).join(", ")}],
2050    }`}};te(Ll,"SIZE_IN_BYTES",le.SIZE_IN_BYTES*oL);let ia=Ll;const Vk=0x74785f7374617274n,o1=Vk.toString(16).length/2,h2=o1+7;class Ri{constructor(t,r,n,i,a,s,o,c,l,u){te(this,"revertCode");te(this,"txHash");te(this,"transactionFee");te(this,"noteHashes");te(this,"nullifiers");te(this,"l2ToL1Msgs");te(this,"publicDataWrites");te(this,"privateLogs");te(this,"publicLogs");te(this,"contractClassLogs");if(this.revertCode=t,this.txHash=r,this.transactionFee=n,this.noteHashes=i,this.nullifiers=a,this.l2ToL1Msgs=s,this.publicDataWrites=o,this.privateLogs=c,this.publicLogs=l,this.contractClassLogs=u,i.length>Wu)throw new Error(`Too many note hashes: ${i.length}, max: ${Wu}`);if(i.forEach(d=>{if(d.isZero())throw new Error("Note hash is zero")}),a.length>Ku)throw new Error(`Too many nullifiers: ${a.length}, max: ${Ku}`);
2050if(a.forEach(d=>{if(d.isZero())throw new Error("Nullifier is zero")}),s.length>Gu)throw new Error(`Too many L2 to L1 messages: ${s.length}, max: ${Gu}`);if(s.forEach(d=>{if(d.isZero())throw new Error("L2 to L1 message is zero")}),o.length>ck)throw new Error(`Too many public data writes: ${o.length}, max: ${ck}`);if(o.forEach(d=>{if(d.isEmpty())throw new Error("Public data write is empty")}),c.length>Yu)throw new Error(`Too many private logs: ${c.length}, max: ${Yu}`);c.forEach(d=>{if(d.isEmpty())throw new Error("Private log is empty")})}toBuffer(){return ht([this.revertCode,this.txHash,this.transactionFee,bl(this.noteHashes,1),bl(this.nullifiers,1),bl(this.l2ToL1Msgs,1),bl(this.publicDataWrites,1),bl(this.privateLogs,1),bl(this.publicLogs,1),bl(this.contractClassLogs,1)])}equals(t){return this.revertCode.equals(t.revertCode)&&this.txHash.equals(t.txHash)&&this.transactionFee.equals(t.transactionFee)&&this.noteHashes.length===t.noteHashes.length&&this.noteHashes.every((r,n)=>r.equals(t.noteHashes[n]))&&this.nullifiers.length===t.nullifiers.length&&this.nullifiers.every((r,n)=>r.equals(t.nullifiers[n]))&&this.l2ToL1Msgs.length===t.l2ToL1Msgs.length&&this.l2ToL1Msgs.every((r,n)=>r.equals(t.l2ToL1Msgs[n]))&&this.publicDataWrites.length===t.publicDataWrites.length&&this.publicDataWrites.every((r,n)=>r.equals(t.publicDataWrites[n]))&&this.privateLogs.length===t.privateLogs.length&&this.privateLogs.every((r,n)=>r.equals(t.privateLogs[n]))&&this.publicLogs.length===t.publicLogs.length&&this.publicLogs.every((r,n)=>r.equals(t.publicLogs[n]))&&this.contractClassLogs.length===t.contractClassLogs.length&&this.contractClassLogs.every((r,n)=>r.equals(t.contractClassLogs[n]))}getDASize(){return this.toBlobFields().length*le.SIZE_IN_BYTES}static fromBuffer(t){const r=rt.asReader(t);return new Ri(Ro.fromBuffer(r),Er.fromBuffer(r),le.fromBuffer(r),r.readVectorUint8Prefix(le),r.readVectorUint8Prefix(le),r.readVectorUint8Prefix(le),r.readVectorUint8Prefix(dp),r.readVectorUint8Prefix(Hn),r.readVectorUint8Prefix(ia),r.readVectorUint8Prefix(ha))}txOutHash(){const{l2ToL1Msgs:t}=this;if(t.length==0)return je.alloc(32);const r=t.length==1?1:Math.ceil(Math.log2(t.length));let n=Kpe(t.map(a=>a.toBuffer()),je.alloc(32),2**r),i=[];for(let a=0;a<r;a++){for(let s=0;s<n.length;s+=2)i[s/2]=Vz(je.concat([n[s],n[s+1]]));n=i,i=[]}return n[0]}static async random(t=3,r=1){return new Ri(Ro.random(),Er.random(),new le(Math.floor(Math.random()*1e5)),Ar(Wu,le.random),Ar(Ku,le.random),Ar(Gu,le.random),Ar(ck,()=>new dp(le.random(),le.random())),Ar(Yu,()=>new Hn(Ar(Nh,le.random))),await nL(t*r,async()=>await ia.random()),await nL(Y0,ha.random))}static empty(){return new Ri(Ro.OK,Er.zero(),le.ZERO,[],[],[],[],[],[],[])}isEmpty(){return this.nullifiers.length===0}toString(){return Ur(this.toBuffer())}toPrefix(t,r){const n=je.alloc(4);return n.writeUint8(t),n.writeUInt16BE(r,2),new le(n)}static fromPrefix(t){const r=t.toBuffer().subarray(-4);return{type:r[0],length:new le(r.subarray(-2)).toNumber()}}encodeFirstField(t,r){const n=je.alloc(2);return n.writeUInt16BE(t,0),new le(je.concat([Ca(Vk,o1),je.alloc(1),n,je.alloc(1),je.from([uk]),je.alloc(1),r.toBuffer()]))}static decodeFirstField(t){const r=t.toBuffer().subarray(-h2);return{length:new le(r.subarray(o1+1,o1+3)).toNumber(),revertCode:r[r.length-1]}}static isFirstField(t){const r=t.toBuffer();if(!r.subarray(0,t.size-h2).equals(je.alloc(t.size-h2)))return!1;const n=r.subarray(-h2);return!(!new le(n.subarray(0,o1)).equals(new le(Vk))||n[n.length-3]!==uk||n[n.length-1]>4)}toBlobFields(){if(this.isEmpty())return[];const t=[];if(t.push(le.ZERO),t.push(this.txHash.hash),t.push(new le(je.concat([je.from([Qge]),je.alloc(1),this.transactionFee.toBuffer().subarray(3)]))),this.noteHashes.length&&(t.push(this.toPrefix(PL,this.noteHashes.length)),t.push(...this.noteHashes)),this.nullifiers.length&&(t.push(this.toPrefix(zL,this.nullifiers.length)),t.push(...this.nullifiers)),this.l2ToL1Msgs.length&&(t.push(this.toPrefix(LL,this.l2ToL1Msgs.length)),t.push(...this.l2ToL1Msgs)),this.publicDataWrites.length&&(t.push(this.toPrefix(DL,this.publicDataWrites.length*2)),t.push(...this.publicDataWrites.map(r=>[r.leafSlot,r.value]).flat())),this.privateLogs.length){const r=this.privateLogs.reduce((n,i)=>n+(i.getEmittedLength()==0?0:i.getEmittedLength()+1),0);t.push(this.toPrefix(UL,r)),t.push(...this.privateLogs.flatMap(n=>[new le(n.getEmittedLength()),...n.getEmittedFields()]))}if(this.publicLogs.length){const r=this.publicLogs.reduce((n,i)=>n+(i.getEmittedLength()==0?0:i.getEmittedLength()+1),0);t.push(this.toPrefix(qL,r)),t.push(...this.publicLogs.flatMap(n=>[new le(n.getEmittedLength()),...n.getEmittedFields()]))}if(this.contractClassLogs.length){const r=this.contractClassLogs.reduce((n,i)=>n+(i.getEmittedLength()==0?0:i.getEmittedLength()+2),0);t.push(this.toPrefix(VL,r)),t.push(...this.contractClassLogs.flatMap(n=>[new le(n.getEmittedLength()),n.contractAddress.toField(),...n.getEmittedFields()]))}return t[0]=this.encodeFirstField(t.length,this.revertCode),t}static fromBlobFields(t){const r=l=>{if(l.length)throw new Error("Invalid fields given to TxEffect.fromBlobFields(): Attempted to assign property twice.")},n=this.empty();if(!(t instanceof Pt)&&!t.length)return n;const i=Pt.asReader(t),a=i.readField();if(!this.isFirstField(a))throw new Error("Invalid fields given to TxEffect.fromBlobFields(): First field invali
2050d.");const{length:s,revertCode:o}=this.decodeFirstField(a);n.revertCode=Ro.fromField(new le(o)),n.txHash=new Er(i.readField());const c=i.readField();for(n.transactionFee=le.fromBuffer(je.concat([je.alloc(3),c.toBuffer().subarray(3)]));!i.isFinished();){const{type:l,length:u}=this.fromPrefix(i.readField());switch(l){case PL:r(n.noteHashes),n.noteHashes=i.readFieldArray(u);break;case zL:r(n.nullifiers),n.nullifiers=i.readFieldArray(u);break;case LL:r(n.l2ToL1Msgs),n.l2ToL1Msgs=i.readFieldArray(u);break;case DL:{r(n.publicDataWrites);const d=i.readFieldArray(u);for(let p=0;p<u;p+=2)n.publicDataWrites.push(new dp(d[p],d[p+1]));break}case UL:{r(n.privateLogs);const d=i.readFieldArray(u);let p=0;for(;p<u;){const w=d[p++].toNumber(),O=d.slice(p,p+=w);n.privateLogs.push(Hn.fromFields(O.concat(new Array(Nh-w).fill(le.ZERO))))}break}case qL:{r(n.publicLogs);const d=i.readFieldArray(u);let p=0;for(;p<u;){const w=d[p++].toNumber(),O=d.slice(p,p+=w);n.publicLogs.push(ia.fromFields(O.concat(new Array(oL-w).fill(le.ZERO))))}break}case VL:{r(n.contractClassLogs);const d=i.readFieldArray(u);let p=0;for(;p<u;){const w=d[p++].toNumber(),O=d.slice(p,p+=w+1);n.contractClassLogs.push(ha.fromFields(O.concat(new Array(wL-w).fill(le.ZERO))))}break}case uk:default:throw new Error("Too many fields to decode given to TxEffect.fromBlobFields()")}}return n}static from(t){return new Ri(t.revertCode,t.txHash,t.transactionFee,t.noteHashes,t.nullifiers,t.l2ToL1Msgs,t.publicDataWrites,t.privateLogs,t.publicLogs,t.contractClassLogs)}static get schema(){return K.object({revertCode:Ro.schema,txHash:Er.schema,transactionFee:He.Fr,noteHashes:K.array(He.Fr),nullifiers:K.array(He.Fr),l2ToL1Msgs:K.array(He.Fr),publicDataWrites:K.array(dp.schema),privateLogs:K.array(Hn.schema),publicLogs:K.array(ia.schema),contractClassLogs:K.array(ha.schema)}).transform(Ri.from)}[ct.inspect.custom](){return`TxEffect {
2051      revertCode: ${this.revertCode},
2052      txHash: ${this.txHash},
2053      transactionFee: ${this.transactionFee},
2054      note hashes: [${this.noteHashes.map(t=>t.toString()).join(", ")}],
2055      nullifiers: [${this.nullifiers.map(t=>t.toString()).join(", ")}],
2056      l2ToL1Msgs: [${this.l2ToL1Msgs.map(t=>t.toString()).join(", ")}],
2057      publicDataWrites: [${this.publicDataWrites.map(t=>t.toString()).join(", ")}],
2058      privateLogs: [${this.privateLogs.map(t=>t.toString()).join(", ")}],
2059      publicLogs: [${this.publicLogs.map(t=>t.toString()).join(", ")}],
2060      contractClassLogs: [${this.contractClassLogs.map(t=>t.toString()).join(", ")}],
2061     }`}static fromString(t){return Ri.fromBuffer(fn(t))}}class l1{constructor(t,r,n){te(this,"privateExecutionResult");te(this,"publicInputs");te(this,"clientIvcProof");this.privateExecutionResult=t,this.publicInputs=r,this.clientIvcProof=n}toTx(){const t=_U(this.privateExecutionResult);return new No(this.publicInputs,this.clientIvcProof,t,this.privateExecutionResult.publicFunctionCalldata)}static get schema(){return K.object({privateExecutionResult:Lc.schema,publicInputs:cs.schema,clientIvcProof:La.schema}).transform(l1.from)}static from(t){return new l1(t.privateExecutionResult,t.publicInputs,t.clientIvcProof)}static async random(){return new l1(await Lc.random(),cs.empty(),La.empty())}}const Uye=K.object({functionName:K.string(),gateCount:K.number().optional(),bytecode:US,witness:Dx(K.number(),K.string())});class d2{constructor(t){te(this,"executionSteps");this.executionSteps=t}static get schema(){return K.object({executionSteps:K.array(Uye)}).transform(({executionSteps:t})=>new d2(t))}static random(){return new d2([{functionName:"random",bytecode:je.from("random"),witness:new Map([[1,"random"]])}])}}var EU=1/0,qye=9007199254740991,Vye=17976931348623157e292,MU=NaN,Zk=4294967295,Zye="[object Symbol]",$ye=/^\s+|\s+$/g,Hye=/^[-+]0x[0-9a-f]+$/i,Wye=/^0b[01]+$/i,Kye=/^0o[0-7]+$/i,Gye=parseInt;function Yye(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var Xye=Object.prototype,Jye=Xye.toString,Qye=Math.min;function AU(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function eve(e){return!!e&&typeof e=="object"}function tve(e){return typeof e=="symbol"||eve(e)&&Jye.call(e)==Zye}function rve(e){if(!e)return e===0?e:0;if(e=ive(e),e===EU||e===-EU){var t=e<0?-1:1;return t*Vye}return e===e?e:0}function nve(e){var t=rve(e),r=t%1;return t===t?r?t-r:t:0}function ive(e){if(typeof e=="number")return e;if(tve(e))return MU;if(AU(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=AU(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace($ye,"");var r=Wye.test(e);return r||Kye.test(e)?Gye(e.slice(2),r?2:8):Hye.test(e)?MU:+e}function ave(e){return e}function sve(e,t){if(e=nve(e),e<1||e>qye)return[];var r=Zk,n=Qye(e,Zk);t=typeof t=="function"?t:ave,e-=Zk;for(var i=Yye(n,t);++r<e;)t(r);return i}var ove=sve;
2061const CU=Nr(ove),lve=K.object({filePath:K.string(),line:K.number().int().nonnegative(),column:K.number().int().nonnegative(),fileSource:K.string(),locationText:K.string()}),cve=K.union([K.array(lve),K.array(K.string())]);function uve(e){return typeof e[0]=="string"}class c1 extends Error{constructor(r,n,i=[],a,s){super(r,s);te(this,"originalMessage");te(this,"functionErrorStack");te(this,"revertData");te(this,"noirErrorStack");te(this,"aztecContext");this.originalMessage=r,this.functionErrorStack=n,this.revertData=i,this.noirErrorStack=a,this.aztecContext="";const o=()=>this.getMessage(),c=()=>this.getStack();Object.defineProperties(this,{message:{configurable:!1,enumerable:!0,get(){return o()}},stack:{configurable:!1,enumerable:!0,get(){return c()},set(l){}}})}getMessage(){return this.noirErrorStack&&!uve(this.noirErrorStack)&&this.noirErrorStack.length?`${this.originalMessage} '${this.noirErrorStack[this.noirErrorStack.length-1].locationText}'${this.aztecContext}`:this.originalMessage}getOriginalMessage(){return this.originalMessage}setOriginalMessage(r){this.originalMessage=r}enrichWithContractName(r,n){this.functionErrorStack.forEach(i=>{i.contractAddress.equals(r)&&(i.contractName=n)})}enrichWithFunctionName(r,n,i){this.functionErrorStack.forEach(a=>{a.contractAddress.equals(r)&&a.functionSelector&&a.functionSelector.equals(n)&&(a.functionName=i)})}getStack(){const r=this.getCallStack(),n=this.getNoirCallStack(),i=[...r.map(a=>{var s;return`at ${a.contractName??a.contractAddress.toString()}.${a.functionName??((s=a.functionSelector)==null?void 0:s.toString())??"unknown"}`}),...n.map(a=>typeof a=="string"?`at opcode ${a}`:`at ${a.locationText} (${a.filePath}:${a.line}:${a.column})`)];return[`Simulation error: ${this.message}`,...i.reverse()].join(`
2062`)}getCallStack(){return this.functionErrorStack}getNoirCallStack(){return this.noirErrorStack||[]}setNoirCallStack(r){this.noirErrorStack=r}setAztecContext(r){this.aztecContext=r}toJSON(){return{originalMessage:this.originalMessage,functionErrorStack:this.functionErrorStack,noirErrorStack:this.noirErrorStack,revertData:this.revertData.map(r=>r.toString())}}static get schema(){return K.object({originalMessage:K.string(),functionErrorStack:K.array(K.object({contractAddress:Be.AztecAddress,contractName:K.string().optional(),functionSelector:Be.FunctionSelector,functionName:K.string().optional()})),noirErrorStack:cve.optional(),revertData:K.array(Be.Fr)}).transform(({originalMessage:r,functionErrorStack:n,noirErrorStack:i,revertData:a})=>new c1(r,n,a,i))}static async random(){return new c1("Random simulation error",[{contractAddress:await nt.random(),functionSelector:Yr.random()}])}}class Dc{constructor(t,r){te(this,"values");te(this,"nested");this.values=t,this.nested=r??[]}static get schema(){return K.object({values:K.array(He.Fr).optional(),nested:K.array(K.lazy(()=>Dc.schema))}).transform(({values:t,nested:r})=>new Dc(t,r))}static empty(){return new Dc([])}static random(t=1){return new Dc(CU(3,le.random),t>0?[Dc.random(t-1)]:[])}}class pp{constructor(t,r,n,i,a){te(this,"revertReason");te(this,"constants");te(this,"txEffect");te(this,"publicReturnValues");te(this,"gasUsed");this.revertReason=t,this.constants=r,this.txEffect=n,this.publicReturnValues=i,this.gasUsed=a}static get schema(){return K.object({revertReason:c1.schema.optional(),constants:Fo.schema,txEffect:Ri.schema,publicReturnValues:K.array(Dc.schema),gasUsed:K.object({totalGas:cr.schema,teardownGas:cr.schema,publicGas:cr.schema,billedGas:cr.schema})}).transform(t=>new pp(t.revertReason,t.constants,t.txEffect,t.publicReturnValues,t.gasUsed))}static async random(){return new pp(await c1.random(),Fo.empty(),Ri.empty(),CU(2,Dc.random),{teardownGas:cr.random(),totalGas:cr.random(),publicGas:cr.random(),billedGas:cr.random()})}}class TU{constructor(t,r){te(this,"privateExecutionResult");te(this,"publicInputs");this.privateExecutionResult=t,this.publicInputs=r}getPrivateReturnValues(){return fve(this.privateExecutionResult)}toSimulatedTx(){const t=_U(this.privateExecutionResult);return new No(this.publicInputs,La.empty(),t,this.privateExecutionResult.publicFunctionCalldata)}}class mp{constructor(t,r,n){te(this,"privateExecutionResult");te(this,"publicInputs");te(this,"publicOutput");this.privateExecutionResult=t,this.publicInputs=r,this.publicOutput=n}get gasUsed(){var t;return((t=this.publicOutput)==null?void 0:t.gasUsed)??{totalGas:this.publicInputs.gasUsed,billedGas:this.publicInputs.gasUsed,teardownGas:cr.empty(),publicGas:cr.empty()}}static get schema(){return K.object({privateExecutionResult:Lc.schema,publicInputs:cs.schema,publicOutput:pp.schema.optional()}).transform(mp.from)}static from(t){return new mp(t.privateExecutionResult,t.publicInputs,t.publicOutput)}static fromPrivateSimulationResultAndPublicOutput(t,r){return new mp(t.privateExecutionResult,t.publicInputs,r)}static async random(){return new mp(await Lc.random(),cs.empty(),await pp.random())}getPrivateReturnValues(){return new TU(this.privateExecutionResult,this.publicInputs).getPrivateReturnValues()}toSimulatedTx(){return new TU(this.privateExecutionResult,this.publicInputs).toSimulatedTx()}getPublicReturnValues(){return this.publicOutput?this.publicOutput.publicReturnValues:[]}}function fve(e){const t=r=>{const n=new Dc(r.returnValues);return n.nested=r.nestedExecutions.map(i=>t(i)),n};return t(e.entrypoint)}class lf{constructor(t,r,n){te(this,"contractAddress");te(this,"storageSlot");te(this,"data");this.contractAddress=t,this.storageSlot=r,this.data=n}static get schema(){return Ds(lf)}toJSON(){return this.toString()}toBuffer(){return ht(this.contractAddress,this.storageSlot,new Xu(this.data))}static fromBuffer(t){const r=rt.asReader(t);return new lf(nt.fromBuffer(r),le.fromBuffer(r),r.readVector(le))}toString(){return Ur(this.toBuffer())}static fromString(t){return lf.fromBuffer(fn(t))}}class Il{constructor(t,r,n,i,a,s,o){te(this,"origin");te(this,"functionSelector");te(this,"firstCallArgsHash");te(this,"txContext");te(this,"argsOfCalls");te(this,"authWitnesses");te(this,"capsules");this.origin=t,this.functionSelector=r,this.firstCallArgsHash=n,this.txContext=i,this.argsOfCalls=a,this.authWitnesses=s,this.capsules=o}static get schema(){return K.object({origin:Be.AztecAddress,functionSelector:Be.FunctionSelector,firstCallArgsHash:Be.Fr,txContext:an.schema,argsOfCalls:K.array(Si.schema),authWitnesses:K.array(Oc.schema),capsules:K.array(lf.schema)}).transform(Il.from)}toTxRequest(){return new nf(this.origin,new Pc(this.functionSelector,!0),this.firstCallArgsHash,this.txContext)}static getFields(t){return[t.origin,t.functionSelector,t.firstCallArgsHash,t.txContext,t.argsOfCalls,t.authWitnesses,t.capsules]}static from(t){return new Il(...Il.getFields(t))}toBuffer(){return ht(this.origin,this.functionSelector,this.firstCallArgsHash,this.txContext,new Xu(this.argsOfCalls),new Xu(this.authWitnesses),new Xu(this.capsules))}toString(){return Ur(this.toBuffer())}static fromBuffer(t){const r=rt.asReader(t);return new Il(r.readObject(nt),r.readObject(Yr),le.fromBuffer(r),r.readObject(an),r.readVector(Si),r.readVector(Oc),r.readVector(lf))}static fromString(t){return Il.fromBuffer(fn(t))}static async random(){return new Il(await nt.random(),Yr.random(),le.random(),an.empty(),[Si.random()],[Oc.random()],[new lf(await nt.random(),le.random(),[le.random(),le.random()]),new lf(await nt.random(),le.random(),[le.random()])])}[ct.inspect.custom](){return`TxExecutionRequest(${this.origin} called ${this.functionSelector})`}}const hve=K.discriminatedUnion("result",[K.object({result:K.literal("valid"),reason:K.array(K.string()).optional()}),K.object({result:K.literal("invalid"),reason:K.array(K.string())}),K.object({result:K.literal("skipped"),reason:K.array(K.string())})]);class cf{constructor(t){te(this,"txEffects");this.txEffects=t,t.forEach(r=>{if(r.isEmpty())throw new Error("Empty tx effect not allowed in Body")})}equals(t){return this.txEffects.length===t.txEffects.length&&this.txEffects.every((r,n)=>r.equals(t.txEffects[n]))}static get schema(){return K.object({txEffects:K.array(Ri.schema)}).transform(({txEffects:t})=>new cf(t))}toBuffer(){return ht(this.txEffects.length,this.txEffects)}static fromBuffer(t){const r=rt.asReader(t);return new this(r.readVector(Ri))}toBlobFields(){let t=[];
2062if(this.txEffects.forEach(r=>{t=t.concat(r.toBlobFields())}),t.length>sL*aL)throw new Error(`Attempted to overfill block's blobs with ${t.length} elements. The maximum is ${sL*aL}`);return t}static fromBlobFields(t){const r=[];let n=0;for(;n!==t.length;){if(!Ri.isFirstField(t[n]))throw new Error("Invalid fields given to Body.fromBlobFields(): First field invalid.");const a=Ri.decodeFirstField(t[n]).length;r.push(t.slice(n,n+a)),n+=a}const i=r.filter(a=>a.length).map(a=>Ri.fromBlobFields(a));return new this(i)}[ct.inspect.custom](){return`Body {
2063  txEffects: ${ct.inspect(this.txEffects)},
2064}`}static async random(t=4,r=3,n=1){const i=await cz(t,()=>Ri.random(r,n));return new cf(i)}static empty(){return new cf([])}}function dve(e=0,t=void 0,r=void 0,n=void 0,i=void 0){return new Xr(gp(e+256),pve(e+512,t,i),mve(e+1536),bve(e+=1792,r,n??r),new le(e+2048),new le(e+2304))}function gp(e=1){return new Ct(new le(e),e)}function pve(e=0,t=void 0,r=void 0){return new jo(t?new le(t):new le(e),Ca(BigInt(e+256),xi),r??Ca(BigInt(e+512),xi),Ca(BigInt(e+768),xi))}function mve(e=0){return new xl(gp(e),gve(e+1))}function gve(e=0){return new wl(gp(e),gp(e+1),gp(e+2))}function bve(e=1,t=void 0,r=void 0){return new si(new le(e),new le(e+1),new le(t??e+2),new le(r??e+3),new le(e+4),Eo.fromField(new le(e+5)),nt.fromField(new le(e+6)),new qr(new le(e+7),new le(e+8)))}class Ol{constructor(t,r,n){te(this,"archive");te(this,"header");te(this,"body");this.archive=t,this.header=r,this.body=n}static get schema(){return K.object({archive:Ct.schema,header:Xr.schema,body:cf.schema}).transform(({archive:t,header:r,body:n})=>new Ol(t,r,n))}static fromBuffer(t){const r=rt.asReader(t),n=r.readObject(Xr),i=r.readObject(Ct),a=r.readObject(cf);return new Ol(i,n,a)}toBuffer(){return ht(this.header,this.archive,this.body)}static fromString(t){return Ol.fromBuffer(fn(t))}toString(){return Ur(this.toBuffer())}static async random(t,r=4,n=3,i=1,a=void 0,s=void 0){const o=await cf.random(r,n,i);return new Ol(gp(t+1),dve(0,r,t,s??t,a),o)}static empty(){return new Ol(Ct.zero(),Xr.empty(),cf.empty())}get number(){return Number(this.header.globalVariables.blockNumber.toBigInt())}hash(){return this.header.hash()}getPublicInputsHash(){const t=[this.header.globalVariables,Ct.zero(),Ct.zero(),Ct.zero(),Ct.zero(),this.header.lastArchive,this.header.state.partial.noteHashTree,this.header.state.partial.nullifierTree,this.header.state.partial.publicDataTree,this.header.state.l1ToL2MessageTree,this.archive];return Bge(t)}getStartStateHash(){const t=ht(new le(Number(this.header.globalVariables.blockNumber.toBigInt())-1),Ct.zero(),Ct.zero(),Ct.zero(),Ct.zero(),this.header.lastArchive);return KS(t)}getEndStateHash(){const t=ht(this.header.globalVariables.blockNumber,this.header.state.partial.noteHashTree,this.header.state.partial.nullifierTree,this.header.state.partial.publicDataTree,this.header.state.l1ToL2MessageTree,this.archive);return KS(t)}getStats(){const t={privateLogCount:this.body.txEffects.reduce((r,n)=>r+n.privateLogs.length,0),publicLogCount:this.body.txEffects.reduce((r,n)=>r+n.publicLogs.length,0),contractClassLogCount:this.body.txEffects.reduce((r,n)=>r+n.contractClassLogs.length,0),contractClassLogSize:this.body.txEffects.reduce((r,n)=>r+n.contractClassLogs.reduce((i,a)=>i+a.getEmittedLength(),0),0)};return{txCount:this.body.txEffects.length,blockNumber:this.number,blockTimestamp:this.header.globalVariables.timestamp.toNumber(),...t}}equals(t){return this.archive.equals(t.archive)&&this.header.equals(t.header)&&this.body.equals(t.body)}}function yve(e,t){return new Promise(r=>setTimeout(()=>r(t),e))}V0("types:l2_block_downloader");function $k(e){return K.object({data:e,l2BlockNumber:Be.Integer,l2BlockHash:K.string()})}const us=K.union([Be.Integer,K.literal("latest")]),Hk=K.union([K.object({number:K.literal(0),hash:K.undefined()}),K.object({number:K.number(),hash:K.string()})]),vve=K.object({latest:Hk,proven:Hk,finalized:Hk}),wve=K.object({block:Ol.schema,l1:K.object({blockNumber:He.BigInt,timestamp:He.BigInt,blockHash:K.string()}),signatures:K.array(jc.schema)});class Zs{constructor(t,r,n){te(this,"blockNumber");te(this,"txIndex");te(this,"logIndex");if(this.blockNumber=t,this.txIndex=r,this.logIndex=n,!Number.isInteger(t)||t<Zge)throw new Error(`Invalid block number: ${t}`);if(!Number.isInteger(r))throw new Error(`Invalid tx index: ${r}`);if(!Number.isInteger(n))throw new Error(`Invalid log index: ${n}`)}static random(){return new Zs(Math.floor(Math.random()*1e3)+1,Math.floor(Math.random()*1e3),Math.floor(Math.random()*100))}static get schema(){return K.object({blockNumber:Be.Integer,txIndex:Be.Integer,logIndex:Be.Integer}).transform(({blockNumber:t,txIndex:r,logIndex:n})=>new Zs(t,r,n))}toBuffer(){return je.concat([Ca(BigInt(this.blockNumber),4),Ca(BigInt(this.txIndex),4),Ca(BigInt(this.logIndex),4)])}static fromBuffer(t){const r=rt.asReader(t),n=r.readNumber(),i=r.readNumber(),a=r.readNumber();return new Zs(n,i,a)}toString(){return`${this.blockNumber}-${this.txIndex}-${this.logIndex}`}static fromString(t){const[r,n,i]=t.split("-"),a=Number(r),s=Number(n),o=Number(i);return new Zs(a,s,o)}toHumanReadable(){return`logId: (blockNumber: ${this.blockNumber}, txIndex: ${this.txIndex}, logIndex: ${this.logIndex})`}}const p2=K.object({txHash:Er.schema.optional(),fromBlock:Be.Integer.optional(),toBlock:Be.Integer.optional(),afterLog:Zs.schema.optional(),contractAddress:Be.AztecAddress.optional()});var m2={exports:{}};
vendor: 6,202 bytes, line 2064
2064m2.exports,function(e,t){var r=200,n="__lodash_hash_undefined__",i=1,a=2,s=9007199254740991,o="[object Arguments]",c="[object Array]",l="[object AsyncFunction]",u="[object Boolean]",d="[object Date]",p="[object Error]",w="[object Function]",O="[object GeneratorFunction]",I="[object Map]",R="[object Number]",C="[object Null]",j="[object Object]",N="[object Promise]",P="[object Proxy]",Z="[object RegExp]",X="[object Set]",re="[object String]",ne="[object Symbol]",ae="[object Undefined]",ue="[object WeakMap]",m="[object ArrayBuffer]",A="[object DataView]",f="[object Float32Array]",g="[object Float64Array]",_="[object Int8Array]",B="[object Int16Array]",T="[object Int32Array]",S="[object Uint8Array]",h="[object Uint8ClampedArray]",x="[object Uint16Array]",v="[object Uint32Array]",F=/[\\^$.*+?()[\]{}|]/g,Q=/^\[object .+?Constructor\]$/,G=/^(?:0|[1-9]\d*)$/,J={};J[f]=J[g]=J[_]=J[B]=J[T]=J[S]=J[h]=J[x]=J[v]=!0,J[o]=J[c]=J[m]=J[u]=J[A]=J[d]=J[p]=J[w]=J[I]=J[R]=J[j]=J[Z]=J[X]=J[re]=J[ue]=!1;var Y=typeof dt=="object"&&dt&&dt.Object===Object&&dt,V=typeof self=="object"&&self&&self.Object===Object&&self,W=Y||V||Function("return this")(),ce=t&&!t.nodeType&&t,pe=ce&&!0&&e&&!e.nodeType&&e,ee=pe&&pe.exports===ce,se=ee&&Y.process,ve=function(){try{return se&&se.binding&&se.binding("util")}catch{}}(),_e=ve&&ve.isTypedArray;function Ue(me,Me){for(var Ze=-1,pt=me==null?0:me.length,$r=0,Ht=[];++Ze<pt;){var gn=me[Ze];Me(gn,Ze,me)&&(Ht[$r++]=gn)}return Ht}function xe(me,Me){for(var Ze=-1,pt=Me.length,$r=me.length;++Ze<pt;)me[$r+Ze]=Me[Ze];return me}function Te(me,Me){for(var Ze=-1,pt=me==null?0:me.length;++Ze<pt;)if(Me(me[Ze],Ze,me))return!0;return!1}function $e(me,Me){for(var Ze=-1,pt=Array(me);++Ze<me;)pt[Ze]=Me(Ze);return pt}function Ae(me){return function(Me){return me(Me)}}function De(me,Me){return me.has(Me)}function Ke(me,Me){return me==null?void 0:me[Me]}function ut(me){var Me=-1,Ze=Array(me.size);return me.forEach(function(pt,$r){Ze[++Me]=[$r,pt]}),Ze}function Fe(me,Me){return function(Ze){return me(Me(Ze))}}function ge(me){var Me=-1,Ze=Array(me.size);return me.forEach(function(pt){Ze[++Me]=pt}),Ze}var we=Array.prototype,ke=Function.prototype,Ne=Object.prototype,z=W["__core-js_shared__"],H=ke.toString,k=Ne.hasOwnProperty,L=function(){var me=/[^.]+$/.exec(z&&z.keys&&z.keys.IE_PROTO||"");return me?"Symbol(src)_1."+me:""}(),q=Ne.toString,ie=RegExp("^"+H.call(k).replace(F,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),fe=ee?W.Buffer:void 0,be=W.Symbol,Ce=W.Uint8Array,ze=Ne.propertyIsEnumerable,Ie=we.splice,qe=be?be.toStringTag:void 0,it=Object.getOwnPropertySymbols,Ve=fe?fe.isBuffer:void 0,zt=Fe(Object.keys,Object),wt=Ni(W,"DataView"),Xe=Ni(W,"Map"),Tt=Ni(W,"Promise"),jt=Ni(W,"Set"),Je=Ni(W,"WeakMap"),Et=Ni(Object,"create"),Bt=qo(wt),Qe=qo(Xe),Lt=qo(Tt),Dt=qo(jt),et=qo(Je),Rt=be?be.prototype:void 0,Mt=Rt?Rt.valueOf:void 0;function Ye(me){var Me=-1,Ze=me==null?0:me.length;for(this.clear();++Me<Ze;){var pt=me[Me];this.set(pt[0],pt[1])}}function Nt(){this.__data__=Et?Et(null):{},this.size=0}function Ft(me){var Me=this.has(me)&&delete this.__data__[me];return this.size-=Me?1:0,Me}function tt(me){var Me=this.__data__;if(Et){var Ze=Me[me];return Ze===n?void 0:Ze}return k.call(Me,me)?Me[me]:void 0}function At(me){var Me=this.__data__;return Et?Me[me]!==void 0:k.call(Me,me)}function It(me,Me){var Ze=this.__data__;return this.size+=this.has(me)?0:1,Ze[me]=Et&&Me===void 0?n:Me,this}Ye.prototype.clear=Nt,Ye.prototype.delete=Ft,Ye.prototype.get=tt,Ye.prototype.has=At,Ye.prototype.set=It;function xt(me){var Me=-1,Ze=me==null?0:me.length;for(this.clear();++Me<Ze;){var pt=me[Me];this.set(pt[0],pt[1])}}function oi(){this.__data__=[],this.size=0}function li(me){var Me=this.__data__,Ze=qa(Me,me);if(Ze<0)return!1;var pt=Me.length-1;return Ze==pt?Me.pop():Ie.call(Me,Ze,1),--this.size,!0}function ci(me){var Me=this.__data__,Ze=qa(Me,me);return Ze<0?void 0:Me[Ze][1]}function Rn(me){return qa(this.__data__,me)>-1}function Sn(me,Me){var Ze=this.__data__,pt=qa(Ze,me);return pt<0?(++this.size,Ze.push([me,Me])):Ze[pt][1]=Me,this}xt.prototype.clear=oi,xt.prototype.delete=li,xt.prototype.get=ci,xt.prototype.has=Rn,xt.prototype.set=Sn;function zr(me){var Me=-1,Ze=me==null?0:me.length;for(this.clear();++Me<Ze;){var pt=me[Me];this.set(pt[0],pt[1])}}function mn(){this.size=0,this.__data__={hash:new Ye,map:new(Xe||xt),string:new Ye}}function Nn(me){var Me=ui(this,me).delete(me);return this.size-=Me?1:0,Me}function Kn(me){return ui(this,me).get(me)}function sn(me){return ui(this,me).has(me)}function Fn(me,Me){var Ze=ui(this,me),pt=Ze.size;return Ze.set(me,Me),this.size+=Ze.size==pt?0:1,this}zr.prototype.clear=mn,zr.prototype.delete=Nn,zr.prototype.get=Kn,zr.prototype.has=sn,zr.prototype.set=Fn;function Tn(me){var Me=-1,Ze=me==null?0:me.length;for(this.__data__=new zr;++Me<Ze;)this.add(me[Me])}function Pn(me){return this.__data__.set(me,n),this}function Gn(me){return this.__data__.has(me)}Tn.prototype.add=Tn.prototype.push=Pn,Tn.prototype.has=Gn;function Zr(me){var Me=this.__data__=new xt(me);this.size=Me.size}function Yn(){this.__data__=new xt,this.size=0}function zn(me){var Me=this.__data__,Ze=Me.delete(me);return this.size=Me.size,Ze}function Ua(me){return this.__data__.get(me)}function Do(me){return this.__data__.has(me)}function S2(me,Me){var Ze=this.__data__;if(Ze instanceof xt){var pt=Ze.__data__;if(!Xe||pt.length<r-1)return pt.push([me,Me]),this.size=++Ze.size,this;Ze=this.__data__=new zr(pt)}return Ze.set(me,Me),this.size=Ze.size,this}Zr.prototype.clear=Yn,Zr.prototype.delete=zn,Zr.prototype.get=Ua,Zr.prototype.has=Do,Zr.prototype.set=S2;function fE(me,Me){var Ze=od(me),pt=!Ze&&S1(me),$r=!Ze&&!pt&&k1(me),Ht=!Ze&&!pt&&!$r&&N2(me),gn=Ze||pt||$r||Ht,Xn=gn?$e(me.length,String):[],br=Xn.length;for(var Tr in me)k.call(me,Tr)&&!(gn&&(Tr=="length"||$r&&(Tr=="offset"||Tr=="parent")||Ht&&(Tr=="buffer"||Tr=="byteLength"||Tr=="byteOffset")||C2(Tr,br)))&&Xn.push(Tr);return Xn}function qa(me,Me){for(var Ze=me.length;Ze--;)if(_1(me[Ze][0],Me))return Ze;return-1}function sd(me,Me,Ze){var pt=Me(me);return od(me)?pt:xe(pt,Ze(me))}function Uo(me){return me==null?me===void 0?ae:C:qe&&qe in Object(me)?A2(me):I2
vendor: 4,793 bytes, line 2064
2064(me)}function vf(me){return xf(me)&&Uo(me)==o}function Op(me,Me,Ze,pt,$r){return me===Me?!0:me==null||Me==null||!xf(me)&&!xf(Me)?me!==me&&Me!==Me:Bp(me,Me,Ze,pt,Op,$r)}function Bp(me,Me,Ze,pt,$r,Ht){var gn=od(me),Xn=od(Me),br=gn?c:Dl(me),Tr=Xn?c:Dl(Me);br=br==o?j:br,Tr=Tr==o?j:Tr;var Ln=br==j,hs=Tr==j,Jn=br==Tr;if(Jn&&k1(me)){if(!k1(Me))return!1;gn=!0,Ln=!1}if(Jn&&!Ln)return Ht||(Ht=new Zr),gn||N2(me)?w1(me,Me,Ze,pt,$r,Ht):x1(me,Me,br,Ze,pt,$r,Ht);if(!(Ze&i)){var Va=Ln&&k.call(me,"__wrapped__"),Dn=hs&&k.call(Me,"__wrapped__");if(Va||Dn){var Ul=Va?me.value():me,ki=Dn?Me.value():Me;return Ht||(Ht=new Zr),$r(Ul,ki,Ze,pt,Ht)}}return Jn?(Ht||(Ht=new Zr),M2(me,Me,Ze,pt,$r,Ht)):!1}function v1(me){if(!R2(me)||T2(me))return!1;var Me=B2(me)?ie:Q;return Me.test(qo(me))}function k2(me){return xf(me)&&E1(me.length)&&!!J[Uo(me)]}function E2(me){if(!j2(me))return zt(me);var Me=[];for(var Ze in Object(me))k.call(me,Ze)&&Ze!="constructor"&&Me.push(Ze);return Me}function w1(me,Me,Ze,pt,$r,Ht){var gn=Ze&i,Xn=me.length,br=Me.length;if(Xn!=br&&!(gn&&br>Xn))return!1;var Tr=Ht.get(me);if(Tr&&Ht.get(Me))return Tr==Me;var Ln=-1,hs=!0,Jn=Ze&a?new Tn:void 0;for(Ht.set(me,Me),Ht.set(Me,me);++Ln<Xn;){var Va=me[Ln],Dn=Me[Ln];if(pt)var Ul=gn?pt(Dn,Va,Ln,Me,me,Ht):pt(Va,Dn,Ln,me,Me,Ht);if(Ul!==void 0){if(Ul)continue;hs=!1;break}if(Jn){if(!Te(Me,function(ki,Zc){if(!De(Jn,Zc)&&(Va===ki||$r(Va,ki,Ze,pt,Ht)))return Jn.push(Zc)})){hs=!1;break}}else if(!(Va===Dn||$r(Va,Dn,Ze,pt,Ht))){hs=!1;break}}return Ht.delete(me),Ht.delete(Me),hs}function x1(me,Me,Ze,pt,$r,Ht,gn){switch(Ze){case A:if(me.byteLength!=Me.byteLength||me.byteOffset!=Me.byteOffset)return!1;me=me.buffer,Me=Me.buffer;case m:return!(me.byteLength!=Me.byteLength||!Ht(new Ce(me),new Ce(Me)));case u:case d:case R:return _1(+me,+Me);case p:return me.name==Me.name&&me.message==Me.message;case Z:case re:return me==Me+"";case I:var Xn=ut;case X:var br=pt&i;if(Xn||(Xn=ge),me.size!=Me.size&&!br)return!1;var Tr=gn.get(me);if(Tr)return Tr==Me;pt|=a,gn.set(me,Me);var Ln=w1(Xn(me),Xn(Me),pt,$r,Ht,gn);return gn.delete(me),Ln;case ne:if(Mt)return Mt.call(me)==Mt.call(Me)}return!1}function M2(me,Me,Ze,pt,$r,Ht){var gn=Ze&i,Xn=wf(me),br=Xn.length,Tr=wf(Me),Ln=Tr.length;if(br!=Ln&&!gn)return!1;for(var hs=br;hs--;){var Jn=Xn[hs];if(!(gn?Jn in Me:k.call(Me,Jn)))return!1}var Va=Ht.get(me);if(Va&&Ht.get(Me))return Va==Me;var Dn=!0;Ht.set(me,Me),Ht.set(Me,me);for(var Ul=gn;++hs<br;){Jn=Xn[hs];var ki=me[Jn],Zc=Me[Jn];if(pt)var F2=gn?pt(Zc,ki,Jn,Me,me,Ht):pt(ki,Zc,Jn,me,Me,Ht);if(!(F2===void 0?ki===Zc||$r(ki,Zc,Ze,pt,Ht):F2)){Dn=!1;break}Ul||(Ul=Jn=="constructor")}if(Dn&&!Ul){var Fi=me.constructor,ld=Me.constructor;Fi!=ld&&"constructor"in me&&"constructor"in Me&&!(typeof Fi=="function"&&Fi instanceof Fi&&typeof ld=="function"&&ld instanceof ld)&&(Dn=!1)}return Ht.delete(me),Ht.delete(Me),Dn}function wf(me){return sd(me,mE,hE)}function ui(me,Me){var Ze=me.__data__;return dE(Me)?Ze[typeof Me=="string"?"string":"hash"]:Ze.map}function Ni(me,Me){var Ze=Ke(me,Me);return v1(Ze)?Ze:void 0}function A2(me){var Me=k.call(me,qe),Ze=me[qe];try{me[qe]=void 0;var pt=!0}catch{}var $r=q.call(me);return pt&&(Me?me[qe]=Ze:delete me[qe]),$r}var hE=it?function(me){return me==null?[]:(me=Object(me),Ue(it(me),function(Me){return ze.call(me,Me)}))}:gE,Dl=Uo;(wt&&Dl(new wt(new ArrayBuffer(1)))!=A||Xe&&Dl(new Xe)!=I||Tt&&Dl(Tt.resolve())!=N||jt&&Dl(new jt)!=X||Je&&Dl(new Je)!=ue)&&(Dl=function(me){var Me=Uo(me),Ze=Me==j?me.constructor:void 0,pt=Ze?qo(Ze):"";if(pt)switch(pt){case Bt:return A;case Qe:return I;case Lt:return N;case Dt:return X;case et:return ue}return Me});function C2(me,Me){return Me=Me??s,!!Me&&(typeof me=="number"||G.test(me))&&me>-1&&me%1==0&&me<Me}function dE(me){var Me=typeof me;return Me=="string"||Me=="number"||Me=="symbol"||Me=="boolean"?me!=="__proto__":me===null}function T2(me){return!!L&&L in me}function j2(me){var Me=me&&me.constructor,Ze=typeof Me=="function"&&Me.prototype||Ne;return me===Ze}function I2(me){return q.call(me)}function qo(me){if(me!=null){try{return H.call(me)}catch{}try{return me+""}catch{}}return""}function _1(me,Me){return me===Me||me!==me&&Me!==Me}var S1=vf(function(){return arguments}())?vf:function(me){return xf(me)&&k.call(me,"callee")&&!ze.call(me,"callee")},od=Array.isArray;function O2(me){return me!=null&&E1(me.length)&&!B2(me)}var k1=Ve||bE;function pE(me,Me){return Op(me,Me)}function B2(me){if(!R2(me))return!1;var Me=Uo(me);return Me==w||Me==O||Me==l||Me==P}function E1(me){return typeof me=="number"&&me>-1&&me%1==0&&me<=s}function R2(me){var Me=typeof me;return me!=null&&(Me=="object"||Me=="function")}function xf(me){return me!=null&&typeof me=="object"}var N2=_e?Ae(_e):k2;function mE(me){return O2(me)?fE(me):E2(me)}function gE(){return[]}function bE(){return!1}e.exports=pE}
2064(m2,m2.exports);var xve=m2.exports;const jU=Nr(xve);class Wh{constructor(t,r){te(this,"id");te(this,"log");this.id=t,this.log=r}static async random(){return new Wh(Zs.random(),await ia.random())}static get schema(){return K.object({id:Zs.schema,log:ia.schema}).transform(Wh.from)}static from(t){return new Wh(t.id,t.log)}toBuffer(){return je.concat([this.id.toBuffer(),this.log.toBuffer()])}toString(){return Ur(this.toBuffer())}toHumanReadable(){return`${this.id.toHumanReadable()}, ${this.log.toHumanReadable()}`}equals(t){return jU(this,t)}static fromBuffer(t){const r=rt.asReader(t),n=Zs.fromBuffer(r),i=ia.fromBuffer(r);return new Wh(n,i)}static fromString(t){return Wh.fromBuffer(fn(t))}}class Kh{constructor(t,r){te(this,"id");te(this,"log");this.id=t,this.log=r}static async random(){return new Kh(Zs.random(),await ha.random())}static get schema(){return K.object({id:Zs.schema,log:ha.schema}).transform(Kh.from)}static from(t){return new Kh(t.id,t.log)}toBuffer(){return je.concat([this.id.toBuffer(),this.log.toBuffer()])}toString(){return Ur(this.toBuffer())}equals(t){return jU(this,t)}static fromBuffer(t){const r=rt.asReader(t),n=Zs.fromBuffer(r),i=ha.fromBuffer(r);return new Kh(n,i)}static fromString(t){return Kh.fromBuffer(fn(t))}}class u1{constructor(t,r,n,i){te(this,"txHash");te(this,"dataStartIndexForTx");te(this,"blockNumber");te(this,"log");this.txHash=t,this.dataStartIndexForTx=r,this.blockNumber=n,this.log=i}get isFromPublic(){return this.log instanceof ia}static get schema(){return K.object({txHash:Er.schema,dataStartIndexForTx:K.number(),blockNumber:K.number(),log:K.union([Hn.schema,ia.schema])}).transform(({txHash:t,dataStartIndexForTx:r,blockNumber:n,log:i})=>new u1(t,r,n,i))}toBuffer(){const t=this.log instanceof ia;return je.concat([this.txHash.toBuffer(),qx(this.dataStartIndexForTx),qx(this.blockNumber),Lz(t),this.log.toBuffer()])}static fromBuffer(t){const r=rt.asReader(t),n=r.readObject(Er),i=r.readNumber(),a=r.readNumber(),s=r.readBoolean()?ia.fromBuffer(r):Hn.fromBuffer(r);return new u1(n,i,a,s)}static async random(){const t=Math.random()<.5?await ia.random():Hn.random();return new u1(Er.random(),1,1,t)}equals(t){return this.txHash.equals(t.txHash)&&this.dataStartIndexForTx===t.dataStartIndexForTx&&this.blockNumber===t.blockNumber&&(this.log instanceof ia&&t.log instanceof ia||this.log instanceof Hn&&t.log instanceof Hn)&&this.log.equals(t.log)}}class f1{constructor(t,r,n,i,a){te(this,"note");te(this,"recipient");te(this,"contractAddress");te(this,"storageSlot");te(this,"txHash");this.note=t,this.recipient=r,this.contractAddress=n,this.storageSlot=i,this.txHash=a}toBuffer(){return ht([this.note,this.recipient,this.contractAddress,this.storageSlot,this.txHash])}static fromBuffer(t){const r=rt.asReader(t),n=r.readObject(Bo),i=r.readObject(nt),a=r.readObject(nt),s=r.readObject(le),o=r.readObject(Er);return new this(n,i,a,s,o)}static get schema(){return K.object({note:Bo.schema,recipient:Be.AztecAddress,contractAddress:Be.AztecAddress,storageSlot:Be.Fr,txHash:Er.schema}).transform(({note:t,recipient:r,contractAddress:n,storageSlot:i,txHash:a})=>new f1(t,r,n,i,a))}toString(){return Ur(this.toBuffer())}static fromString(t){return f1.fromBuffer(fn(t))}static async random(){return new f1(Bo.random(),await nt.random(),await nt.random(),le.random(),Er.random())}}class h1 extends f1{constructor(r,n,i,a,s,o){super(r,n,i,a,s);te(this,"nonce");this.nonce=o}static get schema(){return K.object({note:Bo.schema,recipient:Be.AztecAddress,contractAddress:Be.AztecAddress,storageSlot:Be.Fr,txHash:Er.schema,nonce:Be.Fr}).transform(({note:r,recipient:n,contractAddress:i,storageSlot:a,txHash:s,nonce:o})=>new h1(r,n,i,a,s,o))}toBuffer(){return ht([this.note,this.recipient,this.contractAddress,this.storageSlot,this.txHash,this.nonce])}static async random(){return new h1(Bo.random(),await nt.random(),await nt.random(),le.random(),Er.random(),le.random())}static fromBuffer(r){const n=rt.asReader(r),i=n.readObject(Bo),a=n.readObject(nt),s=n.readObject(nt),o=n.readObject(le),c=n.readObject(Er),l=n.readObject(le);return new this(i,a,s,o,c,l)}static fromString(r){return h1.fromBuffer(fn(r))}}var _ve=function(e){return e[e.ACTIVE=1]="ACTIVE",e[e.ACTIVE_OR_NULLIFIED=2]="ACTIVE_OR_NULLIFIED",e}({});const Sve=K.object({txHash:Er.schema.optional(),contractAddress:Be.AztecAddress.optional(),storageSlot:Be.Fr.optional(),recipient:Be.AztecAddress.optional(),status:K.nativeEnum(_ve).optional(),siloedNullifier:Be.Fr.optional(),scopes:K.array(Be.AztecAddress).optional()});async function kve(e){const t="saltedInitializationHash"in e?e.saltedInitializationHash:await Eve(e);return yl([e.originalContractClassId,t],Ba.PARTIAL_ADDRESS)}function Eve(e){return yl([e.salt,e.initializationHash,e.deployer],Ba.PARTIAL_ADDRESS)}
vendor: 10,172 bytes, lines 2064-2076
2064var Wk={exports:{}},Kk={},IU;function OU(){if(IU)return Kk;IU=1;function e(j){"@babel/helpers - typeof";return e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(N){return typeof N}:function(N){return N&&typeof Symbol=="function"&&N.constructor===Symbol&&N!==Symbol.prototype?"symbol":typeof N},e(j)}function t(j,N,P){return Object.defineProperty(j,"prototype",{writable:!1}),j}function r(j,N){if(!(j instanceof N))throw new TypeError("Cannot call a class as a function")}function n(j,N){if(typeof N!="function"&&N!==null)throw new TypeError("Super expression must either be null or a function");j.prototype=Object.create(N&&N.prototype,{constructor:{value:j,writable:!0,configurable:!0}}),Object.defineProperty(j,"prototype",{writable:!1}),N&&i(j,N)}function i(j,N){return i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(P,Z){return P.__proto__=Z,P},i(j,N)}function a(j){var N=c();return function(){var P=l(j),Z;if(N){var X=l(this).constructor;Z=Reflect.construct(P,arguments,X)}else Z=P.apply(this,arguments);return s(this,Z)}}function s(j,N){if(N&&(e(N)==="object"||typeof N=="function"))return N;if(N!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return o(j)}function o(j){if(j===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return j}function c(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function l(j){return l=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(N){return N.__proto__||Object.getPrototypeOf(N)},l(j)}var u={},d,p;function w(j,N,P){P||(P=Error);function Z(re,ne,ae){return typeof N=="string"?N:N(re,ne,ae)}var X=function(re){n(ae,re);var ne=a(ae);function ae(ue,m,A){var f;return r(this,ae),f=ne.call(this,Z(ue,m,A)),f.code=j,f}return t(ae)}(P);u[j]=X}function O(j,N){if(Array.isArray(j)){var P=j.length;return j=j.map(function(Z){return String(Z)}),P>2?"one of ".concat(N," ").concat(j.slice(0,P-1).join(", "),", or ")+j[P-1]:P===2?"one of ".concat(N," ").concat(j[0]," or ").concat(j[1]):"of ".concat(N," ").concat(j[0])}else return"of ".concat(N," ").concat(String(j))}function I(j,N,P){return j.substr(0,N.length)===N}function R(j,N,P){return(P===void 0||P>j.length)&&(P=j.length),j.substring(P-N.length,P)===N}function C(j,N,P){return typeof P!="number"&&(P=0),P+N.length>j.length?!1:j.indexOf(N,P)!==-1}return w("ERR_AMBIGUOUS_ARGUMENT",'The "%s" argument is ambiguous. %s',TypeError),w("ERR_INVALID_ARG_TYPE",function(j,N,P){d===void 0&&(d=aE()),d(typeof j=="string","'name' must be a string");var Z;typeof N=="string"&&I(N,"not ")?(Z="must not be",N=N.replace(/^not /,"")):Z="must be";var X;if(R(j," argument"))X="The ".concat(j," ").concat(Z," ").concat(O(N,"type"));else{var re=C(j,".")?"property":"argument";X='The "'.concat(j,'" ').concat(re," ").concat(Z," ").concat(O(N,"type"))}return X+=". Received type ".concat(e(P)),X},TypeError),w("ERR_INVALID_ARG_VALUE",function(j,N){var P=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"is invalid";p===void 0&&(p=ct);var Z=p.inspect(N);return Z.length>128&&(Z="".concat(Z.slice(0,128),"...")),"The argument '".concat(j,"' ").concat(P,". Received ").concat(Z)},TypeError),w("ERR_INVALID_RETURN_VALUE",function(j,N,P){var Z;return P&&P.constructor&&P.constructor.name?Z="instance of ".concat(P.constructor.name):Z="type ".concat(e(P)),"Expected ".concat(j,' to be returned from the "').concat(N,'"')+" function but got ".concat(Z,".")},TypeError),w("ERR_MISSING_ARGS",function(){for(var j=arguments.length,N=new Array(j),P=0;P<j;P++)N[P]=arguments[P];d===void 0&&(d=aE()),d(N.length>0,"At least one arg needs to be specified");var Z="The ",X=N.length;switch(N=N.map(function(re){return'"'.concat(re,'"')}),X){case 1:Z+="".concat(N[0]," argument");break;case 2:Z+="".concat(N[0]," and ").concat(N[1]," arguments");break;default:Z+=N.slice(0,X-1).join(", "),Z+=", and ".concat(N[X-1]," arguments");break}return"".concat(Z," must be specified")},TypeError),Kk.codes=u,Kk}var Gk,BU;function Mve(){if(BU)return Gk;BU=1;function e(h,x){var v=Object.keys(h);if(Object.getOwnPropertySymbols){var F=Object.getOwnPropertySymbols(h);x&&(F=F.filter(function(Q){return Object.getOwnPropertyDescriptor(h,Q).enumerable})),v.push.apply(v,F)}return v}function t(h){for(var x=1;x<arguments.length;x++){var v=arguments[x]!=null?arguments[x]:{};x%2?e(Object(v),!0).forEach(function(F){r(h,F,v[F])}):Object.getOwnPropertyDescriptors?Object.defineProperties(h,Object.getOwnPropertyDescriptors(v)):e(Object(v)).forEach(function(F){Object.defineProperty(h,F,Object.getOwnPropertyDescriptor(v,F))})}return h}function r(h,x,v){return x=s(x),x in h?Object.defineProperty(h,x,{value:v,enumerable:!0,configurable:!0,writable:!0}):h[x]=v,h}function n(h,x){if(!(h instanceof x))throw new TypeError("Cannot call a class as a function")}function i(h,x){for(var v=0;v<x.length;v++){var F=x[v];F.enumerable=F.enumerable||!1,F.configurable=!0,"value"in F&&(F.writable=!0),Object.defineProperty(h,s(F.key),F)}}function a(h,x,v){return x&&i(h.prototype,x),Object.defineProperty(h,"prototype",{writable:!1}),h}function s(h){var x=o(h,"string");return j(x)==="symbol"?x:String(x)}function o(h,x){if(j(h)!=="object"||h===null)return h;var v=h[Symbol.toPrimitive];if(v!==void 0){var F=v.call(h,x||"default");if(j(F)!=="object")return F;throw new TypeError("@@toPrimitive must return a primitive value.")}return(x==="string"?String:Number)(h)}function c(h,x){if(typeof x!="function"&&x!==null)throw new TypeError("Super expression must either be null or a function");h.prototype=Object.create(x&&x.prototype,{constructor:{value:h,writable:!0,configurable:!0}}),Object.defineProperty(h,"prototype",{writable:!1}),x&&R(h,x)}function l(h){var x=O();return function(){var v=C(h),F;if(x){var Q=C(this).constructor;F=Reflect.construct(v,arguments,Q)}else F=v.apply(this,arguments);return u(this,F)}}function u(h,x){if(x&&(j(x)==="object"||typeof x=="function"))return x;if(x!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return d(h)}function d(h){if(h===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return h}function p(h){var x=typeof Map=="function"?new Map:void 0;return p=function(v){if(v===null||!I(v))return v;if(typeof v!="function")throw new TypeError("Super expression must either be null or a function");if(typeof x<"u"){if(x.has(v))return x.get(v);x.set(v,F)}function F(){return w(v,arguments,C(this).constructor)}return F.prototype=Object.create(v.prototype,{constructor:{value:F,enumerable:!1,writable:!0,configurable:!0}}),R(F,v)},p(h)}function w(h,x,v){return O()?w=Reflect.construct.bind():w=function(F,Q,G){var J=[null];J.push.apply(J,Q);var Y=Function.bind.apply(F,J),V=new Y;return G&&R(V,G.prototype),V},w.apply(null,arguments)}function O(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function I(h){return Function.toString.call(h).indexOf("[native code]")!==-1}function R(h,x){return R=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(v,F){return v.__proto__=F,v},R(h,x)}function C(h){return C=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(x){return x.__proto__||Object.getPrototypeOf(x)},C(h)}function j(h){"@babel/helpers - typeof";return j=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(x){return typeof x}:function(x){return x&&typeof Symbol=="function"&&x.constructor===Symbol&&x!==Symbol.prototype?"symbol":typeof x},j(h)}var N=ct,P=N.inspect,Z=OU(),X=Z.codes.ERR_INVALID_ARG_TYPE;function re(h,x,v){return(v===void 0||v>h.length)&&(v=h.length),h.substring(v-x.length,v)===x}function ne(h,x){if(x=Math.floor(x),h.length==0||x==0)return"";var v=h.length*x;for(x=Math.floor(Math.log(x)/Math.log(2));x;)h+=h,x--;return h+=h.substring(0,v-h.length),h}var ae="",ue="",m="",A="",f={deepStrictEqual:"Expected values to be strictly deep-equal:",strictEqual:"Expected values to be strictly equal:",strictEqualObject:'Expected "actual" to be reference-equal to "expected":',deepEqual:"Expected values to be loosely deep-equal:",equal:"Expected values to be loosely equal:",notDeepStrictEqual:'Expected "actual" not to be strictly deep-equal to:',notStrictEqual:'Expected "actual" to be strictly unequal to:',notStrictEqualObject:'Expected "actual" not to be reference-equal to "expected":',notDeepEqual:'Expected "actual" not to be loosely deep-equal to:',notEqual:'Expected "actual" to be loosely unequal to:',notIdentical:"Values identical but not reference-equal:"},g=10;function _(h){var x=Object.keys(h),v=Object.create(Object.getPrototypeOf(h));return x.forEach(function(F){v[F]=h[F]}),Object.defineProperty(v,"message",{value:h.message}),v}function B(h){return P(h,{compact:!1,customInspect:!1,depth:1e3,maxArrayLength:1/0,showHidden:!1,breakLength:1/0,showProxy:!1,sorted:!0,getters:!0})}function T(h,x,v){var F="",Q="",G=0,J="",Y=!1,V=B(h),W=V.split(`
2065`),ce=B(x).split(`
2066`),pe=0,ee="";if(v==="strictEqual"&&j(h)==="object"&&j(x)==="object"&&h!==null&&x!==null&&(v="strictEqualObject"),W.length===1&&ce.length===1&&W[0]!==ce[0]){var se=W[0].length+ce[0].length;if(se<=g){if((j(h)!=="object"||h===null)&&(j(x)!=="object"||x===null)&&(h!==0||x!==0))return"".concat(f[v],`
2067
2068`)+"".concat(W[0]," !== ").concat(ce[0],`
2069`)}else if(v!=="strictEqualObject"){var ve=ot.stderr&&ot.stderr.isTTY?ot.stderr.columns:80;if(se<ve){for(;W[0][pe]===ce[0][pe];)pe++;pe>2&&(ee=`
2070  `.concat(ne(" ",pe),"^"),pe=0)}}}for(var _e=W[W.length-1],Ue=ce[ce.length-1];_e===Ue&&(pe++<2?J=`
2071  `.concat(_e).concat(J):F=_e,W.pop(),ce.pop(),!(W.length===0||ce.length===0));)_e=W[W.length-1],Ue=ce[ce.length-1];var xe=Math.max(W.length,ce.length);if(xe===0){var Te=V.split(`
2072`);if(Te.length>30)for(Te[26]="".concat(ae,"...").concat(A);Te.length>27;)Te.pop();return"".concat(f.notIdentical,`
2073
2074`).concat(Te.join(`
2075`),`
2076`)}pe>3&&(J=`
2077`.concat(ae,"...").concat(A).concat(J),Y=!0),F!==""&&(J=`
2078  `.concat(F).concat(J),F="");var $e=0,Ae=f[v]+`
2079`.concat(ue,"+ actual").concat(A," ").concat(m,"- expected").concat(A),De=" ".concat(ae,"...").concat(A," Lines skipped");for(pe=0;pe<xe;pe++){var Ke=pe-G;if(W.length<pe+1)Ke>1&&pe>2&&(Ke>4?(Q+=`
2080`.concat(ae,"...").concat(A),Y=!0):Ke>3&&(Q+=`
2081  `.concat(ce[pe-2]),$e++),Q+=`
2082  `.concat(ce[pe-1]),$e++),G=pe,F+=`
2083`.concat(m,"-").concat(A," ").concat(ce[pe]),$e++;else if(ce.length<pe+1)Ke>1&&pe>2&&(Ke>4?(Q+=`
2084`.concat(ae,"...").concat(A),Y=!0):Ke>3&&(Q+=`
2085  `.concat(W[pe-2]),$e++),Q+=`
2086  `.concat(W[pe-1]),$e++),G=pe,Q+=`
2087`.concat(ue,"+").concat(A," ").concat(W[pe]),$e++;else{var ut=ce[pe],Fe=W[pe],ge=Fe!==ut&&(!re(Fe,",")||Fe.slice(0,-1)!==ut);ge&&re(ut,",")&&ut.slice(0,-1)===Fe&&(ge=!1,Fe+=","),ge?(Ke>1&&pe>2&&(Ke>4?(Q+=`
2088`.concat(ae,"...").concat(A),Y=!0):Ke>3&&(Q+=`
2089  `.concat(W[pe-2]),$e++),Q+=`
2090  `.concat(W[pe-1]),$e++),G=pe,Q+=`
2091`.concat(ue,"+").concat(A," ").concat(Fe),F+=`
2092`.concat(m,"-").concat(A," ").concat(ut),$e+=2):(Q+=F,F="",(Ke===1||pe===0)&&(Q+=`
2093  `.concat(Fe),$e++))}if($e>20&&pe<xe-2)return"".concat(Ae).concat(De,`
2094`).concat(Q,`
2095`).concat(ae,"...").concat(A).concat(F,`
2096`)+"".concat(ae,"...").concat(A)}return"".concat(Ae).concat(Y?De:"",`
2097`).concat(Q).concat(F).concat(J).concat(ee)}var S=function(h,x){c(F,h);var v=l(F);function F(Q){var G;if(n(this,F),j(Q)!=="object"||Q===null)throw new X("options","Object",Q);var J=Q.message,Y=Q.operator,V=Q.stackStartFn,W=Q.actual,ce=Q.expected,pe=Error.stackTraceLimit;if(Error.stackTraceLimit=0,J!=null)G=v.call(this,String(J));else if(ot.stderr&&ot.stderr.isTTY&&(ot.stderr&&ot.stderr.getColorDepth&&ot.stderr.getColorDepth()!==1?(ae="\x1B[34m",ue="\x1B[32m",A="\x1B[39m",m="\x1B[31m"):(ae="",ue="",A="",m="")),j(W)==="object"&&W!==null&&j(ce)==="object"&&ce!==null&&"stack"in W&&W instanceof Error&&"stack"in ce&&ce instanceof Error&&(W=_(W),ce=_(ce)),Y==="deepStrictEqual"||Y==="strictEqual")G=v.call(this,T(W,ce,Y));else if(Y==="notDeepStrictEqual"||Y==="notStrictEqual"){var ee=f[Y],se=B(W).split(`
2098`);if(Y==="notStrictEqual"&&j(W)==="object"&&W!==null&&(ee=f.notStrictEqualObject),se.length>30)for(se[26]="".concat(ae,"...").concat(A);se.length>27;)se.pop();se.length===1?G=v.call(this,"".concat(ee," ").concat(se[0])):G=v.call(this,"".concat(ee,`
2099
2100`).concat(se.join(`
2101`),`
2102`))}else{var ve=B(W),_e="",Ue=f[Y];Y==="notDeepEqual"||Y==="notEqual"?(ve="".concat(f[Y],`
2103
2104`).concat(ve),ve.length>1024&&(ve="".concat(ve.slice(0,1021),"..."))):(_e="".concat(B(ce)),ve.length>512&&(ve="".concat(ve.slice(0,509),"...")),_e.length>512&&(_e="".concat(_e.slice(0,509),"...")),Y==="deepEqual"||Y==="equal"?ve="".concat(Ue,`
2105
2106`).concat(ve,`
2107
2108should equal
2109
2110`):_e=" ".concat(Y," ").concat(_e)),G=v.call(this,"".concat(ve).concat(_e))}return Error.stackTraceLimit=pe,G.generatedMessage=!J,Object.defineProperty(d(G),"name",{value:"AssertionError [ERR_ASSERTION]",enumerable:!1,writable:!0,configurable:!0}),G.code="ERR_ASSERTION",G.actual=W,G.expected=ce,G.operator=Y,Error.captureStackTrace&&Error.captureStackTrace(d(G),V),G.stack,G.name="AssertionError",u(G)}return a(F,[{key:"toString",value:function(){return"".concat(this.name," [").concat(this.code,"]: ").concat(this.message)}},{key:x,value:function(Q,G){return P(this,t(t({},G),{},{customInspect:!1,depth:0}))}}]),F}(p(Error),P.custom);return Gk=S,Gk}var RU=Object.prototype.toString,NU=function(e){var t=RU.call(e),r=t==="[object Arguments]";return r||(r=t!=="[object Array]"&&e!==null&&typeof e=="object"&&typeof e.length=="number"&&e.length>=0&&RU.call(e.callee)==="[object Function]"),r},Yk,FU;function Ave(){if(FU)return Yk;FU=1;var e;if(!Object.keys){var t=Object.prototype.hasOwnProperty,r=Object.prototype.toString,n=NU,i=Object.prototype.propertyIsEnumerable,a=!i.call({toString:null},"toString"),s=i.call(function(){},"prototype"),o=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],c=function(p){var w=p.constructor;return w&&w.prototype===p},l={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHe
2110ight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},u=function(){if(typeof window>"u")return!1;for(var p in window)try{if(!l["$"+p]&&t.call(window,p)&&window[p]!==null&&typeof window[p]=="object")try{c(window[p])}catch{return!0}}catch{return!0}return!1}(),d=function(p){if(typeof window>"u"||!u)return c(p);try{return c(p)}catch{return!1}};e=function(p){var w=p!==null&&typeof p=="object",O=r.call(p)==="[object Function]",I=n(p),R=w&&r.call(p)==="[object String]",C=[];if(!w&&!O&&!I)throw new TypeError("Object.keys called on a non-object");var j=s&&O;if(R&&p.length>0&&!t.call(p,0))for(var N=0;N<p.length;++N)C.push(String(N));if(I&&p.length>0)for(var P=0;P<p.length;++P)C.push(String(P));else for(var Z in p)!(j&&Z==="prototype")&&t.call(p,Z)&&C.push(String(Z));if(a)for(var X=d(p),re=0;re<o.length;++re)!(X&&o[re]==="constructor")&&t.call(p,o[re])&&C.push(o[re]);return C}}return Yk=e,Yk}var Cve=Array.prototype.slice,Tve=NU,PU=Object.keys,g2=PU?function(e){return PU(e)}:Ave(),zU=Object.keys;g2.shim=function(){if(Object.keys){var e=function(){var t=Object.keys(arguments);return t&&t.length===arguments.length}(1,2);e||(Object.keys=function(t){return Tve(t)?zU(Cve.call(t)):zU(t)})}else Object.keys=g2;return Object.keys||g2};var LU=g2,DU={exports:{}};(function(e){var t=gc,r=al,n=Tg,i=mc,a=r("%Function.prototype.apply%"),s=r("%Function.prototype.call%"),o=r("%Reflect.apply%",!0)||t.call(s,a),c=Iu,l=r("%Math.max%");e.exports=function(d){if(typeof d!="function")throw new i("a function is required");var p=o(t,s,arguments);return n(p,1+l(0,d.length-(arguments.length-1)),!0)};var u=function(){return o(t,a,arguments)};c?c(e.exports,"apply",{value:u}):e.exports.apply=u})(DU);var jve=DU.exports,UU=al,qU=jve,Ive=qU(UU("String.prototype.indexOf")),Ove=function(e,t){var r=UU(e,!!t);return typeof r=="function"&&Ive(e,".prototype.")>-1?qU(r):r},Bve=LU,VU=d4(),ZU=Ove,$U=Object,Rve=ZU("Array.prototype.push"),HU=ZU("Object.prototype.propertyIsEnumerable"),Nve=VU?Object.getOwnPropertySymbols:null,Fve=function(e,t){if(e==null)throw new TypeError("target must be an object");var r=$U(e);if(arguments.length===1)return r;for(var n=1;n<arguments.length;++n){var i=$U(arguments[n]),a=Bve(i),s=VU&&(Object.getOwnPropertySymbols||Nve);if(s)for(var o=s(i),c=0;c<o.length;++c){var l=o[c];HU(i,l)&&Rve(a,l)}for(var u=0;u<a.length;++u){var d=a[u];if(HU(i,d)){var p=i[d];r[d]=p}}}return r},Pve=Fve,zve=function(){if(!Object.assign)return!1;for(var e="abcdefghijklmnopqrst",t=e.split(""),r={},n=0;n<t.length;++n)r[t[n]]=t[n];var i=Object.assign({},r),a="";for(var s in i)a+=s;return e!==a},Lve=function(){if(!Object.assign||!Object.preventExtensions)return!1;var e=Object.preventExtensions({1:2});try{Object.assign(e,"xy")}catch{return e[1]==="y"}return!1},Dve=function(){return!Object.assign||zve()||Lve()?Pve:Object.assign},WU=function(e){return e!==e},KU=function(e,t){return e===0&&t===0?1/e===1/t:!!(e===t||WU(e)&&WU(t))},Uve=KU,Xk=function(){return typeof Object.is=="function"?Object.is:Uve},GU={exports:{}};(function(e){var t=gc,r=al,n=Tg,i=mc,a=r("%Function.prototype.apply%"),s=r("%Function.prototype.call%"),o=r("%Reflect.apply%",!0)||t.call(s,a),c=Iu,l=r("%Math.max%");e.exports=function(d){if(typeof d!="function")throw new i("a function is required");var p=o(t,s,arguments);return n(p,1+l(0,d.length-(arguments.length-1)),!0)};var u=function(){return o(t,a,arguments)};c?c(e.exports,"apply",{value:u}):e.exports.apply=u})(GU);var qve=GU.exports,YU=al,XU=qve,Vve=XU(YU("String.prototype.indexOf")),Zve=function(e,t){var r=YU(e,!!t);return typeof r=="function"&&Vve(e,".prototype.")>-1?XU(r):r},Jk,JU;function b2(){if(JU)return Jk;JU=1;var e=LU,t=typeof Symbol=="function"&&typeof Symbol("foo")=="symbol",r=Object.prototype.toString,n=Array.prototype.concat,i=aB,a=function(l){return typeof l=="function"&&r.call(l)==="[object Function]"},s=oB(),o=function(l,u,d,p){if(u in l){if(p===!0){if(l[u]===d)return}else if(!a(p)||!p())return}s?i(l,u,d,!0):i(l,u,d)},c=function(l,u){var d=arguments.length>2?arguments[2]:{},p=e(u);t&&(p=n.call(p,Object.getOwnPropertySymbols(u)));for(var w=0;w<p.length;w+=1)o(l,p[w],u[p[w]],d[p[w]])};return c.supportsDescriptors=!!s,Jk=c,Jk}var Qk,QU;function $ve(){if(QU)return Qk;QU=1;var e=Xk,t=b2();return Qk=function(){var r=e();return t(Object,{is:r},{is:function(){return Object.is!==r}}),r},Qk}var eE,eq;function Hve(){if(eq)return eE;eq=1;var e=b2(),t=N4,r=KU,n=Xk,i=$ve(),a=t(n(),Object);return e(a,{getPolyfill:n,implementation:r,shim:i}),eE=a,eE}var tq={exports:{}},rq;function Wve(){return rq||(rq=1,function(e){var t=gc,r=al,n=Tg,i=mc,a=r("%Function.prototype.apply%"),s=r("%Function.prototype.call%"),o=r("%Reflect.apply%",!0)||t.call(s,a),c=Iu,l=r("%Math.max%");e.exports=function(d){if(typeof d!="function")throw new i("a function is required");var p=o(t,s,arguments);return n(p,1+l(0,d.length-(arguments.length-1)),!0)};var u=function(){return o(t,a,arguments)};c?c(e.exports,"apply",{value:u}):e.exports.apply=u}(tq)),tq.exports}var nq,iq;function aq(){return iq||(iq=1,nq=function(e){return e!==e}),nq}var tE,sq;
vendor: 19,042 bytes, lines 2110-2120
2110function oq(){if(sq)return tE;sq=1;var e=aq();return tE=function(){return Number.isNaN&&Number.isNaN(NaN)&&!Number.isNaN("a")?Number.isNaN:e},tE}var rE,lq;function Kve(){if(lq)return rE;lq=1;var e=b2(),t=oq();return rE=function(){var r=t();return e(Number,{isNaN:r},{isNaN:function(){return Number.isNaN!==r}}),r},rE}var nE,cq;function Gve(){if(cq)return nE;cq=1;var e=Wve(),t=b2(),r=aq(),n=oq(),i=Kve(),a=e(n(),Number);return t(a,{getPolyfill:n,implementation:r,shim:i}),nE=a,nE}var iE,uq;function Yve(){if(uq)return iE;uq=1;function e(ge,we){return a(ge)||i(ge,we)||r(ge,we)||t()}function t(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2111In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function r(ge,we){if(ge){if(typeof ge=="string")return n(ge,we);var ke=Object.prototype.toString.call(ge).slice(8,-1);if(ke==="Object"&&ge.constructor&&(ke=ge.constructor.name),ke==="Map"||ke==="Set")return Array.from(ge);if(ke==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ke))return n(ge,we)}}function n(ge,we){(we==null||we>ge.length)&&(we=ge.length);for(var ke=0,Ne=new Array(we);ke<we;ke++)Ne[ke]=ge[ke];return Ne}function i(ge,we){var ke=ge==null?null:typeof Symbol<"u"&&ge[Symbol.iterator]||ge["@@iterator"];if(ke!=null){var Ne,z,H,k,L=[],q=!0,ie=!1;try{if(H=(ke=ke.call(ge)).next,we!==0)for(;!(q=(Ne=H.call(ke)).done)&&(L.push(Ne.value),L.length!==we);q=!0);}catch(fe){ie=!0,z=fe}finally{try{if(!q&&ke.return!=null&&(k=ke.return(),Object(k)!==k))return}finally{if(ie)throw z}}return L}}function a(ge){if(Array.isArray(ge))return ge}function s(ge){"@babel/helpers - typeof";return s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(we){return typeof we}:function(we){return we&&typeof Symbol=="function"&&we.constructor===Symbol&&we!==Symbol.prototype?"symbol":typeof we},s(ge)}var o=/a/g.flags!==void 0,c=function(ge){var we=[];return ge.forEach(function(ke){return we.push(ke)}),we},l=function(ge){var we=[];return ge.forEach(function(ke,Ne){return we.push([Ne,ke])}),we},u=Object.is?Object.is:Hve(),d=Object.getOwnPropertySymbols?Object.getOwnPropertySymbols:function(){return[]},p=Number.isNaN?Number.isNaN:Gve();function w(ge){return ge.call.bind(ge)}var O=w(Object.prototype.hasOwnProperty),I=w(Object.prototype.propertyIsEnumerable),R=w(Object.prototype.toString),C=ct.types,j=C.isAnyArrayBuffer,N=C.isArrayBufferView,P=C.isDate,Z=C.isMap,X=C.isRegExp,re=C.isSet,ne=C.isNativeError,ae=C.isBoxedPrimitive,ue=C.isNumberObject,m=C.isStringObject,A=C.isBooleanObject,f=C.isBigIntObject,g=C.isSymbolObject,_=C.isFloat32Array,B=C.isFloat64Array;function T(ge){if(ge.length===0||ge.length>10)return!0;for(var we=0;we<ge.length;we++){var ke=ge.charCodeAt(we);if(ke<48||ke>57)return!0}return ge.length===10&&ge>=Math.pow(2,32)}function S(ge){return Object.keys(ge).filter(T).concat(d(ge).filter(Object.prototype.propertyIsEnumerable.bind(ge)))}function h(ge,we){if(ge===we)return 0;for(var ke=ge.length,Ne=we.length,z=0,H=Math.min(ke,Ne);z<H;++z)if(ge[z]!==we[z]){ke=ge[z],Ne=we[z];break}return ke<Ne?-1:Ne<ke?1:0}var x=!0,v=!1,F=0,Q=1,G=2,J=3;function Y(ge,we){return o?ge.source===we.source&&ge.flags===we.flags:RegExp.prototype.toString.call(ge)===RegExp.prototype.toString.call(we)}function V(ge,we){if(ge.byteLength!==we.byteLength)return!1;for(var ke=0;ke<ge.byteLength;ke++)if(ge[ke]!==we[ke])return!1;return!0}function W(ge,we){return ge.byteLength!==we.byteLength?!1:h(new Uint8Array(ge.buffer,ge.byteOffset,ge.byteLength),new Uint8Array(we.buffer,we.byteOffset,we.byteLength))===0}function ce(ge,we){return ge.byteLength===we.byteLength&&h(new Uint8Array(ge),new Uint8Array(we))===0}function pe(ge,we){return ue(ge)?ue(we)&&u(Number.prototype.valueOf.call(ge),Number.prototype.valueOf.call(we)):m(ge)?m(we)&&String.prototype.valueOf.call(ge)===String.prototype.valueOf.call(we):A(ge)?A(we)&&Boolean.prototype.valueOf.call(ge)===Boolean.prototype.valueOf.call(we):f(ge)?f(we)&&BigInt.prototype.valueOf.call(ge)===BigInt.prototype.valueOf.call(we):g(we)&&Symbol.prototype.valueOf.call(ge)===Symbol.prototype.valueOf.call(we)}function ee(ge,we,ke,Ne){if(ge===we)return ge!==0?!0:ke?u(ge,we):!0;if(ke){if(s(ge)!=="object")return typeof ge=="number"&&p(ge)&&p(we);if(s(we)!=="object"||ge===null||we===null||Object.getPrototypeOf(ge)!==Object.getPrototypeOf(we))return!1}else{if(ge===null||s(ge)!=="object")return we===null||s(we)!=="object"?ge==we:!1;if(we===null||s(we)!=="object")return!1}var z=R(ge),H=R(we);if(z!==H)return!1;if(Array.isArray(ge)){if(ge.length!==we.length)return!1;var k=S(ge),L=S(we);return k.length!==L.length?!1:ve(ge,we,ke,Ne,Q,k)}if(z==="[object Object]"&&(!Z(ge)&&Z(we)||!re(ge)&&re(we)))return!1;if(P(ge)){if(!P(we)||Date.prototype.getTime.call(ge)!==Date.prototype.getTime.call(we))return!1}else if(X(ge)){if(!X(we)||!Y(ge,we))return!1}else if(ne(ge)||ge instanceof Error){if(ge.message!==we.message||ge.name!==we.name)return!1}else if(N(ge)){if(!ke&&(_(ge)||B(ge))){if(!V(ge,we))return!1}else if(!W(ge,we))return!1;var q=S(ge),ie=S(we);return q.length!==ie.length?!1:ve(ge,we,ke,Ne,F,q)}else{if(re(ge))return!re(we)||ge.size!==we.size?!1:ve(ge,we,ke,Ne,G);if(Z(ge))return!Z(we)||ge.size!==we.size?!1:ve(ge,we,ke,Ne,J);if(j(ge)){if(!ce(ge,we))return!1}else if(ae(ge)&&!pe(ge,we))return!1}return ve(ge,we,ke,Ne,F)}function se(ge,we){return we.filter(function(ke){return I(ge,ke)})}function ve(ge,we,ke,Ne,z,H){if(arguments.length===5){H=Object.keys(ge);var k=Object.keys(we);if(H.length!==k.length)return!1}for(var L=0;L<H.length;L++)if(!O(we,H[L]))return!1;if(ke&&arguments.length===5){var q=d(ge);if(q.length!==0){var ie=0;for(L=0;L<q.length;L++){var fe=q[L];if(I(ge,fe)){if(!I(we,fe))return!1;H.push(fe),ie++}else if(I(we,fe))return!1}var be=d(we);if(q.length!==be.length&&se(we,be).length!==ie)return!1}else{var Ce=d(we);if(Ce.length!==0&&se(we,Ce).length!==0)return!1}}if(H.length===0&&(z===F||z===Q&&ge.length===0||ge.size===0))return!0;if(Ne===void 0)Ne={val1:new Map,val2:new Map,position:0};else{var ze=Ne.val1.get(ge);if(ze!==void 0){var Ie=Ne.val2.get(we);if(Ie!==void 0)return ze===Ie}Ne.position++}Ne.val1.set(ge,Ne.position),Ne.val2.set(we,Ne.position);var qe=Ke(ge,we,ke,H,Ne,z);return Ne.val1.delete(ge),Ne.val2.delete(we),qe}function _e(ge,we,ke,Ne){for(var z=c(ge),H=0;H<z.length;H++){var k=z[H];if(ee(we,k,ke,Ne))return ge.delete(k),!0}return!1}function Ue(ge){switch(s(ge)){case"undefined":return null;case"object":return;case"symbol":return!1;case"string":ge=+ge;case"number":if(p(ge))return!1}return!0}function xe(ge,we,ke){var Ne=Ue(ke);return Ne??(we.has(Ne)&&!ge.has(Ne))}function Te(ge,we,ke,Ne,z){var H=Ue(ke);if(H!=null)return H;var k=we.get(H);return k===void 0&&!we.has(H)||!ee(Ne,k,!1,z)?!1:!ge.has(H)&&ee(Ne,k,!1,z)}function $e(ge,we,ke,Ne){for(var z=null,H=c(ge),k=0;k<H.length;k++){var L=H[k];if(s(L)==="object"&&L!==null)z===null&&(z=new Set),z.add(L);else if(!we.has(L)){if(ke||!xe(ge,we,L))return!1;z===null&&(z=new Set),z.add(L)}}if(z!==null){for(var q=c(we),ie=0;ie<q.length;ie++){var fe=q[ie];if(s(fe)==="object"&&fe!==null){if(!_e(z,fe,ke,Ne))return!1}else if(!ke&&!ge.has(fe)&&!_e(z,fe,ke,Ne))return!1}return z.size===0}return!0}function Ae(ge,we,ke,Ne,z,H){for(var k=c(ge),L=0;L<k.length;L++){var q=k[L];if(ee(ke,q,z,H)&&ee(Ne,we.get(q),z,H))return ge.delete(q),!0}return!1}function De(ge,we,ke,Ne){for(var z=null,H=l(ge),k=0;k<H.length;k++){var L=e(H[k],2),q=L[0],ie=L[1];if(s(q)==="object"&&q!==null)z===null&&(z=new Set),z.add(q);else{var fe=we.get(q);if(fe===void 0&&!we.has(q)||!ee(ie,fe,ke,Ne)){if(ke||!Te(ge,we,q,ie,Ne))return!1;z===null&&(z=new Set),z.add(q)}}}if(z!==null){for(var be=l(we),Ce=0;Ce<be.length;Ce++){var ze=e(be[Ce],2),Ie=ze[0],qe=ze[1];if(s(Ie)==="object"&&Ie!==null){if(!Ae(z,ge,Ie,qe,ke,Ne))return!1}else if(!ke&&(!ge.has(Ie)||!ee(ge.get(Ie),qe,!1,Ne))&&!Ae(z,ge,Ie,qe,!1,Ne))return!1}return z.size===0}return!0}function Ke(ge,we,ke,Ne,z,H){var k=0;if(H===G){if(!$e(ge,we,ke,z))return!1}else if(H===J){if(!De(ge,we,ke,z))return!1}else if(H===Q)for(;k<ge.length;k++)if(O(ge,k)){if(!O(we,k)||!ee(ge[k],we[k],ke,z))return!1}else{if(O(we,k))return!1;for(var L=Object.keys(ge);k<L.length;k++){var q=L[k];if(!O(we,q)||!ee(ge[q],we[q],ke,z))return!1}return L.length===Object.keys(we).length}for(k=0;k<Ne.length;k++){var ie=Ne[k];if(!ee(ge[ie],we[ie],ke,z))return!1}return!0}function ut(ge,we){return ee(ge,we,v)}function Fe(ge,we){return ee(ge,we,x)}return iE={isDeepEqual:ut,isDeepStrictEqual:Fe},iE}var fq;function aE(){if(fq)return Wk.exports;fq=1;function e(G){"@babel/helpers - typeof";return e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(J){return typeof J}:function(J){return J&&typeof Symbol=="function"&&J.constructor===Symbol&&J!==Symbol.prototype?"symbol":typeof J},e(G)}function t(G,J,Y){return Object.defineProperty(G,"prototype",{writable:!1}),G}function r(G,J){if(!(G instanceof J))throw new TypeError("Cannot call a class as a function")}var n=OU(),i=n.codes,a=i.ERR_AMBIGUOUS_ARGUMENT,s=i.ERR_INVALID_ARG_TYPE,o=i.ERR_INVALID_ARG_VALUE,c=i.ERR_INVALID_RETURN_VALUE,l=i.ERR_MISSING_ARGS,u=Mve(),d=ct,p=d.inspect,w=ct.types,O=w.isPromise,I=w.isRegExp,R=Dve(),C=Xk(),j=Zve("RegExp.prototype.test"),N,P;function Z(){var G=Yve();N=G.isDeepEqual,P=G.isDeepStrictEqual}var X=!1,re=Wk.exports=A,ne={};function ae(G){throw G.message instanceof Error?G.message:new u(G)}function ue(G,J,Y,V,W){var ce=arguments.length,pe;if(ce===0)pe="Failed";else if(ce===1)Y=G,G=void 0;else{if(X===!1){X=!0;var ee=ot.emitWarning?ot.emitWarning:console.warn.bind(console);ee("assert.fail() with more than one argument is deprecated. Please use assert.strictEqual() instead or only pass a message.","DeprecationWarning","DEP0094")}ce===2&&(V="!=")}if(Y instanceof Error)throw Y;var se={actual:G,expected:J,operator:V===void 0?"fail":V,stackStartFn:W||ue};Y!==void 0&&(se.message=Y);var ve=new u(se);throw pe&&(ve.message=pe,ve.generatedMessage=!0),ve}re.fail=ue,re.AssertionError=u;function m(G,J,Y,V){if(!Y){var W=!1;if(J===0)W=!0,V="No value argument passed to `assert.ok()`";else if(V instanceof Error)throw V;var ce=new u({actual:Y,expected:!0,message:V,operator:"==",stackStartFn:G});throw ce.generatedMessage=W,ce}}function A(){for(var G=arguments.length,J=new Array(G),Y=0;Y<G;Y++)J[Y]=arguments[Y];m.apply(void 0,[A,J.length].concat(J))}re.ok=A,re.equal=function G(J,Y,V){if(arguments.length<2)throw new l("actual","expected");J!=Y&&ae({actual:J,expected:Y,message:V,operator:"==",stackStartFn:G})},re.notEqual=function G(J,Y,V){if(arguments.length<2)throw new l("actual","expected");J==Y&&ae({actual:J,expected:Y,message:V,operator:"!=",stackStartFn:G})},re.deepEqual=function G(J,Y,V){if(arguments.length<2)throw new l("actual","expected");N===void 0&&Z(),N(J,Y)||ae({actual:J,expected:Y,message:V,operator:"deepEqual",stackStartFn:G})},re.notDeepEqual=function G(J,Y,V){if(arguments.length<2)throw new l("actual","expected");N===void 0&&Z(),N(J,Y)&&ae({actual:J,expected:Y,message:V,operator:"notDeepEqual",stackStartFn:G})},re.deepStrictEqual=function G(J,Y,V){if(arguments.length<2)throw new l("actual","expected");N===void 0&&Z(),P(J,Y)||ae({actual:J,expected:Y,message:V,operator:"deepStrictEqual",stackStartFn:G})},re.notDeepStrictEqual=f;function f(G,J,Y){if(arguments.length<2)throw new l("actual","expected");N===void 0&&Z(),P(G,J)&&ae({actual:G,expected:J,message:Y,operator:"notDeepStrictEqual",stackStartFn:f})}re.strictEqual=function G(J,Y,V){if(arguments.length<2)throw new l("actual","expected");C(J,Y)||ae({actual:J,expected:Y,message:V,operator:"strictEqual",stackStartFn:G})},re.notStrictEqual=function G(J,Y,V){if(arguments.length<2)throw new l("actual","expected");C(J,Y)&&ae({actual:J,expected:Y,message:V,operator:"notStrictEqual",stackStartFn:G})};var g=t(function G(J,Y,V){var W=this;r(this,G),Y.forEach(function(ce){ce in J&&(V!==void 0&&typeof V[ce]=="string"&&I(J[ce])&&j(J[ce],V[ce])?W[ce]=V[ce]:W[ce]=J[ce])})});function _(G,J,Y,V,W,ce){if(!(Y in G)||!P(G[Y],J[Y])){if(!V){var pe=new g(G,W),ee=new g(J,W,G),se=new u({actual:pe,expected:ee,operator:"deepStrictEqual",stackStartFn:ce});throw se.actual=G,se.expected=J,se.operator=ce.name,se}ae({actual:G,expected:J,message:V,operator:ce.name,stackStartFn:ce})}}function B(G,J,Y,V){if(typeof J!="function"){if(I(J))return j(J,G);if(arguments.length===2)throw new s("expected",["Function","RegExp"],J);if(e(G)!=="object"||G===null){var W=new u({actual:G,expected:J,message:Y,operator:"deepStrictEqual",stackStartFn:V});throw W.operator=V.name,W}var ce=Object.keys(J);if(J instanceof Error)ce.push("name","message");else if(ce.length===0)throw new o("error",J,"may not be an empty object");return N===void 0&&Z(),ce.forEach(function(pe){typeof G[pe]=="string"&&I(J[pe])&&j(J[pe],G[pe])||_(G,J,pe,Y,ce,V)}),!0}return J.prototype!==void 0&&G instanceof J?!0:Error.isPrototypeOf(J)?!1:J.call({},G)===!0}function T(G){if(typeof G!="function")throw new s("fn","Function",G);try{G()}catch(J){return J}return ne}function S(G){return O(G)||G!==null&&e(G)==="object"&&typeof G.then=="function"&&typeof G.catch=="function"}function h(G){return Promise.resolve().then(function(){var J;if(typeof G=="function"){if(J=G(),!S(J))throw new c("instance of Promise","promiseFn",J)}else if(S(G))J=G;else throw new s("promiseFn",["Function","Promise"],G);return Promise.resolve().then(function(){return J}).then(function(){return ne}).catch(function(Y){return Y})})}function x(G,J,Y,V){if(typeof Y=="string"){if(arguments.length===4)throw new s("error",["Object","Error","Function","RegExp"],Y);if(e(J)==="object"&&J!==null){if(J.message===Y)throw new a("error/message",'The error message "'.concat(J.message,'" is identical to the message.'))}else if(J===Y)throw new a("error/message",'The error "'.concat(J,'" is identical to the message.'));V=Y,Y=void 0}else if(Y!=null&&e(Y)!=="object"&&typeof Y!="function")throw new s("error",["Object","Error","Function","RegExp"],Y);if(J===ne){var W="";Y&&Y.name&&(W+=" (".concat(Y.name,")")),W+=V?": ".concat(V):".";var ce=G.name==="rejects"?"rejection":"exception";ae({actual:void 0,expected:Y,operator:G.name,message:"Missing expected ".concat(ce).concat(W),stackStartFn:G})}if(Y&&!B(J,Y,V,G))throw J}function v(G,J,Y,V){if(J!==ne){if(typeof Y=="string"&&(V=Y,Y=void 0),!Y||B(J,Y)){var W=V?": ".concat(V):".",ce=G.name==="doesNotReject"?"rejection":"exception";ae({actual:J,expected:Y,operator:G.name,message:"Got unwanted ".concat(ce).concat(W,`
2112`)+'Actual message: "'.concat(J&&J.message,'"'),stackStartFn:G})}throw J}}re.throws=function G(J){for(var Y=arguments.length,V=new Array(Y>1?Y-1:0),W=1;W<Y;W++)V[W-1]=arguments[W];x.apply(void 0,[G,T(J)].concat(V))},re.rejects=function G(J){for(var Y=arguments.length,V=new Array(Y>1?Y-1:0),W=1;W<Y;W++)V[W-1]=arguments[W];return h(J).then(function(ce){return x.apply(void 0,[G,ce].concat(V))})},re.doesNotThrow=function G(J){for(var Y=arguments.length,V=new Array(Y>1?Y-1:0),W=1;W<Y;W++)V[W-1]=arguments[W];v.apply(void 0,[G,T(J)].concat(V))},re.doesNotReject=function G(J){for(var Y=arguments.length,V=new Array(Y>1?Y-1:0),W=1;W<Y;W++)V[W-1]=arguments[W];return h(J).then(function(ce){return v.apply(void 0,[G,ce].concat(V))})},re.ifError=function G(J){if(J!=null){var Y="ifError got unwanted exception: ";e(J)==="object"&&typeof J.message=="string"?J.message.length===0&&J.constructor?Y+=J.constructor.name:Y+=J.message:Y+=p(J);var V=new u({actual:J,expected:null,operator:"ifError",message:Y,stackStartFn:G}),W=J.stack;if(typeof W=="string"){var ce=W.split(`
2113`);ce.shift();for(var pe=V.stack.split(`
2114`),ee=0;ee<ce.length;ee++){var se=pe.indexOf(ce[ee]);if(se!==-1){pe=pe.slice(0,se);break}}V.stack="".concat(pe.join(`
2115`),`
2116`).concat(ce.join(`
2117`))}throw V}};function F(G,J,Y,V,W){if(!I(J))throw new s("regexp","RegExp",J);var ce=W==="match";if(typeof G!="string"||j(J,G)!==ce){if(Y instanceof Error)throw Y;var pe=!Y;Y=Y||(typeof G!="string"?'The "string" argument must be of type string. Received type '+"".concat(e(G)," (").concat(p(G),")"):(ce?"The input did not match the regular expression ":"The input was expected to not match the regular expression ")+"".concat(p(J),`. Input:
2118
2119`).concat(p(G),`
2120`));var ee=new u({actual:G,expected:J,message:Y,operator:W,stackStartFn:V});throw ee.generatedMessage=pe,ee}}re.match=function G(J,Y,V){F(J,Y,V,G,"match")},re.doesNotMatch=function G(J,Y,V){F(J,Y,V,G,"doesNotMatch")};function Q(){for(var G=arguments.length,J=new Array(G),Y=0;Y<G;Y++)J[Y]=arguments[Y];m.apply(void 0,[Q,J.length].concat(J))}return re.strict=R(Q,re,{equal:re.strictEqual,deepEqual:re.deepStrictEqual,notEqual:re.notStrictEqual,notDeepEqual:re.notDeepStrictEqual}),re.strict.strict=re.strict,Wk.exports}aE();const Xve=1,hq=K.object({selector:Yr.schema,vkHash:He.Fr}),Jve=hq.and(K.object({bytecode:He.Buffer})),Qve=K.object({selector:Yr.schema,bytecode:He.Buffer}),ewe=K.object({artifactMetadataHash:He.Fr,functionMetadataHash:He.Fr,unconstrainedFunctionsArtifactTreeRoot:He.Fr,privateFunctionTreeSiblingPath:K.array(He.Fr),privateFunctionTreeLeafIndex:He.Integer,artifactTreeSiblingPath:K.array(He.Fr),artifactTreeLeafIndex:He.Integer}),twe=K.object({artifactMetadataHash:He.Fr,functionMetadataHash:He.Fr,privateFunctionsArtifactTreeRoot:He.Fr,artifactTreeSiblingPath:K.array(He.Fr),artifactTreeLeafIndex:He.Integer}),dq=K.object({version:K.literal(Xve),artifactHash:He.Fr,privateFunctions:K.array(hq),packedBytecode:He.Buffer}),rwe=dq.extend({id:He.Fr}),nwe=K.object({id:He.Fr,privateFunctionsRoot:He.Fr,privateFunctions:K.array(Jve.and(ewe)),unconstrainedFunctions:K.array(Qve.and(twe))}).and(dq.omit({privateFunctions:!0})),iwe=1,awe=K.object({version:K.literal(iwe),salt:Be.Fr,deployer:Be.AztecAddress,currentContractClassId:Be.Fr,originalContractClassId:Be.Fr,initializationHash:Be.Fr,publicKeys:To.schema}),sE=awe.and(K.object({address:Be.AztecAddress}));K.object({prevContractClassId:Be.Fr,newContractClassId:Be.Fr,blockOfChange:K.number().int().nonnegative()}).and(K.object({address:Be.AztecAddress}));const pq=K.object({rollupAddress:He.EthAddress,registryAddress:He.EthAddress,inboxAddress:He.EthAddress,outboxAddress:He.EthAddress,feeJuiceAddress:He.EthAddress,stakingAssetAddress:He.EthAddress,feeJuicePortalAddress:He.EthAddress,coinIssuerAddress:He.EthAddress,rewardDistributorAddress:He.EthAddress,governanceProposerAddress:He.EthAddress,governanceAddress:He.EthAddress,slashFactoryAddress:He.EthAddress.optional(),feeAssetHandlerAddress:He.EthAddress.optional()}),oE=K.object({classRegisterer:Be.AztecAddress,feeJuice:Be.AztecAddress,instanceDeployer:Be.AztecAddress,multiCallEntrypoint:Be.AztecAddress}),mq=K.object({nodeVersion:K.string(),l1ChainId:K.number().int().nonnegative(),protocolVersion:K.number().int().nonnegative(),enr:K.string().optional(),l1ContractAddresses:pq,protocolContractAddresses:oE}).transform(e=>({enr:void 0,...e})),Vc=class Vc{constructor(t,r,n){te(this,"address");te(this,"publicKeys");te(this,"partialAddress");this.address=t,this.publicKeys=r,this.partialAddress=n}static async create(t,r,n){const i=new Vc(t,r,n);
2120return await i.validate(),i}static get schema(){return Ds(Vc)}toJSON(){return this.toString()}static async random(){return await this.fromSecretKeyAndPartialAddress(le.random(),le.random())}static async fromSecretKeyAndPartialAddress(t,r){const{publicKeys:n}=await lbe(t),i=await WL(n,r);return new Vc(i,n,r)}async getPreaddress(){return HL(await this.publicKeys.hash(),this.partialAddress)}static async fromSecretKeyAndInstance(t,r){const n=await kve(r);return Vc.fromSecretKeyAndPartialAddress(t,n)}async validate(){const t=await WL(this.publicKeys,this.partialAddress);if(!t.equals(this.address))throw new Error(`Address cannot be derived from public keys and partial address (received ${this.address.toString()}, derived ${t.toString()})`)}toReadableString(){return`Address: ${this.address.toString()}
2121Master Nullifier Public Key: ${this.publicKeys.masterNullifierPublicKey.toString()}
2122Master Incoming Viewing Public Key: ${this.publicKeys.masterIncomingViewingPublicKey.toString()}
2123Master Outgoing Viewing Public Key: ${this.publicKeys.masterOutgoingViewingPublicKey.toString()}
2124Master Tagging Public Key: ${this.publicKeys.masterTaggingPublicKey.toString()}
2125Partial Address: ${this.partialAddress.toString()}
2126`}equals(t){return this.address.equals(t.address)&&this.publicKeys.equals(t.publicKeys)&&this.partialAddress.equals(t.partialAddress)}toBuffer(){return ht([this.address,this.publicKeys,this.partialAddress])}static fromBuffer(t){const r=rt.asReader(t),n=r.readObject(nt),i=r.readObject(To),a=r.readObject(le);return Vc.create(n,i,a)}static fromString(t){return Vc.fromBuffer(je.from(t.replace(/^0x/i,""),"hex"))}toString(){return Ur(this.toBuffer())}};te(Vc,"SIZE_IN_BYTES",320);let y2=Vc;const gq=K.object({logs:K.array(Kh.schema),maxLogsHit:K.boolean()}),bq=K.object({logs:K.array(Wh.schema),maxLogsHit:K.boolean()}),yq=K.object({eventSelector:Be.EventSelector,abiType:Fc,fieldNames:K.array(K.string())}),swe=K.object({contractInstance:K.union([sE,K.undefined()]),isContractInitialized:K.boolean(),isContractPubliclyDeployed:K.boolean()}),owe=K.object({contractClass:K.union([rwe,K.undefined()]),isContractClassPubliclyRegistered:K.boolean(),artifact:K.union([l2,K.undefined()])}),lwe=K.object({pxeVersion:K.string(),protocolContractAddresses:oE}),cwe={isL1ToL2MessageSynced:K.function().args(Be.Fr).returns(K.boolean()),registerAccount:K.function().args(Be.Fr,Be.Fr).returns(y2.schema),getRegisteredAccounts:K.function().returns(K.array(y2.schema)),registerSender:K.function().args(Be.AztecAddress).returns(Be.AztecAddress),getSenders:K.function().returns(K.array(Be.AztecAddress)),removeSender:K.function().args(Be.AztecAddress).returns(K.void()),registerContractClass:K.function().args(l2).returns(K.void()),registerContract:K.function().args(K.object({instance:sE,artifact:K.optional(l2)})).returns(K.void()),updateContract:K.function().args(Be.AztecAddress,l2).returns(K.void()),getContracts:K.function().returns(K.array(Be.AztecAddress)),proveTx:K.function().args(Il.schema,Lc.schema).returns(l1.schema),profileTx:K.function().args(Il.schema,K.union([K.literal("gates"),K.literal("full"),K.literal("execution-steps")]),ua(Be.AztecAddress)).returns(d2.schema),simulateTx:K.function().args(Il.schema,K.boolean(),ua(Be.AztecAddress),ua(K.boolean()),ua(K.boolean()),ua(K.array(Be.AztecAddress))).returns(mp.schema),sendTx:K.function().args(No.schema).returns(Er.schema),getTxReceipt:K.function().args(Er.schema).returns(up.schema),getTxEffect:K.function().args(Er.schema).returns(K.union([$k(Ri.schema),K.undefined()])),getPublicStorageAt:K.function().args(Be.AztecAddress,Be.Fr).returns(Be.Fr),getNotes:K.function().args(Sve).returns(K.array(h1.schema)),getL1ToL2MembershipWitness:K.function().args(Be.AztecAddress,Be.Fr,Be.Fr).returns(K.tuple([Be.BigInt,An.schemaFor(iL)])),getL2ToL1MembershipWitness:K.function().args(K.number(),Be.Fr).returns(K.tuple([Be.BigInt,An.schema])),getBlock:K.function().args(K.number()).returns(K.union([Ol.schema,K.undefined()])),getCurrentBaseFees:K.function().returns(qr.schema),simulateUnconstrained:K.function().args(K.string(),K.array(K.any()),Be.AztecAddress,ua(K.array(Oc.schema)),ua(Be.AztecAddress),ua(K.array(Be.AztecAddress))).returns(Fb),getPublicLogs:K.function().args(p2).returns(bq),getContractClassLogs:K.function().args(p2).returns(gq),getBlockNumber:K.function().returns(K.number()),getProvenBlockNumber:K.function().returns(K.number()),getNodeInfo:K.function().returns(mq),getPXEInfo:K.function().returns(lwe),getContractMetadata:K.function().args(Be.AztecAddress).returns(swe),getContractClassMetadata:K.function().args(Be.Fr,ua(K.boolean())).returns(owe),getPrivateEvents:K.function().args(yq,K.number(),K.number(),K.array(Be.Point)).returns(K.array(Fb)),getPublicEvents:K.function().args(yq,K.number(),K.number()).returns(K.array(Fb))};
2126class vq extends Error{}function*uwe(){const e=[1,1,1,2,4,8,16,32,64];let t=0;for(;;)yield e[Math.min(t++,e.length-1)]}function*fwe(e){for(const t of e)yield t}async function hwe(e,t="Operation",r=uwe(),n=V0("foundation:retry"),i=!1){for(;;)try{return await e()}catch(a){if(a instanceof vq)throw a;const s=r.next().value;if(s===void 0)throw a;n.verbose(`${t} failed. Will retry in ${s}s...`),!i&&n.error(`Error while retrying ${t}`,a),await yve(s*1e3);continue}}const dwe=V0("json-rpc:json_rpc_client");async function wq(e,t,r,n,i={},a=!1){dwe.debug(ct.format("JsonRpcClient.fetch",e,t,"->",r));let s;try{n?s=await fetch(`${e}/${t}`,{method:"POST",body:hk(r),headers:{"content-type":"application/json",...i}}):s=await fetch(e,{method:"POST",body:hk({...r,method:t}),headers:{"content-type":"application/json",...i}})}catch(c){const l=`Error fetching from host ${e} with method ${t}: ${ct.inspect(c)}`;throw new Error(l)}let o;try{o=await s.json()}catch{throw s.ok?new Error(`Failed to parse body as JSON: ${s.text()}`):new Error(s.statusText)}if(!s.ok){const c=`Error ${s.status} from server ${e} on ${t}: ${o.error.message}`;throw a||s.status>=400&&s.status<500?new vq(c):new Error(c)}return{response:o,headers:s.headers}}function pwe(e,t,r){return async(n,i,a,s,o={},c)=>await hwe(()=>wq(n,i,a,s,o,c??t),`JsonRpcClient request ${i} to ${n}`,fwe(e),r,!1)}function mwe(e,t,r={}){const n=r.fetch??wq,i=r.log??V0("json-rpc:client"),{useApiEndpoints:a=!1,namespaceMethods:s=!1}=r;let o=0;const c=async(u,d)=>{if(!Fge(t,u))throw new Error(`Unspecified method ${u} in client schema`);const p=s?`${s}_${u}`:u,w={jsonrpc:"2.0",id:o++,method:p,params:d};i.debug(ct.format("request",p,d));const{response:O,headers:I}=await n(e,p,w,a);if(i.debug(ct.format("result",p,O)),r.onResponse&&await r.onResponse({response:O,headers:I}),O.error)throw O.error;if(![null,void 0,"null","undefined"].includes(O.result))return t[u].returnType().parseAsync(O.result)},l={};for(const u of Object.keys(t))l[u]=(...d)=>c(u,d);return l}const gwe=K.enum(["block-mined","block-proposed","block-missed","attestation-sent","attestation-missed"]),xq=K.array(K.object({slot:He.BigInt,status:gwe})),bwe=K.array(xq);K.record(bwe);const _q=K.object({timestamp:He.BigInt,slot:He.BigInt,date:K.string()}),Sq=K.object({currentStreak:He.Integer,rate:K.number(),count:He.Integer}),ywe=K.object({address:He.EthAddress,lastProposal:_q.optional(),lastAttestation:_q.optional(),totalSlots:He.Integer,missedProposals:Sq,missedAttestations:Sq,history:xq}),vwe=K.object({stats:K.record(ywe),lastProcessedSlot:He.BigInt.optional(),initialSlot:He.BigInt.optional(),slotWindow:He.Integer});class wwe extends Error{constructor(t,r,n){super(`Expected component version ${t} to be ${r} but received ${n}`),this.name="ComponentsVersionsError"}}function xwe(e){return({headers:t})=>{for(const r in e){const n=e[r];if(n!==void 0){const i=t.get(`x-aztec-${r}`);if(i!=null&&i!==n.toString())throw new wwe(r,n.toString(),i)}}return Promise.resolve()}}const _we=K.object({finalisedBlockNumber:K.number().int().nonnegative(),latestBlockNumber:K.number().int().nonnegative(),latestBlockHash:K.string(),oldestHistoricBlockNumber:K.number().int().nonnegative(),treesAreSynched:K.boolean()});K.function().args().returns(vve),K.function().args().returns(_we),K.function().args(us,K.nativeEnum(Ao),K.array(Be.Fr)).returns(K.array(ua($k(Be.BigInt)))),K.function().args(us,Be.BigInt).returns(An.schemaFor(ok)),K.function().args(us,Be.BigInt).returns(An.schemaFor(zge)),K.function().args(us,Be.Fr).returns(K.tuple([Be.BigInt,An.schemaFor(iL)]).optional()),K.function().args(Be.Fr).returns(K.boolean()),K.function().args(us,Be.Fr).returns(K.tuple([Be.BigInt,An.schema])),K.function().args(us,Be.BigInt).returns(An.schemaFor(Pge)),K.function().args(us,Be.BigInt).returns(An.schemaFor(Hx)),K.function().args(us,Be.Fr).returns(Pb.schema.optional()),K.function().args(us,Be.Fr).returns(Pb.schema.optional()),K.function().args(us,Be.Fr).returns(X0.schema.optional()),K.function().args(us).returns(Ol.schema.optional()),K.function().returns(K.number()),K.function().returns(K.number()),K.function().returns(K.boolean()),K.function().returns(mq),K.function().args(K.number(),K.number()).returns(K.array(Ol.schema)),K.function().args(K.number(),K.number()).returns(K.array(wve)),K.function().returns(qr.schema),K.function().returns(K.string()),K.function().returns(K.number()),K.function().returns(K.number()),K.function().returns(pq),K.function().returns(oE),K.function().args(Be.AztecAddress,K.array(K.string())).returns(K.void()),K.function().args(K.number(),K.number()).returns(K.array(Hn.schema)),K.function().args(p2).returns(bq),K.function().args(p2).returns(gq),K.function().args(K.array(Be.Fr)).returns(K.array(K.array(u1.schema))),K.function().args(No.schema).returns(K.void()),K.function().args(Er.schema).returns(up.schema),K.function().args(Er.schema).returns($k(Ri.schema).optional()),K.function().returns(K.array(No.schema)),K.function().returns(K.number()),K.function().args(Er.schema).returns(No.schema.optional()),K.function().args(K.array(Er.schema)).returns(K.array(No.schema)),K.function().args(us,Be.AztecAddress,Be.Fr).returns(Be.Fr),K.function().args(ua(us)).returns(Xr.schema.optional()),K.function().returns(vwe),K.function().args(No.schema,ua(K.boolean())).returns(pp.schema),K.function().args(No.schema,ua(K.object({isSimulation:ua(K.boolean()),skipFeeEnforcement:ua(K.boolean())}))).returns(hve),K.function().args(Be.Fr).returns(nwe.optional()),K.function().args(Be.AztecAddress).returns(sE.optional()),K.function().returns(K.string().optional());const Swe=K.union([K.object({address:Be.AztecAddress,selector:Be.FunctionSelector}),K.object({address:Be.AztecAddress}),K.object({classId:Be.Fr,selector:Be.FunctionSelector}),K.object({classId:Be.Fr})]),kwe=K.object({transactionPollingIntervalMS:K.number().optional(),maxTxsPerBlock:K.number().optional(),minTxsPerBlock:K.number().optional(),maxL2BlockGas:K.number().optional(),maxDABlockGas:K.number().optional(),coinbase:Be.EthAddress.optional(),feeRecipient:Be.AztecAddress.optional(),acvmWorkingDirectory:K.string().optional(),acvmBinaryPath:K.string().optional(),allowedInSetup:K.array(Swe).optional(),maxBlockSizeInBytes:K.number().optional(),governanceProposerPayload:Be.EthAddress.optional(),maxL1TxInclusionTimeIntoSlot:K.number().optional(),enforceTimeTable:K.boolean().optional()}),Ewe=K.object({nodeUrl:K.string().optional(),realProofs:K.boolean(),proverId:Be.Fr,proverTestDelayType:K.enum(["fixed","realistic"]),proverTestDelayMs:K.number(),proverTestDelayFactor:K.number(),proverAgentC
vendor: 6,498 bytes, line 2126
2126ount:K.number()});({...Ype(!0)},le.ZERO),{...CS(0)},{...CS(1)},{...CS(1)};function i3e(e){return le.fromHexString(e.startsWith("0x")?e:je.from(e,"utf8").toString("hex"))}K.function().args(kwe.merge(Ewe).partial()).returns(K.void()),K.function().returns(K.void()),K.function().args(K.string()).returns(K.void()),new le(1),new le(1),new le(1),new le(1),new le(1),new le(1),nt.fromBigInt(1n),nt.fromBigInt(2n),nt.fromBigInt(3n),nt.fromBigInt(4n),nt.fromBigInt(5n),nt.fromBigInt(6n),le.fromHexString("0x2ce2fff4f09f246b769ca0d2f7f05a20cfbf1d507f05782a27fa4bb088cf7ccf"),le.fromHexString("0x0738fc15e7f87fda14367d93cb7c1a83e355b5ac2b185a578aac966c3d946849"),le.fromHexString("0x01e684c0d5fa33d11baba49b5e6691c2af85c4b109b2f31bdb1532e11c3af106"),le.fromHexString("0x00b97ee571f03e87217241732ceb5c16df993569ead7e9dcec10f86254e81989"),le.fromHexString("0x2f2a0525989e3b439d631f6e641097d6003e9dc29652241b7c7bcfcf84a4e97f"),le.fromHexString("0x0f684f47de2f37df362ea798e33773aab5dce8a30da3692e073449fe78f0cac5");const Mwe=le.fromHexString("0x1308fb8fbb9de77db373b5795de91d429401ab9b59203ecb830c58439da040c2");le.fromHexString("0x20cd27645f65c15a38720ca984aef936592f3938a705db706d068ad13fc58ae9"),le.fromHexString("0x0abf338154e355442d9916d630da0491036d5a7b23c42b477c1395ba3bf9b42d"),le.fromHexString("0x27774539896271d6dbe0c1de45ddc44709d1e8d9a9fb686ca3c105d87c417bb8"),le.fromHexString("0x2ec28b91a5f838506d6042915005ff55cf7a0a5f889a83b11faed33a31b486f2"),new le(0xe92f9f8a534e858fcf777da206e08b0c620ecf9deb21d13479813f6n);function Bl(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}function kq(e,t){for(var r="",n=0,i=-1,a=0,s,o=0;o<=e.length;++o){if(o<e.length)s=e.charCodeAt(o);else{if(s===47)break;s=47}if(s===47){if(!(i===o-1||a===1))if(i!==o-1&&a===2){if(r.length<2||n!==2||r.charCodeAt(r.length-1)!==46||r.charCodeAt(r.length-2)!==46){if(r.length>2){var c=r.lastIndexOf("/");if(c!==r.length-1){c===-1?(r="",n=0):(r=r.slice(0,c),n=r.length-1-r.lastIndexOf("/")),i=o,a=0;continue}}else if(r.length===2||r.length===1){r="",n=0,i=o,a=0;continue}}t&&(r.length>0?r+="/..":r="..",n=2)}else r.length>0?r+="/"+e.slice(i+1,o):r=e.slice(i+1,o),n=o-i-1;i=o,a=0}else s===46&&a!==-1?++a:a=-1}return r}function Awe(e,t){var r=t.dir||t.root,n=t.base||(t.name||"")+(t.ext||"");return r?r===t.root?r+n:r+e+n:n}var d1={resolve:function(){for(var e="",t=!1,r,n=arguments.length-1;n>=-1&&!t;n--){var i;n>=0?i=arguments[n]:(r===void 0&&(r=ot.cwd()),i=r),Bl(i),i.length!==0&&(e=i+"/"+e,t=i.charCodeAt(0)===47)}return e=kq(e,!t),t?e.length>0?"/"+e:"/":e.length>0?e:"."},normalize:function(e){if(Bl(e),e.length===0)return".";var t=e.charCodeAt(0)===47,r=e.charCodeAt(e.length-1)===47;return e=kq(e,!t),e.length===0&&!t&&(e="."),e.length>0&&r&&(e+="/"),t?"/"+e:e},isAbsolute:function(e){return Bl(e),e.length>0&&e.charCodeAt(0)===47},join:function(){if(arguments.length===0)return".";for(var e,t=0;t<arguments.length;++t){var r=arguments[t];Bl(r),r.length>0&&(e===void 0?e=r:e+="/"+r)}return e===void 0?".":d1.normalize(e)},relative:function(e,t){if(Bl(e),Bl(t),e===t||(e=d1.resolve(e),t=d1.resolve(t),e===t))return"";for(var r=1;r<e.length&&e.charCodeAt(r)===47;++r);for(var n=e.length,i=n-r,a=1;a<t.length&&t.charCodeAt(a)===47;++a);for(var s=t.length,o=s-a,c=i<o?i:o,l=-1,u=0;u<=c;++u){if(u===c){if(o>c){if(t.charCodeAt(a+u)===47)return t.slice(a+u+1);if(u===0)return t.slice(a+u)}else i>c&&(e.charCodeAt(r+u)===47?l=u:u===0&&(l=0));break}var d=e.charCodeAt(r+u),p=t.charCodeAt(a+u);if(d!==p)break;d===47&&(l=u)}var w="";for(u=r+l+1;u<=n;++u)(u===n||e.charCodeAt(u)===47)&&(w.length===0?w+="..":w+="/..");return w.length>0?w+t.slice(a+l):(a+=l,t.charCodeAt(a)===47&&++a,t.slice(a))},_makeLong:function(e){return e},dirname:function(e){if(Bl(e),e.length===0)return".";for(var t=e.charCodeAt(0),r=t===47,n=-1,i=!0,a=e.length-1;a>=1;--a)if(t=e.charCodeAt(a),t===47){if(!i){n=a;break}}else i=!1;return n===-1?r?"/":".":r&&n===1?"//":e.slice(0,n)},basename:function(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Bl(e);var r=0,n=-1,i=!0,a;if(t!==void 0&&t.length>0&&t.length<=e.length){if(t.length===e.length&&t===e)return"";var s=t.length-1,o=-1;for(a=e.length-1;a>=0;--a){var c=e.charCodeAt(a);if(c===47){if(!i){r=a+1;break}}else o===-1&&(i=!1,o=a+1),s>=0&&(c===t.charCodeAt(s)?--s===-1&&(n=a):(s=-1,n=o))}return r===n?n=o:n===-1&&(n=e.length),e.slice(r,n)}else{for(a=e.length-1;a>=0;--a)if(e.charCodeAt(a)===47){if(!i){r=a+1;break}}else n===-1&&(i=!1,n=a+1);return n===-1?"":e.slice(r,n)}},extname:function(e){Bl(e);for(var t=-1,r=0,n=-1,i=!0,a=0,s=e.length-1;s>=0;--s){var o=e.charCodeAt(s);if(o===47){if(!i){r=s+1;break}continue}n===-1&&(i=!1,n=s+1),o===46?t===-1?t=s:a!==1&&(a=1):t!==-1&&(a=-1)}return t===-1||n===-1||a===0||a===1&&t===n-1&&t===r+1?"":e.slice(t,n)},format:function(e){if(e===null||typeof e!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof e);return Awe("/",e)},parse:function(e){Bl(e);var t={root:"",dir:"",base:"",ext:"",name:""};if(e.length===0)return t;var r=e.charCodeAt(0),n=r===47,i;n?(t.root="/",i=1):i=0;for(var a=-1,s=0,o=-1,c=!0,l=e.length-1,u=0;l>=i;--l){if(r=e.charCodeAt(l),r===47){if(!c){s=l+1;break}continue}o===-1&&(c=!1,o=l+1),r===46?a===-1?a=l:u!==1&&(u=1):a!==-1&&(u=-1)}return a===-1||o===-1||u===0||u===1&&a===o-1&&a===s+1?o!==-1&&(s===0&&n?t.base=t.name=e.slice(1,o):t.base=t.name=e.slice(s,o)):(s===0&&n?(t.name=e.slice(1,a),t.base=e.slice(1,o)):(t.name=e.slice(s,a),t.base=e.slice(s,o)),t.ext=e.slice(a,o)),s>0?t.dir=e.slice(0,s-1):n&&(t.dir="/"),t},sep:"/",delimiter:":",win32:null,posix:null};d1.posix=d1;function Cwe(e,t={},r=pwe([1,2,3],!1)){return mwe(e,cwe,{namespaceMethods:"pxe",fetch:r,onResponse:xwe({l2ProtocolContractsTreeRoot:Mwe.toString(),...t})})}const Eq=e=>{const t="http://188.40.109.171:8080/";return{readContract:async()=>{const r=await Cwe(t),n=await r.getContractArtifact("0x29022b95dec76fd6851092ed6dc917c38f5d5a35576e4e750b220f9ac23a66cd");console.log(n);const{l1ChainId:i}=await r.getNodeInfo();console.log(`Connected to chain ${i}`),console.log("UserAccounts:",await r.getRegisteredAccounts())}}},Twe=({addressInfo:e,isLoading:t})=>{var R;const r=["bytecode","read","write"],n=to(),i=g6(),[a,s]=he.useState("bytecode");he.useEffect(()=>{const C=n.hash.replace("#","");C?r.includes(C)?s(C):(i("#bytecode",{replace:!0}),s("bytecode")):(i("#bytecode",{replace:!0}),s("bytecode"))},[n,i]);const o=r.map(C=>
2126({key:C,label:C.charAt(0).toUpperCase()+C.slice(1),to:`#${C}`})),[c,l]=he.useState("hex"),[u,d]=he.useState([]),p=he.useRef([]),{readContract:w}=Eq();he.useEffect(()=>{!a||!(e!=null&&e.functions)||(p.current=p.current.slice(0,e.functions.length))},[(R=e==null?void 0:e.functions)==null?void 0:R.length]);const O=()=>{const C=()=>{if(!(e!=null&&e.byteCode))return"[]";const j=e.byteCode,N="0x"+je.from(j,"binary").toString("hex"),P=je.from(j,"binary").toString("base64"),Z=[...je.from(j,"binary")].map(X=>X.toString(2).padStart(8,"0")).join(" ");if(c==="hex")return N;if(c==="base64")return P;if(c==="binary")return Z};return M.jsx("div",{className:"flex flex-col gap-5 p-6",children:M.jsx("textarea",{className:`w-full h-52 p-4 border border-surface-border bg-surface-card rounded-xl resize-y leading-7 font-mono text-sm focus:outline-none focus:border-brand-purple/50 transition-colors ${e!=null&&e.byteCode?"text-text-primary":"text-text-muted"}`,value:C(),readOnly:!0})})},I=C=>{var P;if(((P=e==null?void 0:e.functions)==null?void 0:P.length)===0||!(e!=null&&e.functions))return M.jsx("div",{className:"flex flex-col items-center justify-center w-full h-64 p-6",children:M.jsxs("p",{className:"text-text-muted font-normal text-sm",children:["No ",C," functions found"]})});let j=0;const N=e.functions.map((Z,X)=>{var re;if(C==="read"&&Z.isStatic||C==="write"&&!Z.isStatic){j++;const ne=u.includes(X),ae=()=>{d(ue=>ne?ue.filter(m=>m!==X):[...ue,X])};return M.jsxs("div",{className:"border border-surface-border rounded-xl overflow-hidden bg-surface-card hover:border-brand-purple/30 transition-colors",children:[M.jsxs("div",{onClick:ae,className:"flex items-center justify-between px-4 py-3 cursor-pointer hover:bg-surface-hover transition-colors",children:[M.jsxs("div",{className:"flex items-center gap-3",children:[M.jsxs("span",{className:"text-sm font-medium text-text-primary",children:[j,". ",Z.name]}),M.jsx(vr,{variant:Z.functionType==="private"?"warning":Z.functionType==="public"?"success":"default",children:Z.functionType})]}),M.jsx("span",{className:"text-text-muted",children:M.jsx(yu,{size:20,className:`transition-transform duration-300 ${ne?"rotate-90":""}`})})]}),M.jsx("div",{ref:ue=>p.current[X]=ue,className:"transition-all duration-300 ease-in-out overflow-hidden",style:{height:ne?`${(re=p.current[X])==null?void 0:re.scrollHeight}px`:"0px"},children:M.jsxs("div",{className:"px-4 pb-4 pt-2 flex flex-col gap-4 border-t border-surface-border",children:[(Z==null?void 0:Z.parameters)&&Z.parameters.map(ue=>M.jsxs("div",{className:"flex flex-col gap-2",children:[M.jsxs("div",{className:"flex items-center gap-2 text-sm",children:[M.jsx("span",{className:"text-text-primary font-medium",children:ue.name}),M.jsx(vr,{variant:ue.visibility==="private"?"warning":"success",size:"sm",children:ue.visibility})]}),M.jsx(Vr,{placeholder:`[${Object.values(ue.type).toString().replaceAll(",","]  [")}]`,className:"font-mono text-sm"})]},ue.name)),M.jsx(St,{onClick:async()=>{await w()},variant:"primary",size:"sm",className:"w-fit",children:"Read"})]})})]},Z.name)}});return j===0?M.jsx("div",{className:"flex flex-col items-center justify-center w-full h-64 p-6",children:M.jsxs("p",{className:"text-text-muted font-normal text-sm",children:["No ",C," functions found"]})}):M.jsx("div",{className:"flex flex-col gap-3 p-6",children:N})};return M.jsxs(ch,{variant:"flat",padding:"none",className:"w-full",children:[M.jsxs("div",{className:"flex items-center justify-between gap-2 p-4 border-b border-surface-border",children:[M.jsx(Sg,{items:o,activeKey:a,roundness:"full",size:"sm",className:"w-min bg-surface-main"}),M.jsxs("select",{id:"view-selector",className:"w-[130px] h-8 pl-3 pr-8 py-2 border text-xs border-surface-border bg-surface-main text-text-primary rounded-md focus:outline-none focus:border-brand-purple/50 transition-colors [background-position:right_0.5rem_center]",value:c,onChange:C=>l(C.target.value),children:[M.jsx("option",{value:"hex",children:"Hexadecimal"}),M.jsx("option",{value:"base64",children:"Base64"}),M.jsx("option",{value:"binary",children:"Binary"})]})]}),a==="bytecode"?O():I(a)]})},jwe=()=>{const[e,t]=he.useState(null),{hash:r}=$d(),{network:n}=di(),i=Vn({queryKey:["address",r,n],queryFn:()=>uY(r,n),enabled:!!r,onError:o=>{console.error("Failed to fetch address:",o),t("Failed to fetch address. Please try again later.")}}),a=i.data||[],s=i.isLoading;return M.jsxs(M.Fragment,{children:[M.jsx(Ms,{route:"/addresses"}),M.jsxs("div",{className:"px-[6.5vw] py-[73px] w-full flex flex-col gap-4",children:[M.jsx(Ts,{variant:"detail",title:"Address",showSearchBar:!0}),e?M.jsx(pi,{message:e,type:"general_error"}):!i.isLoading&&!i.data?M.jsx(pi,{message:"Address Not Found",type:"not_found",currentNetwork:n.name}):M.jsxs("div",{className:"flex flex-col w-full gap-8",children:[M.jsx(Mie,{addressInfo:a,isLoading:s}),M.jsx(Twe,{addressInfo:a,isLoading:s})]})]})]})},p1=(e,t)=>{const[r,n]=he.useState(1),[i,a]=he.useState(20),[s,o]=he.useState(),c=[20,50,100];he.useEffect(()=>{n(1)},[t]),he.useEffect(()=>{const u=Math.ceil(e/i)||1;r>u&&n(u)},[e,i,r]);const l=Math.ceil(e/i)||1;return{page:r,limit:i,renderPaginationButtons:()=>M.jsxs("div",{className:"flex pt-2 w-full justify-between items-center text-[10px] font-medium below-mobile:justify-center",children:[M.jsxs("div",{className:"flex gap-2 items-center below-mobile:hidden",children:[M.jsx("span",{className:"text-text-muted",children:"Show rows:"}),M.jsx("select",{value:i,onChange:u=>a(Number(u.target.value)),className:"bg-surface-card border border-surface-border text-text-primary px-3 h-7 rounded-md hover:border-brand-purple/50 transition-colors cursor-pointer focus:outline-none focus:border-brand-purple/50",children:c.map(u=>M.jsx("option",{value:u,children:u},u))})]}),M.jsxs("div",{className:"flex gap-2 items-center",children:[M.jsx("span",{className:"text-text-muted",children:"Go to:"}),M.jsx(Vr,{placeholder:r.toString(),onChange:u=>{const d=u.target.value;/^\d+$/.test(d)&&Number(d)>0&&o(d<=l?d:l)},onKeyDown:u=>{u.key==="Enter"&&s!==void 0&&(n(Number(s)),u.target.blur())},onBlur:()=>{s!==void 0&&n(Number(s))},className:"bg-surface-card border-surface-border text-text-primary h-7 rounded-md w-12 text-center px-2",size:"sm"}),M.jsx(St,{onClick:()=>n(1),disabled:r===1,variant:"ghost",roundness:"soft",className:"!w-7 !h-7 !px-0 !min-w-0 !text-brand-purple",children:M.jsxs("div",{className:"flex items-center",children:[M.jsx(yu,{className:"w-3 h-3 rotate-180"}),M.jsx(yu,{className:"w-3 h-3 rotate-180 -ml-2"})]})}),M.jsx(St,{onClick:()=>n(r-1),disabled:r===1,variant:"ghost",roundness:"soft",className:"!w-7 !h-7 !px-0 !min-w-0 !text-brand-purple",children:M.jsx(yu,{className:"w-3.5 h-3.5 rotate-180"})}),M.jsxs("div",{className:"bg-surface-card border border-surface-border text-text-primary px-3 h-7 rounded-md flex items-center",children:[r," of ",l]}),M.jsx(St,{onClick:()=>n(r+1),disabled:r===l,variant:"ghost",roundness:"soft",className:"!w-7 !h-7 !px-0 !min-w-0 !text-brand-purple",children:M.jsx(yu,{className:"w-3.5 h-3.5"})}),M.jsx(St,{onClick:()=>n(l),disabled:r===l,variant:"ghost",roundness:"soft",className:"!w-7 !h-7 !px-0 !min-w-0 !text-brand-purple",children:M.jsxs("div",{className:"flex items-center",children:[M.jsx(yu,{className:"w-3 h-3"}),M.jsx(yu,{className:"w-3 h-3 -ml-2"})]})})]})]})}},Iwe=()=>{var re,ne,ae;const[e,t]=he.useState(null);ZT();const{network:r}=di(),{renderFilterElement:n,renderFilterButton:i,renderFilterIndicators:a,filters:s,setFilters:o,setSort:c,currentSort:l,isFilterPanelOpen:u,setIsFilterPanelOpen:d}=Eg(),p=Vn({queryKey:["latestBlockNumber",s,r],queryFn:()=>lY(r),onError:ue=>{console.error("Failed to fetch latest block number:",ue),t("Failed to fetch latest block number. Please try again later.")}}),w=(re=p.data)==null?void 0:re.count,[O,I]=he.useState(1),[R,C]=he.useState(20),j=Vn({queryKey:["blocks",O,R,s,r],queryFn:()=>VC(O,R,s,r),enabled:!!w,onError:ue=>{console.error("Failed to fetch blocks:",ue),t("Failed to fetch blocks. Please try again later.")}}),N=((ne=j.data)==null?void 0:ne.total)||w;console.log(N);const{page:P,limit:Z,renderPaginationButtons:X}=p1(N,s);return he.useEffect(()=>{I(P),C(Z)},[P,Z]),M.jsxs(M.Fragment,{children:[M.jsx(Ms,{route:"/blocks"}),M.jsxs("div",{className:"px-[6.5vw] py-[73px] w-full below-lg:py-[40px] below-lg:px-0",children:[M.jsx(Ts,{variant:"list",title:"Blocks",totalCount:N,itemLabel:"Blocks",isLoading:!w,showSearchBar:!0,filterIndicators:a("flex-1 mr-2"),filterButton:i()}),M.jsx(ac,{data:((ae=j.data)==null?void 0:ae.blocks)||[],columns:[{key:"hash",label:"Hash",width:"23%",type:"hash",cellClassName:"",mobile:{order:2,showLabel:!0}},{key:"number",label:"Number",width:"15%",type:"number",sortable:!0,sortKey:"number",cellClassName:"overflow-hidden text-ellipsis flex items-center",mobile:{order:1,prominent:!0}},{key:"timestamp",label:"Age",width:"12%",type:"timestamp",sortable:!0,sortKey:"timestamp",cellClassName:"",mobile:{order:3,showLabel:!0}},{key:"txCount",label:"Tx Count",width:"10%",type:"count",sortable:!0,sortKey:"txCount",cell
2126ClassName:"",mobile:!1},{key:"finalityStatus",label:"Status",width:"18%",type:"status",cellClassName:"overflow-hidden text-ellipsis font-mono",mobile:{order:4,showLabel:!1}},{key:"totalFees",label:"Fee",width:"12%",type:"fee",sortable:!0,sortKey:"totalFees",cellClassName:"",mobile:{order:5,showLabel:!0}}],variant:"detailed",loading:p.isLoading||j.isLoading,error:e,sortable:!0,currentSort:l,onSort:c,filters:s,setFilters:o,filterTypes:["timestamp","txCount","fee"],isFilterPanelOpen:u,setIsFilterPanelOpen:d,limit:Z}),X()]})]})},Owe=()=>{var re,ne,ae;const[e,t]=he.useState(null),[r,n]=he.useState(1),[i,a]=he.useState(10),{network:s}=di(),{renderFilterElement:o,renderFilterButton:c,renderFilterIndicators:l,filters:u,setFilters:d,setSort:p,currentSort:w,isFilterPanelOpen:O,setIsFilterPanelOpen:I}=Eg(),R=Vn({queryKey:["totalTxCount",u,s],queryFn:()=>cY(s),onError:ue=>{console.error("Failed to fetch total transaction count:",ue),t("Failed to fetch total transaction count. Please try again later.")}}),C=(re=R.data)==null?void 0:re.count,j=Vn({queryKey:["transactions",r,i,u,s],queryFn:()=>HC(r,i,u,s),enabled:!!C,onError:ue=>{console.error("Failed to fetch transactions:",ue),t("Failed to fetch transactions. Please try again later.")}}),N=((ne=j.data)==null?void 0:ne.total)||C,{page:P,limit:Z,renderPaginationButtons:X}=p1(N,u);return he.useEffect(()=>{n(P),a(Z)},[P,Z]),M.jsxs(M.Fragment,{children:[M.jsx(Ms,{route:"/transactions"}),M.jsxs("div",{className:"px-[6.5vw] py-[73px] w-full below-lg:py-[40px] below-lg:px-0",children:[M.jsx(Ts,{variant:"list",title:"Transactions",totalCount:N,itemLabel:"Transactions",isLoading:!N,showSearchBar:!0,filterIndicators:l("flex-1 mr-2"),filterButton:c()}),M.jsx(ac,{data:((ae=j.data)==null?void 0:ae.transactions)||[],columns:[{key:"hash",label:"Hash",width:"15%",type:"hash",cellClassName:"",mobile:{order:1,showLabel:!0}},{key:"blockNumber",label:"Block",width:"10%",type:"number",sortable:!0,sortKey:"blockNumber",mobile:{order:2,showLabel:!0}},{key:"timestamp",label:"Age",width:"10%",type:"timestamp",sortable:!0,sortKey:"timestamp",cellClassName:"",mobile:{order:3,showLabel:!0}},{key:"index",label:"Index",width:"5%",type:"count",sortable:!0,sortKey:"index",cellClassName:"",mobile:!1},{key:"hash",label:"Nullifier",width:"32%",type:"nullifier",cellClassName:" max-w-full overflow-ellipsis overflow-hidden",mobile:!1},{key:"transactionFee",label:"Fee",width:"10%",type:"fee",sortable:!0,sortKey:"transactionFee",cellClassName:"",mobile:{order:4,showLabel:!0}}],variant:"detailed",loading:R.isLoading||j.isLoading,error:e,sortable:!0,currentSort:w,onSort:p,filters:u,setFilters:d,filterTypes:["timestamp","blockNumber","index","txFee"],isFilterPanelOpen:O,setIsFilterPanelOpen:I,limit:Z}),X()]})]})},Bwe=()=>{var Z,X,re;const[e,t]=he.useState(null),{network:r}=di(),{renderFilterElement:n,renderFilterButton:i,renderFilterIndicators:a,filters:s,setFilters:o,setSort:c,currentSort:l,isFilterPanelOpen:u,setIsFilterPanelOpen:d}=Eg(),p=Vn({queryKey:["accountCount",s,r],queryFn:()=>hY(r),onError:ne=>{console.error("Failed to fetch account count:",ne),t("Failed to fetch account count. Please try again later.")}}),w=(Z=p.data)==null?void 0:Z.count,{page:O,limit:I,renderPaginationButtons:R}=p1(w,s),C=Vn({queryKey:["addresses",O,I,s,r],queryFn:()=>fY(O,I,s,r),enabled:!!w,onError:ne=>{console.error("Failed to fetch accounts:",ne),t("Failed to fetch accounts. Please try again later.")}}),j=((X=C.data)==null?void 0:X.total)||w,N=((re=C.data)==null?void 0:re.accounts)||[],P=p.isLoading||C.isLoading;return M.jsxs(M.Fragment,{children:[M.jsx(Ms,{route:"/addresses"}),M.jsxs("div",{className:"px-[6.5vw] py-[73px] w-full  below-lg:py-[40px] below-lg:px-0",children:[M.jsx(Ts,{variant:"list",title:"Addresses",totalCount:j,itemLabel:"Addresses",isLoading:!j,showSearchBar:!0,filterIndicators:a("flex-1 mr-2"),filterButton:i()}),M.jsx(ac,{data:N,columns:[{key:"address",label:"Address",width:"30%",type:"address",cellClassName:"",mobile:{order:1,showLabel:!0}},{key:"contractClassID",label:"Contract Class",width:"20%",type:"hash",linkTo:ne=>`/class/${ne}`,cellClassName:"text-brand-yellow/90",mobile:{order:2,showLabel:!0}},{key:"blockNumber",label:"Block Number",width:"15%",type:"number",sortable:!0,sortKey:"blockNumber",cellClassName:"",mobile:{order:3,showLabel:!0}},{key:"creationTimestamp",label:"Created",width:"15%",type:"timestamp",sortable:!0,sortKey:"creationTimestamp",cellClassName:"",mobile:{order:4,showLabel:!0}},{key:"balance",label:"Balance",width:"10%",type:"fee",cellClassName:"",mobile:{order:5,showLabel:!0}}],variant:"detailed",loading:P,error:e,sortable:!0,currentSort:l,onSort:c,filters:s,setFilters:o,filterTypes:["blockNumber","creationTimestamp","version"],isFilterPanelOpen:u,setIsFilterPanelOpen:d,limit:I}),R()]})]})},Rwe=he.lazy(()=>new Promise(e=>{setTimeout(()=>{e(f4(()=>import("./networkIframe-AjBCNy7b.js"),[]))},100)})),Nwe=()=>{const e="Network Status | Aztec Explorer",t="View the real-time status and metrics of the Aztec Network. Monitor network health, performance, and other key statistics.",[r,n]=he.useState(!1);return he.useEffect(()=>{n(!0)},[]),M.jsxs(M.Fragment,{children:[M.jsx(Ms,{title:e,description:t}),M.jsxs("div",{className:"h-full w-full flex flex-col gap-4 px-4 py-6 ",children:[M.jsx(Ts,{variant:"detail",title:"Network Status",subtitle:M.jsx("a",{target:"_blank",rel:"noopener noreferrer",href:"https://network.aztecexplorer.xyz/",className:"text-textGray text-[12px] underline hover:text-pastelPink dark:hover:text-pastelBlue",children:"https://network.aztecexplorer.xyz"}),showSearchBar:!0}),M.jsx("div",{className:"w-full h-[70vh] border border-borderGray rounded-[20px] p-2 overflow-hidden",children:r?M.jsx(he.Suspense,{fallback:M.jsx("div",{className:"w-full h-full flex flex-col items-center justify-center gap-4",children:M.jsx(Qr,{className:"rounded-xl"})}),children:r&&M.jsx(Rwe,{})}):null})]})]})}
2126,Fwe=()=>{var Z,X,re;const[e,t]=he.useState(null),{network:r}=di(),{renderFilterElement:n,renderFilterButton:i,renderFilterIndicators:a,filters:s,setFilters:o,setSort:c,currentSort:l,isFilterPanelOpen:u,setIsFilterPanelOpen:d}=Eg(),p=Vn({queryKey:["classCount",s,r],queryFn:()=>mY(r),onError:ne=>{console.error("Failed to fetch class count:",ne),t("Failed to fetch class count. Please try again later.")}}),w=(Z=p.data)==null?void 0:Z.count,{page:O,limit:I,renderPaginationButtons:R}=p1(w,s),C=Vn({queryKey:["classes",O,I,s,r],queryFn:()=>pY(O,I,s,r),enabled:!!w,onError:ne=>{console.error("Failed to fetch classes:",ne),t("Failed to fetch classes. Please try again later.")}}),j=((X=C.data)==null?void 0:X.total)||w,N=((re=C.data)==null?void 0:re.contractClasses)||[],P=p.isLoading||C.isLoading;return M.jsxs(M.Fragment,{children:[M.jsx(Ms,{route:"/classes"}),M.jsxs("div",{className:"px-[6.5vw] py-[73px] w-full  below-lg:py-[40px] below-lg:px-0",children:[M.jsx(Ts,{variant:"list",title:"Classes",totalCount:j,itemLabel:"Classes",isLoading:!j,showSearchBar:!0,filterIndicators:a("flex-1 mr-2"),filterButton:i()}),M.jsx(ac,{data:N,columns:[{key:"id",label:"Class ID",width:"30%",type:"hash",cellClassName:"",mobile:{order:1,showLabel:!0}},{key:"artifactHash",label:"Artifact Hash",width:"20%",type:"hash",linkTo:null,cellClassName:"text-text-primary",mobile:{order:5,showLabel:!0}},{key:"blockNumber",label:"Block",width:"8%",type:"number",sortable:!0,sortKey:"blockNumber",cellClassName:"",mobile:{order:3,showLabel:!0}},{key:"creationTimestamp",label:"Age",width:"8%",type:"timestamp",sortable:!0,sortKey:"creationTimestamp",cellClassName:"",mobile:{order:2,showLabel:!0}},{key:"version",label:"Version",width:"7%",type:"fee",sortable:!0,sortKey:"version",cellClassName:"flex items-center justify-center",mobile:{order:4,showLabel:!0}}],variant:"detailed",loading:P,error:e,sortable:!0,currentSort:l,onSort:c,filters:s,setFilters:o,filterTypes:["blockNumber","creationTimestamp","version"],isFilterPanelOpen:u,setIsFilterPanelOpen:d,limit:I}),R()]})]})},Pwe=({classInfo:e,isLoading:t})=>{const r=e.contractClass,n=e.accounts,i=[{key:"id",label:"Class ID"},{key:"creationTimestamp",label:"Creation Time"},{key:"txHash",label:"Transaction Hash"},{key:"blockNumber",label:"Block Number"},{key:"blockHash",label:"Block Hash"},{key:"version",label:"Version"},{key:"artifactHash",label:"Artifact Hash"},{key:"privateFunctionsRoot",label:"Private Functions Root"}],a=[{title:"Summary",icon:M.jsx(vr,{variant:"blue",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(hv,{className:"w-4 h-4"})}),fields:["id","creationTimestamp","txHash"]},{title:"Block Details",icon:M.jsx(vr,{variant:"purple",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(Zf,{className:"w-4 h-4"})}),fields:["blockNumber","blockHash","version"]},{title:"Class Information",icon:M.jsx(vr,{variant:"yellow",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(w6,{className:"w-4 h-4"})}),fields:["artifactHash","privateFunctionsRoot"]}];return M.jsxs("div",{className:"flex flex-col gap-8",children:[M.jsx(kg,{data:r,fields:i,groups:a,isLoading:t}),n&&n.length>0&&M.jsx("div",{className:"mt-4",children:M.jsx(ac,{data:n,title:"Contract Instances",titleIcon:M.jsx(Nm,{className:"w-4 h-4"}),theme:"tx",columns:[{key:"address",label:"Address",width:"30%",type:"address",cellClassName:"",mobile:{order:1,showLabel:!0}},{key:"blockNumber",label:"Block Number",width:"20%",type:"number",cellClassName:"",mobile:{order:2,showLabel:!0}},{key:"creationTimestamp",label:"Created",width:"20%",type:"timestamp",cellClassName:"",mobile:{order:3,showLabel:!0}},{key:"balance",label:"Balance",width:"10%",type:"fee",cellClassName:"",mobile:{order:4,showLabel:!0}}],variant:"detailed",loading:t,error:!1,limit:10})})]})},zwe=({classInfo:e,isLoading:t})=>{var R;const r=["bytecode","read","write"],n=to(),i=g6(),[a,s]=he.useState("bytecode");he.useEffect(()=>{const C=n.hash.replace("#","");C?r.includes(C)?s(C):(i("#bytecode",{replace:!0}),s("bytecode")):(i("#bytecode",{replace:!0}),s("bytecode"))},[n,i]);const o=r.map(C=>({key:C,label:C.charAt(0).toUpperCase()+C.slice(1),to:`#${C}`})),[c,l]=he.useState("hex"),[u,d]=he.useState([]),p=he.useRef([]),{readContract:w}=Eq();he.useEffect(()=>{!a||!(e!=null&&e.publicFunctions)||(p.current=p.current.slice(0,e.publicFunctions.length))},[(R=e==null?void 0:e.publicFunctions)==null?void 0:R.length]);const O=()=>{var j;const C=()=>{var re;if(!((re=e==null?void 0:e.packedBytecode)!=null&&re.data))return"[]";const N=e.packedBytecode.data,P="0x"+je.from(N,"binary").toString("hex"),Z=je.from(N,"binary").toString("base64"),X=[...je.from(N,"binary")].map(ne=>ne.toString(2).padStart(8,"0")).join(" ");if(c==="hex")return P;if(c==="base64")return Z;if(c==="binary")return X};return M.jsx("div",{className:"flex flex-col gap-5 p-6",children:M.jsx("textarea",{className:`w-full h-52 p-4 border border-surface-border bg-surface-card rounded-xl resize-y leading-7 font-mono text-sm focus:outline-none focus:border-brand-purple/50 transition-colors ${(j=e==null?void 0:e.packedBytecode)!=null&&j.data?"text-text-primary":"text-text-muted"}`,value:C(),readOnly:!0})})},I=C=>{var P;if(((P=e==null?void 0:e.publicFunctions)==null?void 0:P.length)===0||!(e!=null&&e.publicFunctions))return M.jsx("div",{className:"flex flex-col items-center justify-center w-full h-64 p-6",children:M.jsxs("p",{className:"text-text-muted font-normal text-sm",children:["No ",C," functions foun
2126d"]})});let j=0;const N=e.publicFunctions.map((Z,X)=>{var re;if(C==="read"&&Z.isStatic||C==="write"&&!Z.isStatic){j++;const ne=u.includes(X),ae=()=>{d(ue=>ne?ue.filter(m=>m!==X):[...ue,X])};return M.jsxs("div",{className:"border border-surface-border rounded-xl overflow-hidden bg-surface-card hover:border-brand-purple/30 transition-colors",children:[M.jsxs("div",{onClick:ae,className:"flex items-center justify-between px-4 py-3 cursor-pointer hover:bg-surface-hover transition-colors",children:[M.jsxs("div",{className:"flex items-center gap-3",children:[M.jsxs("span",{className:"text-sm font-medium text-text-primary",children:[j,". ",Z.name]}),M.jsx(vr,{variant:Z.functionType==="private"?"warning":Z.functionType==="public"?"success":"default",children:Z.functionType})]}),M.jsx("span",{className:"text-text-muted",children:ne?M.jsx(OW,{size:20}):M.jsx(IW,{size:20})})]}),M.jsx("div",{ref:ue=>p.current[X]=ue,className:"transition-all duration-300 ease-in-out overflow-hidden",style:{height:ne?`${(re=p.current[X])==null?void 0:re.scrollHeight}px`:"0px"},children:M.jsxs("div",{className:"px-4 pb-4 pt-2 flex flex-col gap-4 border-t border-surface-border",children:[(Z==null?void 0:Z.parameters)&&Z.parameters.map(ue=>M.jsxs("div",{className:"flex flex-col gap-2",children:[M.jsxs("div",{className:"flex items-center gap-2 text-sm",children:[M.jsx("span",{className:"text-text-primary font-medium",children:ue.name}),M.jsx(vr,{variant:ue.visibility==="private"?"warning":"success",size:"sm",children:ue.visibility})]}),M.jsx(Vr,{placeholder:`[${Object.values(ue.type).toString().replaceAll(",","]  [")}]`,className:"font-mono text-sm"})]},ue.name)),M.jsx(St,{onClick:async()=>{await w()},variant:"primary",size:"sm",className:"w-fit",children:"Read"})]})})]},Z.name)}});return j===0?M.jsx("div",{className:"flex flex-col items-center justify-center w-full h-64 p-6",children:M.jsxs("p",{className:"text-text-muted font-normal text-sm",children:["No ",C," functions found"]})}):M.jsx("div",{className:"flex flex-col gap-3 p-6",children:N})};return M.jsxs(ch,{variant:"flat",padding:"none",className:"w-full",children:[M.jsxs("div",{className:"flex items-center justify-between gap-2 p-4 border-b border-surface-border",children:[M.jsx(Sg,{items:o,activeKey:a,roundness:"full",size:"sm",className:"w-min bg-surface-main"}),M.jsxs("select",{id:"view-selector",className:" w-[130px] h-8 px-3 py-2 border text-xs border-surface-border bg-surface-main text-text-primary rounded-md focus:outline-none focus:border-brand-purple/50 transition-colors",value:c,onChange:C=>l(C.target.value),children:[M.jsx("option",{value:"hex",children:"Hexadecimal"}),M.jsx("option",{value:"base64",children:"Base64"}),M.jsx("option",{value:"binary",children:"Binary"})]})]}),a==="bytecode"?O():I(a)]})},Lwe=()=>{const[e,t]=he.useState(null),{hash:r}=$d(),{network:n}=di(),i=Vn({queryKey:["class",r,n],queryFn:()=>dY(r,n),enabled:!!r,onError:o=>{console.error("Failed to fetch class:",o),t("Failed to fetch class. Please try again later.")}}),a=i.data||[],s=i.isLoading;return M.jsxs(M.Fragment,{children:[M.jsx(Ms,{route:"/classes"}),M.jsxs("div",{className:"px-[6.5vw] py-[73px] w-full flex flex-col gap-4",children:[M.jsx(Ts,{variant:"detail",title:"Class",showSearchBar:!0}),e?M.jsx(pi,{message:e,type:"general_error"}):!i.isLoading&&!i.data?M.jsx(pi,{message:"Class Not Found",type:"not_found",currentNetwork:n.name}):M.jsxs("div",{className:"flex flex-col w-full gap-8",children:[M.jsx(Pwe,{classInfo:a,isLoading:s}),M.jsx(zwe,{classInfo:a,isLoading:s})]})]})]})},Dwe=({checked:e=!1,onChange:t,disabled:r=!1,size:n="md",className:i})=>{const a={sm:{track:"w-8 h-4",thumb:"w-3 h-3",translate:"translate-x-4"},md:{track:"w-10 h-5",thumb:"w-4 h-4",translate:"translate-x-5"},lg:{track:"w-12 h-6",thumb:"w-5 h-5",translate:"translate-x-6"}},s=a[n]||a.md;return M.jsx("button",{type:"button",role:"switch","aria-checked":e,disabled:r,onClick:()=>!r&&(t==null?void 0:t(!e)),className:mt("relative inline-flex items-center rounded-full transition-colors duration-200 focus:outline-none focus:ring-2 focus:ring-brand-purple/50 focus:ring-offset-2 focus:ring-offset-surface-main",s.track,e?"bg-brand-purple":"bg-surface-border",r&&"opacity-50 cursor-not-allowed",!r&&"cursor-pointer",i),children:M.jsx("span",{className:mt("inline-block rounded-full bg-white shadow-sm transform transition-transform duration-200",s.thumb,e?s.translate:"translate-x-0.5")})})},lE=({label:e,description:t,checked:r,onChange:n,disabled:i=!1,disabledReason:a})=>M.jsxs("div",{className:mt("flex items-center justify-between py-4",i&&"opacity-60"),children:[M.jsxs("div",{className:"flex-1 pr-4",children:[M.jsx("p",{className:"text-sm font-medium text-text-primary",children:e}),t&&M.jsx("p",{className:"text-xs text-text-muted mt-0.5",children:t}),i&&a&&M.jsx("p",{className:"text-xs text-brand-purple mt-1",children:a})]}),M.jsx(Dwe,{checked:r,onChange:n,disabled:i})]}),Uwe=64,qwe=64,Vwe={transaction:"purple",block:"blue",address:"pink",contractClass:"orange",other:"default"}
2126,Zwe=({item:e,onEdit:t,onRemove:r,isReadOnly:n=!1,onNetworkSwitch:i})=>{var Z;const[a,s]=he.useState(!1),[o,c]=he.useState(e.tag||""),[l,u]=he.useState(e.description||""),{getTagRoute:d}=a0(),p=d(e.value,e),w=e.valueType||null,O=w?(Z=Km[w])==null?void 0:Z.label:null,I=w?Vwe[w]:"default",R=e.fieldLabel==="Manual Entry",C=()=>{!o.trim()&&!l.trim()||t&&(t(e.value,{tag:o.trim()||null,description:l.trim()||null,fieldLabel:e.fieldLabel,pageType:e.pageType,pagePath:e.pagePath}),s(!1))},j=()=>{c(e.tag||""),u(e.description||""),s(!1)},N=X=>{X.key==="Enter"?C():X.key==="Escape"&&j()},P=()=>{i&&i()};return a&&!n?M.jsxs("div",{className:"flex flex-col gap-3 py-4 px-4 bg-surface-hover rounded-lg",children:[M.jsx("div",{className:"flex items-center gap-2",children:M.jsx("span",{className:"text-xs text-text-muted font-mono break-all flex-1",children:e.value})}),M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx(Vr,{value:o,onChange:X=>X.target.value.length<=Uwe&&c(X.target.value),onKeyDown:N,placeholder:"Tag",height:"sm",roundness:"soft",className:"!w-[140px] !text-xs"}),M.jsx(Vr,{value:l,onChange:X=>X.target.value.length<=qwe&&u(X.target.value),onKeyDown:N,placeholder:"Description",height:"sm",roundness:"soft",className:"flex-1 !text-xs"}),M.jsx(St,{variant:"ghost",size:"icon",onClick:C,className:"!text-brand-green hover:!bg-brand-green/10",children:M.jsx(Rm,{className:"w-4 h-4"})}),M.jsx(St,{variant:"ghost",size:"icon",onClick:j,children:M.jsx(Hd,{className:"w-4 h-4"})})]})]}):M.jsxs("div",{className:"flex items-start justify-between py-3 px-4 hover:bg-surface-hover rounded-lg transition-colors group",children:[M.jsxs("div",{className:"flex-1 min-w-0",children:[M.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[M.jsx("p",{className:"text-xs text-text-primary font-mono break-all",children:e.value}),O&&M.jsx(vr,{variant:I,size:"sm",border:!1,children:O}),R&&!O&&M.jsx(vr,{variant:"default",size:"sm",border:!1,children:"Manual Entry"})]}),e.tag&&M.jsx("p",{className:"text-sm font-medium text-brand-purple mt-1.5",children:e.tag}),e.description&&M.jsx("p",{className:"text-xs text-text-muted mt-1",children:e.description}),p&&M.jsxs(ti,{to:p,onClick:P,className:"inline-flex items-center gap-1 text-[11px] text-text-muted hover:text-brand-purple hover:underline mt-2 transition-colors",children:[M.jsx(UW,{className:"w-3 h-3"}),M.jsx("span",{children:"View source"})]})]}),!n&&M.jsxs("div",{className:"flex items-center gap-1 opacity-0 group-hover:opacity-100 transition-opacity ml-2",children:[M.jsx(St,{variant:"ghost",size:"icon",onClick:()=>s(!0),children:M.jsx(x6,{className:"w-4 h-4"})}),M.jsx(St,{variant:"ghost",size:"icon",onClick:()=>r==null?void 0:r(e.value),className:"hover:!text-brand-red hover:!bg-brand-red/10",children:M.jsx(mv,{className:"w-4 h-4"})})]})]})},$we=64,Hwe=64,Wwe=Object.entries(Km).map(([e,t])=>({key:e,label:t.label})),Kwe=({onAdd:e,onCancel:t})=>{const[r,n]=he.useState(""),[i,a]=he.useState(""),[s,o]=he.useState(""),[c,l]=he.useState("other"),[u,d]=he.useState(""),p=()=>{if(!r.trim()){d("Value is required");return}if(!i.trim()&&!s.trim()){d("Tag or description is required");return}e(r.trim(),{tag:i.trim()||null,description:s.trim()||null,fieldLabel:"Manual Entry",pageType:"Settings",pagePath:null,valueType:c}),n(""),a(""),o(""),l("other"),d(""),t()},w=O=>{O.key==="Enter"?p():O.key==="Escape"&&t()};return M.jsxs("div",{className:"flex flex-col gap-3 p-4 bg-surface-hover rounded-lg border border-surface-border",children:[M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx(fv,{className:"w-4 h-4 text-brand-purple"}),M.jsx("span",{className:"text-sm font-medium text-text-primary",children:"Add New Tag"})]}),M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx(Vr,{value:r,onChange:O=>{n(O.target.value),d("")},onKeyDown:w,placeholder:"Value (address, hash, etc.)",height:"sm",roundness:"soft",error:!!u&&!r.trim(),className:"flex-1 !text-xs font-mono"}),M.jsx("select",{value:c,onChange:O=>l(O.target.value),className:"h-[32px] px-2 text-xs bg-surface-main border border-surface-border rounded-md text-text-primary focus:outline-none focus:ring-1 focus:ring-brand-purple/50",children:Wwe.map(O=>
2126M.jsx("option",{value:O.key,children:O.label},O.key))})]}),M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx(Vr,{value:i,onChange:O=>O.target.value.length<=$we&&a(O.target.value),onKeyDown:w,placeholder:"Tag",height:"sm",roundness:"soft",className:"!w-[140px] !text-xs"}),M.jsx(Vr,{value:s,onChange:O=>O.target.value.length<=Hwe&&o(O.target.value),onKeyDown:w,placeholder:"Description",height:"sm",roundness:"soft",className:"flex-1 !text-xs"})]}),u&&M.jsx("p",{className:"text-xs text-brand-red",children:u}),M.jsxs("div",{className:"flex items-center justify-end gap-2",children:[M.jsx(St,{variant:"ghost",size:"sm",onClick:t,children:"Cancel"}),M.jsx(St,{variant:"purple",size:"sm",onClick:p,children:"Add Tag"})]})]})},cE={[ro.MAINNET]:"Mainnet",[ro.DEVNET]:"Devnet",[ro.TESTNET]:"Testnet"},Gwe=()=>{const{network:e,setNetwork:t}=di(),{rawSettings:r,updateSetting:n,getAllTags:i,getTagsForNetwork:a,setTag:s,removeTag:o,clearAllTags:c,exportTags:l,importTags:u,isMobile:d,storageError:p,clearStorageError:w}=a0(),[O,I]=he.useState(!1),[R,C]=he.useState(""),[j,N]=he.useState(e),[P,Z]=he.useState(!1),[X,re]=he.useState(""),ne=he.useRef(null),ae=he.useMemo(()=>j===e?i():a(j),[j,e,i,a]),ue=he.useMemo(()=>{if(!X.trim())return ae;const v=X.toLowerCase().trim();return ae.filter(F=>{var Y,V,W;const Q=(Y=F.tag)==null?void 0:Y.toLowerCase().includes(v),G=(V=F.description)==null?void 0:V.toLowerCase().includes(v),J=(W=F.value)==null?void 0:W.toLowerCase().includes(v);return Q||G||J})},[ae,X]),m=j!==e,{page:A,limit:f,renderPaginationButtons:g}=p1(ue.length,j+X),_=he.useMemo(()=>{const v=(A-1)*f;return ue.slice(v,v+f)},[ue,A,f]),B=Object.values(ro).map(v=>({key:v,label:cE[v]})),T=()=>{const v={settings:r,tags:JSON.parse(l()),network:e,exportedAt:new Date().toISOString()},F=new Blob([JSON.stringify(v,null,2)],{type:"application/json"}),Q=URL.createObjectURL(F),G=document.createElement("a");G.href=Q,G.download=`aztec-explorer-notes-${e}-${new Date().toISOString().split("T")[0]}.json`,document.body.appendChild(G),G.click(),document.body.removeChild(G),URL.revokeObjectURL(Q)},S=()=>{var v;(v=ne.current)==null||v.click()},h=v=>{var G;const F=(G=v.target.files)==null?void 0:G[0];if(!F)return;const Q=new FileReader;Q.onload=J=>{try{const Y=JSON.parse(J.target.result);if(Y.tags){const V=u(JSON.stringify(Y.tags),!0);if(!V.success){C("Failed to import tags: "+V.error);return}}Y.settings&&Object.entries(Y.settings).forEach(([V,W])=>{n(V,W)}),C("")}catch{C("Invalid file format")}},Q.readAsText(F),v.target.value=""},x=v=>{v!==e&&t(v)};return M.jsxs(M.Fragment,{children:[M.jsx(Ms,{title:"Settings | Aztec Explorer",description:"Manage your Aztec Explorer settings and saved notes.",keywords:"settings, notes, tags, Aztec Explorer"}),M.jsxs("div",{className:"py-[73px] w-full flex flex-col gap-6",children:[M.jsx(Ts,{variant:"detail",title:"Settings"}),M.jsxs("div",{className:"flex flex-col w-full gap-6",children:[M.jsxs(ch,{variant:"flat",padding:"none",children:[M.jsxs("div",{className:"flex items-center gap-2 px-4 h-[50px] border-surface-border",children:[M.jsx(vr,{variant:"purple",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(LW,{className:"w-4 h-4"})}),M.jsx("h2",{className:"text-text-primary font-bold text-[12px] uppercase tracking-wide",children:"Display Options"})]}),M.jsxs("div",{className:"px-4 divide-y divide-surface-border",children:[M.jsx(lE,{label:"Display Tags Instead of Actual Values",description:"Show your custom tags in place of raw addresses and hashes",checked:r.displayTagsInsteadOfValues,onChange:v=>n("displayTagsInsteadOfValues",v)}),M.jsx(lE,{label:"Display Note Popovers",description:"Show popover with original value and notes when hovering tagged items",checked:r.displayNotePopovers,onChange:v=>n("displayNotePopovers",v),disabled:d,disabledReason:"Disabled on mobile devices"}),M.jsx(lE,{label:"Allow Hover Effects for Adding Notes",description:"Show edit button when hovering over taggable values",checked:r.allowHoverEffects,onChange:v=>n("allowHoverEffects",v),disabled:d,disabledReason:"Disabled on mobile devices"})]})]}),M.jsxs(ch,{variant:"flat",padding:"none",children:[M.jsxs("div",{className:"flex items-center justify-between px-4 py-3 border-surface-border below-mobile:flex-col below-mobile:items-start below-mobile:gap-5",children:[M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx(vr,{variant:"green",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(dv,{className:"w-4 h-4"})}),M.jsx("h2",{className:"text-text-primary font-bold text-[12px] uppercase tracking-wide",children:"Saved Notes"}),M.jsxs("span",{className:"text-xs text-text-muted",children:["(",ue.length,X&&ue.length!==ae.length?` of ${ae.length}`:""," ",ae.length===1?"item":"items",")"]})]}),M.jsxs("div",{className:"flex items-center gap-5",children:[M.jsx(Sg,{items:B,activeKey:j,onChange:N,size:"xs",roundness:"full",className:"w-min"}),M.jsxs("div",{className:"flex items-center gap-2",children:[!O&&M.jsx(St,{variant:"ghost",size:"sm",onClick:()=>I(!0),iconBefore:M.jsx(fv,{className:"w-3.5 h-3.5"}),children:"Add"}),ae.length>0&&!m&&(P?M.jsxs("div",{className:"flex items-center gap-1",children:[M.jsx("span",{className:"text-[10px] text-text-muted",children:"Clear all?"}),M.jsx(St,{variant:"ghost",size:"xs",onClick:()=>{c(),Z(!1)},className:"!text-brand-red hover:!bg-brand-red/10",children:"Yes"}),M.jsx(St,{variant:"ghost",size:"xs",onClick:()=>Z(!1),children:"No"})]}):M.jsx(St,{variant:"ghost",size:"sm",onClick:()=>Z(!0),iconBefore:M.jsx(mv,{className:"w-3.5 h-3.5"}),className:"!text-brand-red hover:!bg-brand-red/10",children:"Clear All"}))]})]})]}),ae.length>0&&M.jsx("div",{className:"px-4 pb-3",children:M.jsx(Vr,{value:X,onChange:v=>re(v.target.value),placeholder:"Search notes...",height:"sm",roundness:"soft",iconBefore:M.jsx(pv,{className:"w-4 h-4 text-text-muted"}),className:"!text-xs"})}),M.jsxs("div",{className:"p-4 flex flex-col gap-2",children:[p&&M.jsxs("div",{className:"flex items-center justify-between bg-brand-red/10 border border-brand-red/20 rounded-lg px-4 py-3 mb-2",children:[M.jsx("p",{className:"text-sm text-brand-red",children:p}),M.jsx(St,{variant:"ghost",size:"xs",onClick:w,className:"!text-brand-red hover:!bg-brand-red/10",children:"Dismiss"})]}),O&&M.jsx(Kwe,{onAdd:s,onCancel:()=>I(!1)}),ue.length===0&&!O?M.jsxs("div",{className:"py-8 text-center",children:[M.jsx(dv,{className:"w-8 h-8 text-text-muted mx-auto mb-2"}),X?M.jsxs(M.Fragment,{children:[M.jsxs("p",{className:"text-sm text-text-muted",children:['No notes matching "',X,'"']}),M.jsx("p",{className:"text-xs text-text-muted mt-1",children:"Try a different search term"})]}):M.jsxs(M.Fragment,{children:[M.jsxs("p",{className:"text-sm text-text-muted",children:["No saved notes for ",cE[j]]}),M.jsx("p",{className:"text-xs text-text-muted mt-1",children:"Hover over addresses and hashes to add notes, or click Add above"})]})]}):M.jsxs("div",{className:"flex flex-col",children:[_.map(v=>M.jsx(Zwe,{item:v,onEdit:m?void 0:s,onRemove:m?void 0:o,isReadOnly:m,onNetworkSwitch:()=>x(j)},v.value)),ue.length>f&&g()]})]})]}),M.jsxs(ch,{variant:"flat",padding:"none",children:[M.jsx("div",{className:"flex items-center justify-between px-4 h-[50px] border-surface-border",children:M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx(vr,{variant:"blue",icon:!0,border:!1,className:"w-6 h-6",children:M.jsx(FW,{className:"w-4 h-4"})}),M.jsx("h2",{className:"text-text-primary font-bold text-[12px] uppercase tracking-wide",children:"Import / Export"})]})}),M.jsxs("div",{className:"px-4 py-4 w-full flex justify-between items-center",children:[M.jsxs("p",{className:"text-xs text-text-muted",children:["Backup or restore your settings and notes for"," ",cE[e]]}),M.jsxs("div",{className:"flex items-center gap-2",children:[M.jsx("input",{ref:ne,type:"file",accept:".json",onChange:h,className:"hidden"}),M.jsx(St,{variant:"gray",size:"sm",onClick:S,children:"Import"}),M.jsx(St,{variant:"purple",size:"sm",onClick:T,children:"Export"})]}),R&&M.jsx("p",{className:"text-xs text-brand-red mt-2",children:R})]})]})]})]})]})},Ywe=({dotSize:e=1,density:t=20,dotColor:r="currentColor",dotOpacity:n=.3,dotOpacityLight:i,fadeOut:a=!0,className:s,...o})=>{const c=t,l=e,u=i??n,d={backgroundImage:`radial-gradient(${r} ${l}px, transparent ${l}px)`,backgroundSize:`${c}px ${c}px`,...a&&{maskImage:"linear-gradient(to bottom, black 0%, transparent 100%)",WebkitMaskImage:"linear-gradient(to bottom, black 0%, transparent 100%)"}};return M.jsxs("div",{className:mt("absolute inset-0 pointer-events-none",s),...o,children:[M.jsx("div",{className:"absolute inset-0 block dark:hidden",style:{...d,opacity:u}}),M.jsx("div",{className:"absolute inset-0 hidden dark:block",style:{...d,opacity:n}})]})};function Xwe(){const e=to().pathname==="/";return M.jsxs("div",{className:"w-screen min-h-screen flex flex-col justify-between items-center relative bg-surface-main ",children:[e&&M.jsx(Ywe,{dotOpacity:.5,dotOpacityLight:.15,density:24,dotColor:Xa.brand.purple,className:"!h-[600px] top-0 left-0 right-0"}),M.jsx("div",{className:"w-full max-w-[1980px] items-center  px-[7vw] below-mobile-xs:px-[7vw] ",children:M.jsx(Sie,{})}),M.jsx("div",{className:"flex flex-col w-full max-w-[1980px] items-center justify-center px-[7vw] below-mobile-xs:px-[7vw] ",children:M.jsxs(fW,{children:[M.jsx(Ga,{path:"/",element:M.jsx(eie,{})}),M.jsx(Ga,{path:"/tx/:hash",element:M.jsx(wie,{})}),M.jsx(Ga,{path:"/block/:hash",element:M.jsx(Eie,{})}),M.jsx(Ga,{path:"/address/:hash",element:M.jsx(jwe,{})}),M.jsx(Ga,{path:"/addresses",element:M.jsx(Bwe,{})}),M.jsx(Ga,{path:"/blocks",element:M.jsx(Iwe,{})}),M.jsx(Ga,{path:"/transactions",element:M.jsx(Owe,{})}),M.jsx(Ga,{path:"/network",element:M.jsx(Nwe,{})}
2126),M.jsx(Ga,{path:"/classes",element:M.jsx(Fwe,{})}),M.jsx(Ga,{path:"/class/:hash",element:M.jsx(Lwe,{})}),M.jsx(Ga,{path:"/settings",element:M.jsx(Gwe,{})}),M.jsx(Ga,{path:"*",element:M.jsx(LX,{})})]})}),M.jsx("div",{className:"w-full max-w-[1980px] items-center  px-[7vw] below-mobile-xs:px-[7vw] border-t border-surface-border ",children:M.jsx(XW,{})})]})}const Jwe=new oJ;K1.createRoot(document.getElementById("root")).render(M.jsx(Ei.StrictMode,{children:M.jsx(yW,{children:M.jsx(fJ,{client:Jwe,children:M.jsx(YW,{children:M.jsx(DJ,{children:M.jsx(ST,{children:M.jsx(Xwe,{})})})})})})}))})();export{Qr as L,K_e as __tla,M as j,he as r};

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